@cloudscape-design/components 3.0.459 → 3.0.460

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 (255) hide show
  1. package/alert/styles.css.js +25 -25
  2. package/alert/styles.scoped.css +59 -53
  3. package/alert/styles.selectors.js +25 -25
  4. package/anchor-navigation/styles.css.js +8 -8
  5. package/anchor-navigation/styles.scoped.css +39 -30
  6. package/anchor-navigation/styles.selectors.js +8 -8
  7. package/annotation-context/annotation/styles.css.js +24 -24
  8. package/annotation-context/annotation/styles.scoped.css +55 -48
  9. package/annotation-context/annotation/styles.selectors.js +24 -24
  10. package/app-layout/content-wrapper/styles.css.js +3 -3
  11. package/app-layout/content-wrapper/styles.scoped.css +15 -15
  12. package/app-layout/content-wrapper/styles.selectors.js +3 -3
  13. package/app-layout/drawer/styles.css.js +12 -12
  14. package/app-layout/drawer/styles.scoped.css +29 -30
  15. package/app-layout/drawer/styles.selectors.js +12 -12
  16. package/app-layout/interfaces.d.ts +3 -4
  17. package/app-layout/interfaces.d.ts.map +1 -1
  18. package/app-layout/interfaces.js.map +1 -1
  19. package/app-layout/mobile-toolbar/styles.css.js +8 -8
  20. package/app-layout/mobile-toolbar/styles.scoped.css +18 -17
  21. package/app-layout/mobile-toolbar/styles.selectors.js +8 -8
  22. package/app-layout/notifications/styles.css.js +3 -3
  23. package/app-layout/notifications/styles.scoped.css +6 -6
  24. package/app-layout/notifications/styles.selectors.js +3 -3
  25. package/app-layout/split-panel/styles.css.js +2 -2
  26. package/app-layout/split-panel/styles.scoped.css +3 -3
  27. package/app-layout/split-panel/styles.selectors.js +2 -2
  28. package/app-layout/styles.css.js +16 -16
  29. package/app-layout/styles.scoped.css +26 -26
  30. package/app-layout/styles.selectors.js +16 -16
  31. package/app-layout/toggles/styles.css.js +2 -2
  32. package/app-layout/toggles/styles.scoped.css +10 -9
  33. package/app-layout/toggles/styles.selectors.js +2 -2
  34. package/app-layout/utils/use-drawers.js.map +1 -1
  35. package/app-layout/visual-refresh/context.js +1 -1
  36. package/app-layout/visual-refresh/context.js.map +1 -1
  37. package/app-layout/visual-refresh/styles.css.js +80 -80
  38. package/app-layout/visual-refresh/styles.scoped.css +268 -251
  39. package/app-layout/visual-refresh/styles.selectors.js +80 -80
  40. package/area-chart/styles.css.js +6 -6
  41. package/area-chart/styles.scoped.css +12 -11
  42. package/area-chart/styles.selectors.js +6 -6
  43. package/attribute-editor/styles.css.js +14 -14
  44. package/attribute-editor/styles.scoped.css +30 -29
  45. package/attribute-editor/styles.selectors.js +14 -14
  46. package/autosuggest/styles.css.js +3 -3
  47. package/autosuggest/styles.scoped.css +5 -5
  48. package/autosuggest/styles.selectors.js +3 -3
  49. package/badge/styles.css.js +5 -5
  50. package/badge/styles.scoped.css +11 -7
  51. package/badge/styles.selectors.js +5 -5
  52. package/bar-chart/index.d.ts +1 -1
  53. package/bar-chart/index.d.ts.map +1 -1
  54. package/bar-chart/index.js +2 -2
  55. package/bar-chart/index.js.map +1 -1
  56. package/bar-chart/interfaces.d.ts +8 -3
  57. package/bar-chart/interfaces.d.ts.map +1 -1
  58. package/bar-chart/interfaces.js.map +1 -1
  59. package/box/styles.css.js +190 -190
  60. package/box/styles.scoped.css +244 -240
  61. package/box/styles.selectors.js +190 -190
  62. package/breadcrumb-group/item/styles.css.js +9 -9
  63. package/breadcrumb-group/item/styles.scoped.css +20 -19
  64. package/breadcrumb-group/item/styles.selectors.js +9 -9
  65. package/breadcrumb-group/styles.css.js +7 -7
  66. package/breadcrumb-group/styles.scoped.css +28 -21
  67. package/breadcrumb-group/styles.selectors.js +7 -7
  68. package/button/styles.css.js +20 -20
  69. package/button/styles.scoped.css +155 -153
  70. package/button/styles.selectors.js +20 -20
  71. package/button-dropdown/category-elements/styles.css.js +13 -13
  72. package/button-dropdown/category-elements/styles.scoped.css +60 -50
  73. package/button-dropdown/category-elements/styles.selectors.js +13 -13
  74. package/button-dropdown/item-element/styles.css.js +15 -15
  75. package/button-dropdown/item-element/styles.scoped.css +38 -33
  76. package/button-dropdown/item-element/styles.selectors.js +15 -15
  77. package/button-dropdown/mobile-expandable-group/styles.css.js +5 -5
  78. package/button-dropdown/mobile-expandable-group/styles.scoped.css +8 -8
  79. package/button-dropdown/mobile-expandable-group/styles.selectors.js +5 -5
  80. package/button-dropdown/styles.css.js +15 -15
  81. package/button-dropdown/styles.scoped.css +39 -36
  82. package/button-dropdown/styles.selectors.js +15 -15
  83. package/calendar/styles.css.js +18 -18
  84. package/calendar/styles.scoped.css +75 -59
  85. package/calendar/styles.selectors.js +18 -18
  86. package/cards/styles.css.js +38 -38
  87. package/cards/styles.scoped.css +110 -94
  88. package/cards/styles.selectors.js +38 -38
  89. package/code-editor/resizable-box/styles.css.js +3 -3
  90. package/code-editor/resizable-box/styles.scoped.css +10 -10
  91. package/code-editor/resizable-box/styles.selectors.js +3 -3
  92. package/code-editor/styles.css.js +32 -32
  93. package/code-editor/styles.scoped.css +210 -198
  94. package/code-editor/styles.selectors.js +32 -32
  95. package/collection-preferences/content-display/styles.css.js +11 -11
  96. package/collection-preferences/content-display/styles.scoped.css +40 -30
  97. package/collection-preferences/content-display/styles.selectors.js +11 -11
  98. package/collection-preferences/styles.css.js +37 -37
  99. package/collection-preferences/styles.scoped.css +79 -66
  100. package/collection-preferences/styles.selectors.js +37 -37
  101. package/column-layout/flexible-column-layout/styles.css.js +5 -5
  102. package/column-layout/flexible-column-layout/styles.scoped.css +8 -9
  103. package/column-layout/flexible-column-layout/styles.selectors.js +5 -5
  104. package/column-layout/styles.css.js +13 -13
  105. package/column-layout/styles.scoped.css +70 -64
  106. package/column-layout/styles.selectors.js +13 -13
  107. package/container/styles.css.js +28 -28
  108. package/container/styles.scoped.css +106 -98
  109. package/container/styles.selectors.js +28 -28
  110. package/content-layout/styles.css.js +7 -7
  111. package/content-layout/styles.scoped.css +15 -15
  112. package/content-layout/styles.selectors.js +7 -7
  113. package/date-picker/styles.css.js +7 -7
  114. package/date-picker/styles.scoped.css +12 -12
  115. package/date-picker/styles.selectors.js +7 -7
  116. package/date-range-picker/calendar/grids/styles.css.js +25 -25
  117. package/date-range-picker/calendar/grids/styles.scoped.css +71 -60
  118. package/date-range-picker/calendar/grids/styles.selectors.js +25 -25
  119. package/date-range-picker/relative-range/styles.css.js +9 -9
  120. package/date-range-picker/relative-range/styles.scoped.css +21 -21
  121. package/date-range-picker/relative-range/styles.selectors.js +9 -9
  122. package/date-range-picker/styles.css.js +38 -38
  123. package/date-range-picker/styles.scoped.css +73 -68
  124. package/date-range-picker/styles.selectors.js +38 -38
  125. package/drawer/styles.css.js +3 -3
  126. package/drawer/styles.scoped.css +21 -18
  127. package/drawer/styles.selectors.js +3 -3
  128. package/expandable-section/expandable-section-container.d.ts +2 -2
  129. package/expandable-section/expandable-section-container.d.ts.map +1 -1
  130. package/expandable-section/expandable-section-container.js.map +1 -1
  131. package/expandable-section/expandable-section-header.d.ts +3 -2
  132. package/expandable-section/expandable-section-header.d.ts.map +1 -1
  133. package/expandable-section/expandable-section-header.js +7 -11
  134. package/expandable-section/expandable-section-header.js.map +1 -1
  135. package/expandable-section/interfaces.d.ts +0 -1
  136. package/expandable-section/interfaces.d.ts.map +1 -1
  137. package/expandable-section/interfaces.js.map +1 -1
  138. package/expandable-section/internal.d.ts +2 -4
  139. package/expandable-section/internal.d.ts.map +1 -1
  140. package/expandable-section/internal.js.map +1 -1
  141. package/expandable-section/styles.css.js +29 -32
  142. package/expandable-section/styles.scoped.css +99 -106
  143. package/expandable-section/styles.selectors.js +29 -32
  144. package/expandable-section/utils.d.ts +2 -3
  145. package/expandable-section/utils.d.ts.map +1 -1
  146. package/expandable-section/utils.js +1 -4
  147. package/expandable-section/utils.js.map +1 -1
  148. package/file-upload/dropzone/styles.css.js +2 -2
  149. package/file-upload/dropzone/styles.scoped.css +8 -4
  150. package/file-upload/dropzone/styles.selectors.js +2 -2
  151. package/file-upload/file-option/styles.css.js +7 -7
  152. package/file-upload/file-option/styles.scoped.css +15 -15
  153. package/file-upload/file-option/styles.selectors.js +7 -7
  154. package/file-upload/styles.css.js +2 -2
  155. package/file-upload/styles.scoped.css +4 -4
  156. package/file-upload/styles.selectors.js +2 -2
  157. package/flashbar/styles.css.js +47 -47
  158. package/flashbar/styles.scoped.css +220 -215
  159. package/flashbar/styles.selectors.js +47 -47
  160. package/form/styles.css.js +9 -9
  161. package/form/styles.scoped.css +18 -18
  162. package/form/styles.selectors.js +9 -9
  163. package/form-field/styles.css.js +19 -19
  164. package/form-field/styles.scoped.css +34 -34
  165. package/form-field/styles.selectors.js +19 -19
  166. package/internal/components/cartesian-chart/interfaces.d.ts.map +1 -1
  167. package/internal/components/cartesian-chart/interfaces.js.map +1 -1
  168. package/internal/components/chart-plot/index.d.ts +1 -1
  169. package/internal/components/chart-plot/index.d.ts.map +1 -1
  170. package/internal/components/chart-plot/index.js.map +1 -1
  171. package/internal/components/chart-series-details/index.d.ts +4 -12
  172. package/internal/components/chart-series-details/index.d.ts.map +1 -1
  173. package/internal/components/chart-series-details/index.js +10 -46
  174. package/internal/components/chart-series-details/index.js.map +1 -1
  175. package/internal/components/chart-series-details/styles.css.js +5 -19
  176. package/internal/components/chart-series-details/styles.scoped.css +15 -141
  177. package/internal/components/chart-series-details/styles.selectors.js +5 -19
  178. package/internal/environment.js +1 -1
  179. package/internal/environment.json +1 -1
  180. package/internal/manifest.json +1 -1
  181. package/line-chart/interfaces.d.ts +8 -2
  182. package/line-chart/interfaces.d.ts.map +1 -1
  183. package/line-chart/interfaces.js.map +1 -1
  184. package/mixed-line-bar-chart/chart-container.d.ts +1 -2
  185. package/mixed-line-bar-chart/chart-container.d.ts.map +1 -1
  186. package/mixed-line-bar-chart/chart-container.js +8 -17
  187. package/mixed-line-bar-chart/chart-container.js.map +1 -1
  188. package/mixed-line-bar-chart/chart-popover.d.ts +0 -1
  189. package/mixed-line-bar-chart/chart-popover.d.ts.map +1 -1
  190. package/mixed-line-bar-chart/chart-popover.js +3 -13
  191. package/mixed-line-bar-chart/chart-popover.js.map +1 -1
  192. package/mixed-line-bar-chart/format-highlighted.d.ts +2 -7
  193. package/mixed-line-bar-chart/format-highlighted.d.ts.map +1 -1
  194. package/mixed-line-bar-chart/format-highlighted.js +5 -25
  195. package/mixed-line-bar-chart/format-highlighted.js.map +1 -1
  196. package/mixed-line-bar-chart/interfaces.d.ts +6 -38
  197. package/mixed-line-bar-chart/interfaces.d.ts.map +1 -1
  198. package/mixed-line-bar-chart/interfaces.js.map +1 -1
  199. package/mixed-line-bar-chart/internal.d.ts +1 -1
  200. package/mixed-line-bar-chart/internal.d.ts.map +1 -1
  201. package/mixed-line-bar-chart/internal.js +2 -2
  202. package/mixed-line-bar-chart/internal.js.map +1 -1
  203. package/modal/styles.css.js +23 -23
  204. package/modal/styles.scoped.css +39 -39
  205. package/modal/styles.selectors.js +23 -23
  206. package/package.json +1 -1
  207. package/pie-chart/interfaces.d.ts +5 -5
  208. package/pie-chart/interfaces.d.ts.map +1 -1
  209. package/pie-chart/interfaces.js.map +1 -1
  210. package/pie-chart/pie-chart.d.ts +1 -1
  211. package/pie-chart/pie-chart.d.ts.map +1 -1
  212. package/pie-chart/pie-chart.js +18 -21
  213. package/pie-chart/pie-chart.js.map +1 -1
  214. package/table/column-widths-utils.d.ts +0 -1
  215. package/table/column-widths-utils.d.ts.map +1 -1
  216. package/table/column-widths-utils.js +0 -18
  217. package/table/column-widths-utils.js.map +1 -1
  218. package/table/internal.d.ts.map +1 -1
  219. package/table/internal.js +6 -7
  220. package/table/internal.js.map +1 -1
  221. package/table/node-data-cell.d.ts +15 -0
  222. package/table/node-data-cell.d.ts.map +1 -0
  223. package/table/node-data-cell.js +25 -0
  224. package/table/node-data-cell.js.map +1 -0
  225. package/table/sticky-columns/use-sticky-columns.js +1 -1
  226. package/table/sticky-columns/use-sticky-columns.js.map +1 -1
  227. package/table/thead.d.ts +1 -0
  228. package/table/thead.d.ts.map +1 -1
  229. package/table/thead.js +18 -3
  230. package/table/thead.js.map +1 -1
  231. package/table/use-column-widths.d.ts +3 -5
  232. package/table/use-column-widths.d.ts.map +1 -1
  233. package/table/use-column-widths.js +11 -61
  234. package/table/use-column-widths.js.map +1 -1
  235. package/table/use-sticky-header.d.ts.map +1 -1
  236. package/table/use-sticky-header.js +13 -0
  237. package/table/use-sticky-header.js.map +1 -1
  238. package/test-utils/dom/internal/chart-popover.d.ts +0 -8
  239. package/test-utils/dom/internal/chart-popover.js +0 -23
  240. package/test-utils/dom/internal/chart-popover.js.map +1 -1
  241. package/test-utils/selectors/internal/chart-popover.d.ts +0 -8
  242. package/test-utils/selectors/internal/chart-popover.js +0 -22
  243. package/test-utils/selectors/internal/chart-popover.js.map +1 -1
  244. package/test-utils/tsconfig.tsbuildinfo +1 -1
  245. package/tiles/styles.css.js +29 -29
  246. package/tiles/styles.scoped.css +97 -91
  247. package/tiles/styles.selectors.js +29 -29
  248. package/internal/components/chart-series-details/series-details-text.d.ts +0 -2
  249. package/internal/components/chart-series-details/series-details-text.d.ts.map +0 -1
  250. package/internal/components/chart-series-details/series-details-text.js +0 -17
  251. package/internal/components/chart-series-details/series-details-text.js.map +0 -1
  252. package/table/no-data-cell.d.ts +0 -13
  253. package/table/no-data-cell.d.ts.map +0 -1
  254. package/table/no-data-cell.js +0 -24
  255. package/table/no-data-cell.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"expandable-section-header.js","sourceRoot":"lib/default/","sources":["expandable-section/expandable-section-header.tsx"],"names":[],"mappings":"AAGA,OAAO,KAA6D,MAAM,OAAO,CAAC;AAClF,OAAO,YAAY,MAAM,kBAAkB,CAAC;AAC5C,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,cAAc,EAAE,EAAE,WAAW,IAAI,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AACtF,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,QAAQ,EAAE,MAAM,+CAA+C,CAAC;AACzE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AS,EAAE,SAAS,IAChB,kBAAkB,GAErB,MAAM,CACoB,CAC9B,CAAC;AACJ,CAAC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { ExpandableSectionProps, InternalVariant } from './interfaces';\nimport React, { KeyboardEventHandler, MouseEventHandler, ReactNode } from 'react';\nimport InternalIcon from '../icon/internal';\nimport clsx from 'clsx';\nimport styles from './styles.css.js';\nimport InternalHeader, { Description as HeaderDescription } from '../header/internal';\nimport { isDevelopment } from '../internal/is-development';\nimport { warnOnce } from '@cloudscape-design/component-toolkit/internal';\nimport { variantSupportsDescription, variantSupportsInteractiveElements } from './utils';\n\nexport const componentName = 'ExpandableSection';\n\ninterface ExpandableDefaultHeaderProps {\n id: string;\n descriptionId?: string;\n className?: string;\n children?: ReactNode;\n expanded: boolean;\n ariaControls: string;\n ariaLabel?: string;\n onKeyUp: KeyboardEventHandler;\n onKeyDown: KeyboardEventHandler;\n onClick: MouseEventHandler;\n icon: JSX.Element;\n variant: InternalVariant;\n}\n\ninterface ExpandableNavigationHeaderProps extends Omit<ExpandableDefaultHeaderProps, 'onKeyUp' | 'onKeyDown'> {\n ariaLabelledBy?: string;\n}\n\ninterface ExpandableHeaderTextWrapperProps extends ExpandableDefaultHeaderProps {\n headerDescription?: ReactNode;\n headerCounter?: string;\n headerInfo?: ReactNode;\n headerActions?: ReactNode;\n headingTagOverride?: ExpandableSectionProps.HeadingTag;\n}\n\ninterface ExpandableSectionHeaderProps extends Omit<ExpandableDefaultHeaderProps, 'children' | 'icon'> {\n header?: ReactNode;\n headerText?: ReactNode;\n headerDescription?: ReactNode;\n headerCounter?: string;\n headerInfo?: ReactNode;\n headerActions?: ReactNode;\n headingTagOverride?: ExpandableSectionProps.HeadingTag;\n ariaLabelledBy?: string;\n}\n\nconst ExpandableDeprecatedHeader = ({\n id,\n className,\n onClick,\n ariaLabel,\n ariaControls,\n expanded,\n children,\n icon,\n onKeyUp,\n onKeyDown,\n variant,\n}: ExpandableDefaultHeaderProps) => {\n return (\n <div\n id={id}\n role=\"button\"\n className={clsx(className, styles['expand-button'], styles['click-target'], styles['header-deprecated'])}\n tabIndex={0}\n onKeyUp={onKeyUp}\n onKeyDown={onKeyDown}\n onClick={onClick}\n aria-label={ariaLabel}\n aria-controls={ariaControls}\n aria-expanded={expanded}\n >\n <div className={clsx(styles['icon-container'], styles[`icon-container-${variant}`])}>{icon}</div>\n {children}\n </div>\n );\n};\n\nconst ExpandableNavigationHeader = ({\n id,\n className,\n onClick,\n ariaLabelledBy,\n ariaLabel,\n ariaControls,\n expanded,\n children,\n icon,\n}: ExpandableNavigationHeaderProps) => {\n return (\n <div id={id} className={clsx(className, styles['click-target'])}>\n <button\n className={clsx(styles['icon-container'], styles['expand-button'])}\n aria-labelledby={ariaLabelledBy}\n aria-label={ariaLabel}\n aria-controls={ariaControls}\n aria-expanded={expanded}\n type=\"button\"\n onClick={onClick}\n >\n {icon}\n </button>\n {children}\n </div>\n );\n};\n\nconst ExpandableHeaderTextWrapper = ({\n id,\n descriptionId,\n className,\n onClick,\n ariaLabel,\n ariaControls,\n expanded,\n children,\n icon,\n headerDescription,\n headerCounter,\n headerInfo,\n headerActions,\n variant,\n headingTagOverride,\n onKeyUp,\n onKeyDown,\n}: ExpandableHeaderTextWrapperProps) => {\n const isContainer = variant === 'container';\n const HeadingTag = headingTagOverride || 'div';\n const supportsInteractiveElements = variantSupportsInteractiveElements(variant);\n const restrictClickableArea = supportsInteractiveElements && (headerInfo || headerActions);\n const actions = supportsInteractiveElements && headerActions;\n const description = variantSupportsDescription(variant) && headerDescription && (\n <span id={descriptionId} className={styles[`description-${variant}`]}>\n {headerDescription}\n </span>\n );\n const listeners = { onClick, onKeyDown, onKeyUp };\n\n // If interactive elements are present, constrain the clickable area to only the icon and the header text\n // to prevent nesting interactive elements.\n const headerButtonListeners = restrictClickableArea ? listeners : undefined;\n // For the default and footer variants with description,\n // include also the immediate wrapper around it to include the entire row for backwards compatibility,\n // but exclude the description.\n const headingTagListeners = !headerButtonListeners && !isContainer && description ? listeners : undefined;\n // For all other cases, make the entire header clickable for backwards compatibility.\n const wrapperListeners = !headerButtonListeners && !headingTagListeners ? listeners : undefined;\n const headerButton = (\n <span\n className={clsx(\n styles['expand-button'],\n isContainer ? styles['header-container-button'] : styles['header-button'],\n headerButtonListeners && styles['click-target']\n )}\n role=\"button\"\n tabIndex={0}\n aria-label={ariaLabel}\n aria-labelledby={!ariaLabel && description ? id : undefined}\n aria-describedby={description ? descriptionId : undefined}\n aria-controls={ariaControls}\n aria-expanded={expanded}\n {...headerButtonListeners}\n >\n <span className={clsx(styles['icon-container'], styles[`icon-container-${variant}`])}>{icon}</span>\n <span id={id} className={styles['header-text']}>\n {children}\n </span>\n </span>\n );\n\n return (\n <div className={clsx(className, wrapperListeners && styles['click-target'])} {...wrapperListeners}>\n {isContainer ? (\n <InternalHeader\n variant=\"h2\"\n description={description}\n counter={headerCounter}\n info={headerInfo}\n actions={actions}\n headingTagOverride={headingTagOverride}\n >\n {headerButton}\n </InternalHeader>\n ) : (\n <>\n <div className={clsx(actions && styles['header-actions-wrapper'])}>\n <HeadingTag\n className={clsx(styles['header-wrapper'], headingTagListeners && styles['click-target'])}\n {...headingTagListeners}\n >\n {headerButton}\n </HeadingTag>\n {actions}\n </div>\n {description && <HeaderDescription variantOverride=\"h3\">{description}</HeaderDescription>}\n </>\n )}\n </div>\n );\n};\n\nexport const ExpandableSectionHeader = ({\n id,\n descriptionId,\n className,\n variant,\n header,\n headerText,\n headerDescription,\n headerCounter,\n headerInfo,\n headerActions,\n headingTagOverride,\n expanded,\n ariaControls,\n ariaLabel,\n ariaLabelledBy,\n onKeyUp,\n onKeyDown,\n onClick,\n}: ExpandableSectionHeaderProps) => {\n const icon = (\n <InternalIcon\n size={variant === 'container' ? 'medium' : 'normal'}\n className={clsx(styles.icon, expanded && styles.expanded)}\n name=\"caret-down-filled\"\n />\n );\n const defaultHeaderProps = {\n id: id,\n icon: icon,\n expanded: expanded,\n ariaControls: ariaControls,\n ariaLabel: ariaLabel,\n onClick: onClick,\n variant,\n };\n\n if ((headerCounter || headerInfo || headerActions) && !variantSupportsInteractiveElements(variant) && isDevelopment) {\n warnOnce(\n componentName,\n 'The `headerCounter`, `headerInfo` and `headerActions` props are only supported for the \"container\" variant.'\n );\n }\n\n if (headerDescription && !variantSupportsDescription(variant) && isDevelopment) {\n warnOnce(componentName, `The \\`headerDescription\\` prop is not supported for the ${variant} variant.`);\n }\n\n const wrapperClassName = clsx(styles.wrapper, styles[`wrapper-${variant}`], expanded && styles['wrapper-expanded']);\n if (variant === 'navigation') {\n return (\n <ExpandableNavigationHeader\n className={clsx(className, wrapperClassName)}\n ariaLabelledBy={ariaLabelledBy}\n {...defaultHeaderProps}\n >\n {headerText ?? header}\n </ExpandableNavigationHeader>\n );\n }\n\n if (headerText) {\n return (\n <ExpandableHeaderTextWrapper\n className={clsx(className, wrapperClassName, expanded && styles.expanded)}\n descriptionId={descriptionId}\n headerDescription={headerDescription}\n headerCounter={headerCounter}\n headerInfo={headerInfo}\n headerActions={headerActions}\n headingTagOverride={headingTagOverride}\n onKeyUp={onKeyUp}\n onKeyDown={onKeyDown}\n {...defaultHeaderProps}\n >\n {headerText}\n </ExpandableHeaderTextWrapper>\n );\n }\n\n if (variant === 'container' && header && isDevelopment) {\n warnOnce(componentName, 'Use `headerText` instead of `header` to provide the button within the heading for a11y.');\n }\n\n return (\n <ExpandableDeprecatedHeader\n className={clsx(className, wrapperClassName, styles.focusable, expanded && styles.expanded)}\n onKeyUp={onKeyUp}\n onKeyDown={onKeyDown}\n {...defaultHeaderProps}\n >\n {header}\n </ExpandableDeprecatedHeader>\n );\n};\n"]}
1
+ {"version":3,"file":"expandable-section-header.js","sourceRoot":"lib/default/","sources":["expandable-section/expandable-section-header.tsx"],"names":[],"mappings":"AAGA,OAAO,KAA6D,MAAM,OAAO,CAAC;AAClF,OAAO,YAAY,MAAM,kBAAkB,CAAC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O,EAAE,OAAO,EAChB,SAAS,EAAE,SAAS,IAChB,kBAAkB,GAErB,MAAM,CACoB,CAC9B,CAAC;AACJ,CAAC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { ExpandableSectionProps } from './interfaces';\nimport React, { KeyboardEventHandler, MouseEventHandler, ReactNode } from 'react';\nimport InternalIcon from '../icon/internal';\nimport clsx from 'clsx';\nimport styles from './styles.css.js';\nimport InternalHeader, { Description as HeaderDescription } from '../header/internal';\nimport { isDevelopment } from '../internal/is-development';\nimport { warnOnce } from '@cloudscape-design/component-toolkit/internal';\nimport { variantSupportsDescription } from './utils';\n\nexport const componentName = 'ExpandableSection';\n\ninterface ExpandableDefaultHeaderProps {\n id: string;\n descriptionId?: string;\n className?: string;\n children?: ReactNode;\n expanded: boolean;\n ariaControls: string;\n ariaLabel?: string;\n onKeyUp: KeyboardEventHandler;\n onKeyDown: KeyboardEventHandler;\n onClick: MouseEventHandler;\n icon: JSX.Element;\n variant: ExpandableSectionProps.Variant;\n}\n\ninterface ExpandableNavigationHeaderProps extends Omit<ExpandableDefaultHeaderProps, 'onKeyUp' | 'onKeyDown'> {\n ariaLabelledBy?: string;\n}\n\ninterface ExpandableHeaderTextWrapperProps extends ExpandableDefaultHeaderProps {\n headerDescription?: ReactNode;\n headerCounter?: string;\n headerInfo?: ReactNode;\n headerActions?: ReactNode;\n headingTagOverride?: ExpandableSectionProps.HeadingTag;\n}\n\ninterface ExpandableSectionHeaderProps extends Omit<ExpandableDefaultHeaderProps, 'children' | 'icon'> {\n variant: ExpandableSectionProps.Variant;\n header?: ReactNode;\n headerText?: ReactNode;\n headerDescription?: ReactNode;\n headerCounter?: string;\n headerInfo?: ReactNode;\n headerActions?: ReactNode;\n headingTagOverride?: ExpandableSectionProps.HeadingTag;\n ariaLabelledBy?: string;\n}\n\nconst ExpandableDeprecatedHeader = ({\n id,\n className,\n onClick,\n ariaLabel,\n ariaControls,\n expanded,\n children,\n icon,\n onKeyUp,\n onKeyDown,\n variant,\n}: ExpandableDefaultHeaderProps) => {\n return (\n <div\n id={id}\n role=\"button\"\n className={clsx(className, styles['expand-button'], styles['click-target'], styles['header-deprecated'])}\n tabIndex={0}\n onKeyUp={onKeyUp}\n onKeyDown={onKeyDown}\n onClick={onClick}\n aria-label={ariaLabel}\n aria-controls={ariaControls}\n aria-expanded={expanded}\n >\n <div className={clsx(styles['icon-container'], styles[`icon-container-${variant}`])}>{icon}</div>\n {children}\n </div>\n );\n};\n\nconst ExpandableNavigationHeader = ({\n id,\n className,\n onClick,\n ariaLabelledBy,\n ariaLabel,\n ariaControls,\n expanded,\n children,\n icon,\n}: ExpandableNavigationHeaderProps) => {\n return (\n <div id={id} className={clsx(className, styles['click-target'])}>\n <button\n className={clsx(styles['icon-container'], styles['expand-button'])}\n aria-labelledby={ariaLabelledBy}\n aria-label={ariaLabel}\n aria-controls={ariaControls}\n aria-expanded={expanded}\n type=\"button\"\n onClick={onClick}\n >\n {icon}\n </button>\n {children}\n </div>\n );\n};\n\nconst ExpandableHeaderTextWrapper = ({\n id,\n descriptionId,\n className,\n onClick,\n ariaLabel,\n ariaControls,\n expanded,\n children,\n icon,\n headerDescription,\n headerCounter,\n headerInfo,\n headerActions,\n variant,\n headingTagOverride,\n onKeyUp,\n onKeyDown,\n}: ExpandableHeaderTextWrapperProps) => {\n const isContainer = variant === 'container';\n const HeadingTag = headingTagOverride || 'div';\n const hasInteractiveElements = isContainer && (headerInfo || headerActions);\n const listeners = { onClick, onKeyDown, onKeyUp };\n\n const description = variantSupportsDescription(variant) && headerDescription && (\n <span id={descriptionId} className={styles[`description-${variant}`]}>\n {headerDescription}\n </span>\n );\n\n // If interactive elements are present, constrain the clickable area to only the icon and the header text\n // to prevent nesting interactive elements.\n const headerButtonListeners = hasInteractiveElements ? listeners : undefined;\n // For the default and footer variants with description,\n // include also the immediate wrapper around it to include the entire row for backwards compatibility,\n // but exclude the description.\n const headingTagListeners = !headerButtonListeners && !isContainer && description ? listeners : undefined;\n // For all other cases, make the entire header clickable for backwards compatibility.\n const wrapperListeners = !headerButtonListeners && !headingTagListeners ? listeners : undefined;\n\n const headerButton = (\n <span\n className={clsx(\n styles['expand-button'],\n isContainer ? styles['header-container-button'] : styles['header-button'],\n headerButtonListeners && styles['click-target']\n )}\n role=\"button\"\n tabIndex={0}\n aria-label={ariaLabel}\n aria-labelledby={!ariaLabel && description ? id : undefined}\n aria-describedby={description ? descriptionId : undefined}\n aria-controls={ariaControls}\n aria-expanded={expanded}\n {...headerButtonListeners}\n >\n <span className={clsx(styles['icon-container'], styles[`icon-container-${variant}`])}>{icon}</span>\n <span id={id} className={styles['header-text']}>\n {children}\n </span>\n </span>\n );\n\n return (\n <div className={clsx(className, wrapperListeners && styles['click-target'])} {...wrapperListeners}>\n {isContainer ? (\n <InternalHeader\n variant=\"h2\"\n description={description}\n counter={headerCounter}\n info={headerInfo}\n actions={headerActions}\n headingTagOverride={headingTagOverride}\n >\n {headerButton}\n </InternalHeader>\n ) : (\n <>\n <HeadingTag\n className={clsx(styles['header-wrapper'], headingTagListeners && styles['click-target'])}\n {...headingTagListeners}\n >\n {headerButton}\n </HeadingTag>\n {description && <HeaderDescription variantOverride=\"h3\">{description}</HeaderDescription>}\n </>\n )}\n </div>\n );\n};\n\nexport const ExpandableSectionHeader = ({\n id,\n descriptionId,\n className,\n variant,\n header,\n headerText,\n headerDescription,\n headerCounter,\n headerInfo,\n headerActions,\n headingTagOverride,\n expanded,\n ariaControls,\n ariaLabel,\n ariaLabelledBy,\n onKeyUp,\n onKeyDown,\n onClick,\n}: ExpandableSectionHeaderProps) => {\n const icon = (\n <InternalIcon\n size={variant === 'container' ? 'medium' : 'normal'}\n className={clsx(styles.icon, expanded && styles.expanded)}\n name=\"caret-down-filled\"\n />\n );\n const defaultHeaderProps = {\n id: id,\n icon: icon,\n expanded: expanded,\n ariaControls: ariaControls,\n ariaLabel: ariaLabel,\n onClick: onClick,\n variant,\n };\n\n if ((headerCounter || headerInfo || headerActions) && variant !== 'container' && isDevelopment) {\n warnOnce(\n componentName,\n 'The `headerCounter`, `headerInfo` and `headerActions` props are only supported for the \"container\" variant.'\n );\n }\n\n if (headerDescription && !variantSupportsDescription(variant) && isDevelopment) {\n warnOnce(componentName, `The \\`headerDescription\\` prop is not supported for the ${variant} variant.`);\n }\n\n const wrapperClassName = clsx(styles.wrapper, styles[`wrapper-${variant}`], expanded && styles['wrapper-expanded']);\n if (variant === 'navigation') {\n return (\n <ExpandableNavigationHeader\n className={clsx(className, wrapperClassName)}\n ariaLabelledBy={ariaLabelledBy}\n {...defaultHeaderProps}\n >\n {headerText ?? header}\n </ExpandableNavigationHeader>\n );\n }\n\n if (headerText) {\n return (\n <ExpandableHeaderTextWrapper\n className={clsx(className, wrapperClassName, expanded && styles.expanded)}\n descriptionId={descriptionId}\n headerDescription={headerDescription}\n headerCounter={headerCounter}\n headerInfo={headerInfo}\n headerActions={headerActions}\n headingTagOverride={headingTagOverride}\n onKeyUp={onKeyUp}\n onKeyDown={onKeyDown}\n {...defaultHeaderProps}\n >\n {headerText}\n </ExpandableHeaderTextWrapper>\n );\n }\n\n if (variant === 'container' && header && isDevelopment) {\n warnOnce(componentName, 'Use `headerText` instead of `header` to provide the button within the heading for a11y.');\n }\n\n return (\n <ExpandableDeprecatedHeader\n className={clsx(className, wrapperClassName, styles.focusable, expanded && styles.expanded)}\n onKeyUp={onKeyUp}\n onKeyDown={onKeyDown}\n {...defaultHeaderProps}\n >\n {header}\n </ExpandableDeprecatedHeader>\n );\n};\n"]}
@@ -8,7 +8,6 @@ export declare namespace ExpandableSectionProps {
8
8
  }
9
9
  type HeadingTag = 'h1' | 'h2' | 'h3' | 'h4' | 'h5';
10
10
  }
11
- export type InternalVariant = ExpandableSectionProps.Variant | 'compact';
12
11
  export interface ExpandableSectionProps extends BaseComponentProps {
13
12
  /**
14
13
  * Determines whether the component initially displays in expanded state (that is, with content visible). The component operates in an uncontrolled
@@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ACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;;OAIG;IACH,kBAAkB,CAAC,EAAE,sBAAsB,CAAC,UAAU,CAAC;IAEvD;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;OAGG;IACH,QAAQ,CAAC,EAAE,yBAAyB,CAAC,sBAAsB,CAAC,YAAY,CAAC,CAAC;IAE1E;;OAEG;IACH,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAE7B;;OAEG;IACH,aAAa,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACjC"}
@@ -1 +1 @@
1
- {"version":3,"file":"interfaces.js","sourceRoot":"lib/default/","sources":["expandable-section/interfaces.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React from 'react';\nimport { BaseComponentProps } from '../internal/base-component';\nimport { NonCancelableEventHandler } from '../internal/events';\n\nexport namespace ExpandableSectionProps {\n export type Variant = 'default' | 'footer' | 'container' | 'navigation' | 'stacked';\n export interface ChangeDetail {\n expanded: boolean;\n }\n export type HeadingTag = 'h1' | 'h2' | 'h3' | 'h4' | 'h5';\n}\n\nexport type InternalVariant = ExpandableSectionProps.Variant | 'compact';\n\nexport interface ExpandableSectionProps extends BaseComponentProps {\n /**\n * Determines whether the component initially displays in expanded state (that is, with content visible). The component operates in an uncontrolled\n * manner even if you provide a value for this property.\n */\n defaultExpanded?: boolean;\n\n /**\n * Determines whether the component is in the expanded state (that is, with content visible). The component operates in a controlled\n * manner if you provide a value for this property.\n */\n expanded?: boolean;\n\n /**\n * The possible variants of an expandable section are as follows:\n * * `default` - Use this variant in any context.\n * * `footer` - Use this variant in container footers.\n * * `container` - Use this variant in a detail page alongside other containers.\n * * `navigation` - Use this variant in the navigation panel with anchors and custom styled content.\n * It doesn't have any default styles.\n * * `stacked` - Use this variant directly adjacent to other stacked containers (such as a container, table).\n * @visualrefresh `stacked` variant\n * */\n variant?: ExpandableSectionProps.Variant;\n\n /**\n * Determines whether the content section's default padding is removed. This default padding is only present for the `container` variant.\n */\n disableContentPaddings?: boolean;\n\n /**\n * Primary content displayed in the expandable section element.\n */\n children?: React.ReactNode;\n\n /**\n * @deprecated Use `headerText` instead.\n */\n header?: React.ReactNode;\n\n /**\n * The heading text. Use plain text. When using the container variant, you can use additional header props like `headerDescription` and `headerCounter` to display other elements in the header.\n */\n headerText?: React.ReactNode;\n\n /**\n * Supplementary text below the heading. Use with the container, default or footer variants.\n */\n headerDescription?: string;\n\n /**\n * Specifies secondary text that's displayed to the right of the heading title. Use with the container variant.\n * Behaves similar to the Header component counter.\n */\n headerCounter?: string;\n\n /**\n * Overrides the default [HTML heading tag](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/Heading_Elements).\n * Use with the container variant (which defaults to H2) or default/footer variants (which default to DIV). Note that this only\n * works with the `headerText` slot (not with the deprecated `header`), and not with the navigation variant.\n */\n headingTagOverride?: ExpandableSectionProps.HeadingTag;\n\n /**\n * Adds `aria-label` to the header element.\n * Use to assign unique labels when there are multiple expandable sections with the same header text on one page.\n */\n headerAriaLabel?: string;\n\n /**\n * Called when the state changes (that is, when the user expands or collapses the component).\n * The event `detail` contains the current value of the `expanded` property.\n */\n onChange?: NonCancelableEventHandler<ExpandableSectionProps.ChangeDetail>;\n\n /**\n * The area next to the heading, used to display an Info link. Use with the container variant.\n */\n headerInfo?: React.ReactNode;\n\n /**\n * Actions for the header. Use with the container variant.\n */\n headerActions?: React.ReactNode;\n}\n"]}
1
+ {"version":3,"file":"interfaces.js","sourceRoot":"lib/default/","sources":["expandable-section/interfaces.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React from 'react';\nimport { BaseComponentProps } from '../internal/base-component';\nimport { NonCancelableEventHandler } from '../internal/events';\n\nexport namespace ExpandableSectionProps {\n export type Variant = 'default' | 'footer' | 'container' | 'navigation' | 'stacked';\n export interface ChangeDetail {\n expanded: boolean;\n }\n export type HeadingTag = 'h1' | 'h2' | 'h3' | 'h4' | 'h5';\n}\n\nexport interface ExpandableSectionProps extends BaseComponentProps {\n /**\n * Determines whether the component initially displays in expanded state (that is, with content visible). The component operates in an uncontrolled\n * manner even if you provide a value for this property.\n */\n defaultExpanded?: boolean;\n\n /**\n * Determines whether the component is in the expanded state (that is, with content visible). The component operates in a controlled\n * manner if you provide a value for this property.\n */\n expanded?: boolean;\n\n /**\n * The possible variants of an expandable section are as follows:\n * * `default` - Use this variant in any context.\n * * `footer` - Use this variant in container footers.\n * * `container` - Use this variant in a detail page alongside other containers.\n * * `navigation` - Use this variant in the navigation panel with anchors and custom styled content.\n * It doesn't have any default styles.\n * * `stacked` - Use this variant directly adjacent to other stacked containers (such as a container, table).\n * @visualrefresh `stacked` variant\n * */\n variant?: ExpandableSectionProps.Variant;\n\n /**\n * Determines whether the content section's default padding is removed. This default padding is only present for the `container` variant.\n */\n disableContentPaddings?: boolean;\n\n /**\n * Primary content displayed in the expandable section element.\n */\n children?: React.ReactNode;\n\n /**\n * @deprecated Use `headerText` instead.\n */\n header?: React.ReactNode;\n\n /**\n * The heading text. Use plain text. When using the container variant, you can use additional header props like `headerDescription` and `headerCounter` to display other elements in the header.\n */\n headerText?: React.ReactNode;\n\n /**\n * Supplementary text below the heading. Use with the container, default or footer variants.\n */\n headerDescription?: string;\n\n /**\n * Specifies secondary text that's displayed to the right of the heading title. Use with the container variant.\n * Behaves similar to the Header component counter.\n */\n headerCounter?: string;\n\n /**\n * Overrides the default [HTML heading tag](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/Heading_Elements).\n * Use with the container variant (which defaults to H2) or default/footer variants (which default to DIV). Note that this only\n * works with the `headerText` slot (not with the deprecated `header`), and not with the navigation variant.\n */\n headingTagOverride?: ExpandableSectionProps.HeadingTag;\n\n /**\n * Adds `aria-label` to the header element.\n * Use to assign unique labels when there are multiple expandable sections with the same header text on one page.\n */\n headerAriaLabel?: string;\n\n /**\n * Called when the state changes (that is, when the user expands or collapses the component).\n * The event `detail` contains the current value of the `expanded` property.\n */\n onChange?: NonCancelableEventHandler<ExpandableSectionProps.ChangeDetail>;\n\n /**\n * The area next to the heading, used to display an Info link. Use with the container variant.\n */\n headerInfo?: React.ReactNode;\n\n /**\n * Actions for the header. Use with the container variant.\n */\n headerActions?: React.ReactNode;\n}\n"]}
@@ -1,8 +1,6 @@
1
1
  /// <reference types="react" />
2
- import { ExpandableSectionProps, InternalVariant } from './interfaces';
2
+ import { ExpandableSectionProps } from './interfaces';
3
3
  import { InternalBaseComponentProps } from '../internal/hooks/use-base-component';
4
- export type InternalExpandableSectionProps = Omit<ExpandableSectionProps, 'variant'> & InternalBaseComponentProps & {
5
- variant?: InternalVariant;
6
- };
4
+ export type InternalExpandableSectionProps = ExpandableSectionProps & InternalBaseComponentProps;
7
5
  export default function InternalExpandableSection({ expanded: controlledExpanded, defaultExpanded, onChange, variant, children, header, headerText, headerCounter, headerDescription, headerInfo, headerActions, headingTagOverride, disableContentPaddings, headerAriaLabel, __internalRootRef, ...props }: InternalExpandableSectionProps): JSX.Element;
8
6
  //# sourceMappingURL=internal.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"internal.d.ts","sourceRoot":"lib/default/","sources":["expandable-section/internal.tsx"],"names":[],"mappings":";AAYA,OAAO,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAKvE,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAGlF,MAAM,MAAM,8BAA8B,GAAG,IAAI,CAAC,sBAAsB,EAAE,SAAS,CAAC,GAClF,0BAA0B,GAAG;IAC3B,OAAO,CAAC,EAAE,eAAe,CAAC;CAC3B,CAAC;AAEJ,MAAM,CAAC,OAAO,UAAU,yBAAyB,CAAC,EAChD,QAAQ,EAAE,kBAAkB,EAC5B,eAAe,EACf,QAAQ,EACR,OAAmB,EACnB,QAAQ,EACR,MAAM,EACN,UAAU,EACV,aAAa,EACb,iBAAiB,EACjB,UAAU,EACV,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,eAAe,EACf,iBAAiB,EACjB,GAAG,KAAK,EACT,EAAE,8BAA8B,eAgGhC"}
1
+ {"version":3,"file":"internal.d.ts","sourceRoot":"lib/default/","sources":["expandable-section/internal.tsx"],"names":[],"mappings":";AAYA,OAAO,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAC;AAKtD,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAGlF,MAAM,MAAM,8BAA8B,GAAG,sBAAsB,GAAG,0BAA0B,CAAC;AAEjG,MAAM,CAAC,OAAO,UAAU,yBAAyB,CAAC,EAChD,QAAQ,EAAE,kBAAkB,EAC5B,eAAe,EACf,QAAQ,EACR,OAAmB,EACnB,QAAQ,EACR,MAAM,EACN,UAAU,EACV,aAAa,EACb,iBAAiB,EACjB,UAAU,EACV,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,eAAe,EACf,iBAAiB,EACjB,GAAG,KAAK,EACT,EAAE,8BAA8B,eAgGhC"}
@@ -1 +1 @@
1
- {"version":3,"file":"internal.js","sourceRoot":"lib/default/","sources":["expandable-section/internal.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAiB,WAAW,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAClE,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACrE,OAAO,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,sBAAsB,EAAE,M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ACtB,EAAE,EAAE,gBAAgB,EACpB,aAAa,EAAE,aAAa,EAC5B,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,UAAU,WAAW,EAAE,CAAC,CAAC,EAC/D,OAAO,EAAE,WAAW,EACpB,QAAQ,EAAE,CAAC,CAAC,QAAQ,EACpB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,UAAU,EACtB,iBAAiB,EAAE,iBAAiB,EACpC,aAAa,EAAE,aAAa,EAC5B,UAAU,EAAE,UAAU,EACtB,aAAa,EAAE,aAAa,EAC5B,kBAAkB,EAAE,kBAAkB,IAClC,YAAY,EAChB,EAEJ,iBAAiB,EAAE,iBAAiB;QAEpC,oBAAC,aAAa,IAAC,EAAE,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE,EAAE,UAAU,EAAE,EAAE,KAAK,EAAE,MAAM,CAAC,eAAe,CAAC,EAAE,EAAE,OAAO,EAAE,GAAG;YACpG,6BACE,EAAE,EAAE,SAAS,EACb,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,MAAM,CAAC,WAAW,WAAW,EAAE,CAAC,EAAE,QAAQ,IAAI,MAAM,CAAC,kBAAkB,CAAC,CAAC,EACzG,IAAI,EAAC,OAAO,gBACA,YAAY,CAAC,SAAS,qBACjB,YAAY,CAAC,cAAc,sBAC1B,0BAA0B,CAAC,WAAW,CAAC,IAAI,iBAAiB,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,SAAS,IAEzG,QAAQ,CACL,CACQ,CACW,CAC9B,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { KeyboardEvent, useCallback, useRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport clsx from 'clsx';\n\nimport { getBaseProps } from '../internal/base-component';\nimport { useControllable } from '../internal/hooks/use-controllable';\nimport { useUniqueId } from '../internal/hooks/use-unique-id';\nimport { KeyCode } from '../internal/keycode';\nimport { fireNonCancelableEvent } from '../internal/events';\n\nimport { ExpandableSectionProps, InternalVariant } from './interfaces';\n\nimport styles from './styles.css.js';\nimport { ExpandableSectionContainer } from './expandable-section-container';\nimport { ExpandableSectionHeader } from './expandable-section-header';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { variantSupportsDescription } from './utils';\n\nexport type InternalExpandableSectionProps = Omit<ExpandableSectionProps, 'variant'> &\n InternalBaseComponentProps & {\n variant?: InternalVariant;\n };\n\nexport default function InternalExpandableSection({\n expanded: controlledExpanded,\n defaultExpanded,\n onChange,\n variant = 'default',\n children,\n header,\n headerText,\n headerCounter,\n headerDescription,\n headerInfo,\n headerActions,\n headingTagOverride,\n disableContentPaddings,\n headerAriaLabel,\n __internalRootRef,\n ...props\n}: InternalExpandableSectionProps) {\n const ref = useRef<HTMLDivElement>(null);\n const controlId = useUniqueId();\n const triggerControlId = `${controlId}-trigger`;\n const descriptionId = `${controlId}-description`;\n\n const baseProps = getBaseProps(props);\n const [expanded, setExpanded] = useControllable(controlledExpanded, onChange, defaultExpanded, {\n componentName: 'ExpandableSection',\n controlledProp: 'expanded',\n changeHandler: 'onChange',\n });\n\n const onExpandChange = useCallback(\n (expanded: boolean) => {\n setExpanded(expanded);\n fireNonCancelableEvent(onChange, { expanded });\n },\n [onChange, setExpanded]\n );\n\n const onClick = useCallback(() => {\n onExpandChange(!expanded);\n }, [onExpandChange, expanded]);\n\n const onKeyUp = useCallback(\n (event: KeyboardEvent<Element>) => {\n const interactionKeys = [KeyCode.enter, KeyCode.space];\n\n if (interactionKeys.indexOf(event.keyCode) !== -1) {\n onExpandChange(!expanded);\n }\n },\n [onExpandChange, expanded]\n );\n\n const onKeyDown = useCallback((event: KeyboardEvent<Element>) => {\n if (event.keyCode === KeyCode.space) {\n // Prevent the page from scrolling when toggling the component with the space bar.\n event.preventDefault();\n }\n }, []);\n\n const triggerProps = {\n ariaControls: controlId,\n ariaLabel: headerAriaLabel,\n ariaLabelledBy: headerAriaLabel ? undefined : triggerControlId,\n onKeyUp,\n onKeyDown,\n onClick,\n };\n\n // Map stacked variant to container to avoid code duplication\n const baseVariant: InternalVariant = variant === 'stacked' ? 'container' : variant;\n\n return (\n <ExpandableSectionContainer\n {...baseProps}\n expanded={expanded}\n className={clsx(baseProps.className, styles.root)}\n variant={variant}\n disableContentPaddings={disableContentPaddings}\n header={\n <ExpandableSectionHeader\n id={triggerControlId}\n descriptionId={descriptionId}\n className={clsx(styles.header, styles[`header-${baseVariant}`])}\n variant={baseVariant}\n expanded={!!expanded}\n header={header}\n headerText={headerText}\n headerDescription={headerDescription}\n headerCounter={headerCounter}\n headerInfo={headerInfo}\n headerActions={headerActions}\n headingTagOverride={headingTagOverride}\n {...triggerProps}\n />\n }\n __internalRootRef={__internalRootRef}\n >\n <CSSTransition in={expanded} timeout={30} classNames={{ enter: styles['content-enter'] }} nodeRef={ref}>\n <div\n id={controlId}\n ref={ref}\n className={clsx(styles.content, styles[`content-${baseVariant}`], expanded && styles['content-expanded'])}\n role=\"group\"\n aria-label={triggerProps.ariaLabel}\n aria-labelledby={triggerProps.ariaLabelledBy}\n aria-describedby={variantSupportsDescription(baseVariant) && headerDescription ? descriptionId : undefined}\n >\n {children}\n </div>\n </CSSTransition>\n </ExpandableSectionContainer>\n );\n}\n"]}
1
+ {"version":3,"file":"internal.js","sourceRoot":"lib/default/","sources":["expandable-section/internal.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAiB,WAAW,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAClE,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,C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0\nimport React, { KeyboardEvent, useCallback, useRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport clsx from 'clsx';\n\nimport { getBaseProps } from '../internal/base-component';\nimport { useControllable } from '../internal/hooks/use-controllable';\nimport { useUniqueId } from '../internal/hooks/use-unique-id';\nimport { KeyCode } from '../internal/keycode';\nimport { fireNonCancelableEvent } from '../internal/events';\n\nimport { ExpandableSectionProps } from './interfaces';\n\nimport styles from './styles.css.js';\nimport { ExpandableSectionContainer } from './expandable-section-container';\nimport { ExpandableSectionHeader } from './expandable-section-header';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { variantSupportsDescription } from './utils';\n\nexport type InternalExpandableSectionProps = ExpandableSectionProps & InternalBaseComponentProps;\n\nexport default function InternalExpandableSection({\n expanded: controlledExpanded,\n defaultExpanded,\n onChange,\n variant = 'default',\n children,\n header,\n headerText,\n headerCounter,\n headerDescription,\n headerInfo,\n headerActions,\n headingTagOverride,\n disableContentPaddings,\n headerAriaLabel,\n __internalRootRef,\n ...props\n}: InternalExpandableSectionProps) {\n const ref = useRef<HTMLDivElement>(null);\n const controlId = useUniqueId();\n const triggerControlId = `${controlId}-trigger`;\n const descriptionId = `${controlId}-description`;\n\n const baseProps = getBaseProps(props);\n const [expanded, setExpanded] = useControllable(controlledExpanded, onChange, defaultExpanded, {\n componentName: 'ExpandableSection',\n controlledProp: 'expanded',\n changeHandler: 'onChange',\n });\n\n const onExpandChange = useCallback(\n (expanded: boolean) => {\n setExpanded(expanded);\n fireNonCancelableEvent(onChange, { expanded });\n },\n [onChange, setExpanded]\n );\n\n const onClick = useCallback(() => {\n onExpandChange(!expanded);\n }, [onExpandChange, expanded]);\n\n const onKeyUp = useCallback(\n (event: KeyboardEvent<Element>) => {\n const interactionKeys = [KeyCode.enter, KeyCode.space];\n\n if (interactionKeys.indexOf(event.keyCode) !== -1) {\n onExpandChange(!expanded);\n }\n },\n [onExpandChange, expanded]\n );\n\n const onKeyDown = useCallback((event: KeyboardEvent<Element>) => {\n if (event.keyCode === KeyCode.space) {\n // Prevent the page from scrolling when toggling the component with the space bar.\n event.preventDefault();\n }\n }, []);\n\n const triggerProps = {\n ariaControls: controlId,\n ariaLabel: headerAriaLabel,\n ariaLabelledBy: headerAriaLabel ? undefined : triggerControlId,\n onKeyUp,\n onKeyDown,\n onClick,\n };\n\n // Map stacked variant to container to avoid code duplication\n const baseVariant: ExpandableSectionProps.Variant = variant === 'stacked' ? 'container' : variant;\n\n return (\n <ExpandableSectionContainer\n {...baseProps}\n expanded={expanded}\n className={clsx(baseProps.className, styles.root)}\n variant={variant}\n disableContentPaddings={disableContentPaddings}\n header={\n <ExpandableSectionHeader\n id={triggerControlId}\n descriptionId={descriptionId}\n className={clsx(styles.header, styles[`header-${baseVariant}`])}\n variant={baseVariant}\n expanded={!!expanded}\n header={header}\n headerText={headerText}\n headerDescription={headerDescription}\n headerCounter={headerCounter}\n headerInfo={headerInfo}\n headerActions={headerActions}\n headingTagOverride={headingTagOverride}\n {...triggerProps}\n />\n }\n __internalRootRef={__internalRootRef}\n >\n <CSSTransition in={expanded} timeout={30} classNames={{ enter: styles['content-enter'] }} nodeRef={ref}>\n <div\n id={controlId}\n ref={ref}\n className={clsx(styles.content, styles[`content-${baseVariant}`], expanded && styles['content-expanded'])}\n role=\"group\"\n aria-label={triggerProps.ariaLabel}\n aria-labelledby={triggerProps.ariaLabelledBy}\n aria-describedby={variantSupportsDescription(baseVariant) && headerDescription ? descriptionId : undefined}\n >\n {children}\n </div>\n </CSSTransition>\n </ExpandableSectionContainer>\n );\n}\n"]}
@@ -1,37 +1,34 @@
1
1
 
2
2
  import './styles.scoped.css';
3
3
  export default {
4
- "content-enter": "awsui_content-enter_gwq0h_hpg6a_97",
5
- "awsui-motion-fade-in": "awsui_awsui-motion-fade-in_gwq0h_hpg6a_1",
6
- "trigger-expanded": "awsui_trigger-expanded_gwq0h_hpg6a_119",
7
- "icon": "awsui_icon_gwq0h_hpg6a_133",
8
- "root": "awsui_root_gwq0h_hpg6a_151",
9
- "expand-button": "awsui_expand-button_gwq0h_hpg6a_167",
10
- "expanded": "awsui_expanded_gwq0h_hpg6a_174",
11
- "icon-container": "awsui_icon-container_gwq0h_hpg6a_178",
12
- "icon-container-container": "awsui_icon-container-container_gwq0h_hpg6a_183",
13
- "wrapper": "awsui_wrapper_gwq0h_hpg6a_187",
14
- "wrapper-default": "awsui_wrapper-default_gwq0h_hpg6a_194",
15
- "wrapper-footer": "awsui_wrapper-footer_gwq0h_hpg6a_194",
16
- "wrapper-navigation": "awsui_wrapper-navigation_gwq0h_hpg6a_197",
17
- "wrapper-container": "awsui_wrapper-container_gwq0h_hpg6a_200",
18
- "wrapper-compact": "awsui_wrapper-compact_gwq0h_hpg6a_204",
19
- "header-deprecated": "awsui_header-deprecated_gwq0h_hpg6a_218",
20
- "wrapper-expanded": "awsui_wrapper-expanded_gwq0h_hpg6a_242",
21
- "header": "awsui_header_gwq0h_hpg6a_218",
22
- "header-wrapper": "awsui_header-wrapper_gwq0h_hpg6a_261",
23
- "header-actions-wrapper": "awsui_header-actions-wrapper_gwq0h_hpg6a_271",
24
- "header-button": "awsui_header-button_gwq0h_hpg6a_276",
25
- "header-container-button": "awsui_header-container-button_gwq0h_hpg6a_276",
26
- "header-container": "awsui_header-container_gwq0h_hpg6a_276",
27
- "header-navigation": "awsui_header-navigation_gwq0h_hpg6a_308",
28
- "header-text": "awsui_header-text_gwq0h_hpg6a_340",
29
- "content": "awsui_content_gwq0h_hpg6a_97",
30
- "content-default": "awsui_content-default_gwq0h_hpg6a_347",
31
- "content-footer": "awsui_content-footer_gwq0h_hpg6a_350",
32
- "content-expanded": "awsui_content-expanded_gwq0h_hpg6a_353",
33
- "content-compact": "awsui_content-compact_gwq0h_hpg6a_356",
34
- "focusable": "awsui_focusable_gwq0h_hpg6a_360",
35
- "click-target": "awsui_click-target_gwq0h_hpg6a_371"
4
+ "content-enter": "awsui_content-enter_gwq0h_12nx0_97",
5
+ "awsui-motion-fade-in": "awsui_awsui-motion-fade-in_gwq0h_12nx0_1",
6
+ "trigger-expanded": "awsui_trigger-expanded_gwq0h_12nx0_119",
7
+ "icon": "awsui_icon_gwq0h_12nx0_133",
8
+ "root": "awsui_root_gwq0h_12nx0_151",
9
+ "expand-button": "awsui_expand-button_gwq0h_12nx0_167",
10
+ "expanded": "awsui_expanded_gwq0h_12nx0_174",
11
+ "icon-container": "awsui_icon-container_gwq0h_12nx0_178",
12
+ "icon-container-container": "awsui_icon-container-container_gwq0h_12nx0_182",
13
+ "wrapper": "awsui_wrapper_gwq0h_12nx0_186",
14
+ "wrapper-default": "awsui_wrapper-default_gwq0h_12nx0_194",
15
+ "wrapper-footer": "awsui_wrapper-footer_gwq0h_12nx0_194",
16
+ "wrapper-navigation": "awsui_wrapper-navigation_gwq0h_12nx0_198",
17
+ "wrapper-container": "awsui_wrapper-container_gwq0h_12nx0_201",
18
+ "header-deprecated": "awsui_header-deprecated_gwq0h_12nx0_216",
19
+ "wrapper-expanded": "awsui_wrapper-expanded_gwq0h_12nx0_236",
20
+ "header": "awsui_header_gwq0h_12nx0_216",
21
+ "header-wrapper": "awsui_header-wrapper_gwq0h_12nx0_256",
22
+ "header-button": "awsui_header-button_gwq0h_12nx0_268",
23
+ "header-container-button": "awsui_header-container-button_gwq0h_12nx0_268",
24
+ "header-container": "awsui_header-container_gwq0h_12nx0_268",
25
+ "header-navigation": "awsui_header-navigation_gwq0h_12nx0_300",
26
+ "header-text": "awsui_header-text_gwq0h_12nx0_334",
27
+ "content": "awsui_content_gwq0h_12nx0_97",
28
+ "content-default": "awsui_content-default_gwq0h_12nx0_341",
29
+ "content-footer": "awsui_content-footer_gwq0h_12nx0_345",
30
+ "content-expanded": "awsui_content-expanded_gwq0h_12nx0_349",
31
+ "focusable": "awsui_focusable_gwq0h_12nx0_353",
32
+ "click-target": "awsui_click-target_gwq0h_12nx0_364"
36
33
  };
37
34
 
@@ -94,10 +94,10 @@ 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_content-enter_gwq0h_hpg6a_97:not(#\9) {
98
- animation: awsui_awsui-motion-fade-in_gwq0h_hpg6a_1 var(--motion-duration-show-paced-q2lo2h, 180ms) var(--motion-easing-show-paced-ne2o0s, ease-out);
97
+ .awsui_content-enter_gwq0h_12nx0_97:not(#\9) {
98
+ animation: awsui_awsui-motion-fade-in_gwq0h_12nx0_1 var(--motion-duration-show-paced-q2lo2h, 180ms) var(--motion-easing-show-paced-ne2o0s, ease-out);
99
99
  }
100
- @keyframes awsui_awsui-motion-fade-in_gwq0h_hpg6a_1 {
100
+ @keyframes awsui_awsui-motion-fade-in_gwq0h_12nx0_1 {
101
101
  from {
102
102
  opacity: 0.2;
103
103
  }
@@ -106,40 +106,40 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
106
106
  }
107
107
  }
108
108
  @media (prefers-reduced-motion: reduce) {
109
- .awsui_content-enter_gwq0h_hpg6a_97:not(#\9) {
109
+ .awsui_content-enter_gwq0h_12nx0_97:not(#\9) {
110
110
  animation: none;
111
111
  transition: none;
112
112
  }
113
113
  }
114
- .awsui-motion-disabled .awsui_content-enter_gwq0h_hpg6a_97:not(#\9), .awsui-mode-entering .awsui_content-enter_gwq0h_hpg6a_97:not(#\9) {
114
+ .awsui-motion-disabled .awsui_content-enter_gwq0h_12nx0_97:not(#\9), .awsui-mode-entering .awsui_content-enter_gwq0h_12nx0_97:not(#\9) {
115
115
  animation: none;
116
116
  transition: none;
117
117
  }
118
118
 
119
- .awsui_trigger-expanded_gwq0h_hpg6a_119:not(#\9) {
119
+ .awsui_trigger-expanded_gwq0h_12nx0_119:not(#\9) {
120
120
  transition: border-bottom-color var(--motion-duration-show-paced-q2lo2h, 180ms) var(--motion-easing-show-paced-ne2o0s, ease-out);
121
121
  }
122
122
  @media (prefers-reduced-motion: reduce) {
123
- .awsui_trigger-expanded_gwq0h_hpg6a_119:not(#\9) {
123
+ .awsui_trigger-expanded_gwq0h_12nx0_119:not(#\9) {
124
124
  animation: none;
125
125
  transition: none;
126
126
  }
127
127
  }
128
- .awsui-motion-disabled .awsui_trigger-expanded_gwq0h_hpg6a_119:not(#\9), .awsui-mode-entering .awsui_trigger-expanded_gwq0h_hpg6a_119:not(#\9) {
128
+ .awsui-motion-disabled .awsui_trigger-expanded_gwq0h_12nx0_119:not(#\9), .awsui-mode-entering .awsui_trigger-expanded_gwq0h_12nx0_119:not(#\9) {
129
129
  animation: none;
130
130
  transition: none;
131
131
  }
132
132
 
133
- .awsui_icon_gwq0h_hpg6a_133:not(#\9) {
133
+ .awsui_icon_gwq0h_12nx0_133:not(#\9) {
134
134
  transition: transform var(--motion-duration-rotate-90-4ry26y, 135ms) var(--motion-easing-rotate-90-sb4dk7, cubic-bezier(0.165, 0.84, 0.44, 1));
135
135
  }
136
136
  @media (prefers-reduced-motion: reduce) {
137
- .awsui_icon_gwq0h_hpg6a_133:not(#\9) {
137
+ .awsui_icon_gwq0h_12nx0_133:not(#\9) {
138
138
  animation: none;
139
139
  transition: none;
140
140
  }
141
141
  }
142
- .awsui-motion-disabled .awsui_icon_gwq0h_hpg6a_133:not(#\9), .awsui-mode-entering .awsui_icon_gwq0h_hpg6a_133:not(#\9) {
142
+ .awsui-motion-disabled .awsui_icon_gwq0h_12nx0_133:not(#\9), .awsui-mode-entering .awsui_icon_gwq0h_12nx0_133:not(#\9) {
143
143
  animation: none;
144
144
  transition: none;
145
145
  }
@@ -148,7 +148,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
148
148
  Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
149
149
  SPDX-License-Identifier: Apache-2.0
150
150
  */
151
- .awsui_root_gwq0h_hpg6a_151:not(#\9) {
151
+ .awsui_root_gwq0h_12nx0_151:not(#\9) {
152
152
  /* stylelint-disable-next-line plugin/no-unsupported-browser-features */
153
153
  border-collapse: separate;
154
154
  border-spacing: 0;
@@ -190,123 +190,115 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
190
190
  display: block;
191
191
  }
192
192
 
193
- .awsui_expand-button_gwq0h_hpg6a_167:not(#\9) {
193
+ .awsui_expand-button_gwq0h_12nx0_167:not(#\9) {
194
194
  /* used in test-utils */
195
195
  }
196
196
 
197
- .awsui_icon_gwq0h_hpg6a_133:not(#\9) {
197
+ .awsui_icon_gwq0h_12nx0_133:not(#\9) {
198
198
  transform: rotate(-90deg);
199
199
  }
200
- .awsui_icon_gwq0h_hpg6a_133.awsui_expanded_gwq0h_hpg6a_174:not(#\9) {
200
+ .awsui_icon_gwq0h_12nx0_133.awsui_expanded_gwq0h_12nx0_174:not(#\9) {
201
201
  transform: rotate(0deg);
202
202
  }
203
203
 
204
- .awsui_icon-container_gwq0h_hpg6a_178:not(#\9) {
204
+ .awsui_icon-container_gwq0h_12nx0_178:not(#\9) {
205
205
  position: relative;
206
- margin-left: calc((var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2);
207
- margin-right: calc(var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px));
206
+ margin-inline: calc((var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2) calc(var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px));
208
207
  }
209
- .awsui_icon-container-container_gwq0h_hpg6a_183:not(#\9) {
210
- margin-right: var(--space-xs-zb16t3, 8px);
208
+ .awsui_icon-container-container_gwq0h_12nx0_182:not(#\9) {
209
+ margin-inline-end: var(--space-xs-zb16t3, 8px);
211
210
  }
212
211
 
213
- .awsui_wrapper_gwq0h_hpg6a_187:not(#\9) {
212
+ .awsui_wrapper_gwq0h_12nx0_186:not(#\9) {
214
213
  box-sizing: border-box;
215
- border: none;
216
- width: 100%;
214
+ border-block: none;
215
+ border-inline: none;
216
+ inline-size: 100%;
217
217
  line-height: var(--line-height-body-m-30ar75, 20px);
218
- text-align: left;
218
+ text-align: start;
219
219
  }
220
- .awsui_wrapper-default_gwq0h_hpg6a_194:not(#\9), .awsui_wrapper-footer_gwq0h_hpg6a_194:not(#\9) {
221
- border: var(--border-divider-section-width-8a5uu9, 2px) solid transparent;
220
+ .awsui_wrapper-default_gwq0h_12nx0_194:not(#\9), .awsui_wrapper-footer_gwq0h_12nx0_194:not(#\9) {
221
+ border-block: var(--border-divider-section-width-8a5uu9, 2px) solid transparent;
222
+ border-inline: var(--border-divider-section-width-8a5uu9, 2px) solid transparent;
222
223
  }
223
- .awsui_wrapper-navigation_gwq0h_hpg6a_197:not(#\9) {
224
- border-left: var(--border-divider-section-width-8a5uu9, 2px) solid transparent;
224
+ .awsui_wrapper-navigation_gwq0h_12nx0_198:not(#\9) {
225
+ border-inline-start: var(--border-divider-section-width-8a5uu9, 2px) solid transparent;
225
226
  }
226
- .awsui_wrapper-navigation_gwq0h_hpg6a_197:not(#\9), .awsui_wrapper-container_gwq0h_hpg6a_200:not(#\9) {
227
+ .awsui_wrapper-navigation_gwq0h_12nx0_198:not(#\9), .awsui_wrapper-container_gwq0h_12nx0_201:not(#\9) {
227
228
  display: flex;
228
229
  font-weight: var(--font-weight-heading-s-cwn6wc, 700);
229
230
  }
230
- .awsui_wrapper-default_gwq0h_hpg6a_194:not(#\9), .awsui_wrapper-navigation_gwq0h_hpg6a_197:not(#\9), .awsui_wrapper-footer_gwq0h_hpg6a_194:not(#\9), .awsui_wrapper-compact_gwq0h_hpg6a_204:not(#\9) {
231
+ .awsui_wrapper-default_gwq0h_12nx0_194:not(#\9), .awsui_wrapper-navigation_gwq0h_12nx0_198:not(#\9), .awsui_wrapper-footer_gwq0h_12nx0_194:not(#\9) {
231
232
  color: var(--color-text-expandable-section-default-lm3qgp, #000716);
232
233
  -webkit-font-smoothing: var(--font-smoothing-webkit-m8nc84, antialiased);
233
234
  -moz-osx-font-smoothing: var(--font-smoothing-moz-osx-foywby, grayscale);
234
- }
235
- .awsui_wrapper-default_gwq0h_hpg6a_194:not(#\9), .awsui_wrapper-navigation_gwq0h_hpg6a_197:not(#\9), .awsui_wrapper-footer_gwq0h_hpg6a_194:not(#\9) {
236
235
  font-size: var(--font-expandable-heading-size-smdiul, 16px);
237
236
  letter-spacing: var(--letter-spacing-heading-s-jr3mor, -0.005em);
238
237
  }
239
- .awsui_wrapper-default_gwq0h_hpg6a_194:not(#\9) {
240
- padding-top: var(--space-scaled-xxs-7597g1, 4px);
241
- padding-bottom: var(--space-scaled-xxs-7597g1, 4px);
242
- padding-right: var(--space-xxs-p8yyaw, 4px);
238
+ .awsui_wrapper-default_gwq0h_12nx0_194:not(#\9) {
239
+ padding-block: var(--space-scaled-xxs-7597g1, 4px);
240
+ padding-inline-end: var(--space-xxs-p8yyaw, 4px);
243
241
  }
244
- .awsui_wrapper-default_gwq0h_hpg6a_194.awsui_header-deprecated_gwq0h_hpg6a_218:not(#\9) {
245
- padding-left: var(--space-xxs-p8yyaw, 4px);
242
+ .awsui_wrapper-default_gwq0h_12nx0_194.awsui_header-deprecated_gwq0h_12nx0_216:not(#\9) {
243
+ padding-inline-start: var(--space-xxs-p8yyaw, 4px);
246
244
  }
247
- .awsui_wrapper-default_gwq0h_hpg6a_194:not(#\9):not(.awsui_header-deprecated_gwq0h_hpg6a_218) {
248
- padding-left: calc(var(--space-xxs-p8yyaw, 4px) + calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px)));
245
+ .awsui_wrapper-default_gwq0h_12nx0_194:not(#\9):not(.awsui_header-deprecated_gwq0h_12nx0_216) {
246
+ padding-inline-start: calc(var(--space-xxs-p8yyaw, 4px) + calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px)));
249
247
  }
250
- .awsui_wrapper-footer_gwq0h_hpg6a_194:not(#\9) {
251
- padding-top: var(--space-scaled-xxs-7597g1, 4px);
252
- padding-bottom: var(--space-scaled-xxs-7597g1, 4px);
248
+ .awsui_wrapper-footer_gwq0h_12nx0_194:not(#\9) {
249
+ padding-block: var(--space-scaled-xxs-7597g1, 4px);
250
+ padding-inline-end: 0;
253
251
  }
254
- .awsui_wrapper-footer_gwq0h_hpg6a_194:not(#\9), .awsui_wrapper-compact_gwq0h_hpg6a_204:not(#\9) {
255
- padding-right: 0;
252
+ .awsui_wrapper-footer_gwq0h_12nx0_194.awsui_header-deprecated_gwq0h_12nx0_216:not(#\9) {
253
+ padding-inline-start: 0;
256
254
  }
257
- .awsui_wrapper-footer_gwq0h_hpg6a_194.awsui_header-deprecated_gwq0h_hpg6a_218:not(#\9), .awsui_wrapper-compact_gwq0h_hpg6a_204.awsui_header-deprecated_gwq0h_hpg6a_218:not(#\9) {
258
- padding-left: 0;
259
- }
260
- .awsui_wrapper-footer_gwq0h_hpg6a_194:not(#\9):not(.awsui_header-deprecated_gwq0h_hpg6a_218), .awsui_wrapper-compact_gwq0h_hpg6a_204:not(#\9):not(.awsui_header-deprecated_gwq0h_hpg6a_218) {
261
- padding-left: calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px));
255
+ .awsui_wrapper-footer_gwq0h_12nx0_194:not(#\9):not(.awsui_header-deprecated_gwq0h_12nx0_216) {
256
+ padding-inline-start: calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px));
262
257
  }
263
- .awsui_wrapper-container_gwq0h_hpg6a_200:not(#\9) {
264
- padding-top: var(--space-container-header-top-5qav00, 12px);
265
- padding-bottom: var(--space-container-header-bottom-vj01hn, 8px);
266
- padding-right: var(--space-container-horizontal-wfukh3, 20px);
258
+ .awsui_wrapper-container_gwq0h_12nx0_201:not(#\9) {
259
+ padding-block: var(--space-container-header-top-5qav00, 12px) var(--space-container-header-bottom-vj01hn, 8px);
260
+ padding-inline-end: var(--space-container-horizontal-wfukh3, 20px);
267
261
  }
268
- .awsui_wrapper-container_gwq0h_hpg6a_200:not(#\9):not(.awsui_wrapper-expanded_gwq0h_hpg6a_242) {
269
- padding-bottom: var(--space-container-header-top-5qav00, 12px);
262
+ .awsui_wrapper-container_gwq0h_12nx0_201:not(#\9):not(.awsui_wrapper-expanded_gwq0h_12nx0_236) {
263
+ padding-block-end: var(--space-container-header-top-5qav00, 12px);
270
264
  }
271
- .awsui_wrapper-container_gwq0h_hpg6a_200.awsui_header-deprecated_gwq0h_hpg6a_218:not(#\9) {
272
- padding-left: var(--space-container-horizontal-wfukh3, 20px);
265
+ .awsui_wrapper-container_gwq0h_12nx0_201.awsui_header-deprecated_gwq0h_12nx0_216:not(#\9) {
266
+ padding-inline-start: var(--space-container-horizontal-wfukh3, 20px);
273
267
  }
274
- .awsui_wrapper-container_gwq0h_hpg6a_200:not(#\9):not(.awsui_header-deprecated_gwq0h_hpg6a_218) {
275
- padding-left: calc(var(--space-container-horizontal-wfukh3, 20px) + calc(var(--size-icon-medium-y9xuoq, 20px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xs-zb16t3, 8px)));
268
+ .awsui_wrapper-container_gwq0h_12nx0_201:not(#\9):not(.awsui_header-deprecated_gwq0h_12nx0_216) {
269
+ padding-inline-start: calc(var(--space-container-horizontal-wfukh3, 20px) + calc(var(--size-icon-medium-y9xuoq, 20px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xs-zb16t3, 8px)));
276
270
  }
277
- body[data-awsui-focus-visible=true] .awsui_wrapper-container_gwq0h_hpg6a_200:not(#\9):focus {
278
- padding: calc(var(--space-scaled-s-aqzyko, 12px) - var(--border-divider-section-width-8a5uu9, 2px)) calc(var(--space-l-t419sm, 20px) - var(--border-divider-section-width-8a5uu9, 2px));
271
+ body[data-awsui-focus-visible=true] .awsui_wrapper-container_gwq0h_12nx0_201:not(#\9):focus {
272
+ padding-block: calc(var(--space-scaled-s-aqzyko, 12px) - var(--border-divider-section-width-8a5uu9, 2px));
273
+ padding-inline: calc(var(--space-l-t419sm, 20px) - var(--border-divider-section-width-8a5uu9, 2px));
279
274
  }
280
- .awsui_wrapper-default_gwq0h_hpg6a_194.awsui_wrapper-expanded_gwq0h_hpg6a_242:not(#\9) {
281
- border-bottom-color: var(--color-border-divider-default-et9j7s, #e9ebed);
275
+ .awsui_wrapper-default_gwq0h_12nx0_194.awsui_wrapper-expanded_gwq0h_12nx0_236:not(#\9) {
276
+ border-block-end-color: var(--color-border-divider-default-et9j7s, #e9ebed);
282
277
  }
283
278
 
284
- .awsui_header_gwq0h_hpg6a_218:not(#\9) {
279
+ .awsui_header_gwq0h_12nx0_216:not(#\9) {
285
280
  /* used in test-utils */
286
281
  }
287
- .awsui_header-wrapper_gwq0h_hpg6a_261:not(#\9), .awsui_header-deprecated_gwq0h_hpg6a_218:not(#\9) {
282
+ .awsui_header-wrapper_gwq0h_12nx0_256:not(#\9), .awsui_header-deprecated_gwq0h_12nx0_216:not(#\9) {
288
283
  display: flex;
289
284
  font-weight: var(--font-weight-heading-s-cwn6wc, 700);
290
285
  }
291
- .awsui_header-wrapper_gwq0h_hpg6a_261:not(#\9) {
286
+ .awsui_header-wrapper_gwq0h_12nx0_256:not(#\9) {
292
287
  font-size: inherit;
293
288
  letter-spacing: inherit;
294
- margin: 0;
295
- padding: 0;
289
+ margin-block: 0;
290
+ margin-inline: 0;
291
+ padding-block: 0;
292
+ padding-inline: 0;
296
293
  }
297
- .awsui_header-actions-wrapper_gwq0h_hpg6a_271:not(#\9) {
298
- display: flex;
299
- flex-direction: row;
300
- justify-content: space-between;
301
- }
302
- body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_hpg6a_276:not(#\9):focus, body[data-awsui-focus-visible=true] .awsui_header-container-button_gwq0h_hpg6a_276:not(#\9):focus {
294
+ body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_12nx0_268:not(#\9):focus, body[data-awsui-focus-visible=true] .awsui_header-container-button_gwq0h_12nx0_268:not(#\9):focus {
303
295
  position: relative;
304
296
  }
305
- body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_hpg6a_276:not(#\9):focus, body[data-awsui-focus-visible=true] .awsui_header-container-button_gwq0h_hpg6a_276:not(#\9):focus {
297
+ body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_12nx0_268:not(#\9):focus, body[data-awsui-focus-visible=true] .awsui_header-container-button_gwq0h_12nx0_268:not(#\9):focus {
306
298
  outline: 2px dotted transparent;
307
299
  outline-offset: calc(0px - 1px);
308
300
  }
309
- body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_hpg6a_276:not(#\9):focus::before, body[data-awsui-focus-visible=true] .awsui_header-container-button_gwq0h_hpg6a_276:not(#\9):focus::before {
301
+ body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_12nx0_268:not(#\9):focus::before, body[data-awsui-focus-visible=true] .awsui_header-container-button_gwq0h_12nx0_268:not(#\9):focus::before {
310
302
  content: " ";
311
303
  display: block;
312
304
  position: absolute;
@@ -317,42 +309,44 @@ body[data-awsui-focus-visible=true] .awsui_header-button_gwq0h_hpg6a_276:not(#\9
317
309
  border-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
318
310
  box-shadow: 0 0 0 2px var(--color-border-item-focused-b2ntyl, #0972d3);
319
311
  }
320
- .awsui_header-button_gwq0h_hpg6a_276:not(#\9) {
312
+ .awsui_header-button_gwq0h_12nx0_268:not(#\9) {
321
313
  box-sizing: border-box;
322
314
  display: flex;
323
- margin-left: calc(-1 * calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px)));
315
+ margin-inline-start: calc(-1 * calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px)));
324
316
  }
325
- .awsui_header-container-button_gwq0h_hpg6a_276:not(#\9) {
326
- margin-left: calc(-1 * calc(var(--size-icon-medium-y9xuoq, 20px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xs-zb16t3, 8px)));
317
+ .awsui_header-container-button_gwq0h_12nx0_268:not(#\9) {
318
+ margin-inline-start: calc(-1 * calc(var(--size-icon-medium-y9xuoq, 20px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xs-zb16t3, 8px)));
327
319
  }
328
- .awsui_header-container_gwq0h_hpg6a_276:not(#\9) {
329
- width: 100%;
320
+ .awsui_header-container_gwq0h_12nx0_268:not(#\9) {
321
+ inline-size: 100%;
330
322
  }
331
- .awsui_header-container_gwq0h_hpg6a_276 > .awsui_icon-container_gwq0h_hpg6a_178:not(#\9) {
332
- margin-top: var(--space-expandable-section-icon-offset-top-ekk5vc, 4px);
323
+ .awsui_header-container_gwq0h_12nx0_268 > .awsui_icon-container_gwq0h_12nx0_178:not(#\9) {
324
+ margin-block-start: var(--space-expandable-section-icon-offset-top-ekk5vc, 4px);
333
325
  }
334
- .awsui_header-navigation_gwq0h_hpg6a_308 > .awsui_icon-container_gwq0h_hpg6a_178:not(#\9) {
326
+ .awsui_header-navigation_gwq0h_12nx0_300 > .awsui_icon-container_gwq0h_12nx0_178:not(#\9) {
335
327
  display: inline-flex;
336
328
  cursor: pointer;
337
329
  color: var(--color-text-expandable-section-navigation-icon-default-htcovl, #414d5c);
338
- border: 0;
339
- padding: 0;
330
+ border-block: 0;
331
+ border-inline: 0;
332
+ padding-block: 0;
333
+ padding-inline: 0;
340
334
  background: transparent;
341
335
  outline: none;
342
336
  text-decoration: none;
343
337
  flex-direction: column;
344
338
  }
345
- .awsui_header-navigation_gwq0h_hpg6a_308 > .awsui_icon-container_gwq0h_hpg6a_178:not(#\9):hover {
339
+ .awsui_header-navigation_gwq0h_12nx0_300 > .awsui_icon-container_gwq0h_12nx0_178:not(#\9):hover {
346
340
  color: var(--color-text-expandable-section-hover-2d1zpj, #0972d3);
347
341
  }
348
- body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_hpg6a_308 > .awsui_icon-container_gwq0h_hpg6a_178:not(#\9):focus {
342
+ body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_12nx0_300 > .awsui_icon-container_gwq0h_12nx0_178:not(#\9):focus {
349
343
  position: relative;
350
344
  }
351
- body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_hpg6a_308 > .awsui_icon-container_gwq0h_hpg6a_178:not(#\9):focus {
345
+ body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_12nx0_300 > .awsui_icon-container_gwq0h_12nx0_178:not(#\9):focus {
352
346
  outline: 2px dotted transparent;
353
347
  outline-offset: calc(2px - 1px);
354
348
  }
355
- body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_hpg6a_308 > .awsui_icon-container_gwq0h_hpg6a_178:not(#\9):focus::before {
349
+ body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_12nx0_300 > .awsui_icon-container_gwq0h_12nx0_178:not(#\9):focus::before {
356
350
  content: " ";
357
351
  display: block;
358
352
  position: absolute;
@@ -363,40 +357,39 @@ body[data-awsui-focus-visible=true] .awsui_header-navigation_gwq0h_hpg6a_308 > .
363
357
  border-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
364
358
  box-shadow: 0 0 0 2px var(--color-border-item-focused-b2ntyl, #0972d3);
365
359
  }
366
- .awsui_header-text_gwq0h_hpg6a_340:not(#\9) {
360
+ .awsui_header-text_gwq0h_12nx0_334:not(#\9) {
367
361
  /* used in test-utils */
368
362
  }
369
363
 
370
- .awsui_content_gwq0h_hpg6a_97:not(#\9) {
364
+ .awsui_content_gwq0h_12nx0_97:not(#\9) {
371
365
  display: none;
372
366
  }
373
- .awsui_content-default_gwq0h_hpg6a_347:not(#\9) {
374
- padding: var(--space-scaled-xs-26e2du, 8px) 0;
367
+ .awsui_content-default_gwq0h_12nx0_341:not(#\9) {
368
+ padding-block: var(--space-scaled-xs-26e2du, 8px);
369
+ padding-inline: 0;
375
370
  }
376
- .awsui_content-footer_gwq0h_hpg6a_350:not(#\9) {
377
- padding: var(--space-xs-zb16t3, 8px) 0;
371
+ .awsui_content-footer_gwq0h_12nx0_345:not(#\9) {
372
+ padding-block: var(--space-xs-zb16t3, 8px);
373
+ padding-inline: 0;
378
374
  }
379
- .awsui_content-expanded_gwq0h_hpg6a_353:not(#\9) {
375
+ .awsui_content-expanded_gwq0h_12nx0_349:not(#\9) {
380
376
  display: block;
381
377
  }
382
- .awsui_content-compact_gwq0h_hpg6a_356:not(#\9) {
383
- padding-inline-start: calc(var(--size-icon-normal-0m1722, 16px) + (var(--line-height-body-m-30ar75, 20px) - var(--size-icon-normal-0m1722, 16px)) / -2 + var(--space-xxs-p8yyaw, 4px) + var(--border-divider-list-width-27y3k5, 1px));
384
- }
385
378
 
386
- .awsui_focusable_gwq0h_hpg6a_360:not(#\9):focus {
379
+ .awsui_focusable_gwq0h_12nx0_353:not(#\9):focus {
387
380
  outline: none;
388
381
  text-decoration: none;
389
382
  }
390
- body[data-awsui-focus-visible=true] .awsui_focusable_gwq0h_hpg6a_360:not(#\9):focus {
383
+ body[data-awsui-focus-visible=true] .awsui_focusable_gwq0h_12nx0_353:not(#\9):focus {
391
384
  outline: 2px dotted transparent;
392
385
  border: var(--border-field-width-09w7vk, 2px) solid var(--color-border-item-focused-b2ntyl, #0972d3);
393
386
  border-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
394
387
  box-shadow: 0 0 0 var(--border-control-focus-ring-shadow-spread-0ctpjf, 0px) var(--color-border-item-focused-b2ntyl, #0972d3);
395
388
  }
396
389
 
397
- .awsui_click-target_gwq0h_hpg6a_371:not(#\9) {
390
+ .awsui_click-target_gwq0h_12nx0_364:not(#\9) {
398
391
  cursor: pointer;
399
392
  }
400
- .awsui_click-target_gwq0h_hpg6a_371:not(#\9):not(.awsui_wrapper-container_gwq0h_hpg6a_200):not(.awsui_header-container-button_gwq0h_hpg6a_276):hover {
393
+ .awsui_click-target_gwq0h_12nx0_364:not(#\9):not(.awsui_wrapper-container_gwq0h_12nx0_201):not(.awsui_header-container-button_gwq0h_12nx0_268):hover {
401
394
  color: var(--color-text-expandable-section-hover-2d1zpj, #0972d3);
402
395
  }