Skip to content
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

[Mobile][Web] [Desktop] List for different icons #1255

Closed
EgorK0rshun opened this issue Jun 6, 2023 · 4 comments
Closed

[Mobile][Web] [Desktop] List for different icons #1255

EgorK0rshun opened this issue Jun 6, 2023 · 4 comments

Comments

@EgorK0rshun
Copy link
Contributor

it's possible to use your own symbols for lists?
there is an attribute implementation for a list with accepted value ,

class ListAttribute extends Attribute<String?> {
  const ListAttribute(String? val) : super('list', AttributeScope.BLOCK, val);
}

but if you specify any value other than the available values, the list is a characterless construct.

Right now the implementation is only for lists with dots, numbers and checkboxes. What can I override, so that for the attribute to match my widget to the left of the text in the list.
there is only one validation in text_block.dart

if (attrs[Attribute.list.key] == Attribute.ol) {
  return QuillNumberPoint(
if (attrs[Attribute.list.key] == Attribute.ul) {
  return QuillBulletPoint(
if (attrs[Attribute.list.key] == Attribute.checked) {
 return CheckboxPoint(
if (attrs.containsKey(Attribute.codeBlock.key)) {
return QuillNumberPoint(

There was an issue about checkboxes, I would like to have this for icons passed by ColorAttribute example.
Do you plan to change the interaction with the lists a little bit soon?

@hoangsang17th
Copy link
Contributor

You can follow below the code

image
image

@EgorK0rshun
Copy link
Contributor Author

EgorK0rshun commented Jun 30, 2023

@hoangsang17th ,I'll try, thank u!
maybe you know if you can somehow get around the problem with the fact that after applying the AlignAttribute, the left side of the lists (icons) remains in the same place?

@hoangsang17th
Copy link
Contributor

@EgorK0rshun Sorry for this delay!
I don't have the answer, please close this issue and open a new issue for your question.

@EgorK0rshun
Copy link
Contributor Author

#1258

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants