@adobe-commerce/elsie 2.0.0 → 2.1.0-alpha-20260730150638

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 (250) hide show
  1. package/.elsie.js +3 -3
  2. package/CHANGELOG.md +394 -112
  3. package/LICENSE.md +257 -157
  4. package/README.md +4 -2
  5. package/__mocks__/svg.js +3 -3
  6. package/bin/builders/build/index.js +2 -1
  7. package/bin/builders/concurrently/index.js +1 -1
  8. package/bin/builders/generate/api/index.js +7 -7
  9. package/bin/builders/generate/component/index.js +8 -8
  10. package/bin/builders/generate/config/index.js +5 -5
  11. package/bin/builders/generate/config/templates/elsie.js +1 -1
  12. package/bin/builders/generate/container/index.js +7 -7
  13. package/bin/builders/generate/index.js +36 -36
  14. package/bin/builders/gql/index.js +28 -28
  15. package/bin/builders/gql/validate.js +116 -105
  16. package/bin/builders/serve/index.js +1 -1
  17. package/bin/builders/types/validate-tsconfig.js +5 -5
  18. package/bin/index.js +12 -6
  19. package/bin/lib/cli.js +3 -3
  20. package/bin/lib/validate-typeof.js +3 -3
  21. package/bin/lib/write-file.js +3 -3
  22. package/bin/lib/write-parent-index.js +4 -4
  23. package/config/eslint.mjs +2 -1
  24. package/config/jest.mjs +7 -2
  25. package/config/plugins/dts-normalize-relative-replacer.cjs +1 -1
  26. package/config/plugins/dts.mjs +4 -3
  27. package/config/prettier.json +25 -3
  28. package/config/setEnvVars.mjs +2 -2
  29. package/config/storybook/addon.js +5 -5
  30. package/config/storybook/components/FileTree/FileTree.jsx +4 -4
  31. package/config/storybook/components/FileTree/index.js +4 -4
  32. package/config/storybook/components/Flex/Flex.jsx +3 -3
  33. package/config/storybook/components/Flex/index.js +3 -3
  34. package/config/storybook/components/OptionsTable/OptionsTable.jsx +3 -3
  35. package/config/storybook/components/OptionsTable/index.js +4 -4
  36. package/config/storybook/components/Panel/Panel.tsx +7 -7
  37. package/config/storybook/components/Panel/index.ts +3 -3
  38. package/config/storybook/components/Screenshot/Screenshot.jsx +3 -3
  39. package/config/storybook/components/Screenshot/index.js +4 -4
  40. package/config/storybook/components/Steps/Steps.jsx +3 -3
  41. package/config/storybook/components/Steps/index.js +4 -4
  42. package/config/storybook/components/StoryWrapper/StoryWrapper.jsx +3 -3
  43. package/config/storybook/components/StoryWrapper/index.js +3 -3
  44. package/config/storybook/components/Summary/Summary.jsx +3 -3
  45. package/config/storybook/components/Summary/index.js +3 -3
  46. package/config/storybook/components/Variants/Variants.jsx +11 -7
  47. package/config/storybook/components/Variants/index.js +3 -3
  48. package/config/storybook/manager.js +3 -3
  49. package/config/storybook/preview.jsx +3 -3
  50. package/config/storybook/theming/fonts.css +12 -4
  51. package/config/storybook/theming/preview.css +3 -1
  52. package/config/storybook/theming/theme.js +3 -3
  53. package/config/vite.mjs +53 -26
  54. package/package.json +15 -15
  55. package/src/components/Accordion/Accordion.css +1 -1
  56. package/src/components/Accordion/Accordion.stories.tsx +18 -18
  57. package/src/components/Accordion/Accordion.tsx +12 -8
  58. package/src/components/Accordion/index.ts +3 -3
  59. package/src/components/ActionButton/ActionButton.stories.tsx +8 -8
  60. package/src/components/ActionButton/ActionButton.tsx +7 -5
  61. package/src/components/ActionButton/index.ts +3 -3
  62. package/src/components/ActionButtonGroup/ActionButtonGroup.stories.tsx +3 -3
  63. package/src/components/ActionButtonGroup/ActionButtonGroup.tsx +2 -2
  64. package/src/components/ActionButtonGroup/index.ts +3 -3
  65. package/src/components/AlertBanner/AlertBanner.stories.tsx +6 -6
  66. package/src/components/AlertBanner/AlertBanner.tsx +12 -10
  67. package/src/components/AlertBanner/index.ts +3 -3
  68. package/src/components/Breadcrumbs/Breadcrumbs.stories.tsx +14 -14
  69. package/src/components/Breadcrumbs/Breadcrumbs.tsx +3 -3
  70. package/src/components/Breadcrumbs/index.ts +3 -3
  71. package/src/components/Button/Button.mdx +24 -11
  72. package/src/components/Button/Button.stories.tsx +6 -6
  73. package/src/components/Button/Button.tsx +48 -24
  74. package/src/components/Button/index.ts +3 -3
  75. package/src/components/Card/Card.stories.tsx +6 -6
  76. package/src/components/Card/Card.tsx +3 -3
  77. package/src/components/Card/index.ts +3 -3
  78. package/src/components/CartItem/CartItem.stories.tsx +12 -12
  79. package/src/components/CartItem/CartItem.tsx +4 -2
  80. package/src/components/CartItem/CartItemSkeleton.tsx +3 -3
  81. package/src/components/CartItem/index.ts +3 -3
  82. package/src/components/CartList/CartList.tsx +3 -3
  83. package/src/components/CartList/index.ts +3 -3
  84. package/src/components/Checkbox/Checkbox.stories.tsx +17 -14
  85. package/src/components/Checkbox/Checkbox.tsx +8 -6
  86. package/src/components/Checkbox/index.ts +3 -3
  87. package/src/components/ColorSwatch/ColorSwatch.css +8 -4
  88. package/src/components/ColorSwatch/ColorSwatch.stories.tsx +6 -6
  89. package/src/components/ColorSwatch/ColorSwatch.tsx +8 -6
  90. package/src/components/ColorSwatch/index.ts +3 -3
  91. package/src/components/ContentGrid/ContentGrid.css +15 -15
  92. package/src/components/ContentGrid/ContentGrid.stories.tsx +4 -4
  93. package/src/components/ContentGrid/ContentGrid.tsx +3 -3
  94. package/src/components/ContentGrid/index.ts +3 -3
  95. package/src/components/Divider/Divider.stories.tsx +7 -4
  96. package/src/components/Divider/Divider.tsx +3 -3
  97. package/src/components/Divider/index.ts +4 -4
  98. package/src/components/Field/Field.stories.tsx +7 -7
  99. package/src/components/Field/Field.tsx +4 -2
  100. package/src/components/Field/index.ts +3 -3
  101. package/src/components/Header/Header.stories.tsx +9 -10
  102. package/src/components/Header/Header.tsx +11 -7
  103. package/src/components/Header/index.ts +3 -3
  104. package/src/components/Icon/Icon.stories.helpers.jsx +4 -4
  105. package/src/components/Icon/Icon.stories.tsx +74 -60
  106. package/src/components/Icon/Icon.tsx +77 -44
  107. package/src/components/Icon/index.ts +3 -3
  108. package/src/components/IllustratedMessage/IllustratedMessage.stories.tsx +8 -8
  109. package/src/components/IllustratedMessage/IllustratedMessage.tsx +7 -5
  110. package/src/components/IllustratedMessage/index.ts +3 -3
  111. package/src/components/Image/Image.stories.tsx +3 -3
  112. package/src/components/Image/Image.tsx +4 -4
  113. package/src/components/Image/index.ts +3 -3
  114. package/src/components/ImageSwatch/ImageSwatch.css +8 -4
  115. package/src/components/ImageSwatch/ImageSwatch.stories.tsx +10 -10
  116. package/src/components/ImageSwatch/ImageSwatch.tsx +25 -23
  117. package/src/components/ImageSwatch/index.ts +3 -3
  118. package/src/components/InLineAlert/InLineAlert.stories.tsx +12 -7
  119. package/src/components/InLineAlert/InLineAlert.tsx +4 -2
  120. package/src/components/InLineAlert/index.ts +3 -3
  121. package/src/components/Incrementer/Incrementer.stories.tsx +9 -9
  122. package/src/components/Incrementer/Incrementer.tsx +75 -37
  123. package/src/components/Incrementer/index.ts +3 -3
  124. package/src/components/Input/Input.css +4 -1
  125. package/src/components/Input/Input.stories.tsx +5 -5
  126. package/src/components/Input/Input.tsx +5 -3
  127. package/src/components/Input/index.ts +3 -3
  128. package/src/components/InputDate/InputDate.tsx +3 -3
  129. package/src/components/InputDate/index.ts +3 -3
  130. package/src/components/InputFile/InputFile.css +16 -16
  131. package/src/components/InputFile/InputFile.stories.tsx +21 -16
  132. package/src/components/InputFile/InputFile.tsx +8 -6
  133. package/src/components/InputFile/index.ts +5 -5
  134. package/src/components/InputPassword/InputPassword.stories.tsx +4 -4
  135. package/src/components/InputPassword/InputPassword.tsx +5 -4
  136. package/src/components/InputPassword/PasswordStatusIndicator/PasswordStatusIndicator.tsx +1 -1
  137. package/src/components/InputPassword/PasswordStatusIndicator/index.ts +3 -3
  138. package/src/components/InputPassword/index.ts +3 -3
  139. package/src/components/LiveRegion/LiveRegion.css +20 -0
  140. package/src/components/LiveRegion/LiveRegion.mdx +83 -0
  141. package/src/components/LiveRegion/LiveRegion.stories.tsx +191 -0
  142. package/src/components/LiveRegion/LiveRegion.tsx +71 -0
  143. package/src/components/LiveRegion/index.ts +10 -0
  144. package/src/components/Modal/Modal.stories.tsx +27 -16
  145. package/src/components/Modal/Modal.tsx +10 -11
  146. package/src/components/Modal/index.ts +3 -3
  147. package/src/components/MultiSelect/MultiSelect.stories.tsx +15 -15
  148. package/src/components/MultiSelect/MultiSelect.tsx +15 -15
  149. package/src/components/Pagination/Pagination.css +1 -1
  150. package/src/components/Pagination/Pagination.stories.tsx +0 -1
  151. package/src/components/Pagination/Pagination.tsx +17 -12
  152. package/src/components/Pagination/PaginationButton.tsx +2 -3
  153. package/src/components/Pagination/index.ts +3 -3
  154. package/src/components/Picker/Picker.css +3 -1
  155. package/src/components/Picker/Picker.stories.tsx +1 -1
  156. package/src/components/Picker/Picker.tsx +8 -6
  157. package/src/components/Picker/index.ts +3 -3
  158. package/src/components/Portal/Portal.stories.tsx +50 -44
  159. package/src/components/Portal/Portal.tsx +4 -4
  160. package/src/components/Price/Price.stories.tsx +3 -3
  161. package/src/components/Price/Price.tsx +4 -2
  162. package/src/components/Price/index.ts +3 -3
  163. package/src/components/PriceRange/PriceRange.stories.tsx +3 -3
  164. package/src/components/PriceRange/PriceRange.tsx +8 -6
  165. package/src/components/PriceRange/index.ts +3 -3
  166. package/src/components/ProductItemCard/ProductItemCard.tsx +4 -2
  167. package/src/components/ProductItemCard/ProductItemCardSkeleton.tsx +16 -16
  168. package/src/components/ProductItemCard/index.ts +4 -4
  169. package/src/components/ProgressSpinner/ProgressSpinner.stories.tsx +8 -8
  170. package/src/components/ProgressSpinner/ProgressSpinner.tsx +7 -5
  171. package/src/components/ProgressSpinner/index.ts +3 -3
  172. package/src/components/RadioButton/RadioButton.stories.tsx +1 -1
  173. package/src/components/RadioButton/RadioButton.tsx +4 -2
  174. package/src/components/Skeleton/Skeleton.stories.tsx +4 -4
  175. package/src/components/Skeleton/Skeleton.tsx +11 -7
  176. package/src/components/Skeleton/index.ts +3 -3
  177. package/src/components/Table/Table.css +106 -99
  178. package/src/components/Table/Table.stories.tsx +404 -227
  179. package/src/components/Table/Table.tsx +11 -7
  180. package/src/components/Table/index.ts +4 -4
  181. package/src/components/Tag/Tag.stories.tsx +6 -6
  182. package/src/components/Tag/Tag.tsx +7 -5
  183. package/src/components/Tag/index.ts +3 -3
  184. package/src/components/TextArea/TextArea.css +3 -1
  185. package/src/components/TextArea/TextArea.stories.tsx +9 -6
  186. package/src/components/TextArea/TextArea.tsx +3 -3
  187. package/src/components/TextArea/index.ts +3 -3
  188. package/src/components/TextSwatch/TextSwatch.css +4 -2
  189. package/src/components/TextSwatch/TextSwatch.stories.tsx +8 -8
  190. package/src/components/TextSwatch/TextSwatch.tsx +12 -7
  191. package/src/components/TextSwatch/index.ts +3 -3
  192. package/src/components/ToggleButton/ToggleButton.css +6 -2
  193. package/src/components/ToggleButton/ToggleButton.stories.tsx +10 -6
  194. package/src/components/ToggleButton/ToggleButton.tsx +8 -3
  195. package/src/components/ToggleButton/index.ts +3 -3
  196. package/src/components/UIProvider/UIProvider.css +3 -2
  197. package/src/components/UIProvider/UIProvider.tsx +11 -7
  198. package/src/components/UIProvider/debugger.css +5 -6
  199. package/src/components/UIProvider/index.ts +3 -3
  200. package/src/components/index.ts +1 -0
  201. package/src/docs/API/event-bus.mdx +64 -37
  202. package/src/docs/API/graphql.mdx +69 -36
  203. package/src/docs/API/initializer.mdx +58 -35
  204. package/src/docs/API/render.mdx +45 -32
  205. package/src/docs/Design/colors.mdx +10 -12
  206. package/src/docs/Design/grid.mdx +41 -14
  207. package/src/docs/Design/overview.mdx +20 -4
  208. package/src/docs/Design/shapes.mdx +8 -7
  209. package/src/docs/Design/spacing.mdx +3 -1
  210. package/src/docs/Design/typography.mdx +3 -2
  211. package/src/docs/Utilities/VComponent.mdx +27 -10
  212. package/src/docs/Utilities/classList.mdx +7 -5
  213. package/src/docs/Utilities/debounce.mdx +6 -7
  214. package/src/docs/Utilities/getCookie.mdx +1 -2
  215. package/src/docs/Utilities/getFormErrors.mdx +1 -2
  216. package/src/docs/Utilities/getFormValues.mdx +1 -2
  217. package/src/docs/Utilities/getPathValue.mdx +2 -4
  218. package/src/docs/Utilities/links.mdx +16 -7
  219. package/src/docs/cli-usage.mdx +8 -3
  220. package/src/docs/components/overview.mdx +14 -4
  221. package/src/docs/quick-start.mdx +69 -22
  222. package/src/docs/slots.mdx +74 -37
  223. package/src/docs/welcome.mdx +13 -4
  224. package/src/i18n/index.ts +3 -3
  225. package/src/lib/aem/assets.ts +9 -9
  226. package/src/lib/aem/configs.ts +16 -8
  227. package/src/lib/classes.ts +4 -4
  228. package/src/lib/config.ts +3 -3
  229. package/src/lib/debounce.ts +3 -3
  230. package/src/lib/deepmerge.ts +6 -13
  231. package/src/lib/deviceUtils.ts +3 -3
  232. package/src/lib/form-values.ts +3 -3
  233. package/src/lib/get-price-formatter.ts +8 -3
  234. package/src/lib/i18n.ts +3 -3
  235. package/src/lib/image-params-keymap.ts +3 -3
  236. package/src/lib/initializer.ts +11 -12
  237. package/src/lib/is-number.ts +3 -3
  238. package/src/lib/locale-config.ts +4 -4
  239. package/src/lib/render.tsx +14 -8
  240. package/src/lib/resolve-image.ts +19 -16
  241. package/src/lib/signals.ts +4 -4
  242. package/src/lib/slot.tsx +34 -27
  243. package/src/lib/tests.tsx +6 -8
  244. package/src/lib/types.ts +3 -3
  245. package/src/lib/vcomponent.tsx +3 -3
  246. package/src/shims/importmap.js +3107 -20
  247. package/static/assets/images/index.ts +3 -3
  248. package/storybook-stories.js +3 -3
  249. package/tests/__mocks__/browserMocks.ts +3 -3
  250. package/tests/__mocks__/fileMocks.ts +3 -3
package/CHANGELOG.md CHANGED
@@ -1,59 +1,117 @@
1
1
  # @adobe-commerce/elsie
2
2
 
3
+ ## 2.1.0-alpha-20260730150638
4
+
5
+ ### Minor Changes
6
+
7
+ - d9ac070: feat(a11y): add LiveRegion component and Button loading state for
8
+ WCAG 4.1.3
9
+
10
+ - New `LiveRegion` component: a visually-hidden, always-mounted
11
+ `role="status"` span for announcing status changes to screen readers without
12
+ focus movement. Accepts `message` (string toggled between empty and the
13
+ label) and `politeness` ("polite" | "assertive"). Use this alongside
14
+ `Skeleton` and `ProgressSpinner` instead of relying on those components' own
15
+ `role="status"` which fires unreliably when they are conditionally mounted.
16
+ - `Button` now accepts `loading?: boolean` (sets `aria-busy` on the button
17
+ element) and `loadingLabel?: string` (renders a sibling `LiveRegion` outside
18
+ the button element — live regions must not be nested inside interactive
19
+ elements).
20
+
21
+ ### Patch Changes
22
+
23
+ - a920177: fix(Incrementer): prevent quantity input flicker during in-progress
24
+ typing, and prevent double onValue call when debounce fires before blur
25
+
3
26
  ## 2.0.0
4
27
 
5
28
  ### Major Changes
6
29
 
7
30
  - ea02d5f: Upgrade Jest to 30.4.2 and Storybook to 10.4.0
8
31
 
9
- Updated testing and component development tools to latest stable versions. Jest 30.4.2 provides enhanced snapshot handling and improved test performance. Storybook 10.4.0 includes updated addon ecosystem, improved Preact Vite integration, and enhanced accessibility features with addon-a11y and addon-coverage support.
32
+ Updated testing and component development tools to latest stable versions.
33
+ Jest 30.4.2 provides enhanced snapshot handling and improved test performance.
34
+ Storybook 10.4.0 includes updated addon ecosystem, improved Preact Vite
35
+ integration, and enhanced accessibility features with addon-a11y and
36
+ addon-coverage support.
10
37
 
11
38
  - 9cd299b: Upgrade TypeScript to 6.0 and ESLint to 9 (flat config)
12
39
 
13
40
  ## What changed
14
41
 
15
42
  ### TypeScript 4.7 → 6.0
16
-
17
- - `tsconfig-base.json` updated with correct TS 6 defaults. Two new-default opt-outs are deferred as tech debt: `exactOptionalPropertyTypes` and `verbatimModuleSyntax`.
18
- - `moduleResolution` changed from `"nodenext"` to `"bundler"` across all packages — the correct pairing for `module: "esnext"` in a Vite monorepo. Only `packages/elsie` keeps `"NodeNext"` (paired with `module: "NodeNext"` for its dual CJS/ESM output).
19
- - `baseUrl` removed from all tsconfigs (deprecated in TS 6; `paths` resolves relative to the tsconfig file directly).
20
- - `rootDir` added explicitly to `build-tools`, `event-bus`, `fetch-graphql`, and `recaptcha` tsconfigs (implicit `rootDir` deprecated in TS 6).
21
- - `types: []` set in `tsconfig-base.json` to prevent ambient test types from leaking into declaration output. Each package's own `tsconfig.json` declares its `types` explicitly (`jest`, `node`, `vite/client`, etc.).
22
- - `babel-plugin-tsconfig-paths` removed — it was a no-op in every package that listed it.
23
- - `noUncheckedIndexedAccess` enabled — violations were few enough to fix in source.
43
+ - `tsconfig-base.json` updated with correct TS 6 defaults. Two new-default
44
+ opt-outs are deferred as tech debt: `exactOptionalPropertyTypes` and
45
+ `verbatimModuleSyntax`.
46
+ - `moduleResolution` changed from `"nodenext"` to `"bundler"` across all
47
+ packages — the correct pairing for `module: "esnext"` in a Vite monorepo.
48
+ Only `packages/elsie` keeps `"NodeNext"` (paired with `module: "NodeNext"`
49
+ for its dual CJS/ESM output).
50
+ - `baseUrl` removed from all tsconfigs (deprecated in TS 6; `paths` resolves
51
+ relative to the tsconfig file directly).
52
+ - `rootDir` added explicitly to `build-tools`, `event-bus`, `fetch-graphql`,
53
+ and `recaptcha` tsconfigs (implicit `rootDir` deprecated in TS 6).
54
+ - `types: []` set in `tsconfig-base.json` to prevent ambient test types from
55
+ leaking into declaration output. Each package's own `tsconfig.json` declares
56
+ its `types` explicitly (`jest`, `node`, `vite/client`, etc.).
57
+ - `babel-plugin-tsconfig-paths` removed — it was a no-op in every package that
58
+ listed it.
59
+ - `noUncheckedIndexedAccess` enabled — violations were few enough to fix in
60
+ source.
24
61
 
25
62
  ### ESLint 8 → 9 (flat config)
26
-
27
- - `@typescript-eslint/parser` and `@typescript-eslint/eslint-plugin` (v5) removed; replaced by the unified `typescript-eslint` v8 package.
63
+ - `@typescript-eslint/parser` and `@typescript-eslint/eslint-plugin` (v5)
64
+ removed; replaced by the unified `typescript-eslint` v8 package.
28
65
  - `eslint-config-preact` bumped to `^2.0.0` (ESLint 9 support).
29
66
  - `eslint-config-prettier` bumped to `^10.0.0`.
30
- - `eslint-plugin-mdx` bumped to `^3.8.1`. **ESLint 10 is not supported** — `eslint-plugin-mdx` vendors an internal ESLint API removed in v10; ESLint 9 is pinned until a fix is released.
67
+ - `eslint-plugin-mdx` bumped to `^3.8.1`. **ESLint 10 is not supported** —
68
+ `eslint-plugin-mdx` vendors an internal ESLint API removed in v10; ESLint 9
69
+ is pinned until a fix is released.
31
70
  - `globals` added (`^15.0.0`) for `languageOptions.globals` in flat config.
32
- - Shared config (`packages/elsie/config/eslint.mjs`) rewritten as a flat-config array export.
33
- - Per-package `.eslintrc.js` files deleted; replaced with `eslint.config.js` (ESM flat config).
34
- - Several `typescript-eslint` v8 rules disabled to preserve prior behavior: `no-explicit-any`, `ban-ts-comment`, `no-unused-expressions`, `no-unsafe-function-type`, `no-require-imports`, `no-empty-object-type`. Tracked as tech debt.
35
- - `reportUnusedDisableDirectives` disabled to avoid sweeping pre-existing inline disable comments.
71
+ - Shared config (`packages/elsie/config/eslint.mjs`) rewritten as a
72
+ flat-config array export.
73
+ - Per-package `.eslintrc.js` files deleted; replaced with `eslint.config.js`
74
+ (ESM flat config).
75
+ - Several `typescript-eslint` v8 rules disabled to preserve prior behavior:
76
+ `no-explicit-any`, `ban-ts-comment`, `no-unused-expressions`,
77
+ `no-unsafe-function-type`, `no-require-imports`, `no-empty-object-type`.
78
+ Tracked as tech debt.
79
+ - `reportUnusedDisableDirectives` disabled to avoid sweeping pre-existing
80
+ inline disable comments.
36
81
 
37
82
  ### `vite-plugin-dts` removed; replaced with custom `dtsPlugin`
38
83
 
39
- `vite-plugin-dts@3.9.1` declared a `typescript <5.0` peer range and its v5 successor was incompatible with this monorepo's layout (cross-package sources, workspace symlinks, multi-`outDir`). It was removed and replaced with a thin custom Vite plugin at `packages/elsie/config/plugins/dts.mjs` (`dtsPlugin`) that runs `tsc` directly. The resulting `dist/` layout is identical to what v3.9 produced (147 `.d.ts` files, 12 top-level entry shims).
84
+ `vite-plugin-dts@3.9.1` declared a `typescript <5.0` peer range and its v5
85
+ successor was incompatible with this monorepo's layout (cross-package sources,
86
+ workspace symlinks, multi-`outDir`). It was removed and replaced with a thin
87
+ custom Vite plugin at `packages/elsie/config/plugins/dts.mjs` (`dtsPlugin`)
88
+ that runs `tsc` directly. The resulting `dist/` layout is identical to what
89
+ v3.9 produced (147 `.d.ts` files, 12 top-level entry shims).
40
90
 
41
91
  ### Module format standardization
42
92
 
43
93
  All tooling config files now follow a consistent format:
44
94
 
45
- - **ESLint / Jest / Vite configs** — ESM (`.js` in `"type":"module"` packages; `.mjs` in elsie).
46
- - **Prettier** — JSON only (`@adobe-commerce/elsie/config/prettier.json` referenced via each package's `"prettier"` key). `prettier.config.*` files deleted from all packages.
95
+ - **ESLint / Jest / Vite configs** — ESM (`.js` in `"type":"module"` packages;
96
+ `.mjs` in elsie).
97
+ - **Prettier** — JSON only (`@adobe-commerce/elsie/config/prettier.json`
98
+ referenced via each package's `"prettier"` key). `prettier.config.*` files
99
+ deleted from all packages.
47
100
  - **elsie CLI** (`bin/**`) — intentionally stays CommonJS.
48
101
 
49
102
  See `architecture/decisions/009-module-format.md` for the full convention.
50
103
 
51
104
  ### `.elsie.js` → `.elsie.cjs`
52
105
 
53
- The consumer project config file is renamed from `.elsie.js` to `.elsie.cjs`. With `"type":"module"` now required in consumer packages, a plain `.js` file is treated as ES module — making `module.exports` a SyntaxError and making `require()` in the elsie CLI fail with `ERR_REQUIRE_ESM`. The `.cjs` extension forces CommonJS regardless of the package's `"type"` field.
106
+ The consumer project config file is renamed from `.elsie.js` to `.elsie.cjs`.
107
+ With `"type":"module"` now required in consumer packages, a plain `.js` file
108
+ is treated as ES module — making `module.exports` a SyntaxError and making
109
+ `require()` in the elsie CLI fail with `ERR_REQUIRE_ESM`. The `.cjs` extension
110
+ forces CommonJS regardless of the package's `"type"` field.
54
111
 
55
112
  - `elsie generate config` now writes `.elsie.cjs`.
56
- - The CLI (`bin/lib/config.js`) and `config/vite.mjs` both prefer `.elsie.cjs` and fall back to `.elsie.js` for packages not yet migrated.
113
+ - The CLI (`bin/lib/config.js`) and `config/vite.mjs` both prefer `.elsie.cjs`
114
+ and fall back to `.elsie.js` for packages not yet migrated.
57
115
  - `.elsie.cjs` added to `.npmignore` in all consumer packages.
58
116
 
59
117
  ## Consumer migration
@@ -61,20 +119,29 @@
61
119
  See `docs/elsie-v2-migration.md` for the full step-by-step guide. Key actions:
62
120
 
63
121
  1. Add `"type": "module"` to `package.json`.
64
- 2. Replace `.eslintrc.js` with `eslint.config.js` (ESM flat config importing from `@adobe-commerce/elsie/config/eslint.mjs`).
122
+ 2. Replace `.eslintrc.js` with `eslint.config.js` (ESM flat config importing
123
+ from `@adobe-commerce/elsie/config/eslint.mjs`).
65
124
  3. Rename `.elsie.js` → `.elsie.cjs` (keep `module.exports` content as-is).
66
- 4. Add `"prettier": "@adobe-commerce/elsie/config/prettier.json"` to `package.json`; delete `prettier.config.js`.
67
- 5. Update `tsconfig.json`: remove `baseUrl`, add explicit `rootDir` and `types`.
125
+ 4. Add `"prettier": "@adobe-commerce/elsie/config/prettier.json"` to
126
+ `package.json`; delete `prettier.config.js`.
127
+ 5. Update `tsconfig.json`: remove `baseUrl`, add explicit `rootDir` and
128
+ `types`.
68
129
  6. Add `tsconfig.build.json` for declaration emit (required by `dtsPlugin`).
69
- 7. Convert `.elsie.js` imports in `.storybook/main.js` and `storybook-stories.js` to reference `.elsie.cjs`.
130
+ 7. Convert `.elsie.js` imports in `.storybook/main.js` and
131
+ `storybook-stories.js` to reference `.elsie.cjs`.
70
132
 
71
133
  ### Minor Changes
72
134
 
73
135
  - c21a378: Add optional `cypress` export to shared ESLint config
74
136
 
75
- `cypress` is a new named export from `@adobe-commerce/elsie/config/eslint.mjs` that provides a pre-configured ESLint flat config for Cypress test files (`cypress/**/*.js`). It applies `eslint-plugin-cypress`'s recommended rules with `jest/expect-expect` turned off.
137
+ `cypress` is a new named export from `@adobe-commerce/elsie/config/eslint.mjs`
138
+ that provides a pre-configured ESLint flat config for Cypress test files
139
+ (`cypress/**/*.js`). It applies `eslint-plugin-cypress`'s recommended rules
140
+ with `jest/expect-expect` turned off.
76
141
 
77
- The plugin is declared as an optional peer dependency — `cypress` resolves to an empty array when `eslint-plugin-cypress` is not installed, so projects that don't use Cypress are unaffected.
142
+ The plugin is declared as an optional peer dependency — `cypress` resolves to
143
+ an empty array when `eslint-plugin-cypress` is not installed, so projects that
144
+ don't use Cypress are unaffected.
78
145
 
79
146
  ## Usage
80
147
 
@@ -95,41 +162,102 @@
95
162
  export default [...base, ...cypress, ...sourceImportRestrictions];
96
163
  ```
97
164
 
98
- - 9d558ed: Adds `window.DROPINS.showOverlays(state)` — a developer utility that visually outlines all dropin containers and slots on the page with labeled overlays, making it easier to understand how the storefront is composed at runtime.
165
+ - 9d558ed: Adds `window.DROPINS.showOverlays(state)` — a developer utility that
166
+ visually outlines all dropin containers and slots on the page with labeled
167
+ overlays, making it easier to understand how the storefront is composed at
168
+ runtime.
99
169
 
100
- `DROPINS.showSlots()` is deprecated in favor of `showOverlays()` and will log a console warning when called.
170
+ `DROPINS.showSlots()` is deprecated in favor of `showOverlays()` and will log
171
+ a console warning when called.
101
172
 
102
173
  - c25a5d7: feat(elsie): add `changeset` builder command
103
174
 
104
- Adds `elsie changeset` as a first-class CLI command, wrapping `@changesets/cli`. All subcommands pass through transparently (`status`, `version`, `publish`, `--snapshot`, etc.). `@changesets/cli` is now a dependency of elsie, so consumers no longer need to install it separately.
175
+ Adds `elsie changeset` as a first-class CLI command, wrapping
176
+ `@changesets/cli`. All subcommands pass through transparently (`status`,
177
+ `version`, `publish`, `--snapshot`, etc.). `@changesets/cli` is now a
178
+ dependency of elsie, so consumers no longer need to install it separately.
105
179
 
106
- - 005edc7: Adds validation to the Incrementer component when the field is changed to "empty".
180
+ - 005edc7: Adds validation to the Incrementer component when the field is
181
+ changed to "empty".
107
182
 
108
183
  ### Patch Changes
109
184
 
110
- - bf352d2: Fix InputDate showing wrong format after selecting a date from the calendar
111
- - 4c3d82d: fix(field): associate error messages with inputs via aria-describedby (WCAG 3.3.1)
112
- - 36354d9: Add disableWhenSingle prop to Picker; defaults to true (preserves existing behavior). Pass false to keep the picker interactive when only one option is available.
113
- - 09c2100: Declare `preact` as a runtime dependency. It previously sat in `devDependencies` (unlike `@preact/signals` and `preact-i18n`), so standalone consumers of `@adobe-commerce/elsie` had an unmet `preact` — also the unmet peer of `@preact/preset-vite`, `@storybook/preact-vite` and `@testing-library/preact`. It now resolves to the same `~10.22.1` bundled into `@dropins/tools`. The emitted bundle is unchanged.
114
- - 4641ab0: Fix `Field` and `InLineAlert` status/error messages not being announced by screen readers. `Field`'s description/hint element now always carries `role="status"` and `aria-live="polite"`, instead of only adding `aria-live` once an error appeared, so assistive technology reliably announces validation and success messages (WCAG 4.1.3). `InLineAlert` now sets `role="alert"`/`aria-live="assertive"` for `type="error"` and `role="status"`/`aria-live="polite"` for `success`/`warning`, since it previously had no live-region semantics at all.
115
- - ccada8c: Reset default margin on Header and CartItem titles to support rendering them as semantic headings
116
- - cb6eb81: Fix `InLineAlert` additional-action buttons announcing the same accessible name across multiple alerts. Each entry in `additionalActions` may now include an optional `'aria-label'` that is applied to the rendered button (falling back to `label` when omitted), so consumers can give visually identical "Undo"/"Dismiss" style buttons unique, descriptive names for assistive technology.
117
- - ab5cf32: Fix `Modal` accessibility: the dialog now exposes `role="dialog"`, `aria-modal="true"`, and an `aria-labelledby` linked to its title. Focus moves into the modal when it opens (falling back to the dialog body when there are no focusable elements), Tab/Shift+Tab now cycles between the first and last focusable elements instead of escaping the modal, and focus returns to the previously focused element when the modal closes.
118
- - 58da630: Fix `Picker` accessible name and label association. The `<select>` now falls back to `floatingLabel` or `placeholder` for its `aria-label` when no `name` is provided, and the floating `<label>` is now correctly associated with the rendered `<select>` via its generated id instead of the raw `id` prop.
119
- - 450c408: fix(Picker): auto-select and emit the sole option when the control auto-disables, so single-option narrowing on configurable PDPs no longer leaves the value unselected and Add to Cart permanently disabled
120
- - 33ebe8a: Add accessible labels to password validation and input status icons (WCAG 1.1.1)
121
- - 2ad7316: Fix `ToggleButton`'s underlying radio input announcing the shared radio-group `name` (e.g. "payment-method") as its accessible name for every option instead of the option's own visible label, which violates WCAG 2.4.6 (Headings and Labels) and 2.5.3 (Label in Name). The radio input's accessible name now defaults to `aria-labelledby` pointing at the option's own visible label content (e.g. "Check / Money order"), which works correctly whether `label` is a string or a `VNode`. An optional `ariaLabel` prop is still available for consumers who need to set an explicit accessible name via `aria-label` instead.
122
- - 256007e: Fix ToggleButton generating invalid HTML ids when value prop contains spaces, breaking aria-labelledby label association
123
- - 016a558: Fix low-contrast field label text in `Input` when a field is in an error state. The floating label color now meets WCAG AA contrast requirements for normal-size text against light backgrounds, matching the color already used for error text elsewhere (helper text, alerts).
124
- - 51fcb35: fix(a11y): darken low-contrast focus indicators to meet WCAG 1.4.11 (3:1 non-text contrast)
125
-
126
- The default keyboard focus indicator across Button, IconButton, Checkbox, RadioButton, ActionButton, ActionButtonGroup, ToggleButton, TextSwatch, ColorSwatch, ImageSwatch, and links used `--color-neutral-400` (#d6d6d6, ~1.45:1 against white), below the 3:1 minimum required by WCAG 1.4.11. These focus indicators now use `--color-neutral-600` (#8f8f8f, ~3.2:1), so keyboard users can reliably see which control is focused.
185
+ - bf352d2: Fix InputDate showing wrong format after selecting a date from the
186
+ calendar
187
+ - 4c3d82d: fix(field): associate error messages with inputs via aria-describedby
188
+ (WCAG 3.3.1)
189
+ - 36354d9: Add disableWhenSingle prop to Picker; defaults to true (preserves
190
+ existing behavior). Pass false to keep the picker interactive when only one
191
+ option is available.
192
+ - 09c2100: Declare `preact` as a runtime dependency. It previously sat in
193
+ `devDependencies` (unlike `@preact/signals` and `preact-i18n`), so standalone
194
+ consumers of `@adobe-commerce/elsie` had an unmet `preact` — also the unmet
195
+ peer of `@preact/preset-vite`, `@storybook/preact-vite` and
196
+ `@testing-library/preact`. It now resolves to the same `~10.22.1` bundled into
197
+ `@dropins/tools`. The emitted bundle is unchanged.
198
+ - 4641ab0: Fix `Field` and `InLineAlert` status/error messages not being
199
+ announced by screen readers. `Field`'s description/hint element now always
200
+ carries `role="status"` and `aria-live="polite"`, instead of only adding
201
+ `aria-live` once an error appeared, so assistive technology reliably announces
202
+ validation and success messages (WCAG 4.1.3). `InLineAlert` now sets
203
+ `role="alert"`/`aria-live="assertive"` for `type="error"` and
204
+ `role="status"`/`aria-live="polite"` for `success`/`warning`, since it
205
+ previously had no live-region semantics at all.
206
+ - ccada8c: Reset default margin on Header and CartItem titles to support
207
+ rendering them as semantic headings
208
+ - cb6eb81: Fix `InLineAlert` additional-action buttons announcing the same
209
+ accessible name across multiple alerts. Each entry in `additionalActions` may
210
+ now include an optional `'aria-label'` that is applied to the rendered button
211
+ (falling back to `label` when omitted), so consumers can give visually
212
+ identical "Undo"/"Dismiss" style buttons unique, descriptive names for
213
+ assistive technology.
214
+ - ab5cf32: Fix `Modal` accessibility: the dialog now exposes `role="dialog"`,
215
+ `aria-modal="true"`, and an `aria-labelledby` linked to its title. Focus moves
216
+ into the modal when it opens (falling back to the dialog body when there are
217
+ no focusable elements), Tab/Shift+Tab now cycles between the first and last
218
+ focusable elements instead of escaping the modal, and focus returns to the
219
+ previously focused element when the modal closes.
220
+ - 58da630: Fix `Picker` accessible name and label association. The `<select>`
221
+ now falls back to `floatingLabel` or `placeholder` for its `aria-label` when
222
+ no `name` is provided, and the floating `<label>` is now correctly associated
223
+ with the rendered `<select>` via its generated id instead of the raw `id`
224
+ prop.
225
+ - 450c408: fix(Picker): auto-select and emit the sole option when the control
226
+ auto-disables, so single-option narrowing on configurable PDPs no longer
227
+ leaves the value unselected and Add to Cart permanently disabled
228
+ - 33ebe8a: Add accessible labels to password validation and input status icons
229
+ (WCAG 1.1.1)
230
+ - 2ad7316: Fix `ToggleButton`'s underlying radio input announcing the shared
231
+ radio-group `name` (e.g. "payment-method") as its accessible name for every
232
+ option instead of the option's own visible label, which violates WCAG 2.4.6
233
+ (Headings and Labels) and 2.5.3 (Label in Name). The radio input's accessible
234
+ name now defaults to `aria-labelledby` pointing at the option's own visible
235
+ label content (e.g. "Check / Money order"), which works correctly whether
236
+ `label` is a string or a `VNode`. An optional `ariaLabel` prop is still
237
+ available for consumers who need to set an explicit accessible name via
238
+ `aria-label` instead.
239
+ - 256007e: Fix ToggleButton generating invalid HTML ids when value prop contains
240
+ spaces, breaking aria-labelledby label association
241
+ - 016a558: Fix low-contrast field label text in `Input` when a field is in an
242
+ error state. The floating label color now meets WCAG AA contrast requirements
243
+ for normal-size text against light backgrounds, matching the color already
244
+ used for error text elsewhere (helper text, alerts).
245
+ - 51fcb35: fix(a11y): darken low-contrast focus indicators to meet WCAG 1.4.11
246
+ (3:1 non-text contrast)
247
+
248
+ The default keyboard focus indicator across Button, IconButton, Checkbox,
249
+ RadioButton, ActionButton, ActionButtonGroup, ToggleButton, TextSwatch,
250
+ ColorSwatch, ImageSwatch, and links used `--color-neutral-400` (#d6d6d6,
251
+ ~1.45:1 against white), below the 3:1 minimum required by WCAG 1.4.11. These
252
+ focus indicators now use `--color-neutral-600` (#8f8f8f, ~3.2:1), so keyboard
253
+ users can reliably see which control is focused.
127
254
 
128
255
  ## 2.0.0-beta.1
129
256
 
130
257
  ### Patch Changes
131
258
 
132
- - 256007e: Fix ToggleButton generating invalid HTML ids when value prop contains spaces, breaking aria-labelledby label association
259
+ - 256007e: Fix ToggleButton generating invalid HTML ids when value prop contains
260
+ spaces, breaking aria-labelledby label association
133
261
 
134
262
  ## 2.0.0-beta.0
135
263
 
@@ -137,54 +265,89 @@
137
265
 
138
266
  - ea02d5f: Upgrade Jest to 30.4.2 and Storybook to 10.4.0
139
267
 
140
- Updated testing and component development tools to latest stable versions. Jest 30.4.2 provides enhanced snapshot handling and improved test performance. Storybook 10.4.0 includes updated addon ecosystem, improved Preact Vite integration, and enhanced accessibility features with addon-a11y and addon-coverage support.
268
+ Updated testing and component development tools to latest stable versions.
269
+ Jest 30.4.2 provides enhanced snapshot handling and improved test performance.
270
+ Storybook 10.4.0 includes updated addon ecosystem, improved Preact Vite
271
+ integration, and enhanced accessibility features with addon-a11y and
272
+ addon-coverage support.
141
273
 
142
274
  - 9cd299b: Upgrade TypeScript to 6.0 and ESLint to 9 (flat config)
143
275
 
144
276
  ## What changed
145
277
 
146
278
  ### TypeScript 4.7 → 6.0
147
-
148
- - `tsconfig-base.json` updated with correct TS 6 defaults. Two new-default opt-outs are deferred as tech debt: `exactOptionalPropertyTypes` and `verbatimModuleSyntax`.
149
- - `moduleResolution` changed from `"nodenext"` to `"bundler"` across all packages — the correct pairing for `module: "esnext"` in a Vite monorepo. Only `packages/elsie` keeps `"NodeNext"` (paired with `module: "NodeNext"` for its dual CJS/ESM output).
150
- - `baseUrl` removed from all tsconfigs (deprecated in TS 6; `paths` resolves relative to the tsconfig file directly).
151
- - `rootDir` added explicitly to `build-tools`, `event-bus`, `fetch-graphql`, and `recaptcha` tsconfigs (implicit `rootDir` deprecated in TS 6).
152
- - `types: []` set in `tsconfig-base.json` to prevent ambient test types from leaking into declaration output. Each package's own `tsconfig.json` declares its `types` explicitly (`jest`, `node`, `vite/client`, etc.).
153
- - `babel-plugin-tsconfig-paths` removed — it was a no-op in every package that listed it.
154
- - `noUncheckedIndexedAccess` enabled — violations were few enough to fix in source.
279
+ - `tsconfig-base.json` updated with correct TS 6 defaults. Two new-default
280
+ opt-outs are deferred as tech debt: `exactOptionalPropertyTypes` and
281
+ `verbatimModuleSyntax`.
282
+ - `moduleResolution` changed from `"nodenext"` to `"bundler"` across all
283
+ packages — the correct pairing for `module: "esnext"` in a Vite monorepo.
284
+ Only `packages/elsie` keeps `"NodeNext"` (paired with `module: "NodeNext"`
285
+ for its dual CJS/ESM output).
286
+ - `baseUrl` removed from all tsconfigs (deprecated in TS 6; `paths` resolves
287
+ relative to the tsconfig file directly).
288
+ - `rootDir` added explicitly to `build-tools`, `event-bus`, `fetch-graphql`,
289
+ and `recaptcha` tsconfigs (implicit `rootDir` deprecated in TS 6).
290
+ - `types: []` set in `tsconfig-base.json` to prevent ambient test types from
291
+ leaking into declaration output. Each package's own `tsconfig.json` declares
292
+ its `types` explicitly (`jest`, `node`, `vite/client`, etc.).
293
+ - `babel-plugin-tsconfig-paths` removed — it was a no-op in every package that
294
+ listed it.
295
+ - `noUncheckedIndexedAccess` enabled — violations were few enough to fix in
296
+ source.
155
297
 
156
298
  ### ESLint 8 → 9 (flat config)
157
-
158
- - `@typescript-eslint/parser` and `@typescript-eslint/eslint-plugin` (v5) removed; replaced by the unified `typescript-eslint` v8 package.
299
+ - `@typescript-eslint/parser` and `@typescript-eslint/eslint-plugin` (v5)
300
+ removed; replaced by the unified `typescript-eslint` v8 package.
159
301
  - `eslint-config-preact` bumped to `^2.0.0` (ESLint 9 support).
160
302
  - `eslint-config-prettier` bumped to `^10.0.0`.
161
- - `eslint-plugin-mdx` bumped to `^3.8.1`. **ESLint 10 is not supported** — `eslint-plugin-mdx` vendors an internal ESLint API removed in v10; ESLint 9 is pinned until a fix is released.
303
+ - `eslint-plugin-mdx` bumped to `^3.8.1`. **ESLint 10 is not supported** —
304
+ `eslint-plugin-mdx` vendors an internal ESLint API removed in v10; ESLint 9
305
+ is pinned until a fix is released.
162
306
  - `globals` added (`^15.0.0`) for `languageOptions.globals` in flat config.
163
- - Shared config (`packages/elsie/config/eslint.mjs`) rewritten as a flat-config array export.
164
- - Per-package `.eslintrc.js` files deleted; replaced with `eslint.config.js` (ESM flat config).
165
- - Several `typescript-eslint` v8 rules disabled to preserve prior behavior: `no-explicit-any`, `ban-ts-comment`, `no-unused-expressions`, `no-unsafe-function-type`, `no-require-imports`, `no-empty-object-type`. Tracked as tech debt.
166
- - `reportUnusedDisableDirectives` disabled to avoid sweeping pre-existing inline disable comments.
307
+ - Shared config (`packages/elsie/config/eslint.mjs`) rewritten as a
308
+ flat-config array export.
309
+ - Per-package `.eslintrc.js` files deleted; replaced with `eslint.config.js`
310
+ (ESM flat config).
311
+ - Several `typescript-eslint` v8 rules disabled to preserve prior behavior:
312
+ `no-explicit-any`, `ban-ts-comment`, `no-unused-expressions`,
313
+ `no-unsafe-function-type`, `no-require-imports`, `no-empty-object-type`.
314
+ Tracked as tech debt.
315
+ - `reportUnusedDisableDirectives` disabled to avoid sweeping pre-existing
316
+ inline disable comments.
167
317
 
168
318
  ### `vite-plugin-dts` removed; replaced with custom `dtsPlugin`
169
319
 
170
- `vite-plugin-dts@3.9.1` declared a `typescript <5.0` peer range and its v5 successor was incompatible with this monorepo's layout (cross-package sources, workspace symlinks, multi-`outDir`). It was removed and replaced with a thin custom Vite plugin at `packages/elsie/config/plugins/dts.mjs` (`dtsPlugin`) that runs `tsc` directly. The resulting `dist/` layout is identical to what v3.9 produced (147 `.d.ts` files, 12 top-level entry shims).
320
+ `vite-plugin-dts@3.9.1` declared a `typescript <5.0` peer range and its v5
321
+ successor was incompatible with this monorepo's layout (cross-package sources,
322
+ workspace symlinks, multi-`outDir`). It was removed and replaced with a thin
323
+ custom Vite plugin at `packages/elsie/config/plugins/dts.mjs` (`dtsPlugin`)
324
+ that runs `tsc` directly. The resulting `dist/` layout is identical to what
325
+ v3.9 produced (147 `.d.ts` files, 12 top-level entry shims).
171
326
 
172
327
  ### Module format standardization
173
328
 
174
329
  All tooling config files now follow a consistent format:
175
330
 
176
- - **ESLint / Jest / Vite configs** — ESM (`.js` in `"type":"module"` packages; `.mjs` in elsie).
177
- - **Prettier** — JSON only (`@adobe-commerce/elsie/config/prettier.json` referenced via each package's `"prettier"` key). `prettier.config.*` files deleted from all packages.
331
+ - **ESLint / Jest / Vite configs** — ESM (`.js` in `"type":"module"` packages;
332
+ `.mjs` in elsie).
333
+ - **Prettier** — JSON only (`@adobe-commerce/elsie/config/prettier.json`
334
+ referenced via each package's `"prettier"` key). `prettier.config.*` files
335
+ deleted from all packages.
178
336
  - **elsie CLI** (`bin/**`) — intentionally stays CommonJS.
179
337
 
180
338
  See `architecture/decisions/009-module-format.md` for the full convention.
181
339
 
182
340
  ### `.elsie.js` → `.elsie.cjs`
183
341
 
184
- The consumer project config file is renamed from `.elsie.js` to `.elsie.cjs`. With `"type":"module"` now required in consumer packages, a plain `.js` file is treated as ES module — making `module.exports` a SyntaxError and making `require()` in the elsie CLI fail with `ERR_REQUIRE_ESM`. The `.cjs` extension forces CommonJS regardless of the package's `"type"` field.
342
+ The consumer project config file is renamed from `.elsie.js` to `.elsie.cjs`.
343
+ With `"type":"module"` now required in consumer packages, a plain `.js` file
344
+ is treated as ES module — making `module.exports` a SyntaxError and making
345
+ `require()` in the elsie CLI fail with `ERR_REQUIRE_ESM`. The `.cjs` extension
346
+ forces CommonJS regardless of the package's `"type"` field.
185
347
 
186
348
  - `elsie generate config` now writes `.elsie.cjs`.
187
- - The CLI (`bin/lib/config.js`) and `config/vite.mjs` both prefer `.elsie.cjs` and fall back to `.elsie.js` for packages not yet migrated.
349
+ - The CLI (`bin/lib/config.js`) and `config/vite.mjs` both prefer `.elsie.cjs`
350
+ and fall back to `.elsie.js` for packages not yet migrated.
188
351
  - `.elsie.cjs` added to `.npmignore` in all consumer packages.
189
352
 
190
353
  ## Consumer migration
@@ -192,20 +355,29 @@
192
355
  See `docs/elsie-v2-migration.md` for the full step-by-step guide. Key actions:
193
356
 
194
357
  1. Add `"type": "module"` to `package.json`.
195
- 2. Replace `.eslintrc.js` with `eslint.config.js` (ESM flat config importing from `@adobe-commerce/elsie/config/eslint.mjs`).
358
+ 2. Replace `.eslintrc.js` with `eslint.config.js` (ESM flat config importing
359
+ from `@adobe-commerce/elsie/config/eslint.mjs`).
196
360
  3. Rename `.elsie.js` → `.elsie.cjs` (keep `module.exports` content as-is).
197
- 4. Add `"prettier": "@adobe-commerce/elsie/config/prettier.json"` to `package.json`; delete `prettier.config.js`.
198
- 5. Update `tsconfig.json`: remove `baseUrl`, add explicit `rootDir` and `types`.
361
+ 4. Add `"prettier": "@adobe-commerce/elsie/config/prettier.json"` to
362
+ `package.json`; delete `prettier.config.js`.
363
+ 5. Update `tsconfig.json`: remove `baseUrl`, add explicit `rootDir` and
364
+ `types`.
199
365
  6. Add `tsconfig.build.json` for declaration emit (required by `dtsPlugin`).
200
- 7. Convert `.elsie.js` imports in `.storybook/main.js` and `storybook-stories.js` to reference `.elsie.cjs`.
366
+ 7. Convert `.elsie.js` imports in `.storybook/main.js` and
367
+ `storybook-stories.js` to reference `.elsie.cjs`.
201
368
 
202
369
  ### Minor Changes
203
370
 
204
371
  - c21a378: Add optional `cypress` export to shared ESLint config
205
372
 
206
- `cypress` is a new named export from `@adobe-commerce/elsie/config/eslint.mjs` that provides a pre-configured ESLint flat config for Cypress test files (`cypress/**/*.js`). It applies `eslint-plugin-cypress`'s recommended rules with `jest/expect-expect` turned off.
373
+ `cypress` is a new named export from `@adobe-commerce/elsie/config/eslint.mjs`
374
+ that provides a pre-configured ESLint flat config for Cypress test files
375
+ (`cypress/**/*.js`). It applies `eslint-plugin-cypress`'s recommended rules
376
+ with `jest/expect-expect` turned off.
207
377
 
208
- The plugin is declared as an optional peer dependency — `cypress` resolves to an empty array when `eslint-plugin-cypress` is not installed, so projects that don't use Cypress are unaffected.
378
+ The plugin is declared as an optional peer dependency — `cypress` resolves to
379
+ an empty array when `eslint-plugin-cypress` is not installed, so projects that
380
+ don't use Cypress are unaffected.
209
381
 
210
382
  ## Usage
211
383
 
@@ -226,34 +398,93 @@
226
398
  export default [...base, ...cypress, ...sourceImportRestrictions];
227
399
  ```
228
400
 
229
- - 9d558ed: Adds `window.DROPINS.showOverlays(state)` — a developer utility that visually outlines all dropin containers and slots on the page with labeled overlays, making it easier to understand how the storefront is composed at runtime.
401
+ - 9d558ed: Adds `window.DROPINS.showOverlays(state)` — a developer utility that
402
+ visually outlines all dropin containers and slots on the page with labeled
403
+ overlays, making it easier to understand how the storefront is composed at
404
+ runtime.
230
405
 
231
- `DROPINS.showSlots()` is deprecated in favor of `showOverlays()` and will log a console warning when called.
406
+ `DROPINS.showSlots()` is deprecated in favor of `showOverlays()` and will log
407
+ a console warning when called.
232
408
 
233
409
  - c25a5d7: feat(elsie): add `changeset` builder command
234
410
 
235
- Adds `elsie changeset` as a first-class CLI command, wrapping `@changesets/cli`. All subcommands pass through transparently (`status`, `version`, `publish`, `--snapshot`, etc.). `@changesets/cli` is now a dependency of elsie, so consumers no longer need to install it separately.
411
+ Adds `elsie changeset` as a first-class CLI command, wrapping
412
+ `@changesets/cli`. All subcommands pass through transparently (`status`,
413
+ `version`, `publish`, `--snapshot`, etc.). `@changesets/cli` is now a
414
+ dependency of elsie, so consumers no longer need to install it separately.
236
415
 
237
- - 005edc7: Adds validation to the Incrementer component when the field is changed to "empty".
416
+ - 005edc7: Adds validation to the Incrementer component when the field is
417
+ changed to "empty".
238
418
 
239
419
  ### Patch Changes
240
420
 
241
- - bf352d2: Fix InputDate showing wrong format after selecting a date from the calendar
242
- - 4c3d82d: fix(field): associate error messages with inputs via aria-describedby (WCAG 3.3.1)
243
- - 36354d9: Add disableWhenSingle prop to Picker; defaults to true (preserves existing behavior). Pass false to keep the picker interactive when only one option is available.
244
- - 09c2100: Declare `preact` as a runtime dependency. It previously sat in `devDependencies` (unlike `@preact/signals` and `preact-i18n`), so standalone consumers of `@adobe-commerce/elsie` had an unmet `preact` — also the unmet peer of `@preact/preset-vite`, `@storybook/preact-vite` and `@testing-library/preact`. It now resolves to the same `~10.22.1` bundled into `@dropins/tools`. The emitted bundle is unchanged.
245
- - 4641ab0: Fix `Field` and `InLineAlert` status/error messages not being announced by screen readers. `Field`'s description/hint element now always carries `role="status"` and `aria-live="polite"`, instead of only adding `aria-live` once an error appeared, so assistive technology reliably announces validation and success messages (WCAG 4.1.3). `InLineAlert` now sets `role="alert"`/`aria-live="assertive"` for `type="error"` and `role="status"`/`aria-live="polite"` for `success`/`warning`, since it previously had no live-region semantics at all.
246
- - ccada8c: Reset default margin on Header and CartItem titles to support rendering them as semantic headings
247
- - cb6eb81: Fix `InLineAlert` additional-action buttons announcing the same accessible name across multiple alerts. Each entry in `additionalActions` may now include an optional `'aria-label'` that is applied to the rendered button (falling back to `label` when omitted), so consumers can give visually identical "Undo"/"Dismiss" style buttons unique, descriptive names for assistive technology.
248
- - ab5cf32: Fix `Modal` accessibility: the dialog now exposes `role="dialog"`, `aria-modal="true"`, and an `aria-labelledby` linked to its title. Focus moves into the modal when it opens (falling back to the dialog body when there are no focusable elements), Tab/Shift+Tab now cycles between the first and last focusable elements instead of escaping the modal, and focus returns to the previously focused element when the modal closes.
249
- - 58da630: Fix `Picker` accessible name and label association. The `<select>` now falls back to `floatingLabel` or `placeholder` for its `aria-label` when no `name` is provided, and the floating `<label>` is now correctly associated with the rendered `<select>` via its generated id instead of the raw `id` prop.
250
- - 450c408: fix(Picker): auto-select and emit the sole option when the control auto-disables, so single-option narrowing on configurable PDPs no longer leaves the value unselected and Add to Cart permanently disabled
251
- - 33ebe8a: Add accessible labels to password validation and input status icons (WCAG 1.1.1)
252
- - 2ad7316: Fix `ToggleButton`'s underlying radio input announcing the shared radio-group `name` (e.g. "payment-method") as its accessible name for every option instead of the option's own visible label, which violates WCAG 2.4.6 (Headings and Labels) and 2.5.3 (Label in Name). The radio input's accessible name now defaults to `aria-labelledby` pointing at the option's own visible label content (e.g. "Check / Money order"), which works correctly whether `label` is a string or a `VNode`. An optional `ariaLabel` prop is still available for consumers who need to set an explicit accessible name via `aria-label` instead.
253
- - 016a558: Fix low-contrast field label text in `Input` when a field is in an error state. The floating label color now meets WCAG AA contrast requirements for normal-size text against light backgrounds, matching the color already used for error text elsewhere (helper text, alerts).
254
- - 51fcb35: fix(a11y): darken low-contrast focus indicators to meet WCAG 1.4.11 (3:1 non-text contrast)
255
-
256
- The default keyboard focus indicator across Button, IconButton, Checkbox, RadioButton, ActionButton, ActionButtonGroup, ToggleButton, TextSwatch, ColorSwatch, ImageSwatch, and links used `--color-neutral-400` (#d6d6d6, ~1.45:1 against white), below the 3:1 minimum required by WCAG 1.4.11. These focus indicators now use `--color-neutral-600` (#8f8f8f, ~3.2:1), so keyboard users can reliably see which control is focused.
421
+ - bf352d2: Fix InputDate showing wrong format after selecting a date from the
422
+ calendar
423
+ - 4c3d82d: fix(field): associate error messages with inputs via aria-describedby
424
+ (WCAG 3.3.1)
425
+ - 36354d9: Add disableWhenSingle prop to Picker; defaults to true (preserves
426
+ existing behavior). Pass false to keep the picker interactive when only one
427
+ option is available.
428
+ - 09c2100: Declare `preact` as a runtime dependency. It previously sat in
429
+ `devDependencies` (unlike `@preact/signals` and `preact-i18n`), so standalone
430
+ consumers of `@adobe-commerce/elsie` had an unmet `preact` — also the unmet
431
+ peer of `@preact/preset-vite`, `@storybook/preact-vite` and
432
+ `@testing-library/preact`. It now resolves to the same `~10.22.1` bundled into
433
+ `@dropins/tools`. The emitted bundle is unchanged.
434
+ - 4641ab0: Fix `Field` and `InLineAlert` status/error messages not being
435
+ announced by screen readers. `Field`'s description/hint element now always
436
+ carries `role="status"` and `aria-live="polite"`, instead of only adding
437
+ `aria-live` once an error appeared, so assistive technology reliably announces
438
+ validation and success messages (WCAG 4.1.3). `InLineAlert` now sets
439
+ `role="alert"`/`aria-live="assertive"` for `type="error"` and
440
+ `role="status"`/`aria-live="polite"` for `success`/`warning`, since it
441
+ previously had no live-region semantics at all.
442
+ - ccada8c: Reset default margin on Header and CartItem titles to support
443
+ rendering them as semantic headings
444
+ - cb6eb81: Fix `InLineAlert` additional-action buttons announcing the same
445
+ accessible name across multiple alerts. Each entry in `additionalActions` may
446
+ now include an optional `'aria-label'` that is applied to the rendered button
447
+ (falling back to `label` when omitted), so consumers can give visually
448
+ identical "Undo"/"Dismiss" style buttons unique, descriptive names for
449
+ assistive technology.
450
+ - ab5cf32: Fix `Modal` accessibility: the dialog now exposes `role="dialog"`,
451
+ `aria-modal="true"`, and an `aria-labelledby` linked to its title. Focus moves
452
+ into the modal when it opens (falling back to the dialog body when there are
453
+ no focusable elements), Tab/Shift+Tab now cycles between the first and last
454
+ focusable elements instead of escaping the modal, and focus returns to the
455
+ previously focused element when the modal closes.
456
+ - 58da630: Fix `Picker` accessible name and label association. The `<select>`
457
+ now falls back to `floatingLabel` or `placeholder` for its `aria-label` when
458
+ no `name` is provided, and the floating `<label>` is now correctly associated
459
+ with the rendered `<select>` via its generated id instead of the raw `id`
460
+ prop.
461
+ - 450c408: fix(Picker): auto-select and emit the sole option when the control
462
+ auto-disables, so single-option narrowing on configurable PDPs no longer
463
+ leaves the value unselected and Add to Cart permanently disabled
464
+ - 33ebe8a: Add accessible labels to password validation and input status icons
465
+ (WCAG 1.1.1)
466
+ - 2ad7316: Fix `ToggleButton`'s underlying radio input announcing the shared
467
+ radio-group `name` (e.g. "payment-method") as its accessible name for every
468
+ option instead of the option's own visible label, which violates WCAG 2.4.6
469
+ (Headings and Labels) and 2.5.3 (Label in Name). The radio input's accessible
470
+ name now defaults to `aria-labelledby` pointing at the option's own visible
471
+ label content (e.g. "Check / Money order"), which works correctly whether
472
+ `label` is a string or a `VNode`. An optional `ariaLabel` prop is still
473
+ available for consumers who need to set an explicit accessible name via
474
+ `aria-label` instead.
475
+ - 016a558: Fix low-contrast field label text in `Input` when a field is in an
476
+ error state. The floating label color now meets WCAG AA contrast requirements
477
+ for normal-size text against light backgrounds, matching the color already
478
+ used for error text elsewhere (helper text, alerts).
479
+ - 51fcb35: fix(a11y): darken low-contrast focus indicators to meet WCAG 1.4.11
480
+ (3:1 non-text contrast)
481
+
482
+ The default keyboard focus indicator across Button, IconButton, Checkbox,
483
+ RadioButton, ActionButton, ActionButtonGroup, ToggleButton, TextSwatch,
484
+ ColorSwatch, ImageSwatch, and links used `--color-neutral-400` (#d6d6d6,
485
+ ~1.45:1 against white), below the 3:1 minimum required by WCAG 1.4.11. These
486
+ focus indicators now use `--color-neutral-600` (#8f8f8f, ~3.2:1), so keyboard
487
+ users can reliably see which control is focused.
257
488
 
258
489
  ## 1.9.0
259
490
 
@@ -261,28 +492,59 @@
261
492
 
262
493
  - af62897: Update minimum Node.js requirement to 22 LTS
263
494
 
264
- Packages are now built with Node.js 22. `elsie` requires `>=22`; browser-only packages (`fetch-graphql`, `event-bus`, `recaptcha`, `storefront-design`, `build-tools`) do not declare an `engines` field as they do not run in Node.js.
495
+ Packages are now built with Node.js 22. `elsie` requires `>=22`; browser-only
496
+ packages (`fetch-graphql`, `event-bus`, `recaptcha`, `storefront-design`,
497
+ `build-tools`) do not declare an `engines` field as they do not run in
498
+ Node.js.
265
499
 
266
- - 62adf1c: Reduce HTTP requests on page load through three bundling optimizations. The preact runtime is isolated in its own vendor chunk so it no longer co-locates into other chunks. Dropin API and internal component modules are consolidated into `chunks/api.js` and `chunks/components.js` respectively, replacing the previous pattern of one chunk file per function or component. All SVG icons are consolidated into a single `chunks/icons.js` chunk instead of one chunk per icon.
500
+ - 62adf1c: Reduce HTTP requests on page load through three bundling
501
+ optimizations. The preact runtime is isolated in its own vendor chunk so it no
502
+ longer co-locates into other chunks. Dropin API and internal component modules
503
+ are consolidated into `chunks/api.js` and `chunks/components.js` respectively,
504
+ replacing the previous pattern of one chunk file per function or component.
505
+ All SVG icons are consolidated into a single `chunks/icons.js` chunk instead
506
+ of one chunk per icon.
267
507
 
268
- Drop-ins must be rebuilt against this release to get the reduced request footprint. No source changes are required.
508
+ Drop-ins must be rebuilt against this release to get the reduced request
509
+ footprint. No source changes are required.
269
510
 
270
511
  ### Patch Changes
271
512
 
272
- - d2aacc7: Fix: GraphQL fragment source files are no longer incorrectly bundled into `chunks/api.js`. The `manualChunks` function now walks the full importer graph (with cycle protection) to determine whether an api-directory module is owned by the fragments barrel, so fragment files stay in the fragments output chunk even when accessed through intermediate sub-barrels.
273
- - 5c64620: Implement a new `fragment-import-redirect` build plugin that automatically detects and redirects any dropin source file that directly imports a fragment source file (bypassing the barrel). The import is silently redirected to the fragments barrel at build time and a warning is emitted identifying the file so it can be corrected in source. This ensures fragment constants always appear as local declarations in `fragments.js` regardless of how dropin source code references them.
513
+ - d2aacc7: Fix: GraphQL fragment source files are no longer incorrectly bundled
514
+ into `chunks/api.js`. The `manualChunks` function now walks the full importer
515
+ graph (with cycle protection) to determine whether an api-directory module is
516
+ owned by the fragments barrel, so fragment files stay in the fragments output
517
+ chunk even when accessed through intermediate sub-barrels.
518
+ - 5c64620: Implement a new `fragment-import-redirect` build plugin that
519
+ automatically detects and redirects any dropin source file that directly
520
+ imports a fragment source file (bypassing the barrel). The import is silently
521
+ redirected to the fragments barrel at build time and a warning is emitted
522
+ identifying the file so it can be corrected in source. This ensures fragment
523
+ constants always appear as local declarations in `fragments.js` regardless of
524
+ how dropin source code references them.
274
525
 
275
526
  ## 1.9.0-beta.3
276
527
 
277
528
  ### Patch Changes
278
529
 
279
- - 5c64620: Implement a new `fragment-import-redirect` build plugin that automatically detects and redirects any dropin source file that directly imports a fragment source file (bypassing the barrel). The import is silently redirected to the fragments barrel at build time and a warning is emitted identifying the file so it can be corrected in source. This ensures fragment constants always appear as local declarations in `fragments.js` regardless of how dropin source code references them.
530
+ - 5c64620: Implement a new `fragment-import-redirect` build plugin that
531
+ automatically detects and redirects any dropin source file that directly
532
+ imports a fragment source file (bypassing the barrel). The import is silently
533
+ redirected to the fragments barrel at build time and a warning is emitted
534
+ identifying the file so it can be corrected in source. This ensures fragment
535
+ constants always appear as local declarations in `fragments.js` regardless of
536
+ how dropin source code references them.
280
537
 
281
538
  ## 1.9.0-beta.2
282
539
 
283
540
  ### Patch Changes
284
541
 
285
- - d2aacc7: Fix: GraphQL fragment source files are no longer incorrectly bundled into `chunks/api.js`. The `manualChunks` function now walks the full importer graph (with cycle protection) to determine whether an api-directory module is owned by the fragments barrel, so fragment files stay in the fragments output chunk even when accessed through intermediate sub-barrels. Boilerplate GraphQL overrides work correctly in all dropin barrel structures.
542
+ - d2aacc7: Fix: GraphQL fragment source files are no longer incorrectly bundled
543
+ into `chunks/api.js`. The `manualChunks` function now walks the full importer
544
+ graph (with cycle protection) to determine whether an api-directory module is
545
+ owned by the fragments barrel, so fragment files stay in the fragments output
546
+ chunk even when accessed through intermediate sub-barrels. Boilerplate GraphQL
547
+ overrides work correctly in all dropin barrel structures.
286
548
 
287
549
  ## 1.9.0-beta.1
288
550
 
@@ -290,35 +552,53 @@
290
552
 
291
553
  - af62897: Update minimum Node.js requirement to 22 LTS
292
554
 
293
- Packages are now built with Node.js 22. `elsie` requires `>=22`; browser-only packages (`fetch-graphql`, `event-bus`, `recaptcha`, `storefront-design`, `build-tools`) do not declare an `engines` field as they do not run in Node.js.
555
+ Packages are now built with Node.js 22. `elsie` requires `>=22`; browser-only
556
+ packages (`fetch-graphql`, `event-bus`, `recaptcha`, `storefront-design`,
557
+ `build-tools`) do not declare an `engines` field as they do not run in
558
+ Node.js.
294
559
 
295
560
  ## 1.9.0-beta.0
296
561
 
297
562
  ### Minor Changes
298
563
 
299
- - 62adf1c: Reduce HTTP requests on page load through three bundling optimizations. The preact runtime is isolated in its own vendor chunk so it no longer co-locates into other chunks. Dropin API and internal component modules are consolidated into `chunks/api.js` and `chunks/components.js` respectively, replacing the previous pattern of one chunk file per function or component. All SVG icons are consolidated into a single `chunks/icons.js` chunk instead of one chunk per icon.
564
+ - 62adf1c: Reduce HTTP requests on page load through three bundling
565
+ optimizations. The preact runtime is isolated in its own vendor chunk so it no
566
+ longer co-locates into other chunks. Dropin API and internal component modules
567
+ are consolidated into `chunks/api.js` and `chunks/components.js` respectively,
568
+ replacing the previous pattern of one chunk file per function or component.
569
+ All SVG icons are consolidated into a single `chunks/icons.js` chunk instead
570
+ of one chunk per icon.
300
571
 
301
- Drop-ins must be rebuilt against this release to get the reduced request footprint. No source changes are required.
572
+ Drop-ins must be rebuilt against this release to get the reduced request
573
+ footprint. No source changes are required.
302
574
 
303
575
  ## 1.8.1
304
576
 
305
577
  ### Patch Changes
306
578
 
307
- - e44f618: Fixed `srcset w` descriptors to use actual image widths instead of viewport breakpoints, preventing blurry product images.
308
- - 46d57ca: Add optional `sizes` prop to the `Image` component so dropins can provide layout-aware sizing hints for more accurate srcset image source selection.
579
+ - e44f618: Fixed `srcset w` descriptors to use actual image widths instead of
580
+ viewport breakpoints, preventing blurry product images.
581
+ - 46d57ca: Add optional `sizes` prop to the `Image` component so dropins can
582
+ provide layout-aware sizing hints for more accurate srcset image source
583
+ selection.
309
584
 
310
585
  ## 1.8.1-beta.0
311
586
 
312
587
  ### Patch Changes
313
588
 
314
- - e44f618: Fixed `srcset w` descriptors to use actual image widths instead of viewport breakpoints, preventing blurry product images.
315
- - 46d57ca: Add optional `sizes` prop to the `Image` component so dropins can provide layout-aware sizing hints for more accurate srcset image source selection.
589
+ - e44f618: Fixed `srcset w` descriptors to use actual image widths instead of
590
+ viewport breakpoints, preventing blurry product images.
591
+ - 46d57ca: Add optional `sizes` prop to the `Image` component so dropins can
592
+ provide layout-aware sizing hints for more accurate srcset image source
593
+ selection.
316
594
 
317
595
  ## 1.8.0
318
596
 
319
597
  ### Minor Changes
320
598
 
321
- - c4da094: Enhance the Vite build process to automatically generate a package.json file and include both the LICENSE and CHANGELOG files in the dist directory.
599
+ - c4da094: Enhance the Vite build process to automatically generate a
600
+ package.json file and include both the LICENSE and CHANGELOG files in the dist
601
+ directory.
322
602
 
323
603
  ### Patch Changes
324
604
 
@@ -334,4 +614,6 @@
334
614
 
335
615
  ### Minor Changes
336
616
 
337
- - c4da094: Enhance the Vite build process to automatically generate a package.json file and include both the LICENSE and CHANGELOG files in the dist directory.
617
+ - c4da094: Enhance the Vite build process to automatically generate a
618
+ package.json file and include both the LICENSE and CHANGELOG files in the dist
619
+ directory.