Postponed
Project:
Drupal core
Version:
main
Component:
layout_builder.module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
25 Nov 2019 at 19:27 UTC
Updated:
17 Dec 2019 at 18:31 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
zrpnrComment #3
tim.plunkettComment #4
zrpnrStill investigating whether #2988970: Layout Builder should make it easier to modify the default layout for an entity type when viewing an entity and #3043228: Add Umami-specific styling for Layout Builder messages are a conflict with this change.
This patch keeps the render array mostly intact and uses messenger to
addMessage.Comment #6
zrpnrThis helped with the overrides, but because messages are duplicated in the status message block and the layout builder area it fails the functional tests.
Fully removing the return value for
buildMessageprevents the "you are editing the layout" duplicate.That lets it pass
LayoutBuilderDisableInteractionsTestandLayoutBuilderUiTest.However the ajax "unsaved changes" message will still appear in the status message block and the layout builder area.
I think this is also related to #3023228: Layout builder is showing two status messages
Comment #7
zrpnrAn option to remove the duplicates is to entirely remove the lb specific markup and only use the Messenger.
This means also changing the selector in 3 functional tests in LayoutBuilderTest.
However, this causes a regression - losing the special icons added in #2988970: Layout Builder should make it easier to modify the default layout for an entity type when viewing an entity
and doesn't prevent the ajax message from appearing in the form markup after a layout change.
Comment #8
zrpnrI posted a patch to #3100473: Allow additional message types, I think that approach could work for LB to add in the special classes that would be removed in #7
Comment #9
tim.plunkettThis is a fine patch as-is, but the tests show the regression. Those CSS classes are vaguely important for the styling, so we need to postpone this for now on the issue linked in #8