1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-08-18 21:21:21 +02:00

Add renderText and leafPosition (#5850)

* feat

* revert

* revert

* docs

* test

* refactor

* test

* revert

* refactor

* doc

* docs

* refactor

* docs

* test

* docs

* docs

* docs

* refactor
This commit is contained in:
Ziad Beyens
2025-04-29 16:30:57 +02:00
committed by GitHub
parent 2c62e01797
commit 22a3dda36d
20 changed files with 390 additions and 117 deletions

View File

@@ -26,9 +26,9 @@ If a `props.text` property is passed in, it will be ignored.
If there are properties in `text` that are not in `props`, those will be ignored when it comes to testing for a match.
#### `Text.decorations(node: Text, decorations: DecoratedRange[]) => Text[]`
#### `Text.decorations(node: Text, decorations: DecoratedRange[]) => { leaf: Text; position?: LeafPosition }[]`
Get the leaves for a text node, given `decorations`.
Get the leaves and positions for a text node, given `decorations`.
### Check methods