The official LineHeight extension should handle line-height styles on block nodes (e.g., <p>) when pasting from Google Docs/Word. #7183
Some1Somewhere
started this conversation in
Feature Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Description
Currently, the LineHeight extension only parses line-height from textStyle marks (
<span>tags).However, rich text editors like Google Docs and Microsoft Word apply line-height to the block node itself (e.g.,
<p style="line-height: 1.5;">).When a user pastes this content, the official LineHeight extension ignores the style, and the formatting is lost.
Request: Could the official LineHeight extension be updated to also include a parseHTML rule that detects line-height on block nodes? It could then automatically convert this to the correct textStyle mark on the fly. This would dramatically improve the "out-of-the-box" paste experience while still preserving Tiptap's v3 textStyle data model."
Use Case
This would significantly enhance copy paste functionality from other 3rd party editors
Type
Other
Beta Was this translation helpful? Give feedback.
All reactions