@ieeesa-npm/presentation 0.27.6 → 0.27.7

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.
Files changed (27) hide show
  1. package/esm2022/lib/components/file-download/file-download.component.mjs +1 -1
  2. package/esm2022/lib/components/file-upload/file-upload.component.mjs +5 -5
  3. package/esm2022/lib/components/list/list.component.mjs +1 -1
  4. package/esm2022/lib/directives/dynamic-form-field/dynamic-form-field.directive.mjs +1 -1
  5. package/esm2022/lib/models/download-file.model.mjs +1 -1
  6. package/esm2022/lib/models/file-upload-payload-model.mjs +1 -1
  7. package/esm2022/lib/models/file-upload-response.model.mjs +1 -1
  8. package/esm2022/lib/models/file-upload-status.model.mjs +1 -1
  9. package/esm2022/lib/models/list-item.model.mjs +1 -1
  10. package/esm2022/lib/services/file-upload.service.mjs +17 -17
  11. package/esm2022/public-api.mjs +1 -2
  12. package/fesm2022/ieeesa-npm-presentation.mjs +20 -20
  13. package/fesm2022/ieeesa-npm-presentation.mjs.map +1 -1
  14. package/lib/components/dynamic-form/dynamic-form.component.d.ts +1 -1
  15. package/lib/components/file-download/file-download.component.d.ts +14 -19
  16. package/lib/components/file-upload/file-upload.component.d.ts +19 -15
  17. package/lib/components/list/list.component.d.ts +3 -3
  18. package/lib/directives/dynamic-form-field/dynamic-form-field.directive.d.ts +1 -1
  19. package/lib/directives/file-upload/file-upload.directive.d.ts +1 -1
  20. package/lib/models/download-file.model.d.ts +1 -1
  21. package/lib/models/file-upload-payload-model.d.ts +8 -1
  22. package/lib/models/file-upload-response.model.d.ts +3 -3
  23. package/lib/models/file-upload-status.model.d.ts +3 -3
  24. package/lib/models/list-item.model.d.ts +2 -2
  25. package/lib/services/file-upload.service.d.ts +12 -25
  26. package/package.json +1 -1
  27. package/public-api.d.ts +0 -1
@@ -91,7 +91,7 @@ export declare class DynamicFormComponent implements OnInit, AfterContentInit, A
91
91
  formTimeSelected: EventEmitter<SelectedTime>;
92
92
  supportTextLinkClick: EventEmitter<LinkEventEmitType>;
93
93
  formSlideToggleChange: EventEmitter<SlideToggleOption>;
94
- formFileUpload: EventEmitter<FileList | File>;
94
+ formFileUpload: EventEmitter<File | FileList>;
95
95
  dropdownOpenedChange: EventEmitter<SelectOpenedState>;
96
96
  formColorPickerChange: EventEmitter<string>;
97
97
  formRadioOptionSelected: EventEmitter<RadioOption>;
@@ -2,7 +2,7 @@ import { EventEmitter, OnDestroy, OnInit } from '@angular/core';
2
2
  import { FormUtilityService } from '../../services/form-utility.service';
3
3
  import { FileUploadService } from '../../services/file-upload.service';
4
4
  import { FileDownloadConfig } from '../../models/file-download-config.model';
5
- import { DownloadFile } from '../../models/download-file.model';
5
+ import { DownloadAttachment } from '../../models/download-file.model';
6
6
  import { Subject } from 'rxjs';
7
7
  import { SharedService } from '@ieeesa-npm/shared';
8
8
  import * as i0 from "@angular/core";
@@ -134,14 +134,13 @@ export declare class FileDownloadComponent implements OnInit, OnDestroy {
134
134
  helpLink: string;
135
135
  hamburgerMenu: string;
136
136
  };
137
- /**
138
- * Removes the selected file from the downloaded files list.
139
- * @param {number} index
140
- * @param {File } file
141
- * @memberof FileDownloadedComponent
142
- */
143
137
  label: {
144
- signOut: string;
138
+ signOut: string; /**
139
+ * Removes the selected file from the downloaded files list.
140
+ * @param {number} index
141
+ * @param {File } file
142
+ * @memberof FileDownloadedComponent
143
+ */
145
144
  };
146
145
  buttons: {
147
146
  id: number;
@@ -154,11 +153,7 @@ export declare class FileDownloadComponent implements OnInit, OnDestroy {
154
153
  iconURL: string;
155
154
  label: string;
156
155
  ariaLabel: string;
157
- toolTip: string; /**
158
- * Deletes file by given agendaAttachmentId
159
- * @param {string} agendaAttachmentId
160
- * @memberof UploadAttachmentsComponent
161
- */
156
+ toolTip: string;
162
157
  isToolTipNeeded: boolean;
163
158
  }[];
164
159
  errors: {
@@ -319,12 +314,12 @@ export declare class FileDownloadComponent implements OnInit, OnDestroy {
319
314
  destroy$: Subject<boolean>;
320
315
  preSignedUrl: string;
321
316
  fileName: string;
322
- downloadFiles: File | FileList | any | DownloadFile[];
317
+ downloadFiles: File | FileList | any | DownloadAttachment[];
323
318
  fileDownloadConfig: FileDownloadConfig;
324
319
  isPublicAPI?: boolean;
325
320
  domainUrl?: string;
326
- downloadSelectedFile: EventEmitter<File | DownloadFile>;
327
- deleteSelectedFile: EventEmitter<File | DownloadFile>;
321
+ downloadSelectedFile: EventEmitter<File | DownloadAttachment>;
322
+ deleteSelectedFile: EventEmitter<File | DownloadAttachment>;
328
323
  fileDeleteBtn: {
329
324
  id: number;
330
325
  ariaLabel: string;
@@ -344,19 +339,19 @@ export declare class FileDownloadComponent implements OnInit, OnDestroy {
344
339
  * @param {File } file
345
340
  * @memberof FileDownloadedComponent
346
341
  */
347
- onDownloadFile(file: File | DownloadFile): void;
342
+ onDownloadFile(file: File | DownloadAttachment): void;
348
343
  /**
349
344
  * Retrieves pre-signed URL for downloading the selected file from Amazon S3 bucket.
350
345
  * @memberof FileDownloadedComponent
351
346
  */
352
- getFileDownloadPresignedUrls(file: File | DownloadFile): void;
347
+ getFileDownloadPresignedUrls(file: File | DownloadAttachment): void;
353
348
  /**
354
349
  * Removes the selected file from the downloaded files list.
355
350
  * @param {number} index
356
351
  * @param {File } file
357
352
  * @memberof FileDownloadedComponent
358
353
  */
359
- onDeleteFile(file: File | DownloadFile, index: number): void;
354
+ onDeleteFile(file: File | DownloadAttachment, index: number): void;
360
355
  /**
361
356
  * Deletes file by given agendaAttachmentId
362
357
  * @param {string} agendaAttachmentId
@@ -8,7 +8,7 @@ import { AlignBrowsedFiles } from '../../models/align-browsed-files.model';
8
8
  import { AlignType } from '../../models/align-type.model';
9
9
  import { FileUploadStatus } from '../../models/file-upload-status.model';
10
10
  import { FileDownloadConfig } from '../../models/file-download-config.model';
11
- import { DownloadFile } from '../../models/download-file.model';
11
+ import { DownloadAttachment } from '../../models/download-file.model';
12
12
  import * as i0 from "@angular/core";
13
13
  /**
14
14
  * Provides functionality for uploading files to aws s3 bucket.
@@ -234,22 +234,18 @@ export declare class FileUploadComponent implements OnInit {
234
234
  allowedFileSize2: string;
235
235
  allowedFileFormat: string;
236
236
  browseFiles: string;
237
- /**
238
- * Triggers and opens the file browse window when the Browse button is clicked.
239
- * @memberof FileUploadComponent
240
- */
241
237
  uploadProgress: string;
242
238
  upload: string;
243
239
  mb: string;
244
240
  uploadFor: string;
245
241
  uploadErrorMsg: string;
242
+ of: string;
246
243
  /**
247
244
  * Returns the failed file names with comma separation.
248
245
  * @param {string[]} fileNames
249
246
  * @return {*} {string}
250
247
  * @memberof FileUploadComponent
251
248
  */
252
- of: string;
253
249
  filesUploaded: string;
254
250
  fileAlreadyExists: string;
255
251
  };
@@ -280,6 +276,11 @@ export declare class FileUploadComponent implements OnInit {
280
276
  invalidFileFormat: string;
281
277
  invalidFileSize: string;
282
278
  "2026": string;
279
+ /**
280
+ * Enables or disables the file upload button.
281
+ * @param {boolean} enable
282
+ * @memberof FileUploadComponent
283
+ */
283
284
  "2059": string;
284
285
  "2060": string;
285
286
  "2061": string;
@@ -298,6 +299,13 @@ export declare class FileUploadComponent implements OnInit {
298
299
  search: {
299
300
  searchIcon: string;
300
301
  };
302
+ /**
303
+ * TrackByFunction is called for each file in the collection and return a unique identifier for that file.
304
+ * @param {number} index
305
+ * @param {File} file
306
+ * @return {File}
307
+ * @memberof FileUploadComponent
308
+ */
301
309
  richTextEditor: {
302
310
  label: {
303
311
  editor: string;
@@ -332,22 +340,18 @@ export declare class FileUploadComponent implements OnInit {
332
340
  allowedFileSize2: string;
333
341
  allowedFileFormat: string;
334
342
  browseFiles: string;
335
- /**
336
- * Triggers and opens the file browse window when the Browse button is clicked.
337
- * @memberof FileUploadComponent
338
- */
339
343
  uploadProgress: string;
340
344
  upload: string;
341
345
  mb: string;
342
346
  uploadFor: string;
343
347
  uploadErrorMsg: string;
348
+ of: string;
344
349
  /**
345
350
  * Returns the failed file names with comma separation.
346
351
  * @param {string[]} fileNames
347
352
  * @return {*} {string}
348
353
  * @memberof FileUploadComponent
349
354
  */
350
- of: string;
351
355
  filesUploaded: string;
352
356
  fileAlreadyExists: string;
353
357
  };
@@ -411,8 +415,8 @@ export declare class FileUploadComponent implements OnInit {
411
415
  _fileDownloadConfig: FileDownloadConfig;
412
416
  set fileDownloadConfig(value: FileDownloadConfig);
413
417
  get fileDownloadConfig(): FileDownloadConfig;
414
- uploadSelectedFiles: EventEmitter<FileList | File>;
415
- downloadSelectedFile: EventEmitter<File | DownloadFile>;
418
+ uploadSelectedFiles: EventEmitter<File | FileList>;
419
+ downloadSelectedFile: EventEmitter<File | DownloadAttachment>;
416
420
  apiBaseUrl: string;
417
421
  constructor(formUtilityService: FormUtilityService, fileUploadService: FileUploadService);
418
422
  /**
@@ -464,7 +468,7 @@ export declare class FileUploadComponent implements OnInit {
464
468
  * Emits file download event emitter.
465
469
  * @memberof FileUploadComponent
466
470
  */
467
- downloadFile(file: File | DownloadFile): void;
471
+ downloadFile(file: File | DownloadAttachment): void;
468
472
  /**
469
473
  * Returns unique identifier for the file list.
470
474
  * @param {number} index
@@ -505,7 +509,7 @@ export declare class FileUploadComponent implements OnInit {
505
509
  * Based on isMultiFileUpload flag return files to download.
506
510
  * @memberof FileUploadComponent
507
511
  */
508
- getFilesToDownload(): DownloadFile[];
512
+ getFilesToDownload(): DownloadAttachment[];
509
513
  /**
510
514
  * TrackByFunction is called for each file in the collection and return a unique identifier for that file.
511
515
  * @param {number} index
@@ -3,7 +3,7 @@ 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
5
  import { FileDownloadConfig } from '../../models/file-download-config.model';
6
- import { DownloadFile } from '../../models/download-file.model';
6
+ import { DownloadAttachment } from '../../models/download-file.model';
7
7
  import * as i0 from "@angular/core";
8
8
  export declare class ListComponent implements OnDestroy {
9
9
  elementRef: ElementRef;
@@ -19,7 +19,7 @@ export declare class ListComponent implements OnDestroy {
19
19
  set listHeaderConfig(listHeaderDetail: ListHeader);
20
20
  get listHeaderConfig(): ListHeader;
21
21
  hyperLinkAndButtonClick: EventEmitter<Event>;
22
- downloadSelectedFile: EventEmitter<File | DownloadFile>;
22
+ downloadSelectedFile: EventEmitter<File | DownloadAttachment>;
23
23
  constants: any;
24
24
  indentation: any;
25
25
  addListButton: IconButton;
@@ -74,7 +74,7 @@ export declare class ListComponent implements OnDestroy {
74
74
  * Emits file download event emitter.
75
75
  * @memberof ListComponent
76
76
  */
77
- downloadFile(file: File | DownloadFile): void;
77
+ downloadFile(file: File | DownloadAttachment): void;
78
78
  /**
79
79
  * Removing the event listeners on destroy.
80
80
  * @memberof ListComponent
@@ -82,7 +82,7 @@ export declare class DynamicFormFieldDirective implements FormField, OnInit, OnD
82
82
  formSlideToggleChange: EventEmitter<SlideToggleOption>;
83
83
  dropdownOpenedChange: EventEmitter<SelectOpenedState>;
84
84
  formColorPickerChange: EventEmitter<string>;
85
- formFileUpload: EventEmitter<FileList | File>;
85
+ formFileUpload: EventEmitter<File | FileList>;
86
86
  formRadioOptionSelected: EventEmitter<RadioOption>;
87
87
  ctaButtonClick: EventEmitter<IconButton>;
88
88
  formMultiSelectAutoCompleteSearch: EventEmitter<string>;
@@ -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<FileList | File>;
11
+ fileDropped: EventEmitter<File | FileList>;
12
12
  /**
13
13
  * Binds the 'multiple' attribute based on the value of allowMultiple property.
14
14
  * @readonly
@@ -1,4 +1,4 @@
1
- export interface DownloadFile {
1
+ export interface DownloadAttachment {
2
2
  attachmentId: string;
3
3
  fileName: string;
4
4
  }
@@ -1,3 +1,10 @@
1
+ export interface FileDetails {
2
+ meetingId: string;
3
+ agendaId: string;
4
+ agendaItemId: string;
5
+ preSignedDuration: number;
6
+ fileNameList: [];
7
+ }
1
8
  export interface FileUploadPayload {
2
- [key: string]: any;
9
+ payload: FileDetails;
3
10
  }
@@ -1,12 +1,12 @@
1
- export interface FileUploadBodyResponse {
1
+ export interface FileAttachmentInfo {
2
2
  fileName: string;
3
3
  preSignedUrl: string;
4
4
  s3Path: string;
5
5
  errorMessage?: string | null;
6
6
  }
7
- export interface FileUploadResponse {
7
+ export interface GetFileUploadPresignedUrlsResponse {
8
8
  status: boolean;
9
- body: FileUploadBodyResponse[] | {
9
+ body: FileAttachmentInfo[] | {
10
10
  errorCodes: string[];
11
11
  };
12
12
  message: string;
@@ -1,8 +1,8 @@
1
- import { DownloadFile } from './download-file.model';
1
+ import { DownloadAttachment } from './download-file.model';
2
2
  export interface FileUploadStatus {
3
3
  noOfFilesUploadedSuccessfully: number;
4
- filesNamesUploadFailed: string[];
4
+ filesNameOfUploadFailed: string[];
5
5
  alreadyExistsFiles: string[];
6
6
  isUploadingStart: boolean;
7
- uploadedFiles: DownloadFile[];
7
+ uploadedFiles: DownloadAttachment[];
8
8
  }
@@ -1,5 +1,5 @@
1
1
  import { IconButton } from '../models/icon-button.model';
2
- import { DownloadFile } from './download-file.model';
2
+ import { DownloadAttachment } from './download-file.model';
3
3
  import { Menu } from './menu.model';
4
4
  export interface ListItem {
5
5
  id: string;
@@ -14,7 +14,7 @@ export interface ListItem {
14
14
  itemLevel?: number;
15
15
  actionMenus?: Menu[];
16
16
  actionIcon?: IconButton;
17
- attachments?: DownloadFile[];
17
+ attachments?: DownloadAttachment[];
18
18
  }
19
19
  export interface ListHeader {
20
20
  title: string;
@@ -4,9 +4,9 @@ import { AlertsService, HttpService, LoaderNotificationService } from '@ieeesa-n
4
4
  import { FileUploadPresignedUrl, GetFileDownloadPresignedUrlByAttachmentIdResponse } from '../models/file-upload-presigned-url-res.model';
5
5
  import { Observable, Subject } from 'rxjs';
6
6
  import { FileUploadPayload } from '../models/file-upload-payload-model';
7
- import { FileUploadBodyResponse, FileUploadResponse } from '../models/file-upload-response.model';
7
+ import { FileAttachmentInfo, GetFileUploadPresignedUrlsResponse } from '../models/file-upload-response.model';
8
8
  import { DeleteFileResponse } from '../models/file-info.model';
9
- import { DownloadFile } from '../models/download-file.model';
9
+ import { DownloadAttachment } from '../models/download-file.model';
10
10
  import * as i0 from "@angular/core";
11
11
  /**
12
12
  * This service interacts with the server to obtain pre-signed URLs for file upload and uploads files to Amazon S3.
@@ -137,14 +137,6 @@ export declare class FileUploadService implements OnDestroy {
137
137
  alt: {
138
138
  logo: string;
139
139
  };
140
- /**
141
- * Uploads file to AWS S3 using a pre-signed URL.
142
- * @param {string} preSignedUrl
143
- * @param files
144
- * @param isMultipleFileUpload
145
- * @return {Observable<any>} -Returns an observable that emits the response after uploading the file to S3.
146
- * @memberof FileUploadService
147
- */
148
140
  ariaLabel: {
149
141
  helpLink: string;
150
142
  hamburgerMenu: string;
@@ -215,13 +207,6 @@ export declare class FileUploadService implements OnDestroy {
215
207
  select: string;
216
208
  cancel: string;
217
209
  };
218
- /**
219
- * Return distinct message for sent, upload progress, & response events.
220
- * @param {HttpEvent<any>} event
221
- * @param {(File | FileList)} file
222
- * @return {*}
223
- * @memberof FileUploadService
224
- */
225
210
  ariaLabel: {
226
211
  colorPicker: string;
227
212
  next: string;
@@ -332,7 +317,7 @@ export declare class FileUploadService implements OnDestroy {
332
317
  fileByteArray: Uint8Array | undefined;
333
318
  httpClient: HttpClient;
334
319
  isFileUploading: boolean;
335
- filesNamesUploadFailed: string[];
320
+ filesNameOfUploadFailed: string[];
336
321
  noOfFilesUploadedSuccessfully: number;
337
322
  uploadedFileName: string;
338
323
  constructor(httpService: HttpService, handler: HttpBackend, alertService: AlertsService, loaderNotificationService: LoaderNotificationService);
@@ -357,10 +342,12 @@ export declare class FileUploadService implements OnDestroy {
357
342
  getFileUploadPresignedUrl(file: File | FileList, appId: string): Observable<FileUploadPresignedUrl>;
358
343
  /**
359
344
  * Gets pre-signed URL for the files to be uploaded in S3 bucket
360
- * @param fileUploadPayload
361
- * @param fileUploadAPIPath
345
+ * @param {FileUploadPayload} fileUploadPayload
346
+ * @param {string} fileUploadAPIPath
347
+ * @return {Observable<GetFileUploadPresignedUrlsResponse>}
348
+ * @memberof FileUploadService
362
349
  */
363
- getPreSignedURL(fileUploadPayload: FileUploadPayload, fileUploadAPIPath?: string): Observable<FileUploadResponse>;
350
+ getPreSignedURL(fileUploadPayload: FileUploadPayload, fileUploadAPIPath: string): Observable<GetFileUploadPresignedUrlsResponse>;
364
351
  /**
365
352
  * Uploads file to AWS S3 using a pre-signed URL.
366
353
  * @param {string} preSignedUrl
@@ -369,7 +356,7 @@ export declare class FileUploadService implements OnDestroy {
369
356
  * @return {Observable<any>} -Returns an observable that emits the response after uploading the file to S3.
370
357
  * @memberof FileUploadService
371
358
  */
372
- uploadFileToS3(preSignedUrl: FileUploadBodyResponse[] | string, files: File | FileList, isMultipleFileUpload?: boolean): Observable<any>;
359
+ uploadFileToS3(preSignedUrl: FileAttachmentInfo[] | string, files: File | FileList, isMultipleFileUpload?: boolean): Observable<any>;
373
360
  /**
374
361
  * Makes http call to AWS to upload file in S3 bucket
375
362
  * @param {string} preSignedUrl
@@ -423,7 +410,7 @@ export declare class FileUploadService implements OnDestroy {
423
410
  * @return {Observable<string>}
424
411
  * @memberof FileUploadService
425
412
  */
426
- getFileDownloadPresignedUrls(file: File | FileList | string | DownloadFile, isPublicAPI?: boolean, domainUrl?: string, downloadUri?: string): Observable<string | GetFileDownloadPresignedUrlByAttachmentIdResponse>;
413
+ getFileDownloadPresignedUrls(file: File | FileList | string | DownloadAttachment, isPublicAPI?: boolean, domainUrl?: string, downloadUri?: string): Observable<string | GetFileDownloadPresignedUrlByAttachmentIdResponse>;
427
414
  /**
428
415
  * Downloads file to AWS S3 using a presigned URL.
429
416
  * @return {Observable<any>}
@@ -457,8 +444,8 @@ export declare class FileUploadService implements OnDestroy {
457
444
  */
458
445
  private getFileExtension;
459
446
  /**
460
- * Deletes file by given fileId
461
- * @param {string} fileId
447
+ * Delete the file from AWS S3 based on the by given fileId inside deleteFileApiPath
448
+ * @param {string} deleteFileApiPath
462
449
  * @return {*} {Observable<DeleteFileResponse>}
463
450
  * @memberof FileUploadService
464
451
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ieeesa-npm/presentation",
3
- "version": "0.27.6",
3
+ "version": "0.27.7",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^16.1.0",
6
6
  "@angular/core": "^16.1.0",
package/public-api.d.ts CHANGED
@@ -60,7 +60,6 @@ export * from './lib/models/download-file.model';
60
60
  export * from './lib/models/event-emit-type.model';
61
61
  export * from './lib/models/field-config.model';
62
62
  export * from './lib/models/file-attachment.model';
63
- export * from './lib/models/file-download-config.model';
64
63
  export * from './lib/models/footer-config.model';
65
64
  export * from './lib/models/form-control-types.model';
66
65
  export * from './lib/models/form-field.model';