- Issue created by @vml-bsummers
- Merge request !5Edit UIStyleOptions.php to use UI Styles Source Plugins β (Open) created by Unnamed author
UI Styles Paragraphs module doesn't show color previews in forms. It always uses a basic dropdown without previews, even when preview settings are defined in the YAML file.
1. Install UI Styles and UI Styles Paragraphs modules
2. Add background colors in a theme's YAML file with preview settings
3. Enable these styles for paragraphs
4. Edit a paragraph and see that there are no color previews in the form
Update the UIStyleOptions class to use the UI Styles source plugins. This will:
1. Add the source plugin manager to the class
2. Find the right plugin for each style
3. Use that plugin to create the form element with previews
4. Fall back to a basic dropdown if no plugin works
1. Test the patch on different sites
2. Check that all source plugins work correctly
3. Update documentation
Forms will now show visual previews for styles:
- Background colors will show color swatches
- Text alignments could show alignment icons
- Spacing options could show spacing indicators
This makes it easier for editors to pick the right option.
No API changes.
No data model changes.
Active
1.1
Code