flutter-quill icon indicating copy to clipboard operation
flutter-quill copied to clipboard

Adding some kind of identifier for "select header style buttons" configuration in the `childBuilder`'s extra options

Open ghost opened this issue 1 year ago • 2 comments

Is there an existing issue for this?

Use case

I'm adding custom buttons for all the editor's possible styling options (bold, header, etc.), but then I discovered there's no way to differentiate the header style buttons. If I want to put custom buttons, I need to know which button this is (header, h1, h2, or h3) in order to display the correct "icon" and to display if it is selected.

Proposal

I suggest adding a Header enum that consist of header/n, h1, h2 & h3, and adding this and a bool isSelected to QuillToolbarSelectHeaderStyleButtonsExtraOptions.

ghost avatar Jan 10 '25 12:01 ghost

This is actually a great idea!

chrissnoek avatar Jan 10 '25 12:01 chrissnoek

Yes please!

keesplugandpay avatar Jan 10 '25 12:01 keesplugandpay