@adobe-commerce/elsie 3.0.0-beta.0 → 3.0.0

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 (2) hide show
  1. package/CHANGELOG.md +482 -0
  2. package/package.json +5 -5
package/CHANGELOG.md CHANGED
@@ -1,5 +1,487 @@
1
1
  # @adobe-commerce/elsie
2
2
 
3
+ ## 3.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - 9859213: Consolidate Tools' shared internal helpers into one chunk and combine
8
+ Preact compat, hooks, and JSX runtime exports in `preact-bundle.js` to reduce
9
+ JavaScript requests. Preact core remains a separate entry to preserve its
10
+ export semantics.
11
+
12
+ The public `@dropins/tools/preact-compat.js`,
13
+ `@dropins/tools/preact-hooks.js`, and `@dropins/tools/preact-jsx-runtime.js`
14
+ entries retain their original APIs. These compatibility entries and the
15
+ consolidated bundle share one Preact runtime.
16
+
17
+ Upgrade Tools first, then rebuild and upgrade drop-ins individually with the
18
+ updated Elsie import mappings. Old and new drop-ins can coexist with the
19
+ updated Tools; new drop-ins require a Tools version that provides
20
+ `preact-bundle.js`. Source imports and boilerplate block imports remain
21
+ unchanged. Existing preloads remain valid; update them to the consolidated
22
+ entry as drop-ins are migrated. Unused compatibility entries do not add
23
+ requests for fully migrated consumers.
24
+
25
+ - 3313516: feat(elsie)!: restructure the toolchain (Elsie 3) — breaking
26
+
27
+ The CLI, shared configs, and test-kit have been reorganized.
28
+ `@dropins/tools`'s runtime bundle (components, build tools, and the re-exposed
29
+ `event-bus` / `fetch-graphql`) is unaffected — these changes only impact repos
30
+ that consume `@adobe-commerce/elsie` as their **development toolchain** (the
31
+ drop-in package repos).
32
+
33
+ Migration checklist for consuming repos:
34
+
35
+ 1. **Config source.** Elsie no longer reads `.elsie.cjs` / `.elsie.js`. Move
36
+ your configuration into the `"elsie"` key of `package.json`.
37
+
38
+ 2. **`elsie types` removed.** Replace any `"type-check": "elsie types"` script
39
+ with a direct `tsc --noEmit` (or your project's equivalent). Note the old
40
+ command now no longer exists — audit scripts that relied on it, since a
41
+ stale reference will fail rather than silently pass.
42
+
43
+ 3. **`config/` → `configs/` (plural) relocation.** Update references:
44
+ - tsconfig `extends`: `@adobe-commerce/elsie/config/tsconfig-base.json` →
45
+ `@adobe-commerce/elsie/configs/tsconfig/base.json` (and
46
+ `tsconfig-preact.json` → `configs/tsconfig/preact.json`).
47
+ - Prettier: `@adobe-commerce/elsie/config/prettier.json` →
48
+ `@adobe-commerce/elsie/configs/prettier.js`.
49
+ - Jest / ESLint / Vite: `config/jest.mjs`, `config/eslint.mjs`,
50
+ `config/vite.mjs` → `configs/jest.js`, `configs/eslint.js`,
51
+ `configs/vite.js`.
52
+
53
+ 4. **Test-kit import path.** `@adobe-commerce/elsie/lib/tests` →
54
+ `@adobe-commerce/elsie/tests` (and `@adobe-commerce/elsie/tests/dom` for
55
+ component tests). See the test-kit changeset for the full ambient-globals
56
+ migration.
57
+
58
+ 5. **Shared tsconfig dropped ambient Jest types.** Repos extending the base
59
+ tsconfig should import the jest API from `@adobe-commerce/elsie/tests`
60
+ (backed by `@jest/globals`) and drop `@types/jest` / `types: ["jest"]`.
61
+
62
+ 6. **ESLint config factory replaced.** The `createConfig` /`browser`/`node`
63
+ exports of `@adobe-commerce/elsie/configs/eslint.js` are gone. Compose your
64
+ flat config from the building blocks instead:
65
+
66
+ ```js
67
+ import {
68
+ defineConfig,
69
+ globals,
70
+ typescript,
71
+ tests,
72
+ preact,
73
+ storybook,
74
+ } from '@adobe-commerce/elsie/configs/eslint.js';
75
+
76
+ // was: createConfig({ runtime: 'browser' })
77
+ export default defineConfig(globals('browser'), typescript(), tests());
78
+ ```
79
+
80
+ `defineConfig(...layers)` keeps the shared base first and prettier last;
81
+ `globals(env, files)` scopes environment globals; presets and
82
+ `runtime: 'agnostic'` (omit `globals`) map over directly. One config can
83
+ now scope different folders to different runtimes via each layer's `files`.
84
+
85
+ 7. **Jest config factory renamed.** `@adobe-commerce/elsie/configs/jest.js`
86
+ now exports `defineConfig` (was `createConfig`), matching the ESLint entry.
87
+ Update your `jest.config.js` imports accordingly; the options are
88
+ unchanged.
89
+
90
+ 8. **`restrictions` moved under the ESLint presets, its own export subpath
91
+ dropped.** `@adobe-commerce/elsie/configs/eslint/restrictions.js` no longer
92
+ exists; `restrictions` is now exported from
93
+ `@adobe-commerce/elsie/configs/eslint.js` like the other presets:
94
+
95
+ ```js
96
+ import {
97
+ defineConfig,
98
+ typescript,
99
+ restrictions,
100
+ } from '@adobe-commerce/elsie/configs/eslint.js';
101
+
102
+ // was: import { restrictions } from '@adobe-commerce/elsie/configs/eslint/restrictions.js';
103
+ export default defineConfig(typescript(), restrictions());
104
+ ```
105
+
106
+ ### Minor Changes
107
+
108
+ - dc26db1: Allow consumers to pass axe-playwright `checkA11y` option overrides
109
+ when creating the shared Storybook accessibility test runner config.
110
+ - 3313516: feat(elsie): add `clean` and `format` builders
111
+
112
+ - New `elsie clean [paths...]` command (wraps rimraf, defaults to `dist`).
113
+ - New `elsie format [paths...]` command (wraps Prettier; `--check` verifies
114
+ instead of writing; defaults to the current directory).
115
+
116
+ As a result, `@dropins/build-tools` drops its `rimraf` and `vite`
117
+ devDependencies, and `@adobe-commerce/storefront-design` drops `rimraf`; both
118
+ now use `elsie clean` for their cleanup step.
119
+
120
+ - 697d1bc: Allow the Cypress ESLint preset to accept a `rules` option for scoped
121
+ rule additions and overrides while retaining unspecified recommended rules.
122
+ - 3c1f65f: Add an opt-in `cypress()` ESLint preset with Cypress's recommended
123
+ rules and globals scoped to JavaScript and TypeScript files under `cypress/`,
124
+ with a customizable `files` option. Bundle `eslint-plugin-cypress` so
125
+ consumers can use the preset without installing the plugin themselves.
126
+ - 3c1f65f: Allow the ESLint `globals()` helper to accept an array of
127
+ environments sharing one optional file scope, such as
128
+ `globals(['browser', 'node'])`. Merge globals in array order while preserving
129
+ existing single-environment calls.
130
+ - c6f21c7: Provide shared MSW handler and Node server APIs through
131
+ `@adobe-commerce/elsie/msw` and `@adobe-commerce/elsie/msw/node`, and
132
+ Storybook integration through `@adobe-commerce/elsie/storybook/msw`. Add
133
+ `elsie msw init` to generate browser workers using Elsie's installed MSW
134
+ version, so consumers can remove their direct MSW and MSW Storybook addon
135
+ dependencies.
136
+ - b58cb76: Provide a shared Storybook main-config factory with the Preact/Vite
137
+ framework and common addons resolved from Elsie. Resolve Storybook preview
138
+ imports from Elsie's dependency tree so isolated consumers can run
139
+ `elsie storybook` and `elsie storybook build` without installing the Storybook
140
+ CLI themselves.
141
+ - 25ba0c5: Share the named `a11yTestRunnerConfig` Storybook configuration
142
+ through `@adobe-commerce/elsie/storybook/test-runner`. Consumers can replace
143
+ their duplicate `.storybook/test-runner.ts` hooks with an import and remove
144
+ direct `@storybook/test-runner` and `axe-playwright` dependencies when no
145
+ other files import them.
146
+ - 3313516: feat(elsie): extend `elsie storybook` with `build` and `test` modes
147
+
148
+ `elsie storybook` only ever ran `storybook dev`; building and testing
149
+ Storybook still meant calling `storybook build` and `test-storybook` bare,
150
+ which resolve their binaries via the shell's inherited `PATH` — the same class
151
+ of bug the CLI's `resolveBin()`-based dispatch (`lint`/`test`/
152
+ `changeset`/`types`) was fixed to avoid.
153
+
154
+ `elsie storybook [mode]` now accepts `dev` (default, unchanged), `build`
155
+ (`elsie storybook build`), and `test` (`elsie storybook test`, resolving
156
+ `@storybook/test-runner`'s `test-storybook` bin). All other arguments keep
157
+ flowing through untouched, so existing invocations are unaffected.
158
+
159
+ `packages/elsie`'s own `build:storybook`, `build:storybook:ci`,
160
+ `test:storybook`, and `test:storybook:ci` scripts now go through this instead
161
+ of calling `storybook build` / `test-storybook` directly.
162
+
163
+ - 25ba0c5: Add `elsie storybook --install-playwright` to install browsers with
164
+ Elsie's Playwright binary without a direct Playwright dependency in consuming
165
+ packages.
166
+ - 25ba0c5: Expose Preact story types, browser play-function helpers, actions,
167
+ and shared decorators through `@adobe-commerce/elsie/storybook/types`,
168
+ `/storybook/tests`, `/storybook/actions`, and `/storybook/decorators`.
169
+ Consumers can remove direct Storybook dependencies after migrating story
170
+ imports. Update generated stories and the migration guide to use these
171
+ subpaths and the Storybook config factory at
172
+ `@adobe-commerce/elsie/storybook/config`.
173
+ - 5bbe0b1: Extend `elsie sync-tools` to scan both `examples/` and `static/` by
174
+ default, including assets used by Storybook and CI. Add `--directories` to
175
+ scan additional directories without replacing the defaults, in both sync and
176
+ `--check` modes.
177
+ - 13776b6: Add `elsie sync-tools` to synchronize example HTML and JavaScript
178
+ `@dropins/tools` URLs with the consumer's installed Elsie version. Use
179
+ `elsie sync-tools --check` to detect version drift in CI without modifying
180
+ files. Unversioned CDN URLs are also pinned to the installed version rather
181
+ than implicitly resolving to `latest`, including for alpha and beta releases.
182
+ - 3313516: feat(elsie): explicit jest imports via an
183
+ `@adobe-commerce/elsie/tests` test-kit
184
+
185
+ Tests now import their jest API explicitly instead of relying on ambient
186
+ `@types/jest` globals, following Jest's recommendation for version-matched
187
+ types (`@jest/globals` ships with jest, `@types/jest` is third-party and can
188
+ drift):
189
+
190
+ The test-kit is split into three tiers, each a superset of the previous, so a
191
+ test imports exactly the machinery it needs:
192
+
193
+ - `@adobe-commerce/elsie/tests` — the base tier. Re-exports the jest API
194
+ surface (`jest`/`describe`/`it`/`test`/`expect` + lifecycle hooks) from
195
+ `@jest/globals` plus the `mockResolvedFn`/`mockRejectedFn` helpers. Pulls in
196
+ no DOM code, so it is safe to import from any package's jest config.
197
+ - `@adobe-commerce/elsie/tests/dom` — the "pure DOM" tier. Adds jest-dom
198
+ assertion matchers (registered against jsdom) for tests that assert on the
199
+ DOM but render no components.
200
+ - `@adobe-commerce/elsie/tests/preact` — the "DOM + preact" tier. Adds
201
+ `@testing-library/preact` and `userEvent` on top of `/tests/dom`, for
202
+ component tests (requires a jest config that resolves packages to their
203
+ node/CJS builds, e.g. via `testEnvironmentOptions.customExportConditions`).
204
+
205
+ The jest `defineConfig` factory mirrors these tiers with a `preset` option
206
+ (replacing the previous `environment: 'node' | 'jsdom'`):
207
+
208
+ - `preset: 'node'` (default) — a node environment, no DOM.
209
+ - `preset: 'dom'` — a jsdom environment with browser-API shims, without the
210
+ preact/compat module aliasing or asset mocks, so packages that only touch
211
+ the DOM no longer pull in preact machinery.
212
+ - `preset: 'preact'` — everything `dom` sets up plus the preact/compat
213
+ aliasing and css/svg asset mocks needed to render preact components.
214
+
215
+ Other notes:
216
+
217
+ - `@jest/globals` and `@testing-library/user-event` are now elsie
218
+ dependencies; the DOM tier includes jest-dom's matcher type augmentation.
219
+ - `@types/jest` is no longer required and `types: ["jest"]` has been dropped
220
+ from the shared tsconfig. Import `jest` from the test-kit in files that use
221
+ its runtime API or mock types. The shared Jest config rewrites named `jest`
222
+ imports before Babel's mock hoisting and resolves Elsie's Jest dependency.
223
+
224
+ Consumers migrating: replace ambient jest globals with imports from
225
+ `@adobe-commerce/elsie/tests` (`/tests/dom` for DOM-only tests,
226
+ `/tests/preact` for component tests), pick the matching `defineConfig`
227
+ `preset`, and drop `@types/jest`.
228
+
229
+ - 3313516: fix(elsie): declare the toolchain as real dependencies so it works
230
+ outside this monorepo
231
+
232
+ `elsie`'s CLI
233
+ (`lint`/`test`/`build`/`serve`/`format`/`clean`/`changeset`/`gql`) and its
234
+ shared configs (`configs/jest.js`, `configs/eslint.js`, `configs/vite.js`, and
235
+ the `@adobe-commerce/elsie/tests`(`/dom`) test-kit) required packages that
236
+ were classified as `devDependencies` — `eslint`, `jest` and its environments,
237
+ `babel-jest` and the Babel presets it needs, `vite` and its plugins,
238
+ `prettier`, `rimraf`, `@changesets/cli`, `@jest/globals`,
239
+ `@testing-library/preact`/`user-event`, and others. `devDependencies` are
240
+ never installed for anyone who depends on `@adobe-commerce/elsie` normally, so
241
+ none of this was actually present for an external consumer's install,
242
+ regardless of package manager or `node_modules` layout — the CLI and shared
243
+ configs only ever worked inside this monorepo (where every workspace package's
244
+ `devDependencies` are installed at the root), contradicting the "batteries
245
+ included, no separate install needed" toolchain this SDK is meant to provide.
246
+
247
+ The packages `tooling/` actually requires at runtime are now real
248
+ `dependencies` — including `graphql-codegen-typescript-mock-data`, which the
249
+ `elsie gql mocks` command loads as a codegen plugin and which is not reachable
250
+ through `@graphql-codegen/cli`'s own dependency subtree. Packages elsie only
251
+ uses to build its own `dist` bundle (the sibling SDK workspace packages,
252
+ `@types/node`, `@chromatic-com/storybook`, etc.) remain `devDependencies`.
253
+ `typescript` is a `peerDependency` instead — see
254
+ `docs/toolchain-peer-dependencies.md`.
255
+
256
+ Verified end-to-end: packed the tarball, installed it into a scratch pnpm
257
+ project with the default (isolated, non-hoisted) `nodeLinker` and zero other
258
+ dependencies, and confirmed `elsie test`/`elsie format` run successfully
259
+ against it — no `nodeLinker: hoisted` workaround needed.
260
+
261
+ - 3313516: feat(elsie): make `typescript` a peer dependency; remove the `types`
262
+ command
263
+
264
+ `typescript` is now an optional `peerDependency` of `@adobe-commerce/elsie`
265
+ instead of a bundled `dependency`. The `dts` Vite plugin (used by
266
+ `elsie build` for `.d.ts` generation) resolves `typescript` from the building
267
+ package's own install rather than elsie's, so declaration output reflects the
268
+ exact compiler version that package's `tsconfig.json`, source, and IDE
269
+ actually use. A package with no `typescript` devDependency of its own gets a
270
+ clear error instead of a silently mismatched build. See
271
+ `docs/toolchain-peer-dependencies.md` for the full rationale.
272
+
273
+ The `elsie types` command (`tsc --noEmit` plus TS6 tsconfig validation) is
274
+ removed — with `typescript` no longer bundled, elsie has no reason to own a
275
+ type-checking command. A package that wants one defines its own script (e.g.
276
+ `"types": "tsc --noEmit"`), using its own installed `typescript`.
277
+
278
+ `build-tools`, `event-bus`, `fetch-graphql`, and `recaptcha` each gain a
279
+ `typescript` devDependency of their own (pinned via `pnpm-workspace.yaml`'s
280
+ `catalog.typescript`) so `.d.ts` generation and any future type-checking
281
+ script keep working now that elsie no longer bundles it.
282
+
283
+ - cdcb0e3: Rename `createConfig()` to `defineConfig()` for the generic Vite
284
+ library base. Move the complete dropin pipeline's default export from
285
+ `configs/vite.js` to `configs/vite/dropin.config.js`. The build and serve CLI
286
+ commands load that bundled config file when `--config` is omitted.
287
+
288
+ Add `withEntries(config, entries)` to extend named bundle inputs while
289
+ preserving generated entries and the rest of the pipeline. It accepts config
290
+ objects, promises, and functions and forwards Vite's config environment.
291
+
292
+ ### Patch Changes
293
+
294
+ - e06c05f: fix(a11y): Checkbox now derives its internal label/description ids
295
+ from the unique `id` prop when provided, instead of the (often shared) `name`
296
+ prop, so two checkboxes with the same `name` no longer produce duplicate DOM
297
+ ids that cause screen readers to announce the wrong checkbox's label (WCAG
298
+ 4.1.2)
299
+ - 3313516: fix(elsie): stop importing preact's private `preact/src/jsx` in
300
+ `classes`
301
+
302
+ `src/lib/classes.ts` imported `JSXInternal` from `preact/src/jsx`, a path
303
+ preact does not expose through its package `exports`. Under modern module
304
+ resolution this fails to resolve, and the specifier leaked into the published
305
+ `@dropins/tools` declarations, breaking standalone TypeScript consumers. The
306
+ small structural signal type is now defined locally instead.
307
+
308
+ - 000433d: Include the default console reporter and `jest-junit` in the shared
309
+ Jest config, with the suite name `Unit Tests` and class name template
310
+ `UnitTests.{classname}`, writing reports to `test-results/junit.xml` under
311
+ Jest's root directory. Resolve the JUnit reporter through Elsie so consumers
312
+ do not need to install it. For multi-project configs, reporters are configured
313
+ at the root and can be overridden through the first config's `reporters`
314
+ option.
315
+ - 59b2754: Fix dropin declaration imports that resolve through `node_modules` so
316
+ they reference the published `@dropins/tools/lib` and
317
+ `@dropins/tools/components` entry points instead of relative filesystem paths.
318
+ - 00d0d9b: fix(elsie): scope TypeScript ESLint parser and rules to JS/TS files
319
+
320
+ Composing `typescript()` and `mdx()` now parses Markdown and MDX correctly in
321
+ either order. Existing TypeScript-only core-rule overrides retain their
322
+ narrower file scope.
323
+
324
+ - 3313516: fix(elsie): publish a deterministic package via a `files` allowlist
325
+
326
+ The package relied on a `.npmignore` denylist that missed `storybook-static`
327
+ (and referenced a stale `vite.config.mjs`), so a pack after a Storybook build
328
+ shipped ~24 MB unpacked and its contents depended on which local build
329
+ commands had run. It now uses a `package.json` `files` allowlist (`tooling`,
330
+ `src`, and docs, minus tests/snapshots/coverage), producing a stable ~1.5 MB
331
+ package.
332
+
333
+ - daf8d7f: fix(elsie): recognize JSX component imports in MDX linting
334
+
335
+ The MDX ESLint preset now counts JSX component tags as usages of their
336
+ imports, while still reporting genuinely unused imports.
337
+
338
+ - de1cba3: Allow an optional `lib` section in the Elsie configuration schema so
339
+ packages with library entry points pass config validation. When present, `lib`
340
+ requires string `root` and `importAliasRoot` fields and rejects unknown
341
+ properties.
342
+ - 25ba0c5: Re-export Storybook Docs blocks from
343
+ `@adobe-commerce/elsie/storybook/blocks` so consumer preview files can use
344
+ `DocsContainer`, `DocsPage`, and other blocks without installing
345
+ `@storybook/addon-docs` directly.
346
+ - 69f5386: Fix Storybook Vite dependency-optimization warnings for pnpm
347
+ consumers by resolving the React DOM shim to its installed file and removing a
348
+ prebundle entry for unpublished static assets.
349
+ - 6c5b573: Remove the ambient Jest declaration from the shared tsconfigs. All
350
+ three test tiers export runtime `jest` and its type namespace for explicit
351
+ imports such as `import { jest } from '@adobe-commerce/elsie/tests'` and
352
+ `jest.Mock<() => Promise<null>>`.
353
+
354
+ The shared Jest config rewrites named Jest imports before mock hoisting and
355
+ resolves `@jest/globals` from Elsie's own dependencies, including with pnpm's
356
+ isolated linker. Consumers must import `jest` wherever they use its runtime
357
+ API or mock types; no consumer-installed Jest dependency is required. Use
358
+ jest-dom's bundled DOM matcher types instead of Elsie's redundant local
359
+ augmentation.
360
+
361
+ Centralize provider-backed component rendering in `/tests/preact`. Its
362
+ `render` loads the consumer's `src/i18n/en_US.json`, supplies `UIProvider` and
363
+ the `.dropin-design` wrapper, and supports language/definition overrides.
364
+ Export the original Testing Library render as `renderPreact`. The legacy
365
+ `/lib/tests` entry point now re-exports this tier so tests can migrate to a
366
+ single public import.
367
+
368
+ - 3313516: fix(elsie): make downgraded import restrictions work for wildcard
369
+ patterns
370
+
371
+ `restrictions()`'s `severityOverrides` built the warning's
372
+ `no-restricted-syntax` selector from an exact `source.value=` match, so
373
+ downgrading a wildcard pattern (e.g. `@adobe-commerce/elsie/src/*`) matched
374
+ nothing. Wildcard groups now emit a regex selector. All downgraded patterns
375
+ are also emitted in a single `no-restricted-syntax` rule, so downgrading more
376
+ than one no longer drops all but the last (flat config replaces, rather than
377
+ merges, repeated rule entries).
378
+
379
+ - 3313516: fix(elsie): fix `transformIgnorePatterns` for pnpm's isolated-linker
380
+ virtual store
381
+
382
+ The shared Jest config factory (`@adobe-commerce/elsie/configs/jest.js`)
383
+ allow-lists elsie and the other `@adobe-commerce/*` packages for
384
+ transformation since they ship untranspiled TS/TSX source. The allow-list
385
+ regex only matched the outer `node_modules/` segment, so under pnpm's default
386
+ (isolated) linker — where a real dependency is nested one level deeper at
387
+ `node_modules/.pnpm/<scope>+<name>@<version>/node_modules/<scope>/<name>/…` —
388
+ the pattern no longer matched and those packages silently stopped being
389
+ transformed, failing every consumer test suite with
390
+ `SyntaxError: Cannot use import statement outside a module`.
391
+
392
+ `transformIgnorePatterns` now includes a second pattern anchored on `.pnpm/`
393
+ so both the flat/hoisted layout (Yarn, npm, `nodeLinker: hoisted`) and pnpm's
394
+ isolated virtual store are handled correctly. Consumers on pnpm's default
395
+ linker no longer need a hand-rolled `transformIgnorePatterns` override or
396
+ `nodeLinker: hoisted` to work around this.
397
+
398
+ - 3313516: fix(elsie): stop `MultiSelect`'s screen-reader announcements from
399
+ looping infinitely while the dropdown is open
400
+
401
+ `preact-i18n`'s `useText()` returns a brand-new translations object on every
402
+ render. Two of `MultiSelect`'s `useEffect`s depended on that whole object and
403
+ each called `announce()` with a different message, so while the dropdown was
404
+ open they kept re-triggering each other — one effect's announcement change
405
+ caused a re-render that fired the other effect, which changed the announcement
406
+ back, forever, synchronously. This produced an unbounded render loop that
407
+ could exhaust the JS heap (observed as Jest OOM crashes in
408
+ `MultiSelect.test.tsx`).
409
+
410
+ Both effects now depend on the specific translation strings they use instead
411
+ of the whole object, and `useAccessibilityAnnouncements` clears its pending
412
+ timeout before scheduling a new one (and on unmount) instead of leaving it
413
+ dangling.
414
+
415
+ - 3313516: fix(elsie): only announce `MultiSelect`'s open message on the open
416
+ transition
417
+
418
+ The effect that announces "Dropdown expanded. N options available" depended on
419
+ the selection and filtered-result counts, so it re-fired on every select and
420
+ search keystroke while the dropdown was open — overwriting the specific
421
+ selection and search-result announcements with the generic open message. It
422
+ now runs only on the closed-to-open transition.
423
+
424
+ - 641d4f5: fix(a11y): Picker's accessible name now prefers the human-readable
425
+ floating label or placeholder over the raw `name` attribute, so screen readers
426
+ announce the same text sighted users see instead of an internal field
427
+ identifier (WCAG 2.5.3)
428
+ - 3313516: chore: migrate build tooling from Yarn to pnpm
429
+
430
+ The monorepo now uses pnpm instead of Yarn v1. As part of this, elsie's CLI
431
+ (`lint`/`test`/`storybook`/`changeset`/`types`) no longer shells out to bare
432
+ command names — each tool is resolved and spawned directly, fixing a latent
433
+ path-with-spaces bug and command-injection surface.
434
+
435
+ `tooling/` (the CLI, and the shared
436
+ eslint/jest/prettier/vite/storybook/tsconfig configs) is now correctly
437
+ included when `@adobe-commerce/elsie` is published — an oversight from merging
438
+ the tooling package back into elsie meant `.npmignore` excluded it, which
439
+ would have shipped a package whose own `bin` and `exports` pointed at files
440
+ that didn't exist in the tarball. This is unrelated to (and does not affect)
441
+ the separate `@dropins/tools` bundle published from `dist/`.
442
+
443
+ - cd72618: Fix an intermittent `insertBefore` `NotFoundError` crash caused by
444
+ `Portal` manually grafting its rendered DOM node into `document.body` (via a
445
+ raw `appendChild` in a `useLayoutEffect`) instead of using Preact's own portal
446
+ primitive.
447
+
448
+ That manual graft moved a Preact-owned DOM node out from under its logical
449
+ parent without informing the reconciler, so the parent's internal DOM
450
+ bookkeeping became stale. Any later update that needed to remove or reposition
451
+ the portalled node relative to a sibling — for example `Modal` closing while a
452
+ sibling in the same parent re-renders, as happens in `storefront-cart`'s
453
+ `GiftOptions` when clicking "Apply" (closing the gift-wrap modal while the
454
+ accordion swaps from its editable form to the read-only summary) — could throw
455
+ `Failed to execute 'insertBefore' on 'Node': The node before which the new node is to be inserted is not a child of this node.`
456
+
457
+ `Portal` now renders its children with `createPortal` (from `preact/compat`)
458
+ into the same lazily-created, `document.body`-appended root element, so
459
+ Preact's reconciler tracks the split between logical parent and DOM container
460
+ itself instead of relying on an untracked DOM move. Timing is unchanged (the
461
+ root is still created during render and attached during `useLayoutEffect`), so
462
+ no consumer-visible behavior changes and no `Slot` or image-swatch code needed
463
+ to change.
464
+
465
+ - 3313516: chore: upgrade vite-tsconfig-paths 4.3.2 → 6.1.1
466
+
467
+ 6.x resolves `${configDir}`-expanded `include` entries correctly, so the
468
+ per-package relative `include` overrides that worked around the 4.x limitation
469
+ are no longer needed. Removed the redundant `["src", "tests"]` overrides (and
470
+ their duplicated comments) from `build-tools`, `event-bus`, `fetch-graphql`,
471
+ and `recaptcha`, which now inherit the base tsconfig's `${configDir}` include.
472
+ `elsie` keeps its `["src"]` include (it deliberately excludes its jest `tests`
473
+ dir); its comment was updated to reflect the real reason rather than the
474
+ obsolete workaround.
475
+
476
+ Also removed the default `@/*` → `${configDir}/src/*` mapping from the base
477
+ tsconfig. Because tsconfig `paths` is replaced wholesale (never merged) when a
478
+ config redeclares it, a base-level default is a footgun: any package that
479
+ needs an extra alias silently loses `@/*`. It is now opt-in — a package that
480
+ wants it declares its own `paths`. No base-extending package in the repo
481
+ relied on it (event-bus already uses relative imports). Preact packages are
482
+ unaffected: the preact config still declares its own `@/*` alongside the
483
+ react→preact aliases.
484
+
3
485
  ## 3.0.0-beta.0
4
486
 
5
487
  ### Major Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adobe-commerce/elsie",
3
- "version": "3.0.0-beta.0",
3
+ "version": "3.0.0",
4
4
  "license": "SEE LICENSE IN LICENSE.md",
5
5
  "description": "Domain Package SDK",
6
6
  "engines": {
@@ -64,10 +64,10 @@
64
64
  "./*": "./*"
65
65
  },
66
66
  "devDependencies": {
67
- "@adobe-commerce/event-bus": "~1.1.2-beta.0",
68
- "@adobe-commerce/fetch-graphql": "~1.3.2-beta.0",
69
- "@adobe-commerce/recaptcha": "1.3.1-beta.0",
70
- "@adobe-commerce/storefront-design": "~1.1.2-beta.0",
67
+ "@adobe-commerce/event-bus": "~1.1.2",
68
+ "@adobe-commerce/fetch-graphql": "~1.3.2",
69
+ "@adobe-commerce/recaptcha": "1.3.1",
70
+ "@adobe-commerce/storefront-design": "~1.1.2",
71
71
  "@chromatic-com/storybook": "^5",
72
72
  "@preact/signals": "^2.3.1",
73
73
  "@types/node": "^22.0.0",