Problem/Motivation

  • Templates of text_format_wrapper print `attributes` to the description what ends in uninterpretable aria attribute.
  • Text summary behavior (text/drupal.text library) uses theme-provided classes for it's operations which may be broken in custom themes.

Proposed resolution

Fix text_format_wrapper by printing attributes to the main wrapper and providing the missing attribute for the description.
Add js classes to the TextareaWithSummaryWidget for the text/drupal.text library (where text/drupal.text is attached).

Remaining tasks

Provide a patch with test.

User interface changes

Nothing.

API changes

None.

Data model changes

Nothing.

Release notes snippet

@Todo

Comments

huzooka created an issue. See original summary.

huzooka’s picture

Title: Clean up formatted text form element » Fix inconsistencies of TextareaWidget and TextareaWithSummaryWidget form elements
huzooka’s picture

Patch without new test (to check what breaks).

huzooka’s picture

Assigned: huzooka » Unassigned
Status: Active » Needs review

Status: Needs review » Needs work

The last submitted patch, 3: text-textarea_inconsistencies-3016343-3.patch, failed testing. View results

huzooka’s picture

Status: Needs work » Needs review
StatusFileSize
new6.14 KB

Provide the right test (without documenting the unavailable required and disabled).
Hiding patch #3.

lauriii’s picture

Status: Needs review » Needs work

This change will break existing themes. We should find a way to make this so that this doesn't break on themes that extend Stable.

wim leers’s picture

We've long wanted to get rid of the "text with summary" field type. And hence also the widget. If we fix #1378350: Clean up the "Long text and summary" field, we won't need to fix this.

Version: 8.6.x-dev » 8.8.x-dev

Drupal 8.6.x will not receive any further development aside from security fixes. Bug reports should be targeted against the 8.8.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.9.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.7 was released on June 3, 2020 and is the final full bugfix release for the Drupal 8.8.x series. Drupal 8.8.x will not receive any further development aside from security fixes. Sites should prepare to update to Drupal 8.9.0 or Drupal 9.0.0 for ongoing support.

Bug reports should be targeted against the 8.9.x-dev branch from now on, and new development or disruptive changes should be targeted against the 9.1.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.9.x-dev » 9.2.x-dev

Drupal 8 is end-of-life as of November 17, 2021. There will not be further changes made to Drupal 8. Bugfixes are now made to the 9.3.x and higher branches only. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.15 was released on June 1st, 2022 and is the final full bugfix release for the Drupal 9.3.x series. Drupal 9.3.x will not receive any further development aside from security fixes. Drupal 9 bug reports should be targeted for the 9.4.x-dev branch from now on, and new development or disruptive changes should be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.9 was released on December 7, 2022 and is the final full bugfix release for the Drupal 9.4.x series. Drupal 9.4.x will not receive any further development aside from security fixes. Drupal 9 bug reports should be targeted for the 9.5.x-dev branch from now on, and new development or disruptive changes should be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

solideogloria’s picture

Version: 9.5.x-dev » 11.x-dev
dww’s picture

Issue tags: +Bug Smash Initiative

Coming from #2421445-30: Text format wrapper does not honor description_display. To fix that bug, I wanted to entirely remove some code that lives in the wrong templates, yet it includes a @see comment pointing here. 😅 During self-review (#30.4) I pointed out the brokenness of attributes not being used in the wrapper element. Now that I'm reading the summary here, that's most of what this issue aims to fix. Hopefully this will be smaller and easier to land once we get the description out of the way entirely and leave that to form-element.html.twig itself (when {{ children }}is rendered).

I won't formally mark this postponed, but it should probably wait until #2421445 lands...

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.