betancourtl / draft-js-custom-styles

Create custom inline styles for draft-js in a sane way
MIT License
34 stars 17 forks source link

Suggestions for setting font family? #11

Closed brandondurham closed 5 years ago

brandondurham commented 6 years ago

It seems to be missing from most of the Draft.js-related documentation I’m finding, yet is one of the more common setting people tend to use.

I’m working on a type testing tool that requires a “font” feature where you can choose the font you’d like applied to the selected text. There will most definitely be lots of overlapping selections. Any recommendations on how to pull this off?

betancourtl commented 5 years ago

If you go to this link. https://webdeveloperpr.github.io/draft-js-custom-styles/ and see the toggle functionality. You might be able to re-create the same behavior with using a select dropdown. Each Select Option could be a font-family

brandondurham commented 5 years ago

Very nice. Is the source code posted anywhere?