diff --git a/.changeset/tabbed-posts-category-fix-scoped.md b/.changeset/tabbed-posts-category-fix-scoped.md deleted file mode 100644 index 1ed005ce..00000000 --- a/.changeset/tabbed-posts-category-fix-scoped.md +++ /dev/null @@ -1,20 +0,0 @@ ---- -"@devgateway/dvz-ui-react": patch ---- - -Revert the PR #296 fix for TCDICORE-601, which comma-joined all array/object -attributes in `PreviewComponent.tsx` before postMessage'ing them to the -block-editor preview iframe. That change was a shared choke point used by -every embeddable block, and it broke any block whose attribute is an array of -objects (e.g. `filters`, map `legendBreaks`) by turning it into an -unparseable `"[object Object],[object Object]"` string. - -`PreviewComponent.tsx` now always JSON-stringifies object/array attributes -again, restoring pre-PR-296 behavior for every block except Tabbed Posts. - -The original TCDICORE-601 problem — the Tabbed Posts editor preview sending -`categories` as `"[5,7]"` instead of the front-end's comma-separated `"5,7"` -— is now fixed locally inside the Tabbed Posts embeddable component -(`tabbedposts/index.jsx`), which detects a JSON-array-shaped `categories` -string and normalizes it to the comma-separated format the REST API expects, -without changing how any other block's attributes are serialized. diff --git a/packages/dvz-ui/CHANGELOG.md b/packages/dvz-ui/CHANGELOG.md index 1cfd1d9f..40949aec 100644 --- a/packages/dvz-ui/CHANGELOG.md +++ b/packages/dvz-ui/CHANGELOG.md @@ -1,5 +1,26 @@ # @devgateway/dvz-ui-react +## 1.9.15 + +### Patch Changes + +- [#298](https://github.com/devgateway/data-viz-ui/pull/298) [`dc8a212`](https://github.com/devgateway/data-viz-ui/commit/dc8a212c4e56fae08ad9cb697dd91d9cbe8c209d) Thanks [@claude](https://github.com/apps/claude)! - Revert the PR #296 fix for TCDICORE-601, which comma-joined all array/object + attributes in `PreviewComponent.tsx` before postMessage'ing them to the + block-editor preview iframe. That change was a shared choke point used by + every embeddable block, and it broke any block whose attribute is an array of + objects (e.g. `filters`, map `legendBreaks`) by turning it into an + unparseable `"[object Object],[object Object]"` string. + + `PreviewComponent.tsx` now always JSON-stringifies object/array attributes + again, restoring pre-PR-296 behavior for every block except Tabbed Posts. + + The original TCDICORE-601 problem — the Tabbed Posts editor preview sending + `categories` as `"[5,7]"` instead of the front-end's comma-separated `"5,7"` + — is now fixed locally inside the Tabbed Posts embeddable component + (`tabbedposts/index.jsx`), which detects a JSON-array-shaped `categories` + string and normalizes it to the comma-separated format the REST API expects, + without changing how any other block's attributes are serialized. + ## 1.9.14 ### Patch Changes diff --git a/packages/dvz-ui/package.json b/packages/dvz-ui/package.json index e36bbb04..29d61b31 100644 --- a/packages/dvz-ui/package.json +++ b/packages/dvz-ui/package.json @@ -1,6 +1,6 @@ { "name": "@devgateway/dvz-ui-react", - "version": "1.9.14", + "version": "1.9.15", "main": "dist/cjs/index.js", "module": "dist/esm/index.js", "types": "dist/types/index.d.ts",