@genesislcap/foundation-notifications 14.52.2 → 14.53.0

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 (35) hide show
  1. package/dist/dts/notification-builder.d.ts.map +1 -1
  2. package/dist/dts/toast/toast-builder.d.ts +17 -1
  3. package/dist/dts/toast/toast-builder.d.ts.map +1 -1
  4. package/dist/dts/toast/toast-launcher.d.ts.map +1 -1
  5. package/dist/dts/types.d.ts +40 -0
  6. package/dist/dts/types.d.ts.map +1 -1
  7. package/dist/esm/toast/toast-builder.js +26 -0
  8. package/dist/esm/toast/toast-launcher.js +29 -6
  9. package/dist/foundation-notifications.api.json +652 -11
  10. package/dist/foundation-notifications.d.ts +59 -0
  11. package/docs/api/foundation-notifications.md +3 -0
  12. package/docs/api/foundation-notifications.notificationdatarow.alert_id.md +11 -0
  13. package/docs/api/foundation-notifications.notificationdatarow.created_at.md +11 -0
  14. package/docs/api/foundation-notifications.notificationdatarow.details.md +14 -0
  15. package/docs/api/foundation-notifications.notificationdatarow.expiry.md +11 -0
  16. package/docs/api/foundation-notifications.notificationdatarow.header.md +11 -0
  17. package/docs/api/foundation-notifications.notificationdatarow.md +28 -0
  18. package/docs/api/foundation-notifications.notificationdatarow.message.md +11 -0
  19. package/docs/api/foundation-notifications.notificationdatarow.notify_severity.md +11 -0
  20. package/docs/api/foundation-notifications.notificationdatarow.sender.md +11 -0
  21. package/docs/api/foundation-notifications.notificationdatarow.user_name.md +11 -0
  22. package/docs/api/foundation-notifications.notificationseverity.md +13 -0
  23. package/docs/api/foundation-notifications.toast.buttons.md +11 -0
  24. package/docs/api/foundation-notifications.toast.details.md +11 -0
  25. package/docs/api/foundation-notifications.toast.md +2 -0
  26. package/docs/api/foundation-notifications.toastbuilder.md +2 -0
  27. package/docs/api/foundation-notifications.toastbuilder.withbuttons.md +25 -0
  28. package/docs/api/foundation-notifications.toastbuilder.withdetails.md +25 -0
  29. package/docs/api/foundation-notifications.toastbutton.action.md +25 -0
  30. package/docs/api/foundation-notifications.toastbutton.appearance.md +11 -0
  31. package/docs/api/foundation-notifications.toastbutton.condition.md +24 -0
  32. package/docs/api/foundation-notifications.toastbutton.md +28 -0
  33. package/docs/api/foundation-notifications.toastbutton.placeholder.md +11 -0
  34. package/docs/api-report.md +51 -0
  35. package/package.json +5 -5
@@ -240,6 +240,25 @@ export declare class NotificationBuilder {
240
240
  build(): NotificationStructure;
241
241
  }
242
242
 
243
+ /**
244
+ * Interface for notify data
245
+ * @public
246
+ */
247
+ export declare interface NotificationDataRow {
248
+ ALERT_ID: string;
249
+ CREATED_AT: number;
250
+ DETAILS: {
251
+ OPERATION: string;
252
+ ROW_REF: string;
253
+ };
254
+ HEADER: string;
255
+ MESSAGE: string;
256
+ NOTIFY_SEVERITY: NotificationSeverity;
257
+ EXPIRY?: null;
258
+ SENDER?: null;
259
+ USER_NAME: string;
260
+ }
261
+
243
262
  /**
244
263
  * @internal
245
264
  */
@@ -255,6 +274,12 @@ export declare enum NotificationEvent {
255
274
  NOTIFICATION_EVENT = "notification-event"
256
275
  }
257
276
 
277
+ /**
278
+ * type for notification severity
279
+ * @public
280
+ */
281
+ export declare type NotificationSeverity = 'Information' | 'Warning' | 'Serious' | 'Critical';
282
+
258
283
  /**
259
284
  * Interface for Structure
260
285
  * @public
@@ -381,6 +406,8 @@ export declare interface Toast {
381
406
  readonly type?: NotificationType;
382
407
  readonly autoClose?: boolean;
383
408
  readonly closeTimeout?: number;
409
+ readonly details?: NotificationDataRow;
410
+ readonly buttons?: ToastButton[];
384
411
  }
385
412
 
386
413
  /**
@@ -391,6 +418,8 @@ export declare class ToastBuilder {
391
418
  private autoClose;
392
419
  private closeTimeout;
393
420
  private type;
421
+ private details;
422
+ private buttons;
394
423
  /**
395
424
  * Add position to toast
396
425
  * @public
@@ -419,6 +448,20 @@ export declare class ToastBuilder {
419
448
  * @returns
420
449
  */
421
450
  withType(type: NotificationType): ToastBuilder;
451
+ /**
452
+ * Add details data to notifications
453
+ * @public
454
+ * @param details - NotificationDataRow
455
+ * @returns
456
+ */
457
+ withDetails(details: NotificationDataRow): ToastBuilder;
458
+ /**
459
+ * Add buttons to notifications
460
+ * @public
461
+ * @param buttons - ToastButton[]
462
+ * @returns
463
+ */
464
+ withButtons(buttons: ToastButton[]): ToastBuilder;
422
465
  /**
423
466
  * Build notification
424
467
  * @returns Toast
@@ -426,6 +469,22 @@ export declare class ToastBuilder {
426
469
  build(): Toast;
427
470
  }
428
471
 
472
+ /**
473
+ * Interface for ToastButton
474
+ * @public
475
+ */
476
+ export declare interface ToastButton {
477
+ action({ details, element }: {
478
+ details: NotificationDataRow;
479
+ element: HTMLElement;
480
+ }): void;
481
+ condition({ details }?: {
482
+ details: NotificationDataRow;
483
+ }): boolean;
484
+ placeholder?: string;
485
+ appearance?: string;
486
+ }
487
+
429
488
  /**
430
489
  * @public
431
490
  * type for notification position
@@ -28,9 +28,11 @@
28
28
  | [ConfirmingAction](./foundation-notifications.confirmingaction.md) | Interface for Confirming Action configuration |
29
29
  | [Dialog](./foundation-notifications.dialog.md) | Interface for Dialog configuration |
30
30
  | [DismissingAction](./foundation-notifications.dismissingaction.md) | Interface for Dismissing Action configuration |
31
+ | [NotificationDataRow](./foundation-notifications.notificationdatarow.md) | Interface for notify data |
31
32
  | [NotificationStructure](./foundation-notifications.notificationstructure.md) | Interface for Structure |
32
33
  | [Snackbar](./foundation-notifications.snackbar.md) | Interface for Snackbar configuration |
33
34
  | [Toast](./foundation-notifications.toast.md) | Interface for Toast configuration |
35
+ | [ToastButton](./foundation-notifications.toastbutton.md) | Interface for ToastButton |
34
36
 
35
37
  ## Variables
36
38
 
@@ -52,6 +54,7 @@
52
54
 
53
55
  | Type Alias | Description |
54
56
  | --- | --- |
57
+ | [NotificationSeverity](./foundation-notifications.notificationseverity.md) | type for notification severity |
55
58
  | [NotificationType](./foundation-notifications.notificationtype.md) | type for notification |
56
59
  | [SnackbarType](./foundation-notifications.snackbartype.md) | type for snackbar type |
57
60
  | [ToastPosition](./foundation-notifications.toastposition.md) | type for notification position |
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [ALERT\_ID](./foundation-notifications.notificationdatarow.alert_id.md)
4
+
5
+ ## NotificationDataRow.ALERT\_ID property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ ALERT_ID: string;
11
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [CREATED\_AT](./foundation-notifications.notificationdatarow.created_at.md)
4
+
5
+ ## NotificationDataRow.CREATED\_AT property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ CREATED_AT: number;
11
+ ```
@@ -0,0 +1,14 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [DETAILS](./foundation-notifications.notificationdatarow.details.md)
4
+
5
+ ## NotificationDataRow.DETAILS property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ DETAILS: {
11
+ OPERATION: string;
12
+ ROW_REF: string;
13
+ };
14
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [EXPIRY](./foundation-notifications.notificationdatarow.expiry.md)
4
+
5
+ ## NotificationDataRow.EXPIRY property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ EXPIRY?: null;
11
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [HEADER](./foundation-notifications.notificationdatarow.header.md)
4
+
5
+ ## NotificationDataRow.HEADER property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ HEADER: string;
11
+ ```
@@ -0,0 +1,28 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md)
4
+
5
+ ## NotificationDataRow interface
6
+
7
+ Interface for notify data
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ export interface NotificationDataRow
13
+ ```
14
+
15
+ ## Properties
16
+
17
+ | Property | Modifiers | Type | Description |
18
+ | --- | --- | --- | --- |
19
+ | [ALERT\_ID](./foundation-notifications.notificationdatarow.alert_id.md) | | string | |
20
+ | [CREATED\_AT](./foundation-notifications.notificationdatarow.created_at.md) | | number | |
21
+ | [DETAILS](./foundation-notifications.notificationdatarow.details.md) | | { OPERATION: string; ROW\_REF: string; } | |
22
+ | [EXPIRY?](./foundation-notifications.notificationdatarow.expiry.md) | | null | _(Optional)_ |
23
+ | [HEADER](./foundation-notifications.notificationdatarow.header.md) | | string | |
24
+ | [MESSAGE](./foundation-notifications.notificationdatarow.message.md) | | string | |
25
+ | [NOTIFY\_SEVERITY](./foundation-notifications.notificationdatarow.notify_severity.md) | | [NotificationSeverity](./foundation-notifications.notificationseverity.md) | |
26
+ | [SENDER?](./foundation-notifications.notificationdatarow.sender.md) | | null | _(Optional)_ |
27
+ | [USER\_NAME](./foundation-notifications.notificationdatarow.user_name.md) | | string | |
28
+
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [MESSAGE](./foundation-notifications.notificationdatarow.message.md)
4
+
5
+ ## NotificationDataRow.MESSAGE property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ MESSAGE: string;
11
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [NOTIFY\_SEVERITY](./foundation-notifications.notificationdatarow.notify_severity.md)
4
+
5
+ ## NotificationDataRow.NOTIFY\_SEVERITY property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ NOTIFY_SEVERITY: NotificationSeverity;
11
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [SENDER](./foundation-notifications.notificationdatarow.sender.md)
4
+
5
+ ## NotificationDataRow.SENDER property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ SENDER?: null;
11
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationDataRow](./foundation-notifications.notificationdatarow.md) &gt; [USER\_NAME](./foundation-notifications.notificationdatarow.user_name.md)
4
+
5
+ ## NotificationDataRow.USER\_NAME property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ USER_NAME: string;
11
+ ```
@@ -0,0 +1,13 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [NotificationSeverity](./foundation-notifications.notificationseverity.md)
4
+
5
+ ## NotificationSeverity type
6
+
7
+ type for notification severity
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ export type NotificationSeverity = 'Information' | 'Warning' | 'Serious' | 'Critical';
13
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [Toast](./foundation-notifications.toast.md) &gt; [buttons](./foundation-notifications.toast.buttons.md)
4
+
5
+ ## Toast.buttons property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ readonly buttons?: ToastButton[];
11
+ ```
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [Toast](./foundation-notifications.toast.md) &gt; [details](./foundation-notifications.toast.details.md)
4
+
5
+ ## Toast.details property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ readonly details?: NotificationDataRow;
11
+ ```
@@ -17,7 +17,9 @@ export interface Toast
17
17
  | Property | Modifiers | Type | Description |
18
18
  | --- | --- | --- | --- |
19
19
  | [autoClose?](./foundation-notifications.toast.autoclose.md) | <code>readonly</code> | boolean | _(Optional)_ |
20
+ | [buttons?](./foundation-notifications.toast.buttons.md) | <code>readonly</code> | [ToastButton](./foundation-notifications.toastbutton.md)<!-- -->\[\] | _(Optional)_ |
20
21
  | [closeTimeout?](./foundation-notifications.toast.closetimeout.md) | <code>readonly</code> | number | _(Optional)_ |
22
+ | [details?](./foundation-notifications.toast.details.md) | <code>readonly</code> | [NotificationDataRow](./foundation-notifications.notificationdatarow.md) | _(Optional)_ |
21
23
  | [position?](./foundation-notifications.toast.position.md) | <code>readonly</code> | [ToastPosition](./foundation-notifications.toastposition.md) | _(Optional)_ |
22
24
  | [type?](./foundation-notifications.toast.type.md) | <code>readonly</code> | [NotificationType](./foundation-notifications.notificationtype.md) | _(Optional)_ |
23
25
 
@@ -17,7 +17,9 @@ export declare class ToastBuilder
17
17
  | --- | --- | --- |
18
18
  | [build()](./foundation-notifications.toastbuilder.build.md) | | Build notification |
19
19
  | [withAutoClose(autoClose)](./foundation-notifications.toastbuilder.withautoclose.md) | | Add auto close to notification |
20
+ | [withButtons(buttons)](./foundation-notifications.toastbuilder.withbuttons.md) | | Add buttons to notifications |
20
21
  | [withCloseTimeout(closeTimeout)](./foundation-notifications.toastbuilder.withclosetimeout.md) | | Add close timeout to notification |
22
+ | [withDetails(details)](./foundation-notifications.toastbuilder.withdetails.md) | | Add details data to notifications |
21
23
  | [withPosition(position)](./foundation-notifications.toastbuilder.withposition.md) | | Add position to toast |
22
24
  | [withType(type)](./foundation-notifications.toastbuilder.withtype.md) | | Add type to notification, if the type is anything other than 'warning' or 'success' do not add it |
23
25
 
@@ -0,0 +1,25 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastBuilder](./foundation-notifications.toastbuilder.md) &gt; [withButtons](./foundation-notifications.toastbuilder.withbuttons.md)
4
+
5
+ ## ToastBuilder.withButtons() method
6
+
7
+ Add buttons to notifications
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ withButtons(buttons: ToastButton[]): ToastBuilder;
13
+ ```
14
+
15
+ ## Parameters
16
+
17
+ | Parameter | Type | Description |
18
+ | --- | --- | --- |
19
+ | buttons | [ToastButton](./foundation-notifications.toastbutton.md)<!-- -->\[\] | ToastButton\[\] |
20
+
21
+ **Returns:**
22
+
23
+ [ToastBuilder](./foundation-notifications.toastbuilder.md)
24
+
25
+
@@ -0,0 +1,25 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastBuilder](./foundation-notifications.toastbuilder.md) &gt; [withDetails](./foundation-notifications.toastbuilder.withdetails.md)
4
+
5
+ ## ToastBuilder.withDetails() method
6
+
7
+ Add details data to notifications
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ withDetails(details: NotificationDataRow): ToastBuilder;
13
+ ```
14
+
15
+ ## Parameters
16
+
17
+ | Parameter | Type | Description |
18
+ | --- | --- | --- |
19
+ | details | [NotificationDataRow](./foundation-notifications.notificationdatarow.md) | NotificationDataRow |
20
+
21
+ **Returns:**
22
+
23
+ [ToastBuilder](./foundation-notifications.toastbuilder.md)
24
+
25
+
@@ -0,0 +1,25 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastButton](./foundation-notifications.toastbutton.md) &gt; [action](./foundation-notifications.toastbutton.action.md)
4
+
5
+ ## ToastButton.action() method
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ action({ details, element }: {
11
+ details: NotificationDataRow;
12
+ element: HTMLElement;
13
+ }): void;
14
+ ```
15
+
16
+ ## Parameters
17
+
18
+ | Parameter | Type | Description |
19
+ | --- | --- | --- |
20
+ | { details, element } | { details: [NotificationDataRow](./foundation-notifications.notificationdatarow.md)<!-- -->; element: HTMLElement; } | |
21
+
22
+ **Returns:**
23
+
24
+ void
25
+
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastButton](./foundation-notifications.toastbutton.md) &gt; [appearance](./foundation-notifications.toastbutton.appearance.md)
4
+
5
+ ## ToastButton.appearance property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ appearance?: string;
11
+ ```
@@ -0,0 +1,24 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastButton](./foundation-notifications.toastbutton.md) &gt; [condition](./foundation-notifications.toastbutton.condition.md)
4
+
5
+ ## ToastButton.condition() method
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ condition({ details }?: {
11
+ details: NotificationDataRow;
12
+ }): boolean;
13
+ ```
14
+
15
+ ## Parameters
16
+
17
+ | Parameter | Type | Description |
18
+ | --- | --- | --- |
19
+ | { details } | { details: [NotificationDataRow](./foundation-notifications.notificationdatarow.md)<!-- -->; } | _(Optional)_ |
20
+
21
+ **Returns:**
22
+
23
+ boolean
24
+
@@ -0,0 +1,28 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastButton](./foundation-notifications.toastbutton.md)
4
+
5
+ ## ToastButton interface
6
+
7
+ Interface for ToastButton
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ export interface ToastButton
13
+ ```
14
+
15
+ ## Properties
16
+
17
+ | Property | Modifiers | Type | Description |
18
+ | --- | --- | --- | --- |
19
+ | [appearance?](./foundation-notifications.toastbutton.appearance.md) | | string | _(Optional)_ |
20
+ | [placeholder?](./foundation-notifications.toastbutton.placeholder.md) | | string | _(Optional)_ |
21
+
22
+ ## Methods
23
+
24
+ | Method | Description |
25
+ | --- | --- |
26
+ | [action({ details, element })](./foundation-notifications.toastbutton.action.md) | |
27
+ | [condition({ details })](./foundation-notifications.toastbutton.condition.md) | |
28
+
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-notifications](./foundation-notifications.md) &gt; [ToastButton](./foundation-notifications.toastbutton.md) &gt; [placeholder](./foundation-notifications.toastbutton.placeholder.md)
4
+
5
+ ## ToastButton.placeholder property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ placeholder?: string;
11
+ ```
@@ -99,6 +99,31 @@ export class NotificationBuilder {
99
99
  withToast(toast: Toast): NotificationBuilder;
100
100
  }
101
101
 
102
+ // @public
103
+ export interface NotificationDataRow {
104
+ // (undocumented)
105
+ ALERT_ID: string;
106
+ // (undocumented)
107
+ CREATED_AT: number;
108
+ // (undocumented)
109
+ DETAILS: {
110
+ OPERATION: string;
111
+ ROW_REF: string;
112
+ };
113
+ // (undocumented)
114
+ EXPIRY?: null;
115
+ // (undocumented)
116
+ HEADER: string;
117
+ // (undocumented)
118
+ MESSAGE: string;
119
+ // (undocumented)
120
+ NOTIFY_SEVERITY: NotificationSeverity;
121
+ // (undocumented)
122
+ SENDER?: null;
123
+ // (undocumented)
124
+ USER_NAME: string;
125
+ }
126
+
102
127
  // Warning: (ae-internal-missing-underscore) The name "NotificationElement" should be prefixed with an underscore because the declaration is marked as @internal
103
128
  //
104
129
  // @internal (undocumented)
@@ -112,6 +137,9 @@ export enum NotificationEvent {
112
137
  NOTIFICATION_EVENT = "notification-event"
113
138
  }
114
139
 
140
+ // @public
141
+ export type NotificationSeverity = 'Information' | 'Warning' | 'Serious' | 'Critical';
142
+
115
143
  // @public
116
144
  export interface NotificationStructure {
117
145
  // (undocumented)
@@ -179,8 +207,12 @@ export interface Toast {
179
207
  // (undocumented)
180
208
  readonly autoClose?: boolean;
181
209
  // (undocumented)
210
+ readonly buttons?: ToastButton[];
211
+ // (undocumented)
182
212
  readonly closeTimeout?: number;
183
213
  // (undocumented)
214
+ readonly details?: NotificationDataRow;
215
+ // (undocumented)
184
216
  readonly position?: ToastPosition;
185
217
  // (undocumented)
186
218
  readonly type?: NotificationType;
@@ -190,11 +222,30 @@ export interface Toast {
190
222
  export class ToastBuilder {
191
223
  build(): Toast;
192
224
  withAutoClose(autoClose: boolean): ToastBuilder;
225
+ withButtons(buttons: ToastButton[]): ToastBuilder;
193
226
  withCloseTimeout(closeTimeout: number): ToastBuilder;
227
+ withDetails(details: NotificationDataRow): ToastBuilder;
194
228
  withPosition(position: ToastPosition): ToastBuilder;
195
229
  withType(type: NotificationType): ToastBuilder;
196
230
  }
197
231
 
232
+ // @public
233
+ export interface ToastButton {
234
+ // (undocumented)
235
+ action({ details, element }: {
236
+ details: NotificationDataRow;
237
+ element: HTMLElement;
238
+ }): void;
239
+ // (undocumented)
240
+ appearance?: string;
241
+ // (undocumented)
242
+ condition({ details }?: {
243
+ details: NotificationDataRow;
244
+ }): boolean;
245
+ // (undocumented)
246
+ placeholder?: string;
247
+ }
248
+
198
249
  // @public
199
250
  export type ToastPosition = 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
200
251
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/foundation-notifications",
3
3
  "description": "Genesis Foundation UI Notifications Utils",
4
- "version": "14.52.2",
4
+ "version": "14.53.0",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -37,11 +37,11 @@
37
37
  "test:debug": "genx test --debug"
38
38
  },
39
39
  "devDependencies": {
40
- "@genesislcap/foundation-testing": "14.52.2",
41
- "@genesislcap/genx": "14.52.2"
40
+ "@genesislcap/foundation-testing": "14.53.0",
41
+ "@genesislcap/genx": "14.53.0"
42
42
  },
43
43
  "dependencies": {
44
- "@genesislcap/foundation-utils": "14.52.2",
44
+ "@genesislcap/foundation-utils": "14.53.0",
45
45
  "@microsoft/fast-element": "^1.7.0",
46
46
  "tslib": "^2.3.1"
47
47
  },
@@ -53,5 +53,5 @@
53
53
  "publishConfig": {
54
54
  "access": "public"
55
55
  },
56
- "gitHead": "9ee4ddde47ecc9d5065be29bf7560e66b4839878"
56
+ "gitHead": "026e0655a3e50a4ab8db54d701c2abcd74c4bf9b"
57
57
  }