Global Elements: Implements auditLog and contentRollback kinds for History and Rollback#22633
Merged
nielslyngsoe merged 8 commits intoMay 4, 2026
Merged
Conversation
This comment was marked as low quality.
This comment was marked as low quality.
auditLog and contentRollback kinds for History and RollbackauditLog and contentRollback kinds for History and Rollback
Contributor
There was a problem hiding this comment.
Pull request overview
This PR migrates the Element workspace History and Rollback features to the shared auditLog workspaceInfoApp kind and shared contentRollback entity/audit-log action kinds, removing element-specific duplicated UI/action code and aligning Element behavior with other content types.
Changes:
- Replaces the bespoke Element History info app with the shared
workspaceInfoAppkindauditLog, backed by a new Element audit-log repository. - Replaces the bespoke Element Rollback modal/entity-action with shared
contentRollbackentityAction andauditLogActionkinds, and aligns the Element rollback repository toUmbContentRollbackRepository. - Refactors Element audit-log tag metadata selection into a frozen lookup map and exposes it via
getTagStyleAndText().
Reviewed changes
Copilot reviewed 19 out of 19 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/repository/rollback.server.data-source.ts | Updates rollback data-source docs (and continues to call management API endpoints for element versions). |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/repository/rollback.repository.ts | Adopts UmbContentRollbackRepository and normalizes returned data to the shared rollback models. |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/modal/types.ts | Removes element-specific rollback modal types (modal removed). |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/modal/rollback-modal.element.ts | Removes bespoke element rollback modal implementation (replaced by shared rollback modal machinery). |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/modal/manifests.ts | Removes modal manifest registration for the deleted element rollback modal. |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/modal/constants.ts | Removes modal token/constants for the deleted element rollback modal. |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/manifests.ts | Registers new rollback-related manifests (adds audit-log action manifests; removes modal manifests). |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/entity-action/rollback.action.ts | Removes bespoke rollback entity action implementation (replaced by kind-based action). |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/entity-action/manifests.ts | Switches Element rollback entity action to shared contentRollback kind with repo aliases and conditions. |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/constants.ts | Stops re-exporting removed modal constants; keeps repository constants export. |
| src/Umbraco.Web.UI.Client/src/packages/elements/rollback/audit-log-action/manifests.ts | Adds shared contentRollback audit-log action for Elements in History header actions. |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/repository/manifests.ts | Registers the Element audit-log repository extension. |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/repository/element-audit-log.repository.ts | Adds getTagStyleAndText() backed by a frozen lookup map for shared audit-log UI rendering. |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/repository/constants.ts | Introduces the Element audit-log repository alias constant. |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/manifests.ts | Includes repository manifests alongside info-app manifests for Elements audit-log. |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/info-app/utils.ts | Removes bespoke tag-style helper (now provided by repository via getTagStyleAndText()). |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/info-app/manifests.ts | Migrates Element History info app to shared auditLog kind and wires repository alias via meta. |
| src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/info-app/element-history-workspace-info-app.element.ts | Removes bespoke Element history info-app element (replaced by shared audit-log info app). |
| src/Umbraco.Web.UI.Client/src/assets/lang/en.ts | Adds rollback_elementRolledBack localization string (for upcoming/shared rollback notification improvements). |
…ackoffice/element` Surfaces the constant through the element audit-log barrel so it's available on the public package entry, matching the documents audit-log pattern.
…history # Conflicts: # src/Umbraco.Web.UI.Client/src/packages/elements/audit-log/info-app/element-history-workspace-info-app.element.ts
nielslyngsoe
approved these changes
May 4, 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.
Description
Implements the
auditLogkind for the Audit Log History workspace info app, and implementscontentRollbackkind for the "Rollback" button that appears on that workspace info app and opens the reusable Rollback modal.Summary
auditLogworkspaceInfoApp kind (matching the pattern already used by Documents, Media, and Document Blueprints).contentRollbackentityAction andauditLogActionkinds, replacing the duplicated rollback modal/action with the shared content rollback machinery.UmbElementRollbackRepositorywith theUmbContentRollbackRepositoryinterface.UmbElementAuditLogRepository.getTagStyleAndTextto use a frozen lookup map (reduces cyclomatic complexity).Net result: ~800 fewer lines of element-specific duplication while bringing the Element workspace in line with the standard content audit-log/rollback UX.
Notes
rollback_documentRolledBacklocalization key. But once PR Content Rollback: Add notification message meta property #22631 is merged in (andmainis merged upstream intov18/dev), this will use the correct localization key.Test plan