No notes defined.
<div class="sds-amount -processing">
<span class="sds-amount__value">{#.###,##}</span>
<span class="sds-amount__currency">€</span>
</div>
<div class="{{ namespace }}amount{% for mod in modifiers %} {{ mod }}{% endfor %}{% for mod in classes %} {{ mod }}{% endfor %}">
<span class="{{ namespace }}amount__value">{{ text }}</span>
{% if currency %}
<span class="{{ namespace }}amount__currency">{{ currency }}</span>
{% endif %}
{% if frequency %}
<span class="{{ namespace }}amount__frequency">
{{ frequency }}
</span>
{% endif %}
</div>
/* variables specific to current element */
.#{$namespace}amount {
/* Save root element context for easy access if nesting is needed */
$self: &;
/* properties of current element + media queries */
display: inline-flex;
align-items: center;
font-weight: map-deep-get($token-font-weight-map, "semi-bold");
flex-shrink: 0;
@include custom-prop-fallback("color","sys-color-text-primary-contrast");
/* 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 */
// amount__childElement
&__currency {
// follows same logic as parent
margin-left: 0.15em;
}
&__frequency {
margin-left: 0.35em;
margin-top: -0.35em;
font-size: 0.7em; // => base font MAX
line-height: $line-height-base; // => base font line height
font-weight: inherit;
position: relative;
top: -0.1em; // positioning tweak
align-self: flex-end;
}
/* modifiers */
// amount -positive
&.-positive {
// follows same logic as base element
@include custom-prop-fallback("color", "sys-color-text-status-success-vivid");
}
// amount -negative
&.-negative {
// follows same logic as base element
@include custom-prop-fallback("color", "sys-color-text-status-danger-vivid");
&.-fade {
font-style: italic;
@include custom-prop-fallback("color", "sys-color-text-secondary-muted");
}
}
&.-processing {
// follows same logic as base element
@include custom-prop-fallback("color", "sys-color-text-status-warning-vivid");
}
&.-secondary100 {
@include custom-prop-fallback("color", "sys-color-text-primary-vivid");
}
&.-highlight100 {
@include custom-prop-fallback("color", "sys-color-text-highlight-vivid");
}
&.-amountXs {
font-size: map-deep-get($design-tokens, "sys-font-size-helper-small");
}
&.-amountSm {
@extend %textHelper;
}
&.-amountLg {
@extend %textBodyLg;
}
&.-amountXl {
@extend %textBodyXl;
font-weight: map-deep-get($token-font-weight-map, "bold");
}
&.-amountXxl {
@extend %textBodyXxl;
font-weight: map-deep-get($token-font-weight-map, "regular");
}
&.-regular {
font-weight: map-deep-get($token-font-weight-map, "regular");
}
//&.-huge {
// font-size: map-deep-get($token-font-size-map, "body", "xxl");
// line-height: map-deep-get($token-font-line-height-map, "l");
//}
/* random parent element */
/*
*
* Syntax : .randomParentElt & {}
*
*/
/* Pseudo Classes */
&:hover {
@media (hover: hover) {
}
}
&:focus {
}
&:active {
}
&:focus,
&:active {
}
}