2025-06-24 00:35:17 +02:00

95 lines
2.2 KiB
SCSS

@use "@@/styles/shared" as *;
@use "@@/styles/tokens/tokens" as *;
.ds-chip {
@include reset;
@include stack-space($space-xx-small);
@include inline-space($font-space-xx-small);
position: relative;
display: inline-block;
font-family: $font-family-text;
line-height: $line-height-base;
padding: $font-space-xx-small $font-space-large;
padding-bottom: $font-space-xxx-small;
border-radius: $border-radius-base;
font-weight: $font-weight-bold;
color: $text-color-base;
background-color: $background-color-softest;
&.ds-chip-removable {
padding-right: $space-x-small + $space-small;
}
}
.ds-chip-inverse {
color: $text-color-inverse;
background-color: $background-color-inverse-softer;
}
.ds-chip-primary {
color: $text-color-primary-inverse;
background-color: $background-color-primary;
}
.ds-chip-success {
color: $text-color-success-inverse;
background-color: $background-color-success;
}
.ds-chip-warning {
color: $text-color-warning-inverse;
background-color: $background-color-warning;
}
.ds-chip-danger {
color: $text-color-danger-inverse;
background-color: $background-color-danger;
}
.ds-chip-round {
border-radius: $border-radius-rounded;
}
.ds-chip-size-small {
font-size: $font-size-xx-small;
padding: $font-space-xxx-small ($font-space-large + $font-space-xxx-small);
}
.ds-chip-size-base {
font-size: $font-size-small;
padding-left: $font-space-large + $font-space-xx-small;
padding-right: $font-space-large + $font-space-xx-small;
padding-top: $font-space-xxx-small;
}
.ds-chip-size-large {
font-size: $font-size-base;
padding-left: $font-space-x-large;
padding-right: $font-space-x-large;
padding-top: $font-space-xx-small;
padding-bottom: $font-space-xxx-small;
}
.ds-chip-close {
@include reset-button;
position: absolute;
right: $font-space-base;
top: 50%;
transform: translateY(-50%);
display: inline-flex;
align-items: center;
justify-content: center;
font-size: $font-size-x-small;
width: $space-small;
height: $space-small;
border-radius: $border-radius-circle;
//background-color: $background-color-base;
opacity: $opacity-soft;
cursor: pointer;
transition: all $duration-short $ease-out-sharp;
&:hover {
opacity: 1;
}
}