Skip to content
This repository has been archived by the owner on Oct 25, 2022. It is now read-only.

Slate Editor is not compatible with the Table-of-Contents block #173

Open
tisto opened this issue Oct 25, 2021 · 3 comments
Open

Slate Editor is not compatible with the Table-of-Contents block #173

tisto opened this issue Oct 25, 2021 · 3 comments

Comments

@tisto
Copy link

tisto commented Oct 25, 2021

StR

  1. as admin
  2. create a new page with a table of content block
  3. add a block with a headline
  4. -> the headline should show up in the TOC block but it doesn't
@tiberiuichim
Copy link
Member

@tisto in Volto the TOC block is hardcoded for draftjs, see https://github.com/plone/volto/blob/master/src/components/manage/Blocks/ToC/View.jsx#L46

With volto-slate we implement a pluggable protocol, compatible with volto-block-toc.

https://github.com/eea/volto-slate/blob/master/src/blocks/Text/index.js#L122

Basically, in the TextBlock configuration we write a function that is specific to slate blocks. I think volto-block-toc should be ported and included with Volto.

@tiberiuichim
Copy link
Member

There's a Volto issue for this: plone/volto#1616

@tisto
Copy link
Author

tisto commented Oct 25, 2021

@tiberiuichim thanks for the feedback. I guess we should make a checklist on the Slate adoption ticket and make sure Slate properly works with all existing blocks we have.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants