/* variables specific to current element */ $element-specific-variables: ""; .#{$namespace}listItem { /* Save root element context for easy access if nesting is needed */ $self: &; /* properties of current element + media queries */ display: flex; align-items: center; border-radius: map-deep-get($token-radius-map,"16"); @include spacer-component-inset("sm"); @include spacer-component-inline("md"); width: 100%; // Needed if item is button text-align: left; // Needed if item is button @include custom-prop-fallback("background-color", "sys-color-elevation-surface-flat"); /* 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 */ &__inner { @include spacer-component-inline("md"); display: flex; align-items: center; position: relative; flex-grow: 1; margin: 0 !important; } // listItem__text &__text { // follows same logic as parent min-width: 0; // necessary if text overflow applied //flex-shrink: 0; } // listItem__textMain &__textMain { display: block; @include text-truncate(); &.#{$namespace}textBodyLg { font-weight: map-deep-get($token-font-weight-map, "semi-bold"); } + #{$self}__description, + #{$self}__textMeta { //margin-top: 2px; //@TODO exception? } } &__textMeta { @include custom-prop-fallback("color", "sys-color-text-primary-muted"); } &__rightContent { display: flex; align-items: center; margin-left: auto; @include spacer-component-inline("md"); &.-number { justify-content: space-between; width: 25%; } } &__collapseTrigger { position: absolute; top: 0; left: 0; width: 100%; height: 100%; } &__collapse{ transition: none !important; } &__status { font-weight: map-deep-get($token-font-weight-map, "semi-bold"); &.-positive { @include custom-prop-fallback("color", "sys-color-text-status-success-vivid"); } &.-neg { @include custom-prop-fallback("color", "sys-color-text-status-danger-vivid"); } } &__iconCircleTextGroup { margin-top: map-deep-get($token-spacer-unit-map, "8"); } &__detail { box-shadow: map-deep-get($token-shadow-map, "active"); position: relative; // necessary for shadow to show above next element margin: 0 (-($timeline-item-horiz-padding-global)); } &__detailHeader { margin-bottom: map-deep-get($token-spacer-unit-map, "48"); margin-left: -8px; margin-right: -8px; position: relative; width: auto; #{$self}__rightContent { margin-right: 0; } } &__detailHelperText { @include custom-prop-fallback("color", "sys-color-text-primary-vivid"); font-size: map-deep-get($token-font-size-map, "body", "s"); } &__detailText { font-size: map-deep-get($token-font-size-map, "body", "xl"); &.-success100 { @include custom-prop-fallback("color", "sys-color-text-status-success-vivid"); } } &__transactionState, &__transactionState > * { @include text-truncate(); [class*="icon"] { flex-shrink: 0; } } &__secondary100 { @include custom-prop-fallback("color", "sys-color-text-primary-vivid"); } &__creditCard { width: map-deep-get($token-sizes-unit-map, "40"); } /* modifiers */ // listItem -headingText &.-headingText { // follows same logic as base element #{$self}__textMain { @extend .h5; } } // listItem -rounded &.-rounded { border-radius: map-deep-get($token-radius-map, "32"); } &.-action { align-items: flex-start; #{$self}__avatar { margin-top: map-deep-get($token-spacer-unit-map, "4"); } #{$self}__textMeta { @include custom-prop-fallback("color", "sys-color-text-primary-contrast"); } } &.-disabled { pointer-events: none; opacity: .4; } &.-dom { #{$self}__textMeta { font-weight: map-deep-get($token-font-weight-map, "semi-bold"); margin-top: map-deep-get($token-spacer-unit-map, "4"); margin-bottom: map-deep-get($token-spacer-unit-map, "2"); } } &.-insetMd { @include spacer-component-inset("md"); } &.-insetLg, &.-paddingLg { @include spacer-component-inset("lg"); } /* random parent element */ /* * * Syntax : .randomParentElt & {} * */ &Wrapper { position: relative; @include hover() { > #{$self} { @include custom-prop-fallback("background-color", "sys-color-elevation-surface-sunken"); } } &.-detailShown { > #{$self} { display: none; } } } /* Pseudo Classes */ &:hover { @media (hover: hover) { } } &:focus { } &:active { } &:focus, &:active { } }