@cloudscape-design/components-themeable 3.0.1102 → 3.0.1104

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 (150) hide show
  1. package/lib/internal/manifest.json +1 -1
  2. package/lib/internal/scss/app-layout/visual-refresh-toolbar/drawer/styles.scss +10 -1
  3. package/lib/internal/scss/button-dropdown/item-element/styles.scss +1 -1
  4. package/lib/internal/scss/internal/generated/custom-css-properties/index.scss +1 -1
  5. package/lib/internal/scss/select/parts/styles.scss +1 -1
  6. package/lib/internal/template/app-layout/utils/use-ai-drawer.d.ts +0 -1
  7. package/lib/internal/template/app-layout/utils/use-ai-drawer.d.ts.map +1 -1
  8. package/lib/internal/template/app-layout/utils/use-ai-drawer.js +1 -1
  9. package/lib/internal/template/app-layout/utils/use-ai-drawer.js.map +1 -1
  10. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/global-ai-drawer.js +2 -2
  11. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/global-ai-drawer.js.map +1 -1
  12. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/global-drawers.d.ts +0 -1
  13. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/global-drawers.d.ts.map +1 -1
  14. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/global-drawers.js +0 -2
  15. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/global-drawers.js.map +1 -1
  16. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/index.d.ts +2 -2
  17. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/index.d.ts.map +1 -1
  18. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/index.js +2 -2
  19. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/index.js.map +1 -1
  20. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/local-drawer.d.ts +0 -1
  21. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/local-drawer.d.ts.map +1 -1
  22. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/local-drawer.js +0 -2
  23. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/local-drawer.js.map +1 -1
  24. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/styles.css.js +25 -24
  25. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/styles.scoped.css +74 -66
  26. package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/styles.selectors.js +25 -24
  27. package/lib/internal/template/app-layout/visual-refresh-toolbar/internal.d.ts +0 -7
  28. package/lib/internal/template/app-layout/visual-refresh-toolbar/internal.d.ts.map +1 -1
  29. package/lib/internal/template/app-layout/visual-refresh-toolbar/internal.js +0 -14
  30. package/lib/internal/template/app-layout/visual-refresh-toolbar/internal.js.map +1 -1
  31. package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/index.d.ts +0 -1
  32. package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/index.d.ts.map +1 -1
  33. package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/index.js +0 -3
  34. package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/index.js.map +1 -1
  35. package/lib/internal/template/app-layout/visual-refresh-toolbar/notifications/index.d.ts +0 -1
  36. package/lib/internal/template/app-layout/visual-refresh-toolbar/notifications/index.d.ts.map +1 -1
  37. package/lib/internal/template/app-layout/visual-refresh-toolbar/notifications/index.js +0 -3
  38. package/lib/internal/template/app-layout/visual-refresh-toolbar/notifications/index.js.map +1 -1
  39. package/lib/internal/template/app-layout/visual-refresh-toolbar/split-panel/index.d.ts +0 -2
  40. package/lib/internal/template/app-layout/visual-refresh-toolbar/split-panel/index.d.ts.map +1 -1
  41. package/lib/internal/template/app-layout/visual-refresh-toolbar/split-panel/index.js +0 -3
  42. package/lib/internal/template/app-layout/visual-refresh-toolbar/split-panel/index.js.map +1 -1
  43. package/lib/internal/template/app-layout/visual-refresh-toolbar/toolbar/index.d.ts +0 -1
  44. package/lib/internal/template/app-layout/visual-refresh-toolbar/toolbar/index.d.ts.map +1 -1
  45. package/lib/internal/template/app-layout/visual-refresh-toolbar/toolbar/index.js +0 -3
  46. package/lib/internal/template/app-layout/visual-refresh-toolbar/toolbar/index.js.map +1 -1
  47. package/lib/internal/template/button-dropdown/item-element/styles.css.js +16 -16
  48. package/lib/internal/template/button-dropdown/item-element/styles.scoped.css +25 -25
  49. package/lib/internal/template/button-dropdown/item-element/styles.selectors.js +16 -16
  50. package/lib/internal/template/date-range-picker/calendar/index.d.ts +4 -18
  51. package/lib/internal/template/date-range-picker/calendar/index.d.ts.map +1 -1
  52. package/lib/internal/template/date-range-picker/calendar/index.js +2 -2
  53. package/lib/internal/template/date-range-picker/calendar/index.js.map +1 -1
  54. package/lib/internal/template/date-range-picker/calendar/interfaces.d.ts +22 -0
  55. package/lib/internal/template/date-range-picker/calendar/interfaces.d.ts.map +1 -0
  56. package/lib/internal/template/date-range-picker/calendar/interfaces.js +2 -0
  57. package/lib/internal/template/date-range-picker/calendar/interfaces.js.map +1 -0
  58. package/lib/internal/template/date-range-picker/calendar/range-inputs.d.ts +2 -20
  59. package/lib/internal/template/date-range-picker/calendar/range-inputs.d.ts.map +1 -1
  60. package/lib/internal/template/date-range-picker/calendar/range-inputs.js +11 -13
  61. package/lib/internal/template/date-range-picker/calendar/range-inputs.js.map +1 -1
  62. package/lib/internal/template/date-range-picker/calendar/utils.d.ts +4 -0
  63. package/lib/internal/template/date-range-picker/calendar/utils.d.ts.map +1 -1
  64. package/lib/internal/template/date-range-picker/calendar/utils.js +40 -0
  65. package/lib/internal/template/date-range-picker/calendar/utils.js.map +1 -1
  66. package/lib/internal/template/date-range-picker/dropdown.d.ts +3 -2
  67. package/lib/internal/template/date-range-picker/dropdown.d.ts.map +1 -1
  68. package/lib/internal/template/date-range-picker/dropdown.js +2 -2
  69. package/lib/internal/template/date-range-picker/dropdown.js.map +1 -1
  70. package/lib/internal/template/date-range-picker/index.d.ts.map +1 -1
  71. package/lib/internal/template/date-range-picker/index.js +3 -2
  72. package/lib/internal/template/date-range-picker/index.js.map +1 -1
  73. package/lib/internal/template/date-range-picker/interfaces.d.ts +53 -11
  74. package/lib/internal/template/date-range-picker/interfaces.d.ts.map +1 -1
  75. package/lib/internal/template/date-range-picker/interfaces.js.map +1 -1
  76. package/lib/internal/template/flashbar/collapsible-flashbar.d.ts +2 -2
  77. package/lib/internal/template/flashbar/collapsible-flashbar.d.ts.map +1 -1
  78. package/lib/internal/template/flashbar/collapsible-flashbar.js.map +1 -1
  79. package/lib/internal/template/flashbar/common.d.ts +2 -2
  80. package/lib/internal/template/flashbar/common.d.ts.map +1 -1
  81. package/lib/internal/template/flashbar/common.js +1 -5
  82. package/lib/internal/template/flashbar/common.js.map +1 -1
  83. package/lib/internal/template/flashbar/implementation.d.ts +5 -0
  84. package/lib/internal/template/flashbar/implementation.d.ts.map +1 -0
  85. package/lib/internal/template/flashbar/implementation.js +16 -0
  86. package/lib/internal/template/flashbar/implementation.js.map +1 -0
  87. package/lib/internal/template/flashbar/index.d.ts.map +1 -1
  88. package/lib/internal/template/flashbar/index.js +6 -8
  89. package/lib/internal/template/flashbar/index.js.map +1 -1
  90. package/lib/internal/template/flashbar/interfaces.d.ts +2 -0
  91. package/lib/internal/template/flashbar/interfaces.d.ts.map +1 -1
  92. package/lib/internal/template/flashbar/interfaces.js.map +1 -1
  93. package/lib/internal/template/flashbar/internal.d.ts +2 -0
  94. package/lib/internal/template/flashbar/internal.d.ts.map +1 -0
  95. package/lib/internal/template/flashbar/internal.js +5 -0
  96. package/lib/internal/template/flashbar/internal.js.map +1 -0
  97. package/lib/internal/template/flashbar/non-collapsible-flashbar.d.ts +2 -2
  98. package/lib/internal/template/flashbar/non-collapsible-flashbar.d.ts.map +1 -1
  99. package/lib/internal/template/flashbar/non-collapsible-flashbar.js.map +1 -1
  100. package/lib/internal/template/internal/base-component/styles.scoped.css +12 -1
  101. package/lib/internal/template/internal/environment.js +2 -2
  102. package/lib/internal/template/internal/environment.json +2 -2
  103. package/lib/internal/template/internal/generated/styles/tokens.d.ts +1 -0
  104. package/lib/internal/template/internal/generated/styles/tokens.js +1 -0
  105. package/lib/internal/template/internal/generated/theming/index.cjs +47 -14
  106. package/lib/internal/template/internal/generated/theming/index.cjs.d.ts +9 -0
  107. package/lib/internal/template/internal/generated/theming/index.d.ts +9 -0
  108. package/lib/internal/template/internal/generated/theming/index.js +47 -14
  109. package/lib/internal/template/internal/plugins/widget/internal.d.ts +4 -0
  110. package/lib/internal/template/internal/plugins/widget/internal.d.ts.map +1 -1
  111. package/lib/internal/template/internal/plugins/widget/internal.js +16 -0
  112. package/lib/internal/template/internal/plugins/widget/internal.js.map +1 -1
  113. package/lib/internal/template/internal/plugins/widget.d.ts +1 -1
  114. package/lib/internal/template/internal/plugins/widget.d.ts.map +1 -1
  115. package/lib/internal/template/internal/plugins/widget.js +1 -1
  116. package/lib/internal/template/internal/plugins/widget.js.map +1 -1
  117. package/lib/internal/template/internal/utils/date-time/format-date-time-with-offset.d.ts.map +1 -1
  118. package/lib/internal/template/internal/utils/date-time/format-date-time-with-offset.js +4 -0
  119. package/lib/internal/template/internal/utils/date-time/format-date-time-with-offset.js.map +1 -1
  120. package/lib/internal/template/internal/widget-exports.d.ts +1 -0
  121. package/lib/internal/template/internal/widget-exports.d.ts.map +1 -1
  122. package/lib/internal/template/internal/widget-exports.js +1 -0
  123. package/lib/internal/template/internal/widget-exports.js.map +1 -1
  124. package/lib/internal/template/mixed-line-bar-chart/bar-groups.d.ts.map +1 -1
  125. package/lib/internal/template/mixed-line-bar-chart/bar-groups.js +4 -1
  126. package/lib/internal/template/mixed-line-bar-chart/bar-groups.js.map +1 -1
  127. package/lib/internal/template/select/parts/styles.css.js +22 -22
  128. package/lib/internal/template/select/parts/styles.scoped.css +24 -24
  129. package/lib/internal/template/select/parts/styles.selectors.js +22 -22
  130. package/lib/internal/template/status-indicator/index.d.ts +1 -1
  131. package/lib/internal/template/status-indicator/index.d.ts.map +1 -1
  132. package/lib/internal/template/status-indicator/index.js.map +1 -1
  133. package/lib/internal/template/status-indicator/interfaces.d.ts +46 -0
  134. package/lib/internal/template/status-indicator/interfaces.d.ts.map +1 -0
  135. package/lib/internal/template/status-indicator/interfaces.js +2 -0
  136. package/lib/internal/template/status-indicator/interfaces.js.map +1 -0
  137. package/lib/internal/template/status-indicator/internal.d.ts +3 -31
  138. package/lib/internal/template/status-indicator/internal.d.ts.map +1 -1
  139. package/lib/internal/template/status-indicator/internal.js +6 -2
  140. package/lib/internal/template/status-indicator/internal.js.map +1 -1
  141. package/lib/internal/template/steps/interfaces.d.ts +1 -1
  142. package/lib/internal/template/steps/interfaces.d.ts.map +1 -1
  143. package/lib/internal/template/steps/interfaces.js.map +1 -1
  144. package/lib/internal/template/table/internal.js +2 -2
  145. package/lib/internal/template/table/internal.js.map +1 -1
  146. package/lib/internal/template/test-utils/dom/index.js +332 -83
  147. package/lib/internal/template/test-utils/dom/index.js.map +1 -1
  148. package/lib/internal/template/test-utils/selectors/index.js +332 -83
  149. package/lib/internal/template/test-utils/selectors/index.js.map +1 -1
  150. package/package.json +1 -1
@@ -134,6 +134,7 @@ export declare interface TypedOverride {
134
134
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
135
135
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
136
136
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
137
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
137
138
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
138
139
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
139
140
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -400,6 +401,7 @@ export declare interface TypedOverride {
400
401
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
401
402
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
402
403
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
404
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
403
405
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
404
406
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
405
407
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -666,6 +668,7 @@ export declare interface TypedOverride {
666
668
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
667
669
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
668
670
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
671
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
669
672
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
670
673
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
671
674
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -932,6 +935,7 @@ export declare interface TypedOverride {
932
935
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
933
936
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
934
937
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
938
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
935
939
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
936
940
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
937
941
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1198,6 +1202,7 @@ export declare interface TypedOverride {
1198
1202
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1199
1203
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1200
1204
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1205
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1201
1206
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1202
1207
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1203
1208
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1464,6 +1469,7 @@ export declare interface TypedOverride {
1464
1469
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1465
1470
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1466
1471
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1472
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1467
1473
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1468
1474
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1469
1475
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1730,6 +1736,7 @@ export declare interface TypedOverride {
1730
1736
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1731
1737
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1732
1738
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1739
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1733
1740
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1734
1741
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1735
1742
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1996,6 +2003,7 @@ export declare interface TypedOverride {
1996
2003
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1997
2004
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1998
2005
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2006
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1999
2007
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2000
2008
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2001
2009
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -2262,6 +2270,7 @@ export declare interface TypedOverride {
2262
2270
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2263
2271
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2264
2272
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2273
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2265
2274
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2266
2275
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2267
2276
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -134,6 +134,7 @@ export declare interface TypedOverride {
134
134
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
135
135
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
136
136
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
137
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
137
138
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
138
139
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
139
140
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -400,6 +401,7 @@ export declare interface TypedOverride {
400
401
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
401
402
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
402
403
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
404
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
403
405
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
404
406
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
405
407
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -666,6 +668,7 @@ export declare interface TypedOverride {
666
668
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
667
669
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
668
670
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
671
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
669
672
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
670
673
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
671
674
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -932,6 +935,7 @@ export declare interface TypedOverride {
932
935
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
933
936
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
934
937
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
938
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
935
939
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
936
940
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
937
941
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1198,6 +1202,7 @@ export declare interface TypedOverride {
1198
1202
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1199
1203
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1200
1204
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1205
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1201
1206
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1202
1207
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1203
1208
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1464,6 +1469,7 @@ export declare interface TypedOverride {
1464
1469
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1465
1470
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1466
1471
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1472
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1467
1473
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1468
1474
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1469
1475
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1730,6 +1736,7 @@ export declare interface TypedOverride {
1730
1736
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1731
1737
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1732
1738
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1739
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1733
1740
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1734
1741
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1735
1742
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1996,6 +2003,7 @@ export declare interface TypedOverride {
1996
2003
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1997
2004
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1998
2005
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2006
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
1999
2007
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2000
2008
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2001
2009
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -2262,6 +2270,7 @@ export declare interface TypedOverride {
2262
2270
  colorTextButtonIconDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2263
2271
  colorBorderButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2264
2272
  colorTextButtonPrimaryDisabled?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2273
+ colorItemSelected?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2265
2274
  colorBorderContainerTop?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2266
2275
  colorBorderControlDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
2267
2276
  colorBorderDividerDefault?: GlobalValue | TypedModeValueOverride<'light' | 'dark'>;
@@ -1214,6 +1214,10 @@ export var preset = {
1214
1214
  "light": "{colorGrey500}",
1215
1215
  "dark": "{colorGrey500}"
1216
1216
  },
1217
+ "colorItemSelected": {
1218
+ "light": "{colorBlue600}",
1219
+ "dark": "{colorBlue400}"
1220
+ },
1217
1221
  "colorBorderCalendarGrid": {
1218
1222
  "light": "transparent",
1219
1223
  "dark": "transparent"
@@ -1339,8 +1343,8 @@ export var preset = {
1339
1343
  "dark": "{colorBorderItemSelected}"
1340
1344
  },
1341
1345
  "colorBorderItemSelected": {
1342
- "light": "{colorBlue600}",
1343
- "dark": "{colorBlue400}"
1346
+ "light": "{colorItemSelected}",
1347
+ "dark": "{colorItemSelected}"
1344
1348
  },
1345
1349
  "colorBorderLayout": {
1346
1350
  "light": "{colorGrey350}",
@@ -3494,6 +3498,10 @@ export var preset = {
3494
3498
  "light": "{colorGrey500}",
3495
3499
  "dark": "{colorGrey500}"
3496
3500
  },
3501
+ "colorItemSelected": {
3502
+ "light": "{colorBlue400}",
3503
+ "dark": "{colorBlue400}"
3504
+ },
3497
3505
  "colorBorderCalendarGrid": {
3498
3506
  "light": "transparent",
3499
3507
  "dark": "transparent"
@@ -3619,8 +3627,8 @@ export var preset = {
3619
3627
  "dark": "{colorBorderItemSelected}"
3620
3628
  },
3621
3629
  "colorBorderItemSelected": {
3622
- "light": "{colorBlue400}",
3623
- "dark": "{colorBlue400}"
3630
+ "light": "{colorItemSelected}",
3631
+ "dark": "{colorItemSelected}"
3624
3632
  },
3625
3633
  "colorBorderLayout": {
3626
3634
  "light": "{colorGrey650}",
@@ -4672,6 +4680,10 @@ export var preset = {
4672
4680
  "light": "{colorGrey500}",
4673
4681
  "dark": "{colorGrey500}"
4674
4682
  },
4683
+ "colorItemSelected": {
4684
+ "light": "{colorBlue400}",
4685
+ "dark": "{colorBlue400}"
4686
+ },
4675
4687
  "colorBorderCalendarGrid": {
4676
4688
  "light": "transparent",
4677
4689
  "dark": "transparent"
@@ -4797,8 +4809,8 @@ export var preset = {
4797
4809
  "dark": "{colorBorderItemSelected}"
4798
4810
  },
4799
4811
  "colorBorderItemSelected": {
4800
- "light": "{colorBlue400}",
4801
- "dark": "{colorBlue400}"
4812
+ "light": "{colorItemSelected}",
4813
+ "dark": "{colorItemSelected}"
4802
4814
  },
4803
4815
  "colorBorderLayout": {
4804
4816
  "light": "{colorGrey650}",
@@ -5782,6 +5794,10 @@ export var preset = {
5782
5794
  "light": "{colorGrey500}",
5783
5795
  "dark": "{colorGrey500}"
5784
5796
  },
5797
+ "colorItemSelected": {
5798
+ "light": "{colorBlue600}",
5799
+ "dark": "{colorBlue400}"
5800
+ },
5785
5801
  "colorBorderCalendarGrid": {
5786
5802
  "light": "transparent",
5787
5803
  "dark": "transparent"
@@ -5907,8 +5923,8 @@ export var preset = {
5907
5923
  "dark": "{colorBorderItemSelected}"
5908
5924
  },
5909
5925
  "colorBorderItemSelected": {
5910
- "light": "{colorBlue600}",
5911
- "dark": "{colorBlue400}"
5926
+ "light": "{colorItemSelected}",
5927
+ "dark": "{colorItemSelected}"
5912
5928
  },
5913
5929
  "colorBorderLayout": {
5914
5930
  "light": "{colorGrey350}",
@@ -6892,6 +6908,10 @@ export var preset = {
6892
6908
  "light": "{colorGrey500}",
6893
6909
  "dark": "{colorGrey500}"
6894
6910
  },
6911
+ "colorItemSelected": {
6912
+ "light": "{colorBlue600}",
6913
+ "dark": "{colorBlue400}"
6914
+ },
6895
6915
  "colorBorderCalendarGrid": {
6896
6916
  "light": "transparent",
6897
6917
  "dark": "transparent"
@@ -7017,8 +7037,8 @@ export var preset = {
7017
7037
  "dark": "{colorBorderItemSelected}"
7018
7038
  },
7019
7039
  "colorBorderItemSelected": {
7020
- "light": "{colorBlue600}",
7021
- "dark": "{colorBlue400}"
7040
+ "light": "{colorItemSelected}",
7041
+ "dark": "{colorItemSelected}"
7022
7042
  },
7023
7043
  "colorBorderLayout": {
7024
7044
  "light": "{colorGrey350}",
@@ -8002,6 +8022,10 @@ export var preset = {
8002
8022
  "light": "{colorGrey500}",
8003
8023
  "dark": "{colorGrey500}"
8004
8024
  },
8025
+ "colorItemSelected": {
8026
+ "light": "{colorBlue600}",
8027
+ "dark": "{colorBlue400}"
8028
+ },
8005
8029
  "colorBorderCalendarGrid": {
8006
8030
  "light": "transparent",
8007
8031
  "dark": "transparent"
@@ -8127,8 +8151,8 @@ export var preset = {
8127
8151
  "dark": "{colorBorderItemSelected}"
8128
8152
  },
8129
8153
  "colorBorderItemSelected": {
8130
- "light": "{colorBlue600}",
8131
- "dark": "{colorBlue400}"
8154
+ "light": "{colorItemSelected}",
8155
+ "dark": "{colorItemSelected}"
8132
8156
  },
8133
8157
  "colorBorderLayout": {
8134
8158
  "light": "{colorGrey350}",
@@ -9114,6 +9138,10 @@ export var preset = {
9114
9138
  "light": "{colorGrey500}",
9115
9139
  "dark": "{colorGrey500}"
9116
9140
  },
9141
+ "colorItemSelected": {
9142
+ "light": "{colorBlue400}",
9143
+ "dark": "{colorBlue400}"
9144
+ },
9117
9145
  "colorBorderCalendarGrid": {
9118
9146
  "light": "transparent",
9119
9147
  "dark": "transparent"
@@ -9239,8 +9267,8 @@ export var preset = {
9239
9267
  "dark": "{colorBorderItemSelected}"
9240
9268
  },
9241
9269
  "colorBorderItemSelected": {
9242
- "light": "{colorBlue400}",
9243
- "dark": "{colorBlue400}"
9270
+ "light": "{colorItemSelected}",
9271
+ "dark": "{colorItemSelected}"
9244
9272
  },
9245
9273
  "colorBorderLayout": {
9246
9274
  "light": "{colorGrey650}",
@@ -10069,6 +10097,7 @@ export var preset = {
10069
10097
  "colorTextButtonIconDisabled": "color",
10070
10098
  "colorBorderButtonPrimaryDisabled": "color",
10071
10099
  "colorTextButtonPrimaryDisabled": "color",
10100
+ "colorItemSelected": "color",
10072
10101
  "colorBorderCalendarGrid": "color",
10073
10102
  "colorBorderCalendarGridSelectedFocusRing": "color",
10074
10103
  "colorBorderCellShaded": "color",
@@ -10538,6 +10567,7 @@ export var preset = {
10538
10567
  "colorTextButtonIconDisabled",
10539
10568
  "colorBorderButtonPrimaryDisabled",
10540
10569
  "colorTextButtonPrimaryDisabled",
10570
+ "colorItemSelected",
10541
10571
  "colorBorderContainerTop",
10542
10572
  "colorBorderControlDefault",
10543
10573
  "colorBorderDividerDefault",
@@ -10898,6 +10928,7 @@ export var preset = {
10898
10928
  "colorTextButtonIconDisabled",
10899
10929
  "colorBorderButtonPrimaryDisabled",
10900
10930
  "colorTextButtonPrimaryDisabled",
10931
+ "colorItemSelected",
10901
10932
  "colorBorderContainerTop",
10902
10933
  "colorBorderControlDefault",
10903
10934
  "colorBorderDividerDefault",
@@ -11398,6 +11429,7 @@ export var preset = {
11398
11429
  "colorTextButtonIconDisabled": "color-text-button-icon-disabled",
11399
11430
  "colorBorderButtonPrimaryDisabled": "color-border-button-primary-disabled",
11400
11431
  "colorTextButtonPrimaryDisabled": "color-text-button-primary-disabled",
11432
+ "colorItemSelected": "color-item-selected",
11401
11433
  "colorBorderCalendarGrid": "color-border-calendar-grid",
11402
11434
  "colorBorderCalendarGridSelectedFocusRing": "color-border-calendar-grid-selected-focus-ring",
11403
11435
  "colorBorderCellShaded": "color-border-cell-shaded",
@@ -12156,6 +12188,7 @@ export var preset = {
12156
12188
  "colorTextButtonIconDisabled": "--color-text-button-icon-disabled-nnofkn",
12157
12189
  "colorBorderButtonPrimaryDisabled": "--color-border-button-primary-disabled-b5p1ji",
12158
12190
  "colorTextButtonPrimaryDisabled": "--color-text-button-primary-disabled-q79gms",
12191
+ "colorItemSelected": "--color-item-selected-72rnwy",
12159
12192
  "colorBorderCalendarGrid": "--color-border-calendar-grid-67r4w4",
12160
12193
  "colorBorderCalendarGridSelectedFocusRing": "--color-border-calendar-grid-selected-focus-ring-jk1fb0",
12161
12194
  "colorBorderCellShaded": "--color-border-cell-shaded-0ipazf",
@@ -7,6 +7,10 @@ export declare function clearInitialMessages(): void;
7
7
  * Returns whether there is an app layout present on this page or not
8
8
  */
9
9
  export declare function isAppLayoutReady(): boolean;
10
+ /**
11
+ * Returns a promise that resolves once the app layout has loaded
12
+ */
13
+ export declare function whenAppLayoutReady(): Promise<unknown>;
10
14
  /**
11
15
  * Registers a new runtime drawer to app layout
12
16
  * @param drawer
@@ -1 +1 @@
1
- {"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../../../src/internal/plugins/widget/internal.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,aAAa,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAU9G,KAAK,gBAAgB,GAAG,CAAC,KAAK,EAAE,gBAAgB,KAAK,IAAI,CAAC;AAW1D,wBAAgB,wBAAwB,wCAEvC;AAED,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,gBAAgB,cASjE;AAED,wBAAgB,oBAAoB,SAEnC;AAED;;GAEG;AACH,wBAAgB,gBAAgB,YAE/B;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,aAAa,QAMvD;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,sBAAsB,QAE3D"}
1
+ {"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../../../src/internal/plugins/widget/internal.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,aAAa,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAY9G,KAAK,gBAAgB,GAAG,CAAC,KAAK,EAAE,gBAAgB,KAAK,IAAI,CAAC;AAW1D,wBAAgB,wBAAwB,wCAEvC;AAED,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,gBAAgB,cAWjE;AAED,wBAAgB,oBAAoB,SAEnC;AAED;;GAEG;AACH,wBAAgB,gBAAgB,YAE/B;AAED;;GAEG;AACH,wBAAgB,kBAAkB,qBAOjC;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,aAAa,QAMvD;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,sBAAsB,QAE3D"}
@@ -3,6 +3,7 @@
3
3
  import { reportRuntimeApiWarning } from '../helpers/metrics';
4
4
  const storageKeyMessageHandler = Symbol.for('awsui-widget-api-message-handler');
5
5
  const storageKeyInitialMessages = Symbol.for('awsui-widget-api-initial-messages');
6
+ const storageKeyReadyDeferCallbacks = Symbol.for('awsui-widget-api-ready-defer');
6
7
  function getWindow() {
7
8
  return window;
8
9
  }
@@ -14,11 +15,14 @@ export function getAppLayoutInitialState() {
14
15
  return getWindow()[storageKeyInitialMessages];
15
16
  }
16
17
  export function registerAppLayoutHandler(handler) {
18
+ var _a;
17
19
  const win = getWindow();
18
20
  if (win[storageKeyMessageHandler]) {
19
21
  reportRuntimeApiWarning('AppLayoutWidget', 'Double registration attempt, the old handler will be overridden');
20
22
  }
21
23
  win[storageKeyMessageHandler] = handler;
24
+ (_a = win[storageKeyReadyDeferCallbacks]) === null || _a === void 0 ? void 0 : _a.forEach(fn => fn());
25
+ win[storageKeyReadyDeferCallbacks] = [];
22
26
  return () => {
23
27
  win[storageKeyMessageHandler] = undefined;
24
28
  };
@@ -32,6 +36,18 @@ export function clearInitialMessages() {
32
36
  export function isAppLayoutReady() {
33
37
  return !!getAppLayoutMessageHandler();
34
38
  }
39
+ /**
40
+ * Returns a promise that resolves once the app layout has loaded
41
+ */
42
+ export function whenAppLayoutReady() {
43
+ var _a;
44
+ if (isAppLayoutReady()) {
45
+ return Promise.resolve();
46
+ }
47
+ const win = getWindow();
48
+ win[storageKeyReadyDeferCallbacks] = (_a = win[storageKeyReadyDeferCallbacks]) !== null && _a !== void 0 ? _a : [];
49
+ return new Promise(resolve => { var _a; return (_a = win[storageKeyReadyDeferCallbacks]) === null || _a === void 0 ? void 0 : _a.push(resolve); });
50
+ }
35
51
  /**
36
52
  * Registers a new runtime drawer to app layout
37
53
  * @param drawer
@@ -1 +1 @@
1
- {"version":3,"file":"internal.js","sourceRoot":"","sources":["../../../../../src/internal/plugins/widget/internal.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAG7D,MAAM,wBAAwB,GAAG,MAAM,CAAC,GAAG,CAAC,kCAAkC,CAAC,CAAC;AAChF,MAAM,yBAAyB,GAAG,MAAM,CAAC,GAAG,CAAC,mCAAmC,CAAC,CAAC;AASlF,SAAS,SAAS;IAChB,OAAO,MAAiC,CAAC;AAC3C,CAAC;AAED,SAAS,0BAA0B;IACjC,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,OAAO,GAAG,CAAC,wBAAwB,CAAC,CAAC;AACvC,CAAC;AAED,MAAM,UAAU,wBAAwB;IACtC,OAAO,SAAS,EAAE,CAAC,yBAAyB,CAAC,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,wBAAwB,CAAC,OAAyB;IAChE,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,IAAI,GAAG,CAAC,wBAAwB,CAAC,EAAE;QACjC,uBAAuB,CAAC,iBAAiB,EAAE,iEAAiE,CAAC,CAAC;KAC/G;IACD,GAAG,CAAC,wBAAwB,CAAC,GAAG,OAAO,CAAC;IACxC,OAAO,GAAG,EAAE;QACV,GAAG,CAAC,wBAAwB,CAAC,GAAG,SAAS,CAAC;IAC5C,CAAC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,oBAAoB;IAClC,SAAS,EAAE,CAAC,yBAAyB,CAAC,GAAG,SAAS,CAAC;AACrD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gBAAgB;IAC9B,OAAO,CAAC,CAAC,0BAA0B,EAAE,CAAC;AACxC,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAAC,MAAqB;;IACtD,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,MAAM,OAAO,GAA0B,EAAE,IAAI,EAAE,oBAAoB,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IACvF,GAAG,CAAC,yBAAyB,CAAC,GAAG,MAAA,GAAG,CAAC,yBAAyB,CAAC,mCAAI,EAAE,CAAC;IACtE,GAAG,CAAC,yBAAyB,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC7C,MAAA,0BAA0B,EAAE,0CAAG,OAAO,CAAC,CAAC;AAC1C,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,YAAY,CAAC,OAA+B;;IAC1D,MAAA,0BAA0B,EAAE,0CAAG,OAAO,CAAC,CAAC;AAC1C,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { reportRuntimeApiWarning } from '../helpers/metrics';\nimport { AppLayoutMessage, AppLayoutUpdateMessage, DrawerPayload, RegisterDrawerMessage } from './interfaces';\n\nconst storageKeyMessageHandler = Symbol.for('awsui-widget-api-message-handler');\nconst storageKeyInitialMessages = Symbol.for('awsui-widget-api-initial-messages');\n\ninterface WindowWithApi extends Window {\n [storageKeyMessageHandler]: AppLayoutHandler | undefined;\n [storageKeyInitialMessages]: Array<RegisterDrawerMessage> | undefined;\n}\n\ntype AppLayoutHandler = (event: AppLayoutMessage) => void;\n\nfunction getWindow() {\n return window as Window as WindowWithApi;\n}\n\nfunction getAppLayoutMessageHandler() {\n const win = getWindow();\n return win[storageKeyMessageHandler];\n}\n\nexport function getAppLayoutInitialState() {\n return getWindow()[storageKeyInitialMessages];\n}\n\nexport function registerAppLayoutHandler(handler: AppLayoutHandler) {\n const win = getWindow();\n if (win[storageKeyMessageHandler]) {\n reportRuntimeApiWarning('AppLayoutWidget', 'Double registration attempt, the old handler will be overridden');\n }\n win[storageKeyMessageHandler] = handler;\n return () => {\n win[storageKeyMessageHandler] = undefined;\n };\n}\n\nexport function clearInitialMessages() {\n getWindow()[storageKeyInitialMessages] = undefined;\n}\n\n/**\n * Returns whether there is an app layout present on this page or not\n */\nexport function isAppLayoutReady() {\n return !!getAppLayoutMessageHandler();\n}\n\n/**\n * Registers a new runtime drawer to app layout\n * @param drawer\n */\nexport function registerLeftDrawer(drawer: DrawerPayload) {\n const win = getWindow();\n const message: RegisterDrawerMessage = { type: 'registerLeftDrawer', payload: drawer };\n win[storageKeyInitialMessages] = win[storageKeyInitialMessages] ?? [];\n win[storageKeyInitialMessages].push(message);\n getAppLayoutMessageHandler()?.(message);\n}\n\n/**\n * Interact with already registered app layout drawers\n * @param message\n */\nexport function updateDrawer(message: AppLayoutUpdateMessage) {\n getAppLayoutMessageHandler()?.(message);\n}\n"]}
1
+ {"version":3,"file":"internal.js","sourceRoot":"","sources":["../../../../../src/internal/plugins/widget/internal.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAG7D,MAAM,wBAAwB,GAAG,MAAM,CAAC,GAAG,CAAC,kCAAkC,CAAC,CAAC;AAChF,MAAM,yBAAyB,GAAG,MAAM,CAAC,GAAG,CAAC,mCAAmC,CAAC,CAAC;AAClF,MAAM,6BAA6B,GAAG,MAAM,CAAC,GAAG,CAAC,8BAA8B,CAAC,CAAC;AAUjF,SAAS,SAAS;IAChB,OAAO,MAAiC,CAAC;AAC3C,CAAC;AAED,SAAS,0BAA0B;IACjC,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,OAAO,GAAG,CAAC,wBAAwB,CAAC,CAAC;AACvC,CAAC;AAED,MAAM,UAAU,wBAAwB;IACtC,OAAO,SAAS,EAAE,CAAC,yBAAyB,CAAC,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,wBAAwB,CAAC,OAAyB;;IAChE,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,IAAI,GAAG,CAAC,wBAAwB,CAAC,EAAE;QACjC,uBAAuB,CAAC,iBAAiB,EAAE,iEAAiE,CAAC,CAAC;KAC/G;IACD,GAAG,CAAC,wBAAwB,CAAC,GAAG,OAAO,CAAC;IACxC,MAAA,GAAG,CAAC,6BAA6B,CAAC,0CAAE,OAAO,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;IACxD,GAAG,CAAC,6BAA6B,CAAC,GAAG,EAAE,CAAC;IACxC,OAAO,GAAG,EAAE;QACV,GAAG,CAAC,wBAAwB,CAAC,GAAG,SAAS,CAAC;IAC5C,CAAC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,oBAAoB;IAClC,SAAS,EAAE,CAAC,yBAAyB,CAAC,GAAG,SAAS,CAAC;AACrD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gBAAgB;IAC9B,OAAO,CAAC,CAAC,0BAA0B,EAAE,CAAC;AACxC,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,kBAAkB;;IAChC,IAAI,gBAAgB,EAAE,EAAE;QACtB,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC;KAC1B;IACD,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,GAAG,CAAC,6BAA6B,CAAC,GAAG,MAAA,GAAG,CAAC,6BAA6B,CAAC,mCAAI,EAAE,CAAC;IAC9E,OAAO,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE,WAAC,OAAA,MAAA,GAAG,CAAC,6BAA6B,CAAC,0CAAE,IAAI,CAAC,OAAO,CAAC,CAAA,EAAA,CAAC,CAAC;AACnF,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAAC,MAAqB;;IACtD,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;IACxB,MAAM,OAAO,GAA0B,EAAE,IAAI,EAAE,oBAAoB,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IACvF,GAAG,CAAC,yBAAyB,CAAC,GAAG,MAAA,GAAG,CAAC,yBAAyB,CAAC,mCAAI,EAAE,CAAC;IACtE,GAAG,CAAC,yBAAyB,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC7C,MAAA,0BAA0B,EAAE,0CAAG,OAAO,CAAC,CAAC;AAC1C,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,YAAY,CAAC,OAA+B;;IAC1D,MAAA,0BAA0B,EAAE,0CAAG,OAAO,CAAC,CAAC;AAC1C,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { reportRuntimeApiWarning } from '../helpers/metrics';\nimport { AppLayoutMessage, AppLayoutUpdateMessage, DrawerPayload, RegisterDrawerMessage } from './interfaces';\n\nconst storageKeyMessageHandler = Symbol.for('awsui-widget-api-message-handler');\nconst storageKeyInitialMessages = Symbol.for('awsui-widget-api-initial-messages');\nconst storageKeyReadyDeferCallbacks = Symbol.for('awsui-widget-api-ready-defer');\n\ninterface WindowWithApi extends Window {\n [storageKeyMessageHandler]: AppLayoutHandler | undefined;\n [storageKeyInitialMessages]: Array<RegisterDrawerMessage> | undefined;\n [storageKeyReadyDeferCallbacks]: Array<(value?: unknown) => void> | undefined;\n}\n\ntype AppLayoutHandler = (event: AppLayoutMessage) => void;\n\nfunction getWindow() {\n return window as Window as WindowWithApi;\n}\n\nfunction getAppLayoutMessageHandler() {\n const win = getWindow();\n return win[storageKeyMessageHandler];\n}\n\nexport function getAppLayoutInitialState() {\n return getWindow()[storageKeyInitialMessages];\n}\n\nexport function registerAppLayoutHandler(handler: AppLayoutHandler) {\n const win = getWindow();\n if (win[storageKeyMessageHandler]) {\n reportRuntimeApiWarning('AppLayoutWidget', 'Double registration attempt, the old handler will be overridden');\n }\n win[storageKeyMessageHandler] = handler;\n win[storageKeyReadyDeferCallbacks]?.forEach(fn => fn());\n win[storageKeyReadyDeferCallbacks] = [];\n return () => {\n win[storageKeyMessageHandler] = undefined;\n };\n}\n\nexport function clearInitialMessages() {\n getWindow()[storageKeyInitialMessages] = undefined;\n}\n\n/**\n * Returns whether there is an app layout present on this page or not\n */\nexport function isAppLayoutReady() {\n return !!getAppLayoutMessageHandler();\n}\n\n/**\n * Returns a promise that resolves once the app layout has loaded\n */\nexport function whenAppLayoutReady() {\n if (isAppLayoutReady()) {\n return Promise.resolve();\n }\n const win = getWindow();\n win[storageKeyReadyDeferCallbacks] = win[storageKeyReadyDeferCallbacks] ?? [];\n return new Promise(resolve => win[storageKeyReadyDeferCallbacks]?.push(resolve));\n}\n\n/**\n * Registers a new runtime drawer to app layout\n * @param drawer\n */\nexport function registerLeftDrawer(drawer: DrawerPayload) {\n const win = getWindow();\n const message: RegisterDrawerMessage = { type: 'registerLeftDrawer', payload: drawer };\n win[storageKeyInitialMessages] = win[storageKeyInitialMessages] ?? [];\n win[storageKeyInitialMessages].push(message);\n getAppLayoutMessageHandler()?.(message);\n}\n\n/**\n * Interact with already registered app layout drawers\n * @param message\n */\nexport function updateDrawer(message: AppLayoutUpdateMessage) {\n getAppLayoutMessageHandler()?.(message);\n}\n"]}
@@ -1,3 +1,3 @@
1
1
  export * from './widget/interfaces';
2
- export { registerLeftDrawer, updateDrawer, isAppLayoutReady } from './widget/internal';
2
+ export { registerLeftDrawer, updateDrawer, isAppLayoutReady, whenAppLayoutReady } from './widget/internal';
3
3
  //# sourceMappingURL=widget.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"widget.d.ts","sourceRoot":"","sources":["../../../../src/internal/plugins/widget.ts"],"names":[],"mappings":"AAEA,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC"}
1
+ {"version":3,"file":"widget.d.ts","sourceRoot":"","sources":["../../../../src/internal/plugins/widget.ts"],"names":[],"mappings":"AAEA,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC"}
@@ -1,5 +1,5 @@
1
1
  // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2
2
  // SPDX-License-Identifier: Apache-2.0
3
3
  export * from './widget/interfaces';
4
- export { registerLeftDrawer, updateDrawer, isAppLayoutReady } from './widget/internal';
4
+ export { registerLeftDrawer, updateDrawer, isAppLayoutReady, whenAppLayoutReady } from './widget/internal';
5
5
  //# sourceMappingURL=widget.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"widget.js","sourceRoot":"","sources":["../../../../src/internal/plugins/widget.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nexport * from './widget/interfaces';\nexport { registerLeftDrawer, updateDrawer, isAppLayoutReady } from './widget/internal';\n"]}
1
+ {"version":3,"file":"widget.js","sourceRoot":"","sources":["../../../../src/internal/plugins/widget.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nexport * from './widget/interfaces';\nexport { registerLeftDrawer, updateDrawer, isAppLayoutReady, whenAppLayoutReady } from './widget/internal';\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"format-date-time-with-offset.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-date-time-with-offset.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAK7E,wBAAgB,wBAAwB,CAAC,EACvC,IAAI,EACJ,MAAM,EACN,cAAc,EACd,UAAU,EACV,MAAM,GACP,EAAE;IACD,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,oBAAoB,CAAC,cAAc,CAAC;IAC5C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,UAWA"}
1
+ {"version":3,"file":"format-date-time-with-offset.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-date-time-with-offset.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAK7E,wBAAgB,wBAAwB,CAAC,EACvC,IAAI,EACJ,MAAM,EACN,cAAc,EACd,UAAU,EACV,MAAM,GACP,EAAE;IACD,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,oBAAoB,CAAC,cAAc,CAAC;IAC5C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,UAeA"}
@@ -10,6 +10,10 @@ export function formatDateTimeWithOffset({ date, format, hideTimeOffset, timeOff
10
10
  case 'long-localized': {
11
11
  return formatDateLocalized({ date, hideTimeOffset, isDateOnly, isMonthOnly, locale, timeOffset });
12
12
  }
13
+ case 'slashed': {
14
+ const formatted = formatDateIso({ date, hideTimeOffset, isDateOnly, isMonthOnly, timeOffset }).split('T');
15
+ return `${formatted[0].split('-').join('/')}${formatted[1] ? `T${formatted[1]}` : ''}`;
16
+ }
13
17
  default: {
14
18
  return formatDateIso({ date, hideTimeOffset, isDateOnly, isMonthOnly, timeOffset });
15
19
  }
@@ -1 +1 @@
1
- {"version":3,"file":"format-date-time-with-offset.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-date-time-with-offset.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAGtC,OAAO,aAAa,MAAM,mBAAmB,CAAC;AAC9C,OAAO,mBAAmB,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAE9D,MAAM,UAAU,wBAAwB,CAAC,EACvC,IAAI,EACJ,MAAM,EACN,cAAc,EACd,UAAU,EACV,MAAM,GAOP;IACC,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;IACvC,MAAM,WAAW,GAAG,cAAc,CAAC,IAAI,CAAC,CAAC;IACzC,QAAQ,MAAM,EAAE;QACd,KAAK,gBAAgB,CAAC,CAAC;YACrB,OAAO,mBAAmB,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,EAAE,UAAU,EAAE,CAAC,CAAC;SACnG;QACD,OAAO,CAAC,CAAC;YACP,OAAO,aAAa,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,CAAC;SACrF;KACF;AACH,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { DateRangePickerProps } from '../../../date-range-picker/interfaces';\nimport formatDateIso from './format-date-iso';\nimport formatDateLocalized from './format-date-localized';\nimport { isIsoDateOnly, isIsoMonthOnly } from './is-iso-only';\n\nexport function formatDateTimeWithOffset({\n date,\n format,\n hideTimeOffset,\n timeOffset,\n locale,\n}: {\n date: string;\n format: DateRangePickerProps.AbsoluteFormat;\n hideTimeOffset?: boolean;\n timeOffset?: number;\n locale?: string;\n}) {\n const isDateOnly = isIsoDateOnly(date);\n const isMonthOnly = isIsoMonthOnly(date);\n switch (format) {\n case 'long-localized': {\n return formatDateLocalized({ date, hideTimeOffset, isDateOnly, isMonthOnly, locale, timeOffset });\n }\n default: {\n return formatDateIso({ date, hideTimeOffset, isDateOnly, isMonthOnly, timeOffset });\n }\n }\n}\n"]}
1
+ {"version":3,"file":"format-date-time-with-offset.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-date-time-with-offset.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAGtC,OAAO,aAAa,MAAM,mBAAmB,CAAC;AAC9C,OAAO,mBAAmB,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAE9D,MAAM,UAAU,wBAAwB,CAAC,EACvC,IAAI,EACJ,MAAM,EACN,cAAc,EACd,UAAU,EACV,MAAM,GAOP;IACC,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;IACvC,MAAM,WAAW,GAAG,cAAc,CAAC,IAAI,CAAC,CAAC;IACzC,QAAQ,MAAM,EAAE;QACd,KAAK,gBAAgB,CAAC,CAAC;YACrB,OAAO,mBAAmB,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,EAAE,UAAU,EAAE,CAAC,CAAC;SACnG;QACD,KAAK,SAAS,CAAC,CAAC;YACd,MAAM,SAAS,GAAG,aAAa,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;YAC1G,OAAO,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SACxF;QACD,OAAO,CAAC,CAAC;YACP,OAAO,aAAa,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,CAAC;SACrF;KACF;AACH,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { DateRangePickerProps } from '../../../date-range-picker/interfaces';\nimport formatDateIso from './format-date-iso';\nimport formatDateLocalized from './format-date-localized';\nimport { isIsoDateOnly, isIsoMonthOnly } from './is-iso-only';\n\nexport function formatDateTimeWithOffset({\n date,\n format,\n hideTimeOffset,\n timeOffset,\n locale,\n}: {\n date: string;\n format: DateRangePickerProps.AbsoluteFormat;\n hideTimeOffset?: boolean;\n timeOffset?: number;\n locale?: string;\n}) {\n const isDateOnly = isIsoDateOnly(date);\n const isMonthOnly = isIsoMonthOnly(date);\n switch (format) {\n case 'long-localized': {\n return formatDateLocalized({ date, hideTimeOffset, isDateOnly, isMonthOnly, locale, timeOffset });\n }\n case 'slashed': {\n const formatted = formatDateIso({ date, hideTimeOffset, isDateOnly, isMonthOnly, timeOffset }).split('T');\n return `${formatted[0].split('-').join('/')}${formatted[1] ? `T${formatted[1]}` : ''}`;\n }\n default: {\n return formatDateIso({ date, hideTimeOffset, isDateOnly, isMonthOnly, timeOffset });\n }\n }\n}\n"]}
@@ -12,6 +12,7 @@ export { AppLayoutStateProvider as AppLayoutWidgetizedState } from '../app-layou
12
12
  export { SplitPanelImplementation as SplitPanel } from '../split-panel/implementation';
13
13
  export { BreadcrumbGroupImplementation as BreadcrumbGroup } from '../breadcrumb-group/implementation';
14
14
  export { DrawerImplementation as Drawer } from '../drawer/implementation';
15
+ export { FlashbarImplementation as Flashbar } from '../flashbar/implementation';
15
16
  export { SideNavigationImplementation as SideNavigation } from '../side-navigation/implementation';
16
17
  export { HelpPanelImplementation as HelpPanel } from '../help-panel/implementation';
17
18
  //# sourceMappingURL=widget-exports.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"widget-exports.d.ts","sourceRoot":"","sources":["../../../src/internal/widget-exports.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAGhD,OAAO,EACL,6BAA6B,IAAI,eAAe,EAChD,oCAAoC,IAAI,sBAAsB,GAC/D,MAAM,6CAA6C,CAAC;AACrD,OAAO,EAAE,iCAAiC,IAAI,mBAAmB,EAAE,MAAM,iDAAiD,CAAC;AAC3H,OAAO,EAAE,oCAAoC,IAAI,sBAAsB,EAAE,MAAM,oDAAoD,CAAC;AACpI,OAAO,EACL,6CAA6C,IAAI,yBAAyB,EAC1E,2CAA2C,IAAI,uBAAuB,GACvE,MAAM,kDAAkD,CAAC;AAC1D,OAAO,EAAE,8BAA8B,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAGlH,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,2BAA2B,IAAI,sBAAsB,EAAE,MAAM,mEAAmE,CAAC;AAC1I,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,+BAA+B,IAAI,0BAA0B,EAAE,MAAM,uEAAuE,CAAC;AACtJ,OAAO,EAAE,sBAAsB,IAAI,wBAAwB,EAAE,MAAM,4CAA4C,CAAC;AAEhH,OAAO,EAAE,wBAAwB,IAAI,UAAU,EAAE,MAAM,+BAA+B,CAAC;AACvF,OAAO,EAAE,6BAA6B,IAAI,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACtG,OAAO,EAAE,oBAAoB,IAAI,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAC1E,OAAO,EAAE,4BAA4B,IAAI,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnG,OAAO,EAAE,uBAAuB,IAAI,SAAS,EAAE,MAAM,8BAA8B,CAAC"}
1
+ {"version":3,"file":"widget-exports.d.ts","sourceRoot":"","sources":["../../../src/internal/widget-exports.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAGhD,OAAO,EACL,6BAA6B,IAAI,eAAe,EAChD,oCAAoC,IAAI,sBAAsB,GAC/D,MAAM,6CAA6C,CAAC;AACrD,OAAO,EAAE,iCAAiC,IAAI,mBAAmB,EAAE,MAAM,iDAAiD,CAAC;AAC3H,OAAO,EAAE,oCAAoC,IAAI,sBAAsB,EAAE,MAAM,oDAAoD,CAAC;AACpI,OAAO,EACL,6CAA6C,IAAI,yBAAyB,EAC1E,2CAA2C,IAAI,uBAAuB,GACvE,MAAM,kDAAkD,CAAC;AAC1D,OAAO,EAAE,8BAA8B,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAGlH,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,2BAA2B,IAAI,sBAAsB,EAAE,MAAM,mEAAmE,CAAC;AAC1I,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,+BAA+B,IAAI,0BAA0B,EAAE,MAAM,uEAAuE,CAAC;AACtJ,OAAO,EAAE,sBAAsB,IAAI,wBAAwB,EAAE,MAAM,4CAA4C,CAAC;AAEhH,OAAO,EAAE,wBAAwB,IAAI,UAAU,EAAE,MAAM,+BAA+B,CAAC;AACvF,OAAO,EAAE,6BAA6B,IAAI,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACtG,OAAO,EAAE,oBAAoB,IAAI,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAC1E,OAAO,EAAE,sBAAsB,IAAI,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAE,4BAA4B,IAAI,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnG,OAAO,EAAE,uBAAuB,IAAI,SAAS,EAAE,MAAM,8BAA8B,CAAC"}
@@ -16,6 +16,7 @@ export { AppLayoutStateProvider as AppLayoutWidgetizedState } from '../app-layou
16
16
  export { SplitPanelImplementation as SplitPanel } from '../split-panel/implementation';
17
17
  export { BreadcrumbGroupImplementation as BreadcrumbGroup } from '../breadcrumb-group/implementation';
18
18
  export { DrawerImplementation as Drawer } from '../drawer/implementation';
19
+ export { FlashbarImplementation as Flashbar } from '../flashbar/implementation';
19
20
  export { SideNavigationImplementation as SideNavigation } from '../side-navigation/implementation';
20
21
  export { HelpPanelImplementation as HelpPanel } from '../help-panel/implementation';
21
22
  //# sourceMappingURL=widget-exports.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"widget-exports.js","sourceRoot":"","sources":["../../../src/internal/widget-exports.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAEhD,0BAA0B;AAC1B,OAAO,EACL,6BAA6B,IAAI,eAAe,EAChD,oCAAoC,IAAI,sBAAsB,GAC/D,MAAM,6CAA6C,CAAC;AACrD,OAAO,EAAE,iCAAiC,IAAI,mBAAmB,EAAE,MAAM,iDAAiD,CAAC;AAC3H,OAAO,EAAE,oCAAoC,IAAI,sBAAsB,EAAE,MAAM,oDAAoD,CAAC;AACpI,OAAO,EACL,6CAA6C,IAAI,yBAAyB,EAC1E,2CAA2C,IAAI,uBAAuB,GACvE,MAAM,kDAAkD,CAAC;AAC1D,OAAO,EAAE,8BAA8B,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAElH,8BAA8B;AAC9B,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,2BAA2B,IAAI,sBAAsB,EAAE,MAAM,mEAAmE,CAAC;AAC1I,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,+BAA+B,IAAI,0BAA0B,EAAE,MAAM,uEAAuE,CAAC;AACtJ,OAAO,EAAE,sBAAsB,IAAI,wBAAwB,EAAE,MAAM,4CAA4C,CAAC;AAEhH,OAAO,EAAE,wBAAwB,IAAI,UAAU,EAAE,MAAM,+BAA+B,CAAC;AACvF,OAAO,EAAE,6BAA6B,IAAI,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACtG,OAAO,EAAE,oBAAoB,IAAI,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAC1E,OAAO,EAAE,4BAA4B,IAAI,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnG,OAAO,EAAE,uBAAuB,IAAI,SAAS,EAAE,MAAM,8BAA8B,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nexport { PACKAGE_VERSION } from './environment';\n\n// Legacy widgetized parts\nexport {\n AppLayoutDrawerImplementation as AppLayoutDrawer,\n AppLayoutGlobalDrawersImplementation as AppLayoutGlobalDrawers,\n} from '../app-layout/visual-refresh-toolbar/drawer';\nexport { AppLayoutNavigationImplementation as AppLayoutNavigation } from '../app-layout/visual-refresh-toolbar/navigation';\nexport { AppLayoutNotificationsImplementation as AppLayoutNotifications } from '../app-layout/visual-refresh-toolbar/notifications';\nexport {\n AppLayoutSplitPanelDrawerBottomImplementation as AppLayoutSplitPanelBottom,\n AppLayoutSplitPanelDrawerSideImplementation as AppLayoutSplitPanelSide,\n} from '../app-layout/visual-refresh-toolbar/split-panel';\nexport { AppLayoutToolbarImplementation as AppLayoutToolbar } from '../app-layout/visual-refresh-toolbar/toolbar';\n\n// Refactored widgetized parts\nexport { BeforeMainSlotImplementation as AppLayoutBeforeMainSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/before-main-slot';\nexport { AfterMainSlotImplementation as AppLayoutAfterMainSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/after-main-slot';\nexport { TopContentSlotImplementation as AppLayoutTopContentSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/top-content-slot';\nexport { BottomContentSlotImplementation as AppLayoutBottomContentSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/bottom-content-slot';\nexport { AppLayoutStateProvider as AppLayoutWidgetizedState } from '../app-layout/visual-refresh-toolbar/state';\n\nexport { SplitPanelImplementation as SplitPanel } from '../split-panel/implementation';\nexport { BreadcrumbGroupImplementation as BreadcrumbGroup } from '../breadcrumb-group/implementation';\nexport { DrawerImplementation as Drawer } from '../drawer/implementation';\nexport { SideNavigationImplementation as SideNavigation } from '../side-navigation/implementation';\nexport { HelpPanelImplementation as HelpPanel } from '../help-panel/implementation';\n"]}
1
+ {"version":3,"file":"widget-exports.js","sourceRoot":"","sources":["../../../src/internal/widget-exports.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAEhD,0BAA0B;AAC1B,OAAO,EACL,6BAA6B,IAAI,eAAe,EAChD,oCAAoC,IAAI,sBAAsB,GAC/D,MAAM,6CAA6C,CAAC;AACrD,OAAO,EAAE,iCAAiC,IAAI,mBAAmB,EAAE,MAAM,iDAAiD,CAAC;AAC3H,OAAO,EAAE,oCAAoC,IAAI,sBAAsB,EAAE,MAAM,oDAAoD,CAAC;AACpI,OAAO,EACL,6CAA6C,IAAI,yBAAyB,EAC1E,2CAA2C,IAAI,uBAAuB,GACvE,MAAM,kDAAkD,CAAC;AAC1D,OAAO,EAAE,8BAA8B,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAElH,8BAA8B;AAC9B,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,2BAA2B,IAAI,sBAAsB,EAAE,MAAM,mEAAmE,CAAC;AAC1I,OAAO,EAAE,4BAA4B,IAAI,uBAAuB,EAAE,MAAM,oEAAoE,CAAC;AAC7I,OAAO,EAAE,+BAA+B,IAAI,0BAA0B,EAAE,MAAM,uEAAuE,CAAC;AACtJ,OAAO,EAAE,sBAAsB,IAAI,wBAAwB,EAAE,MAAM,4CAA4C,CAAC;AAEhH,OAAO,EAAE,wBAAwB,IAAI,UAAU,EAAE,MAAM,+BAA+B,CAAC;AACvF,OAAO,EAAE,6BAA6B,IAAI,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACtG,OAAO,EAAE,oBAAoB,IAAI,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAC1E,OAAO,EAAE,sBAAsB,IAAI,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAE,4BAA4B,IAAI,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnG,OAAO,EAAE,uBAAuB,IAAI,SAAS,EAAE,MAAM,8BAA8B,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nexport { PACKAGE_VERSION } from './environment';\n\n// Legacy widgetized parts\nexport {\n AppLayoutDrawerImplementation as AppLayoutDrawer,\n AppLayoutGlobalDrawersImplementation as AppLayoutGlobalDrawers,\n} from '../app-layout/visual-refresh-toolbar/drawer';\nexport { AppLayoutNavigationImplementation as AppLayoutNavigation } from '../app-layout/visual-refresh-toolbar/navigation';\nexport { AppLayoutNotificationsImplementation as AppLayoutNotifications } from '../app-layout/visual-refresh-toolbar/notifications';\nexport {\n AppLayoutSplitPanelDrawerBottomImplementation as AppLayoutSplitPanelBottom,\n AppLayoutSplitPanelDrawerSideImplementation as AppLayoutSplitPanelSide,\n} from '../app-layout/visual-refresh-toolbar/split-panel';\nexport { AppLayoutToolbarImplementation as AppLayoutToolbar } from '../app-layout/visual-refresh-toolbar/toolbar';\n\n// Refactored widgetized parts\nexport { BeforeMainSlotImplementation as AppLayoutBeforeMainSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/before-main-slot';\nexport { AfterMainSlotImplementation as AppLayoutAfterMainSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/after-main-slot';\nexport { TopContentSlotImplementation as AppLayoutTopContentSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/top-content-slot';\nexport { BottomContentSlotImplementation as AppLayoutBottomContentSlot } from '../app-layout/visual-refresh-toolbar/widget-areas/bottom-content-slot';\nexport { AppLayoutStateProvider as AppLayoutWidgetizedState } from '../app-layout/visual-refresh-toolbar/state';\n\nexport { SplitPanelImplementation as SplitPanel } from '../split-panel/implementation';\nexport { BreadcrumbGroupImplementation as BreadcrumbGroup } from '../breadcrumb-group/implementation';\nexport { DrawerImplementation as Drawer } from '../drawer/implementation';\nexport { FlashbarImplementation as Flashbar } from '../flashbar/implementation';\nexport { SideNavigationImplementation as SideNavigation } from '../side-navigation/implementation';\nexport { HelpPanelImplementation as HelpPanel } from '../help-panel/implementation';\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"bar-groups.d.ts","sourceRoot":"","sources":["../../../src/mixed-line-bar-chart/bar-groups.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAM1D,UAAU,SAAS,CAAC,CAAC,SAAS,cAAc;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;IACnB,eAAe,EAAE,OAAO,CAAC;IACzB,SAAS,EAAE,cAAc,CAAC,CAAC,CAAC,EAAE,CAAC;IAC/B,qBAAqB,EAAE,IAAI,GAAG,MAAM,CAAC;IACrC,mBAAmB,EAAE,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC;CACtD;AAED;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,CAAC,SAAS,cAAc,EAAE,EAC1D,SAAS,EACT,SAAS,EACT,eAAe,EACf,SAAS,EACT,qBAAqB,EACrB,mBAAmB,GACpB,EAAE,SAAS,CAAC,CAAC,CAAC,eAsBd"}
1
+ {"version":3,"file":"bar-groups.d.ts","sourceRoot":"","sources":["../../../src/mixed-line-bar-chart/bar-groups.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAM1D,UAAU,SAAS,CAAC,CAAC,SAAS,cAAc;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;IACnB,eAAe,EAAE,OAAO,CAAC;IACzB,SAAS,EAAE,cAAc,CAAC,CAAC,CAAC,EAAE,CAAC;IAC/B,qBAAqB,EAAE,IAAI,GAAG,MAAM,CAAC;IACrC,mBAAmB,EAAE,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC;CACtD;AAED;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,CAAC,SAAS,cAAc,EAAE,EAC1D,SAAS,EACT,SAAS,EACT,eAAe,EACf,SAAS,EACT,qBAAqB,EACrB,mBAAmB,GACpB,EAAE,SAAS,CAAC,CAAC,CAAC,eAwBd"}
@@ -9,6 +9,9 @@ const OUTLINE_PADDING = 2;
9
9
  * Other rectangles are only needed for the "findBarGroups" test-utils selector.
10
10
  */
11
11
  export default function BarGroups({ ariaLabel, isRefresh, isPopoverPinned, barGroups, highlightedGroupIndex, highlightedGroupRef, }) {
12
- return (React.createElement("g", { role: "group", "aria-hidden": "true" }, barGroups.map((group, index) => (React.createElement("rect", { key: index, x: Math.max(0, group.position.x - OUTLINE_PADDING), y: Math.max(0, group.position.y - OUTLINE_PADDING), width: group.position.width + 2 * OUTLINE_PADDING, height: group.position.height + 2 * OUTLINE_PADDING, ref: index === highlightedGroupIndex ? highlightedGroupRef : undefined, rx: isRefresh ? 4 : 2, role: "button", "aria-label": ariaLabel, "aria-haspopup": true, "aria-expanded": isPopoverPinned, fill: "none", className: styles['bar-group'] })))));
12
+ return (React.createElement("g", { role: "group", "aria-hidden": "true" }, barGroups.map((group, index) => (React.createElement("rect", { key: index, x: Math.max(0, group.position.x - OUTLINE_PADDING), y: Math.max(0, group.position.y - OUTLINE_PADDING), width: group.position.width + 2 * OUTLINE_PADDING, height: group.position.height + 2 * OUTLINE_PADDING, ref: index === highlightedGroupIndex ? highlightedGroupRef : undefined, rx: isRefresh ? 4 : 2, role: "button", "aria-label": ariaLabel, "aria-haspopup": true, "aria-expanded": isPopoverPinned,
13
+ // We must use "transparent" instead of "none" so that Firefox popover placement works correctly.
14
+ // When an SVG element has no stroke or fill color the Firefox optimizes it out.
15
+ fill: "transparent", className: styles['bar-group'] })))));
13
16
  }
14
17
  //# sourceMappingURL=bar-groups.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"bar-groups.js","sourceRoot":"","sources":["../../../src/mixed-line-bar-chart/bar-groups.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAErC,MAAM,eAAe,GAAG,CAAC,CAAC;AAW1B;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAA2B,EAC1D,SAAS,EACT,SAAS,EACT,eAAe,EACf,SAAS,EACT,qBAAqB,EACrB,mBAAmB,GACN;IACb,OAAO,CACL,2BAAG,IAAI,EAAC,OAAO,iBAAa,MAAM,IAC/B,SAAS,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC,CAC/B,8BACE,GAAG,EAAE,KAAK,EACV,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,GAAG,eAAe,CAAC,EAClD,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,GAAG,eAAe,CAAC,EAClD,KAAK,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,GAAG,CAAC,GAAG,eAAe,EACjD,MAAM,EAAE,KAAK,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,GAAG,eAAe,EACnD,GAAG,EAAE,KAAK,KAAK,qBAAqB,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,SAAS,EACtE,EAAE,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EACrB,IAAI,EAAC,QAAQ,gBACD,SAAS,mBACN,IAAI,mBACJ,eAAe,EAC9B,IAAI,EAAC,MAAM,EACX,SAAS,EAAE,MAAM,CAAC,WAAW,CAAC,GAC9B,CACH,CAAC,CACA,CACL,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React from 'react';\n\nimport { ChartDataTypes } from './interfaces';\nimport { ScaledBarGroup } from './make-scaled-bar-groups';\n\nimport styles from './styles.css.js';\n\nconst OUTLINE_PADDING = 2;\n\ninterface BarGroups<T extends ChartDataTypes> {\n ariaLabel: string;\n isRefresh: boolean;\n isPopoverPinned: boolean;\n barGroups: ScaledBarGroup<T>[];\n highlightedGroupIndex: null | number;\n highlightedGroupRef: React.RefObject<SVGRectElement>;\n}\n\n/**\n * The component renders empty SVG rectangles corresponding to the bar group slots.\n * The highlighted group rectangle is used for the pseudo-focus and therefore requires ARIA attributes.\n * Other rectangles are only needed for the \"findBarGroups\" test-utils selector.\n */\nexport default function BarGroups<T extends ChartDataTypes>({\n ariaLabel,\n isRefresh,\n isPopoverPinned,\n barGroups,\n highlightedGroupIndex,\n highlightedGroupRef,\n}: BarGroups<T>) {\n return (\n <g role=\"group\" aria-hidden=\"true\">\n {barGroups.map((group, index) => (\n <rect\n key={index}\n x={Math.max(0, group.position.x - OUTLINE_PADDING)}\n y={Math.max(0, group.position.y - OUTLINE_PADDING)}\n width={group.position.width + 2 * OUTLINE_PADDING}\n height={group.position.height + 2 * OUTLINE_PADDING}\n ref={index === highlightedGroupIndex ? highlightedGroupRef : undefined}\n rx={isRefresh ? 4 : 2}\n role=\"button\"\n aria-label={ariaLabel}\n aria-haspopup={true}\n aria-expanded={isPopoverPinned}\n fill=\"none\"\n className={styles['bar-group']}\n />\n ))}\n </g>\n );\n}\n"]}
1
+ {"version":3,"file":"bar-groups.js","sourceRoot":"","sources":["../../../src/mixed-line-bar-chart/bar-groups.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAErC,MAAM,eAAe,GAAG,CAAC,CAAC;AAW1B;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAA2B,EAC1D,SAAS,EACT,SAAS,EACT,eAAe,EACf,SAAS,EACT,qBAAqB,EACrB,mBAAmB,GACN;IACb,OAAO,CACL,2BAAG,IAAI,EAAC,OAAO,iBAAa,MAAM,IAC/B,SAAS,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC,CAC/B,8BACE,GAAG,EAAE,KAAK,EACV,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,GAAG,eAAe,CAAC,EAClD,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,GAAG,eAAe,CAAC,EAClD,KAAK,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,GAAG,CAAC,GAAG,eAAe,EACjD,MAAM,EAAE,KAAK,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,GAAG,eAAe,EACnD,GAAG,EAAE,KAAK,KAAK,qBAAqB,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,SAAS,EACtE,EAAE,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EACrB,IAAI,EAAC,QAAQ,gBACD,SAAS,mBACN,IAAI,mBACJ,eAAe;QAC9B,iGAAiG;QACjG,gFAAgF;QAChF,IAAI,EAAC,aAAa,EAClB,SAAS,EAAE,MAAM,CAAC,WAAW,CAAC,GAC9B,CACH,CAAC,CACA,CACL,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React from 'react';\n\nimport { ChartDataTypes } from './interfaces';\nimport { ScaledBarGroup } from './make-scaled-bar-groups';\n\nimport styles from './styles.css.js';\n\nconst OUTLINE_PADDING = 2;\n\ninterface BarGroups<T extends ChartDataTypes> {\n ariaLabel: string;\n isRefresh: boolean;\n isPopoverPinned: boolean;\n barGroups: ScaledBarGroup<T>[];\n highlightedGroupIndex: null | number;\n highlightedGroupRef: React.RefObject<SVGRectElement>;\n}\n\n/**\n * The component renders empty SVG rectangles corresponding to the bar group slots.\n * The highlighted group rectangle is used for the pseudo-focus and therefore requires ARIA attributes.\n * Other rectangles are only needed for the \"findBarGroups\" test-utils selector.\n */\nexport default function BarGroups<T extends ChartDataTypes>({\n ariaLabel,\n isRefresh,\n isPopoverPinned,\n barGroups,\n highlightedGroupIndex,\n highlightedGroupRef,\n}: BarGroups<T>) {\n return (\n <g role=\"group\" aria-hidden=\"true\">\n {barGroups.map((group, index) => (\n <rect\n key={index}\n x={Math.max(0, group.position.x - OUTLINE_PADDING)}\n y={Math.max(0, group.position.y - OUTLINE_PADDING)}\n width={group.position.width + 2 * OUTLINE_PADDING}\n height={group.position.height + 2 * OUTLINE_PADDING}\n ref={index === highlightedGroupIndex ? highlightedGroupRef : undefined}\n rx={isRefresh ? 4 : 2}\n role=\"button\"\n aria-label={ariaLabel}\n aria-haspopup={true}\n aria-expanded={isPopoverPinned}\n // We must use \"transparent\" instead of \"none\" so that Firefox popover placement works correctly.\n // When an SVG element has no stroke or fill color the Firefox optimizes it out.\n fill=\"transparent\"\n className={styles['bar-group']}\n />\n ))}\n </g>\n );\n}\n"]}