/* variables specific to current element */ $element-specific-variables: ""; .#{$namespace}badgeSelector { /* Save root element context for easy access if nesting is needed */ $self: &; /* properties of current element + media queries */ @include custom-prop-fallback("background-color", "comp-button-secondary-background-color"); @include custom-prop-fallback("color", "sys-color-text-primary-muted"); border-radius: map-deep-get($token-radius-map, "16"); display: inline-flex; align-items: center; justify-content: center; min-width: map-deep-get($token-sizes-unit-map, "48"); min-height: $badge-selector-height-global; padding: map-deep-get($token-spacer-inset-map, "sm"); gap: map-deep-get($token-spacer-inline-map, "sm"); border: $border-width*2 solid transparent; /* Pseudo Elements */ &::before { } &::after { } /* Include elements that are linked to the current element but have to reside at the root level of the stylesheet (e.g: keyframes) */ @at-root { } /* children - write selector in full in comments in order to facilitate search */ // badgeSelector__text &__text { // follows same logic as parent font-weight: map-deep-get($token-font-weight-map, "semi-bold"); } &[aria-pressed="true"] { @include custom-prop-fallback("border-color", "sys-color-text-primary-vivid","true","true"); @include custom-prop-fallback("color", "sys-color-text-primary-vivid"); } /* modifiers */ // badgeSelector -isSelected &.-isSelected { // follows same logic as base element @include custom-prop-fallback("border-color", "sys-color-text-primary-vivid","true","true"); @include custom-prop-fallback("color", "sys-color-text-primary-vivid"); } &.-large { width: auto; height: auto; padding: 1em; border-radius: map-deep-get($token-radius-map, "24"); [class*="icon"] { &::before { @extend %textBodyXxl; line-height: 1; } } #{$self}__text { text-align: center; font-weight: map-deep-get($token-font-weight-map, "bold"); } &.-hasText { padding: 0.9915em 1.38125em; @extend %textBodyXl; } } &.-hasText { padding: 0.5em 1.5em; } &.-cta { @include custom-prop-fallback("background-color", "comp-button-secondary-inverse-background-color"); @include custom-prop-fallback("color", "comp-button-secondary-text-color"); &:hover, &:focus { @media (hover: hover) { @include custom-prop-fallback("background-color", "comp-button-secondary-hovered-background-color", true, true); } } } &.-colorOption { padding-right: $input-padding-x*2; &.-labelHiddenMobile { @include media-breakpoint-between("xs","sm") { padding-right: map-deep-get($token-spacer-inset-map, "sm"); #{$self}__text { display: none; } } } } &.-isDisabled, [disabled] + & { @include custom-prop-fallback("color", "comp-button-secondary-disabled-text-color","true","true"); } /* random parent element */ /* * * Syntax : .randomParentElt & {} * */ /* Pseudo Classes */ &:hover, &:focus { @media (hover: hover) { @include custom-prop-fallback("background-color", "comp-button-secondary-hovered-background-color", true, true); } } &:focus { } &:active { } &:focus, &:active { } }