twill
twill copied to clipboard
Add "link" function to TipTap Wysiwyg editor
Description
This PR enables the hyperlink feature in the TipTap WYSIWYG editor. This is currently incomplete and disabled, and the only workaround being to copy pre-formatted text from another editor like Word.
New icon has been added in the header will launch a modal to accept a link URL and the option of opening in a new page.

This is a basic implementation but I think an essential feature for people using TipTap.
Related Issues
Related posts reporting this issue: https://spectrum.chat/twill/help/tiptap-wysiwyg~6adf54cf-be29-412a-b115-20fe34adf977 https://spectrum.chat/twill/feature-requests/need-hyperlinking-in-tiptap-editor~723d4cdc-9566-4055-99e7-e0409baa194e
Hey @johnwedgbury ,
Thanks for your contribution!
A few things:
- Styling is not consistent with the rest of the ui. We need to adjust the button to match with other buttons.
- We should make the strings translatable.
- The input label should use a label attribute.
- I cannot seem to "tab" to go to other elements in the popup.
I had to push a small fix because the frontend would not compile.
Hi @haringsrob ,
Thanks for your feedback, I have addressed those points.
Please let me know if there is anything further
@haringsrob sorry to nudge. Would you be able to review this if you get chance please?
Hey @johnwedgbury, we are doing a final design check then we can merge this.
Hi @johnwedgbury i am currently adding some style enhancements to your link modal, after discussing with the twill design team one request from the design/UX team is for the modal to display the current focused text - with the ability to update the text value in that modal.
i have attached an image of the desired modal -
let me know if that is possible or if i can clarify anything for you :)
Thanks again all for the help, this work is ported to 3.x
https://github.com/area17/twill/pull/2080