fix(uve): Fixed API button on toolbar #31136
Merged
+79
−35
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.
Screen.Recording.2025-01-14.at.6.57.49.PM.mov
This pull request introduces several changes to improve URL sanitization and testing within the
dot-ema-shell
component and related files. The most important changes include adding URL sanitization logic, updating tests to reflect these changes, and removing redundant code.URL Sanitization:
core-web/libs/portlets/edit-ema/portlet/src/lib/dot-ema-shell/dot-ema-shell.component.ts
: Added thesanitizeURL
function to sanitize URLs before further processing.core-web/libs/portlets/edit-ema/portlet/src/lib/services/guards/edit-ema.guard.ts
: Removed thesanitizeURL
import and related code, as the sanitization is now handled elsewhere. [1] [2]Testing Updates:
core-web/libs/portlets/edit-ema/portlet/src/lib/dot-ema-shell/dot-ema-shell.component.spec.ts
: Added new test cases to verify URL sanitization whenloadPageAsset
is called with different URL formats.core-web/libs/portlets/edit-ema/portlet/src/lib/services/guards/edit-ema.guard.spec.ts
: Updated test cases to reflect the changes in URL sanitization logic.Code Cleanup:
core-web/libs/portlets/edit-ema/portlet/src/lib/store/features/load/withLoad.ts
: Added a comment suggesting the use ofretryWhen()
for potential future improvements.This PR fixes: #31118