remove k12 css variant since we don't use it for now

closes: CNVS-22285

since we took out all usage of the $is-k12 sass variable
when we removed the legacy k12 stuff we did, there
is no actual difference between the new_styles
and k12 variants. so we don't need to generate
2 different files for now (since their output will
be exactly the same).

this will cut the css generation time in half
when deploying and when generating a preview in 
theme editor since instead of outputting 2 css files
(1 for new_styles_normal_contrast and 1 for 
k12_normal_contrast) for every css bundle for every
theme, we just make one (new_styles_normal_contrast)

In the future, ui/ux might want to reintroduce
a sass variable like $is-k12 to do different things
if they are a k12 school. But when/if we do that,
we can just save it as part of the variables saved
in the school's brand_config from the theme editor.

that will be possible because when you turn on the 
k12 feature flag, it defaults to using the 
predefined 'K12 Theme' brand_config so *all* k12 
schools will have a brand_config

test plan:
make sure canvas looks the same as it did before if
you have the k12 feature flag turned on

Change-Id: I197c30b9c5ed5150a3683f836008cbdbce78b09d
Reviewed-on: https://gerrit.instructure.com/59743
Tested-by: Jenkins
Reviewed-by: Colleen Palmer <colleen@instructure.com>
Product-Review: Colleen Palmer <colleen@instructure.com>
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
This commit is contained in:
Ryan Shaw 2015-07-31 12:38:45 -06:00
parent 497051ad06
commit 7cac901ad8
9 changed files with 2 additions and 19 deletions

View File

@ -3,9 +3,7 @@ define ->
brandableCss =
getCssVariant: ->
variant = if window.ENV.k12
'k12'
else if window.ENV.use_new_styles
variant = if window.ENV.use_new_styles
'new_styles'
else
'legacy'

View File

@ -265,9 +265,7 @@ module ApplicationHelper
end
def css_variant
if k12?
variant = 'k12'
elsif use_new_styles?
if use_new_styles?
variant = 'new_styles'
else
variant = 'legacy'

View File

@ -1,3 +0,0 @@
$use_new_styles: true;
$is-k12: true;
$use_high_contrast: true;

View File

@ -1,3 +0,0 @@
$use_new_styles: true;
$is-k12: true;
$use_high_contrast: false;

View File

@ -1,3 +1,2 @@
$use_new_styles: false;
$is-k12: false;
$use_high_contrast: true;

View File

@ -1,3 +1,2 @@
$use_new_styles: false;
$is-k12: false;
$use_high_contrast: false;

View File

@ -1,3 +1,2 @@
$use_new_styles: true;
$is-k12: false;
$use_high_contrast: true;

View File

@ -1,3 +1,2 @@
$use_new_styles: true;
$is-k12: false;
$use_high_contrast: false;

View File

@ -19,6 +19,3 @@ variants:
new_styles_normal_contrast:
brandable: true
new_styles_high_contrast: {}
k12_normal_contrast:
brandable: true
k12_high_contrast: {}