TINY-12690: add skin with modern css enabled#10544
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the WalkthroughIntroduces a new experimental UI skin enabling CSS custom properties, adds related LESS files and imports, and updates the Grunt build skin map to include the new skin alias. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
Status, Documentation and Community
|
This stack of pull requests is managed by Graphite. Learn more about stacking. |
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (4)
modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/content.inline.less (1)
1-1: Enable CSS custom properties in content.inline.less
Define@custom-properties-enabledbefore importing the theme so that content builds emit CSS variables as expected.• File: modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/content.inline.less
Apply:-@import 'src/less/theme/content-ui'; +@custom-properties-enabled: true; +@import 'src/less/theme/content-ui';modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/content.less (2)
1-1: Place feature toggles before imports to avoid surprises.Define the flag before the import so the theme can reliably switch to emitting CSS custom properties during compilation.
Apply this diff:
-@import 'src/less/theme/content-ui'; +@custom-properties-enabled: true; +@import 'src/less/theme/content-ui';
3-9: Use theme font‐stack token in experimental skinThe theme already defines a global Less variable and CSS custom-property for the font stack:
@font-stackin modules/oxide/src/less/theme/globals/global-variables.less--tox-private-font-stack(with fallback@font-stack) in modules/oxide/src/less/theme/globals/tinymce.lessPlease update your skin’s content.less to use these tokens instead of hardcoding
sans-serif.• File: modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/content.less
body { - font-family: sans-serif; + font-family: var(--tox-private-font-stack, @font-stack); } table { border-collapse: collapse; }This ensures changes to the design system propagate across all skins.
modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/skin.less (1)
1-7: Move@custom-properties-enabledbefore the import for deterministic behavior.Less variables are lazily evaluated but guards/mixins may consult flags during import resolution. Defining the toggle up-front avoids subtle ordering pitfalls.
Apply this diff:
-@import 'src/less/theme/theme'; - -// -// Place your variables here -// - -@custom-properties-enabled: true; +@custom-properties-enabled: true; +@import 'src/less/theme/theme'; + +// +// Place your variables here +//
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Knowledge Base: Disabled due to Reviews > Disable Knowledge Base setting
📒 Files selected for processing (5)
modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/content.inline.less(1 hunks)modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/content.less(1 hunks)modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/skin.less(1 hunks)modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/skin.shadowdom.less(1 hunks)modules/tinymce/Gruntfile.js(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (10)
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: task-list-completed
- GitHub Check: Analyze (javascript)
🔇 Additional comments (2)
modules/oxide/src/less/skins/ui/experimental-css-custom-props-enabled/skin.shadowdom.less (1)
1-1: No changes needed: Shadow DOM theme doesn’t read the custom-properties flag
After inspectingmodules/oxide/src/less/theme/shadowdom.less, it has no conditional logic based on@custom-properties-enabled. Adding+@custom-properties-enabled: true;before importing it in
skin.shadowdom.lesswould have no effect today. We can leave the import as-is and revisit if the theme ever honours the flag.modules/tinymce/Gruntfile.js (1)
34-36: Mapping addition looks correct and consistent with the build copy task.The new alias will be picked up by copy:ui-skins (cwd uses the value, dest uses the key), so
experimental-css-custom-props-enabledshould be packaged tojs/tinymce/skins/ui/experimental-css-custom-props-enabled.
accd4f3 to
690b08c
Compare
Related Ticket: TINY-12690 Description of Changes: - Added a new skin that enables CSS custom properties - Updated the oxideUiSkinMap in Gruntfile.js to include the new skin Pre-checks: - [x] ~~Changelog entry added~~ - [x] ~~Tests have been added (if applicable)~~ - [x] Branch prefixed with `feature/`, `hotfix/`or `spike/` Review: - [x] ~~Milestone set~~ - [x] ~~Docs ticket created (if applicable)~~ GitHub issues (if applicable): <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - New Features - Introduced an experimental UI skin that enables CSS custom properties for enhanced theming flexibility. - Includes base typography updates (sans-serif body) and refined table rendering (collapsed borders). - Shadow DOM styling support included for consistent component theming. - Available via a new skin alias to simplify selection in builds and configurations. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
Related Ticket: TINY-12690 Description of Changes: - Added a new skin that enables CSS custom properties - Updated the oxideUiSkinMap in Gruntfile.js to include the new skin Pre-checks: - [x] ~~Changelog entry added~~ - [x] ~~Tests have been added (if applicable)~~ - [x] Branch prefixed with `feature/`, `hotfix/`or `spike/` Review: - [x] ~~Milestone set~~ - [x] ~~Docs ticket created (if applicable)~~ GitHub issues (if applicable): <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - New Features - Introduced an experimental UI skin that enables CSS custom properties for enhanced theming flexibility. - Includes base typography updates (sans-serif body) and refined table rendering (collapsed borders). - Shadow DOM styling support included for consistent component theming. - Available via a new skin alias to simplify selection in builds and configurations. <!-- end of auto-generated comment: release notes by coderabbit.ai -->

Related Ticket: TINY-12690
Description of Changes:
Pre-checks:
Changelog entry addedTests have been added (if applicable)feature/,hotfix/orspike/Review:
Milestone setDocs ticket created (if applicable)GitHub issues (if applicable):
Summary by CodeRabbit