@eui/components 17.0.0-rc.5 → 17.0.0-rc.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 (149) hide show
  1. package/docs/classes/EuiAutoCompleteItem.html +1 -1
  2. package/docs/components/EuiAlertComponent.html +141 -15
  3. package/docs/components/EuiAutocompleteComponent.html +28 -16
  4. package/docs/components/EuiAvatarComponent.html +15 -72
  5. package/docs/components/EuiBadgeComponent.html +61 -637
  6. package/docs/components/EuiBlockContentComponent.html +192 -715
  7. package/docs/components/EuiBlockDocumentComponent.html +18 -725
  8. package/docs/components/EuiCardContentComponent.html +69 -0
  9. package/docs/components/EuiDashboardButtonComponent.html +1 -1
  10. package/docs/components/EuiDashboardCardComponent.html +5 -5
  11. package/docs/components/EuiDialogContainerComponent.html +1 -1
  12. package/docs/components/EuiDropdownComponent.html +43 -385
  13. package/docs/components/EuiFieldsetComponent.html +6 -6
  14. package/docs/components/EuiMenuComponent.html +96 -961
  15. package/docs/components/EuiMenuItemComponent.html +1 -1
  16. package/docs/components/EuiTreeComponent.html +1 -1
  17. package/docs/dependencies.html +2 -2
  18. package/docs/directives/EuiDropdownContentDirective.html +119 -7
  19. package/docs/js/menu-wc.js +221 -190
  20. package/docs/js/menu-wc_es5.js +1 -1
  21. package/docs/js/search/search_index.js +2 -2
  22. package/docs/miscellaneous/variables.html +35 -0
  23. package/docs/modules/EuiAlertModule.html +4 -1
  24. package/docs/modules/EuiAppSidebarModule.html +4 -28
  25. package/docs/modules/EuiAppToolbarModule.html +4 -28
  26. package/docs/modules/EuiAvatarModule.html +7 -28
  27. package/docs/modules/EuiBadgeModule.html +11 -1
  28. package/docs/modules/EuiChartsModule.html +4 -28
  29. package/docs/modules/EuiFieldsetModule.html +3 -0
  30. package/docs/modules/EuiHeaderModule.html +4 -28
  31. package/docs/modules/EuiPageModule.html +4 -28
  32. package/docs/modules/EuiSidebarMenuModule.html +4 -28
  33. package/docs/modules/EuiSkeletonModule.html +4 -28
  34. package/docs/modules/EuiToolbarModule.html +4 -28
  35. package/docs/modules/EuiUserProfileModule.html +4 -28
  36. package/esm2022/eui-alert/eui-alert.component.mjs +75 -80
  37. package/esm2022/eui-alert/eui-alert.module.mjs +49 -0
  38. package/esm2022/eui-alert/index.mjs +2 -1
  39. package/esm2022/eui-autocomplete/eui-autocomplete.component.mjs +47 -76
  40. package/esm2022/eui-autocomplete/models/eui-autocomplete-item.model.mjs +2 -1
  41. package/esm2022/eui-avatar/avatar-badge/avatar-badge.component.mjs +1 -4
  42. package/esm2022/eui-avatar/eui-avatar-list.component.mjs +1 -4
  43. package/esm2022/eui-avatar/eui-avatar.component.mjs +20 -39
  44. package/esm2022/eui-avatar/eui-avatar.module.mjs +5 -2
  45. package/esm2022/eui-badge/eui-badge.component.mjs +40 -35
  46. package/esm2022/eui-badge/eui-badge.module.mjs +19 -0
  47. package/esm2022/eui-badge/index.mjs +2 -1
  48. package/esm2022/eui-block-content/eui-block-content.component.mjs +22 -19
  49. package/esm2022/eui-block-document/eui-block-document.component.mjs +14 -19
  50. package/esm2022/eui-card/components/eui-card-content/eui-card-content.component.mjs +6 -2
  51. package/esm2022/eui-dashboard-button/eui-dashboard-button.component.mjs +6 -9
  52. package/esm2022/eui-dashboard-card/eui-dashboard-card.component.mjs +23 -33
  53. package/esm2022/eui-dialog/container/eui-dialog-container.component.mjs +3 -3
  54. package/esm2022/eui-dropdown/directives/eui-dropdown-content.directive.mjs +10 -4
  55. package/esm2022/eui-dropdown/eui-dropdown.component.mjs +34 -48
  56. package/esm2022/eui-fieldset/eui-fieldset.component.mjs +22 -39
  57. package/esm2022/eui-fieldset/eui-fieldset.module.mjs +4 -3
  58. package/esm2022/eui-menu/eui-menu-item.component.mjs +7 -3
  59. package/esm2022/eui-menu/eui-menu.component.mjs +51 -56
  60. package/esm2022/eui-overlay/components/eui-overlay-header/eui-overlay-header-title/eui-overlay-header-title.component.mjs +1 -1
  61. package/esm2022/eui-tree/eui-tree.component.mjs +9 -4
  62. package/esm2022/layout/eui-app/eui-app-sidebar/sidebar.component.mjs +2 -2
  63. package/esm2022/layout/eui-app/eui-app-toolbar/toolbar.component.mjs +3 -7
  64. package/esm2022/layout/eui-notifications/eui-notifications.component.mjs +1 -1
  65. package/esm2022/layout/eui-notifications-v2/eui-notifications.component.mjs +1 -1
  66. package/esm2022/layout/eui-search/search.component.mjs +1 -2
  67. package/esm2022/layout/eui-user-profile/user-profile.component.mjs +1 -1
  68. package/eui-alert/eui-alert.component.d.ts +13 -23
  69. package/eui-alert/eui-alert.component.d.ts.map +1 -1
  70. package/eui-alert/eui-alert.module.d.ts +14 -0
  71. package/eui-alert/eui-alert.module.d.ts.map +1 -0
  72. package/eui-alert/index.d.ts +1 -0
  73. package/eui-alert/index.d.ts.map +1 -1
  74. package/eui-autocomplete/eui-autocomplete.component.d.ts +39 -23
  75. package/eui-autocomplete/eui-autocomplete.component.d.ts.map +1 -1
  76. package/eui-autocomplete/models/eui-autocomplete-item.model.d.ts +2 -2
  77. package/eui-autocomplete/models/eui-autocomplete-item.model.d.ts.map +1 -1
  78. package/eui-avatar/avatar-badge/avatar-badge.component.d.ts +0 -1
  79. package/eui-avatar/avatar-badge/avatar-badge.component.d.ts.map +1 -1
  80. package/eui-avatar/eui-avatar-list.component.d.ts +0 -1
  81. package/eui-avatar/eui-avatar-list.component.d.ts.map +1 -1
  82. package/eui-avatar/eui-avatar.component.d.ts +10 -10
  83. package/eui-avatar/eui-avatar.component.d.ts.map +1 -1
  84. package/eui-avatar/eui-avatar.module.d.ts +2 -1
  85. package/eui-avatar/eui-avatar.module.d.ts.map +1 -1
  86. package/eui-badge/eui-badge.component.d.ts +8 -14
  87. package/eui-badge/eui-badge.component.d.ts.map +1 -1
  88. package/eui-badge/eui-badge.module.d.ts +10 -0
  89. package/eui-badge/eui-badge.module.d.ts.map +1 -0
  90. package/eui-badge/index.d.ts +1 -0
  91. package/eui-badge/index.d.ts.map +1 -1
  92. package/eui-block-content/eui-block-content.component.d.ts +6 -7
  93. package/eui-block-content/eui-block-content.component.d.ts.map +1 -1
  94. package/eui-block-document/eui-block-document.component.d.ts +3 -7
  95. package/eui-block-document/eui-block-document.component.d.ts.map +1 -1
  96. package/eui-card/components/eui-card-content/eui-card-content.component.d.ts +1 -0
  97. package/eui-card/components/eui-card-content/eui-card-content.component.d.ts.map +1 -1
  98. package/eui-dashboard-button/eui-dashboard-button.component.d.ts +1 -2
  99. package/eui-dashboard-button/eui-dashboard-button.component.d.ts.map +1 -1
  100. package/eui-dashboard-card/eui-dashboard-card.component.d.ts +9 -7
  101. package/eui-dashboard-card/eui-dashboard-card.component.d.ts.map +1 -1
  102. package/eui-dropdown/directives/eui-dropdown-content.directive.d.ts +1 -0
  103. package/eui-dropdown/directives/eui-dropdown-content.directive.d.ts.map +1 -1
  104. package/eui-dropdown/eui-dropdown.component.d.ts +8 -18
  105. package/eui-dropdown/eui-dropdown.component.d.ts.map +1 -1
  106. package/eui-fieldset/eui-fieldset.component.d.ts +12 -8
  107. package/eui-fieldset/eui-fieldset.component.d.ts.map +1 -1
  108. package/eui-fieldset/eui-fieldset.module.d.ts +2 -1
  109. package/eui-fieldset/eui-fieldset.module.d.ts.map +1 -1
  110. package/eui-menu/eui-menu-item.component.d.ts +4 -0
  111. package/eui-menu/eui-menu-item.component.d.ts.map +1 -1
  112. package/eui-menu/eui-menu.component.d.ts +16 -19
  113. package/eui-menu/eui-menu.component.d.ts.map +1 -1
  114. package/eui-tree/eui-tree.component.d.ts.map +1 -1
  115. package/fesm2022/eui-components-eui-alert.mjs +103 -68
  116. package/fesm2022/eui-components-eui-alert.mjs.map +1 -1
  117. package/fesm2022/eui-components-eui-autocomplete.mjs +48 -74
  118. package/fesm2022/eui-components-eui-autocomplete.mjs.map +1 -1
  119. package/fesm2022/eui-components-eui-avatar.mjs +22 -45
  120. package/fesm2022/eui-components-eui-avatar.mjs.map +1 -1
  121. package/fesm2022/eui-components-eui-badge.mjs +42 -22
  122. package/fesm2022/eui-components-eui-badge.mjs.map +1 -1
  123. package/fesm2022/eui-components-eui-block-content.mjs +21 -18
  124. package/fesm2022/eui-components-eui-block-content.mjs.map +1 -1
  125. package/fesm2022/eui-components-eui-block-document.mjs +13 -18
  126. package/fesm2022/eui-components-eui-block-document.mjs.map +1 -1
  127. package/fesm2022/eui-components-eui-card.mjs +5 -1
  128. package/fesm2022/eui-components-eui-card.mjs.map +1 -1
  129. package/fesm2022/eui-components-eui-dashboard-button.mjs +5 -8
  130. package/fesm2022/eui-components-eui-dashboard-button.mjs.map +1 -1
  131. package/fesm2022/eui-components-eui-dashboard-card.mjs +22 -32
  132. package/fesm2022/eui-components-eui-dashboard-card.mjs.map +1 -1
  133. package/fesm2022/eui-components-eui-dialog.mjs +2 -2
  134. package/fesm2022/eui-components-eui-dialog.mjs.map +1 -1
  135. package/fesm2022/eui-components-eui-dropdown.mjs +41 -48
  136. package/fesm2022/eui-components-eui-dropdown.mjs.map +1 -1
  137. package/fesm2022/eui-components-eui-fieldset.mjs +23 -40
  138. package/fesm2022/eui-components-eui-fieldset.mjs.map +1 -1
  139. package/fesm2022/eui-components-eui-menu.mjs +51 -55
  140. package/fesm2022/eui-components-eui-menu.mjs.map +1 -1
  141. package/fesm2022/eui-components-eui-overlay.mjs +1 -1
  142. package/fesm2022/eui-components-eui-overlay.mjs.map +1 -1
  143. package/fesm2022/eui-components-eui-tree.mjs +8 -3
  144. package/fesm2022/eui-components-eui-tree.mjs.map +1 -1
  145. package/fesm2022/eui-components-layout.mjs +7 -12
  146. package/fesm2022/eui-components-layout.mjs.map +1 -1
  147. package/layout/eui-app/eui-app-toolbar/toolbar.component.d.ts.map +1 -1
  148. package/layout/eui-search/search.component.d.ts.map +1 -1
  149. package/package.json +7 -7
@@ -1,6 +1,5 @@
1
1
  import { EventEmitter, OnChanges, QueryList } from '@angular/core';
2
2
  import { BaseStatesDirective } from '@eui/components/shared';
3
- import { BooleanInput } from '@angular/cdk/coercion';
4
3
  import * as i0 from "@angular/core";
5
4
  import * as i1 from "@eui/components/shared";
6
5
  export declare class EuiFieldsetComponent implements OnChanges {
@@ -12,12 +11,12 @@ export declare class EuiFieldsetComponent implements OnChanges {
12
11
  iconClass: string;
13
12
  iconSvgName: string;
14
13
  iconSvgFillColor: string;
15
- hasDefaultIcon: BooleanInput;
16
- isExpandable: BooleanInput;
17
- isExpanded: BooleanInput;
18
- isLarge: BooleanInput;
19
- isFirst: BooleanInput;
20
- euiHighlighted: BooleanInput;
14
+ hasDefaultIcon: boolean;
15
+ isExpandable: boolean;
16
+ isExpanded: boolean;
17
+ isLarge: boolean;
18
+ isFirst: boolean;
19
+ euiHighlighted: boolean;
21
20
  expand: EventEmitter<string>;
22
21
  expandMenuLabel: string;
23
22
  collapseMenuLabel: string;
@@ -27,10 +26,15 @@ export declare class EuiFieldsetComponent implements OnChanges {
27
26
  constructor(baseStatesDirective: BaseStatesDirective);
28
27
  ngOnChanges(): void;
29
28
  onToggle(): void;
30
- private getCssClasses;
31
29
  private setIcon;
32
30
  static ɵfac: i0.ɵɵFactoryDeclaration<EuiFieldsetComponent, never>;
33
31
  static ɵcmp: i0.ɵɵComponentDeclaration<EuiFieldsetComponent, "eui-fieldset", never, { "e2eAttr": { "alias": "e2eAttr"; "required": false; }; "id": { "alias": "id"; "required": false; }; "label": { "alias": "label"; "required": false; }; "iconClass": { "alias": "iconClass"; "required": false; }; "iconSvgName": { "alias": "iconSvgName"; "required": false; }; "iconSvgFillColor": { "alias": "iconSvgFillColor"; "required": false; }; "hasDefaultIcon": { "alias": "hasDefaultIcon"; "required": false; }; "isExpandable": { "alias": "isExpandable"; "required": false; }; "isExpanded": { "alias": "isExpanded"; "required": false; }; "isLarge": { "alias": "isLarge"; "required": false; }; "isFirst": { "alias": "isFirst"; "required": false; }; "euiHighlighted": { "alias": "euiHighlighted"; "required": false; }; }, { "expand": "expand"; }, ["customLabelRightContent", "customLabelExtraContent"], ["euiFieldsetLabelExtraContent", "euiFieldsetLabelRightContent", "*"], false, [{ directive: typeof i1.BaseStatesDirective; inputs: { "euiSecondary": "euiSecondary"; "euiSuccess": "euiSuccess"; "euiInfo": "euiInfo"; "euiWarning": "euiWarning"; "euiDanger": "euiDanger"; "euiAccent": "euiAccent"; "euiVariant": "euiVariant"; "euiHighlighted": "euiHighlighted"; }; outputs: {}; }]>;
32
+ static ngAcceptInputType_hasDefaultIcon: unknown;
33
+ static ngAcceptInputType_isExpandable: unknown;
34
+ static ngAcceptInputType_isExpanded: unknown;
35
+ static ngAcceptInputType_isLarge: unknown;
36
+ static ngAcceptInputType_isFirst: unknown;
37
+ static ngAcceptInputType_euiHighlighted: unknown;
34
38
  }
35
39
  export declare class EuiFieldsetLabelRightContentTagDirective {
36
40
  static ɵfac: i0.ɵɵFactoryDeclaration<EuiFieldsetLabelRightContentTagDirective, never>;
@@ -1 +1 @@
1
- {"version":3,"file":"eui-fieldset.component.d.ts","sourceRoot":"","sources":["../../eui-fieldset/eui-fieldset.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAIH,YAAY,EAIZ,SAAS,EAET,SAAS,EAEZ,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAC7D,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;;;AAGrD,qBAqBa,oBAAqB,YAAW,SAAS;IAoD/B,mBAAmB,EAAE,mBAAmB;IAnD3D,IACW,UAAU,IAAI,MAAM,CAE9B;IAID,OAAO,SAAkB;IAEhB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,gBAAgB,EAAE,MAAM,CAAC;IAIlC,cAAc,EAAE,YAAY,CAAS;IAIrC,YAAY,EAAE,YAAY,CAAS;IAInC,UAAU,EAAE,YAAY,CAAQ;IAIhC,OAAO,EAAE,YAAY,CAAS;IAI9B,OAAO,EAAE,YAAY,CAAS;IAK9B,cAAc,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AChC,WAAW,SAAc;IAGhC,uBAAuB,EAAE,SAAS,CAAC,wCAAwC,CAAC,CAAC;IAE7E,uBAAuB,EAAE,SAAS,CAAC,wCAAwC,CAAC,CAAC;gBAE1D,mBAAmB,EAAE,mBAAmB;IAE3D,WAAW,IAAI,IAAI;IAInB,QAAQ,IAAI,IAAI;IAOhB,OAAO,CAAC,OAAO;yCArDN,oBAAoB;2CAApB,oBAAoB;6CA8Eq8vB,OAAQ;2CAAR,OAAQ;yCAAR,OAAQ;sCAAR,OAAQ;sCAAR,OAAQ;6CAAR,OAAQ;CAV7+vB;AAGD,qBACa,wCAAwC;yCAAxC,wCAAwC;2CAAxC,wCAAwC;CACpD;AACD,qBACa,wCAAwC;yCAAxC,wCAAwC;2CAAxC,wCAAwC;CACpD"}
@@ -3,9 +3,10 @@ import * as i1 from "./eui-fieldset.component";
3
3
  import * as i2 from "@angular/common";
4
4
  import * as i3 from "@eui/components/eui-button";
5
5
  import * as i4 from "@eui/components/eui-icon";
6
+ import * as i5 from "@eui/components/shared";
6
7
  export declare class EuiFieldsetModule {
7
8
  static ɵfac: i0.ɵɵFactoryDeclaration<EuiFieldsetModule, never>;
8
- static ɵmod: i0.ɵɵNgModuleDeclaration<EuiFieldsetModule, [typeof i1.EuiFieldsetComponent, typeof i1.EuiFieldsetLabelRightContentTagDirective, typeof i1.EuiFieldsetLabelExtraContentTagDirective], [typeof i2.CommonModule, typeof i3.EuiButtonModule, typeof i4.EuiIconModule], [typeof i1.EuiFieldsetComponent, typeof i1.EuiFieldsetLabelRightContentTagDirective, typeof i1.EuiFieldsetLabelExtraContentTagDirective]>;
9
+ static ɵmod: i0.ɵɵNgModuleDeclaration<EuiFieldsetModule, [typeof i1.EuiFieldsetComponent, typeof i1.EuiFieldsetLabelRightContentTagDirective, typeof i1.EuiFieldsetLabelExtraContentTagDirective], [typeof i2.CommonModule, typeof i3.EuiButtonModule, typeof i4.EuiIconModule, typeof i5.BaseStatesDirective], [typeof i1.EuiFieldsetComponent, typeof i1.EuiFieldsetLabelRightContentTagDirective, typeof i1.EuiFieldsetLabelExtraContentTagDirective]>;
9
10
  static ɵinj: i0.ɵɵInjectorDeclaration<EuiFieldsetModule>;
10
11
  }
11
12
  //# sourceMappingURL=eui-fieldset.module.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"eui-fieldset.module.d.ts","sourceRoot":"","sources":["../../eui-fieldset/eui-fieldset.module.ts"],"names":[],"mappings":";;;;;AAWA,qBAKa,iBAAiB;yCAAjB,iBAAiB;0CAAjB,iBAAiB;0CAAjB,iBAAiB;CAAG"}
1
+ {"version":3,"file":"eui-fieldset.module.d.ts","sourceRoot":"","sources":["../../eui-fieldset/eui-fieldset.module.ts"],"names":[],"mappings":";;;;;;AAYA,qBAKa,iBAAiB;yCAAjB,iBAAiB;0CAAjB,iBAAiB;0CAAjB,iBAAiB;CAAG"}
@@ -27,6 +27,10 @@ export declare class EuiMenuItemComponent implements OnInit {
27
27
  onExpandToggle(event: Event): void;
28
28
  onActionIconClick($event: MouseEvent): void;
29
29
  private getTooltipFromItem;
30
+ /**
31
+ * Returns the default eui-menu-item class on the HostBinding function
32
+ * @private
33
+ */
30
34
  private getCssClasses;
31
35
  static ɵfac: i0.ɵɵFactoryDeclaration<EuiMenuItemComponent, never>;
32
36
  static ɵcmp: i0.ɵɵComponentDeclaration<EuiMenuItemComponent, "eui-menu-item", never, { "item": { "alias": "item"; "required": false; }; "hasIcon": { "alias": "hasIcon"; "required": false; }; "hasTooltip": { "alias": "hasTooltip"; "required": false; }; "isCollapsed": { "alias": "isCollapsed"; "required": false; }; }, { "expandToggle": "expandToggle"; "itemClick": "itemClick"; }, never, ["*"], false, [{ directive: typeof i1.BaseStatesDirective; inputs: {}; outputs: {}; }]>;
@@ -1 +1 @@
1
- {"version":3,"file":"eui-menu-item.component.d.ts","sourceRoot":"","sources":["../../eui-menu/eui-menu-item.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAMH,YAAY,EAEZ,MAAM,EACT,MA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,EAAE,MAAM,uBAAuB,CAAC;;;AAGrD,qBAWa,oBAAqB,YAAW,MAAM;IA8B5B,mBAAmB,EAAE,mBAAmB;IA5BjC,IAAI,SAAc;IAE5C,IACW,UAAU,IAAI,MAAM,CAE9B;IAEQ,IAAI,EAAE,WAAW,CAAC;IACjB,YAAY,4BAAmC;IAC/C,SAAS,4BAAmC;IAEtD,eAAe,SAAY;IAC3B,iBAAiB,SAAc;IAE/B,SAAS,UAAS;IAClB,UAAU,UAAS;IACnB,WAAW,UAAS;IAIpB,OAAO,EAAC,YAAY,CAAS;IAG7B,UAAU,EAAC,YAAY,CAAS;IAGhC,WAAW,EAAC,YAAY,CAAS;gBAEd,mBAAmB,EAAE,mBAAmB;IAE3D,QAAQ,IAAI,IAAI;IAST,eAAe,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI;IAK/C,IAAI,eAAe,IAAI,MAAM,CAU5B;IAEM,OAAO,CAAC,KAAK,EAAE,KAAK,GAAG,IAAI;IAK3B,cAAc,CAAC,KAAK,EAAE,KAAK,GAAG,IAAI;IAKlC,iBAAiB,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI;IAKlD,OAAO,CAAC,kBAAkB;IAW1B;;;OAGG;IACH,OAAO,CAAC,aAAa;yCAxFZ,oBAAoB;2CAApB,oBAAoB;CA2FhC"}
@@ -1,12 +1,14 @@
1
1
  import { OnInit, EventEmitter, OnChanges, SimpleChanges } from '@angular/core';
2
2
  import { Router, ActivatedRoute } from '@angular/router';
3
3
  import { BooleanInput } from '@angular/cdk/coercion';
4
- import { BaseDirective } from '@eui/components/shared';
4
+ import { BaseStatesDirective } from '@eui/components/shared';
5
5
  import { EuiMenuItem } from './models/eui-menu-item.model';
6
6
  import * as i0 from "@angular/core";
7
- export declare class EuiMenuComponent extends BaseDirective implements OnInit, OnChanges {
7
+ import * as i1 from "@eui/components/shared";
8
+ export declare class EuiMenuComponent implements OnInit, OnChanges {
8
9
  private router;
9
10
  private route;
11
+ baseStatesDirective: BaseStatesDirective;
10
12
  items: EuiMenuItem[];
11
13
  searchFilterLabel: string;
12
14
  externalLinkLabel: string;
@@ -14,22 +16,12 @@ export declare class EuiMenuComponent extends BaseDirective implements OnInit, O
14
16
  itemsState: any[];
15
17
  isClick: EventEmitter<boolean>;
16
18
  itemClick: EventEmitter<EuiMenuItem>;
17
- get isCollapsed(): boolean;
18
- set isCollapsed(value: BooleanInput);
19
- private _isCollapsed;
20
- get hasFilter(): boolean;
21
- set hasFilter(value: BooleanInput);
22
- private _hasFilter;
23
- get hasIcons(): boolean;
24
- set hasIcons(value: BooleanInput);
25
- private _hasIcons;
26
- get hasTooltip(): boolean;
27
- set hasTooltip(value: BooleanInput);
28
- private _hasTooltip;
29
- get expandAllItems(): boolean;
30
- set expandAllItems(value: BooleanInput);
31
- private _expandAllItems;
32
- constructor(router: Router, route: ActivatedRoute);
19
+ isCollapsed: BooleanInput;
20
+ hasFilter: BooleanInput;
21
+ hasIcons: BooleanInput;
22
+ hasTooltip: BooleanInput;
23
+ expandAllItems: BooleanInput;
24
+ constructor(router: Router, route: ActivatedRoute, baseStatesDirective: BaseStatesDirective);
33
25
  get cssClasses(): string;
34
26
  stopPropagation(event: MouseEvent): void;
35
27
  ngOnChanges(changes: SimpleChanges): void;
@@ -96,7 +88,12 @@ export declare class EuiMenuComponent extends BaseDirective implements OnInit, O
96
88
  * @private
97
89
  */
98
90
  private expandToGivenItem;
91
+ /**
92
+ * Returns the default eui-menu class and others based on certain conditions
93
+ * @private
94
+ */
95
+ private getCssClasses;
99
96
  static ɵfac: i0.ɵɵFactoryDeclaration<EuiMenuComponent, never>;
100
- static ɵcmp: i0.ɵɵComponentDeclaration<EuiMenuComponent, "eui-menu", never, { "items": { "alias": "items"; "required": false; }; "searchFilterLabel": { "alias": "searchFilterLabel"; "required": false; }; "externalLinkLabel": { "alias": "externalLinkLabel"; "required": false; }; "fragmentId": { "alias": "fragmentId"; "required": false; }; "isCollapsed": { "alias": "isCollapsed"; "required": false; }; "hasFilter": { "alias": "hasFilter"; "required": false; }; "hasIcons": { "alias": "hasIcons"; "required": false; }; "hasTooltip": { "alias": "hasTooltip"; "required": false; }; "expandAllItems": { "alias": "expandAllItems"; "required": false; }; }, { "isClick": "isClick"; "itemClick": "itemClick"; }, never, never, false, never>;
97
+ static ɵcmp: i0.ɵɵComponentDeclaration<EuiMenuComponent, "eui-menu", never, { "items": { "alias": "items"; "required": false; }; "searchFilterLabel": { "alias": "searchFilterLabel"; "required": false; }; "externalLinkLabel": { "alias": "externalLinkLabel"; "required": false; }; "fragmentId": { "alias": "fragmentId"; "required": false; }; "isCollapsed": { "alias": "isCollapsed"; "required": false; }; "hasFilter": { "alias": "hasFilter"; "required": false; }; "hasIcons": { "alias": "hasIcons"; "required": false; }; "hasTooltip": { "alias": "hasTooltip"; "required": false; }; "expandAllItems": { "alias": "expandAllItems"; "required": false; }; }, { "isClick": "isClick"; "itemClick": "itemClick"; }, never, never, false, [{ directive: typeof i1.BaseStatesDirective; inputs: {}; outputs: {}; }]>;
101
98
  }
102
99
  //# sourceMappingURL=eui-menu.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"eui-menu.component.d.ts","sourceRoot":"","sources":["../../eui-menu/eui-menu.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAMH,MAAM,EAEN,YAAY,EACZ,SAAS,EACT,aAAa,EAEhB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,EAAyB,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAG5E,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAEvD,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;;AAE3D,qBAOa,gBAAiB,SAAQ,aAAc,YAAW,MAAM,EAAE,SAAS;IAuDxE,OAAO,CAAC,MAAM;IACd,OAAO,CAAC,KAAK;IAvDR,KAAK,EAAE,WAAW,EAAE,CAAC;IACrB,iB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AC,oCAAoC;IAqB5C,OAAO,CAAC,6BAA6B;IAmBrC,OAAO,CAAC,sBAAsB;IA6B9B,OAAO,CAAC,WAAW;IAYnB,OAAO,CAAC,kBAAkB;IAY1B,OAAO,CAAC,qCAAqC;IAY7C,OAAO,CAAC,oCAAoC;IAe5C,OAAO,CAAC,kBAAkB;IAmB1B,OAAO,CAAC,qBAAqB;IAS7B,OAAO,CAAC,mBAAmB;IAW3B,OAAO,CAAC,WAAW;IAInB,OAAO,CAAC,cAAc;IAqBtB,OAAO,CAAC,qBAAqB;IAc7B,OAAO,CAAC,cAAc;IAgBtB,OAAO,CAAC,aAAa;IAOrB,OAAO,CAAC,mBAAmB;IAM3B,OAAO,CAAC,aAAa;IAWrB,OAAO,CAAC,mBAAmB;IAW3B,OAAO,CAAC,kBAAkB;IAI1B,OAAO,CAAC,mBAAmB;IAc3B,OAAO,CAAC,wBAAwB;IAgBhC,OAAO,CAAC,aAAa;IAWrB,OAAO,CAAC,iBAAiB;IAUzB,OAAO,CAAC,wBAAwB;yCAr5BvB,gBAAgB;2CAAhB,gBAAgB;CAw5B5B;AAED,qBAmBa,aAAa;yCAAb,aAAa;0CAAb,aAAa,UA76Bb,gBAAgB,uWAAhB,gBAAgB;0CA66BhB,aAAa;CAAG"}
@@ -1,23 +1,28 @@
1
- import { __decorate } from 'tslib';
2
1
  import * as i0 from '@angular/core';
3
- import { Directive, HostBinding, EventEmitter, Component, ChangeDetectionStrategy, ViewEncapsulation, Input, Output, ContentChild, forwardRef, NgModule } from '@angular/core';
2
+ import { Directive, HostBinding, EventEmitter, booleanAttribute, Component, ChangeDetectionStrategy, ViewEncapsulation, Input, Output, ContentChild, forwardRef, NgModule } from '@angular/core';
3
+ import * as uuid from 'uuid';
4
+ import * as i1 from '@eui/components/shared';
5
+ import { BaseStatesDirective } from '@eui/components/shared';
4
6
  import * as i2 from '@angular/common';
5
7
  import { CommonModule } from '@angular/common';
6
8
  import * as i3 from '@eui/components/eui-icon';
7
9
  import { EuiIconModule } from '@eui/components/eui-icon';
8
- import * as i1 from '@eui/components/shared';
9
- import { BaseStatesDirective } from '@eui/components/shared';
10
10
  import * as i4 from '@eui/components/eui-label';
11
11
  import { EuiLabelModule } from '@eui/components/eui-label';
12
- import { coerceBoolean } from '@eui/base';
13
12
  import * as i5 from '@eui/components/eui-button';
14
13
  import { EuiButtonModule } from '@eui/components/eui-button';
15
14
  import * as i6 from '@ngx-translate/core';
16
15
  import { TranslateModule } from '@ngx-translate/core';
17
16
 
17
+ // -------
18
+ // IMPORTS
19
+ // -------
20
+ // Angular
21
+ // Sub content directives for projection - keep the component files tight
18
22
  /* eslint-disable */
19
23
  class EuiAlertTitleDirective {
20
24
  constructor() {
25
+ // host binding class assignment for the content directive, avoiding extra DOM templates wrapper
21
26
  this.class = 'eui-alert__title';
22
27
  }
23
28
  /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertTitleDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
@@ -31,121 +36,151 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
31
36
  args: ['class']
32
37
  }] } });
33
38
  /* eslint-enable */
39
+ // --------------
40
+ // MAIN COMPONENT
41
+ // --------------
34
42
  class EuiAlertComponent {
43
+ // class binding ALWAYS first (for binding against the baseStateDiretive)
35
44
  get cssClasses() {
36
- return this.getCssClasses();
45
+ return [
46
+ // Always refer to the baseStatesDirective
47
+ this.baseStatesDirective.getCssClasses('eui-alert'),
48
+ // own cmp state => reflected with the scss states
49
+ this.isMuted ? 'eui-alert--muted' : '',
50
+ this.isFocusable ? 'eui-alert--focusable' : '',
51
+ !this.isVisible ? 'eui-alert--hidden' : '',
52
+ ]
53
+ .join(' ')
54
+ .trim();
55
+ }
56
+ get ariaDescribedBy() {
57
+ return `alertContent-${this.uniqueId}`;
37
58
  }
59
+ get tabindex() {
60
+ return this.isFocusable ? '0' : '-1';
61
+ }
62
+ // CONSTRUCTOR
63
+ // -----------
38
64
  constructor(baseStatesDirective) {
39
65
  this.baseStatesDirective = baseStatesDirective;
66
+ // a11y bindings, ideally always on the host side / never in the sub wrapper within the HTML,
67
+ // cleaner and also attacking the host DOM element rather than its children
68
+ this.role = 'alert';
69
+ // for e2e unique attr to be defined / pass as input
40
70
  this.e2eAttr = 'eui-alert';
71
+ // component own states
72
+ // conventions if boolean : is / has prefix
73
+ // new v17 usage of transform / act like coerce and included in Angular natively now
41
74
  this.isMuted = false;
42
75
  this.isCloseable = false;
43
76
  this.isFocusable = false;
77
+ // Output event definition
78
+ // convention : verb(present)Component
44
79
  this.closeAlert = new EventEmitter();
80
+ // public variables used in the template
45
81
  this.isVisible = true;
46
82
  }
83
+ // HOOKS
84
+ // -----
47
85
  ngOnInit() {
48
86
  if (!this.baseStatesDirective.euiVariant) {
49
87
  this.baseStatesDirective.euiInfo = true;
50
88
  }
51
- this.randomStringId = this.generateUniqueId();
52
- }
53
- ngOnChanges() {
54
- this.setIcon();
55
- }
56
- ngAfterContentInit() {
57
- this.setIcon();
89
+ this.uniqueId = uuid.v4();
58
90
  }
91
+ // PUBLIC FUNCTIONS FROM TEMPLATE
92
+ // ------------------------------
59
93
  onCloseClick() {
60
94
  this.isVisible = false;
61
95
  this.closeAlert.emit();
62
96
  }
63
- getCssClasses() {
64
- return [
65
- this.baseStatesDirective.getCssClasses('eui-alert'),
66
- this.isMuted ? 'eui-alert--muted' : '',
67
- this.isFocusable ? 'eui-alert--focusable' : '',
68
- !this.isVisible ? 'eui-alert--hidden' : '',
69
- ]
70
- .join(' ')
71
- .trim();
72
- }
73
- setIcon() {
74
- this.alertIconType = 'eui-ecl-information';
75
- this.alertIconFillColor = 'info-100';
76
- if (this.baseStatesDirective.euiWarning) {
77
- this.alertIconType = 'eui-ecl-warning';
78
- this.alertIconFillColor = 'warning-100';
79
- }
80
- if (this.baseStatesDirective.euiDanger) {
81
- this.alertIconType = 'eui-ecl-error';
82
- this.alertIconFillColor = 'danger-100';
83
- }
84
- if (this.baseStatesDirective.euiSuccess) {
85
- this.alertIconType = 'eui-ecl-check-filled';
86
- this.alertIconFillColor = 'success-100';
87
- }
88
- if (this.baseStatesDirective.euiSecondary) {
89
- this.alertIconType = 'help-circle:sharp';
90
- this.alertIconFillColor = 'grey-100';
91
- }
92
- }
93
- generateUniqueId() {
94
- const dateStr = Date.now().toString(36);
95
- const randomStr = Math.random().toString(36).substring(2, 8); // start at index 2 to skip decimal point
96
- return `${dateStr}-${randomStr}`;
97
- }
98
97
  /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertComponent, deps: [{ token: i1.BaseStatesDirective }], target: i0.ɵɵFactoryTarget.Component }); }
99
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.0.2", type: EuiAlertComponent, selector: "div[euiAlert], eui-alert", inputs: { e2eAttr: "e2eAttr", isMuted: "isMuted", isCloseable: "isCloseable", isFocusable: "isFocusable" }, outputs: { closeAlert: "closeAlert" }, host: { properties: { "class": "this.cssClasses", "attr.data-e2e": "this.e2eAttr" } }, queries: [{ propertyName: "alertTitle", first: true, predicate: i0.forwardRef(() => EuiAlertTitleDirective), descendants: true }], usesOnChanges: true, hostDirectives: [{ directive: i1.BaseStatesDirective, inputs: ["euiSecondary", "euiSecondary", "euiSuccess", "euiSuccess", "euiInfo", "euiInfo", "euiWarning", "euiWarning", "euiDanger", "euiDanger", "euiVariant", "euiVariant"] }], ngImport: i0, template: "<div class=\"eui-alert__content-wrapper\" role=\"alert\" [tabindex]=\"isFocusable ? '0' : '-1'\" [attr.aria-describedby]=\"'alertContent-' + randomStringId\">\n <div class=\"eui-alert__type-container\" *ngIf=\"!isMuted\">\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"{{ alertIconType }}\" fillColor=\"{{ alertIconFillColor }}\"></eui-icon-svg>\n </div>\n <div id=\"alertContent-{{ randomStringId }}\" class=\"eui-alert__content\">\n <ng-container *ngIf=\"alertTitle; else alertNoTitle\">\n <ng-template *ngTemplateOutlet=\"contentWithTitle\"></ng-template>\n </ng-container>\n <ng-template #alertNoTitle>\n <ng-template *ngTemplateOutlet=\"contentNoTitle\"></ng-template>\n </ng-template>\n </div>\n</div>\n\n<ng-template #contentWithTitle>\n <div class=\"eui-alert__content-header eui-alert__content-header--with-title\">\n <ng-content select=\"eui-alert-title\"></ng-content>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n</ng-template>\n\n<ng-template #contentNoTitle>\n <div class=\"eui-alert__content-header\">\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n</ng-template>\n\n<ng-template #closeButton>\n <div class=\"eui-alert__close\">\n <button *ngIf=\"isCloseable\"\n euiButton\n euiBasicButton\n euiPrimary\n euiSizeS\n aria-label=\"Close alert button\"\n class=\"eui-u-ml-s\"\n (click)=\"onCloseClick()\">\n <span euiLabel class=\"eui-u-display-hidden-mobile\">{{ 'eui.CLOSE' | translate }}</span>\n <eui-icon-svg icon=\"eui-ecl-close\" class=\"eui-u-ml-xs\"></eui-icon-svg>\n </button>\n </div>\n</ng-template>\n\n<ng-template #content>\n <div class=\"eui-u-display-block\" [class.eui-u-mt-xs]=\"alertTitle\">\n <ng-content></ng-content>\n </div>\n</ng-template>\n", styles: [".eui-alert{--_border-color: var(--eui-alert-border-color, var(--eui-base-color-info-100));--_color: var(--eui-alert-color, var(--eui-base-color-info-130));--_bg-color: var(--eui-alert-type-container-bg-color, var(--eui-base-color-info-10))}.eui-alert{display:flex;background-color:var(--_bg-color);background-position:var(--eui-base-spacing-s);background-repeat:no-repeat;position:relative;border-left:var(--eui-base-spacing-2xs) solid var(--_border-color);border-radius:var(--eui-base-border-radius)}.eui-alert__type-container{align-items:center;display:flex;margin-right:var(--eui-base-spacing-s);height:var(--eui-base-spacing-l)}.eui-alert__content{display:flex;flex-direction:column;width:100%}.eui-alert__content-header{align-items:center;display:flex;flex:1 1 100%;justify-content:space-between;width:100%}.eui-alert__content-header--with-title{min-height:var(--eui-base-spacing-l)}.eui-alert__title{color:var(--_color);font:normal normal 400 1rem/1.25rem var(--eui-base-font-family);font-weight:700}.eui-alert__content-wrapper{display:flex;flex-basis:auto;flex-shrink:1;overflow:auto;padding:var(--eui-base-spacing-m);width:100%}.eui-alert__content-wrapper::-webkit-scrollbar{display:inherit;height:8px;width:8px;background-color:var(--eui-base-color-grey-5)}.eui-alert__content-wrapper::-webkit-scrollbar-thumb{background-color:var(--eui-base-color-grey-20);border-radius:5rem}.eui-alert__content-wrapper::-webkit-scrollbar-thumb:hover{background-color:var(--eui-base-color-grey-50)}.eui-alert__content-wrapper::-webkit-scrollbar-track{background-color:var(--eui-base-color-grey-5);border-radius:0}.eui-alert__close{align-self:flex-start;display:flex;margin-left:auto}.eui-alert__close:hover{text-decoration:underline}.eui-alert--info{--_border-color: var(--eui-base-color-info-100);--_bg-color: var(--eui-base-color-info-10);--_color: var(--eui-base-color-info-130)}.eui-alert--success{--_border-color: var(--eui-base-color-success-100);--_bg-color: var(--eui-base-color-success-10);--_color: var(--eui-base-color-success-130)}.eui-alert--danger{--_border-color: var(--eui-base-color-danger-100);--_bg-color: var(--eui-base-color-danger-10);--_color: var(--eui-base-color-danger-130)}.eui-alert--warning{--_border-color: var(--eui-base-color-warning-100);--_bg-color: var(--eui-base-color-warning-10);--_color: var(--eui-base-color-warning-140)}.eui-alert--hidden{display:none}.eui-alert--focusable:active:not([readonly]),.eui-alert--focusable:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}.eui-alert--focusable [tabindex=\"0\"]:active:not([readonly]),.eui-alert--focusable [tabindex=\"0\"]:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i3.EuiIconSvgComponent, selector: "eui-icon-svg, span[euiIconSvg], i[euiIconSvg]", inputs: ["icon", "size", "fillColor", "set", "ariaLabelledby", "role", "style", "iconUrl", "transform", "aria-label", "ariaHidden", "focusable", "isLoading"] }, { kind: "component", type: i4.EuiLabelComponent, selector: "label[euiLabel], span[euiLabel], div[euiLabel], a[euiLabel], eui-label, label[euiSublabel], span[euiSublabel], div[euiSublabel], a[euiSublabel], eui-sublabel", inputs: ["euiRequired", "euiReadonly", "euiSublabel"] }, { kind: "component", type: i5.EuiButtonComponent, selector: "button[euiButton], a[euiButton]", inputs: ["e2eAttr", "id", "euiBasicButton", "euiButtonCall", "euiBlockButton", "isLoading", "euiIconButton", "euiLineWrap"], outputs: ["buttonClick"] }, { kind: "pipe", type: i6.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
98
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.0.2", type: EuiAlertComponent, selector: "div[euiAlert], eui-alert", inputs: { ariaDescribedBy: "ariaDescribedBy", e2eAttr: "e2eAttr", isMuted: ["isMuted", "isMuted", booleanAttribute], isCloseable: ["isCloseable", "isCloseable", booleanAttribute], isFocusable: ["isFocusable", "isFocusable", booleanAttribute] }, outputs: { closeAlert: "closeAlert" }, host: { properties: { "class": "this.cssClasses", "attr.role": "this.role", "attr.aria-describedby": "this.ariaDescribedBy", "attr.tabindex": "this.tabindex", "attr.data-e2e": "this.e2eAttr" } }, queries: [{ propertyName: "alertTitle", first: true, predicate: i0.forwardRef(() => EuiAlertTitleDirective), descendants: true }], hostDirectives: [{ directive: i1.BaseStatesDirective, inputs: ["euiSuccess", "euiSuccess", "euiInfo", "euiInfo", "euiWarning", "euiWarning", "euiDanger", "euiDanger", "euiVariant", "euiVariant"] }], ngImport: i0, template: "@if (!isMuted) {\n <div class=\"eui-alert__type-container\">\n @switch(baseStatesDirective.euiVariant) {\n @case('info') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-information\" fillColor=\"info-100\"></eui-icon-svg>\n }\n @case('success') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-check-filled\" fillColor=\"success-100\"></eui-icon-svg>\n }\n @case('warning') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-warning\" fillColor=\"warning-100\"></eui-icon-svg>\n }\n @case('danger') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-error\" fillColor=\"danger-100\"></eui-icon-svg>\n }\n }\n </div>\n}\n\n<div id=\"{{ ariaDescribedBy }}\" class=\"eui-alert__content\">\n @if (alertTitle) {\n <ng-template *ngTemplateOutlet=\"contentWithTitle\"></ng-template>\n } @else {\n <ng-template *ngTemplateOutlet=\"contentNoTitle\"></ng-template>\n }\n</div>\n\n<ng-template #contentWithTitle>\n <div class=\"eui-alert__content-header eui-alert__content-header--with-title\">\n <ng-content select=\"eui-alert-title\"></ng-content>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n</ng-template>\n\n<ng-template #contentNoTitle>\n <div class=\"eui-alert__content-header\">\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n</ng-template>\n\n<ng-template #closeButton>\n <div class=\"eui-alert__close\">\n <button *ngIf=\"isCloseable\"\n euiButton\n euiBasicButton\n euiPrimary\n euiSizeS\n aria-label=\"Close alert button\"\n class=\"eui-u-ml-s\"\n (click)=\"onCloseClick()\">\n <span euiLabel class=\"eui-u-display-hidden-mobile\">{{ 'eui.CLOSE' | translate }}</span>\n <eui-icon-svg icon=\"eui-ecl-close\" class=\"eui-u-ml-xs\"></eui-icon-svg>\n </button>\n </div>\n</ng-template>\n\n<ng-template #content>\n <div [class.eui-u-mt-xs]=\"alertTitle\">\n <ng-content></ng-content>\n </div>\n</ng-template>\n", styles: [".eui-alert{--_border-color: var(--eui-alert-border-color, var(--eui-base-color-info-100));--_color: var(--eui-alert-color, var(--eui-base-color-info-130));--_bg-color: var(--eui-alert-type-container-bg-color, var(--eui-base-color-info-10))}.eui-alert{display:flex;background-color:var(--_bg-color);background-position:var(--eui-base-spacing-s);background-repeat:no-repeat;position:relative;border-left:var(--eui-base-spacing-2xs) solid var(--_border-color);border-radius:var(--eui-base-border-radius);flex-basis:auto;flex-shrink:1;overflow:auto;padding:var(--eui-base-spacing-m);width:100%}.eui-alert::-webkit-scrollbar{display:inherit;height:8px;width:8px;background-color:var(--eui-base-color-grey-5)}.eui-alert::-webkit-scrollbar-thumb{background-color:var(--eui-base-color-grey-20);border-radius:5rem}.eui-alert::-webkit-scrollbar-thumb:hover{background-color:var(--eui-base-color-grey-50)}.eui-alert::-webkit-scrollbar-track{background-color:var(--eui-base-color-grey-5);border-radius:0}.eui-alert__type-container{align-items:center;display:flex;margin-right:var(--eui-base-spacing-s);height:var(--eui-base-spacing-l)}.eui-alert__content{display:flex;flex-direction:column;width:100%}.eui-alert__content-header{align-items:center;display:flex;flex:1 1 100%;justify-content:space-between;width:100%}.eui-alert__content-header--with-title{min-height:var(--eui-base-spacing-l)}.eui-alert__title{color:var(--_color);font:normal normal 400 1rem/1.25rem var(--eui-base-font-family);font-weight:700}.eui-alert__close{align-self:flex-start;display:flex;margin-left:auto}.eui-alert__close:hover{text-decoration:underline}.eui-alert--info{--_border-color: var(--eui-base-color-info-100);--_bg-color: var(--eui-base-color-info-10);--_color: var(--eui-base-color-info-130)}.eui-alert--success{--_border-color: var(--eui-base-color-success-100);--_bg-color: var(--eui-base-color-success-10);--_color: var(--eui-base-color-success-130)}.eui-alert--danger{--_border-color: var(--eui-base-color-danger-100);--_bg-color: var(--eui-base-color-danger-10);--_color: var(--eui-base-color-danger-130)}.eui-alert--warning{--_border-color: var(--eui-base-color-warning-100);--_bg-color: var(--eui-base-color-warning-10);--_color: var(--eui-base-color-warning-140)}.eui-alert--hidden{display:none}.eui-alert--focusable:active:not([readonly]),.eui-alert--focusable:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}.eui-alert--focusable [tabindex=\"0\"]:active:not([readonly]),.eui-alert--focusable [tabindex=\"0\"]:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i3.EuiIconSvgComponent, selector: "eui-icon-svg, span[euiIconSvg], i[euiIconSvg]", inputs: ["icon", "size", "fillColor", "set", "ariaLabelledby", "role", "style", "iconUrl", "transform", "aria-label", "ariaHidden", "focusable", "isLoading"] }, { kind: "component", type: i4.EuiLabelComponent, selector: "label[euiLabel], span[euiLabel], div[euiLabel], a[euiLabel], eui-label, label[euiSublabel], span[euiSublabel], div[euiSublabel], a[euiSublabel], eui-sublabel", inputs: ["euiRequired", "euiReadonly", "euiSublabel"] }, { kind: "component", type: i5.EuiButtonComponent, selector: "button[euiButton], a[euiButton]", inputs: ["e2eAttr", "id", "euiBasicButton", "euiButtonCall", "euiBlockButton", "isLoading", "euiIconButton", "euiLineWrap"], outputs: ["buttonClick"] }, { kind: "pipe", type: i6.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
100
99
  }
101
- __decorate([
102
- coerceBoolean
103
- ], EuiAlertComponent.prototype, "isMuted", void 0);
104
- __decorate([
105
- coerceBoolean
106
- ], EuiAlertComponent.prototype, "isCloseable", void 0);
107
- __decorate([
108
- coerceBoolean
109
- ], EuiAlertComponent.prototype, "isFocusable", void 0);
110
100
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertComponent, decorators: [{
111
101
  type: Component,
112
102
  args: [{ selector: 'div[euiAlert], eui-alert', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, hostDirectives: [
113
103
  {
114
104
  directive: BaseStatesDirective,
115
- inputs: ['euiSecondary', 'euiSuccess', 'euiInfo', 'euiWarning', 'euiDanger', 'euiVariant'],
105
+ inputs: [
106
+ 'euiSuccess',
107
+ 'euiInfo',
108
+ 'euiWarning',
109
+ 'euiDanger',
110
+ // important to add the variant per type : euiVariant for colors / euiSizeVariant for sizes
111
+ 'euiVariant',
112
+ ],
116
113
  },
117
- ], template: "<div class=\"eui-alert__content-wrapper\" role=\"alert\" [tabindex]=\"isFocusable ? '0' : '-1'\" [attr.aria-describedby]=\"'alertContent-' + randomStringId\">\n <div class=\"eui-alert__type-container\" *ngIf=\"!isMuted\">\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"{{ alertIconType }}\" fillColor=\"{{ alertIconFillColor }}\"></eui-icon-svg>\n </div>\n <div id=\"alertContent-{{ randomStringId }}\" class=\"eui-alert__content\">\n <ng-container *ngIf=\"alertTitle; else alertNoTitle\">\n <ng-template *ngTemplateOutlet=\"contentWithTitle\"></ng-template>\n </ng-container>\n <ng-template #alertNoTitle>\n <ng-template *ngTemplateOutlet=\"contentNoTitle\"></ng-template>\n </ng-template>\n </div>\n</div>\n\n<ng-template #contentWithTitle>\n <div class=\"eui-alert__content-header eui-alert__content-header--with-title\">\n <ng-content select=\"eui-alert-title\"></ng-content>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n</ng-template>\n\n<ng-template #contentNoTitle>\n <div class=\"eui-alert__content-header\">\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n</ng-template>\n\n<ng-template #closeButton>\n <div class=\"eui-alert__close\">\n <button *ngIf=\"isCloseable\"\n euiButton\n euiBasicButton\n euiPrimary\n euiSizeS\n aria-label=\"Close alert button\"\n class=\"eui-u-ml-s\"\n (click)=\"onCloseClick()\">\n <span euiLabel class=\"eui-u-display-hidden-mobile\">{{ 'eui.CLOSE' | translate }}</span>\n <eui-icon-svg icon=\"eui-ecl-close\" class=\"eui-u-ml-xs\"></eui-icon-svg>\n </button>\n </div>\n</ng-template>\n\n<ng-template #content>\n <div class=\"eui-u-display-block\" [class.eui-u-mt-xs]=\"alertTitle\">\n <ng-content></ng-content>\n </div>\n</ng-template>\n", styles: [".eui-alert{--_border-color: var(--eui-alert-border-color, var(--eui-base-color-info-100));--_color: var(--eui-alert-color, var(--eui-base-color-info-130));--_bg-color: var(--eui-alert-type-container-bg-color, var(--eui-base-color-info-10))}.eui-alert{display:flex;background-color:var(--_bg-color);background-position:var(--eui-base-spacing-s);background-repeat:no-repeat;position:relative;border-left:var(--eui-base-spacing-2xs) solid var(--_border-color);border-radius:var(--eui-base-border-radius)}.eui-alert__type-container{align-items:center;display:flex;margin-right:var(--eui-base-spacing-s);height:var(--eui-base-spacing-l)}.eui-alert__content{display:flex;flex-direction:column;width:100%}.eui-alert__content-header{align-items:center;display:flex;flex:1 1 100%;justify-content:space-between;width:100%}.eui-alert__content-header--with-title{min-height:var(--eui-base-spacing-l)}.eui-alert__title{color:var(--_color);font:normal normal 400 1rem/1.25rem var(--eui-base-font-family);font-weight:700}.eui-alert__content-wrapper{display:flex;flex-basis:auto;flex-shrink:1;overflow:auto;padding:var(--eui-base-spacing-m);width:100%}.eui-alert__content-wrapper::-webkit-scrollbar{display:inherit;height:8px;width:8px;background-color:var(--eui-base-color-grey-5)}.eui-alert__content-wrapper::-webkit-scrollbar-thumb{background-color:var(--eui-base-color-grey-20);border-radius:5rem}.eui-alert__content-wrapper::-webkit-scrollbar-thumb:hover{background-color:var(--eui-base-color-grey-50)}.eui-alert__content-wrapper::-webkit-scrollbar-track{background-color:var(--eui-base-color-grey-5);border-radius:0}.eui-alert__close{align-self:flex-start;display:flex;margin-left:auto}.eui-alert__close:hover{text-decoration:underline}.eui-alert--info{--_border-color: var(--eui-base-color-info-100);--_bg-color: var(--eui-base-color-info-10);--_color: var(--eui-base-color-info-130)}.eui-alert--success{--_border-color: var(--eui-base-color-success-100);--_bg-color: var(--eui-base-color-success-10);--_color: var(--eui-base-color-success-130)}.eui-alert--danger{--_border-color: var(--eui-base-color-danger-100);--_bg-color: var(--eui-base-color-danger-10);--_color: var(--eui-base-color-danger-130)}.eui-alert--warning{--_border-color: var(--eui-base-color-warning-100);--_bg-color: var(--eui-base-color-warning-10);--_color: var(--eui-base-color-warning-140)}.eui-alert--hidden{display:none}.eui-alert--focusable:active:not([readonly]),.eui-alert--focusable:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}.eui-alert--focusable [tabindex=\"0\"]:active:not([readonly]),.eui-alert--focusable [tabindex=\"0\"]:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}\n"] }]
114
+ ], template: "@if (!isMuted) {\n <div class=\"eui-alert__type-container\">\n @switch(baseStatesDirective.euiVariant) {\n @case('info') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-information\" fillColor=\"info-100\"></eui-icon-svg>\n }\n @case('success') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-check-filled\" fillColor=\"success-100\"></eui-icon-svg>\n }\n @case('warning') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-warning\" fillColor=\"warning-100\"></eui-icon-svg>\n }\n @case('danger') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-error\" fillColor=\"danger-100\"></eui-icon-svg>\n }\n }\n </div>\n}\n\n<div id=\"{{ ariaDescribedBy }}\" class=\"eui-alert__content\">\n @if (alertTitle) {\n <ng-template *ngTemplateOutlet=\"contentWithTitle\"></ng-template>\n } @else {\n <ng-template *ngTemplateOutlet=\"contentNoTitle\"></ng-template>\n }\n</div>\n\n<ng-template #contentWithTitle>\n <div class=\"eui-alert__content-header eui-alert__content-header--with-title\">\n <ng-content select=\"eui-alert-title\"></ng-content>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n</ng-template>\n\n<ng-template #contentNoTitle>\n <div class=\"eui-alert__content-header\">\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n</ng-template>\n\n<ng-template #closeButton>\n <div class=\"eui-alert__close\">\n <button *ngIf=\"isCloseable\"\n euiButton\n euiBasicButton\n euiPrimary\n euiSizeS\n aria-label=\"Close alert button\"\n class=\"eui-u-ml-s\"\n (click)=\"onCloseClick()\">\n <span euiLabel class=\"eui-u-display-hidden-mobile\">{{ 'eui.CLOSE' | translate }}</span>\n <eui-icon-svg icon=\"eui-ecl-close\" class=\"eui-u-ml-xs\"></eui-icon-svg>\n </button>\n </div>\n</ng-template>\n\n<ng-template #content>\n <div [class.eui-u-mt-xs]=\"alertTitle\">\n <ng-content></ng-content>\n </div>\n</ng-template>\n", styles: [".eui-alert{--_border-color: var(--eui-alert-border-color, var(--eui-base-color-info-100));--_color: var(--eui-alert-color, var(--eui-base-color-info-130));--_bg-color: var(--eui-alert-type-container-bg-color, var(--eui-base-color-info-10))}.eui-alert{display:flex;background-color:var(--_bg-color);background-position:var(--eui-base-spacing-s);background-repeat:no-repeat;position:relative;border-left:var(--eui-base-spacing-2xs) solid var(--_border-color);border-radius:var(--eui-base-border-radius);flex-basis:auto;flex-shrink:1;overflow:auto;padding:var(--eui-base-spacing-m);width:100%}.eui-alert::-webkit-scrollbar{display:inherit;height:8px;width:8px;background-color:var(--eui-base-color-grey-5)}.eui-alert::-webkit-scrollbar-thumb{background-color:var(--eui-base-color-grey-20);border-radius:5rem}.eui-alert::-webkit-scrollbar-thumb:hover{background-color:var(--eui-base-color-grey-50)}.eui-alert::-webkit-scrollbar-track{background-color:var(--eui-base-color-grey-5);border-radius:0}.eui-alert__type-container{align-items:center;display:flex;margin-right:var(--eui-base-spacing-s);height:var(--eui-base-spacing-l)}.eui-alert__content{display:flex;flex-direction:column;width:100%}.eui-alert__content-header{align-items:center;display:flex;flex:1 1 100%;justify-content:space-between;width:100%}.eui-alert__content-header--with-title{min-height:var(--eui-base-spacing-l)}.eui-alert__title{color:var(--_color);font:normal normal 400 1rem/1.25rem var(--eui-base-font-family);font-weight:700}.eui-alert__close{align-self:flex-start;display:flex;margin-left:auto}.eui-alert__close:hover{text-decoration:underline}.eui-alert--info{--_border-color: var(--eui-base-color-info-100);--_bg-color: var(--eui-base-color-info-10);--_color: var(--eui-base-color-info-130)}.eui-alert--success{--_border-color: var(--eui-base-color-success-100);--_bg-color: var(--eui-base-color-success-10);--_color: var(--eui-base-color-success-130)}.eui-alert--danger{--_border-color: var(--eui-base-color-danger-100);--_bg-color: var(--eui-base-color-danger-10);--_color: var(--eui-base-color-danger-130)}.eui-alert--warning{--_border-color: var(--eui-base-color-warning-100);--_bg-color: var(--eui-base-color-warning-10);--_color: var(--eui-base-color-warning-140)}.eui-alert--hidden{display:none}.eui-alert--focusable:active:not([readonly]),.eui-alert--focusable:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}.eui-alert--focusable [tabindex=\"0\"]:active:not([readonly]),.eui-alert--focusable [tabindex=\"0\"]:focus:not([readonly]){outline:2px solid var(--eui-base-color-accessible-focus);outline-offset:-2px;transition:none}\n"] }]
118
115
  }], ctorParameters: () => [{ type: i1.BaseStatesDirective }], propDecorators: { cssClasses: [{
119
116
  type: HostBinding,
120
117
  args: ['class']
118
+ }], role: [{
119
+ type: HostBinding,
120
+ args: ['attr.role']
121
+ }], ariaDescribedBy: [{
122
+ type: HostBinding,
123
+ args: ['attr.aria-describedby']
124
+ }, {
125
+ type: Input
126
+ }], tabindex: [{
127
+ type: HostBinding,
128
+ args: ['attr.tabindex']
121
129
  }], e2eAttr: [{
122
130
  type: HostBinding,
123
131
  args: ['attr.data-e2e']
124
132
  }, {
125
133
  type: Input
126
134
  }], isMuted: [{
127
- type: Input
135
+ type: Input,
136
+ args: [{ transform: booleanAttribute }]
128
137
  }], isCloseable: [{
129
- type: Input
138
+ type: Input,
139
+ args: [{ transform: booleanAttribute }]
130
140
  }], isFocusable: [{
131
- type: Input
141
+ type: Input,
142
+ args: [{ transform: booleanAttribute }]
132
143
  }], closeAlert: [{
133
144
  type: Output
134
145
  }], alertTitle: [{
135
146
  type: ContentChild,
136
147
  args: [forwardRef(() => EuiAlertTitleDirective), { static: false }]
137
148
  }] } });
149
+
150
+ // Angular
151
+ const COMPONENTS = [
152
+ EuiAlertComponent,
153
+ EuiAlertTitleDirective,
154
+ ];
155
+ // component main module
156
+ // Always same naming convention for all : Eui[CMP_NAME]Module
138
157
  class EuiAlertModule {
139
158
  /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
140
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertModule, declarations: [EuiAlertComponent, EuiAlertTitleDirective], imports: [CommonModule, TranslateModule, EuiIconModule, EuiLabelModule, EuiButtonModule], exports: [EuiAlertComponent, EuiAlertTitleDirective] }); }
141
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertModule, imports: [CommonModule, TranslateModule, EuiIconModule, EuiLabelModule, EuiButtonModule] }); }
159
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertModule, declarations: [EuiAlertComponent,
160
+ EuiAlertTitleDirective], imports: [
161
+ // Angular and 3rd party
162
+ CommonModule, TranslateModule,
163
+ // eUI internals
164
+ BaseStatesDirective,
165
+ EuiIconModule, EuiLabelModule, EuiButtonModule], exports: [EuiAlertComponent,
166
+ EuiAlertTitleDirective] }); }
167
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertModule, imports: [
168
+ // Angular and 3rd party
169
+ CommonModule, TranslateModule,
170
+ EuiIconModule, EuiLabelModule, EuiButtonModule] }); }
142
171
  }
143
172
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: EuiAlertModule, decorators: [{
144
173
  type: NgModule,
145
174
  args: [{
146
- imports: [CommonModule, TranslateModule, EuiIconModule, EuiLabelModule, EuiButtonModule],
147
- declarations: [EuiAlertComponent, EuiAlertTitleDirective],
148
- exports: [EuiAlertComponent, EuiAlertTitleDirective],
175
+ imports: [
176
+ // Angular and 3rd party
177
+ CommonModule, TranslateModule,
178
+ // eUI internals
179
+ BaseStatesDirective,
180
+ EuiIconModule, EuiLabelModule, EuiButtonModule,
181
+ ],
182
+ declarations: [...COMPONENTS],
183
+ exports: [...COMPONENTS],
149
184
  }]
150
185
  }] });
151
186
 
@@ -1 +1 @@
1
- {"version":3,"file":"eui-components-eui-alert.mjs","sources":["../../eui-alert/eui-alert.component.ts","../../eui-alert/eui-alert.component.html","../../eui-alert/eui-components-eui-alert.ts"],"sourcesContent":["import {\n NgModule,\n Component,\n HostBinding,\n EventEmitter,\n Input,\n ChangeDetectionStrategy,\n ViewEncapsulation,\n AfterContentInit,\n Output,\n OnChanges,\n OnInit,\n Directive,\n ContentChild,\n forwardRef,\n QueryList,\n} from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { BooleanInput } from '@angular/cdk/coercion';\n\nimport { EuiIconModule } from '@eui/components/eui-icon';\nimport { BaseStatesDirective } from '@eui/components/shared';\nimport { EuiLabelModule } from '@eui/components/eui-label';\nimport { coerceBoolean } from '@eui/base';\nimport { EuiButtonModule } from '@eui/components/eui-button';\nimport { TranslateModule } from '@ngx-translate/core';\n\n/* eslint-disable */\n@Directive({selector: 'eui-alert-title'})\nexport class EuiAlertTitleDirective {\n @HostBinding('class') class = 'eui-alert__title';\n}\n/* eslint-enable */\n\n@Component({\n templateUrl: './eui-alert.component.html',\n selector: 'div[euiAlert], eui-alert',\n styleUrls: ['./styles/_index.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n hostDirectives: [\n {\n directive: BaseStatesDirective,\n inputs: ['euiSecondary', 'euiSuccess', 'euiInfo', 'euiWarning', 'euiDanger', 'euiVariant'],\n },\n ],\n})\nexport class EuiAlertComponent implements OnInit, OnChanges, AfterContentInit {\n @HostBinding('class')\n public get cssClasses(): string {\n return this.getCssClasses();\n }\n @HostBinding('attr.data-e2e')\n @Input()\n e2eAttr = 'eui-alert';\n\n @Input()\n @coerceBoolean\n isMuted: BooleanInput = false;\n @Input()\n @coerceBoolean\n isCloseable: BooleanInput = false;\n @Input()\n @coerceBoolean\n isFocusable: BooleanInput = false;\n\n @Output() closeAlert = new EventEmitter<null>();\n\n @ContentChild(forwardRef(() => EuiAlertTitleDirective), { static: false }) alertTitle: QueryList<EuiAlertTitleDirective>;\n\n isVisible = true;\n alertIconType: string;\n alertIconFillColor: string;\n randomStringId: string;\n\n constructor(public baseStatesDirective: BaseStatesDirective) {}\n\n ngOnInit(): void {\n if (!this.baseStatesDirective.euiVariant) {\n this.baseStatesDirective.euiInfo = true;\n }\n this.randomStringId = this.generateUniqueId();\n }\n\n ngOnChanges(): void {\n this.setIcon();\n }\n\n ngAfterContentInit(): void {\n this.setIcon();\n }\n\n onCloseClick(): void {\n this.isVisible = false;\n this.closeAlert.emit();\n }\n\n private getCssClasses(): string {\n return [\n this.baseStatesDirective.getCssClasses('eui-alert'),\n this.isMuted ? 'eui-alert--muted' : '',\n this.isFocusable ? 'eui-alert--focusable': '',\n !this.isVisible ? 'eui-alert--hidden' : '',\n ]\n .join(' ')\n .trim();\n }\n\n private setIcon(): void {\n this.alertIconType = 'eui-ecl-information';\n this.alertIconFillColor = 'info-100';\n\n if (this.baseStatesDirective.euiWarning) {\n this.alertIconType = 'eui-ecl-warning';\n this.alertIconFillColor = 'warning-100';\n }\n if (this.baseStatesDirective.euiDanger) {\n this.alertIconType = 'eui-ecl-error';\n this.alertIconFillColor = 'danger-100';\n }\n if (this.baseStatesDirective.euiSuccess) {\n this.alertIconType = 'eui-ecl-check-filled';\n this.alertIconFillColor = 'success-100';\n }\n if (this.baseStatesDirective.euiSecondary) {\n this.alertIconType = 'help-circle:sharp';\n this.alertIconFillColor = 'grey-100';\n }\n }\n\n private generateUniqueId(): string {\n const dateStr = Date.now().toString(36);\n const randomStr = Math.random().toString(36).substring(2, 8); // start at index 2 to skip decimal point\n return `${dateStr}-${randomStr}`;\n }\n}\n\n@NgModule({\n imports: [CommonModule, TranslateModule, EuiIconModule, EuiLabelModule, EuiButtonModule],\n declarations: [EuiAlertComponent, EuiAlertTitleDirective],\n exports: [EuiAlertComponent, EuiAlertTitleDirective],\n})\nexport class EuiAlertModule {}\n","<div class=\"eui-alert__content-wrapper\" role=\"alert\" [tabindex]=\"isFocusable ? '0' : '-1'\" [attr.aria-describedby]=\"'alertContent-' + randomStringId\">\n <div class=\"eui-alert__type-container\" *ngIf=\"!isMuted\">\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"{{ alertIconType }}\" fillColor=\"{{ alertIconFillColor }}\"></eui-icon-svg>\n </div>\n <div id=\"alertContent-{{ randomStringId }}\" class=\"eui-alert__content\">\n <ng-container *ngIf=\"alertTitle; else alertNoTitle\">\n <ng-template *ngTemplateOutlet=\"contentWithTitle\"></ng-template>\n </ng-container>\n <ng-template #alertNoTitle>\n <ng-template *ngTemplateOutlet=\"contentNoTitle\"></ng-template>\n </ng-template>\n </div>\n</div>\n\n<ng-template #contentWithTitle>\n <div class=\"eui-alert__content-header eui-alert__content-header--with-title\">\n <ng-content select=\"eui-alert-title\"></ng-content>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n</ng-template>\n\n<ng-template #contentNoTitle>\n <div class=\"eui-alert__content-header\">\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n</ng-template>\n\n<ng-template #closeButton>\n <div class=\"eui-alert__close\">\n <button *ngIf=\"isCloseable\"\n euiButton\n euiBasicButton\n euiPrimary\n euiSizeS\n aria-label=\"Close alert button\"\n class=\"eui-u-ml-s\"\n (click)=\"onCloseClick()\">\n <span euiLabel class=\"eui-u-display-hidden-mobile\">{{ 'eui.CLOSE' | translate }}</span>\n <eui-icon-svg icon=\"eui-ecl-close\" class=\"eui-u-ml-xs\"></eui-icon-svg>\n </button>\n </div>\n</ng-template>\n\n<ng-template #content>\n <div class=\"eui-u-display-block\" [class.eui-u-mt-xs]=\"alertTitle\">\n <ng-content></ng-content>\n </div>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AA2BA;MAEa,sBAAsB,CAAA;AADnC,IAAA,WAAA,GAAA;QAE0B,IAAK,CAAA,KAAA,GAAG,kBAAkB,CAAC;AACpD,KAAA;iIAFY,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,C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AAc,CAAA;iIAAd,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;AAAd,uBAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,iBA/Fd,iBAAiB,EAlBjB,sBAAsB,CAAA,EAAA,OAAA,EAAA,CA6GrB,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,cAAc,EAAE,eAAe,CA3F9E,EAAA,OAAA,EAAA,CAAA,iBAAiB,EAlBjB,sBAAsB,CAAA,EAAA,CAAA,CAAA,EAAA;kIAiHtB,cAAc,EAAA,OAAA,EAAA,CAJb,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,cAAc,EAAE,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAI9E,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,cAAc,EAAE,eAAe,CAAC;AACxF,oBAAA,YAAY,EAAE,CAAC,iBAAiB,EAAE,sBAAsB,CAAC;AACzD,oBAAA,OAAO,EAAE,CAAC,iBAAiB,EAAE,sBAAsB,CAAC;AACvD,iBAAA,CAAA;;;AE7ID;;AAEG;;;;"}
1
+ {"version":3,"file":"eui-components-eui-alert.mjs","sources":["../../eui-alert/eui-alert.component.ts","../../eui-alert/eui-alert.component.html","../../eui-alert/eui-alert.module.ts","../../eui-alert/eui-components-eui-alert.ts"],"sourcesContent":["// -------\n// IMPORTS\n// -------\n\n// Angular\nimport {\n Component,\n HostBinding,\n EventEmitter,\n Input,\n ChangeDetectionStrategy,\n ViewEncapsulation,\n Output,\n OnInit,\n Directive,\n ContentChild,\n forwardRef,\n QueryList,\n booleanAttribute,\n} from '@angular/core';\n\n// 3rd party\nimport * as uuid from 'uuid';\n\n// eUI internals\nimport { BaseStatesDirective } from '@eui/components/shared';\n\n// Sub content directives for projection - keep the component files tight\n\n/* eslint-disable */\n@Directive({ selector: 'eui-alert-title' })\nexport class EuiAlertTitleDirective {\n // host binding class assignment for the content directive, avoiding extra DOM templates wrapper\n @HostBinding('class') class = 'eui-alert__title';\n}\n/* eslint-enable */\n\n// --------------\n// MAIN COMPONENT\n// --------------\n@Component({\n templateUrl: './eui-alert.component.html', // respect component name convention\n selector: 'div[euiAlert], eui-alert', // if needed multi selectors\n styleUrl: './styles/_index.scss', // respect styles/_index.scss only import\n changeDetection: ChangeDetectionStrategy.OnPush, // OnPush by default for all\n encapsulation: ViewEncapsulation.None, // encapsulation.None by default for all\n\n // use of baseStatesDirective : defined here what the component needs as base props => reflected in styles / states.scss\n hostDirectives: [\n {\n directive: BaseStatesDirective,\n inputs: [\n 'euiSuccess',\n 'euiInfo',\n 'euiWarning',\n 'euiDanger',\n // important to add the variant per type : euiVariant for colors / euiSizeVariant for sizes\n 'euiVariant',\n ],\n },\n ],\n})\nexport class EuiAlertComponent implements OnInit {\n // class binding ALWAYS first (for binding against the baseStateDiretive)\n @HostBinding('class')\n public get cssClasses(): string {\n return [\n // Always refer to the baseStatesDirective\n this.baseStatesDirective.getCssClasses('eui-alert'),\n\n // own cmp state => reflected with the scss states\n this.isMuted ? 'eui-alert--muted' : '',\n this.isFocusable ? 'eui-alert--focusable' : '',\n !this.isVisible ? 'eui-alert--hidden' : '',\n ]\n .join(' ')\n .trim();\n }\n\n // a11y bindings, ideally always on the host side / never in the sub wrapper within the HTML,\n // cleaner and also attacking the host DOM element rather than its children\n @HostBinding('attr.role') role = 'alert';\n @HostBinding('attr.aria-describedby')\n @Input()\n get ariaDescribedBy(): string {\n return `alertContent-${this.uniqueId}`;\n }\n @HostBinding('attr.tabindex')\n get tabindex(): string {\n return this.isFocusable ? '0' : '-1';\n }\n\n // for e2e unique attr to be defined / pass as input\n @HostBinding('attr.data-e2e')\n @Input()\n e2eAttr = 'eui-alert';\n\n // component own states\n // conventions if boolean : is / has prefix\n // new v17 usage of transform / act like coerce and included in Angular natively now\n @Input({ transform: booleanAttribute }) isMuted = false;\n @Input({ transform: booleanAttribute }) isCloseable = false;\n @Input({ transform: booleanAttribute }) isFocusable = false;\n\n // Output event definition\n // convention : verb(present)Component\n @Output() closeAlert = new EventEmitter<null>();\n\n // contentChild def / viewChild defs if needed\n @ContentChild(forwardRef(() => EuiAlertTitleDirective), { static: false }) alertTitle: QueryList<EuiAlertTitleDirective>;\n\n // public variables used in the template\n isVisible = true;\n alertIconType: string;\n alertIconFillColor: string;\n\n private uniqueId: string;\n\n // CONSTRUCTOR\n // -----------\n constructor(public baseStatesDirective: BaseStatesDirective) {}\n\n // HOOKS\n // -----\n ngOnInit(): void {\n if (!this.baseStatesDirective.euiVariant) {\n this.baseStatesDirective.euiInfo = true;\n }\n this.uniqueId = uuid.v4();\n }\n\n // PUBLIC FUNCTIONS FROM TEMPLATE\n // ------------------------------\n onCloseClick(): void {\n this.isVisible = false;\n this.closeAlert.emit();\n }\n\n // PRIVATES\n // --------\n\n}\n","@if (!isMuted) {\n <div class=\"eui-alert__type-container\">\n @switch(baseStatesDirective.euiVariant) {\n @case('info') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-information\" fillColor=\"info-100\"></eui-icon-svg>\n }\n @case('success') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-check-filled\" fillColor=\"success-100\"></eui-icon-svg>\n }\n @case('warning') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-warning\" fillColor=\"warning-100\"></eui-icon-svg>\n }\n @case('danger') {\n <eui-icon-svg class=\"eui-alert__icon-type\" icon=\"eui-ecl-error\" fillColor=\"danger-100\"></eui-icon-svg>\n }\n }\n </div>\n}\n\n<div id=\"{{ ariaDescribedBy }}\" class=\"eui-alert__content\">\n @if (alertTitle) {\n <ng-template *ngTemplateOutlet=\"contentWithTitle\"></ng-template>\n } @else {\n <ng-template *ngTemplateOutlet=\"contentNoTitle\"></ng-template>\n }\n</div>\n\n<ng-template #contentWithTitle>\n <div class=\"eui-alert__content-header eui-alert__content-header--with-title\">\n <ng-content select=\"eui-alert-title\"></ng-content>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n</ng-template>\n\n<ng-template #contentNoTitle>\n <div class=\"eui-alert__content-header\">\n <ng-template *ngTemplateOutlet=\"content\"></ng-template>\n <ng-template *ngTemplateOutlet=\"closeButton\"></ng-template>\n </div>\n</ng-template>\n\n<ng-template #closeButton>\n <div class=\"eui-alert__close\">\n <button *ngIf=\"isCloseable\"\n euiButton\n euiBasicButton\n euiPrimary\n euiSizeS\n aria-label=\"Close alert button\"\n class=\"eui-u-ml-s\"\n (click)=\"onCloseClick()\">\n <span euiLabel class=\"eui-u-display-hidden-mobile\">{{ 'eui.CLOSE' | translate }}</span>\n <eui-icon-svg icon=\"eui-ecl-close\" class=\"eui-u-ml-xs\"></eui-icon-svg>\n </button>\n </div>\n</ng-template>\n\n<ng-template #content>\n <div [class.eui-u-mt-xs]=\"alertTitle\">\n <ng-content></ng-content>\n </div>\n</ng-template>\n","// Angular\nimport { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\n// 3rd party\nimport { TranslateModule } from '@ngx-translate/core';\n\n// eUI internals\nimport { BaseStatesDirective } from '@eui/components/shared';\nimport { EuiIconModule } from '@eui/components/eui-icon';\nimport { EuiLabelModule } from '@eui/components/eui-label';\nimport { EuiButtonModule } from '@eui/components/eui-button';\n\n// component internals\nimport { EuiAlertComponent, EuiAlertTitleDirective } from './eui-alert.component';\n\nconst COMPONENTS = [\n EuiAlertComponent,\n EuiAlertTitleDirective,\n];\n\n// component main module\n@NgModule({\n imports: [\n // Angular and 3rd party\n CommonModule, TranslateModule,\n // eUI internals\n BaseStatesDirective,\n EuiIconModule, EuiLabelModule, EuiButtonModule,\n ],\n declarations: [...COMPONENTS],\n exports: [...COMPONENTS],\n})\n// Always same naming convention for all : Eui[CMP_NAME]Module\nexport class EuiAlertModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA;AACA;AACA;AAEA;AAuBA;AAEA;MAEa,sBAAsB,CAAA;AADnC,IAAA,WAAA,GAAA;;QAG0B,IAAK,CAAA,KAAA,GAAG,kBAAkB,CAAC;AACpD,KAAA;iIAHY,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;qHAAtB,sBAAsB,EAAA,QAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,OAAA,EAAA,YAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA;;2FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBADlC,SAAS;mBAAC,EAAE,QAAQ,EAAE,iBAAiB,EAAE,CAAA;8BAGhB,KAAK,EAAA,CAAA;sBAA1B,WAAW;uBAAC,OAAO,CAAA;;AAExB;AAEA;AACA;AACA;MAuBa,iBAAiB,CAAA;;AAE1B,IAAA,IACW,UAAU,GAAA;QACjB,OAAO;;AAEH,YAAA,IAAI,CAAC,mBAAmB,CAAC,aAAa,CAAC,WAAW,CAAC;;YAGnD,IAAI,CAAC,OAAO,GAAG,kBAAkB,GAAG,EAAE;YACtC,IAAI,CAAC,WAAW,GAAG,sBAAsB,GAAG,EAAE;YAC9C,CAAC,IAAI,CAAC,SAAS,GAAG,mBAAmB,GAAG,EAAE;AAC7C,SAAA;aACI,IAAI,CAAC,GAAG,CAAC;AACT,aAAA,IAAI,EAAE,CAAC;KACf;AAKD,IAAA,IAEI,eAAe,GA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