This issue has been created
There are 2 updates.
 
 
XWiki Platform / cid:jira-generated-image-avatar-be6ad009-13d0-4809-9799-c92ef956ccf2 XWIKI-25738 Open

Support links with generated labels in the BlockNote link modal

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-ea06a292-41a5-4a60-931b-f32bb5c561c4 Marius Dumitru Florea created this issue on 12/Nov/26 11:05
 
Summary: Support links with generated labels in the BlockNote link modal
Issue Type: cid:jira-generated-image-avatar-be6ad009-13d0-4809-9799-c92ef956ccf2 Improvement
Affects Versions: 18.9.0
Assignee: Unassigned
Components: BlockNote
Created: 12/Nov/26 11:05
Priority: cid:jira-generated-image-static-major-96824435-bd61-4d30-94cc-2d2a878c8285 Major
Reporter: Marius Dumitru Florea
Description:

XWiki Rendering supports links without a label of their own, whose label is generated from the link target when the content is rendered (e.g. [[doc:Space.Page]] rather than [[label>>doc:Space.Page]]). The BlockNote editor shows the generated label of such a link and saves the link without it, as long as the label is left untouched in the edited content. The BlockNote link modal doesn't support generated labels though:

  • When editing a link with a generated label, the display text field is pre-filled with the generated label, as if the user had chosen it. Changing the link target then keeps the old label in the editor, which no longer matches the new target.
  • When the user types a display text for a link with a generated label, the link is still saved without a label if the typed text happens to be the same as the generated one.
  • When a link is created or edited with an empty display text, the link label is generated from the link target in the editor, but it's saved in the wiki syntax as a label of its own, e.g. [[Page Title>>doc:Space.Page]] instead of [[doc:Space.Page]].

The link modal should instead:

  • leave the display text field empty when editing a link with a generated label (showing the generated label as placeholder), so that the label follows the link target;
  • save a link with a non-empty display text with that label, even when it's the same as the generated one;
  • save a link submitted with an empty display text, created or edited, without a label, so that its label is generated server-side.
 
 

2 updates

 
cid:jira-generated-image-avatar-ea06a292-41a5-4a60-931b-f32bb5c561c4 Changes by Marius Dumitru Florea on 12/Nov/26 11:05
 
Fix Version: 18.10.0-rc-1
Assignee: Marius Dumitru Florea