Add ContentTypeManagement widget to ui.xml#3903
Add ContentTypeManagement widget to ui.xml#3903jmendeza wants to merge 1 commit intocraftercms:developfrom
Conversation
WalkthroughThis change introduces a new Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
src/main/resources/crafter/studio/upgrade/pipelines.yaml (1)
1365-1367: Misleading commit message.The
commitDetailssays "Update the UI to use new icons for dashboard widgets" but the actual change performed byui-v5.0.0.1.xsltis injecting thecraftercms.components.ContentTypeManagementwidget. Consider updating to accurately describe the change, e.g., "Add ContentTypeManagement widget to ui.xml".Suggested fix
- currentVersion: 5.0.0.0 nextVersion: 5.0.0.1 operations: - type: xsltFileUpgrader template: crafter/studio/upgrade/5.0.x/config/ui/ui-v5.0.0.1.xslt - commitDetails: Update the UI to use new icons for dashboard widgets + commitDetails: Add ContentTypeManagement widget to ui.xml🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/main/resources/crafter/studio/upgrade/pipelines.yaml` around lines 1365 - 1367, The commitDetails for the xsltFileUpgrader entry referencing template crafter/studio/upgrade/5.0.x/config/ui/ui-v5.0.0.1.xslt is misleading; change the commitDetails string from "Update the UI to use new icons for dashboard widgets" to an accurate description such as "Add ContentTypeManagement widget to ui.xml" so it reflects that the XSLT injects the craftercms.components.ContentTypeManagement widget.src/main/webapp/repo-bootstrap/global/blueprints/1000_website_editorial/config/studio/ui.xml (1)
394-479: Add ContentTypeManagement widget definition to other blueprints for consistency.The
2000_headless_store,4000_empty, and5000_headless_blogblueprints referencecraftercms.components.ContentTypeManagementas a tool with only a self-closing widget tag, while1000_website_editorialincludes the full widget definition with configuration for objectTypes (page and component). Adding the widget definition to the other blueprints would align their configuration with1000_website_editorial.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/main/webapp/repo-bootstrap/global/blueprints/1000_website_editorial/config/studio/ui.xml` around lines 394 - 479, The other blueprints (2000_headless_store, 4000_empty, 5000_headless_blog) only include a self-closing <widget id="craftercms.components.ContentTypeManagement" /> while 1000_website_editorial defines the full widget with <configuration> containing <objectTypes id="page"> and <objectTypes id="component">; update those blueprints to replace the self-closing widget with the full ContentTypeManagement widget definition copied from 1000_website_editorial (including the page and component <descriptor> entries, fields like file-name, internal-name, navLabel, placeInNav, and the System Properties <sections>) so all blueprints share the same configured craftercms.components.ContentTypeManagement widget.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@src/main/resources/crafter/studio/upgrade/pipelines.yaml`:
- Around line 1365-1367: The commitDetails for the xsltFileUpgrader entry
referencing template crafter/studio/upgrade/5.0.x/config/ui/ui-v5.0.0.1.xslt is
misleading; change the commitDetails string from "Update the UI to use new icons
for dashboard widgets" to an accurate description such as "Add
ContentTypeManagement widget to ui.xml" so it reflects that the XSLT injects the
craftercms.components.ContentTypeManagement widget.
In
`@src/main/webapp/repo-bootstrap/global/blueprints/1000_website_editorial/config/studio/ui.xml`:
- Around line 394-479: The other blueprints (2000_headless_store, 4000_empty,
5000_headless_blog) only include a self-closing <widget
id="craftercms.components.ContentTypeManagement" /> while 1000_website_editorial
defines the full widget with <configuration> containing <objectTypes id="page">
and <objectTypes id="component">; update those blueprints to replace the
self-closing widget with the full ContentTypeManagement widget definition copied
from 1000_website_editorial (including the page and component <descriptor>
entries, fields like file-name, internal-name, navLabel, placeInNav, and the
System Properties <sections>) so all blueprints share the same configured
craftercms.components.ContentTypeManagement widget.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 4c373df2-5efd-48b6-a71e-0cb765884d68
📒 Files selected for processing (7)
src/main/resources/crafter/studio/upgrade/5.0.x/config/ui/ui-v5.0.0.1.xsltsrc/main/resources/crafter/studio/upgrade/pipelines.yamlsrc/main/webapp/repo-bootstrap/global/blueprints/1000_website_editorial/config/studio/ui.xmlsrc/main/webapp/repo-bootstrap/global/configuration/samples/sample-ui.xmlsrc/test/java/org/craftercms/studio/XsltTest.javasrc/test/resources/crafter/studio/upgrade/xslt/ui/v5.0/5.0.0.1/expected.xmlsrc/test/resources/crafter/studio/upgrade/xslt/ui/v5.0/5.0.0.1/input.xml
Add ContentTypeManagement widget to ui.xml
craftercms/craftercms#8496
Summary by CodeRabbit
Release Notes
New Features
Tests