From a07c569075eac2cc4c327c84ea22564c53095001 Mon Sep 17 00:00:00 2001 From: Jeffrey Dowdle Date: Fri, 19 Dec 2025 13:50:37 +1100 Subject: [PATCH 1/2] fix(@dpc-sdp/ripple-tide-api): fixed linkset parsing 'startsWith' issue --- .../src/services/lib/site-menu-linkset.ts | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/packages/ripple-tide-api/src/services/lib/site-menu-linkset.ts b/packages/ripple-tide-api/src/services/lib/site-menu-linkset.ts index f32582640..c3e28325c 100644 --- a/packages/ripple-tide-api/src/services/lib/site-menu-linkset.ts +++ b/packages/ripple-tide-api/src/services/lib/site-menu-linkset.ts @@ -33,14 +33,30 @@ const setActivePath = (branch: ProcessedMenu[], path: string) => { return isActivePath } +/** + * Checks whether the `prefix` array matches the beginning of the `array`. + * + * Returns `true` if all elements in `prefix` appear in the same order + * at the start of `array`. Returns `false` if `prefix` is longer than + * `array` or if any element differs. + */ +const isPrefix = (prefix: string[], array: string[]): boolean => { + if (prefix.length > array.length) { + return false + } + + return prefix.every((value, index) => value === array[index]) +} + const processNode = (linkset: LinksetMenu[], parentKey: string, level = 1) => { const processedValues: ProcessedMenu[] = [] for (const link of linkset.filter( (item) => item.hierarchy.length === level )) { const nodeKey = link.hierarchy.join('-') + const isChild = isPrefix(parentKey.split('-'), link.hierarchy) - if (level === 1 || nodeKey.startsWith(parentKey)) { + if (level === 1 || isChild) { const values: ProcessedMenu = { text: link.title, url: stripSiteId(link.href), From 731fa670cbc4c7b94f91ff4f7167d2c793b64273 Mon Sep 17 00:00:00 2001 From: SDP Deploy Date: Wed, 24 Dec 2025 04:17:25 +0000 Subject: [PATCH 2/2] chore: release v2.45.1 --- CHANGELOG.md | 4 ++++ lerna.json | 2 +- packages/eslint-config-ripple/package.json | 2 +- packages/nuxt-ripple-analytics/package.json | 2 +- packages/nuxt-ripple-cli/package.json | 2 +- packages/nuxt-ripple-preview/package.json | 2 +- packages/nuxt-ripple/package.json | 2 +- packages/ripple-sdp-core/package.json | 2 +- packages/ripple-storybook/package.json | 2 +- packages/ripple-test-utils/package.json | 2 +- packages/ripple-tide-api/package.json | 2 +- packages/ripple-tide-event/package.json | 2 +- packages/ripple-tide-grant/package.json | 2 +- packages/ripple-tide-landing-page/package.json | 2 +- packages/ripple-tide-media/package.json | 2 +- packages/ripple-tide-news/package.json | 2 +- packages/ripple-tide-publication/package.json | 2 +- packages/ripple-tide-search/package.json | 2 +- packages/ripple-tide-topic/package.json | 2 +- packages/ripple-tide-webform/package.json | 2 +- packages/ripple-ui-core/package.json | 2 +- packages/ripple-ui-forms/package.json | 2 +- packages/ripple-ui-maps/package.json | 2 +- packages/stylelint-config-ripple/package.json | 2 +- 24 files changed, 27 insertions(+), 23 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 823e08774..66e38b62f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## v2.45.1 + +[compare changes](https://github.com/dpc-sdp/ripple-framework/compare/2.45.1...v2.45.1) + ## v2.45.0 [compare changes](https://github.com/dpc-sdp/ripple-framework/compare/2.45.0...v2.45.0) diff --git a/lerna.json b/lerna.json index ace8e7ab0..fd4f7eb8f 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "2.45.0", + "version": "2.45.1", "npmClient": "pnpm", "exact": true, "command": { diff --git a/packages/eslint-config-ripple/package.json b/packages/eslint-config-ripple/package.json index 2e8fd14dc..e2cb93efa 100644 --- a/packages/eslint-config-ripple/package.json +++ b/packages/eslint-config-ripple/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/eslint-config-ripple", "description": "ESLint config for Ripple projects", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "index.js", diff --git a/packages/nuxt-ripple-analytics/package.json b/packages/nuxt-ripple-analytics/package.json index fd69725dd..656d63685 100644 --- a/packages/nuxt-ripple-analytics/package.json +++ b/packages/nuxt-ripple-analytics/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/nuxt-ripple-analytics", "description": "Nuxt module for handling event tracking.", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "main": "./nuxt.config.ts", "repository": "https://github.com/dpc-sdp/ripple-framework", diff --git a/packages/nuxt-ripple-cli/package.json b/packages/nuxt-ripple-cli/package.json index 6c0c72462..e3029aebc 100644 --- a/packages/nuxt-ripple-cli/package.json +++ b/packages/nuxt-ripple-cli/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/nuxt-ripple-cli", "description": "A CLI for simplifying common setup and scaffolding tasks", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./dist/index.js", diff --git a/packages/nuxt-ripple-preview/package.json b/packages/nuxt-ripple-preview/package.json index 48b6ad0dc..4aaac8934 100644 --- a/packages/nuxt-ripple-preview/package.json +++ b/packages/nuxt-ripple-preview/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/nuxt-ripple-preview", "description": "Adds support for drupal preview links in Ripple frontend sites", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "main": "./nuxt.config.ts", "repository": "https://github.com/dpc-sdp/ripple-framework", diff --git a/packages/nuxt-ripple/package.json b/packages/nuxt-ripple/package.json index 938d6c977..039b40152 100644 --- a/packages/nuxt-ripple/package.json +++ b/packages/nuxt-ripple/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/nuxt-ripple", "description": "Nuxt module for integrating Ripple and Tide", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "main": "./nuxt.config.ts", "repository": "https://github.com/dpc-sdp/ripple-framework", diff --git a/packages/ripple-sdp-core/package.json b/packages/ripple-sdp-core/package.json index 53e088958..8a3271821 100644 --- a/packages/ripple-sdp-core/package.json +++ b/packages/ripple-sdp-core/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-sdp-core", "description": "SDP core content types", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-storybook/package.json b/packages/ripple-storybook/package.json index d0b117108..14cc44028 100644 --- a/packages/ripple-storybook/package.json +++ b/packages/ripple-storybook/package.json @@ -1,7 +1,7 @@ { "name": "ripple-storybook", "description": "Ripple Storybook instance", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "private": true, "repository": "https://github.com/dpc-sdp/ripple-framework", diff --git a/packages/ripple-test-utils/package.json b/packages/ripple-test-utils/package.json index 1ee9ec271..c4e048b61 100644 --- a/packages/ripple-test-utils/package.json +++ b/packages/ripple-test-utils/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-test-utils", "description": "Test utils for Ripple sites", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "type": "module", "main": "./dist/config/index.js", diff --git a/packages/ripple-tide-api/package.json b/packages/ripple-tide-api/package.json index d284b76d3..e0f8a4dab 100644 --- a/packages/ripple-tide-api/package.json +++ b/packages/ripple-tide-api/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-api", "description": "Ripple API endpoints for Tide Drupal backend", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./dist/index.js", diff --git a/packages/ripple-tide-event/package.json b/packages/ripple-tide-event/package.json index 0939683d4..ccdd8aa3d 100644 --- a/packages/ripple-tide-event/package.json +++ b/packages/ripple-tide-event/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-event", "description": "Ripple mappings and components for Tide Event Content type", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "main": "./nuxt.config.ts", "repository": "https://github.com/dpc-sdp/ripple-framework", diff --git a/packages/ripple-tide-grant/package.json b/packages/ripple-tide-grant/package.json index e43fb7b77..b63704866 100644 --- a/packages/ripple-tide-grant/package.json +++ b/packages/ripple-tide-grant/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-grant", "description": "Ripple mappings and components for Tide Grant Content type", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-tide-landing-page/package.json b/packages/ripple-tide-landing-page/package.json index 68c4565d6..9a48585af 100644 --- a/packages/ripple-tide-landing-page/package.json +++ b/packages/ripple-tide-landing-page/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-landing-page", "description": "Ripple mappings and components for Tide landing-page Content type", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-tide-media/package.json b/packages/ripple-tide-media/package.json index de08760eb..0563f079e 100644 --- a/packages/ripple-tide-media/package.json +++ b/packages/ripple-tide-media/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-media", "description": "Ripple mappings and components for Tide media", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-tide-news/package.json b/packages/ripple-tide-news/package.json index 62415a9a6..3dfc00247 100644 --- a/packages/ripple-tide-news/package.json +++ b/packages/ripple-tide-news/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-news", "description": "Ripple mappings and components for Tide News content type", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-tide-publication/package.json b/packages/ripple-tide-publication/package.json index 3241a5788..ad5f18459 100644 --- a/packages/ripple-tide-publication/package.json +++ b/packages/ripple-tide-publication/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-publication", "description": "Ripple mappings and components for Tide Publication Content type", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-tide-search/package.json b/packages/ripple-tide-search/package.json index 984e9b2b3..52619d93c 100644 --- a/packages/ripple-tide-search/package.json +++ b/packages/ripple-tide-search/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-search", "description": "Ripple search UI and services for connecting to Tide search", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-tide-topic/package.json b/packages/ripple-tide-topic/package.json index 800a95cd5..2074c4d12 100644 --- a/packages/ripple-tide-topic/package.json +++ b/packages/ripple-tide-topic/package.json @@ -9,7 +9,7 @@ "./mapping": "./mapping/index.ts", "./types": "./types.ts" }, - "version": "2.45.0", + "version": "2.45.1", "dependencies": { "@dpc-sdp/nuxt-ripple": "workspace:*", "@dpc-sdp/ripple-tide-api": "workspace:*", diff --git a/packages/ripple-tide-webform/package.json b/packages/ripple-tide-webform/package.json index 03489e2db..5cf86f8c3 100644 --- a/packages/ripple-tide-webform/package.json +++ b/packages/ripple-tide-webform/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-tide-webform", "description": "Ripple mappings and components for Tide webforms", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./nuxt.config.ts", diff --git a/packages/ripple-ui-core/package.json b/packages/ripple-ui-core/package.json index 41cd4642f..16087e12c 100644 --- a/packages/ripple-ui-core/package.json +++ b/packages/ripple-ui-core/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-ui-core", "description": "Ripple UI Core component library", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "files": [ diff --git a/packages/ripple-ui-forms/package.json b/packages/ripple-ui-forms/package.json index 9724bcfe0..e667e8045 100644 --- a/packages/ripple-ui-forms/package.json +++ b/packages/ripple-ui-forms/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-ui-forms", "description": "A form component library built with Formkit", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "./dist/rpl-forms.umd.js", diff --git a/packages/ripple-ui-maps/package.json b/packages/ripple-ui-maps/package.json index e6b95b9d6..437f98445 100644 --- a/packages/ripple-ui-maps/package.json +++ b/packages/ripple-ui-maps/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/ripple-ui-maps", "description": "Ripple UI Core component library", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "files": [ diff --git a/packages/stylelint-config-ripple/package.json b/packages/stylelint-config-ripple/package.json index 1dd1e2174..2098b3b43 100644 --- a/packages/stylelint-config-ripple/package.json +++ b/packages/stylelint-config-ripple/package.json @@ -1,7 +1,7 @@ { "name": "@dpc-sdp/stylelint-config-ripple", "description": "ESLint config for Ripple projects", - "version": "2.45.0", + "version": "2.45.1", "license": "Apache-2.0", "repository": "https://github.com/dpc-sdp/ripple-framework", "main": "index.js",