From 47ac90041df5a63ebf345cc923e4305d8f518aaf Mon Sep 17 00:00:00 2001 From: jm186140 Date: Mon, 15 Jan 2018 14:34:33 -0800 Subject: [PATCH 1/3] feat(file-input): change API from tables to lists --- src/platform/core/file/file-input/README.md | 29 ++++++++++++++------- 1 file changed, 20 insertions(+), 9 deletions(-) diff --git a/src/platform/core/file/file-input/README.md b/src/platform/core/file/file-input/README.md index 7825f4291f..40f3fbd1c0 100644 --- a/src/platform/core/file/file-input/README.md +++ b/src/platform/core/file/file-input/README.md @@ -33,16 +33,27 @@ export class Demo { ## API Summary -Properties: +#### Inputs -| Name | Type | Description | -| --- | --- | 650--- | -| color | string | Sets button color. Uses same color palette accepted as [MatButton]. -| multiple | boolean | Sets if multiple files can be dropped/selected at once in [TdFileUploadComponent]. -| accept | string | Sets files accepted when opening the file browser dialog. Same as "accept" attribute in `` element. -| disabled | boolean | Disables [TdFileUploadComponent] and clears selected/dropped files. -| select | function($event) | Event emitted when a file is selected. Emits a [File or FileList] object. -| clear | function() | Used to clear the selected files from the [TdFileInputComponent]. ++ color: string + + Sets button color. Uses same color palette accepted as [MatButton]. ++ multiple: boolean + + Sets if multiple files can be dropped/selected at once in [TdFileUploadComponent]. ++ accept: string + + Sets files accepted when opening the file browser dialog. Same as "accept" attribute in `` element. ++ disabled: boolean + + Disables [TdFileUploadComponent] and clears selected/dropped files. + +#### Events + ++ select: function($event) + + Event emitted when a file is selected. + + Emits a [File or FileList] object. + +#### Methods + ++ clear: function + + Used to clear the selected files from the [TdFileInputComponent]. ## Setup From 4e08659190c7fadf9380cc892a505c31ba422f18 Mon Sep 17 00:00:00 2001 From: jm186140 Date: Mon, 15 Jan 2018 15:35:44 -0800 Subject: [PATCH 2/3] feat(file-input): change API from tables to lists --- src/platform/core/file/file-input/README.md | 32 ++++++++++++--------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/src/platform/core/file/file-input/README.md b/src/platform/core/file/file-input/README.md index 40f3fbd1c0..e847d4987e 100644 --- a/src/platform/core/file/file-input/README.md +++ b/src/platform/core/file/file-input/README.md @@ -89,14 +89,17 @@ Example for usage: ## API Summary -Properties: +#### Inputs -| Name | Type | Description | -| --- | --- | 650--- | -| multiple | boolean | Sets whether multiple files can be selected at once in host element, or just a single file. Can also be "multiple" native attribute. -| fileSelect | function($event) | Event emitted when a file or files are selected in host [HTMLInputElement]. Emits a [FileList or File] object. Alternative to not use [(ngModel)]. ++ multiple: boolean + + Sets whether multiple files can be selected at once in host element, or just a single file. + + Can also be "multiple" native attribute. ---- +#### Events + ++ fileSelect: function($event) + + Event emitted when a file or files are selected in host [HTMLInputElement]. + + Emits a [FileList or File] object. Alternative to not use [(ngModel)]. ## TdFileDropDirective: tdFileDrop @@ -118,13 +121,16 @@ Example for usage: ## API Summary -Properties: +#### Inputs -| Name | Type | Description | -| --- | --- | 650--- | -| multiple | boolean | Sets whether multiple files can be dropped at once in host element, or just a single file. Can also be "multiple" native attribute. -| disabled | boolean | Disabled drop events for host element. -| fileDrop | function($event) | Event emitted when a file or files are dropped in host element after being validated. Emits a [FileList or File] object. ++ multiple: boolean + + Sets whether multiple files can be dropped at once in host element, or just a single file. + + Can also be "multiple" native attribute. ++ disabled: boolean + + Disabled drop events for host element. +#### Events ---- ++ fileDrop: function($event) + + Event emitted when a file or files are dropped in host element after being validated. + + Emits a [FileList or File] object. From 5668324dbb7447beb10fe952b8b677b02521c4e3 Mon Sep 17 00:00:00 2001 From: jm186140 Date: Mon, 15 Jan 2018 15:47:09 -0800 Subject: [PATCH 3/3] feat(file-input): change API from tables to lists --- src/platform/core/file/file-input/README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/platform/core/file/file-input/README.md b/src/platform/core/file/file-input/README.md index e847d4987e..2afe0697b5 100644 --- a/src/platform/core/file/file-input/README.md +++ b/src/platform/core/file/file-input/README.md @@ -132,5 +132,7 @@ Example for usage: #### Events + fileDrop: function($event) - + Event emitted when a file or files are dropped in host element after being validated. + + Event emitted when a file or files are dropped in host element after being validated. + Emits a [FileList or File] object. + +