The ld-choose-file
component is used internally for the ld-file-upload
. It is the visual part of the drag and drop area.
<ld-choose-file></ld-choose-file>
TODO: emit files chosen event with file list, that's it.
Property | Attribute | Description | Type | Default |
---|---|---|---|---|
key |
key |
for tracking the node's identity when working with lists | string | number |
undefined |
maxSize |
max-size |
Max. file size in bytes | number |
1572864 |
ref |
ref |
reference to component | any |
undefined |
uploadFiles |
-- | Chosen Files | { state: "pending" | "uploading" | "uploaded" | "upload failed"; fileName: string; fileSize: number; progress: number; }[] |
[] |
Event | Description | Type |
---|---|---|
ldchoosefiles |
CustomEvent<FileList> |
Part | Description |
---|---|
"list" |
ul element wrapping the default slot |
graph TD;
ld-choose-file --> ld-typo
ld-choose-file --> ld-input
ld-file-upload --> ld-choose-file
style ld-choose-file fill:#f9f,stroke:#333,stroke-width:4px
Built with StencilJS