Convert settings to third party settings

Created on 14 May 2024, 11 months ago

Problem/Motivation

Tailwind JIT currently stores its theme configuration as a top level config, e.g.

gin.settings.yml:
secondary_toolbar_frontend: true
high_contrast_mode: false
tailwind_jit:
  compile_html_requests: true
  html_input_file: 'foo.css'
  compile_ajax_requests: true
  ajax_input_file: 'bar.css'

While this does work, it is actually not fully correct. The proper way would be storing the settings as third party settings

gin.settings.yml:
secondary_toolbar_frontend: true
high_contrast_mode: false
third_party_settings:
  tailwind_jit:
    compile_html_requests: true
    html_input_file: 'foo.css'
    compile_ajax_requests: true
    ajax_input_file: 'bar.css'

Remaining tasks

  • Provide a config schema
  • Change to third party setttings
  • Write update hook
📌 Task
Status

Active

Version

1.0

Component

Code

Created by

🇦🇹Austria hudri Austria

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

Comments & Activities

  • Issue created by @hudri
  • 🇦🇹Austria hudri Austria
  • 🇦🇹Austria hudri Austria
  • Status changed to Postponed 11 months ago
  • 🇦🇹Austria hudri Austria

    Postponed due core's problems with 3rd party settings in themes.

  • 🇦🇹Austria hudri Austria

    Olivero (and Gin) are incorrectly overwriting theme third party settings:

    https://www.drupal.org/project/drupal/issues/3402885 🐛 [PP-1] olivero.settings config schema is wrong Postponed

  • Status changed to Closed: won't fix 2 months ago
  • 🇦🇹Austria hudri Austria

    Third party settings are not supported for simple configuration like theme settings (only for full config entities). The way Gin and Olivero currently do it for the shortcut module is a hack to get config schema validation. Contrib modules can not meaningfully use the hack, therefore closing this issue.

    Maybe converting settings to full config entites (like `tailwind_jit.THEMENAME.yml`) is the correct way in the long run, so we can get config schema validation.

Production build 0.71.5 2024