Moderation Meta Published Removed

Created on 1 April 2024, 3 months ago
Updated 18 April 2024, 2 months ago

Problem/Motivation

After recent changes it seems like $form['meta'] is cleared of the published markup and other information. We have several hooks which check and change the markup of the content moderation text which is now causing errors.

Before:

After:

Steps to reproduce

  1. Create a new article node, add a breakpoint at the end of gin_everywhere_form_alter()
  2. Verify that $form['meta'] no longer contains all information
  3. Disable gin_everywhere and repeat step one. It should contain all meta information now.

It looks like even prior to the new changes on 1.0.x-dev it is currently overwriting moderated entity forms where the meta published markup is set as below:

if (isset($form['meta']['published'])) {
        $form['meta']['published']['#markup'] = $this->moderationInfo->getWorkflowForEntity($entity)->getTypePlugin()->getState($entity->moderation_state->value)->label();
}

Proposed resolution

Try and avoid overwriting meta.

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States j-barnes

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

Merge Requests

Comments & Activities

Production build 0.69.0 2024