Files
openfoodnetwork/app/webpacker/css/admin_v3/components/buttons.scss
Jean-Baptiste Bellet 352cf2ff71 Import typography.scss for admin_v3
And do not apply `a` style to `.button` element.

ie.
```
a:not(.button)
```
2023-07-25 14:29:00 +02:00

109 lines
2.0 KiB
SCSS

input[type="submit"],
input[type="button"]:not(.trix-button),
button:not(.plain):not(.trix-button),
.button {
position: relative;
cursor: pointer;
font-size: 14px;
@include border-radius($border-radius);
display: inline-block;
padding: 0px 12px;
background-color: $color-btn-bg;
border: 1px solid $color-btn-bg;
color: $color-btn-text;
text-transform: uppercase;
line-height: 40px;
height: 40px;
font-weight: bold;
&:before {
font-weight: normal !important;
}
&:active,
&:focus {
outline: none;
border: 1px solid $color-btn-hover-border;
}
&:active:focus {
box-shadow: none;
}
&:hover {
background-color: $color-btn-hover-bg;
border: 1px solid $color-btn-hover-bg;
color: $color-btn-hover-text;
}
&.fullwidth {
width: 100%;
text-align: center;
}
&.secondary {
background-color: transparent;
border: 1px solid $color-btn-bg;
color: $color-btn-bg;
&:hover {
background-color: $color-11;
border: 1px solid $color-10;
color: $color-10;
}
&:active,
&:focus {
background-color: $color-11;
border: 1px solid $color-4;
color: $color-4;
}
}
&.disruptive {
background-color: transparent;
border: 1px solid $color-5;
color: $color-5;
&:hover {
background-color: $fair-pink;
border: 1px solid $color-5;
color: $color-5;
}
&:active,
&:focus {
background-color: $fair-pink;
border: 1px solid $roof-terracotta;
color: $roof-terracotta;
}
}
&.medium {
line-height: $btn-medium-height;
height: $btn-medium-height;
}
.badge {
position: absolute;
top: 0;
right: 0;
transform: translateY(-50%);
font-size: 10px;
text-transform: capitalize;
padding: 0px 5px;
border-radius: 3px;
&:before {
padding: 0;
}
&.danger {
background-color: $warning-red;
}
&.success {
background-color: $spree-green;
}
}
}