@zenky/storefront-vue 0.10.8 → 0.10.10
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.
- package/CHANGELOG.md +23 -0
- package/README.md +4 -18
- package/dist/cart/index.d.ts +167 -160
- package/dist/cart/index.js +7 -7
- package/dist/catalog/index.d.ts +23 -24
- package/dist/catalog/index.js +2 -2
- package/dist/catalogEntity-DgrPsJpf.d.ts +44 -0
- package/dist/{chunk-RO25KNM5.js → chunk-2Y6QTHXI.js} +2 -2
- package/dist/chunk-2Y6QTHXI.js.map +1 -0
- package/dist/{chunk-3FDM6T7F.js → chunk-32SLDGE5.js} +8 -6
- package/dist/chunk-32SLDGE5.js.map +1 -0
- package/dist/{chunk-5YD4AIY2.js → chunk-46FNHMWC.js} +4 -4
- package/dist/chunk-46FNHMWC.js.map +1 -0
- package/dist/{chunk-2SMSLZ6G.js → chunk-4UMDIBW5.js} +15 -11
- package/dist/chunk-4UMDIBW5.js.map +1 -0
- package/dist/{chunk-4IFPVEO7.js → chunk-BUNI6MGH.js} +3 -3
- package/dist/chunk-BUNI6MGH.js.map +1 -0
- package/dist/{chunk-E3G7NGCH.js → chunk-FS2UNPTY.js} +2 -2
- package/dist/chunk-FS2UNPTY.js.map +1 -0
- package/dist/{chunk-PTMSPB34.js → chunk-FXKG5TFQ.js} +3 -3
- package/dist/chunk-FXKG5TFQ.js.map +1 -0
- package/dist/{chunk-MOG6UMFM.js → chunk-GILJFP55.js} +2 -2
- package/dist/chunk-GILJFP55.js.map +1 -0
- package/dist/{chunk-2CI4RW7V.js → chunk-GLQXTMVW.js} +2 -2
- package/dist/{chunk-2CI4RW7V.js.map → chunk-GLQXTMVW.js.map} +1 -1
- package/dist/{chunk-MZ66ARDL.js → chunk-GXDTRTUT.js} +2 -2
- package/dist/chunk-GXDTRTUT.js.map +1 -0
- package/dist/{chunk-Z3IW4ODZ.js → chunk-NSOIL7PW.js} +2 -2
- package/dist/chunk-NSOIL7PW.js.map +1 -0
- package/dist/{chunk-NG7RUIWW.js → chunk-OBNMXLJO.js} +19 -3
- package/dist/chunk-OBNMXLJO.js.map +1 -0
- package/dist/{chunk-VFMVQR6Y.js → chunk-QZ3S3NN3.js} +5 -3
- package/dist/chunk-QZ3S3NN3.js.map +1 -0
- package/dist/{chunk-Z247QRDJ.js → chunk-XULHV6SS.js} +3 -3
- package/dist/chunk-XULHV6SS.js.map +1 -0
- package/dist/index.d.ts +4 -3
- package/dist/index.js +14 -14
- package/dist/money/index.d.ts +8 -8
- package/dist/money/index.js +1 -1
- package/dist/order/index.d.ts +3 -3
- package/dist/order/index.js.map +1 -1
- package/dist/pagination/index.d.ts +29 -37
- package/dist/pagination/index.js.map +1 -1
- package/dist/ports/index.d.ts +23 -22
- package/dist/ports/index.js +1 -1
- package/dist/products/index.d.ts +10 -10
- package/dist/products/index.js +3 -3
- package/dist/promotions/index.d.ts +5 -5
- package/dist/promotions/index.js +3 -3
- package/dist/seo/index.d.ts +17 -17
- package/dist/seo/index.js +15 -9
- package/dist/seo/index.js.map +1 -1
- package/dist/snippets/index.js +1 -1
- package/dist/stores/index.d.ts +8 -8
- package/dist/stores/index.js +4 -4
- package/dist/theme/index.d.ts +3 -3
- package/dist/theme/index.js +1 -1
- package/dist/utils/index.d.ts +16 -16
- package/dist/utils/index.js +1 -1
- package/docs/architecture.md +85 -0
- package/docs/consumer-setup.md +13 -54
- package/docs/ports.md +12 -13
- package/package.json +1 -1
- package/dist/chunk-2SMSLZ6G.js.map +0 -1
- package/dist/chunk-3FDM6T7F.js.map +0 -1
- package/dist/chunk-4IFPVEO7.js.map +0 -1
- package/dist/chunk-5YD4AIY2.js.map +0 -1
- package/dist/chunk-E3G7NGCH.js.map +0 -1
- package/dist/chunk-MOG6UMFM.js.map +0 -1
- package/dist/chunk-MZ66ARDL.js.map +0 -1
- package/dist/chunk-NG7RUIWW.js.map +0 -1
- package/dist/chunk-PTMSPB34.js.map +0 -1
- package/dist/chunk-RO25KNM5.js.map +0 -1
- package/dist/chunk-VFMVQR6Y.js.map +0 -1
- package/dist/chunk-Z247QRDJ.js.map +0 -1
- package/dist/chunk-Z3IW4ODZ.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -8,12 +8,35 @@ All notable changes to this project are documented in this file. The format foll
|
|
|
8
8
|
|
|
9
9
|
### Added
|
|
10
10
|
|
|
11
|
+
- `catalogItemEntity` / `isRenderableCatalogItem` (`/catalog`) — resolve a static catalog
|
|
12
|
+
item to a discriminated `category | collection` entity, with `id` and `name` lifted out
|
|
13
|
+
so a consumer can key, title, and scroll-spy a section without branching. Manual
|
|
14
|
+
catalogs can now contain product collections, which ship a `products_collection` object
|
|
15
|
+
instead of `category`. The entity is resolved by which object is present rather than by
|
|
16
|
+
`type`, because the payload (`products_collection`) and `@zenky/storefront-api@1.0.2`
|
|
17
|
+
(`collection`) disagree on the discriminator; both spellings are read. Items whose
|
|
18
|
+
entity has no id are treated as malformed and resolve to `null`.
|
|
19
|
+
- `StaticCatalogItem` / `StaticRemoteCatalog` (`/catalog`) — the catalog shapes as the
|
|
20
|
+
payload actually ships them. The SDK types predate manual catalogs: they omit
|
|
21
|
+
`products_collection` and `catalog_id`, the latter already returned by the live store
|
|
22
|
+
profile (`null` for automatic catalogs, filled for manual ones).
|
|
23
|
+
- `buildCollectionSchemas` (`/seo`) — JSON-LD for a products collection page.
|
|
11
24
|
- `useProductList` — fetches a page of products for a category or collection, with the
|
|
12
25
|
include list that keeps per-stock pricing working (`variants.prices`). Three call sites
|
|
13
26
|
in the consuming app built this fetch by hand and had drifted apart; one of them was
|
|
14
27
|
missing `variants.prices` and silently showed every product's store-wide price instead
|
|
15
28
|
of the price of the stock the customer was actually browsing.
|
|
16
29
|
|
|
30
|
+
### Changed
|
|
31
|
+
|
|
32
|
+
- `useCatalogStore` (`catalog`, `initCatalog`), `findProductInCatalog`, and the
|
|
33
|
+
`catalogItem` on `CatalogProductMatch` are typed `StaticCatalogItem` instead of the
|
|
34
|
+
SDK's `CatalogItem`, so the collection fields are visible on what the store holds.
|
|
35
|
+
`CatalogItem` values remain assignable, so passing catalog data in is unaffected; a
|
|
36
|
+
consumer that annotates a value read back out of the store as `CatalogItem[]` needs to
|
|
37
|
+
widen that annotation.
|
|
38
|
+
- `getRemoteCatalog` returns `StaticRemoteCatalog`, so `catalog_id` is typed.
|
|
39
|
+
|
|
17
40
|
## 0.10.7 - 2026-08-02
|
|
18
41
|
|
|
19
42
|
### Added
|
package/README.md
CHANGED
|
@@ -119,7 +119,7 @@ Pinia falls back to its module-level active instance. Under concurrent SSR that
|
|
|
119
119
|
belongs to whichever request touched it last, so the lookup succeeds with another user's
|
|
120
120
|
state instead of failing.
|
|
121
121
|
|
|
122
|
-
Two cases behave differently
|
|
122
|
+
Two cases behave differently:
|
|
123
123
|
|
|
124
124
|
- **Inside a store action — safe.** Pinia activates the action's own instance for the
|
|
125
125
|
duration of the call, so resolving another store there returns the right one.
|
|
@@ -163,7 +163,9 @@ import {
|
|
|
163
163
|
|
|
164
164
|
The full public contract, adapter examples, SSR lifecycle, and security boundary are in
|
|
165
165
|
[Runtime Ports](docs/ports.md). For a step-by-step consumer integration and upgrade
|
|
166
|
-
checklist, see [Consumer Setup](docs/consumer-setup.md).
|
|
166
|
+
checklist, see [Consumer Setup](docs/consumer-setup.md). For a map of what lives in each
|
|
167
|
+
domain folder and how to decide whether new logic belongs here or in the consumer app,
|
|
168
|
+
see [Architecture](docs/architecture.md).
|
|
167
169
|
|
|
168
170
|
## Subpath Imports
|
|
169
171
|
|
|
@@ -248,22 +250,6 @@ npm run check:runtime # import all entries in SSR + reject Node-only output
|
|
|
248
250
|
npm run check:size # enforce gzip bundle budgets
|
|
249
251
|
```
|
|
250
252
|
|
|
251
|
-
### Local linking with yalc
|
|
252
|
-
|
|
253
|
-
To iterate on an unreleased change without cutting a version, link the package into a
|
|
254
|
-
consumer app with [yalc](https://github.com/wclr/yalc):
|
|
255
|
-
|
|
256
|
-
```bash
|
|
257
|
-
# in this package, after a build:
|
|
258
|
-
npx yalc publish
|
|
259
|
-
|
|
260
|
-
# in the consumer app:
|
|
261
|
-
npx yalc add @zenky/storefront-vue
|
|
262
|
-
|
|
263
|
-
# after each change here:
|
|
264
|
-
npm run build && npx yalc push
|
|
265
|
-
```
|
|
266
|
-
|
|
267
253
|
## Package Scripts
|
|
268
254
|
|
|
269
255
|
- `build` — bundle the multi-entry ESM package with tsup.
|