collective / volto-hydra

A volto addon to let you edit content in realtime when you have many frontends written in any framework
0 stars 2 forks source link

I can Change the text of a selected text block from sidepanel after clicking on it, save and see updated page #16

Closed MAX-786 closed 1 month ago

MAX-786 commented 3 months ago

Problem

We need to be able to edit fields on blocks that don't currently make them visible, like text on a text block.

Technical

Does this mean we need to override all blocks that don't make visible all their schemas? Is there any easier way?

djay commented 2 months ago

@JeffersonBledsoe to see if it's hard or not to get the richtext field to appear in the schema. If it is hard we can just delay this until later.

JeffersonBledsoe commented 2 months ago

As noted in Discord:

If you open the file /packages/volto-slate/src/blocks/Text/schema.js, add value into the fields key within the fieldset definition and add the following object into properties, you get full slate in the sidebar to test with:

value: {
    title: 'Body',
    widget: 'slate',
},
djay commented 1 month ago

@MAX-786 if its easy it would be nice to put the markdown help into it's own section or move to bottom or somehow hide it. or can split that out for later

MAX-786 commented 1 month ago

@djay We can move the markdown help to bottom by shadowing the DefaultTextBlockEditor of volto-slate package. Not sure how to shadow components of other than volto package but i'll ask around and see.