From 3a372a916f3545d37390f692f24f7e1c4d5351b5 Mon Sep 17 00:00:00 2001 From: Dylan William Hardison Date: Wed, 17 May 2017 16:19:36 -0400 Subject: Bug 1363803 - Consolidate YUI js and css into one js and one css file --- Bugzilla/Template.pm | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) (limited to 'Bugzilla/Template.pm') diff --git a/Bugzilla/Template.pm b/Bugzilla/Template.pm index b08cffbde..29b1d4a13 100644 --- a/Bugzilla/Template.pm +++ b/Bugzilla/Template.pm @@ -383,28 +383,23 @@ sub mtime_filter { # Set up the skin CSS cascade: # -# 1. standard/global.css -# 2. YUI CSS +# 1. YUI CSS +# 2. standard/global.css # 3. Standard Bugzilla stylesheet set # 4. Third-party "skin" stylesheet set, per user prefs # 5. Inline css passed to global/header.html.tmpl # 6. Custom Bugzilla stylesheet set sub css_files { - my ($style_urls, $yui, $yui_css) = @_; + my ($style_urls, $no_yui) = @_; # global.css belongs on every page my @requested_css = ( 'skins/standard/global.css', @$style_urls ); - my @yui_required_css; - foreach my $yui_name (@$yui) { - next if !$yui_css->{$yui_name}; - push(@yui_required_css, "js/yui/assets/skins/sam/$yui_name.css"); - } - unshift(@requested_css, @yui_required_css); - + unshift @requested_css, "skins/yui.css" unless $no_yui; + my @css_sets = map { _css_link_set($_) } @requested_css; - + my %by_type = (standard => [], skin => [], custom => []); foreach my $set (@css_sets) { foreach my $key (keys %$set) { -- cgit v1.2.3-24-g4f1b