Fix not properly working Claro theme Media Library styling with the latest Drupal core 9 version 9.5.11

Created on 14 November 2023, about 1 year ago
Updated 12 December 2023, 12 months ago

Problem/Motivation

The claro theme inside the Varbase layout builder is not working and some items are not styled on the backend pages, I can see the files loaded but the variables are not replaced.

Steps to reproduce

Try to edit any uploaded media inside any content type, and see that the styles for warning messages and the sidebar are not styled.

Proposed resolution

  • Claro 9 admin theme in Drupal 9 was frizzed with Drupal 9 is end of life - PSA-2023-11-01
  • Run and commit a new yarn claro:build for latest Drupal 9.5.11 at the time.
  • Change the build for Claro 9 with a new library varbase_layout_builder/claro9
  • Check on a new yarn claro:build for latest Drupal 10.1.6 at the time.
  • Add new libraries to support varbase_layout_builder/claro9 and varbase_layout_builder/claro10 in the same codebase.
    if (version_compare(Drupal::VERSION, '10.0.0', '<')) {
      $form['#attached']['library'][] = 'varbase_layout_builder/claro9';
    }
    else {
      $form['#attached']['library'][] = 'varbase_layout_builder/claro10';
    }

Changes in the scripts in the package.json file

  • Remove the claro:build script
  • Add claro9:build" to build the Claro 9 theme using a Drupal 9 for modal under the Layout Builder, and nested AJAX Media Library dialog.
  • Add claro10:buildto build the Claro 10 theme using a Drupal 10 for modal under the Layout Builder and nested AJAX Media Library dialog.

package.json

    "claro9:build": "webpack --progress --config webpack.config.build.claro9.js",
    "claro10:build": "webpack --progress --config webpack.config.build.claro10.js",

Remaining tasks

  • ✅ File an issue about this project
  • ✅ Addition/Change/Update/Fix to this project
  • ✅ Testing to ensure no regression
  • ➖ Automated unit/functional testing coverage
  • ➖ Developer Documentation support on feature change/addition
  • ➖ User Guide Documentation support on feature change/addition
  • ➖ UX/UI designer responsibilities
  • ➖ Accessibility and Readability
  • ✅ Code review from 1 Varbase core team member
  • ✅ Full testing and approval
  • ✅ Credit contributors
  • ✅ Review with the product owner
  • ✅ Update Release Notes and Update Helper on new feature change/addition
  • ✅ Release varbase-9.0.17 , varbase_layout_builder-10.0.41

Varbase update type

  • ✅ No Update
  • ➖ Optional Update
  • ➖ Forced Update
  • ➖ Forced Update if Unchanged

User interface changes

  • N/A

API changes

  • N/A

Data model changes

  • N/A

Release notes snippet

  • Issue #3401563 by n.ghunaim : Fixed not properly working Claro theme Media Library styling with the latest Drupal core 9 version 9.5.11
🐛 Bug report
Status

Fixed

Version

10.0

Component

Code

Created by

🇯🇴Jordan n.ghunaim Amman - Jordan

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

Comments & Activities

Production build 0.71.5 2024