-
-
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
Implement UI part for List Styles feature #7803
Comments
Blindly estimated as 2. |
DesignsUnordered list stylesOrdered list stylesButton statesI followed the hover styles first implemented in special characters and combined them with heading dropdown active styles. The question of default/revertContext and Problem StatementMy designs contain the "reset/default/revert" button although I haven't found any WYSIWYG editor out there that would use such a thing. I wanted to see how would it look. The button is a tricky thing because it's a feature of CSS world but a potential UX anti-pattern. Decision drivers
Considered optionsUse the "reset" button
Don't use the "reset" button
Pros and Cons of the OptionsOption 1 (use the "reset" button)👍 The button is logical from the CSS perspective – removing the inline style falls back to the inherited (UA) style and this makes sense. 👎 The button is totally illogical from the UX perspective – you need to understand CSS to know what's going on there. Non-technical users will be confused about what it is for – they see a numbered list in the content but the numbered list button is not active. Why? (they do not know that the style isn't in the model, it's just a UA/CMS default list style) 👎 No one uses this kind of button in their UI. Option 2 (do not use the button)👍 There is no confusion around what the button is for because... there is no button. 👍 Cleaner, uncluttered UI. 👎 If we go with the "no style in the model, no active button" approach, users may be confused why their list is numbered but "numbered" style in the drop-down is inactive (they don't know its a browser/CMS default style being rendered). 👎 If we go with the "no style in the model, activate the most likely button" approach, users may be confused why their list is numbered using roman letters (I. II. III.) but the Arabic (1. 2. 3.) style in the drop-down is active (the default browser/CMS style for 👎 (unlikely) But if someone wanted to reset their list style back to the browser/CMS default, they have to discover they need to click the active style again (low discoverability). |
If we are voting, then I'm for the 2nd option.
The same happens for the font family feature when
Users always can use the "Remove Format" button. |
A side-question to @pomek: Do the list styles have the |
Thanks @oleq for the research. I think I'd go with the 2nd option as well. I feel that we can always add the reset button if we see that "click the active option to remove" is not discoverable.
This applies to both options, right?
OK, now I understand the previous point :D Yeah... I think I'm for "no style in the model, no active button". |
Not yet but I'll add it. |
Internal (list): Created the list styles UI. Closes #7803.
Done in #7845. |
Feature (list): Introduced the list styles feature that allows customizing the list's marker of the list item elements. Closes #7801. Feature (theme-lark): Creates styles for the `ListStylesUI` plugin (see #7803). MINOR BREAKING CHANGE (ui): It is now possible to override existing components when [adding new ones](https://ckeditor.com/docs/ckeditor5/latest/api/module_ui_componentfactory-ComponentFactory.html#function-add) to the [component factory](https://ckeditor.com/docs/ckeditor5/latest/api/module_ui_componentfactory-ComponentFactory.html) (previously an error was thrown) (see #7803).
Part of #1031.
The text was updated successfully, but these errors were encountered: