-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Table properties UI] Implement a rich color picker for table (and table cell) properties #6106
Comments
Internal: Moved `normalizeColorOptions()` and `getLocalizedColorOptions()` from `ckeditor5-font` (see ckeditor/ckeditor5/issues/6106).
Other: Moved `normalizeColorOptions()` and `getLocalizedColorOptions()` to `ckeditor5-ui` (see ckeditor/ckeditor5/issues/6106). MINOR BREAKING CHANGE: `normalizeColorOptions()` and `getLocalizedColorOptions()` are no longer available in this package. You can import them from `@ckeditor/ckeditor5-ui/src/colorgrid/utils` instead.
I wanted to move the talk about configuration here (might be an immediate follow-up). Quoting @oleq :
1. NamespacesI think that we probably could match configuration option with the model names (command name): config.table.tableProperties = {
backgroundColors: [],
borderColors: []
} 2. Fallbacks (default options).Also, for me, it would be nice to provide some sane fallbacks so if one would like to override default configuration it would require to change only one value - assuming setting new palette for tables. It might be nice to make So taking the above example this setting would set also Another thing that came to my mind is that maybe we could ease developers and provide another fallback so it would require only one value to change. Maybe This fallback behavior is not so hard to do using variables passed to the config, but anyway some enhancement. |
I don't think this is necessary. If you want to change all options, you do that: const colors = [ ... ];
Editor.create( el, {
tableProperties: {
backgroundColors: colors,
borderColors: colors
},
tableCellProperties: {
backgroundColors: colors,
borderColors: colors
}
} ) If anything, we could later introduce something like |
Like it 👍 |
I decided to have |
A bit, IMO. This will work fine as well: tableCellProperties.borderColors
tableCellProperties.borderStyles
tableCellProperties.backgroundColors Less nesting, lest objects (interfaces) to describe. We won't have 100 options in |
Internal: Introduced color pickers in the table and table cell property forms. Introduced config.table.tableProperties and config.table.tableCellProperties configurations. Closes ckeditor/ckeditor5/issues/6106.
Feature: Added styles for the color input (see ckeditor/ckeditor5/issues/6106).
📝 Provide a description of the new feature
A follow-up of #6049.
ATM
Should be
with a color palette (see: font color) popping up when the color is clicked. The rich color input should become the ckeditor5-ui component.
If you'd like to see this feature implemented, add a 👍 reaction to this post.
The text was updated successfully, but these errors were encountered: