Change text color icon color to selected color Froala Editor

Viewed 173

In FroalaEditor, I am trying to create an option to change text color using the inline toolbar.

Here is the example I have done so far: https://jsfiddle.net/moviecrew/ph7au4v5/

 new FroalaEditor('div#froala-editor', {
   toolbarInline: true,
   charCounterCount: false,
   toolbarVisibleWithoutSelection: true,
   toolbarButtons: ['insertLink', 'color', 'bold', 'italic', 'underline', 'strikeThrough', 
    'subscript', 'superscript', 'fontFamily', 'fontSize', 'textColor', 'backgroundColor', 
    'inlineClass', 'inlineStyle', 'clearFormatting']
});

When a color is selected, I would like to change the color of this icon reflecting the selected color for the selected text. enter image description here

I checked the doc but there was no event related to it.

Is there anything we can do to make this work?

It should actually look like this https://tppr.me/MFxzb

Thank you

0 Answers
Related