bulma/sass/components/menu.sass

60 lines
1.7 KiB
Sass
Raw Normal View History

2020-10-31 23:52:27 +00:00
@import "../utilities/mixins"
2017-07-28 20:05:15 +00:00
$menu-item-color: $text !default
2017-07-26 20:06:52 +00:00
$menu-item-radius: $radius-small !default
2017-07-28 20:05:15 +00:00
$menu-item-hover-color: $text-strong !default
$menu-item-hover-background-color: $background !default
$menu-item-active-color: $link-invert !default
$menu-item-active-background-color: $link !default
2017-07-26 20:06:52 +00:00
2017-07-28 20:05:15 +00:00
$menu-list-border-left: 1px solid $border !default
2019-05-17 12:50:39 +00:00
$menu-list-line-height: 1.25 !default
$menu-list-link-padding: 0.5em 0.75em !default
$menu-nested-list-margin: 0.75em !default
$menu-nested-list-padding-left: 0.75em !default
2017-07-26 20:06:52 +00:00
2017-07-28 20:05:15 +00:00
$menu-label-color: $text-light !default
2019-05-17 12:50:39 +00:00
$menu-label-font-size: 0.75em !default
$menu-label-letter-spacing: 0.1em !default
$menu-label-spacing: 1em !default
2017-07-26 20:06:52 +00:00
2016-10-30 19:20:51 +00:00
.menu
2017-07-28 20:05:15 +00:00
font-size: $size-normal
// Sizes
&.is-small
font-size: $size-small
&.is-medium
font-size: $size-medium
&.is-large
font-size: $size-large
2016-01-24 00:03:43 +00:00
.menu-list
2019-05-17 12:50:39 +00:00
line-height: $menu-list-line-height
2016-01-24 00:03:43 +00:00
a
2017-07-26 20:06:52 +00:00
border-radius: $menu-item-radius
2017-07-28 20:05:15 +00:00
color: $menu-item-color
2016-03-25 13:38:40 +00:00
display: block
2019-05-17 12:50:39 +00:00
padding: $menu-list-link-padding
2016-01-24 00:03:43 +00:00
&:hover
2017-07-28 20:05:15 +00:00
background-color: $menu-item-hover-background-color
color: $menu-item-hover-color
2016-04-10 15:27:27 +00:00
// Modifiers
2016-01-31 11:04:28 +00:00
&.is-active
2017-07-28 20:05:15 +00:00
background-color: $menu-item-active-background-color
color: $menu-item-active-color
2016-04-10 15:27:27 +00:00
li
ul
2020-01-22 09:14:04 +00:00
+ltr-property("border", $menu-list-border-left, false)
2019-05-17 12:50:39 +00:00
margin: $menu-nested-list-margin
2020-01-22 09:14:04 +00:00
+ltr-property("padding", $menu-nested-list-padding-left, false)
2016-01-31 11:04:28 +00:00
2016-03-25 13:38:40 +00:00
.menu-label
2017-07-28 20:05:15 +00:00
color: $menu-label-color
2019-05-17 12:50:39 +00:00
font-size: $menu-label-font-size
letter-spacing: $menu-label-letter-spacing
2016-03-25 13:38:40 +00:00
text-transform: uppercase
&:not(:first-child)
2019-05-17 12:50:39 +00:00
margin-top: $menu-label-spacing
2016-10-30 19:20:51 +00:00
&:not(:last-child)
2019-05-17 12:50:39 +00:00
margin-bottom: $menu-label-spacing