[BUGFIX] Prevent empty links after updating a link via link-browser
Remove selection link attributes after updating an existing link that has been selected with a collapsed selection (that is when the cursor is placed anywhere inside the link). We missed to cleanup all our (and ckeditor's) link related attributes after creating a collapsed selection ("cursor placed after the link") after a link was updated. Adapt to upstream logic to cleanup link attributes as seen in https://github.com/ckeditor/ckeditor5/blob/v39.0.2/packages/ckeditor5-link/src/linkcommand.ts#L206-L208 The logic is slightly modified to use the same generic approach in https://github.com/ckeditor/ckeditor5/blob/v39.0.2/packages/ckeditor5-link/src/linkediting.ts#L697 included our workaround from #101429 Resolves: #102006 Releases: main, 12.4 Change-Id: I79f23a1c309213fbf12017ecb485c7d963fe5a2f Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/81172 Tested-by:Andreas Fernandez <a.fernandez@scripting-base.de> Reviewed-by: Benj...
Showing
- Build/Sources/TypeScript/rte_ckeditor/plugin/typo3-link.ts 15 additions, 2 deletionsBuild/Sources/TypeScript/rte_ckeditor/plugin/typo3-link.ts
- typo3/sysext/rte_ckeditor/Resources/Public/JavaScript/plugin/typo3-link.js 1 addition, 1 deletion...ckeditor/Resources/Public/JavaScript/plugin/typo3-link.js
Please register or sign in to comment