mirror of
https://github.com/material-components/material-web.git
synced 2024-09-11 21:57:41 +03:00
feff7214a7
These are excluded by default, but will be enabled by default in 2.0. Example: `tokens.md-comp-checkbox-values($exclude-custom-properties: false)` PiperOrigin-RevId: 601596085
89 lines
3.1 KiB
SCSS
89 lines
3.1 KiB
SCSS
//
|
|
// Copyright 2023 Google LLC
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
//
|
|
|
|
// go/keep-sorted start
|
|
@use 'sass:map';
|
|
// go/keep-sorted end
|
|
// go/keep-sorted start
|
|
@use './internal/validate';
|
|
@use './md-sys-color';
|
|
@use './md-sys-typescale';
|
|
@use './v0_192/md-comp-list';
|
|
// go/keep-sorted end
|
|
|
|
$supported-tokens: (
|
|
// go/keep-sorted start
|
|
'label-text-color',
|
|
'label-text-font',
|
|
'label-text-line-height',
|
|
'label-text-size',
|
|
'label-text-weight',
|
|
'overline-color',
|
|
'overline-font',
|
|
'overline-line-height',
|
|
'overline-size',
|
|
'overline-weight',
|
|
'supporting-text-color',
|
|
'supporting-text-font',
|
|
'supporting-text-line-height',
|
|
'supporting-text-size',
|
|
'supporting-text-weight',
|
|
'trailing-supporting-text-color',
|
|
'trailing-supporting-text-font',
|
|
'trailing-supporting-text-line-height',
|
|
'trailing-supporting-text-size',
|
|
'trailing-supporting-text-weight',
|
|
// go/keep-sorted end
|
|
);
|
|
|
|
$_default: (
|
|
'md-sys-color': md-sys-color.values-light(),
|
|
'md-sys-typescale': md-sys-typescale.values(),
|
|
);
|
|
|
|
@function values($deps: $_default, $exclude-hardcoded-values: false) {
|
|
// Note: <md-item> does not provide `--md-item-*` custom properties.
|
|
$list-tokens: md-comp-list.values($deps, $exclude-hardcoded-values);
|
|
|
|
$tokens: (
|
|
// go/keep-sorted start
|
|
'label-text-color': map.get($list-tokens, 'list-item-label-text-color'),
|
|
'label-text-font': map.get($list-tokens, 'list-item-label-text-font'),
|
|
'label-text-line-height':
|
|
map.get($list-tokens, 'list-item-label-text-line-height'),
|
|
'label-text-size': map.get($list-tokens, 'list-item-label-text-size'),
|
|
'label-text-weight': map.get($list-tokens, 'list-item-label-text-weight'),
|
|
'overline-color': map.get($list-tokens, 'list-item-overline-color'),
|
|
'overline-font': map.get($list-tokens, 'list-item-overline-font'),
|
|
'overline-line-height':
|
|
map.get($list-tokens, 'list-item-overline-line-height'),
|
|
'overline-size': map.get($list-tokens, 'list-item-overline-size'),
|
|
'overline-weight': map.get($list-tokens, 'list-item-overline-weight'),
|
|
'supporting-text-color':
|
|
map.get($list-tokens, 'list-item-supporting-text-color'),
|
|
'supporting-text-font':
|
|
map.get($list-tokens, 'list-item-supporting-text-font'),
|
|
'supporting-text-line-height':
|
|
map.get($list-tokens, 'list-item-supporting-text-line-height'),
|
|
'supporting-text-size':
|
|
map.get($list-tokens, 'list-item-supporting-text-size'),
|
|
'supporting-text-weight':
|
|
map.get($list-tokens, 'list-item-supporting-text-weight'),
|
|
'trailing-supporting-text-color':
|
|
map.get($list-tokens, 'list-item-trailing-supporting-text-color'),
|
|
'trailing-supporting-text-font':
|
|
map.get($list-tokens, 'list-item-trailing-supporting-text-font'),
|
|
'trailing-supporting-text-line-height':
|
|
map.get($list-tokens, 'list-item-trailing-supporting-text-line-height'),
|
|
'trailing-supporting-text-size':
|
|
map.get($list-tokens, 'list-item-trailing-supporting-text-size'),
|
|
'trailing-supporting-text-weight':
|
|
map.get($list-tokens, 'list-item-trailing-supporting-text-weight'),
|
|
// go/keep-sorted end
|
|
);
|
|
|
|
@return validate.values($tokens, $supported-tokens: $supported-tokens);
|
|
}
|