feat(SDK): Update SDK Library and UVE search bar to Use "personaId" Key #31295
Merged
rjvelazco merged 10 commits intoFeb 3, 2025
Merged
Conversation
4 tasks
4 tasks
fmontes
requested changes
Feb 3, 2025
…rsonaid-key-to-main
zJaaal
requested changes
Feb 3, 2025
…-to-main' of https://github.com/dotCMS/core into issue-28819-sdk-update-sdk-library-to-use-personaid-key-to-main
fmontes
approved these changes
Feb 3, 2025
zJaaal
approved these changes
Feb 3, 2025
hmoreras
approved these changes
Feb 3, 2025
spbolton
pushed a commit
that referenced
this pull request
Jun 20, 2025
…ey (#31295) This pull request includes several updates to the `dot-ema-shell` and related components in the `core-web` library. The primary focus is on refactoring the code to use a new constant `PERSONA_KEY` instead of hardcoded persona identifiers and improving the handling of query parameters. ### Refactoring for `PERSONA_KEY` usage: * [`dot-ema-shell.component.spec.ts`](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L49-R49): Replaced hardcoded persona identifiers with `PERSONA_KEY` in multiple test cases. [[1]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L49-R49) [[2]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L118-R118) [[3]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L333-R333) [[4]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L358-R358) [[5]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L379-R379) [[6]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L480-R480) [[7]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L533-R559) [[8]](diffhunk://#diff-8843e3a4ce8c16e83408b1a6dcc3ad54eaddd17f8e986bbdb502e11bd4446ab4L839-R847) * [`dot-uve-toolbar.component.spec.ts`](diffhunk://#diff-3eaa147616a5d1ff374a5fa27b0f38f0159a9039ef7e8d672dec43631f48a9e1L40-L50): Updated tests to use `PERSONA_KEY` for persona-related parameters. [[1]](diffhunk://#diff-3eaa147616a5d1ff374a5fa27b0f38f0159a9039ef7e8d672dec43631f48a9e1L40-L50) [[2]](diffhunk://#diff-3eaa147616a5d1ff374a5fa27b0f38f0159a9039ef7e8d672dec43631f48a9e1L474-R474) * [`edit-ema-editor.component.spec.ts`](diffhunk://#diff-34ddc5fbacaf04b962f2037385ed284310d5faf35ba409d5705b2caadd5d796aL399-R399): Modified tests to replace hardcoded persona identifiers with `PERSONA_KEY`. [[1]](diffhunk://#diff-34ddc5fbacaf04b962f2037385ed284310d5faf35ba409d5705b2caadd5d796aL399-R399) [[2]](diffhunk://#diff-34ddc5fbacaf04b962f2037385ed284310d5faf35ba409d5705b2caadd5d796aL445-R445) [[3]](diffhunk://#diff-34ddc5fbacaf04b962f2037385ed284310d5faf35ba409d5705b2caadd5d796aL467-R467) ### Codebase improvements: * [`dot-ema-shell.component.ts`](diffhunk://#diff-677330662fea6dadc7e48fd8455ec2a6fe60d624c7ed1f01f0a3e985aacd05c6R40): Introduced the `normalizeQueryParams` utility function to streamline query parameter handling and ensure consistency. [[1]](diffhunk://#diff-677330662fea6dadc7e48fd8455ec2a6fe60d624c7ed1f01f0a3e985aacd05c6R40) [[2]](diffhunk://#diff-677330662fea6dadc7e48fd8455ec2a6fe60d624c7ed1f01f0a3e985aacd05c6L104-L121) * [`dot-uve-toolbar.component.ts`](diffhunk://#diff-217a9e619d6590c4f652e85353b9637ba5e464ddeb0424be35aef39bb8dceb30L201-R232): Refactored the `onPersonaSelected` method to use `PERSONA_KEY` and improved the confirmation dialog logic for persona selection. [[1]](diffhunk://#diff-217a9e619d6590c4f652e85353b9637ba5e464ddeb0424be35aef39bb8dceb30L201-R232) [[2]](diffhunk://#diff-217a9e619d6590c4f652e85353b9637ba5e464ddeb0424be35aef39bb8dceb30L268-R268) ### Utility function updates: * Replaced `createPageApiUrlWithQueryParams` with `buildFullPageURL` in multiple test files to enhance URL handling and consistency. [[1]](diffhunk://#diff-652f846aa914e51df03471614a9ffc9b80757f275a3639fe1131def21c40b39dL23-R23) [[2]](diffhunk://#diff-652f846aa914e51df03471614a9ffc9b80757f275a3639fe1131def21c40b39dL33-R33) [[3]](diffhunk://#diff-3eaa147616a5d1ff374a5fa27b0f38f0159a9039ef7e8d672dec43631f48a9e1L59-R59) These changes ensure that the codebase is more maintainable and consistent, particularly in handling persona-related parameters and query parameters. ### Video https://github.com/user-attachments/assets/df074781-d62f-4c5a-993a-3363e17109e2
This was referenced Jul 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request includes several updates to the
dot-ema-shelland related components in thecore-weblibrary. The primary focus is on refactoring the code to use a new constantPERSONA_KEYinstead of hardcoded persona identifiers and improving the handling of query parameters.Refactoring for
PERSONA_KEYusage:dot-ema-shell.component.spec.ts: Replaced hardcoded persona identifiers withPERSONA_KEYin multiple test cases. [1] [2] [3] [4] [5] [6] [7] [8]dot-uve-toolbar.component.spec.ts: Updated tests to usePERSONA_KEYfor persona-related parameters. [1] [2]edit-ema-editor.component.spec.ts: Modified tests to replace hardcoded persona identifiers withPERSONA_KEY. [1] [2] [3]Codebase improvements:
dot-ema-shell.component.ts: Introduced thenormalizeQueryParamsutility function to streamline query parameter handling and ensure consistency. [1] [2]dot-uve-toolbar.component.ts: Refactored theonPersonaSelectedmethod to usePERSONA_KEYand improved the confirmation dialog logic for persona selection. [1] [2]Utility function updates:
createPageApiUrlWithQueryParamswithbuildFullPageURLin multiple test files to enhance URL handling and consistency. [1] [2] [3]These changes ensure that the codebase is more maintainable and consistent, particularly in handling persona-related parameters and query parameters.
Video
issue-28819-sdk-update-sdk-library-to-use-personaid-key-to-main.mov
This PR fixes: #28819