@cloudscape-design/components-themeable 3.0.296 → 3.0.298

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 (43) hide show
  1. package/lib/internal/manifest.json +1 -1
  2. package/lib/internal/scss/app-layout/drawer/styles.scss +12 -16
  3. package/lib/internal/scss/app-layout/visual-refresh/trigger-button.scss +1 -2
  4. package/lib/internal/scss/flashbar/collapsible.scss +7 -8
  5. package/lib/internal/template/app-layout/drawer/index.d.ts.map +1 -1
  6. package/lib/internal/template/app-layout/drawer/index.js +1 -1
  7. package/lib/internal/template/app-layout/drawer/index.js.map +1 -1
  8. package/lib/internal/template/app-layout/drawer/styles.css.js +10 -10
  9. package/lib/internal/template/app-layout/drawer/styles.scoped.css +29 -32
  10. package/lib/internal/template/app-layout/drawer/styles.selectors.js +10 -10
  11. package/lib/internal/template/app-layout/index.d.ts.map +1 -1
  12. package/lib/internal/template/app-layout/index.js +2 -2
  13. package/lib/internal/template/app-layout/index.js.map +1 -1
  14. package/lib/internal/template/app-layout/interfaces.d.ts +2 -0
  15. package/lib/internal/template/app-layout/interfaces.d.ts.map +1 -1
  16. package/lib/internal/template/app-layout/interfaces.js.map +1 -1
  17. package/lib/internal/template/app-layout/split-panel-drawer/index.d.ts.map +1 -1
  18. package/lib/internal/template/app-layout/split-panel-drawer/index.js +1 -1
  19. package/lib/internal/template/app-layout/split-panel-drawer/index.js.map +1 -1
  20. package/lib/internal/template/app-layout/visual-refresh/styles.css.js +72 -72
  21. package/lib/internal/template/app-layout/visual-refresh/styles.scoped.css +190 -190
  22. package/lib/internal/template/app-layout/visual-refresh/styles.selectors.js +72 -72
  23. package/lib/internal/template/app-layout/visual-refresh/tools.d.ts.map +1 -1
  24. package/lib/internal/template/app-layout/visual-refresh/tools.js +3 -3
  25. package/lib/internal/template/app-layout/visual-refresh/tools.js.map +1 -1
  26. package/lib/internal/template/cards/index.d.ts.map +1 -1
  27. package/lib/internal/template/cards/index.js +4 -2
  28. package/lib/internal/template/cards/index.js.map +1 -1
  29. package/lib/internal/template/cards/interfaces.d.ts +20 -0
  30. package/lib/internal/template/cards/interfaces.d.ts.map +1 -1
  31. package/lib/internal/template/cards/interfaces.js.map +1 -1
  32. package/lib/internal/template/flashbar/styles.css.js +45 -45
  33. package/lib/internal/template/flashbar/styles.scoped.css +151 -151
  34. package/lib/internal/template/flashbar/styles.selectors.js +45 -45
  35. package/lib/internal/template/internal/base-component/styles.scoped.css +51 -47
  36. package/lib/internal/template/internal/environment.js +1 -1
  37. package/lib/internal/template/internal/generated/styles/tokens.d.ts +4 -0
  38. package/lib/internal/template/internal/generated/styles/tokens.js +299 -295
  39. package/lib/internal/template/internal/generated/theming/index.cjs +837 -737
  40. package/lib/internal/template/internal/generated/theming/index.cjs.d.ts +24 -0
  41. package/lib/internal/template/internal/generated/theming/index.d.ts +24 -0
  42. package/lib/internal/template/internal/generated/theming/index.js +837 -737
  43. package/package.json +1 -1
@@ -1,3 +1,3 @@
1
1
  {
2
- "commit": "897f229628b2517a5191f70e3b465f4140d1a45a"
2
+ "commit": "8104f14f571588a2e471e211c309c20aa8c1ae2a"
3
3
  }
@@ -65,36 +65,32 @@ $drawer-z-index-mobile: 1001;
65
65
 
66
66
  .trigger {
67
67
  .drawer-content > .drawer-triggers > & {
68
- padding: constants.$drawers-padding;
69
- margin: 1px constants.$drawers-padding-horizontal;
70
- border-radius: 0;
68
+ background: awsui.$color-background-layout-toggle-default;
71
69
  border: 0;
70
+ border-radius: 0;
71
+ color: awsui.$color-text-layout-toggle;
72
+ padding: constants.$drawers-padding-vertical awsui.$space-s;
73
+ margin-top: 1px;
72
74
 
73
75
  &:not(:last-child) {
74
- box-shadow: 0px 1px awsui.$color-shadow-layout-panel-trigger;
76
+ box-shadow: 0px 1px awsui.$color-shadow-layout-toggle;
75
77
  }
76
78
  &-drawer {
77
79
  &:hover:not(.selected) {
78
- color: awsui.$color-text-layout-panel-trigger-hover;
80
+ color: awsui.$color-text-layout-toggle-hover;
79
81
  &:not(:last-child) {
80
- box-shadow: 0px 1px awsui.$color-shadow-layout-panel-trigger;
82
+ box-shadow: 0px 1px awsui.$color-shadow-layout-toggle;
81
83
  }
82
84
  }
83
85
  }
84
86
 
85
87
  &.selected,
86
88
  &.selected:hover {
87
- padding: constants.$drawers-padding-vertical awsui.$space-s;
88
- margin: 0;
89
- border-top: 1px solid awsui.$color-background-layout-panel-trigger-active;
90
- border-bottom: 1px solid awsui.$color-background-layout-panel-trigger-active;
91
-
92
- background-color: awsui.$color-background-layout-panel-trigger-active;
93
- color: awsui.$color-text-layout-panel-trigger-active;
89
+ background-color: awsui.$color-background-layout-toggle-selected-default;
90
+ border-top: 1px solid awsui.$color-background-layout-toggle-selected-default;
94
91
  box-shadow: none;
95
- &:hover {
96
- cursor: default;
97
- }
92
+ color: awsui.$color-text-layout-toggle-active;
93
+ margin: 0;
98
94
  }
99
95
  }
100
96
  }
@@ -21,9 +21,8 @@ handleSplitPanelMaxWidth function in the context.
21
21
  cursor: pointer;
22
22
  height: awsui.$space-layout-toggle-diameter;
23
23
  padding: 0 awsui.$space-s;
24
- width: awsui.$space-layout-toggle-diameter;
25
-
26
24
  pointer-events: auto;
25
+ width: awsui.$space-layout-toggle-diameter;
27
26
 
28
27
  @include focus-visible.when-visible {
29
28
  @include styles.focus-highlight(3px);
@@ -199,13 +199,12 @@ the grid layout will be:
199
199
 
200
200
  .stack > .notification-bar {
201
201
  @include styles.text-wrapping;
202
-
203
- background: awsui.$color-background-layout-toggle-default;
204
- border-color: awsui.$color-background-layout-toggle-default;
202
+ background: awsui.$color-background-notification-stack-bar;
203
+ border-color: awsui.$color-border-notification-stack-bar;
205
204
  border-radius: awsui.$border-radius-button;
206
205
  border-style: solid;
207
206
  box-shadow: awsui.$shadow-panel-toggle;
208
- color: awsui.$color-text-layout-toggle;
207
+ color: awsui.$color-text-notification-stack-bar;
209
208
  cursor: pointer;
210
209
  display: flex;
211
210
  flex-direction: row;
@@ -226,7 +225,7 @@ the grid layout will be:
226
225
  > .status > .item-count,
227
226
  > .button {
228
227
  @include typography.default-text-style;
229
- color: awsui.$color-text-layout-toggle;
228
+ color: awsui.$color-text-notification-stack-bar;
230
229
  cursor: pointer;
231
230
  margin-top: 0;
232
231
  margin-bottom: 0;
@@ -262,12 +261,12 @@ the grid layout will be:
262
261
  }
263
262
 
264
263
  &:hover {
265
- background: awsui.$color-background-layout-toggle-hover;
266
- border-color: awsui.$color-background-layout-toggle-hover;
264
+ background: awsui.$color-background-notification-stack-bar-hover;
265
+ border-color: awsui.$color-background-notification-stack-bar-hover;
267
266
  }
268
267
 
269
268
  &:active {
270
- background: awsui.$color-background-layout-toggle-active;
269
+ background: awsui.$color-background-notification-stack-bar-active;
271
270
  }
272
271
 
273
272
  &.visual-refresh {
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"lib/default/","sources":["app-layout/drawer/index.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAiB,MAAM,OAAO,CAAC;AAKtC,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAoC,MAAM,cAAc,CAAC;AAkB5G,eAAO,MAAM,MAAM,2FAyGlB,CAAC;AAEF,wBAAgB,iBAAiB,CAAC,EAChC,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,OAAO,EACP,gBAAgB,EAChB,eAAe,GAChB,EAAE,sBAAsB,eAkCxB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"lib/default/","sources":["app-layout/drawer/index.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAiB,MAAM,OAAO,CAAC;AAKtC,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAoC,MAAM,cAAc,CAAC;AAkB5G,eAAO,MAAM,MAAM,2FAyGlB,CAAC;AAEF,wBAAgB,iBAAiB,CAAC,EAChC,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,OAAO,EACP,gBAAgB,EAChB,eAAe,GAChB,EAAE,sBAAsB,eAoCxB"}
@@ -75,7 +75,7 @@ export function DrawerTriggersBar({ isMobile, topOffset, bottomOffset, drawers,
75
75
  }) },
76
76
  React.createElement("div", { style: { top: topOffset, bottom: bottomOffset }, className: clsx(styles['drawer-content'], styles['non-interactive']) }, !isMobile && (React.createElement("aside", { "aria-label": drawers === null || drawers === void 0 ? void 0 : drawers.ariaLabel, className: clsx(styles['drawer-triggers'], contentClassName) }, (_a = drawers === null || drawers === void 0 ? void 0 : drawers.items) === null || _a === void 0 ? void 0 : _a.map((item, index) => {
77
77
  var _a;
78
- return (React.createElement(AppLayoutButton, { className: clsx(toggleClassName, styles.trigger, styles['trigger-drawer'], drawers.activeDrawerId === item.id && styles.selected), key: `drawer-trigger-${index}`, iconName: item.trigger.iconName, iconSvg: item.trigger.iconSvg, ariaLabel: (_a = item.ariaLabels) === null || _a === void 0 ? void 0 : _a.triggerButton, onClick: () => drawers.onChange({ activeDrawerId: item.id }), ariaExpanded: drawers.activeDrawerId !== undefined }));
78
+ return (React.createElement(AppLayoutButton, { className: clsx(toggleClassName, styles.trigger, styles['trigger-drawer'], drawers.activeDrawerId === item.id && styles.selected), key: `drawer-trigger-${index}`, iconName: item.trigger.iconName, iconSvg: item.trigger.iconSvg, ariaLabel: (_a = item.ariaLabels) === null || _a === void 0 ? void 0 : _a.triggerButton, onClick: () => drawers.onChange({ activeDrawerId: item.id !== drawers.activeDrawerId ? item.id : undefined }), ariaExpanded: drawers.activeDrawerId !== undefined }));
79
79
  }))))));
80
80
  }
81
81
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"lib/default/","sources":["app-layout/drawer/index.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,KAAK,EAAE,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAEzE,OAAO,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C,MAAM,CAAC,eAAe,CAAC,CAAC,EAAE,QAAQ;SACpC,CAAC;QAEF,6BACE,KAAK,EAAE,EAAE,GAAG,EAAE,SAAS,EAAE,MAAM,EAAE,YAAY,EAAE,EAC/C,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC,EAAE,MAAM,CAAC,iBAAiB,CAAC,CAAC,IAEnE,CAAC,QAAQ,IAAI,CACZ,6CAAmB,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,SAAS,EAAE,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,iBAAiB,CAAC,EAAE,gBAAgB,CAAC,IAChG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,KAAK,0CAAE,GAAG,CAAC,CAAC,IAAgB,EAAE,KAAa,EAAE,EAAE;;YAAC,OAAA,CACxD,oBAAC,eAAe,IACd,SAAS,EAAE,IAAI,CACb,eAAe,EACf,MAAM,CAAC,OAAO,EACd,MAAM,CAAC,gBAAgB,CAAC,EACxB,OAAO,CAAC,cAAc,KAAK,IAAI,CAAC,EAAE,IAAI,MAAM,CAAC,QAAQ,CACtD,EACD,GAAG,EAAE,kBAAkB,KAAK,EAAE,EAC9B,QAAQ,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ,EAC/B,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO,EAC7B,SAAS,EAAE,MAAA,IAAI,CAAC,UAAU,0CAAE,aAAa,EACzC,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,cAAc,EAAE,IAAI,CAAC,EAAE,EAAE,CAAC,EAC5D,YAAY,EAAE,OAAO,CAAC,cAAc,KAAK,SAAS,GAClD,CACH,CAAA;SAAA,CAAC,CACI,CACT,CACG,CACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport clsx from 'clsx';\nimport React, { useRef } from 'react';\nimport { AppLayoutButton, CloseButton, togglesConfig } from '../toggles';\n\nimport testutilStyles from '../test-classes/styles.css.js';\nimport styles from './styles.css.js';\nimport { DesktopDrawerProps, DrawerTriggersBarProps, DrawerItem, DrawerItemAriaLabels } from './interfaces';\n\n// We are using two landmarks per drawer, i.e. two NAVs and two ASIDEs, because of several\n// known bugs in NVDA that cause focus changes within a container to sometimes not be\n// announced. As a result, we use one region for the open button and one region for the\n// actual drawer content, always hiding the other one when it's not visible.\n// An alternative solution to follow a more classic implementation here to only have one\n// button that triggers the opening/closing of the drawer also did not work due to another\n// series of bugs in NVDA (together with Firefox) which prevent the changed expanded state\n// from being announced.\n// Even with this workaround in place, the announcement of the close button when opening a\n// panel in NVDA is not working correctly. The suspected root cause is one of the bugs below\n// as well.\n// Relevant tickets:\n// * https://github.com/nvaccess/nvda/issues/6606\n// * https://github.com/nvaccess/nvda/issues/5825\n// * https://github.com/nvaccess/nvda/issues/5247\n// * https://github.com/nvaccess/nvda/pull/8869 (reverted PR that was going to fix it)\nexport const Drawer = React.forwardRef(\n (\n {\n contentClassName,\n toggleClassName,\n closeClassName,\n width,\n type,\n toggleRefs,\n topOffset,\n bottomOffset,\n ariaLabels,\n drawersAriaLabels,\n children,\n isOpen,\n isMobile,\n onToggle,\n onClick,\n onLoseFocus,\n drawers,\n resizeHandle,\n }: DesktopDrawerProps,\n ref: React.Ref<HTMLDivElement>\n ) => {\n const openButtonWrapperRef = useRef<HTMLElement | null>(null);\n const { TagName, iconName, getLabels } = togglesConfig[type];\n const { mainLabel, closeLabel, openLabel } = getLabels(ariaLabels);\n const drawerContentWidthOpen = isMobile ? undefined : width;\n const drawerContentWidth = isOpen ? drawerContentWidthOpen : undefined;\n\n const getDrawersLabels = (labels: DrawerItemAriaLabels = {}) => ({\n drawerMainLabel: labels?.content,\n drawerOpenLabel: labels?.triggerButton,\n drawerCloseLabel: labels?.closeButton,\n });\n const { drawerMainLabel, drawerCloseLabel } = getDrawersLabels(drawersAriaLabels);\n\n const regularOpenButton = (\n <TagName ref={openButtonWrapperRef} aria-label={mainLabel} className={styles.toggle} aria-hidden={isOpen}>\n <AppLayoutButton\n ref={toggleRefs.toggle}\n className={toggleClassName}\n iconName={iconName}\n ariaLabel={openLabel}\n onClick={() => onToggle(true)}\n ariaExpanded={false}\n />\n </TagName>\n );\n\n return (\n <div\n ref={ref}\n className={clsx(styles.drawer, {\n [styles['drawer-closed']]: !isOpen,\n [testutilStyles['drawer-closed']]: !isOpen,\n [styles['drawer-mobile']]: isMobile,\n })}\n style={{ width: drawerContentWidth }}\n onBlur={\n onLoseFocus\n ? e => {\n if (!e.relatedTarget || !e.currentTarget.contains(e.relatedTarget)) {\n onLoseFocus(e);\n }\n }\n : undefined\n }\n onClick={event => {\n if (onClick) {\n onClick(event);\n }\n if (!isOpen) {\n // to prevent calling onToggle from the drawer when it's called from the toggle button\n if (\n openButtonWrapperRef.current === event.target ||\n !openButtonWrapperRef.current?.contains(event.target as Node)\n ) {\n onToggle(true);\n }\n }\n }}\n >\n <div\n style={{ width: drawerContentWidth, top: topOffset, bottom: bottomOffset }}\n className={clsx(styles['drawer-content'], contentClassName)}\n >\n {!isMobile && regularOpenButton}\n {resizeHandle}\n <TagName aria-label={drawers ? drawerMainLabel : mainLabel} aria-hidden={!isOpen}>\n <CloseButton\n ref={toggleRefs.close}\n className={closeClassName}\n ariaLabel={drawers ? drawerCloseLabel : closeLabel}\n onClick={() => {\n onToggle(false);\n drawers?.onChange({ activeDrawerId: undefined });\n }}\n />\n {children}\n </TagName>\n </div>\n </div>\n );\n }\n);\n\nexport function DrawerTriggersBar({\n isMobile,\n topOffset,\n bottomOffset,\n drawers,\n contentClassName,\n toggleClassName,\n}: DrawerTriggersBarProps) {\n return (\n <div\n className={clsx(styles.drawer, styles['drawer-closed'], testutilStyles['drawer-closed'], {\n [styles['drawer-mobile']]: isMobile,\n })}\n >\n <div\n style={{ top: topOffset, bottom: bottomOffset }}\n className={clsx(styles['drawer-content'], styles['non-interactive'])}\n >\n {!isMobile && (\n <aside aria-label={drawers?.ariaLabel} className={clsx(styles['drawer-triggers'], contentClassName)}>\n {drawers?.items?.map((item: DrawerItem, index: number) => (\n <AppLayoutButton\n className={clsx(\n toggleClassName,\n styles.trigger,\n styles['trigger-drawer'],\n drawers.activeDrawerId === item.id && styles.selected\n )}\n key={`drawer-trigger-${index}`}\n iconName={item.trigger.iconName}\n iconSvg={item.trigger.iconSvg}\n ariaLabel={item.ariaLabels?.triggerButton}\n onClick={() => drawers.onChange({ activeDrawerId: item.id })}\n ariaExpanded={drawers.activeDrawerId !== undefined}\n />\n ))}\n </aside>\n )}\n </div>\n </div>\n );\n}\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"lib/default/","sources":["app-layout/drawer/index.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,KAAK,EAAE,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAEzE,OAAO,cAAc,MAAM,+BAA+B,CAAC;AAC3D,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAGrC,0FAA0F;AAC1F,qFAAqF;AACrF,uFAAuF;AACvF,4EAA4E;AAC5E,wFAAwF;AACxF,0FAA0F;AAC1F,0FAA0F;AAC1F,wBAAwB;AACxB,0FAA0F;AAC1F,4FAA4F;AAC5F,WAAW;AACX,oBAAoB;AACpB,iDAAiD;AACjD,iDAAiD;AACjD,iDAAiD;AACjD,sFAAsF;AACtF,MAAM,CAAC,MAAM,MAAM,GAAG,KAAK,CAAC,UAAU,CACpC,CACE,EACE,gBAAgB,EAChB,eAAe,EACf,cAAc,EACd,KAAK,EACL,IAAI,EACJ,UAAU,EACV,SAAS,EACT,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,QAAQ,EACR,MAAM,EACN,QAAQ,EACR,Q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BAAC,eAAe,IACd,SAAS,EAAE,IAAI,CACb,eAAe,EACf,MAAM,CAAC,OAAO,EACd,MAAM,CAAC,gBAAgB,CAAC,EACxB,OAAO,CAAC,cAAc,KAAK,IAAI,CAAC,EAAE,IAAI,MAAM,CAAC,QAAQ,CACtD,EACD,GAAG,EAAE,kBAAkB,KAAK,EAAE,EAC9B,QAAQ,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ,EAC/B,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO,EAC7B,SAAS,EAAE,MAAA,IAAI,CAAC,UAAU,0CAAE,aAAa,EACzC,OAAO,EAAE,GAAG,EAAE,CACZ,OAAO,CAAC,QAAQ,CAAC,EAAE,cAAc,EAAE,IAAI,CAAC,EAAE,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC,EAEhG,YAAY,EAAE,OAAO,CAAC,cAAc,KAAK,SAAS,GAClD,CACH,CAAA;SAAA,CAAC,CACI,CACT,CACG,CACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport clsx from 'clsx';\nimport React, { useRef } from 'react';\nimport { AppLayoutButton, CloseButton, togglesConfig } from '../toggles';\n\nimport testutilStyles from '../test-classes/styles.css.js';\nimport styles from './styles.css.js';\nimport { DesktopDrawerProps, DrawerTriggersBarProps, DrawerItem, DrawerItemAriaLabels } from './interfaces';\n\n// We are using two landmarks per drawer, i.e. two NAVs and two ASIDEs, because of several\n// known bugs in NVDA that cause focus changes within a container to sometimes not be\n// announced. As a result, we use one region for the open button and one region for the\n// actual drawer content, always hiding the other one when it's not visible.\n// An alternative solution to follow a more classic implementation here to only have one\n// button that triggers the opening/closing of the drawer also did not work due to another\n// series of bugs in NVDA (together with Firefox) which prevent the changed expanded state\n// from being announced.\n// Even with this workaround in place, the announcement of the close button when opening a\n// panel in NVDA is not working correctly. The suspected root cause is one of the bugs below\n// as well.\n// Relevant tickets:\n// * https://github.com/nvaccess/nvda/issues/6606\n// * https://github.com/nvaccess/nvda/issues/5825\n// * https://github.com/nvaccess/nvda/issues/5247\n// * https://github.com/nvaccess/nvda/pull/8869 (reverted PR that was going to fix it)\nexport const Drawer = React.forwardRef(\n (\n {\n contentClassName,\n toggleClassName,\n closeClassName,\n width,\n type,\n toggleRefs,\n topOffset,\n bottomOffset,\n ariaLabels,\n drawersAriaLabels,\n children,\n isOpen,\n isMobile,\n onToggle,\n onClick,\n onLoseFocus,\n drawers,\n resizeHandle,\n }: DesktopDrawerProps,\n ref: React.Ref<HTMLDivElement>\n ) => {\n const openButtonWrapperRef = useRef<HTMLElement | null>(null);\n const { TagName, iconName, getLabels } = togglesConfig[type];\n const { mainLabel, closeLabel, openLabel } = getLabels(ariaLabels);\n const drawerContentWidthOpen = isMobile ? undefined : width;\n const drawerContentWidth = isOpen ? drawerContentWidthOpen : undefined;\n\n const getDrawersLabels = (labels: DrawerItemAriaLabels = {}) => ({\n drawerMainLabel: labels?.content,\n drawerOpenLabel: labels?.triggerButton,\n drawerCloseLabel: labels?.closeButton,\n });\n const { drawerMainLabel, drawerCloseLabel } = getDrawersLabels(drawersAriaLabels);\n\n const regularOpenButton = (\n <TagName ref={openButtonWrapperRef} aria-label={mainLabel} className={styles.toggle} aria-hidden={isOpen}>\n <AppLayoutButton\n ref={toggleRefs.toggle}\n className={toggleClassName}\n iconName={iconName}\n ariaLabel={openLabel}\n onClick={() => onToggle(true)}\n ariaExpanded={false}\n />\n </TagName>\n );\n\n return (\n <div\n ref={ref}\n className={clsx(styles.drawer, {\n [styles['drawer-closed']]: !isOpen,\n [testutilStyles['drawer-closed']]: !isOpen,\n [styles['drawer-mobile']]: isMobile,\n })}\n style={{ width: drawerContentWidth }}\n onBlur={\n onLoseFocus\n ? e => {\n if (!e.relatedTarget || !e.currentTarget.contains(e.relatedTarget)) {\n onLoseFocus(e);\n }\n }\n : undefined\n }\n onClick={event => {\n if (onClick) {\n onClick(event);\n }\n if (!isOpen) {\n // to prevent calling onToggle from the drawer when it's called from the toggle button\n if (\n openButtonWrapperRef.current === event.target ||\n !openButtonWrapperRef.current?.contains(event.target as Node)\n ) {\n onToggle(true);\n }\n }\n }}\n >\n <div\n style={{ width: drawerContentWidth, top: topOffset, bottom: bottomOffset }}\n className={clsx(styles['drawer-content'], contentClassName)}\n >\n {!isMobile && regularOpenButton}\n {resizeHandle}\n <TagName aria-label={drawers ? drawerMainLabel : mainLabel} aria-hidden={!isOpen}>\n <CloseButton\n ref={toggleRefs.close}\n className={closeClassName}\n ariaLabel={drawers ? drawerCloseLabel : closeLabel}\n onClick={() => {\n onToggle(false);\n drawers?.onChange({ activeDrawerId: undefined });\n }}\n />\n {children}\n </TagName>\n </div>\n </div>\n );\n }\n);\n\nexport function DrawerTriggersBar({\n isMobile,\n topOffset,\n bottomOffset,\n drawers,\n contentClassName,\n toggleClassName,\n}: DrawerTriggersBarProps) {\n return (\n <div\n className={clsx(styles.drawer, styles['drawer-closed'], testutilStyles['drawer-closed'], {\n [styles['drawer-mobile']]: isMobile,\n })}\n >\n <div\n style={{ top: topOffset, bottom: bottomOffset }}\n className={clsx(styles['drawer-content'], styles['non-interactive'])}\n >\n {!isMobile && (\n <aside aria-label={drawers?.ariaLabel} className={clsx(styles['drawer-triggers'], contentClassName)}>\n {drawers?.items?.map((item: DrawerItem, index: number) => (\n <AppLayoutButton\n className={clsx(\n toggleClassName,\n styles.trigger,\n styles['trigger-drawer'],\n drawers.activeDrawerId === item.id && styles.selected\n )}\n key={`drawer-trigger-${index}`}\n iconName={item.trigger.iconName}\n iconSvg={item.trigger.iconSvg}\n ariaLabel={item.ariaLabels?.triggerButton}\n onClick={() =>\n drawers.onChange({ activeDrawerId: item.id !== drawers.activeDrawerId ? item.id : undefined })\n }\n ariaExpanded={drawers.activeDrawerId !== undefined}\n />\n ))}\n </aside>\n )}\n </div>\n </div>\n );\n}\n"]}
@@ -1,15 +1,15 @@
1
1
 
2
2
  import './styles.scoped.css';
3
3
  export default {
4
- "toggle": "awsui_toggle_1uo6m_1dm4c_97",
5
- "drawer-triggers": "awsui_drawer-triggers_1uo6m_1dm4c_102",
6
- "drawer": "awsui_drawer_1uo6m_1dm4c_102",
7
- "drawer-mobile": "awsui_drawer-mobile_1uo6m_1dm4c_112",
8
- "drawer-closed": "awsui_drawer-closed_1uo6m_1dm4c_115",
9
- "drawer-content": "awsui_drawer-content_1uo6m_1dm4c_123",
10
- "non-interactive": "awsui_non-interactive_1uo6m_1dm4c_141",
11
- "trigger": "awsui_trigger_1uo6m_1dm4c_149",
12
- "trigger-drawer": "awsui_trigger-drawer_1uo6m_1dm4c_158",
13
- "selected": "awsui_selected_1uo6m_1dm4c_158"
4
+ "toggle": "awsui_toggle_1uo6m_1y65i_97",
5
+ "drawer-triggers": "awsui_drawer-triggers_1uo6m_1y65i_102",
6
+ "drawer": "awsui_drawer_1uo6m_1y65i_102",
7
+ "drawer-mobile": "awsui_drawer-mobile_1uo6m_1y65i_112",
8
+ "drawer-closed": "awsui_drawer-closed_1uo6m_1y65i_115",
9
+ "drawer-content": "awsui_drawer-content_1uo6m_1y65i_123",
10
+ "non-interactive": "awsui_non-interactive_1uo6m_1y65i_141",
11
+ "trigger": "awsui_trigger_1uo6m_1y65i_149",
12
+ "trigger-drawer": "awsui_trigger-drawer_1uo6m_1y65i_160",
13
+ "selected": "awsui_selected_1uo6m_1y65i_160"
14
14
  };
15
15
 
@@ -94,82 +94,79 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
94
94
  Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
95
95
  SPDX-License-Identifier: Apache-2.0
96
96
  */
97
- .awsui_toggle_1uo6m_1dm4c_97:not(#\9) {
97
+ .awsui_toggle_1uo6m_1y65i_97:not(#\9) {
98
98
  box-sizing: border-box;
99
99
  padding: var(--space-xxs-ynfts5, 4px) 7px;
100
100
  }
101
101
 
102
- .awsui_drawer-triggers_1uo6m_1dm4c_102:not(#\9) {
102
+ .awsui_drawer-triggers_1uo6m_1y65i_102:not(#\9) {
103
103
  box-sizing: border-box;
104
104
  }
105
105
 
106
- .awsui_drawer_1uo6m_1dm4c_102:not(#\9) {
106
+ .awsui_drawer_1uo6m_1y65i_102:not(#\9) {
107
107
  flex-shrink: 0;
108
108
  position: relative;
109
109
  word-wrap: break-word;
110
110
  box-shadow: var(--shadow-panel-v9vx7i, 0 1px 1px 0 rgba(0, 28, 36, 0.3), 1px 1px 1px 0 rgba(0, 28, 36, 0.15), -1px 1px 1px 0 rgba(0, 28, 36, 0.15));
111
111
  }
112
- .awsui_drawer_1uo6m_1dm4c_102:not(#\9):not(.awsui_drawer-mobile_1uo6m_1dm4c_112) {
112
+ .awsui_drawer_1uo6m_1y65i_102:not(#\9):not(.awsui_drawer-mobile_1uo6m_1y65i_112) {
113
113
  z-index: 830;
114
114
  }
115
- .awsui_drawer-closed_1uo6m_1dm4c_115:not(#\9) {
115
+ .awsui_drawer-closed_1uo6m_1y65i_115:not(#\9) {
116
116
  min-width: 40px;
117
117
  cursor: pointer;
118
118
  }
119
- .awsui_drawer-closed_1uo6m_1dm4c_115.awsui_drawer-mobile_1uo6m_1dm4c_112:not(#\9) {
119
+ .awsui_drawer-closed_1uo6m_1y65i_115.awsui_drawer-mobile_1uo6m_1y65i_112:not(#\9) {
120
120
  display: none;
121
121
  }
122
122
 
123
- .awsui_drawer-content_1uo6m_1dm4c_123:not(#\9) {
123
+ .awsui_drawer-content_1uo6m_1y65i_123:not(#\9) {
124
124
  position: fixed;
125
125
  overflow: auto;
126
126
  background-color: var(--color-background-layout-panel-content-r9pdjh, #ffffff);
127
127
  }
128
- .awsui_drawer-mobile_1uo6m_1dm4c_112 > .awsui_drawer-content_1uo6m_1dm4c_123:not(#\9) {
128
+ .awsui_drawer-mobile_1uo6m_1y65i_112 > .awsui_drawer-content_1uo6m_1y65i_123:not(#\9) {
129
129
  z-index: 1001;
130
130
  top: 0;
131
131
  bottom: 0;
132
132
  left: 0;
133
133
  right: 0;
134
134
  }
135
- .awsui_drawer-closed_1uo6m_1dm4c_115 > .awsui_drawer-content_1uo6m_1dm4c_123:not(#\9) {
135
+ .awsui_drawer-closed_1uo6m_1y65i_115 > .awsui_drawer-content_1uo6m_1y65i_123:not(#\9) {
136
136
  width: 40px;
137
137
  }
138
- .awsui_drawer-closed_1uo6m_1dm4c_115 > .awsui_drawer-content_1uo6m_1dm4c_123:not(#\9):hover {
138
+ .awsui_drawer-closed_1uo6m_1y65i_115 > .awsui_drawer-content_1uo6m_1y65i_123:not(#\9):hover {
139
139
  background: var(--color-background-layout-panel-hover-thdv3z, #eaeded);
140
140
  }
141
- .awsui_drawer-closed_1uo6m_1dm4c_115 > .awsui_drawer-content_1uo6m_1dm4c_123.awsui_non-interactive_1uo6m_1dm4c_141:not(#\9):hover {
141
+ .awsui_drawer-closed_1uo6m_1y65i_115 > .awsui_drawer-content_1uo6m_1y65i_123.awsui_non-interactive_1uo6m_1y65i_141:not(#\9):hover {
142
142
  background: var(--color-background-layout-panel-content-r9pdjh, #ffffff);
143
143
  cursor: default;
144
144
  }
145
- .awsui_drawer-content_1uo6m_1dm4c_123 > [aria-hidden=true]:not(#\9) {
145
+ .awsui_drawer-content_1uo6m_1y65i_123 > [aria-hidden=true]:not(#\9) {
146
146
  display: none;
147
147
  }
148
148
 
149
- .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger_1uo6m_1dm4c_149:not(#\9) {
150
- padding: var(--space-scaled-xs-6859qs, 8px) 6px;
151
- margin: 1px 6px;
152
- border-radius: 0;
149
+ .awsui_drawer-content_1uo6m_1y65i_123 > .awsui_drawer-triggers_1uo6m_1y65i_102 > .awsui_trigger_1uo6m_1y65i_149:not(#\9) {
150
+ background: var(--color-background-layout-toggle-default-wvi0uj, transparent);
153
151
  border: 0;
152
+ border-radius: 0;
153
+ color: var(--color-text-layout-toggle-3a24mh, #545b64);
154
+ padding: var(--space-scaled-xs-6859qs, 8px) var(--space-s-hv8c1d, 12px);
155
+ margin-top: 1px;
154
156
  }
155
- .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger_1uo6m_1dm4c_149:not(#\9):not(:last-child) {
156
- box-shadow: 0px 1px var(--color-shadow-layout-panel-trigger-lceo1i, #d5dbdb);
157
+ .awsui_drawer-content_1uo6m_1y65i_123 > .awsui_drawer-triggers_1uo6m_1y65i_102 > .awsui_trigger_1uo6m_1y65i_149:not(#\9):not(:last-child) {
158
+ box-shadow: 0px 1px var(--color-shadow-layout-toggle-ys7l56, #d5dbdb);
157
159
  }
158
- .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger-drawer_1uo6m_1dm4c_158:not(#\9):hover:not(.awsui_selected_1uo6m_1dm4c_158) {
159
- color: var(--color-text-layout-panel-trigger-hover-5qaiq9, #0073bb);
160
+ .awsui_drawer-content_1uo6m_1y65i_123 > .awsui_drawer-triggers_1uo6m_1y65i_102 > .awsui_trigger-drawer_1uo6m_1y65i_160:not(#\9):hover:not(.awsui_selected_1uo6m_1y65i_160) {
161
+ color: var(--color-text-layout-toggle-hover-hsrbuh, #0073bb);
160
162
  }
161
- .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger-drawer_1uo6m_1dm4c_158:not(#\9):hover:not(.awsui_selected_1uo6m_1dm4c_158):not(:last-child) {
162
- box-shadow: 0px 1px var(--color-shadow-layout-panel-trigger-lceo1i, #d5dbdb);
163
+ .awsui_drawer-content_1uo6m_1y65i_123 > .awsui_drawer-triggers_1uo6m_1y65i_102 > .awsui_trigger-drawer_1uo6m_1y65i_160:not(#\9):hover:not(.awsui_selected_1uo6m_1y65i_160):not(:last-child) {
164
+ box-shadow: 0px 1px var(--color-shadow-layout-toggle-ys7l56, #d5dbdb);
163
165
  }
164
- .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger_1uo6m_1dm4c_149.awsui_selected_1uo6m_1dm4c_158:not(#\9), .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger_1uo6m_1dm4c_149.awsui_selected_1uo6m_1dm4c_158:not(#\9):hover {
165
- padding: var(--space-scaled-xs-6859qs, 8px) var(--space-s-hv8c1d, 12px);
166
- margin: 0;
167
- border-top: 1px solid var(--color-background-layout-panel-trigger-active-opo2jh, #0073bb);
168
- border-bottom: 1px solid var(--color-background-layout-panel-trigger-active-opo2jh, #0073bb);
169
- background-color: var(--color-background-layout-panel-trigger-active-opo2jh, #0073bb);
170
- color: var(--color-text-layout-panel-trigger-active-km1y5a, #ffffff);
166
+ .awsui_drawer-content_1uo6m_1y65i_123 > .awsui_drawer-triggers_1uo6m_1y65i_102 > .awsui_trigger_1uo6m_1y65i_149.awsui_selected_1uo6m_1y65i_160:not(#\9), .awsui_drawer-content_1uo6m_1y65i_123 > .awsui_drawer-triggers_1uo6m_1y65i_102 > .awsui_trigger_1uo6m_1y65i_149.awsui_selected_1uo6m_1y65i_160:not(#\9):hover {
167
+ background-color: var(--color-background-layout-toggle-selected-default-kcqbvr, #0073bb);
168
+ border-top: 1px solid var(--color-background-layout-toggle-selected-default-kcqbvr, #0073bb);
171
169
  box-shadow: none;
172
- }
173
- .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger_1uo6m_1dm4c_149.awsui_selected_1uo6m_1dm4c_158:not(#\9):hover, .awsui_drawer-content_1uo6m_1dm4c_123 > .awsui_drawer-triggers_1uo6m_1dm4c_102 > .awsui_trigger_1uo6m_1dm4c_149.awsui_selected_1uo6m_1dm4c_158:not(#\9):hover:hover {
174
- cursor: default;
170
+ color: var(--color-text-layout-toggle-active-y84imf, #ffffff);
171
+ margin: 0;
175
172
  }
@@ -2,15 +2,15 @@
2
2
  // es-module interop with Babel and Typescript
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  module.exports.default = {
5
- "toggle": "awsui_toggle_1uo6m_1dm4c_97",
6
- "drawer-triggers": "awsui_drawer-triggers_1uo6m_1dm4c_102",
7
- "drawer": "awsui_drawer_1uo6m_1dm4c_102",
8
- "drawer-mobile": "awsui_drawer-mobile_1uo6m_1dm4c_112",
9
- "drawer-closed": "awsui_drawer-closed_1uo6m_1dm4c_115",
10
- "drawer-content": "awsui_drawer-content_1uo6m_1dm4c_123",
11
- "non-interactive": "awsui_non-interactive_1uo6m_1dm4c_141",
12
- "trigger": "awsui_trigger_1uo6m_1dm4c_149",
13
- "trigger-drawer": "awsui_trigger-drawer_1uo6m_1dm4c_158",
14
- "selected": "awsui_selected_1uo6m_1dm4c_158"
5
+ "toggle": "awsui_toggle_1uo6m_1y65i_97",
6
+ "drawer-triggers": "awsui_drawer-triggers_1uo6m_1y65i_102",
7
+ "drawer": "awsui_drawer_1uo6m_1y65i_102",
8
+ "drawer-mobile": "awsui_drawer-mobile_1uo6m_1y65i_112",
9
+ "drawer-closed": "awsui_drawer-closed_1uo6m_1y65i_115",
10
+ "drawer-content": "awsui_drawer-content_1uo6m_1y65i_123",
11
+ "non-interactive": "awsui_non-interactive_1uo6m_1y65i_141",
12
+ "trigger": "awsui_trigger_1uo6m_1y65i_149",
13
+ "trigger-drawer": "awsui_trigger-drawer_1uo6m_1y65i_160",
14
+ "selected": "awsui_selected_1uo6m_1y65i_160"
15
15
  };
16
16
 
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"lib/default/","sources":["app-layout/index.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAiF,MAAM,OAAO,CAAC;AAMtG,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAyC9C,OAAO,EAAE,cAAc,EAAE,CAAC;AAE1B,QAAA,MAAM,SAAS,2FA8Bd,CAAC;AA2sBF,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"lib/default/","sources":["app-layout/index.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAiF,MAAM,OAAO,CAAC;AAMtG,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAyC9C,OAAO,EAAE,cAAc,EAAE,CAAC;AAE1B,QAAA,MAAM,SAAS,2FA8Bd,CAAC;AAysBF,eAAe,SAAS,CAAC"}
@@ -400,9 +400,9 @@ const OldAppLayout = React.forwardRef((_a, ref) => {
400
400
  hasBreadcrumbs: !!breadcrumbs,
401
401
  } }, content))),
402
402
  finalSplitPanePosition === 'bottom' && splitPanelWrapped),
403
- finalSplitPanePosition === 'side' && (React.createElement(SideSplitPanelDrawer, { topOffset: headerHeight, bottomOffset: footerHeight, displayed: splitPanelDisplayed, width: splitPanelOpen ? splitPanelSize : undefined }, splitPanelWrapped)),
403
+ finalSplitPanePosition === 'side' && (React.createElement(SideSplitPanelDrawer, { topOffset: headerHeight, bottomOffset: footerHeight, displayed: splitPanelDisplayed, width: splitPanelOpen && splitPanel ? splitPanelSize : undefined }, splitPanelWrapped)),
404
404
  ((hasDrawers && (selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.id)) || (!hasDrawers && !toolsHide)) &&
405
- (hasDrawers ? (React.createElement(ResizableDrawer, { contentClassName: (selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.id) === 'tools' ? testutilStyles.tools : testutilStyles['active-drawer'], toggleClassName: (selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.id) === 'tools' ? testutilStyles['tools-toggle'] : testutilStyles['drawers-trigger'], closeClassName: (selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.id) === 'tools'
405
+ (hasDrawers ? (React.createElement(ResizableDrawer, { contentClassName: (selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.id) === 'tools' ? testutilStyles.tools : testutilStyles['active-drawer'], toggleClassName: testutilStyles['tools-toggle'], closeClassName: (selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.id) === 'tools'
406
406
  ? testutilStyles['tools-close']
407
407
  : testutilStyles['active-drawer-close-button'], ariaLabels: ariaLabels, drawersAriaLabels: selectedDrawer === null || selectedDrawer === void 0 ? void 0 : selectedDrawer.ariaLabels, width: !isResizeInvalid ? drawerSize : toolsWidth, bottomOffset: footerHeight, topOffset: headerHeight, isMobile: isMobile, onToggle: onToolsToggle, isOpen: toolsOpen || activeDrawerId !== undefined, toggleRefs: toolsRefs, type: "tools", onLoseFocus: hasDrawers ? loseDrawersFocus : loseToolsFocus, activeDrawer: selectedDrawer, drawers: {
408
408
  items: tools && !toolsHide ? [toolsItem, ...drawers.items] : drawers.items,