TypeCellOS / BlockNote

A React Rich Text Editor that's block-based (Notion style) and extensible. Built on top of Prosemirror and Tiptap.
https://www.blocknotejs.org/
Mozilla Public License 2.0
6k stars 393 forks source link

Feedback for “Parsing HTML to Blocks” #700

Open roobox opened 3 months ago

roobox commented 3 months ago

Hello community, I want to switch to BlockNote for my Webapplication. But for this to happen BlockNote would need to be able to parse the existing html files of my users. If I want to parse the following HTML:

<p>
This is a <span style="background-color: rgb(161, 0, 0);">colored background</span>
with different <span style="color: rgb(0, 71, 178);">colored text:</span
And a <sub>subtext</sub>
</p>

Non of the following three attributes (

  1. The background color of the first span
  2. The text color of the second span
  3. The sub element )

is getting parsed into the Block format and I therefore loose this information.

I know that these custom colors are not in the default color palette of BlockNote, but I would still expect that they are getting parsed and displayed accordingly and when the user wants to change the color, his custom color is not part of the dropdown options and he could only switch to one of the default colors.

Is there any possibility to include this into BlockNote?

matthewlipski commented 1 month ago

Known issue, see #636 and #572