Commit cf9583ba authored by catch's avatar catch
Browse files

Issue #3374901 by e0ipso, mglaman, smustgrave, mherchel, _utsavsharma,...

Issue #3374901 by e0ipso, mglaman, smustgrave, mherchel, _utsavsharma, gareth.poole, catch, lauriii, eelkeblok, web-beest: SDC stylesheets should be added in the "theme" aggregate group (as opposed to "default" group) to correct CSS source order

(cherry picked from commit c98044ce)
parent e50b7abf
Loading
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -231,7 +231,10 @@ public function buildByExtension($extension) {
            $options['group'] = JS_LIBRARY;
          }
          elseif ($type == 'css') {
            $options['group'] = $extension_type == 'theme' ? CSS_AGGREGATE_THEME : CSS_AGGREGATE_DEFAULT;
            // Component stylesheets should be added in the "theme" aggregate
            // group to load them alongside the theme.
            // @see \Drupal\Core\Plugin\Component::getLibraryName
            $options['group'] = ($extension_type == 'theme' || str_starts_with($id, 'components.')) ? CSS_AGGREGATE_THEME : CSS_AGGREGATE_DEFAULT;
          }
          // By default, all library assets are files.
          if (!isset($options['type'])) {
+1 −0
Original line number Diff line number Diff line
@@ -621,6 +621,7 @@ tabwidth
taskless
tbachert
tcomment
tenderwolf
testbot
testbots
testlogger
+10 −0
Original line number Diff line number Diff line
$schema: https://git.drupalcode.org/project/sdc/-/raw/1.x/src/metadata.schema.json
name: CSS Load Order
props:
  type: object
  properties:
    dummy:
      type: string
libraryOverrides:
  dependencies:
    - sdc_theme_test/css_load_order_dependent
+3 −0
Original line number Diff line number Diff line
div {
  display: block;
}
+2 −0
Original line number Diff line number Diff line
In memory of Hawkeye Tenderwolf. You had the best laughter of all, sometimes I
can still hear it. I miss you dearly, my friend.
Loading