tiptap
tiptap copied to clipboard
Change the background color of the selected texts
What problem are you facing?
I need to use my own custom highlightinh system to hightlight the texts users select. For example, I need the size of the background color of selected texts to be larger than the normal one.
What’s the solution you would like to see?
I'd like to use the mark system you provide, which is similar to your Highlights mark. I just wonder how I can create such a mark that can remove the background-color mark of the last selected texts and add the background-color mark to the current selected texts.
What alternatives did you consider?
Just as the solution#2 of this alternative solution says: "CodeMirror and Monaco have their own highlighting logic. They use a slightly different approach where the highlights are contained in a separate part of the DOM tree."
Anything to add? (optional)
No response
Are you sponsoring us?
- [ ] Yes, I’m a sponsor. 💖