diff --git a/docs/doc-fragments/buildYourOwnFlavor.js b/docs/doc-fragments/buildYourOwnFlavor.js index d8cdbc1..bd5fa38 100644 --- a/docs/doc-fragments/buildYourOwnFlavor.js +++ b/docs/doc-fragments/buildYourOwnFlavor.js @@ -20,7 +20,7 @@ module.exports = {
- +

Font weight for headings (400 is normal, 700 is bold)

@@ -166,7 +166,7 @@ module.exports = {
- +

Universal box shadow for most elements

@@ -1013,6 +1013,32 @@ module.exports = { aVisitedColor: document.getElementById('aVisitedColor').value, mobileBreakpoint: document.getElementById('mobileBreakpoint').value, largeScreenBreakpoint: document.getElementById('largeScreenBreakpoint').value, + }, + layout : { + enabled: document.getElementById('layoutEnabled').checked, + }, + inputControl : { + enabled: document.getElementById('inputControlEnabled').checked, + }, + navigation : { + enabled: document.getElementById('navigationEnabled').checked, + }, + table : { + enabled: document.getElementById('tableEnabled').checked, + }, + contextual : { + enabled: document.getElementById('contextualEnabled').checked, + }, + progress : { + enabled: document.getElementById('progressEnabled').checked, + }, + icon : { + enabled: document.getElementById('iconsEnabled').checked + }, + utility : { + enabled: document.getElementById('utilityEnabled').checked, + genericBoxShadowColor: document.getElementById('genericBoxShadowColor').value, + genericBorderColor: document.getElementById('genericBorderColor').value } }; } @@ -1037,9 +1063,81 @@ module.exports = { flavorFile +='$pre-color: '+flavorData.core.preSidebarColor+'; //
 sidebar color\\n';
       flavorFile +='$border-color: '+flavorData.core.borderColor+'; // Border color\\n';
       flavorFile +='$secondary-border-color: '+flavorData.core.secondaryBorderColor+'; // Secondary border color\\n';
-
+      flavorFile +='$heading-line-height: '+flavorData.core.headingLineHeight+'; // Line height for headings\\n';
+      flavorFile +='$heading-ratio: '+flavorData.core.headingRatio+'; // Ratio for headings (strictly unitless)\\n';
+      flavorFile +='$subheading-font-size:'+flavorData.core.subheadingFontSize+'em; // Font sizing for  elements in headings\\n';
+      flavorFile +='$subheading-top-margin: '+flavorData.core.subheadingTopMargin+'rem; // Top margin of  elements in headings\\n';
+      flavorFile +='$heading-font-weight: '+flavorData.core.headingFontWeight+'; // Font weight for headings\\n';
+      flavorFile +='$horizontal-rule-line-height:  '+flavorData.core.horizontalRuleLineHeight+'em; // 
line height\\n'; + flavorFile +='$universal-margin: '+flavorData.core.universalMargin+'rem; // Universal margin for the most elements\\n'; + flavorFile +='$universal-padding: '+flavorData.core.universalPadding+'rem; // Universal padding for the most elements\\n'; + flavorFile +='$universal-border-radius: '+flavorData.core.universalBorderRadius+'rem; // Universal border-radius for most elements\\n'; + flavorFile +='$universal-box-shadow: '+flavorData.core.universalBoxShadow+'; // Universal box-shadow for most elements\\n'; + flavorFile +='$small-element-font-size: '+flavorData.core.smallFontSize+'em; // Font size for , , \\n'; + flavorFile +='$small-font-size: '+flavorData.core.smallFontSize+'em; // Font sizing for elements\\n'; + flavorFile +='$blockquote-quotation-size: 3rem; // Font size for the quotation of
\\n'; + flavorFile +='$blockquote-cite-size: 0.75em; // Font size for the [cite] of
\\n'; + flavorFile +='$code-font-size: '+flavorData.core.codeFontSize+'em; // Font size for , \\n'; + flavorFile +='$sup-top: '+flavorData.core.supTop+'em; // top\\n'; + flavorFile +='$sub-bottom: '+flavorData.core.subBottom+'em; // bottom\\n'; + flavorFile +='$a-link-color: '+flavorData.core.aLinkColor+'; // Color for :link\\n'; + flavorFile +='$a-visited-color: '+flavorData.core.aVisitedColor+'; // Color for :visited\\n'; + flavorFile +='$bold-font-weight: '+flavorData.core.boldFontWeight+'; // Font weight for and \\n'; + flavorFile +='$mobile-breakpoint: '+flavorData.core.mobileBreakpoint+'; // Breakpoint between small and medium screens (px)\\n'; + flavorFile +='$large-screen-breakpoint: '+flavorData.core.largeScreenBreakpoint+'; // Breakpoint between medium and large screens (px)\\n'; + flavorFile +='\\n'; flavorFile +='@import \\'../mini/core\\';\\n'; - + flavorFile +='\\n'; + if(flavorData.layout.enabled){ + + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/layout\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.inputControl.enabled){ + + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/inputControl\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.navigation.enabled){ + + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/navigation\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.table.enabled){ + + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/table\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.contextual.enabled){ + + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/contextual\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.progress.enabled){ + + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/progress\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.icon.enabled){ + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/icon\\';\\n'; + flavorFile +='\\n'; + } + if(flavorData.utility.enabled){ + + flavorFile +='$box-shadow-generic: 0 4*$__1px 4*$__1px 0 '+flavorData.utility.genericBoxShadowColor+', 0 2*$__1px 2*$__1px -2*$__1px '+flavorData.utility.genericBoxShadowColor+';\\n'; + flavorFile +='$border-generic-color: '+flavorData.utility.genericBorderColor+'; // Border color for bordered elements.\\n'; + flavorFile +='\\n'; + flavorFile +='@import \\'../mini/utility\\';\\n'; + flavorFile +='\\n'; + } + console.log(flavorFile); } `, diff --git a/docs/v3/DEVLOG.md b/docs/v3/DEVLOG.md index ec74428..a6e4510 100644 --- a/docs/v3/DEVLOG.md +++ b/docs/v3/DEVLOG.md @@ -344,3 +344,9 @@ - Made switches disable the controls for each form as necessary in the flavors page. - Added some flavor file generation parts, this will take a little while. + +## 20180519 + +- Finished Sass variable generation for `core` module in flavors page. +- Finished Sass variable generation for `icon` module in flavors page. +- Finished Sass variable generation for `utility` module in flavors page. diff --git a/docs/v3/flavors.html b/docs/v3/flavors.html index 16f9ec4..681b2bb 100644 --- a/docs/v3/flavors.html +++ b/docs/v3/flavors.html @@ -44,7 +44,7 @@
- +

Font weight for headings (400 is normal, 700 is bold)

@@ -190,7 +190,7 @@
- +

Universal box shadow for most elements

@@ -1037,6 +1037,32 @@ aVisitedColor: document.getElementById('aVisitedColor').value, mobileBreakpoint: document.getElementById('mobileBreakpoint').value, largeScreenBreakpoint: document.getElementById('largeScreenBreakpoint').value, + }, + layout : { + enabled: document.getElementById('layoutEnabled').checked, + }, + inputControl : { + enabled: document.getElementById('inputControlEnabled').checked, + }, + navigation : { + enabled: document.getElementById('navigationEnabled').checked, + }, + table : { + enabled: document.getElementById('tableEnabled').checked, + }, + contextual : { + enabled: document.getElementById('contextualEnabled').checked, + }, + progress : { + enabled: document.getElementById('progressEnabled').checked, + }, + icon : { + enabled: document.getElementById('iconsEnabled').checked + }, + utility : { + enabled: document.getElementById('utilityEnabled').checked, + genericBoxShadowColor: document.getElementById('genericBoxShadowColor').value, + genericBorderColor: document.getElementById('genericBorderColor').value } }; } @@ -1061,8 +1087,81 @@ flavorFile +='$pre-color: '+flavorData.core.preSidebarColor+'; //
 sidebar color\n';
       flavorFile +='$border-color: '+flavorData.core.borderColor+'; // Border color\n';
       flavorFile +='$secondary-border-color: '+flavorData.core.secondaryBorderColor+'; // Secondary border color\n';
-      
+      flavorFile +='$heading-line-height: '+flavorData.core.headingLineHeight+'; // Line height for headings\n';
+      flavorFile +='$heading-ratio: '+flavorData.core.headingRatio+'; // Ratio for headings (strictly unitless)\n';
+      flavorFile +='$subheading-font-size:'+flavorData.core.subheadingFontSize+'em; // Font sizing for  elements in headings\n';
+      flavorFile +='$subheading-top-margin: '+flavorData.core.subheadingTopMargin+'rem; // Top margin of  elements in headings\n';
+      flavorFile +='$heading-font-weight: '+flavorData.core.headingFontWeight+'; // Font weight for headings\n';
+      flavorFile +='$horizontal-rule-line-height:  '+flavorData.core.horizontalRuleLineHeight+'em; // 
line height\n'; + flavorFile +='$universal-margin: '+flavorData.core.universalMargin+'rem; // Universal margin for the most elements\n'; + flavorFile +='$universal-padding: '+flavorData.core.universalPadding+'rem; // Universal padding for the most elements\n'; + flavorFile +='$universal-border-radius: '+flavorData.core.universalBorderRadius+'rem; // Universal border-radius for most elements\n'; + flavorFile +='$universal-box-shadow: '+flavorData.core.universalBoxShadow+'; // Universal box-shadow for most elements\n'; + flavorFile +='$small-element-font-size: '+flavorData.core.smallFontSize+'em; // Font size for , , \n'; + flavorFile +='$small-font-size: '+flavorData.core.smallFontSize+'em; // Font sizing for elements\n'; + flavorFile +='$blockquote-quotation-size: 3rem; // Font size for the quotation of
\n'; + flavorFile +='$blockquote-cite-size: 0.75em; // Font size for the [cite] of
\n'; + flavorFile +='$code-font-size: '+flavorData.core.codeFontSize+'em; // Font size for , \n'; + flavorFile +='$sup-top: '+flavorData.core.supTop+'em; // top\n'; + flavorFile +='$sub-bottom: '+flavorData.core.subBottom+'em; // bottom\n'; + flavorFile +='$a-link-color: '+flavorData.core.aLinkColor+'; // Color for :link\n'; + flavorFile +='$a-visited-color: '+flavorData.core.aVisitedColor+'; // Color for :visited\n'; + flavorFile +='$bold-font-weight: '+flavorData.core.boldFontWeight+'; // Font weight for and \n'; + flavorFile +='$mobile-breakpoint: '+flavorData.core.mobileBreakpoint+'; // Breakpoint between small and medium screens (px)\n'; + flavorFile +='$large-screen-breakpoint: '+flavorData.core.largeScreenBreakpoint+'; // Breakpoint between medium and large screens (px)\n'; + flavorFile +='\n'; flavorFile +='@import \'../mini/core\';\n'; + flavorFile +='\n'; + if(flavorData.layout.enabled){ + + flavorFile +='\n'; + flavorFile +='@import \'../mini/layout\';\n'; + flavorFile +='\n'; + } + if(flavorData.inputControl.enabled){ + + flavorFile +='\n'; + flavorFile +='@import \'../mini/inputControl\';\n'; + flavorFile +='\n'; + } + if(flavorData.navigation.enabled){ + + flavorFile +='\n'; + flavorFile +='@import \'../mini/navigation\';\n'; + flavorFile +='\n'; + } + if(flavorData.table.enabled){ + + flavorFile +='\n'; + flavorFile +='@import \'../mini/table\';\n'; + flavorFile +='\n'; + } + if(flavorData.contextual.enabled){ + + flavorFile +='\n'; + flavorFile +='@import \'../mini/contextual\';\n'; + flavorFile +='\n'; + } + if(flavorData.progress.enabled){ + + flavorFile +='\n'; + flavorFile +='@import \'../mini/progress\';\n'; + flavorFile +='\n'; + } + if(flavorData.icon.enabled){ + flavorFile +='\n'; + flavorFile +='@import \'../mini/icon\';\n'; + flavorFile +='\n'; + } + if(flavorData.utility.enabled){ + + flavorFile +='$box-shadow-generic: 0 4*$__1px 4*$__1px 0 '+flavorData.utility.genericBoxShadowColor+', 0 2*$__1px 2*$__1px -2*$__1px '+flavorData.utility.genericBoxShadowColor+';\n'; + flavorFile +='$border-generic-color: '+flavorData.utility.genericBorderColor+'; // Border color for bordered elements.\n'; + flavorFile +='\n'; + flavorFile +='@import \'../mini/utility\';\n'; + flavorFile +='\n'; + } + console.log(flavorFile); } diff --git a/src/mini/_core.scss b/src/mini/_core.scss index 57a8178..b83c5c1 100644 --- a/src/mini/_core.scss +++ b/src/mini/_core.scss @@ -33,7 +33,7 @@ $horizontal-rule-line-height: 1.25em !default; //
line height $blockquote-quotation-size: 3rem !default; // Font size for the quotation of
$blockquote-cite-size: 0.75em !default; // Font size for the [cite] of
$code-font-family: 'Menlo, Consolas, monospace' !default; // Font stack for code elements -$code-font-size: 0.85em; // Font size for , +$code-font-size: 0.85em !default; // Font size for , $small-element-font-size: 0.75em !default; // Font size for , , $sup-top: -0.5em !default; // top $sub-bottom: -0.25em !default; // bottom diff --git a/src/mini/_utility.scss b/src/mini/_utility.scss index 16532b8..7790042 100644 --- a/src/mini/_utility.scss +++ b/src/mini/_utility.scss @@ -8,7 +8,7 @@ $border-generic-color: rgba(0,0,0, 0.3) !default; // Border color for bordered $border-rounded-name: 'rounded' !default; // Class name for rounded-border elements. $border-circular-name: 'circular' !default; // Class name for circular-border elements. $box-shadow-generic-name:'shadowed' !default; // Class name for box-shadow elements. -$box-shadow-generic: 0 4*$__1px 4*$__1px 0 rgba(0, 0, 0, 0.125), 0 2*$__1px 2*$__1px -2*$__1px rgba(0, 0, 0, 0.25); +$box-shadow-generic: 0 4*$__1px 4*$__1px 0 rgba(0, 0, 0, 0.125), 0 2*$__1px 2*$__1px -2*$__1px rgba(0, 0, 0, 0.25) !default; $responsive-margin-name: 'responsive-margin' !default; //Class name for responsive margin elements. $responsive-margin-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive margin elements. $responsive-margin-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive margin elements.