mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-02-24 01:02:31 +01:00
* Add failing test showing splitBlock with isVoid bug Not sure what I actually expected calling `splitBlock()` on void block, but I would expect `splitBlock()` to respect a given block type's isVoid property. This failing test demonstrates that `splitBlock()` always creates a the new block with `isVoid: false`. * Fix isVoid not being copied when using splitBlock() The bug was actually inside `splitBlockAtRange`, as that's what actual drives `splitBlock()` (I assume the bug was therefore present in both methods). The fix is to simply copy across the `isVoid` value from the block being copied.
This directory contains the core logic of Slate. It's separated further into a series of directories:
- Components — containing the React components Slate renders.
- Models — containing the models that define Slate's internal data structure.
- Plugins — containing the plugins that ship with Slate by default.
- Serializers — containing the serializers that ship with Slate by default.
- Utils — containing a few private convenience modules.
Feel free to poke around in each of them to learn more!