feat(uve): open new edit content dialog from UVE when feature flag is enabled#35572
Merged
adrianjm-dotCMS merged 8 commits intoMay 11, 2026
Conversation
… enabled - In `edit-ema-editor`, check content type metadata for the new editor feature flag before opening the edit dialog; opens `DotEditContentDialogComponent` when enabled, falls back to the legacy dialog otherwise - Skip global breadcrumb updates when the edit content store runs in dialog mode to prevent duplicate breadcrumb trails stacking on top of UVE - Export `DotEditContentDialogComponent` and `EditContentDialogData` from the `@dotcms/edit-content` barrel to allow static imports and remove the dynamic `await import(...)` that was incorrectly flagging the library as lazy-loaded Closes #33235 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
8 tasks
This comment was marked as resolved.
This comment was marked as resolved.
- Introduced checks to prevent GlobalStore.addNewBreadcrumb from being called when in dialog mode, avoiding duplicate breadcrumb entries. - Added unit tests to verify that breadcrumbs are not added during dialog mode for both new and existing content initialization. - Refactored content feature specifications to include the new global store behavior. This change enhances user experience by ensuring breadcrumb navigation remains clear and concise when using dialog overlays.
- Implemented a new method to open the edit content dialog conditionally based on the `CONTENT_EDITOR2_ENABLED` feature flag. If enabled, the new dialog is opened; otherwise, it falls back to the legacy dialog. - Updated the `placeItem` and `handleNgEvent` methods to utilize the new dialog handling logic. - Added unit tests to ensure correct dialog behavior for both enabled and disabled states of the feature flag. This change improves the user experience by providing a more flexible and context-aware content editing workflow.
dario-daza
approved these changes
May 5, 2026
- Updated unit tests for `EditEmaEditorComponent` to remove the `actionPayload` property from the expectations, as it was not necessary for the test assertions. - This change simplifies the test cases and focuses on the relevant properties being validated. No functional changes were made to the component itself; this is purely a cleanup of the test specifications.
zJaaal
reviewed
May 6, 2026
- Enhanced the `#openNewContentDialogOrFallback` method to streamline the logic for opening new content dialogs based on content type. - Updated the `placeItem` and `handleNgEvent` methods to utilize the new dialog handling approach, improving readability and maintainability. - This change simplifies the process of determining which dialog to open, enhancing the overall user experience in the content editing workflow.
zJaaal
reviewed
May 6, 2026
- Updated the `#openNewContentDialogOrFallback` method to use a single `item` object for better clarity and maintainability. - Enhanced the handling of content type variables and names, improving the readability of the dialog opening logic. - Added documentation comments for the `#openNewContentDialogOrFallback` and `#openDotEditContentShell` methods to clarify their functionality. This refactor contributes to a more cohesive and understandable codebase for content dialog management.
- Keep both dotContentTypeService and dotCopyContentModalService injections in edit-ema-editor.component.ts - Use origin/main imports in dot-uve-contentlet-quick-edit.component.spec.ts (new component architecture) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Replace `{} as unknown as DotCMSContentType` with `createFakeContentType()`
across 6 test cases for type-safe and DRY test data
- Fix store.setActiveContentlet → store.setSelected (method does not exist)
- Remove unused DotCMSContentType import
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
4 tasks
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.
What changed
edit-ema-editor: When a user clicks to edit a contentlet in the UVE, the editor now checks the content type's feature flag (FEATURE_FLAG_CONTENT_EDITOR2_ENABLED) before deciding which dialog to open. If the flag is enabled, it opens the new Angular-basedDotEditContentDialogComponent; otherwise it falls back to the legacy dialog.content.feature: Skip global breadcrumb updates when the edit content store runs in dialog mode to prevent duplicate breadcrumb trails from stacking on top of the UVE shell breadcrumb.@dotcms/edit-contentbarrel: ExportDotEditContentDialogComponentandEditContentDialogDatafromsrc/index.ts. This also removes theawait import(...)dynamic import that was incorrectly marking the entireedit-contentlibrary as lazy-loaded, which was causing@nx/enforce-module-boundarieslint errors.Screen.Recording.2026-05-06.at.10.09.30.AM.mov
Test plan
FEATURE_FLAG_CONTENT_EDITOR2_ENABLED = true→ new Angular dialog opensyarn nx affected -t lint --base=origin/main→ 0 errorsCloses #33235
This PR fixes: #33235