Is it possible to add style to default <p> tag in Quill?

Viewed 128

My objective is to create a button in toolbar that add style to the default <p> tag where the cursor is. For example:

From <p>Example</p> to <p style="color: white;">Example</p> without nested format?

Now, my workaround is using a new custom blots which did pretty much the same thing like

<p><custom style="color: white;">Example</custom><p>

I literately have no idea how to do that as I'm new to quill. I've been spent few days studying quill/parchment documents but not 100% understand how it work. Any help is appreciated!

0 Answers
Related