-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Improving the List block with cosmetic list types #45830
Comments
Hi, |
We decided we should migrate the list type option to CSS, so that opens the door to add more types! #53301 (comment) |
With #53301, if the list type is output as inline CSS and if we provide an appropriate UI (such as a text field to enter a value in addition to the select element), you can theoretically use various things including emojis. Various ideas have been suggested in #17738, but for core functionality, I think it's better to limit to adding simple styles as defined in MDN. Developers wanting a more complex list type can do so with block style, for example: register_block_style(
'core/list',
array(
'name' => 'checkmark',
'label' => 'Checkmark',
'inline_style' => 'ol.is-style-checkmark { list-style-type: "\2705"; }',
)
);
register_block_style(
'core/list',
array(
'name' => 'circle-alpha',
'label' => 'Circle Alpha',
'inline_style' => '@counter-style circle-alpha { system: fixed; symbols: Ⓐ Ⓑ Ⓒ Ⓓ Ⓔ Ⓕ Ⓖ; suffix: " "; } ol.is-style-circle { list-style: circle-alpha; }',
)
); Alternatively, you may be able to add your own list-type dropdown to the block toolbar via hooks. |
Pulled from this prior issue around improving the overall list block #17738 (comment) this issue is specifically for cosmetic list types, like checks, stars, pins, emojis, etc. Specifically quoting @druxstr:
Let's continue the conversation here to better focus each for consideration.
The text was updated successfully, but these errors were encountered: