From 99c80e3ca1b964f1cbbf3639f92c65f05fd9213d Mon Sep 17 00:00:00 2001 From: jlukic Date: Wed, 19 Nov 2014 16:15:48 -0500 Subject: [PATCH] Move out theme loader from theme.config, use separate include --- src/theme.less | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 src/theme.less diff --git a/src/theme.less b/src/theme.less new file mode 100644 index 000000000..b0b55a1fc --- /dev/null +++ b/src/theme.less @@ -0,0 +1,48 @@ +/******************************* + Import Directives +*******************************/ + +@theme : @@element; + +/*------------------ + Default Theme +-------------------*/ + +@import "@{themesFolder}/default/globals/site.variables"; +@import "@{themesFolder}/default/@{type}s/@{element}.variables"; + +/*------------------ + Packaged Theme +-------------------*/ + +@import "@{themesFolder}/@{site}/globals/site.variables"; +@import "@{themesFolder}/@{theme}/@{type}s/@{element}.variables"; + +/*------------------ + Site Theme +-------------------*/ + +@import "@{siteFolder}/globals/site.variables"; +@import "@{siteFolder}/@{type}s/@{element}.variables"; + + +/******************************* + Import Mix-ins +*******************************/ + +/*------------------ + Fonts +-------------------*/ + +.loadFonts() when (@importGoogleFonts) { + @import (css) 'http://fonts.googleapis.com/css?family=@{googleFontRequest}'; +} + +/*------------------ + Overrides +-------------------*/ + +.loadUIOverrides() { + @import "@{themesFolder}/@{theme}/@{type}s/@{element}.overrides"; + @import "@{siteFolder}/@{type}s/@{element}.overrides"; +}