Problem/Motivation

Most (if not all) status_messages templates refer to the "status_headings" variable under normal circumstances.

The core render element itself renders it as such:

[
  '#theme' => 'status_messages',
  '#message_list' => $messages,
  '#status_headings' => [
    'status' => t('Status message'),
    'error' => t('Error message'),
    'warning' => t('Warning message'),
  ],
],

Proposed resolution

Add this to the build array for status messages:

'#status_headings' => [
  'status' => t('Status message'),
  'error' => t('Error message'),
  'warning' => t('Warning message'),
],

User interface changes

There will be front-end rendering changes in a lot of cases.

API changes

None

Data model changes

None

Issue fork styleguide-3204697

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Luke.Leber created an issue. See original summary.

luke.leber’s picture

Status: Active » Needs review
dcam’s picture

Version: 2.0.0-beta1 » 2.x-dev
Category: Bug report » Feature request

  • dcam committed 2ebd967e on 2.x authored by luke.leber
    Issue #3204697 by luke.leber: status_messages missing "status_headings"...
dcam’s picture

Status: Needs review » Fixed

Yep, I agree this is important. Thank you for your contribution!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.