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 I can select text inline editing and turn it into a link (or edit/remove existing link) #35

Open MAX-786 opened 3 months ago

djay commented 1 month ago

This is one could be a little tricky because ideally you would want the link input to be done by the admin UI so as to keep the UI code as simple as possible in hydra.js so it's less likely to interfer with the frontend js/css.

Quanta specifies it should appear overtop of where the quanta bar was however.

Image

As discussed in the meeting probably the way it will work is

djay commented 1 week ago

Just noticed quanta doesn't make it clear how to remove a link. Clicking link button would have to edit an existing link not remove it. Maybe you are supposed to remove the text of the link and confirm?

Seperate issue but The confirm arrow in volto and quanta I don't like. It's easy to forgot to click it and then your changes aren't saved.

djay commented 2 days ago

@MAX-786 I can't get it to work.

MAX-786 commented 2 days ago

Entering a url has an exception. TypeError: Cannot read properties of null (reading 'outerHTML') at HTMLButtonElement. (hydra.js:506:58)

I wasn't able to reproduce this error, can you provide any steps or anything but ig we can work on these now on later terms ...

djay commented 17 hours ago

@MAX-786 I got it to work once. and other times I got that exception. I couldn't isolate a difference it steps but is is an example

  1. click the block
  2. select the word can
  3. click link
  4. type rule
  5. click confirm - nothing happens. exception

Image

Slightly different problem is that you can select a new block and a word at the same time by double clicking a word but that then loses the word selection so formatting it doesn't work.