From 1e1886bf7f4044e767c4db71b86e11bf3b1aa031 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 24 Aug 2026 20:59:00 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=96=20Version=20packages?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .changeset/cli-type-generation.md | 10 --------- .changeset/mgmt-contents-envelope.md | 7 ------- .changeset/preview-scoped-updates.md | 13 ------------ .changeset/sdk-audit-gaps.md | 18 ---------------- packages/cli/CHANGELOG.md | 16 ++++++++++++++ packages/cli/package.json | 2 +- packages/client/CHANGELOG.md | 24 +++++++++++++++++++++ packages/client/package.json | 2 +- packages/mcp-server/CHANGELOG.md | 7 +++++++ packages/mcp-server/package.json | 2 +- packages/mgmt-client/CHANGELOG.md | 20 ++++++++++++------ packages/mgmt-client/package.json | 2 +- packages/next/CHANGELOG.md | 9 ++++++++ packages/next/package.json | 2 +- packages/nuxt/CHANGELOG.md | 31 ++++++++++++++++++++++++++++ packages/nuxt/package.json | 2 +- packages/react/CHANGELOG.md | 8 +++++++ packages/react/package.json | 2 +- packages/richtext/CHANGELOG.md | 16 ++++++++++++++ packages/richtext/package.json | 2 +- packages/svelte/CHANGELOG.md | 8 +++++++ packages/svelte/package.json | 2 +- packages/vue/CHANGELOG.md | 30 +++++++++++++++++++++++++++ packages/vue/package.json | 2 +- 24 files changed, 173 insertions(+), 64 deletions(-) delete mode 100644 .changeset/cli-type-generation.md delete mode 100644 .changeset/mgmt-contents-envelope.md delete mode 100644 .changeset/preview-scoped-updates.md delete mode 100644 .changeset/sdk-audit-gaps.md diff --git a/.changeset/cli-type-generation.md b/.changeset/cli-type-generation.md deleted file mode 100644 index 5c0517b..0000000 --- a/.changeset/cli-type-generation.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -'@b10cks/cli': minor ---- - -Fix `generate types -o` path resolution and discriminate generated blocks - -- An explicit `-o` is now resolved against the working directory. Only the default output path is placed under a Nuxt 4 `app/` rootDir, so `-o ./app/b10cks/types` no longer lands in `app/app/…`. -- Each generated block interface carries a literal `block: 'slug'`, narrowing `B10cksItem`'s `block: string`. A heterogeneous body array can be discriminated on `block` without a cast. A schema field named `block` is skipped, since it would redeclare the discriminant. - -The literal `block` is a type-level narrowing. Code that assigns a hand-built object with a widened `block: string` to a generated interface (test fixtures, mocks) needs `as const` or an explicit literal after regenerating. diff --git a/.changeset/mgmt-contents-envelope.md b/.changeset/mgmt-contents-envelope.md deleted file mode 100644 index 43cd246..0000000 --- a/.changeset/mgmt-contents-envelope.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -'@b10cks/mgmt-client': patch ---- - -Unwrap the `{ data }` envelope on single-content endpoints - -`contents.get`, `create`, `update`, `move`, `publish`, `unpublish` and `schedule` declared a bare `Content` but resolved to `{ data: Content }`, so callers had to branch on the shape themselves. They now unwrap, making the declared type true. An already-bare response is passed through untouched. diff --git a/.changeset/preview-scoped-updates.md b/.changeset/preview-scoped-updates.md deleted file mode 100644 index e250186..0000000 --- a/.changeset/preview-scoped-updates.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -'@b10cks/client': minor -'@b10cks/vue': minor -'@b10cks/nuxt': minor ---- - -Fix live preview losing the page on a scoped edit, and duplicate-instance injection failures - -- `PreviewStore` now merges `CONTENT_UPDATE` by block `id` (`applyContentUpdate` / `mergeContentUpdate`) instead of replacing the root. The editor sends updates scoped to the edited block, which previously collapsed the whole preview to that block. Unknown ids are ignored. -- Vue injection keys use `Symbol.for(...)`, so a duplicated `@b10cks/vue` copy (Vite dep pre-bundling) can no longer break `useB10cksApi()` during hydration. -- `@b10cks/nuxt` registers `@b10cks/vue`, `@b10cks/client` and `@b10cks/richtext` in `vite.resolve.dedupe` and `optimizeDeps.exclude`, and transpiles them by bare specifier (the previous `resolver.resolve('@b10cks/vue')` produced a nonexistent path). -- New `toRootBlock(entry)` helper (`@b10cks/client`, re-exported from `@b10cks/vue`, auto-imported in Nuxt) returns `{ ...entry.content, id, block }` so the root block is selectable with `v-editable` and root-level editor updates match it. READMEs updated. -- `getConfig()` now includes the config entry's `id` in its result, so `v-editable="config"` works for config-driven regions. Potentially breaking only for a config schema with its own `id` field, which the entry id now shadows. diff --git a/.changeset/sdk-audit-gaps.md b/.changeset/sdk-audit-gaps.md deleted file mode 100644 index f5c8354..0000000 --- a/.changeset/sdk-audit-gaps.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -'@b10cks/client': minor -'@b10cks/vue': minor -'@b10cks/nuxt': minor -'@b10cks/richtext': minor ---- - -Close SDK gaps found auditing three production Nuxt sites - -- `@b10cks/client`: `rv` is now part of `IBBaseQueryParams`, so pinning a request to a revision (or passing `Date.now()` from a server route to sidestep a stale delivery cache) no longer needs an `as object` cast. -- `@b10cks/client`: `getDataEntries` takes a typed `IBDataEntryParams` with `dimension`, the locale-style variant selector for data sources. -- `@b10cks/client`: `GetConfigOptions.language` is deprecated in favour of `language_iso`, matching every other content param. Both still work. -- `@b10cks/nuxt`: `useB10cksConfig` watches `language_iso` as well as `language`, so a config passed `language_iso` refetches on a locale change instead of going stale. -- `@b10cks/nuxt`: new `useB10cksServerApi()`, auto-imported in the server bundle. Nitro routes and middleware get the full `B10cksDataApi` — `getRedirects`, `getSitemap`, `getNamedSitemap` with pagination and caching — instead of hand-rolling paginated fetches and TTL caches. -- `@b10cks/nuxt`: new `useB10cksVersion()` composable, normalizing `?b10cks_vid` to a version string defaulting to `published`. -- `@b10cks/richtext`: new `isRichTextEmpty(document)`, re-exported from `@b10cks/vue/rich-text` and `@b10cks/nuxt`. Reports whether a document renders anything, so a field an editor cleared (an empty paragraph) can skip its wrapper markup. -- `@b10cks/client`: `renderSitemapXml` and `filterSitemapEntries` take a `localePrefix` strategy (`auto` | `always` | `never` | `except-default`). It defaults to `auto`, which prefixes only when the entries span more than one language. A mono-lingual space previously emitted `/en/about` for a page served at `/about`, making every sitemap URL a 404 or a redirect. -- Docs: the client README documents the response-envelope normalization every collection method already does, and points at `filter` for `id` / `canonical_id` / `parent_id` queries. The Nuxt README surfaces `usePreviewContent` from the top of the usage section. diff --git a/packages/cli/CHANGELOG.md b/packages/cli/CHANGELOG.md index 1ca1501..4a3bd68 100644 --- a/packages/cli/CHANGELOG.md +++ b/packages/cli/CHANGELOG.md @@ -1,5 +1,21 @@ # @b10cks/cli +## 2.1.0 + +### Minor Changes + +- [#13](https://github.com/b10cks/sdk/pull/13) [`674abc2`](https://github.com/b10cks/sdk/commit/674abc208232ee1bc2b8e323acf2141eb0f212b8) Thanks [@badmike](https://github.com/badmike)! - Fix `generate types -o` path resolution and discriminate generated blocks + + - An explicit `-o` is now resolved against the working directory. Only the default output path is placed under a Nuxt 4 `app/` rootDir, so `-o ./app/b10cks/types` no longer lands in `app/app/…`. + - Each generated block interface carries a literal `block: 'slug'`, narrowing `B10cksItem`'s `block: string`. A heterogeneous body array can be discriminated on `block` without a cast. A schema field named `block` is skipped, since it would redeclare the discriminant. + + The literal `block` is a type-level narrowing. Code that assigns a hand-built object with a widened `block: string` to a generated interface (test fixtures, mocks) needs `as const` or an explicit literal after regenerating. + +### Patch Changes + +- Updated dependencies [[`122bcd4`](https://github.com/b10cks/sdk/commit/122bcd4f8f5c2a894cbcda50dde720a873b5c476)]: + - @b10cks/mgmt-client@2.1.1 + ## 2.0.2 ### Patch Changes diff --git a/packages/cli/package.json b/packages/cli/package.json index 25aa04b..47c5681 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/cli", - "version": "2.0.2", + "version": "2.1.0", "description": "CLI to interact with the b10cks Management API", "keywords": [ "b10cks", diff --git a/packages/client/CHANGELOG.md b/packages/client/CHANGELOG.md index 80715b4..fe70a77 100644 --- a/packages/client/CHANGELOG.md +++ b/packages/client/CHANGELOG.md @@ -1,5 +1,29 @@ # @b10cks/client +## 1.10.0 + +### Minor Changes + +- [#9](https://github.com/b10cks/sdk/pull/9) [`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb) Thanks [@badmike](https://github.com/badmike)! - Fix live preview losing the page on a scoped edit, and duplicate-instance injection failures + + - `PreviewStore` now merges `CONTENT_UPDATE` by block `id` (`applyContentUpdate` / `mergeContentUpdate`) instead of replacing the root. The editor sends updates scoped to the edited block, which previously collapsed the whole preview to that block. Unknown ids are ignored. + - Vue injection keys use `Symbol.for(...)`, so a duplicated `@b10cks/vue` copy (Vite dep pre-bundling) can no longer break `useB10cksApi()` during hydration. + - `@b10cks/nuxt` registers `@b10cks/vue`, `@b10cks/client` and `@b10cks/richtext` in `vite.resolve.dedupe` and `optimizeDeps.exclude`, and transpiles them by bare specifier (the previous `resolver.resolve('@b10cks/vue')` produced a nonexistent path). + - New `toRootBlock(entry)` helper (`@b10cks/client`, re-exported from `@b10cks/vue`, auto-imported in Nuxt) returns `{ ...entry.content, id, block }` so the root block is selectable with `v-editable` and root-level editor updates match it. READMEs updated. + - `getConfig()` now includes the config entry's `id` in its result, so `v-editable="config"` works for config-driven regions. Potentially breaking only for a config schema with its own `id` field, which the entry id now shadows. + +- [#13](https://github.com/b10cks/sdk/pull/13) [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d) Thanks [@badmike](https://github.com/badmike)! - Close SDK gaps found auditing three production Nuxt sites + + - `@b10cks/client`: `rv` is now part of `IBBaseQueryParams`, so pinning a request to a revision (or passing `Date.now()` from a server route to sidestep a stale delivery cache) no longer needs an `as object` cast. + - `@b10cks/client`: `getDataEntries` takes a typed `IBDataEntryParams` with `dimension`, the locale-style variant selector for data sources. + - `@b10cks/client`: `GetConfigOptions.language` is deprecated in favour of `language_iso`, matching every other content param. Both still work. + - `@b10cks/nuxt`: `useB10cksConfig` watches `language_iso` as well as `language`, so a config passed `language_iso` refetches on a locale change instead of going stale. + - `@b10cks/nuxt`: new `useB10cksServerApi()`, auto-imported in the server bundle. Nitro routes and middleware get the full `B10cksDataApi` — `getRedirects`, `getSitemap`, `getNamedSitemap` with pagination and caching — instead of hand-rolling paginated fetches and TTL caches. + - `@b10cks/nuxt`: new `useB10cksVersion()` composable, normalizing `?b10cks_vid` to a version string defaulting to `published`. + - `@b10cks/richtext`: new `isRichTextEmpty(document)`, re-exported from `@b10cks/vue/rich-text` and `@b10cks/nuxt`. Reports whether a document renders anything, so a field an editor cleared (an empty paragraph) can skip its wrapper markup. + - `@b10cks/client`: `renderSitemapXml` and `filterSitemapEntries` take a `localePrefix` strategy (`auto` | `always` | `never` | `except-default`). It defaults to `auto`, which prefixes only when the entries span more than one language. A mono-lingual space previously emitted `/en/about` for a page served at `/about`, making every sitemap URL a 404 or a redirect. + - Docs: the client README documents the response-envelope normalization every collection method already does, and points at `filter` for `id` / `canonical_id` / `parent_id` queries. The Nuxt README surfaces `usePreviewContent` from the top of the usage section. + ## 1.9.0 ### Minor Changes diff --git a/packages/client/package.json b/packages/client/package.json index 6e151f3..d20fa51 100644 --- a/packages/client/package.json +++ b/packages/client/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/client", - "version": "1.9.0", + "version": "1.10.0", "description": "Core b10cks API client", "keywords": [ "api-client", diff --git a/packages/mcp-server/CHANGELOG.md b/packages/mcp-server/CHANGELOG.md index 4c32f08..70cd84d 100644 --- a/packages/mcp-server/CHANGELOG.md +++ b/packages/mcp-server/CHANGELOG.md @@ -1,5 +1,12 @@ # @b10cks/mcp-server +## 0.14.4 + +### Patch Changes + +- Updated dependencies [[`122bcd4`](https://github.com/b10cks/sdk/commit/122bcd4f8f5c2a894cbcda50dde720a873b5c476)]: + - @b10cks/mgmt-client@2.1.1 + ## 0.14.3 ### Patch Changes diff --git a/packages/mcp-server/package.json b/packages/mcp-server/package.json index b5e05d2..27d05ad 100644 --- a/packages/mcp-server/package.json +++ b/packages/mcp-server/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/mcp-server", - "version": "0.14.3", + "version": "0.14.4", "description": "MCP server for the b10cks headless CMS Management API — block definitions, content, redirects, data sources, releases, automations and more", "keywords": [ "ai", diff --git a/packages/mgmt-client/CHANGELOG.md b/packages/mgmt-client/CHANGELOG.md index 3acdfa5..10934c6 100644 --- a/packages/mgmt-client/CHANGELOG.md +++ b/packages/mgmt-client/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 2.1.1 + +### Patch Changes + +- [#13](https://github.com/b10cks/sdk/pull/13) [`122bcd4`](https://github.com/b10cks/sdk/commit/122bcd4f8f5c2a894cbcda50dde720a873b5c476) Thanks [@badmike](https://github.com/badmike)! - Unwrap the `{ data }` envelope on single-content endpoints + + `contents.get`, `create`, `update`, `move`, `publish`, `unpublish` and `schedule` declared a bare `Content` but resolved to `{ data: Content }`, so callers had to branch on the shape themselves. They now unwrap, making the declared type true. An already-bare response is passed through untouched. + ## 2.1.0 ### Minor Changes @@ -24,12 +32,12 @@ ```ts // before — inconsistent, per resource - client.teams.list({ query: { page: 2 } }) - client.blocks.list(spaceId, { page: 2 }) + client.teams.list({ query: { page: 2 } }); + client.blocks.list(spaceId, { page: 2 }); // after — the same everywhere - client.teams.list({ page: 2 }) - client.blocks.list(spaceId, { page: 2 }) + client.teams.list({ page: 2 }); + client.blocks.list(spaceId, { page: 2 }); ``` **Breaking:** if you passed a `RequestOptions` object positionally to one of the @@ -37,8 +45,8 @@ `spaces.list`, `users.listTokens` and `users.listInvites`): ```ts - client.teams.listMembers(teamId, { headers }) // before - client.teams.listMembers(teamId, undefined, { headers }) // after + client.teams.listMembers(teamId, { headers }); // before + client.teams.listMembers(teamId, undefined, { headers }); // after ``` `RequestOptions.query` remains as an escape hatch for the few non-paginated diff --git a/packages/mgmt-client/package.json b/packages/mgmt-client/package.json index 0e47b0e..03925e7 100644 --- a/packages/mgmt-client/package.json +++ b/packages/mgmt-client/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/mgmt-client", - "version": "2.1.0", + "version": "2.1.1", "description": "Management API client for b10cks", "keywords": [ "api-client", diff --git a/packages/next/CHANGELOG.md b/packages/next/CHANGELOG.md index f54d7f7..adcf026 100644 --- a/packages/next/CHANGELOG.md +++ b/packages/next/CHANGELOG.md @@ -1,5 +1,14 @@ # @b10cks/next +## 0.4.6 + +### Patch Changes + +- Updated dependencies [[`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb), [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d)]: + - @b10cks/client@1.10.0 + - @b10cks/richtext@0.7.0 + - @b10cks/react@0.7.1 + ## 0.4.5 ### Patch Changes diff --git a/packages/next/package.json b/packages/next/package.json index b310c72..82e0510 100644 --- a/packages/next/package.json +++ b/packages/next/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/next", - "version": "0.4.5", + "version": "0.4.6", "description": "Next.js integration SDK for b10cks", "keywords": [ "b10cks", diff --git a/packages/nuxt/CHANGELOG.md b/packages/nuxt/CHANGELOG.md index d765f18..ef3b949 100644 --- a/packages/nuxt/CHANGELOG.md +++ b/packages/nuxt/CHANGELOG.md @@ -1,5 +1,36 @@ # @b10cks/nuxt +## 3.5.0 + +### Minor Changes + +- [#9](https://github.com/b10cks/sdk/pull/9) [`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb) Thanks [@badmike](https://github.com/badmike)! - Fix live preview losing the page on a scoped edit, and duplicate-instance injection failures + + - `PreviewStore` now merges `CONTENT_UPDATE` by block `id` (`applyContentUpdate` / `mergeContentUpdate`) instead of replacing the root. The editor sends updates scoped to the edited block, which previously collapsed the whole preview to that block. Unknown ids are ignored. + - Vue injection keys use `Symbol.for(...)`, so a duplicated `@b10cks/vue` copy (Vite dep pre-bundling) can no longer break `useB10cksApi()` during hydration. + - `@b10cks/nuxt` registers `@b10cks/vue`, `@b10cks/client` and `@b10cks/richtext` in `vite.resolve.dedupe` and `optimizeDeps.exclude`, and transpiles them by bare specifier (the previous `resolver.resolve('@b10cks/vue')` produced a nonexistent path). + - New `toRootBlock(entry)` helper (`@b10cks/client`, re-exported from `@b10cks/vue`, auto-imported in Nuxt) returns `{ ...entry.content, id, block }` so the root block is selectable with `v-editable` and root-level editor updates match it. READMEs updated. + - `getConfig()` now includes the config entry's `id` in its result, so `v-editable="config"` works for config-driven regions. Potentially breaking only for a config schema with its own `id` field, which the entry id now shadows. + +- [#13](https://github.com/b10cks/sdk/pull/13) [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d) Thanks [@badmike](https://github.com/badmike)! - Close SDK gaps found auditing three production Nuxt sites + + - `@b10cks/client`: `rv` is now part of `IBBaseQueryParams`, so pinning a request to a revision (or passing `Date.now()` from a server route to sidestep a stale delivery cache) no longer needs an `as object` cast. + - `@b10cks/client`: `getDataEntries` takes a typed `IBDataEntryParams` with `dimension`, the locale-style variant selector for data sources. + - `@b10cks/client`: `GetConfigOptions.language` is deprecated in favour of `language_iso`, matching every other content param. Both still work. + - `@b10cks/nuxt`: `useB10cksConfig` watches `language_iso` as well as `language`, so a config passed `language_iso` refetches on a locale change instead of going stale. + - `@b10cks/nuxt`: new `useB10cksServerApi()`, auto-imported in the server bundle. Nitro routes and middleware get the full `B10cksDataApi` — `getRedirects`, `getSitemap`, `getNamedSitemap` with pagination and caching — instead of hand-rolling paginated fetches and TTL caches. + - `@b10cks/nuxt`: new `useB10cksVersion()` composable, normalizing `?b10cks_vid` to a version string defaulting to `published`. + - `@b10cks/richtext`: new `isRichTextEmpty(document)`, re-exported from `@b10cks/vue/rich-text` and `@b10cks/nuxt`. Reports whether a document renders anything, so a field an editor cleared (an empty paragraph) can skip its wrapper markup. + - `@b10cks/client`: `renderSitemapXml` and `filterSitemapEntries` take a `localePrefix` strategy (`auto` | `always` | `never` | `except-default`). It defaults to `auto`, which prefixes only when the entries span more than one language. A mono-lingual space previously emitted `/en/about` for a page served at `/about`, making every sitemap URL a 404 or a redirect. + - Docs: the client README documents the response-envelope normalization every collection method already does, and points at `filter` for `id` / `canonical_id` / `parent_id` queries. The Nuxt README surfaces `usePreviewContent` from the top of the usage section. + +### Patch Changes + +- Updated dependencies [[`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb), [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d)]: + - @b10cks/client@1.10.0 + - @b10cks/vue@2.7.0 + - @b10cks/richtext@0.7.0 + ## 3.4.1 ### Patch Changes diff --git a/packages/nuxt/package.json b/packages/nuxt/package.json index 24d3f9f..6383fee 100644 --- a/packages/nuxt/package.json +++ b/packages/nuxt/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/nuxt", - "version": "3.4.1", + "version": "3.5.0", "description": "b10cks Nuxt client SDK", "keywords": [ "b10cks", diff --git a/packages/react/CHANGELOG.md b/packages/react/CHANGELOG.md index 935587f..315bbf2 100644 --- a/packages/react/CHANGELOG.md +++ b/packages/react/CHANGELOG.md @@ -1,5 +1,13 @@ # @b10cks/react +## 0.7.1 + +### Patch Changes + +- Updated dependencies [[`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb), [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d)]: + - @b10cks/client@1.10.0 + - @b10cks/richtext@0.7.0 + ## 0.7.0 ### Minor Changes diff --git a/packages/react/package.json b/packages/react/package.json index 1dcf5d1..9b9e589 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/react", - "version": "0.7.0", + "version": "0.7.1", "description": "React SDK for integrating b10cks into React applications", "keywords": [ "b10cks", diff --git a/packages/richtext/CHANGELOG.md b/packages/richtext/CHANGELOG.md index f4d0440..714d0d9 100644 --- a/packages/richtext/CHANGELOG.md +++ b/packages/richtext/CHANGELOG.md @@ -1,5 +1,21 @@ # @b10cks/richtext +## 0.7.0 + +### Minor Changes + +- [#13](https://github.com/b10cks/sdk/pull/13) [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d) Thanks [@badmike](https://github.com/badmike)! - Close SDK gaps found auditing three production Nuxt sites + + - `@b10cks/client`: `rv` is now part of `IBBaseQueryParams`, so pinning a request to a revision (or passing `Date.now()` from a server route to sidestep a stale delivery cache) no longer needs an `as object` cast. + - `@b10cks/client`: `getDataEntries` takes a typed `IBDataEntryParams` with `dimension`, the locale-style variant selector for data sources. + - `@b10cks/client`: `GetConfigOptions.language` is deprecated in favour of `language_iso`, matching every other content param. Both still work. + - `@b10cks/nuxt`: `useB10cksConfig` watches `language_iso` as well as `language`, so a config passed `language_iso` refetches on a locale change instead of going stale. + - `@b10cks/nuxt`: new `useB10cksServerApi()`, auto-imported in the server bundle. Nitro routes and middleware get the full `B10cksDataApi` — `getRedirects`, `getSitemap`, `getNamedSitemap` with pagination and caching — instead of hand-rolling paginated fetches and TTL caches. + - `@b10cks/nuxt`: new `useB10cksVersion()` composable, normalizing `?b10cks_vid` to a version string defaulting to `published`. + - `@b10cks/richtext`: new `isRichTextEmpty(document)`, re-exported from `@b10cks/vue/rich-text` and `@b10cks/nuxt`. Reports whether a document renders anything, so a field an editor cleared (an empty paragraph) can skip its wrapper markup. + - `@b10cks/client`: `renderSitemapXml` and `filterSitemapEntries` take a `localePrefix` strategy (`auto` | `always` | `never` | `except-default`). It defaults to `auto`, which prefixes only when the entries span more than one language. A mono-lingual space previously emitted `/en/about` for a page served at `/about`, making every sitemap URL a 404 or a redirect. + - Docs: the client README documents the response-envelope normalization every collection method already does, and points at `filter` for `id` / `canonical_id` / `parent_id` queries. The Nuxt README surfaces `usePreviewContent` from the top of the usage section. + ## 0.6.1 ### Patch Changes diff --git a/packages/richtext/package.json b/packages/richtext/package.json index 2bfeec9..808a49c 100644 --- a/packages/richtext/package.json +++ b/packages/richtext/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/richtext", - "version": "0.6.1", + "version": "0.7.0", "description": "Framework-agnostic rich text rendering for b10cks Rich text", "keywords": [ "b10cks", diff --git a/packages/svelte/CHANGELOG.md b/packages/svelte/CHANGELOG.md index 00ffae1..b457e9c 100644 --- a/packages/svelte/CHANGELOG.md +++ b/packages/svelte/CHANGELOG.md @@ -1,5 +1,13 @@ # @b10cks/svelte +## 0.7.1 + +### Patch Changes + +- Updated dependencies [[`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb), [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d)]: + - @b10cks/client@1.10.0 + - @b10cks/richtext@0.7.0 + ## 0.7.0 ### Minor Changes diff --git a/packages/svelte/package.json b/packages/svelte/package.json index 2950497..54c47a6 100644 --- a/packages/svelte/package.json +++ b/packages/svelte/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/svelte", - "version": "0.7.0", + "version": "0.7.1", "description": "Svelte SDK for integrating b10cks into Svelte applications", "keywords": [ "b10cks", diff --git a/packages/vue/CHANGELOG.md b/packages/vue/CHANGELOG.md index 45a3832..46c2f47 100644 --- a/packages/vue/CHANGELOG.md +++ b/packages/vue/CHANGELOG.md @@ -1,5 +1,35 @@ # @b10cks/vue +## 2.7.0 + +### Minor Changes + +- [#9](https://github.com/b10cks/sdk/pull/9) [`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb) Thanks [@badmike](https://github.com/badmike)! - Fix live preview losing the page on a scoped edit, and duplicate-instance injection failures + + - `PreviewStore` now merges `CONTENT_UPDATE` by block `id` (`applyContentUpdate` / `mergeContentUpdate`) instead of replacing the root. The editor sends updates scoped to the edited block, which previously collapsed the whole preview to that block. Unknown ids are ignored. + - Vue injection keys use `Symbol.for(...)`, so a duplicated `@b10cks/vue` copy (Vite dep pre-bundling) can no longer break `useB10cksApi()` during hydration. + - `@b10cks/nuxt` registers `@b10cks/vue`, `@b10cks/client` and `@b10cks/richtext` in `vite.resolve.dedupe` and `optimizeDeps.exclude`, and transpiles them by bare specifier (the previous `resolver.resolve('@b10cks/vue')` produced a nonexistent path). + - New `toRootBlock(entry)` helper (`@b10cks/client`, re-exported from `@b10cks/vue`, auto-imported in Nuxt) returns `{ ...entry.content, id, block }` so the root block is selectable with `v-editable` and root-level editor updates match it. READMEs updated. + - `getConfig()` now includes the config entry's `id` in its result, so `v-editable="config"` works for config-driven regions. Potentially breaking only for a config schema with its own `id` field, which the entry id now shadows. + +- [#13](https://github.com/b10cks/sdk/pull/13) [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d) Thanks [@badmike](https://github.com/badmike)! - Close SDK gaps found auditing three production Nuxt sites + + - `@b10cks/client`: `rv` is now part of `IBBaseQueryParams`, so pinning a request to a revision (or passing `Date.now()` from a server route to sidestep a stale delivery cache) no longer needs an `as object` cast. + - `@b10cks/client`: `getDataEntries` takes a typed `IBDataEntryParams` with `dimension`, the locale-style variant selector for data sources. + - `@b10cks/client`: `GetConfigOptions.language` is deprecated in favour of `language_iso`, matching every other content param. Both still work. + - `@b10cks/nuxt`: `useB10cksConfig` watches `language_iso` as well as `language`, so a config passed `language_iso` refetches on a locale change instead of going stale. + - `@b10cks/nuxt`: new `useB10cksServerApi()`, auto-imported in the server bundle. Nitro routes and middleware get the full `B10cksDataApi` — `getRedirects`, `getSitemap`, `getNamedSitemap` with pagination and caching — instead of hand-rolling paginated fetches and TTL caches. + - `@b10cks/nuxt`: new `useB10cksVersion()` composable, normalizing `?b10cks_vid` to a version string defaulting to `published`. + - `@b10cks/richtext`: new `isRichTextEmpty(document)`, re-exported from `@b10cks/vue/rich-text` and `@b10cks/nuxt`. Reports whether a document renders anything, so a field an editor cleared (an empty paragraph) can skip its wrapper markup. + - `@b10cks/client`: `renderSitemapXml` and `filterSitemapEntries` take a `localePrefix` strategy (`auto` | `always` | `never` | `except-default`). It defaults to `auto`, which prefixes only when the entries span more than one language. A mono-lingual space previously emitted `/en/about` for a page served at `/about`, making every sitemap URL a 404 or a redirect. + - Docs: the client README documents the response-envelope normalization every collection method already does, and points at `filter` for `id` / `canonical_id` / `parent_id` queries. The Nuxt README surfaces `usePreviewContent` from the top of the usage section. + +### Patch Changes + +- Updated dependencies [[`161b103`](https://github.com/b10cks/sdk/commit/161b1031f11a4329b2a903ec3ee9d3c1f0c78efb), [`0a032af`](https://github.com/b10cks/sdk/commit/0a032afd66cec876271ff53b706e5c7912f2e14d)]: + - @b10cks/client@1.10.0 + - @b10cks/richtext@0.7.0 + ## 2.6.0 ### Minor Changes diff --git a/packages/vue/package.json b/packages/vue/package.json index 0d3984b..c809db8 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -1,6 +1,6 @@ { "name": "@b10cks/vue", - "version": "2.6.0", + "version": "2.7.0", "description": "SDK to integrate b10cks into your vue applications", "keywords": [ "b10cks",