Link Attributes plugin does not work in CKEditor5 in Drupal 10.5.x

Created on 12 August 2025, 12 days ago

Problem/Motivation

I am testing a minor update from our Drupal 10.4.8 environment to 10.5.2. When I update to 10.5.2 the three link attributes that I have configured no longer display. When I revert back to 10.4.8 the link attributes display and work normally.

Steps to reproduce

  • Create a Drupal 10.5.x environment
  • Create a text format, in this case I am working with Filtered HTML.
  • Configure that formatter and add a link attribute, in my case I added Group Label "Black Button" with attributes class|btn btn-dark btn-large
  • Save, then navigate to Content and create a piece of content that uses the CKEditor 5 editor and click on the link button, you should NOT see your new attribute

Proposed resolution

I do not have a proposed resolution because at the moment I have not been able to isolate the issue. I am completely unfamiliar with how the plugin pack integrates or works with the ckeditor5 module.

In ckeditor5_plugin_pack_link_attributes -> LinkAttributes.php when I log out getDynamicPluginConfig I can see my attributes but from here I have so far not been able to figure out how ckeditor5 picks up this config and renders my attributes to the link widget. Hopefully someone can help?

Our content authors use my link attributes often I have 3 two buttons and a Link Target with target|_blank.

I would like to update core to 10.5.2 but I cannot until I/we figure out either what I have done wrong :) or where the bug lies.

I am working with Chrome 138.0.7204.184, Drupal 10.4.8 and Drupal 10.5.2, PHP 8.3.24.
As you can see in 10-4-8-image-2.png (By the way I goofed this screenshot is from 10.5.2 based environment) there is no errors in dev tools.

However when I first load the page I do see errors relating to translations as you can see in screenshot 10-5-22-image-3.png (22 s/b just 2 ... wups again).

But those errors are just https://cdn.ckeditor.com/ckeditor5/45.2.0/dll/markdown-gfm/translations/... 404 but maybe this could be the cause I'll check.

Could be related to issue 3459285

🐛 Bug report
Status

Active

Version

1.4

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @dcooke01
  • 🇵🇱Poland salmonek

    Hi dcooke01

    The link popup has changed in a version of CKEditor 5 that is available in Drupal 10.5.
    Now you have to add url first, and then clcik on the link to show contextual menu and click on middle icon. Link attributes will be available in the poput that'll appear.
    We'll update the feature guide with info about that change.

    404 on translation download won't have any negative impact to the editor. I suppose markdown plugin does not have translations at all. We'll check it and disable translation downloading for that plugin.

  • Hi Salmonek,

    Thanks very much for the info. I was able to test and everything works as expected.

    Dave

Production build 0.71.5 2024