From 41ee7cad0e948a57b94eeb2420f99fce7195c217 Mon Sep 17 00:00:00 2001 From: spirobel <43391631+spirobel@users.noreply.github.com> Date: Tue, 25 Feb 2020 11:43:17 +0100 Subject: [PATCH] FIX plugin generator: mobile, desktop stylesheets registering (#9039) After adding styles in the mobile scss they will also be applied to desktop without this change. https://meta.discourse.org/t/registering-assets-for-mobile-and-desktop-making-site-responsive/65041/2 --- lib/generators/plugin/templates/plugin.rb.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/generators/plugin/templates/plugin.rb.erb b/lib/generators/plugin/templates/plugin.rb.erb index e5e963734ee..f18caa3ad2e 100644 --- a/lib/generators/plugin/templates/plugin.rb.erb +++ b/lib/generators/plugin/templates/plugin.rb.erb @@ -7,8 +7,8 @@ # url: https://github.com/<%= @github_username %> register_asset 'stylesheets/common/<%= dasherized_name %>.scss' -register_asset 'stylesheets/desktop/<%= dasherized_name %>.scss' -register_asset 'stylesheets/mobile/<%= dasherized_name %>.scss' +register_asset 'stylesheets/desktop/<%= dasherized_name %>.scss', :desktop +register_asset 'stylesheets/mobile/<%= dasherized_name %>.scss', :mobile enabled_site_setting :<%= underscored_name %>_enabled