WIP - Move variables in respective their components
This commit is contained in:
parent
8d5ce8fa6c
commit
83697d5cd7
9 changed files with 118 additions and 131 deletions
|
@ -1,80 +1,5 @@
|
||||||
// Config file and project variables
|
// Config file and project variables
|
||||||
|
|
||||||
// ----------------
|
|
||||||
// Breakpoints zone
|
|
||||||
// ----------------
|
|
||||||
|
|
||||||
// Warning: you should use your own values, regardless of the devices
|
|
||||||
// Best practice is Mobile First: (min-width: $breakpoint)
|
|
||||||
$tiny : 480px !default; // or 'em' if you prefer, of course
|
|
||||||
$small : 576px !default;
|
|
||||||
$medium : 768px !default;
|
|
||||||
$large : 992px !default;
|
|
||||||
$extra-large : 1200px !default;
|
|
||||||
|
|
||||||
// ----------
|
|
||||||
// Fonts zone
|
|
||||||
// ----------
|
|
||||||
|
|
||||||
// Font families
|
|
||||||
$font-family-base : -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif !default; // system font stack
|
|
||||||
$font-family-headings : sans-serif !default; // font for h1, h2.. h6
|
|
||||||
$font-family-monospace : consolas, courier, monospace !default; // font for code and samples
|
|
||||||
|
|
||||||
// Font sizes (1.6rem value is "16px" equivalent)
|
|
||||||
$font-size-base : 1.6rem !default;
|
|
||||||
|
|
||||||
$font-sizes: (
|
|
||||||
base: (
|
|
||||||
mobile : 1.4rem,
|
|
||||||
desktop : $font-size-base
|
|
||||||
),
|
|
||||||
h1: (
|
|
||||||
mobile : 2.8rem,
|
|
||||||
desktop : 3.2rem
|
|
||||||
),
|
|
||||||
h2: (
|
|
||||||
mobile : 2.4rem,
|
|
||||||
desktop : 2.8rem
|
|
||||||
),
|
|
||||||
h3: (
|
|
||||||
mobile : 2.0rem,
|
|
||||||
desktop : 2.4rem
|
|
||||||
),
|
|
||||||
h4: (
|
|
||||||
mobile : 1.8rem,
|
|
||||||
desktop : 2.0rem
|
|
||||||
),
|
|
||||||
h5: (
|
|
||||||
mobile : 1.6rem,
|
|
||||||
desktop : 1.8rem
|
|
||||||
),
|
|
||||||
h6: (
|
|
||||||
mobile : 1.4rem,
|
|
||||||
desktop : 1.6rem
|
|
||||||
)
|
|
||||||
) !default;
|
|
||||||
|
|
||||||
// Line heights
|
|
||||||
$line-height-s : 1.3 !default;
|
|
||||||
$line-height-base : 1.5 !default;
|
|
||||||
$line-height-l : 1.7 !default;
|
|
||||||
|
|
||||||
// Default margin-bottom
|
|
||||||
$margin-bottom-base : 1rem !default;
|
|
||||||
$headings-margin-bottom : $margin-bottom-base /2 !default;
|
|
||||||
$paragraph-margin-bottom: $margin-bottom-base !default;
|
|
||||||
|
|
||||||
// Font weights
|
|
||||||
$weight-light : 200 !default;
|
|
||||||
$weight-book : 300 !default;
|
|
||||||
$weight-regular : 400 !default;
|
|
||||||
$weight-medium : 500 !default;
|
|
||||||
$weight-bold : 700 !default;
|
|
||||||
|
|
||||||
// Activate hyphenation on small screens
|
|
||||||
$hyphens: false !default;
|
|
||||||
|
|
||||||
// ------------
|
// ------------
|
||||||
// Spacing zone
|
// Spacing zone
|
||||||
// ------------
|
// ------------
|
||||||
|
@ -146,51 +71,13 @@ $color-inverse : $gray-800 !default;
|
||||||
$color-ghost : transparent !default;
|
$color-ghost : transparent !default;
|
||||||
$color-muted : $gray-200 !default;
|
$color-muted : $gray-200 !default;
|
||||||
|
|
||||||
$color-base : $gray-900 !default;
|
|
||||||
$background-base : $white !default;
|
|
||||||
|
|
||||||
$forms-color : $gray-800 !default;
|
|
||||||
|
|
||||||
// ---------------
|
// ---------------
|
||||||
// Components zone
|
// Components zone
|
||||||
// ---------------
|
// ---------------
|
||||||
|
|
||||||
// Component: links
|
|
||||||
$link-color : $gray-800 !default;
|
|
||||||
$link-color-hover : darken($link-color, 15%) !default;
|
|
||||||
$link-decoration : underline !default;
|
|
||||||
$link-decoration-hover : underline !default;
|
|
||||||
|
|
||||||
// Global border-radius
|
// Global border-radius
|
||||||
$border-radius: 0 !default;
|
$border-radius: 0 !default;
|
||||||
|
|
||||||
// Component: quotes
|
|
||||||
$quote-color : $gray-200 !default;
|
|
||||||
|
|
||||||
// Component: arrows
|
|
||||||
$arrow-color : $black !default;
|
|
||||||
|
|
||||||
// Components: checkboxes, radios, switches
|
|
||||||
$checkbox-color: $white !default;
|
|
||||||
$checkbox-background: $gray-800 !default;
|
|
||||||
$checkbox-size: 2rem !default;
|
|
||||||
$checkbox-border-radius: 4px !default;
|
|
||||||
$radio-color: $gray-800 !default;
|
|
||||||
$radio-background: $white !default;
|
|
||||||
$switch-color: $white !default;
|
|
||||||
$switch-background: $gray-800 !default;
|
|
||||||
$switch-size: 2rem !default;
|
|
||||||
$switch-border-radius: 3em !default;
|
|
||||||
|
|
||||||
// Component: tables
|
|
||||||
$table-border : $gray-500 !default;
|
|
||||||
$table-caption-color : $gray-800 !default;
|
|
||||||
$table-background : transparent !default;
|
|
||||||
$table-head-color : $color-base !default;
|
|
||||||
$table-head-background : transparent !default;
|
|
||||||
$table-footer-color : $color-base !default;
|
|
||||||
$table-footer-background : transparent !default;
|
|
||||||
|
|
||||||
// Components: buttons, badges, alerts color variants list
|
// Components: buttons, badges, alerts color variants list
|
||||||
// Convention is: name - background-color - color - border
|
// Convention is: name - background-color - color - border
|
||||||
$variants-list: (
|
$variants-list: (
|
||||||
|
@ -202,20 +89,3 @@ $variants-list: (
|
||||||
(inverse, $color-inverse, $white, none),
|
(inverse, $color-inverse, $white, none),
|
||||||
(ghost, $color-ghost, $white, 0 0 0 1px $white inset)
|
(ghost, $color-ghost, $white, 0 0 0 1px $white inset)
|
||||||
) !default;
|
) !default;
|
||||||
|
|
||||||
// Component: tabs
|
|
||||||
$tabs-border : $gray-200 !default;
|
|
||||||
$tabs-active-border : $gray-800 !default;
|
|
||||||
$tabs-color : $color-base !default;
|
|
||||||
$tabs-active-color : $gray-800 !default;
|
|
||||||
$tabs-background : transparent !default;
|
|
||||||
$tabs-active-background : transparent !default;
|
|
||||||
$tabs-border-radius : 0 !default;
|
|
||||||
|
|
||||||
// Component: nav burger button
|
|
||||||
$burger-color : $gray-800 !default;
|
|
||||||
$burger-background : transparent !default;
|
|
||||||
$burger-hover-background : transparent !default;
|
|
||||||
$burger-size : 2.6rem !default;
|
|
||||||
$burger-weight : 5px !default; // size of stripes
|
|
||||||
$burger-padding : 0 !default;
|
|
||||||
|
|
|
@ -2,6 +2,75 @@
|
||||||
/* ==Base (basic styles) */
|
/* ==Base (basic styles) */
|
||||||
/* ----------------------------- */
|
/* ----------------------------- */
|
||||||
|
|
||||||
|
$color-base : $gray-900 !default;
|
||||||
|
$background-base : $white !default;
|
||||||
|
|
||||||
|
$link-color : $gray-800 !default;
|
||||||
|
$link-color-hover : darken($link-color, 15%) !default;
|
||||||
|
$link-decoration : underline !default;
|
||||||
|
$link-decoration-hover : underline !default;
|
||||||
|
|
||||||
|
$quote-color : $gray-200 !default;
|
||||||
|
|
||||||
|
// Default margin-bottom
|
||||||
|
$margin-bottom-base : 1rem !default;
|
||||||
|
$headings-margin-bottom : $margin-bottom-base /2 !default;
|
||||||
|
$paragraph-margin-bottom: $margin-bottom-base !default;
|
||||||
|
|
||||||
|
// Line heights
|
||||||
|
$line-height-s : 1.3 !default;
|
||||||
|
$line-height-base : 1.5 !default;
|
||||||
|
$line-height-l : 1.7 !default;
|
||||||
|
|
||||||
|
// Font weights
|
||||||
|
$weight-light : 200 !default;
|
||||||
|
$weight-book : 300 !default;
|
||||||
|
$weight-regular : 400 !default;
|
||||||
|
$weight-medium : 500 !default;
|
||||||
|
$weight-bold : 700 !default;
|
||||||
|
|
||||||
|
// Activate hyphenation on small screens
|
||||||
|
$hyphens: false !default;
|
||||||
|
|
||||||
|
// Font families
|
||||||
|
$font-family-base : -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif !default; // system font stack
|
||||||
|
$font-family-headings : sans-serif !default; // font for h1, h2.. h6
|
||||||
|
$font-family-monospace : consolas, courier, monospace !default; // font for code and samples
|
||||||
|
|
||||||
|
// Font sizes (1.6rem value is "16px" equivalent)
|
||||||
|
$font-size-base : 1.6rem !default;
|
||||||
|
|
||||||
|
$font-sizes: (
|
||||||
|
base: (
|
||||||
|
mobile : 1.4rem,
|
||||||
|
desktop : $font-size-base
|
||||||
|
),
|
||||||
|
h1: (
|
||||||
|
mobile : 2.8rem,
|
||||||
|
desktop : 3.2rem
|
||||||
|
),
|
||||||
|
h2: (
|
||||||
|
mobile : 2.4rem,
|
||||||
|
desktop : 2.8rem
|
||||||
|
),
|
||||||
|
h3: (
|
||||||
|
mobile : 2.0rem,
|
||||||
|
desktop : 2.4rem
|
||||||
|
),
|
||||||
|
h4: (
|
||||||
|
mobile : 1.8rem,
|
||||||
|
desktop : 2.0rem
|
||||||
|
),
|
||||||
|
h5: (
|
||||||
|
mobile : 1.6rem,
|
||||||
|
desktop : 1.8rem
|
||||||
|
),
|
||||||
|
h6: (
|
||||||
|
mobile : 1.4rem,
|
||||||
|
desktop : 1.6rem
|
||||||
|
)
|
||||||
|
) !default;
|
||||||
|
|
||||||
/* switching to border-box model for all elements */
|
/* switching to border-box model for all elements */
|
||||||
html {
|
html {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
|
|
@ -2,6 +2,14 @@
|
||||||
/* ==Responsive helpers */
|
/* ==Responsive helpers */
|
||||||
/* -------------------------- */
|
/* -------------------------- */
|
||||||
|
|
||||||
|
// Warning: you should use your own values, regardless of the devices
|
||||||
|
// Best practice is Mobile First: (min-width: $breakpoint)
|
||||||
|
$tiny : 480px !default; // or 'em' if you prefer, of course
|
||||||
|
$small : 576px !default;
|
||||||
|
$medium : 768px !default;
|
||||||
|
$large : 992px !default;
|
||||||
|
$extra-large : 1200px !default;
|
||||||
|
|
||||||
/* large screens */
|
/* large screens */
|
||||||
/* ------------- */
|
/* ------------- */
|
||||||
|
|
||||||
|
|
|
@ -3,6 +3,8 @@
|
||||||
/* ----------------------------- */
|
/* ----------------------------- */
|
||||||
/* see https://knacss.com/styleguide.html#arrows */
|
/* see https://knacss.com/styleguide.html#arrows */
|
||||||
|
|
||||||
|
$arrow-color : $black !default;
|
||||||
|
|
||||||
[class*="icon-arrow--"] {
|
[class*="icon-arrow--"] {
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
|
|
||||||
|
|
|
@ -4,6 +4,13 @@
|
||||||
/* preferably use <button> for buttons !*/
|
/* preferably use <button> for buttons !*/
|
||||||
/* use .btn-- or .button-- classes for variants */
|
/* use .btn-- or .button-- classes for variants */
|
||||||
|
|
||||||
|
$burger-color : $gray-800 !default;
|
||||||
|
$burger-background : transparent !default;
|
||||||
|
$burger-hover-background : transparent !default;
|
||||||
|
$burger-size : 2.6rem !default;
|
||||||
|
$burger-weight : 5px !default; // size of stripes
|
||||||
|
$burger-padding : 0 !default;
|
||||||
|
|
||||||
%btn {
|
%btn {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: $spacer-small $spacer-small-plus;
|
padding: $spacer-small $spacer-small-plus;
|
||||||
|
|
|
@ -8,6 +8,19 @@
|
||||||
/* use .switch class on input type=checkbox */
|
/* use .switch class on input type=checkbox */
|
||||||
// <input type="checkbox" class="switch" id="switch"><label for="switch" class="label">slide to unlock</label>
|
// <input type="checkbox" class="switch" id="switch"><label for="switch" class="label">slide to unlock</label>
|
||||||
|
|
||||||
|
$checkbox-color: $white !default;
|
||||||
|
$checkbox-background: $gray-800 !default;
|
||||||
|
$checkbox-size: 2rem !default;
|
||||||
|
$checkbox-border-radius: 4px !default;
|
||||||
|
|
||||||
|
$radio-color: $gray-800 !default;
|
||||||
|
$radio-background: $white !default;
|
||||||
|
|
||||||
|
$switch-color: $white !default;
|
||||||
|
$switch-background: $gray-800 !default;
|
||||||
|
$switch-size: 2rem !default;
|
||||||
|
$switch-border-radius: 3em !default;
|
||||||
|
|
||||||
// common styles
|
// common styles
|
||||||
.checkbox {
|
.checkbox {
|
||||||
border-radius: $checkbox-border-radius;
|
border-radius: $checkbox-border-radius;
|
||||||
|
@ -116,4 +129,4 @@
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
background-color: $radio-background;
|
background-color: $radio-background;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,6 +3,8 @@
|
||||||
/* ----------------------------- */
|
/* ----------------------------- */
|
||||||
/* thanks to HTML5boilerplate and https://shoelace.style/ */
|
/* thanks to HTML5boilerplate and https://shoelace.style/ */
|
||||||
|
|
||||||
|
$forms-color: $gray-800 !default;
|
||||||
|
|
||||||
/* forms items */
|
/* forms items */
|
||||||
form,
|
form,
|
||||||
fieldset {
|
fieldset {
|
||||||
|
|
|
@ -2,6 +2,14 @@
|
||||||
/* ==Tables */
|
/* ==Tables */
|
||||||
/* ----------------------------- */
|
/* ----------------------------- */
|
||||||
|
|
||||||
|
$table-border : $gray-500 !default;
|
||||||
|
$table-caption-color : $gray-800 !default;
|
||||||
|
$table-background : transparent !default;
|
||||||
|
$table-head-color : $color-base !default;
|
||||||
|
$table-head-background : transparent !default;
|
||||||
|
$table-footer-color : $color-base !default;
|
||||||
|
$table-footer-background : transparent !default;
|
||||||
|
|
||||||
table,
|
table,
|
||||||
.table {
|
.table {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
|
@ -4,6 +4,14 @@
|
||||||
/* see example on https://knacss.com/styleguide.html#tabs */
|
/* see example on https://knacss.com/styleguide.html#tabs */
|
||||||
/* NOTE : tabs need JavaScript to be activated */
|
/* NOTE : tabs need JavaScript to be activated */
|
||||||
|
|
||||||
|
$tabs-border : $gray-200 !default;
|
||||||
|
$tabs-active-border : $gray-800 !default;
|
||||||
|
$tabs-color : $color-base !default;
|
||||||
|
$tabs-active-color : $gray-800 !default;
|
||||||
|
$tabs-background : transparent !default;
|
||||||
|
$tabs-active-background : transparent !default;
|
||||||
|
$tabs-border-radius : 0 !default;
|
||||||
|
|
||||||
.tabs-menu {
|
.tabs-menu {
|
||||||
border-bottom: 2px solid $tabs-border;
|
border-bottom: 2px solid $tabs-border;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue