Skip to content
Snippets Groups Projects

Dependent stylesheets are output in the wrong order

Closed Matt Glaman requested to merge issue/drupal-3374901:3374901-all-for-you-mherchel into 11.x
Files
11
@@ -227,7 +227,9 @@ 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.
$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'])) {
Loading