BREAKING CHANGE(decorators): Migrate to TC39 standard decorators (accessor) across components, update tsconfig and bump dependencies
This commit is contained in:
@@ -23,33 +23,33 @@ export class DeesInputFileupload extends DeesInputBase<DeesInputFileupload> {
|
||||
public static demo = demoFunc;
|
||||
|
||||
@property({ attribute: false })
|
||||
public value: File[] = [];
|
||||
accessor value: File[] = [];
|
||||
|
||||
@state()
|
||||
public state: 'idle' | 'dragOver' | 'dropped' | 'uploading' | 'completed' = 'idle';
|
||||
accessor state: 'idle' | 'dragOver' | 'dropped' | 'uploading' | 'completed' = 'idle';
|
||||
|
||||
@state()
|
||||
public isLoading: boolean = false;
|
||||
accessor isLoading: boolean = false;
|
||||
|
||||
@property({ type: String })
|
||||
public buttonText: string = 'Select files';
|
||||
accessor buttonText: string = 'Select files';
|
||||
|
||||
@property({ type: String })
|
||||
public accept: string = '';
|
||||
accessor accept: string = '';
|
||||
|
||||
@property({ type: Boolean })
|
||||
public multiple: boolean = true;
|
||||
accessor multiple: boolean = true;
|
||||
|
||||
@property({ type: Number })
|
||||
public maxSize: number = 0; // 0 means no limit
|
||||
accessor maxSize: number = 0; // 0 means no limit
|
||||
|
||||
@property({ type: Number })
|
||||
public maxFiles: number = 0; // 0 means no limit
|
||||
accessor maxFiles: number = 0; // 0 means no limit
|
||||
|
||||
@property({ type: String, reflect: true })
|
||||
public validationState: 'valid' | 'invalid' | 'warn' | 'pending' = null;
|
||||
accessor validationState: 'valid' | 'invalid' | 'warn' | 'pending' = null;
|
||||
|
||||
public validationMessage: string = '';
|
||||
accessor validationMessage: string = '';
|
||||
|
||||
private previewUrlMap: WeakMap<File, string> = new WeakMap();
|
||||
private dropArea: HTMLElement | null = null;
|
||||
|
||||
Reference in New Issue
Block a user