/* variables specific to current element */ $element-specific-variables: ""; .#{$namespace}toggleTab { /* Save root element context for easy access if nesting is needed */ $self: &; /* properties of current element + media queries */ @include custom-prop-fallback("background-color","sys-color-elevation-surface-sunken"); border-radius: map-deep-get($token-radius-map, "32"); display: inline-flex; @include spacer-component-inset("xs"); /* 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 */ // toggleTab__childElement &__btn#{$self}__btn { // follows same logic as parent background-color: transparent ; //min-height: map-deep-get($token-spacer); &.active, &.-isActive { @include custom-prop-fallback("background-color","comp-button-secondary-hovered-background-color"); } INPUT:checked + & { @include custom-prop-fallback("background-color", "comp-button-secondary-hovered-background-color"); } INPUT:checked:focus-visible + & { outline-style: solid !important; outline-width: map-deep-get($design-tokens, "comp-button-pressed-border-width") !important; } } /* modifiers */ // toggleTab -fullWidth &.-fullWidth { // follows same logic as base element width: 100%; > * { flex-grow: 1; } #{$self}__btn { width: 100%; } } &.-light { @include custom-prop-fallback("background-color","sys-color-elevation-surface-flat"); } /* random parent element */ /* * * Syntax : .randomParentElt & {} * */ /* Pseudo Classes */ &:hover { @media (hover: hover) { } } &:focus { } &:active { } &:focus, &:active { } }