@ieeesa-npm/presentation 0.26.8 → 0.26.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/assets/constants.json +17 -0
- package/esm2022/lib/components/dynamic-form/dynamic-form.component.mjs +11 -3
- package/esm2022/lib/components/file-download/file-download.component.mjs +132 -0
- package/esm2022/lib/components/file-upload/file-upload.component.mjs +26 -4
- package/esm2022/lib/components/list/list.component.mjs +24 -3
- package/esm2022/lib/directives/dynamic-form-field/dynamic-form-field.directive.mjs +14 -2
- package/esm2022/lib/models/download-file.model.mjs +1 -1
- package/esm2022/lib/models/file-download-config.model.mjs +2 -0
- package/esm2022/lib/models/file-upload-presigned-url-res.model.mjs +1 -1
- package/esm2022/lib/models/file-upload-status.model.mjs +1 -1
- package/esm2022/lib/models/list-item.model.mjs +1 -1
- package/esm2022/lib/services/file-upload.service.mjs +11 -2
- package/esm2022/public-api.mjs +2 -1
- package/fesm2022/ieeesa-npm-presentation.mjs +240 -32
- package/fesm2022/ieeesa-npm-presentation.mjs.map +1 -1
- package/lib/components/chips/chips.component.d.ts +15 -0
- package/lib/components/dynamic-form/dynamic-form.component.d.ts +6 -2
- package/lib/components/file-download/file-download.component.d.ts +362 -0
- package/lib/components/file-upload/file-upload.component.d.ts +33 -9
- package/lib/components/list/list.component.d.ts +12 -1
- package/lib/directives/dynamic-form-field/dynamic-form-field.directive.d.ts +6 -2
- package/lib/directives/file-upload/file-upload.directive.d.ts +1 -1
- package/lib/models/download-file.model.d.ts +1 -1
- package/lib/models/file-download-config.model.d.ts +8 -0
- package/lib/models/file-upload-presigned-url-res.model.d.ts +18 -0
- package/lib/models/file-upload-status.model.d.ts +1 -1
- package/lib/models/list-item.model.d.ts +2 -0
- package/lib/services/file-upload.service.d.ts +26 -9
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
- package/src/lib/assets/constants.json +17 -0
|
@@ -300,6 +300,21 @@ export declare class ChipsComponent implements OnInit, OnDestroy {
|
|
|
300
300
|
colorPicker: string;
|
|
301
301
|
};
|
|
302
302
|
};
|
|
303
|
+
fileDownload: {
|
|
304
|
+
buttons: {
|
|
305
|
+
id: number;
|
|
306
|
+
ariaLabel: string;
|
|
307
|
+
iconURL: string;
|
|
308
|
+
toolTip: string;
|
|
309
|
+
disabled: boolean;
|
|
310
|
+
}[];
|
|
311
|
+
preSignedDuration: string;
|
|
312
|
+
message: {
|
|
313
|
+
errors: {
|
|
314
|
+
errorReadingFile: string;
|
|
315
|
+
};
|
|
316
|
+
};
|
|
317
|
+
};
|
|
303
318
|
};
|
|
304
319
|
chipsType: typeof ChipsType;
|
|
305
320
|
orientations: typeof ChipOrientation;
|
|
@@ -15,6 +15,7 @@ import { RadioOption } from '../../models/radio-option.model';
|
|
|
15
15
|
import { IconButton } from '../../models/icon-button.model';
|
|
16
16
|
import { AutoCompleteOption } from '../../models/autocomplete-option.model';
|
|
17
17
|
import { FileUploadStatus } from '../../models/file-upload-status.model';
|
|
18
|
+
import { FileDownloadConfig } from '../../models/file-download-config.model';
|
|
18
19
|
import * as i0 from "@angular/core";
|
|
19
20
|
/**
|
|
20
21
|
* Creates a reactive form dynamically based on the passed form field configuration and handles the form events.
|
|
@@ -60,6 +61,9 @@ export declare class DynamicFormComponent implements OnInit, AfterContentInit, A
|
|
|
60
61
|
isLeftButtonNeeded: boolean;
|
|
61
62
|
isRightButtonNeeded: boolean;
|
|
62
63
|
actionButtonAlign: AlignType;
|
|
64
|
+
_fileDownloadConfig: FileDownloadConfig;
|
|
65
|
+
set fileDownloadConfig(value: FileDownloadConfig);
|
|
66
|
+
get fileDownloadConfig(): FileDownloadConfig;
|
|
63
67
|
alignmentType: typeof AlignType;
|
|
64
68
|
formSubmit: EventEmitter<any>;
|
|
65
69
|
formChange: EventEmitter<any>;
|
|
@@ -87,7 +91,7 @@ export declare class DynamicFormComponent implements OnInit, AfterContentInit, A
|
|
|
87
91
|
formTimeSelected: EventEmitter<SelectedTime>;
|
|
88
92
|
supportTextLinkClick: EventEmitter<LinkEventEmitType>;
|
|
89
93
|
formSlideToggleChange: EventEmitter<SlideToggleOption>;
|
|
90
|
-
formFileUpload: EventEmitter<
|
|
94
|
+
formFileUpload: EventEmitter<File | FileList>;
|
|
91
95
|
dropdownOpenedChange: EventEmitter<SelectOpenedState>;
|
|
92
96
|
formColorPickerChange: EventEmitter<string>;
|
|
93
97
|
formRadioOptionSelected: EventEmitter<RadioOption>;
|
|
@@ -326,5 +330,5 @@ export declare class DynamicFormComponent implements OnInit, AfterContentInit, A
|
|
|
326
330
|
*/
|
|
327
331
|
onCheckboxCTAButtonClick(event: IconButton): void;
|
|
328
332
|
static ɵfac: i0.ɵɵFactoryDeclaration<DynamicFormComponent, never>;
|
|
329
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<DynamicFormComponent, "ieeesa-dynamic-form", ["dynamicForm"], { "formGroups": { "alias": "formGroups"; "required": false; }; "submitResponse": { "alias": "submitResponse"; "required": false; }; "searchResponse": { "alias": "searchResponse"; "required": false; }; "fileUploadStatus": { "alias": "fileUploadStatus"; "required": false; }; "colWidth": { "alias": "colWidth"; "required": false; }; "isLegendVisible": { "alias": "isLegendVisible"; "required": false; }; "rightButtonLabel": { "alias": "rightButtonLabel"; "required": false; }; "leftButtonLabel": { "alias": "leftButtonLabel"; "required": false; }; "isSubmitButtonDisabled": { "alias": "isSubmitButtonDisabled"; "required": false; }; "isLeftButtonDisabled": { "alias": "isLeftButtonDisabled"; "required": false; }; "isLeftButtonNeeded": { "alias": "isLeftButtonNeeded"; "required": false; }; "isRightButtonNeeded": { "alias": "isRightButtonNeeded"; "required": false; }; "actionButtonAlign": { "alias": "actionButtonAlign"; "required": false; }; }, { "formSubmit": "formSubmit"; "formChange": "formChange"; "formInput": "formInput"; "formLeftButtonClicked": "formLeftButtonClicked"; "formSearchApply": "formSearchApply"; "formGroupsReference": "formGroupsReference"; "dropdownChange": "dropdownChange"; "formCheckboxSelection": "formCheckboxSelection"; "formDateSelected": "formDateSelected"; "formSelectSearch": "formSelectSearch"; "formControlChange": "formControlChange"; "formAutoCompleteSearch": "formAutoCompleteSearch"; "formAutoCompleteClearSearchValue": "formAutoCompleteClearSearchValue"; "autoCompleteOptionSelected": "autoCompleteOptionSelected"; "formAfterContentInit": "formAfterContentInit"; "formSelectedDateRange": "formSelectedDateRange"; "addFormGroup": "addFormGroup"; "formTimeSelected": "formTimeSelected"; "supportTextLinkClick": "supportTextLinkClick"; "formSlideToggleChange": "formSlideToggleChange"; "formFileUpload": "formFileUpload"; "dropdownOpenedChange": "dropdownOpenedChange"; "formColorPickerChange": "formColorPickerChange"; "formRadioOptionSelected": "formRadioOptionSelected"; "ctaButtonClick": "ctaButtonClick"; "formMultiSelectAutoCompleteSearch": "formMultiSelectAutoCompleteSearch"; "formMultiSelectAutoCompleteClearSearchValue": "formMultiSelectAutoCompleteClearSearchValue"; "multiSelectAutoCompleteOptionsSelected": "multiSelectAutoCompleteOptionsSelected"; "formRichTextEditorContentChange": "formRichTextEditorContentChange"; }, never, ["[component]"], true, never>;
|
|
333
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DynamicFormComponent, "ieeesa-dynamic-form", ["dynamicForm"], { "formGroups": { "alias": "formGroups"; "required": false; }; "submitResponse": { "alias": "submitResponse"; "required": false; }; "searchResponse": { "alias": "searchResponse"; "required": false; }; "fileUploadStatus": { "alias": "fileUploadStatus"; "required": false; }; "colWidth": { "alias": "colWidth"; "required": false; }; "isLegendVisible": { "alias": "isLegendVisible"; "required": false; }; "rightButtonLabel": { "alias": "rightButtonLabel"; "required": false; }; "leftButtonLabel": { "alias": "leftButtonLabel"; "required": false; }; "isSubmitButtonDisabled": { "alias": "isSubmitButtonDisabled"; "required": false; }; "isLeftButtonDisabled": { "alias": "isLeftButtonDisabled"; "required": false; }; "isLeftButtonNeeded": { "alias": "isLeftButtonNeeded"; "required": false; }; "isRightButtonNeeded": { "alias": "isRightButtonNeeded"; "required": false; }; "actionButtonAlign": { "alias": "actionButtonAlign"; "required": false; }; "fileDownloadConfig": { "alias": "fileDownloadConfig"; "required": false; }; }, { "formSubmit": "formSubmit"; "formChange": "formChange"; "formInput": "formInput"; "formLeftButtonClicked": "formLeftButtonClicked"; "formSearchApply": "formSearchApply"; "formGroupsReference": "formGroupsReference"; "dropdownChange": "dropdownChange"; "formCheckboxSelection": "formCheckboxSelection"; "formDateSelected": "formDateSelected"; "formSelectSearch": "formSelectSearch"; "formControlChange": "formControlChange"; "formAutoCompleteSearch": "formAutoCompleteSearch"; "formAutoCompleteClearSearchValue": "formAutoCompleteClearSearchValue"; "autoCompleteOptionSelected": "autoCompleteOptionSelected"; "formAfterContentInit": "formAfterContentInit"; "formSelectedDateRange": "formSelectedDateRange"; "addFormGroup": "addFormGroup"; "formTimeSelected": "formTimeSelected"; "supportTextLinkClick": "supportTextLinkClick"; "formSlideToggleChange": "formSlideToggleChange"; "formFileUpload": "formFileUpload"; "dropdownOpenedChange": "dropdownOpenedChange"; "formColorPickerChange": "formColorPickerChange"; "formRadioOptionSelected": "formRadioOptionSelected"; "ctaButtonClick": "ctaButtonClick"; "formMultiSelectAutoCompleteSearch": "formMultiSelectAutoCompleteSearch"; "formMultiSelectAutoCompleteClearSearchValue": "formMultiSelectAutoCompleteClearSearchValue"; "multiSelectAutoCompleteOptionsSelected": "multiSelectAutoCompleteOptionsSelected"; "formRichTextEditorContentChange": "formRichTextEditorContentChange"; }, never, ["[component]"], true, never>;
|
|
330
334
|
}
|
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
import { EventEmitter, OnDestroy } from '@angular/core';
|
|
2
|
+
import { FormUtilityService } from '../../services/form-utility.service';
|
|
3
|
+
import { FileUploadService } from '../../services/file-upload.service';
|
|
4
|
+
import { FileDownloadConfig } from '../../models/file-download-config.model';
|
|
5
|
+
import { DownloadFile } from '../../models/download-file.model';
|
|
6
|
+
import { Subject } from 'rxjs';
|
|
7
|
+
import { SharedService } from '@ieeesa-npm/shared';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
export declare class FileDownloadComponent implements OnDestroy {
|
|
10
|
+
formUtilityService: FormUtilityService;
|
|
11
|
+
sharedService: SharedService;
|
|
12
|
+
fileUploadService: FileUploadService;
|
|
13
|
+
constants: {
|
|
14
|
+
ariaLabel: {
|
|
15
|
+
clear: string;
|
|
16
|
+
warning: string;
|
|
17
|
+
previousMonth: string;
|
|
18
|
+
nextMonth: string;
|
|
19
|
+
menuIcon: string;
|
|
20
|
+
close: string;
|
|
21
|
+
search: string;
|
|
22
|
+
addFormGroup: string;
|
|
23
|
+
};
|
|
24
|
+
button: {
|
|
25
|
+
cancel: string;
|
|
26
|
+
ok: string;
|
|
27
|
+
add: string;
|
|
28
|
+
};
|
|
29
|
+
modalConfig: {
|
|
30
|
+
ariaLabel: string;
|
|
31
|
+
autoFocus: string;
|
|
32
|
+
width: string;
|
|
33
|
+
};
|
|
34
|
+
chips: {
|
|
35
|
+
noOfDefaultVisibleChips: number;
|
|
36
|
+
label: {
|
|
37
|
+
viewAll: string;
|
|
38
|
+
viewLess: string;
|
|
39
|
+
};
|
|
40
|
+
ariaLabel: {
|
|
41
|
+
chipsList: string;
|
|
42
|
+
};
|
|
43
|
+
icons: {
|
|
44
|
+
arrow: {
|
|
45
|
+
id: number;
|
|
46
|
+
iconURL: string;
|
|
47
|
+
toolTip: string;
|
|
48
|
+
ariaLabel: string;
|
|
49
|
+
};
|
|
50
|
+
remove: {
|
|
51
|
+
id: number;
|
|
52
|
+
iconURL: string;
|
|
53
|
+
toolTip: string;
|
|
54
|
+
ariaLabel: string;
|
|
55
|
+
};
|
|
56
|
+
check: {
|
|
57
|
+
id: number;
|
|
58
|
+
iconURL: string;
|
|
59
|
+
toolTip: string;
|
|
60
|
+
ariaLabel: string;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
dataTable: {
|
|
65
|
+
label: {
|
|
66
|
+
clearAll: string;
|
|
67
|
+
};
|
|
68
|
+
message: {
|
|
69
|
+
noRecordFound: string;
|
|
70
|
+
};
|
|
71
|
+
ariaLabel: {
|
|
72
|
+
search: string;
|
|
73
|
+
selectAll: string;
|
|
74
|
+
select: string;
|
|
75
|
+
link: string;
|
|
76
|
+
pagination: string;
|
|
77
|
+
};
|
|
78
|
+
buttons: {
|
|
79
|
+
id: number;
|
|
80
|
+
iconURL: string;
|
|
81
|
+
toolTip: string;
|
|
82
|
+
ariaLabel: string;
|
|
83
|
+
}[];
|
|
84
|
+
};
|
|
85
|
+
datePicker: {
|
|
86
|
+
selectDateLabel: string;
|
|
87
|
+
dateFormatLabel: string;
|
|
88
|
+
startDateLabel: string;
|
|
89
|
+
endDateLabel: string;
|
|
90
|
+
datePickerIcon: string;
|
|
91
|
+
};
|
|
92
|
+
dropdown: {
|
|
93
|
+
placeholderText: string;
|
|
94
|
+
};
|
|
95
|
+
filter: {
|
|
96
|
+
label: {
|
|
97
|
+
filterBy: string;
|
|
98
|
+
applyButton: string;
|
|
99
|
+
clearAll: string;
|
|
100
|
+
};
|
|
101
|
+
buttons: {
|
|
102
|
+
id: number;
|
|
103
|
+
iconURL: string;
|
|
104
|
+
toolTip: string;
|
|
105
|
+
ariaLabel: string;
|
|
106
|
+
}[];
|
|
107
|
+
};
|
|
108
|
+
textarea: {
|
|
109
|
+
maxLengthDefault: number;
|
|
110
|
+
leftCharacters: string;
|
|
111
|
+
};
|
|
112
|
+
autocomplete: {
|
|
113
|
+
minCharToSearch: number;
|
|
114
|
+
debounceTime: number;
|
|
115
|
+
};
|
|
116
|
+
multiSelectAutoComplete: {
|
|
117
|
+
label: {
|
|
118
|
+
clearAll: string;
|
|
119
|
+
};
|
|
120
|
+
ariaLabel: {
|
|
121
|
+
selectedOption: string;
|
|
122
|
+
removeOption: string;
|
|
123
|
+
};
|
|
124
|
+
icons: {
|
|
125
|
+
remove: string;
|
|
126
|
+
clearAll: string;
|
|
127
|
+
};
|
|
128
|
+
};
|
|
129
|
+
header: {
|
|
130
|
+
alt: {
|
|
131
|
+
logo: string;
|
|
132
|
+
};
|
|
133
|
+
ariaLabel: {
|
|
134
|
+
helpLink: string;
|
|
135
|
+
hamburgerMenu: string;
|
|
136
|
+
};
|
|
137
|
+
label: {
|
|
138
|
+
signOut: string;
|
|
139
|
+
};
|
|
140
|
+
buttons: {
|
|
141
|
+
id: number;
|
|
142
|
+
iconURL: string;
|
|
143
|
+
toolTip: string;
|
|
144
|
+
ariaLabel: string;
|
|
145
|
+
}[];
|
|
146
|
+
userProfileMenuOptions: {
|
|
147
|
+
id: number;
|
|
148
|
+
iconURL: string;
|
|
149
|
+
label: string;
|
|
150
|
+
ariaLabel: string;
|
|
151
|
+
toolTip: string;
|
|
152
|
+
isToolTipNeeded: boolean;
|
|
153
|
+
}[];
|
|
154
|
+
errors: {
|
|
155
|
+
"2029": string;
|
|
156
|
+
};
|
|
157
|
+
};
|
|
158
|
+
footer: {
|
|
159
|
+
alt: {
|
|
160
|
+
logo: string;
|
|
161
|
+
};
|
|
162
|
+
links: {
|
|
163
|
+
label: string;
|
|
164
|
+
ariaLabel: string;
|
|
165
|
+
redirectUrl: string;
|
|
166
|
+
}[];
|
|
167
|
+
ieeeLogo: string;
|
|
168
|
+
copyright: {
|
|
169
|
+
link: string;
|
|
170
|
+
textPart1: string;
|
|
171
|
+
textPart2: string;
|
|
172
|
+
hyperLinkPart3: string;
|
|
173
|
+
textPart4: string;
|
|
174
|
+
};
|
|
175
|
+
};
|
|
176
|
+
welcome: {
|
|
177
|
+
buttons: {
|
|
178
|
+
label: string;
|
|
179
|
+
ariaLabel: string;
|
|
180
|
+
url: string;
|
|
181
|
+
}[];
|
|
182
|
+
};
|
|
183
|
+
breadcrumb: {
|
|
184
|
+
label: {
|
|
185
|
+
initial: string;
|
|
186
|
+
};
|
|
187
|
+
};
|
|
188
|
+
loader: {
|
|
189
|
+
ariaLabel: {
|
|
190
|
+
spinner: string;
|
|
191
|
+
};
|
|
192
|
+
};
|
|
193
|
+
defaultWelcomeBgColor: string;
|
|
194
|
+
timePicker: {
|
|
195
|
+
defaultTimeFormat: number;
|
|
196
|
+
timePickerIcon: string;
|
|
197
|
+
};
|
|
198
|
+
colorPicker: {
|
|
199
|
+
label: {
|
|
200
|
+
select: string;
|
|
201
|
+
cancel: string;
|
|
202
|
+
};
|
|
203
|
+
ariaLabel: {
|
|
204
|
+
colorPicker: string;
|
|
205
|
+
next: string;
|
|
206
|
+
back: string;
|
|
207
|
+
select: string;
|
|
208
|
+
cancel: string;
|
|
209
|
+
hexCodeInput: string;
|
|
210
|
+
palette: string;
|
|
211
|
+
};
|
|
212
|
+
defaultColor: string;
|
|
213
|
+
ariaDescription: string;
|
|
214
|
+
ariaDescribedById: string;
|
|
215
|
+
paletteColors: {
|
|
216
|
+
name: string;
|
|
217
|
+
hexCode: string;
|
|
218
|
+
}[];
|
|
219
|
+
};
|
|
220
|
+
fileUpload: {
|
|
221
|
+
label: {
|
|
222
|
+
fileUpload: string;
|
|
223
|
+
allowedFileSize1: string;
|
|
224
|
+
allowedFileSize2: string;
|
|
225
|
+
allowedFileFormat: string;
|
|
226
|
+
browseFiles: string;
|
|
227
|
+
uploadProgress: string;
|
|
228
|
+
upload: string;
|
|
229
|
+
mb: string;
|
|
230
|
+
uploadFor: string;
|
|
231
|
+
uploadErrorMsg: string;
|
|
232
|
+
of: string;
|
|
233
|
+
filesUploaded: string;
|
|
234
|
+
fileAlreadyExists: string;
|
|
235
|
+
};
|
|
236
|
+
ariaLabel: {
|
|
237
|
+
fileUpload: string;
|
|
238
|
+
browseFiles: string;
|
|
239
|
+
fileUploadIcon: string;
|
|
240
|
+
removeFileIcon: string;
|
|
241
|
+
deleteFileIcon: string;
|
|
242
|
+
fileDownload: string;
|
|
243
|
+
fileUploadInput: string;
|
|
244
|
+
};
|
|
245
|
+
iconUrl: {
|
|
246
|
+
fileUploadIcon: string;
|
|
247
|
+
fileRemoveIcon: string;
|
|
248
|
+
deleteIcon: string;
|
|
249
|
+
};
|
|
250
|
+
buttons: {
|
|
251
|
+
id: number;
|
|
252
|
+
ariaLabel: string;
|
|
253
|
+
iconURL: string;
|
|
254
|
+
toolTip: string;
|
|
255
|
+
disabled: boolean;
|
|
256
|
+
}[];
|
|
257
|
+
message: {
|
|
258
|
+
error: {
|
|
259
|
+
errorReadingFile: string;
|
|
260
|
+
invalidFileFormat: string;
|
|
261
|
+
invalidFileSize: string;
|
|
262
|
+
"2026": string;
|
|
263
|
+
"2059": string;
|
|
264
|
+
"2060": string;
|
|
265
|
+
"2061": string;
|
|
266
|
+
"2062": string;
|
|
267
|
+
"2063": string;
|
|
268
|
+
"2064": string;
|
|
269
|
+
};
|
|
270
|
+
};
|
|
271
|
+
limit: {
|
|
272
|
+
maxFileUpload: number;
|
|
273
|
+
};
|
|
274
|
+
};
|
|
275
|
+
list: {
|
|
276
|
+
defaultIndentation: number;
|
|
277
|
+
};
|
|
278
|
+
search: {
|
|
279
|
+
searchIcon: string;
|
|
280
|
+
};
|
|
281
|
+
richTextEditor: {
|
|
282
|
+
label: {
|
|
283
|
+
editor: string;
|
|
284
|
+
};
|
|
285
|
+
ariaLabel: {
|
|
286
|
+
editor: string;
|
|
287
|
+
colorPicker: string;
|
|
288
|
+
};
|
|
289
|
+
};
|
|
290
|
+
fileDownload: {
|
|
291
|
+
buttons: {
|
|
292
|
+
id: number;
|
|
293
|
+
ariaLabel: string;
|
|
294
|
+
iconURL: string;
|
|
295
|
+
toolTip: string;
|
|
296
|
+
disabled: boolean;
|
|
297
|
+
}[];
|
|
298
|
+
preSignedDuration: string;
|
|
299
|
+
message: {
|
|
300
|
+
errors: {
|
|
301
|
+
errorReadingFile: string;
|
|
302
|
+
};
|
|
303
|
+
};
|
|
304
|
+
};
|
|
305
|
+
};
|
|
306
|
+
destroy$: Subject<boolean>;
|
|
307
|
+
preSignedUrl: string;
|
|
308
|
+
fileName: string;
|
|
309
|
+
downloadFiles: File | FileList | any | DownloadFile[];
|
|
310
|
+
fileDownloadConfig: FileDownloadConfig;
|
|
311
|
+
isPublicAPI?: boolean;
|
|
312
|
+
domainUrl?: string;
|
|
313
|
+
downloadSelectedFile: EventEmitter<File | DownloadFile>;
|
|
314
|
+
deleteSelectedFile: EventEmitter<File | DownloadFile>;
|
|
315
|
+
fileDeleteBtn: {
|
|
316
|
+
id: number;
|
|
317
|
+
ariaLabel: string;
|
|
318
|
+
iconURL: string;
|
|
319
|
+
toolTip: string;
|
|
320
|
+
disabled: boolean;
|
|
321
|
+
};
|
|
322
|
+
constructor(formUtilityService: FormUtilityService, sharedService: SharedService, fileUploadService: FileUploadService);
|
|
323
|
+
/**
|
|
324
|
+
* Gets the download AWS pre-signed URL from API on button click or emit the downloadSelectedFile if isNotDownloadFileInternally flg is true.
|
|
325
|
+
* @param {File } file
|
|
326
|
+
* @memberof FileDownloadedComponent
|
|
327
|
+
*/
|
|
328
|
+
onDownloadFile(file: File | DownloadFile): void;
|
|
329
|
+
/**
|
|
330
|
+
* Retrieves pre-signed URL for downloading the selected file from Amazon S3 bucket.
|
|
331
|
+
* @memberof FileDownloadedComponent
|
|
332
|
+
*/
|
|
333
|
+
getFileDownloadPresignedUrls(file: File | DownloadFile): void;
|
|
334
|
+
/**
|
|
335
|
+
* Removes the selected file from the downloaded files list.
|
|
336
|
+
* @param {number} index
|
|
337
|
+
* @param {File } file
|
|
338
|
+
* @memberof FileDownloadedComponent
|
|
339
|
+
*/
|
|
340
|
+
onDeleteFile(file: File | DownloadFile, index: number): void;
|
|
341
|
+
/**
|
|
342
|
+
* Returns unique identifier for the file list.
|
|
343
|
+
* @param {number} index
|
|
344
|
+
* @return {(number | string)}
|
|
345
|
+
* @memberof FileDownloadComponent
|
|
346
|
+
*/
|
|
347
|
+
trackByFn(index: number): number | string;
|
|
348
|
+
/**
|
|
349
|
+
* Cleans up resources when the component is destroyed.
|
|
350
|
+
* @memberof FileDownloadComponent
|
|
351
|
+
*/
|
|
352
|
+
ngOnDestroy(): void;
|
|
353
|
+
/**
|
|
354
|
+
* Download the file using generated presigned Url.
|
|
355
|
+
* @param {string} fileDownloadPresignedUrl
|
|
356
|
+
* @param {string} fileName
|
|
357
|
+
* @memberof FileDownloadComponent
|
|
358
|
+
*/
|
|
359
|
+
downloadFileFromPresignedUrl(fileDownloadPresignedUrl: string, fileName: string): void;
|
|
360
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FileDownloadComponent, never>;
|
|
361
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FileDownloadComponent, "ieeesa-file-download", never, { "downloadFiles": { "alias": "downloadFiles"; "required": false; }; "fileDownloadConfig": { "alias": "fileDownloadConfig"; "required": false; }; "isPublicAPI": { "alias": "isPublicAPI"; "required": false; }; "domainUrl": { "alias": "domainUrl"; "required": false; }; }, { "downloadSelectedFile": "downloadSelectedFile"; "deleteSelectedFile": "deleteSelectedFile"; }, never, never, true, never>;
|
|
362
|
+
}
|
|
@@ -7,6 +7,8 @@ import { FileUploadService } from '../../services/file-upload.service';
|
|
|
7
7
|
import { ViewFilesFormat } from '../../models/view-files-format.model';
|
|
8
8
|
import { AlignType } from '../../models/align-type.model';
|
|
9
9
|
import { FileUploadStatus } from '../../models/file-upload-status.model';
|
|
10
|
+
import { FileDownloadConfig } from '../../models/file-download-config.model';
|
|
11
|
+
import { DownloadFile } from '@presentation/models/download-file.model';
|
|
10
12
|
import * as i0 from "@angular/core";
|
|
11
13
|
/**
|
|
12
14
|
* Provides functionality for uploading files to aws s3 bucket.
|
|
@@ -212,16 +214,15 @@ export declare class FileUploadComponent implements OnInit {
|
|
|
212
214
|
colorPicker: string;
|
|
213
215
|
next: string;
|
|
214
216
|
back: string;
|
|
217
|
+
/**
|
|
218
|
+
* Formats allowed file format and size message in required format.
|
|
219
|
+
* @memberof FileUploadComponent
|
|
220
|
+
*/
|
|
215
221
|
select: string;
|
|
216
222
|
cancel: string;
|
|
217
223
|
hexCodeInput: string;
|
|
218
224
|
palette: string;
|
|
219
225
|
};
|
|
220
|
-
/**
|
|
221
|
-
* Handles the selected file(s) and emits FileUpload event emitter for uploading the file(s).
|
|
222
|
-
* @param {(File | FileList)} file
|
|
223
|
-
* @memberof FileUploadComponent
|
|
224
|
-
*/
|
|
225
226
|
defaultColor: string;
|
|
226
227
|
ariaDescription: string;
|
|
227
228
|
ariaDescribedById: string;
|
|
@@ -300,6 +301,21 @@ export declare class FileUploadComponent implements OnInit {
|
|
|
300
301
|
colorPicker: string;
|
|
301
302
|
};
|
|
302
303
|
};
|
|
304
|
+
fileDownload: {
|
|
305
|
+
buttons: {
|
|
306
|
+
id: number;
|
|
307
|
+
ariaLabel: string;
|
|
308
|
+
iconURL: string;
|
|
309
|
+
toolTip: string;
|
|
310
|
+
disabled: boolean;
|
|
311
|
+
}[];
|
|
312
|
+
preSignedDuration: string;
|
|
313
|
+
message: {
|
|
314
|
+
errors: {
|
|
315
|
+
errorReadingFile: string;
|
|
316
|
+
};
|
|
317
|
+
};
|
|
318
|
+
};
|
|
303
319
|
};
|
|
304
320
|
fileUploadLabel: {
|
|
305
321
|
fileUpload: string;
|
|
@@ -373,8 +389,11 @@ export declare class FileUploadComponent implements OnInit {
|
|
|
373
389
|
set fileUploadStatus(value: FileUploadStatus);
|
|
374
390
|
get uploadedSize(): number;
|
|
375
391
|
set uploadedSize(value: number);
|
|
376
|
-
|
|
377
|
-
|
|
392
|
+
_fileDownloadConfig: FileDownloadConfig;
|
|
393
|
+
set fileDownloadConfig(value: FileDownloadConfig);
|
|
394
|
+
get fileDownloadConfig(): FileDownloadConfig;
|
|
395
|
+
uploadSelectedFiles: EventEmitter<File | FileList>;
|
|
396
|
+
downloadSelectedFile: EventEmitter<File | DownloadFile>;
|
|
378
397
|
constructor(formUtilityService: FormUtilityService, fileUploadService: FileUploadService);
|
|
379
398
|
/**
|
|
380
399
|
* Initializes component properties and retrieves configuration.
|
|
@@ -424,7 +443,7 @@ export declare class FileUploadComponent implements OnInit {
|
|
|
424
443
|
* Emits file download event emitter.
|
|
425
444
|
* @memberof FileUploadComponent
|
|
426
445
|
*/
|
|
427
|
-
downloadFile(): void;
|
|
446
|
+
downloadFile(file: File | DownloadFile): void;
|
|
428
447
|
/**
|
|
429
448
|
* Returns unique identifier for the file list.
|
|
430
449
|
* @param {number} index
|
|
@@ -455,6 +474,11 @@ export declare class FileUploadComponent implements OnInit {
|
|
|
455
474
|
* @memberof FileUploadComponent
|
|
456
475
|
*/
|
|
457
476
|
disableUploadButton(): void;
|
|
477
|
+
/**
|
|
478
|
+
* Based on isMultiFileUpload flag return files to download.
|
|
479
|
+
* @memberof FileUploadComponent
|
|
480
|
+
*/
|
|
481
|
+
getFilesToDownload(): DownloadFile[];
|
|
458
482
|
static ɵfac: i0.ɵɵFactoryDeclaration<FileUploadComponent, never>;
|
|
459
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<FileUploadComponent, "ieeesa-file-upload", never, { "maxFileSizeErrorMessage": { "alias": "maxFileSizeErrorMessage"; "required": false; }; "actionButtonAlign": { "alias": "actionButtonAlign"; "required": false; }; "formControlName": { "alias": "formControlName"; "required": false; }; "isFileSelected": { "alias": "isFileSelected"; "required": false; }; "supportMessage": { "alias": "supportMessage"; "required": false; }; "allowedFileTypes": { "alias": "allowedFileTypes"; "required": false; }; "isMultiFileUpload": { "alias": "isMultiFileUpload"; "required": false; }; "isUploadInProgress": { "alias": "isUploadInProgress"; "required": false; }; "fileUploadHeading": { "alias": "fileUploadHeading"; "required": false; }; "isAllowAnyFileType": { "alias": "isAllowAnyFileType"; "required": false; }; "viewFilesFormat": { "alias": "viewFilesFormat"; "required": false; }; "isUploadButtonNeeded": { "alias": "isUploadButtonNeeded"; "required": false; }; "maxUploadFileSize": { "alias": "maxUploadFileSize"; "required": false; }; "fileUploadErrorPosition": { "alias": "fileUploadErrorPosition"; "required": false; }; "maxFilesUploadLimit": { "alias": "maxFilesUploadLimit"; "required": false; }; "maxFilesUploadLimitErrorMessage": { "alias": "maxFilesUploadLimitErrorMessage"; "required": false; }; "fileUploadStatus": { "alias": "fileUploadStatus"; "required": false; }; "uploadedSize": { "alias": "uploadedSize"; "required": false; }; }, { "uploadSelectedFiles": "uploadSelectedFiles"; "downloadSelectedFile": "downloadSelectedFile"; }, never, never, true, never>;
|
|
483
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FileUploadComponent, "ieeesa-file-upload", never, { "maxFileSizeErrorMessage": { "alias": "maxFileSizeErrorMessage"; "required": false; }; "actionButtonAlign": { "alias": "actionButtonAlign"; "required": false; }; "formControlName": { "alias": "formControlName"; "required": false; }; "isFileSelected": { "alias": "isFileSelected"; "required": false; }; "supportMessage": { "alias": "supportMessage"; "required": false; }; "allowedFileTypes": { "alias": "allowedFileTypes"; "required": false; }; "isMultiFileUpload": { "alias": "isMultiFileUpload"; "required": false; }; "isUploadInProgress": { "alias": "isUploadInProgress"; "required": false; }; "fileUploadHeading": { "alias": "fileUploadHeading"; "required": false; }; "isAllowAnyFileType": { "alias": "isAllowAnyFileType"; "required": false; }; "viewFilesFormat": { "alias": "viewFilesFormat"; "required": false; }; "isUploadButtonNeeded": { "alias": "isUploadButtonNeeded"; "required": false; }; "maxUploadFileSize": { "alias": "maxUploadFileSize"; "required": false; }; "fileUploadErrorPosition": { "alias": "fileUploadErrorPosition"; "required": false; }; "maxFilesUploadLimit": { "alias": "maxFilesUploadLimit"; "required": false; }; "maxFilesUploadLimitErrorMessage": { "alias": "maxFilesUploadLimitErrorMessage"; "required": false; }; "fileUploadStatus": { "alias": "fileUploadStatus"; "required": false; }; "uploadedSize": { "alias": "uploadedSize"; "required": false; }; "fileDownloadConfig": { "alias": "fileDownloadConfig"; "required": false; }; }, { "uploadSelectedFiles": "uploadSelectedFiles"; "downloadSelectedFile": "downloadSelectedFile"; }, never, never, true, never>;
|
|
460
484
|
}
|
|
@@ -2,6 +2,8 @@ import { ElementRef, EventEmitter, OnDestroy } from '@angular/core';
|
|
|
2
2
|
import { ListHeader, ListItem } from '../../models/list-item.model';
|
|
3
3
|
import { Menu } from '../../models/menu.model';
|
|
4
4
|
import { IconButton } from '../../models/icon-button.model';
|
|
5
|
+
import { FileDownloadConfig } from '../../models/file-download-config.model';
|
|
6
|
+
import { DownloadFile } from '../../models/download-file.model';
|
|
5
7
|
import * as i0 from "@angular/core";
|
|
6
8
|
export declare class ListComponent implements OnDestroy {
|
|
7
9
|
elementRef: ElementRef;
|
|
@@ -17,6 +19,7 @@ export declare class ListComponent implements OnDestroy {
|
|
|
17
19
|
set listHeaderConfig(listHeaderDetail: ListHeader);
|
|
18
20
|
get listHeaderConfig(): ListHeader;
|
|
19
21
|
hyperLinkAndButtonClick: EventEmitter<Event>;
|
|
22
|
+
downloadSelectedFile: EventEmitter<File | DownloadFile>;
|
|
20
23
|
constants: any;
|
|
21
24
|
indentation: any;
|
|
22
25
|
addListButton: IconButton;
|
|
@@ -24,6 +27,9 @@ export declare class ListComponent implements OnDestroy {
|
|
|
24
27
|
set addListButtonConfig(addListButton: IconButton);
|
|
25
28
|
get addListButtonConfig(): IconButton;
|
|
26
29
|
domChangeEvent: EventEmitter<MutationRecord>;
|
|
30
|
+
_fileDownloadConfig: FileDownloadConfig;
|
|
31
|
+
set fileDownloadConfig(value: FileDownloadConfig);
|
|
32
|
+
get fileDownloadConfig(): FileDownloadConfig;
|
|
27
33
|
constructor(elementRef: ElementRef);
|
|
28
34
|
/**
|
|
29
35
|
* Emits hyperLinkAndButtonClick event on click of hyper link.
|
|
@@ -64,11 +70,16 @@ export declare class ListComponent implements OnDestroy {
|
|
|
64
70
|
* @memberof ListComponent
|
|
65
71
|
*/
|
|
66
72
|
onDomChange(event: MutationRecord): void;
|
|
73
|
+
/**
|
|
74
|
+
* Emits file download event emitter.
|
|
75
|
+
* @memberof ListComponent
|
|
76
|
+
*/
|
|
77
|
+
downloadFile(file: File | DownloadFile): void;
|
|
67
78
|
/**
|
|
68
79
|
* Removing the event listeners on destroy.
|
|
69
80
|
* @memberof ListComponent
|
|
70
81
|
*/
|
|
71
82
|
ngOnDestroy(): void;
|
|
72
83
|
static ɵfac: i0.ɵɵFactoryDeclaration<ListComponent, never>;
|
|
73
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ListComponent, "ieeesa-list", never, { "listDataItems": { "alias": "listDataItems"; "required": false; }; "listHeaderConfig": { "alias": "listHeaderConfig"; "required": false; }; "indentation": { "alias": "indentation"; "required": false; }; "addListButtonConfig": { "alias": "addListButtonConfig"; "required": false; }; }, { "selectedItemAndAction": "selectedItemAndAction"; "reorderedList": "reorderedList"; "hyperLinkAndButtonClick": "hyperLinkAndButtonClick"; "domChangeEvent": "domChangeEvent"; }, never, never, true, never>;
|
|
84
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ListComponent, "ieeesa-list", never, { "listDataItems": { "alias": "listDataItems"; "required": false; }; "listHeaderConfig": { "alias": "listHeaderConfig"; "required": false; }; "indentation": { "alias": "indentation"; "required": false; }; "addListButtonConfig": { "alias": "addListButtonConfig"; "required": false; }; "fileDownloadConfig": { "alias": "fileDownloadConfig"; "required": false; }; }, { "selectedItemAndAction": "selectedItemAndAction"; "reorderedList": "reorderedList"; "hyperLinkAndButtonClick": "hyperLinkAndButtonClick"; "downloadSelectedFile": "downloadSelectedFile"; "domChangeEvent": "domChangeEvent"; }, never, never, true, never>;
|
|
74
85
|
}
|
|
@@ -13,6 +13,7 @@ import { RadioOption } from '../../models/radio-option.model';
|
|
|
13
13
|
import { IconButton } from '../../models/icon-button.model';
|
|
14
14
|
import { AutoCompleteOption } from '../../models/autocomplete-option.model';
|
|
15
15
|
import { FileUploadStatus } from '../../models/file-upload-status.model';
|
|
16
|
+
import { FileDownloadConfig } from '../../models/file-download-config.model';
|
|
16
17
|
import * as i0 from "@angular/core";
|
|
17
18
|
/**
|
|
18
19
|
* Provides the implementation of DynamicFormFieldDirective which hosts and creates the form fields components dynamically.
|
|
@@ -42,6 +43,9 @@ export declare class DynamicFormFieldDirective implements FormField, OnInit, OnD
|
|
|
42
43
|
private _fileUploadStatus;
|
|
43
44
|
get fileUploadStatus(): FileUploadStatus;
|
|
44
45
|
set fileUploadStatus(value: FileUploadStatus);
|
|
46
|
+
_fileDownloadConfig: FileDownloadConfig;
|
|
47
|
+
set fileDownloadConfig(value: FileDownloadConfig);
|
|
48
|
+
get fileDownloadConfig(): FileDownloadConfig;
|
|
45
49
|
private _submitResponse;
|
|
46
50
|
/**
|
|
47
51
|
* Sets the submit response of form submit event
|
|
@@ -78,7 +82,7 @@ export declare class DynamicFormFieldDirective implements FormField, OnInit, OnD
|
|
|
78
82
|
formSlideToggleChange: EventEmitter<SlideToggleOption>;
|
|
79
83
|
dropdownOpenedChange: EventEmitter<SelectOpenedState>;
|
|
80
84
|
formColorPickerChange: EventEmitter<string>;
|
|
81
|
-
formFileUpload: EventEmitter<
|
|
85
|
+
formFileUpload: EventEmitter<File | FileList>;
|
|
82
86
|
formRadioOptionSelected: EventEmitter<RadioOption>;
|
|
83
87
|
ctaButtonClick: EventEmitter<IconButton>;
|
|
84
88
|
formMultiSelectAutoCompleteSearch: EventEmitter<string>;
|
|
@@ -103,5 +107,5 @@ export declare class DynamicFormFieldDirective implements FormField, OnInit, OnD
|
|
|
103
107
|
*/
|
|
104
108
|
ngOnDestroy(): void;
|
|
105
109
|
static ɵfac: i0.ɵɵFactoryDeclaration<DynamicFormFieldDirective, never>;
|
|
106
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<DynamicFormFieldDirective, "[ieeesaDynamicFormField]", never, { "config": { "alias": "config"; "required": false; }; "group": { "alias": "group"; "required": false; }; "fileUploadStatus": { "alias": "fileUploadStatus"; "required": false; }; "submitResponse": { "alias": "submitResponse"; "required": false; }; "searchResponse": { "alias": "searchResponse"; "required": false; }; }, { "formSearchApply": "formSearchApply"; "formDropdownSelected": "formDropdownSelected"; "formDateSelected": "formDateSelected"; "formTimeSelected": "formTimeSelected"; "formSelectedDateRange": "formSelectedDateRange"; "formSelectSearch": "formSelectSearch"; "formAutoCompleteSearch": "formAutoCompleteSearch"; "autoCompleteClearSearchValue": "autoCompleteClearSearchValue"; "autoCompleteOptionSelected": "autoCompleteOptionSelected"; "formCheckboxSelection": "formCheckboxSelection"; "formInputValue": "formInputValue"; "addFormGroup": "addFormGroup"; "supportTextLinkClick": "supportTextLinkClick"; "formSlideToggleChange": "formSlideToggleChange"; "dropdownOpenedChange": "dropdownOpenedChange"; "formColorPickerChange": "formColorPickerChange"; "formFileUpload": "formFileUpload"; "formRadioOptionSelected": "formRadioOptionSelected"; "ctaButtonClick": "ctaButtonClick"; "formMultiSelectAutoCompleteSearch": "formMultiSelectAutoCompleteSearch"; "multiSelectAutoCompleteClearSearchValue": "multiSelectAutoCompleteClearSearchValue"; "multiSelectAutoCompleteOptionsSelected": "multiSelectAutoCompleteOptionsSelected"; "formRichTextEditorContentChange": "formRichTextEditorContentChange"; }, never, never, true, never>;
|
|
110
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<DynamicFormFieldDirective, "[ieeesaDynamicFormField]", never, { "config": { "alias": "config"; "required": false; }; "group": { "alias": "group"; "required": false; }; "fileUploadStatus": { "alias": "fileUploadStatus"; "required": false; }; "fileDownloadConfig": { "alias": "fileDownloadConfig"; "required": false; }; "submitResponse": { "alias": "submitResponse"; "required": false; }; "searchResponse": { "alias": "searchResponse"; "required": false; }; }, { "formSearchApply": "formSearchApply"; "formDropdownSelected": "formDropdownSelected"; "formDateSelected": "formDateSelected"; "formTimeSelected": "formTimeSelected"; "formSelectedDateRange": "formSelectedDateRange"; "formSelectSearch": "formSelectSearch"; "formAutoCompleteSearch": "formAutoCompleteSearch"; "autoCompleteClearSearchValue": "autoCompleteClearSearchValue"; "autoCompleteOptionSelected": "autoCompleteOptionSelected"; "formCheckboxSelection": "formCheckboxSelection"; "formInputValue": "formInputValue"; "addFormGroup": "addFormGroup"; "supportTextLinkClick": "supportTextLinkClick"; "formSlideToggleChange": "formSlideToggleChange"; "dropdownOpenedChange": "dropdownOpenedChange"; "formColorPickerChange": "formColorPickerChange"; "formFileUpload": "formFileUpload"; "formRadioOptionSelected": "formRadioOptionSelected"; "ctaButtonClick": "ctaButtonClick"; "formMultiSelectAutoCompleteSearch": "formMultiSelectAutoCompleteSearch"; "multiSelectAutoCompleteClearSearchValue": "multiSelectAutoCompleteClearSearchValue"; "multiSelectAutoCompleteOptionsSelected": "multiSelectAutoCompleteOptionsSelected"; "formRichTextEditorContentChange": "formRichTextEditorContentChange"; }, never, never, true, never>;
|
|
107
111
|
}
|
|
@@ -8,7 +8,7 @@ import * as i0 from "@angular/core";
|
|
|
8
8
|
export declare class FileUploadDirective {
|
|
9
9
|
allowedFileTypes: string[];
|
|
10
10
|
isMultiFileUpload: boolean;
|
|
11
|
-
fileDropped: EventEmitter<
|
|
11
|
+
fileDropped: EventEmitter<File | FileList>;
|
|
12
12
|
/**
|
|
13
13
|
* Binds the 'multiple' attribute based on the value of allowMultiple property.
|
|
14
14
|
* @readonly
|
|
@@ -9,6 +9,24 @@ export interface GetFileDownloadPresignedUrlPayload {
|
|
|
9
9
|
domain: string;
|
|
10
10
|
};
|
|
11
11
|
}
|
|
12
|
+
export interface GetFileDownloadPresignedUrlByAttachmentIdPayload {
|
|
13
|
+
payload: {
|
|
14
|
+
attachmentId?: string;
|
|
15
|
+
preSignedDuration: string;
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
export interface GetFileDownloadPresignedUrlByAttachmentIdResponse {
|
|
19
|
+
status: boolean;
|
|
20
|
+
message: string;
|
|
21
|
+
body: {
|
|
22
|
+
preSignedUrl: string;
|
|
23
|
+
fileName: string;
|
|
24
|
+
s3Path?: string;
|
|
25
|
+
errorMessage?: string;
|
|
26
|
+
} | null | {
|
|
27
|
+
errorCodes: string[];
|
|
28
|
+
};
|
|
29
|
+
}
|
|
12
30
|
export interface GetFileUploadPresignedUrlPayload {
|
|
13
31
|
payload: {
|
|
14
32
|
fileName: string;
|