From 3713169cfcd001bb5d783480b339b40a395bb51f Mon Sep 17 00:00:00 2001 From: Anika Henke Date: Mon, 7 Nov 2016 18:24:10 +0000 Subject: [PATCH] Make font variables lowercase Our sass linting only allows hyphenated lowercase names. As all of our font variable names have uppercase letters, the `NameFormat` option needs to be disabled when they are used. This makes all those variables lowercase while also providing a fallback uppercase name to keep it backwards compatible so that we can enable that linting option again in the future. --- stylesheets/_font_stack.scss | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/stylesheets/_font_stack.scss b/stylesheets/_font_stack.scss index ad0d8b0d..7a2c7883 100644 --- a/stylesheets/_font_stack.scss +++ b/stylesheets/_font_stack.scss @@ -4,16 +4,23 @@ // scss-lint:disable NameFormat // New Transport Light -$NTA-Light: "nta", Arial, sans-serif; -$NTA-Light-Tabular: "ntatabularnumbers", $NTA-Light; +$nta-light: "nta", Arial, sans-serif; +$nta-light-tabular: "ntatabularnumbers", $nta-light; // Helvetica Regular -$Helvetica-Regular: "HelveticaNeue", "Helvetica Neue", "Arial", "Helvetica", sans-serif; +$helvetica-regular: "HelveticaNeue", "Helvetica Neue", "Arial", "Helvetica", sans-serif; // Allow font stack to be overridden // Not all apps using toolkit use New Transport -$toolkit-font-stack: $NTA-Light !default; -$toolkit-font-stack-tabular: $NTA-Light-Tabular !default; +$toolkit-font-stack: $nta-light !default; +$toolkit-font-stack-tabular: $nta-light-tabular !default; // Font reset for print -$Print-reset: sans-serif; +$print-reset: sans-serif; + +// fallback variable names after renaming them to be lowercase +// @deprecated, please only use the lowercase versions +$NTA-Light: $nta-light; +$NTA-Light-Tabular: $nta-light-tabular; +$Helvetica-Regular: $helvetica-regular; +$Print-reset: $print-reset;