Using a different theme.gutenberg.yml file based on conditions like content type

Created on 25 August 2023, about 1 year ago

Problem/Motivation

I haven't been able to find a way to have Gutenberg pull in an alternate theme.gutenberg.yml file based on conditions like content type/node/etc. With the Theme Negotiator, a site can be using themes other than the default theme applied based on conditions. However, regardless of the theme set based on these conditions, Gutenberg pulls in the default theme's gutenberg.yml file. Is there a way to change this that I am missing? Could this be added to the documentation on customizing the editor? ( https://www.drupal.org/docs/contributed-modules/gutenberg/add-custom-sty... )

Steps to reproduce

Use Theme Negotiator or a module like Theme Switcher ( https://www.drupal.org/project/theme_switcher ) to apply themes based on conditions, like content type. Create theme.gutenberg.yml files for the default theme and for the conditionally applied theme. On the edit page with Gutenberg enabled, Drupal will load the default theme's Gutenberg customization, not that of the conditionally applied theme.

💬 Support request
Status

Active

Version

2.7

Component

Code

Created by

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

Comments & Activities

Production build 0.71.5 2024