Merge branch 'master' into css-variables

This commit is contained in:
Jeremy Thomas
2020-03-16 18:48:36 +11:00
70 changed files with 19779 additions and 581 deletions

View File

@@ -101,7 +101,7 @@ $alignments: ('centered': 'center', 'justified': 'justify', 'left': 'left', 'rig
a.has-text-#{$name}
&:hover,
&:focus
color: darken($color, 10%) !important
color: bulmaDarken($color, 10%) !important
.has-background-#{$name}
background-color: $color !important

View File

@@ -32,7 +32,7 @@ $navbar-dropdown-radius: $radius-large !default
$navbar-dropdown-z: 20 !default
$navbar-dropdown-boxed-radius: $radius-large !default
$navbar-dropdown-boxed-shadow: 0 8px 8px rgba($scheme-invert, 0.1), 0 0 0 1px rgba($scheme-invert, 0.1) !default
$navbar-dropdown-boxed-shadow: 0 8px 8px bulmaRgba($scheme-invert, 0.1), 0 0 0 1px bulmaRgba($scheme-invert, 0.1) !default
$navbar-dropdown-item-hover-color: $scheme-invert !default
$navbar-dropdown-item-hover-background-color: $background !default
@@ -72,7 +72,7 @@ $navbar-breakpoint: $desktop !default
&:focus,
&:hover,
&.is-active
background-color: darken($color, 5%)
background-color: bulmaDarken($color, 5%)
color: $color-invert
.navbar-link
&::after
@@ -90,7 +90,7 @@ $navbar-breakpoint: $desktop !default
&:focus,
&:hover,
&.is-active
background-color: darken($color, 5%)
background-color: bulmaDarken($color, 5%)
color: $color-invert
.navbar-link
&::after
@@ -98,7 +98,7 @@ $navbar-breakpoint: $desktop !default
.navbar-item.has-dropdown:focus .navbar-link,
.navbar-item.has-dropdown:hover .navbar-link,
.navbar-item.has-dropdown.is-active .navbar-link
background-color: darken($color, 5%)
background-color: bulmaDarken($color, 5%)
color: $color-invert
.navbar-dropdown
a.navbar-item
@@ -245,7 +245,7 @@ a.navbar-item,
display: none
.navbar-menu
background-color: $navbar-background-color
box-shadow: 0 8px 16px rgba($scheme-invert, 0.1)
box-shadow: 0 8px 16px bulmaRgba($scheme-invert, 0.1)
padding: 0.5rem 0
&.is-active
display: block
@@ -257,7 +257,7 @@ a.navbar-item,
&.is-fixed-bottom-touch
bottom: 0
&.has-shadow
box-shadow: 0 -2px 3px rgba($scheme-invert, 0.1)
box-shadow: 0 -2px 3px bulmaRgba($scheme-invert, 0.1)
&.is-fixed-top-touch
top: 0
&.is-fixed-top,
@@ -331,7 +331,7 @@ a.navbar-item,
border-radius: $navbar-dropdown-radius $navbar-dropdown-radius 0 0
border-top: none
bottom: 100%
box-shadow: 0 -8px 8px rgba($scheme-invert, 0.1)
box-shadow: 0 -8px 8px bulmaRgba($scheme-invert, 0.1)
top: auto
&.is-active,
&.is-hoverable:focus,
@@ -358,7 +358,7 @@ a.navbar-item,
border-bottom-left-radius: $navbar-dropdown-radius
border-bottom-right-radius: $navbar-dropdown-radius
border-top: $navbar-dropdown-border-top
box-shadow: 0 8px 8px rgba($scheme-invert, 0.1)
box-shadow: 0 8px 8px bulmaRgba($scheme-invert, 0.1)
display: none
font-size: 0.875rem
left: 0
@@ -409,7 +409,7 @@ a.navbar-item,
&.is-fixed-bottom-desktop
bottom: 0
&.has-shadow
box-shadow: 0 -2px 3px rgba($scheme-invert, 0.1)
box-shadow: 0 -2px 3px bulmaRgba($scheme-invert, 0.1)
&.is-fixed-top-desktop
top: 0
html,

View File

@@ -21,6 +21,7 @@ $button-active-color: $link-active !default
$button-active-border-color: $link-active-border !default
$button-text-color: $text !default
$button-text-decoration: underline !default
$button-text-hover-background-color: $background !default
$button-text-hover-color: $text-strong !default
$button-text-focus-background-color: $border-light !default
@@ -105,7 +106,7 @@ $button-static-border-color: $border !default
background-color: transparent
border-color: transparent
color: $button-text-color
text-decoration: underline
text-decoration: $button-text-decoration
&:hover,
&.is-hovered,
&:focus,
@@ -114,7 +115,7 @@ $button-static-border-color: $border !default
color: $button-text-hover-color
&:active,
&.is-active
background-color: darken($button-text-hover-background-color, 5%)
background-color: bulmaDarken($button-text-hover-background-color, 5%)
color: $button-text-hover-color
&[disabled],
fieldset[disabled] &
@@ -130,7 +131,7 @@ $button-static-border-color: $border !default
color: $color-invert
&:hover,
&.is-hovered
background-color: darken($color, 2.5%)
background-color: bulmaDarken($color, 2.5%)
border-color: transparent
color: $color-invert
&:focus,
@@ -138,10 +139,10 @@ $button-static-border-color: $border !default
border-color: transparent
color: $color-invert
&:not(:active)
box-shadow: $button-focus-box-shadow-size rgba($color, 0.25)
box-shadow: $button-focus-box-shadow-size bulmaRgba($color, 0.25)
&:active,
&.is-active
background-color: darken($color, 5%)
background-color: bulmaDarken($color, 5%)
border-color: transparent
color: $color-invert
&[disabled],
@@ -154,7 +155,7 @@ $button-static-border-color: $border !default
color: $color
&:hover,
&.is-hovered
background-color: darken($color-invert, 5%)
background-color: bulmaDarken($color-invert, 5%)
&[disabled],
fieldset[disabled] &
background-color: $color-invert
@@ -222,12 +223,12 @@ $button-static-border-color: $border !default
color: $color-dark
&:hover,
&.is-hovered
background-color: darken($color-light, 2.5%)
background-color: bulmaDarken($color-light, 2.5%)
border-color: transparent
color: $color-dark
&:active,
&.is-active
background-color: darken($color-light, 5%)
background-color: bulmaDarken($color-light, 5%)
border-color: transparent
color: $color-dark
// Sizes

View File

@@ -29,19 +29,19 @@ $file-name-max-width: 16em !default
&:hover,
&.is-hovered
.file-cta
background-color: darken($color, 2.5%)
background-color: bulmaDarken($color, 2.5%)
border-color: transparent
color: $color-invert
&:focus,
&.is-focused
.file-cta
border-color: transparent
box-shadow: 0 0 0.5em rgba($color, 0.25)
box-shadow: 0 0 0.5em bulmaRgba($color, 0.25)
color: $color-invert
&:active,
&.is-active
.file-cta
background-color: darken($color, 5%)
background-color: bulmaDarken($color, 5%)
border-color: transparent
color: $color-invert
// Sizes
@@ -125,16 +125,16 @@ $file-name-max-width: 16em !default
position: relative
&:hover
.file-cta
background-color: darken($file-cta-background-color, 2.5%)
background-color: bulmaDarken($file-cta-background-color, 2.5%)
color: $file-cta-hover-color
.file-name
border-color: darken($file-name-border-color, 2.5%)
border-color: bulmaDarken($file-name-border-color, 2.5%)
&:active
.file-cta
background-color: darken($file-cta-background-color, 5%)
background-color: bulmaDarken($file-cta-background-color, 5%)
color: $file-cta-active-color
.file-name
border-color: darken($file-name-border-color, 5%)
border-color: bulmaDarken($file-name-border-color, 5%)
.file-input
height: 100%

View File

@@ -18,7 +18,7 @@ $textarea-min-height: 8em !default
&.is-focused,
&:active,
&.is-active
box-shadow: $input-focus-box-shadow-size rgba($color, 0.25)
box-shadow: $input-focus-box-shadow-size bulmaRgba($color, 0.25)
// Sizes
&.is-small
+control-small

View File

@@ -49,12 +49,12 @@
border-color: $color
&:hover,
&.is-hovered
border-color: darken($color, 5%)
border-color: bulmaDarken($color, 5%)
&:focus,
&.is-focused,
&:active,
&.is-active
box-shadow: $input-focus-box-shadow-size rgba($color, 0.25)
box-shadow: $input-focus-box-shadow-size bulmaRgba($color, 0.25)
// Sizes
&.is-small
+control-small

View File

@@ -41,7 +41,7 @@ $hero-body-padding-large: 18rem 1.5rem !default
.navbar-link
&:hover,
&.is-active
background-color: darken($color, 5%)
background-color: bulmaDarken($color, 5%)
color: $color-invert
.tabs
a
@@ -65,13 +65,14 @@ $hero-body-padding-large: 18rem 1.5rem !default
border-color: $color-invert
color: $color
// Modifiers
&.is-bold
$gradient-top-left: darken(saturate(adjust-hue($color, -10deg), 10%), 10%)
$gradient-bottom-right: lighten(saturate(adjust-hue($color, 10deg), 5%), 5%)
background-image: linear-gradient(141deg, $gradient-top-left 0%, $color 71%, $gradient-bottom-right 100%)
+mobile
.navbar-menu
background-image: linear-gradient(141deg, $gradient-top-left 0%, $color 71%, $gradient-bottom-right 100%)
@if type-of($color) == 'color'
&.is-bold
$gradient-top-left: darken(saturate(adjust-hue($color, -10deg), 10%), 10%)
$gradient-bottom-right: lighten(saturate(adjust-hue($color, 10deg), 5%), 5%)
background-image: linear-gradient(141deg, $gradient-top-left 0%, $color 71%, $gradient-bottom-right 100%)
+mobile
.navbar-menu
background-image: linear-gradient(141deg, $gradient-top-left 0%, $color 71%, $gradient-bottom-right 100%)
// Sizes
&.is-small
.hero-body

View File

@@ -62,6 +62,8 @@
@return $value
@function colorLuminance($color)
@if type-of($color) != 'color'
@return 0.55
$color-rgb: ('red': red($color),'green': green($color),'blue': blue($color))
@each $name, $value in $color-rgb
$adjusted: 0
@@ -105,6 +107,11 @@
@return $hue, $saturation, $lightness
@function bulmaRgba($color, $alpha)
@if type-of($color) == 'color'
@return rgba($color, $alpha)
@return $color
@if type-of($color) != 'color'
@return $color
@return rgba($color, $alpha)
@function bulmaDarken($color, $amount)
@if type-of($color) != 'color'
@return $color
@return darken($color, $amount)