@angular/material 17.1.1 → 17.2.0-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_index.scss +4 -4
- package/badge/_badge-theme.scss +30 -11
- package/button/_button-base.scss +50 -10
- package/button/_button-theme.scss +92 -51
- package/button/_fab-theme.scss +82 -15
- package/button/_icon-button-theme.scss +11 -4
- package/button-toggle/_button-toggle-theme.scss +26 -11
- package/checkbox/_checkbox-theme.scss +41 -23
- package/chips/_chips-theme.scss +25 -9
- package/core/_core-theme.scss +85 -38
- package/core/mdc-helpers/_mdc-helpers.scss +0 -8
- package/core/option/_option-theme.scss +24 -10
- package/core/selection/pseudo-checkbox/_pseudo-checkbox-theme.scss +64 -24
- package/core/tokens/_token-utils.scss +22 -0
- package/core/tokens/m2/_index.scss +16 -0
- package/core/tokens/m2/mat/_badge.scss +27 -1
- package/core/tokens/m2/mat/_checkbox.scss +45 -0
- package/core/tokens/m2/mat/_dialog.scss +49 -0
- package/core/tokens/m2/mat/_fab-small.scss +95 -0
- package/core/tokens/m2/mat/_fab.scss +6 -1
- package/core/tokens/m2/mat/_filled-button.scss +17 -2
- package/core/tokens/m2/mat/_icon-button.scss +6 -1
- package/core/tokens/m2/mat/_outlined-button.scss +17 -2
- package/core/tokens/m2/mat/_protected-button.scss +17 -2
- package/core/tokens/m2/mat/_radio.scss +6 -1
- package/core/tokens/m2/mat/_stepper.scss +6 -1
- package/core/tokens/m2/mat/_text-button.scss +20 -2
- package/core/tokens/m2/mdc/_extended-fab.scss +3 -2
- package/core/tokens/m2/mdc/_fab-small.scss +90 -0
- package/core/tokens/m2/mdc/_fab.scss +0 -11
- package/core/tokens/m2/mdc/_icon-button.scss +15 -7
- package/datepicker/_datepicker-theme.scss +25 -9
- package/dialog/_dialog-theme.scss +10 -0
- package/dialog/index.d.ts +28 -9
- package/esm2022/autocomplete/autocomplete-origin.mjs +4 -4
- package/esm2022/autocomplete/autocomplete-trigger.mjs +4 -4
- package/esm2022/autocomplete/autocomplete.mjs +4 -4
- package/esm2022/autocomplete/module.mjs +5 -5
- package/esm2022/badge/badge-module.mjs +5 -5
- package/esm2022/badge/badge.mjs +8 -8
- package/esm2022/bottom-sheet/bottom-sheet-container.mjs +4 -4
- package/esm2022/bottom-sheet/bottom-sheet-module.mjs +5 -5
- package/esm2022/bottom-sheet/bottom-sheet.mjs +4 -4
- package/esm2022/button/button-base.mjs +7 -7
- package/esm2022/button/button.mjs +9 -9
- package/esm2022/button/fab.mjs +17 -17
- package/esm2022/button/icon-button.mjs +9 -9
- package/esm2022/button/module.mjs +5 -5
- package/esm2022/button-toggle/button-toggle-module.mjs +5 -5
- package/esm2022/button-toggle/button-toggle.mjs +7 -7
- package/esm2022/card/card.mjs +43 -43
- package/esm2022/card/module.mjs +5 -5
- package/esm2022/checkbox/checkbox-required-validator.mjs +4 -4
- package/esm2022/checkbox/checkbox.mjs +6 -6
- package/esm2022/checkbox/module.mjs +9 -9
- package/esm2022/chips/chip-action.mjs +4 -4
- package/esm2022/chips/chip-edit-input.mjs +4 -4
- package/esm2022/chips/chip-grid.mjs +4 -4
- package/esm2022/chips/chip-icons.mjs +10 -10
- package/esm2022/chips/chip-input.mjs +4 -4
- package/esm2022/chips/chip-listbox.mjs +4 -4
- package/esm2022/chips/chip-option.mjs +4 -4
- package/esm2022/chips/chip-row.mjs +4 -4
- package/esm2022/chips/chip-set.mjs +4 -4
- package/esm2022/chips/chip.mjs +4 -4
- package/esm2022/chips/module.mjs +5 -5
- package/esm2022/core/common-behaviors/common-module.mjs +5 -5
- package/esm2022/core/datetime/index.mjs +9 -9
- package/esm2022/core/datetime/native-date-adapter.mjs +4 -4
- package/esm2022/core/error/error-options.mjs +7 -7
- package/esm2022/core/internal-form-field/internal-form-field.mjs +4 -4
- package/esm2022/core/line/line.mjs +8 -8
- package/esm2022/core/option/index.mjs +5 -5
- package/esm2022/core/option/optgroup.mjs +4 -4
- package/esm2022/core/option/option.mjs +4 -4
- package/esm2022/core/private/ripple-loader.mjs +4 -4
- package/esm2022/core/ripple/index.mjs +5 -5
- package/esm2022/core/ripple/ripple.mjs +4 -4
- package/esm2022/core/selection/pseudo-checkbox/pseudo-checkbox-module.mjs +5 -5
- package/esm2022/core/selection/pseudo-checkbox/pseudo-checkbox.mjs +4 -4
- package/esm2022/core/version.mjs +1 -1
- package/esm2022/datepicker/calendar-body.mjs +4 -4
- package/esm2022/datepicker/calendar.mjs +7 -7
- package/esm2022/datepicker/date-range-input-parts.mjs +10 -10
- package/esm2022/datepicker/date-range-input.mjs +4 -4
- package/esm2022/datepicker/date-range-picker.mjs +4 -4
- package/esm2022/datepicker/date-range-selection-strategy.mjs +4 -4
- package/esm2022/datepicker/date-selection-model.mjs +10 -10
- package/esm2022/datepicker/datepicker-actions.mjs +10 -10
- package/esm2022/datepicker/datepicker-base.mjs +7 -7
- package/esm2022/datepicker/datepicker-input-base.mjs +4 -4
- package/esm2022/datepicker/datepicker-input.mjs +4 -4
- package/esm2022/datepicker/datepicker-intl.mjs +4 -4
- package/esm2022/datepicker/datepicker-module.mjs +5 -5
- package/esm2022/datepicker/datepicker-toggle.mjs +7 -7
- package/esm2022/datepicker/datepicker.mjs +4 -4
- package/esm2022/datepicker/month-view.mjs +4 -4
- package/esm2022/datepicker/multi-year-view.mjs +4 -4
- package/esm2022/datepicker/year-view.mjs +4 -4
- package/esm2022/dialog/dialog-config.mjs +1 -3
- package/esm2022/dialog/dialog-container.mjs +16 -5
- package/esm2022/dialog/dialog-content-directives.mjs +49 -31
- package/esm2022/dialog/dialog-ref.mjs +3 -1
- package/esm2022/dialog/dialog.mjs +4 -4
- package/esm2022/dialog/module.mjs +5 -5
- package/esm2022/dialog/public-api.mjs +2 -2
- package/esm2022/divider/divider-module.mjs +5 -5
- package/esm2022/divider/divider.mjs +4 -4
- package/esm2022/expansion/accordion.mjs +4 -4
- package/esm2022/expansion/expansion-module.mjs +5 -5
- package/esm2022/expansion/expansion-panel-content.mjs +4 -4
- package/esm2022/expansion/expansion-panel-header.mjs +10 -10
- package/esm2022/expansion/expansion-panel.mjs +7 -7
- package/esm2022/form-field/directives/error.mjs +4 -4
- package/esm2022/form-field/directives/floating-label.mjs +4 -4
- package/esm2022/form-field/directives/hint.mjs +4 -4
- package/esm2022/form-field/directives/label.mjs +4 -4
- package/esm2022/form-field/directives/line-ripple.mjs +4 -4
- package/esm2022/form-field/directives/notched-outline.mjs +4 -4
- package/esm2022/form-field/directives/prefix.mjs +4 -4
- package/esm2022/form-field/directives/suffix.mjs +4 -4
- package/esm2022/form-field/form-field-control.mjs +4 -4
- package/esm2022/form-field/form-field.mjs +4 -4
- package/esm2022/form-field/module.mjs +5 -5
- package/esm2022/grid-list/grid-list-module.mjs +5 -5
- package/esm2022/grid-list/grid-list.mjs +4 -4
- package/esm2022/grid-list/grid-tile.mjs +16 -16
- package/esm2022/icon/icon-module.mjs +5 -5
- package/esm2022/icon/icon-registry.mjs +4 -4
- package/esm2022/icon/icon.mjs +4 -4
- package/esm2022/icon/testing/fake-icon-registry.mjs +8 -8
- package/esm2022/input/input.mjs +4 -4
- package/esm2022/input/module.mjs +5 -5
- package/esm2022/list/action-list.mjs +4 -4
- package/esm2022/list/list-base.mjs +7 -7
- package/esm2022/list/list-item-sections.mjs +19 -19
- package/esm2022/list/list-module.mjs +5 -5
- package/esm2022/list/list-option.mjs +4 -4
- package/esm2022/list/list.mjs +7 -7
- package/esm2022/list/nav-list.mjs +4 -4
- package/esm2022/list/selection-list.mjs +4 -4
- package/esm2022/list/subheader.mjs +4 -4
- package/esm2022/menu/menu-content.mjs +4 -4
- package/esm2022/menu/menu-item.mjs +4 -4
- package/esm2022/menu/menu-trigger.mjs +4 -4
- package/esm2022/menu/menu.mjs +4 -4
- package/esm2022/menu/module.mjs +5 -5
- package/esm2022/paginator/module.mjs +5 -5
- package/esm2022/paginator/paginator-intl.mjs +4 -4
- package/esm2022/paginator/paginator.mjs +4 -4
- package/esm2022/progress-bar/module.mjs +5 -5
- package/esm2022/progress-bar/progress-bar.mjs +4 -4
- package/esm2022/progress-spinner/module.mjs +5 -5
- package/esm2022/progress-spinner/progress-spinner.mjs +4 -4
- package/esm2022/radio/module.mjs +5 -5
- package/esm2022/radio/radio.mjs +8 -8
- package/esm2022/select/module.mjs +5 -5
- package/esm2022/select/select.mjs +7 -7
- package/esm2022/sidenav/drawer.mjs +10 -10
- package/esm2022/sidenav/sidenav-module.mjs +5 -5
- package/esm2022/sidenav/sidenav.mjs +10 -10
- package/esm2022/slide-toggle/module.mjs +9 -9
- package/esm2022/slide-toggle/slide-toggle-required-validator.mjs +4 -4
- package/esm2022/slide-toggle/slide-toggle.mjs +4 -4
- package/esm2022/slider/module.mjs +5 -5
- package/esm2022/slider/slider-input.mjs +7 -7
- package/esm2022/slider/slider-thumb.mjs +4 -4
- package/esm2022/slider/slider.mjs +4 -4
- package/esm2022/snack-bar/module.mjs +5 -5
- package/esm2022/snack-bar/simple-snack-bar.mjs +4 -4
- package/esm2022/snack-bar/snack-bar-container.mjs +4 -4
- package/esm2022/snack-bar/snack-bar-content.mjs +10 -10
- package/esm2022/snack-bar/snack-bar.mjs +4 -4
- package/esm2022/sort/sort-header-intl.mjs +4 -4
- package/esm2022/sort/sort-header.mjs +4 -4
- package/esm2022/sort/sort-module.mjs +5 -5
- package/esm2022/sort/sort.mjs +4 -4
- package/esm2022/stepper/step-content.mjs +4 -4
- package/esm2022/stepper/step-header.mjs +5 -5
- package/esm2022/stepper/step-label.mjs +4 -4
- package/esm2022/stepper/stepper-button.mjs +7 -7
- package/esm2022/stepper/stepper-icon.mjs +4 -4
- package/esm2022/stepper/stepper-intl.mjs +4 -4
- package/esm2022/stepper/stepper-module.mjs +5 -5
- package/esm2022/stepper/stepper.mjs +7 -7
- package/esm2022/table/cell.mjs +22 -22
- package/esm2022/table/module.mjs +5 -5
- package/esm2022/table/row.mjs +22 -22
- package/esm2022/table/table.mjs +7 -7
- package/esm2022/table/text-column.mjs +4 -4
- package/esm2022/tabs/module.mjs +5 -5
- package/esm2022/tabs/paginated-tab-header.mjs +4 -4
- package/esm2022/tabs/tab-body.mjs +7 -7
- package/esm2022/tabs/tab-content.mjs +4 -4
- package/esm2022/tabs/tab-group.mjs +4 -4
- package/esm2022/tabs/tab-header.mjs +4 -4
- package/esm2022/tabs/tab-label-wrapper.mjs +4 -4
- package/esm2022/tabs/tab-label.mjs +4 -4
- package/esm2022/tabs/tab-nav-bar/tab-nav-bar.mjs +10 -10
- package/esm2022/tabs/tab.mjs +4 -4
- package/esm2022/toolbar/toolbar-module.mjs +5 -5
- package/esm2022/toolbar/toolbar.mjs +7 -7
- package/esm2022/tooltip/module.mjs +5 -5
- package/esm2022/tooltip/tooltip.mjs +7 -7
- package/esm2022/tree/node.mjs +10 -10
- package/esm2022/tree/outlet.mjs +4 -4
- package/esm2022/tree/padding.mjs +4 -4
- package/esm2022/tree/toggle.mjs +4 -4
- package/esm2022/tree/tree-module.mjs +5 -5
- package/esm2022/tree/tree.mjs +4 -4
- package/fesm2022/autocomplete.mjs +13 -13
- package/fesm2022/autocomplete.mjs.map +1 -1
- package/fesm2022/badge.mjs +11 -11
- package/fesm2022/badge.mjs.map +1 -1
- package/fesm2022/bottom-sheet.mjs +10 -10
- package/fesm2022/bottom-sheet.mjs.map +1 -1
- package/fesm2022/button-toggle.mjs +10 -10
- package/fesm2022/button-toggle.mjs.map +1 -1
- package/fesm2022/button.mjs +42 -42
- package/fesm2022/button.mjs.map +1 -1
- package/fesm2022/card.mjs +46 -46
- package/fesm2022/card.mjs.map +1 -1
- package/fesm2022/checkbox.mjs +16 -16
- package/fesm2022/checkbox.mjs.map +1 -1
- package/fesm2022/chips.mjs +40 -40
- package/fesm2022/chips.mjs.map +1 -1
- package/fesm2022/core.mjs +59 -59
- package/fesm2022/core.mjs.map +1 -1
- package/fesm2022/datepicker.mjs +82 -82
- package/fesm2022/datepicker.mjs.map +1 -1
- package/fesm2022/dialog.mjs +72 -43
- package/fesm2022/dialog.mjs.map +1 -1
- package/fesm2022/divider.mjs +7 -7
- package/fesm2022/divider.mjs.map +1 -1
- package/fesm2022/expansion.mjs +25 -25
- package/fesm2022/expansion.mjs.map +1 -1
- package/fesm2022/form-field.mjs +34 -34
- package/fesm2022/form-field.mjs.map +1 -1
- package/fesm2022/grid-list.mjs +22 -22
- package/fesm2022/grid-list.mjs.map +1 -1
- package/fesm2022/icon/testing.mjs +7 -7
- package/fesm2022/icon/testing.mjs.map +1 -1
- package/fesm2022/icon.mjs +10 -10
- package/fesm2022/icon.mjs.map +1 -1
- package/fesm2022/input.mjs +7 -7
- package/fesm2022/input.mjs.map +1 -1
- package/fesm2022/list.mjs +49 -49
- package/fesm2022/list.mjs.map +1 -1
- package/fesm2022/menu.mjs +16 -16
- package/fesm2022/menu.mjs.map +1 -1
- package/fesm2022/paginator.mjs +10 -10
- package/fesm2022/paginator.mjs.map +1 -1
- package/fesm2022/progress-bar.mjs +7 -7
- package/fesm2022/progress-bar.mjs.map +1 -1
- package/fesm2022/progress-spinner.mjs +7 -7
- package/fesm2022/progress-spinner.mjs.map +1 -1
- package/fesm2022/radio.mjs +11 -11
- package/fesm2022/radio.mjs.map +1 -1
- package/fesm2022/select.mjs +10 -10
- package/fesm2022/select.mjs.map +1 -1
- package/fesm2022/sidenav.mjs +22 -22
- package/fesm2022/sidenav.mjs.map +1 -1
- package/fesm2022/slide-toggle.mjs +14 -14
- package/fesm2022/slide-toggle.mjs.map +1 -1
- package/fesm2022/slider.mjs +16 -16
- package/fesm2022/slider.mjs.map +1 -1
- package/fesm2022/snack-bar.mjs +22 -22
- package/fesm2022/snack-bar.mjs.map +1 -1
- package/fesm2022/sort.mjs +13 -13
- package/fesm2022/sort.mjs.map +1 -1
- package/fesm2022/stepper.mjs +32 -32
- package/fesm2022/stepper.mjs.map +1 -1
- package/fesm2022/table.mjs +55 -55
- package/fesm2022/table.mjs.map +1 -1
- package/fesm2022/tabs.mjs +40 -40
- package/fesm2022/tabs.mjs.map +1 -1
- package/fesm2022/toolbar.mjs +10 -10
- package/fesm2022/toolbar.mjs.map +1 -1
- package/fesm2022/tooltip.mjs +10 -10
- package/fesm2022/tooltip.mjs.map +1 -1
- package/fesm2022/tree.mjs +25 -25
- package/fesm2022/tree.mjs.map +1 -1
- package/form-field/_form-field-theme.scss +31 -14
- package/icon/_icon-theme.scss +2 -2
- package/package.json +7 -7
- package/paginator/_paginator-theme.scss +10 -16
- package/prebuilt-themes/deeppurple-amber.css +1 -1
- package/prebuilt-themes/indigo-pink.css +1 -1
- package/prebuilt-themes/pink-bluegrey.css +1 -1
- package/prebuilt-themes/purple-green.css +1 -1
- package/progress-bar/_progress-bar-theme.scss +27 -9
- package/progress-spinner/_progress-spinner-theme.scss +38 -17
- package/radio/_radio-theme.scss +34 -18
- package/schematics/ng-add/index.js +2 -2
- package/schematics/ng-add/index.mjs +2 -2
- package/schematics/ng-add/setup-project.js +7 -75
- package/schematics/ng-add/setup-project.mjs +7 -75
- package/schematics/ng-generate/mdc-migration/index_bundled.js +122 -115
- package/schematics/ng-generate/mdc-migration/index_bundled.js.map +4 -4
- package/select/_select-theme.scss +24 -10
- package/slide-toggle/_slide-toggle-theme.scss +29 -9
- package/slider/_slider-theme.scss +28 -11
- package/stepper/_stepper-theme.scss +28 -7
- package/tabs/_tabs-theme.scss +32 -14
|
@@ -110,6 +110,28 @@ $_component-prefix: null;
|
|
|
110
110
|
@return mdc-custom-properties.create-varname('#{$_component-prefix}-#{$token}');
|
|
111
111
|
}
|
|
112
112
|
|
|
113
|
+
// TODO(crisbeto): should be able to replace the usages of `get-token-variable` with this.
|
|
114
|
+
// Returns a `var()` reference to a specific token. Intended for declarations
|
|
115
|
+
// where the token has to be referenced as a part of a larger expression.
|
|
116
|
+
@function get-token-variable-reference($token, $emit-fallback: false) {
|
|
117
|
+
@if $_component-prefix == null or $_tokens == null {
|
|
118
|
+
@error '`get-token-variable-reference` must be used within `use-tokens`';
|
|
119
|
+
}
|
|
120
|
+
@if not map.has-key($_tokens, $token) {
|
|
121
|
+
@error 'Token #{$token} does not exist. Configured tokens are: #{map.keys($_tokens)}';
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
$var: get-token-variable($token);
|
|
125
|
+
$fallback: if($emit-fallback, map.get($_tokens, $token), null);
|
|
126
|
+
|
|
127
|
+
@if ($fallback != null) {
|
|
128
|
+
@return var($var, $fallback);
|
|
129
|
+
}
|
|
130
|
+
@else {
|
|
131
|
+
@return var($var);
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
113
135
|
@mixin create-token-values($prefix, $tokens) {
|
|
114
136
|
@include _configure-token-prefix($prefix...) {
|
|
115
137
|
@include mdc-keys.declare-custom-properties($tokens, $_component-prefix);
|
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
@use 'sass:map';
|
|
2
2
|
@use 'sass:meta';
|
|
3
3
|
@use '../../style/sass-utils';
|
|
4
|
+
@use './mat/app' as tokens-mat-app;
|
|
4
5
|
@use './mat/autocomplete' as tokens-mat-autocomplete;
|
|
5
6
|
@use './mat/badge' as tokens-mat-badge;
|
|
6
7
|
@use './mat/text-button' as tokens-mat-text-button;
|
|
7
8
|
@use './mat/protected-button' as tokens-mat-protected-button;
|
|
8
9
|
@use './mat/filled-button' as tokens-mat-filled-button;
|
|
9
10
|
@use './mat/outlined-button' as tokens-mat-outlined-button;
|
|
11
|
+
@use './mat/dialog' as tokens-mat-dialog;
|
|
10
12
|
@use './mat/bottom-sheet' as tokens-mat-bottom-sheet;
|
|
11
13
|
@use './mat/card' as tokens-mat-card;
|
|
12
14
|
@use './mat/datepicker' as tokens-mat-datepicker;
|
|
13
15
|
@use './mat/divider' as tokens-mat-divider;
|
|
14
16
|
@use './mat/expansion' as tokens-mat-expansion;
|
|
15
17
|
@use './mat/fab' as tokens-mat-fab;
|
|
18
|
+
@use './mat/fab-small' as tokens-mat-fab-small;
|
|
16
19
|
@use './mat/form-field' as tokens-mat-form-field;
|
|
17
20
|
@use './mat/grid-list' as tokens-mat-grid-list;
|
|
18
21
|
@use './mat/icon' as tokens-mat-icon;
|
|
@@ -21,6 +24,9 @@
|
|
|
21
24
|
@use './mat/option' as tokens-mat-option;
|
|
22
25
|
@use './mat/optgroup' as tokens-mat-optgroup;
|
|
23
26
|
@use './mat/paginator' as tokens-mat-paginator;
|
|
27
|
+
@use './mat/checkbox' as tokens-mat-checkbox;
|
|
28
|
+
@use './mat/full-pseudo-checkbox' as tokens-mat-full-pseudo-checkbox;
|
|
29
|
+
@use './mat/minimal-pseudo-checkbox' as tokens-mat-minimal-pseudo-checkbox;
|
|
24
30
|
@use './mat/radio' as tokens-mat-radio;
|
|
25
31
|
@use './mat/ripple' as tokens-mat-ripple;
|
|
26
32
|
@use './mat/select' as tokens-mat-select;
|
|
@@ -46,6 +52,8 @@
|
|
|
46
52
|
@use './mdc/elevated-card' as tokens-mdc-elevated-card;
|
|
47
53
|
@use './mdc/extended-fab' as tokens-mdc-extended-fab;
|
|
48
54
|
@use './mdc/fab' as tokens-mdc-fab;
|
|
55
|
+
@use './mdc/fab-small' as tokens-mdc-fab-small;
|
|
56
|
+
@use './mdc/form-field' as tokens-mdc-form-field;
|
|
49
57
|
@use './mdc/filled-text-field' as tokens-mdc-filled-text-field;
|
|
50
58
|
@use './mdc/icon-button' as tokens-mdc-icon-button;
|
|
51
59
|
@use './mdc/linear-progress' as tokens-mdc-linear-progress;
|
|
@@ -103,15 +111,18 @@
|
|
|
103
111
|
/// )
|
|
104
112
|
@function m2-tokens-from-theme($theme) {
|
|
105
113
|
@return sass-utils.deep-merge-all(
|
|
114
|
+
_get-tokens-for-module($theme, tokens-mat-app),
|
|
106
115
|
_get-tokens-for-module($theme, tokens-mat-autocomplete),
|
|
107
116
|
_get-tokens-for-module($theme, tokens-mat-badge),
|
|
108
117
|
_get-tokens-for-module($theme, tokens-mat-bottom-sheet),
|
|
109
118
|
_get-tokens-for-module($theme, tokens-mat-button-toggle),
|
|
110
119
|
_get-tokens-for-module($theme, tokens-mat-card),
|
|
111
120
|
_get-tokens-for-module($theme, tokens-mat-datepicker),
|
|
121
|
+
_get-tokens-for-module($theme, tokens-mat-dialog),
|
|
112
122
|
_get-tokens-for-module($theme, tokens-mat-divider),
|
|
113
123
|
_get-tokens-for-module($theme, tokens-mat-expansion),
|
|
114
124
|
_get-tokens-for-module($theme, tokens-mat-fab),
|
|
125
|
+
_get-tokens-for-module($theme, tokens-mat-fab-small),
|
|
115
126
|
_get-tokens-for-module($theme, tokens-mat-filled-button),
|
|
116
127
|
_get-tokens-for-module($theme, tokens-mat-form-field),
|
|
117
128
|
_get-tokens-for-module($theme, tokens-mat-grid-list),
|
|
@@ -122,6 +133,9 @@
|
|
|
122
133
|
_get-tokens-for-module($theme, tokens-mat-option),
|
|
123
134
|
_get-tokens-for-module($theme, tokens-mat-outlined-button),
|
|
124
135
|
_get-tokens-for-module($theme, tokens-mat-paginator),
|
|
136
|
+
_get-tokens-for-module($theme, tokens-mat-checkbox),
|
|
137
|
+
_get-tokens-for-module($theme, tokens-mat-full-pseudo-checkbox),
|
|
138
|
+
_get-tokens-for-module($theme, tokens-mat-minimal-pseudo-checkbox),
|
|
125
139
|
_get-tokens-for-module($theme, tokens-mat-protected-button),
|
|
126
140
|
_get-tokens-for-module($theme, tokens-mat-radio),
|
|
127
141
|
_get-tokens-for-module($theme, tokens-mat-ripple),
|
|
@@ -144,8 +158,10 @@
|
|
|
144
158
|
_get-tokens-for-module($theme, tokens-mdc-elevated-card),
|
|
145
159
|
_get-tokens-for-module($theme, tokens-mdc-extended-fab),
|
|
146
160
|
_get-tokens-for-module($theme, tokens-mdc-fab),
|
|
161
|
+
_get-tokens-for-module($theme, tokens-mdc-fab-small),
|
|
147
162
|
_get-tokens-for-module($theme, tokens-mdc-filled-button),
|
|
148
163
|
_get-tokens-for-module($theme, tokens-mdc-filled-text-field),
|
|
164
|
+
_get-tokens-for-module($theme, tokens-mdc-form-field),
|
|
149
165
|
_get-tokens-for-module($theme, tokens-mdc-icon-button),
|
|
150
166
|
_get-tokens-for-module($theme, tokens-mdc-linear-progress),
|
|
151
167
|
_get-tokens-for-module($theme, tokens-mdc-list),
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@use 'sass:meta';
|
|
2
2
|
@use 'sass:map';
|
|
3
|
+
@use 'sass:math';
|
|
3
4
|
@use 'sass:color';
|
|
4
5
|
@use '../../token-utils';
|
|
5
6
|
@use '../../../theming/inspection';
|
|
@@ -11,7 +12,32 @@ $prefix: (mat, badge);
|
|
|
11
12
|
// Tokens that can't be configured through Angular Material's current theming API,
|
|
12
13
|
// but may be in a future version of the theming API.
|
|
13
14
|
@function get-unthemable-tokens() {
|
|
14
|
-
|
|
15
|
+
$default-size: 22px;
|
|
16
|
+
$small-size: $default-size - 6;
|
|
17
|
+
$large-size: $default-size + 6;
|
|
18
|
+
|
|
19
|
+
@return (
|
|
20
|
+
container-shape: 50%,
|
|
21
|
+
container-size: unset,
|
|
22
|
+
small-size-container-size: unset,
|
|
23
|
+
large-size-container-size: unset,
|
|
24
|
+
|
|
25
|
+
legacy-container-size: $default-size,
|
|
26
|
+
legacy-small-size-container-size: $small-size,
|
|
27
|
+
legacy-large-size-container-size: $large-size,
|
|
28
|
+
|
|
29
|
+
container-offset: math.div($default-size, -2) 0,
|
|
30
|
+
small-size-container-offset: math.div($small-size, -2) 0,
|
|
31
|
+
large-size-container-offset: math.div($large-size, -2) 0,
|
|
32
|
+
|
|
33
|
+
container-overlap-offset: math.div($default-size, -2),
|
|
34
|
+
small-size-container-overlap-offset: math.div($small-size, -2),
|
|
35
|
+
large-size-container-overlap-offset: math.div($large-size, -2),
|
|
36
|
+
|
|
37
|
+
container-padding: 0,
|
|
38
|
+
small-size-container-padding: 0,
|
|
39
|
+
large-size-container-padding: 0,
|
|
40
|
+
);
|
|
15
41
|
}
|
|
16
42
|
|
|
17
43
|
// Tokens that can be configured through Angular Material's color theming API.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
@use '../../token-utils';
|
|
2
|
+
@use '../../../theming/theming';
|
|
3
|
+
@use '../../../theming/inspection';
|
|
4
|
+
@use '../../../style/sass-utils';
|
|
5
|
+
|
|
6
|
+
// The prefix used to generate the fully qualified name for tokens in this file.
|
|
7
|
+
$prefix: (mat, checkbox);
|
|
8
|
+
|
|
9
|
+
// Tokens that can't be configured through Angular Material's current theming API,
|
|
10
|
+
// but may be in a future version of the theming API.
|
|
11
|
+
@function get-unthemable-tokens() {
|
|
12
|
+
@return ();
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
// Tokens that can be configured through Angular Material's color theming API.
|
|
16
|
+
@function get-color-tokens($theme) {
|
|
17
|
+
@return (
|
|
18
|
+
disabled-label-color: inspection.get-theme-color($theme, foreground, disabled-text),
|
|
19
|
+
);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// Tokens that can be configured through Angular Material's typography theming API.
|
|
23
|
+
@function get-typography-tokens($theme) {
|
|
24
|
+
@return ();
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
// Tokens that can be configured through Angular Material's density theming API.
|
|
28
|
+
@function get-density-tokens($theme) {
|
|
29
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
30
|
+
|
|
31
|
+
@return (
|
|
32
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
33
|
+
);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
37
|
+
// This is used to create token slots.
|
|
38
|
+
@function get-token-slots() {
|
|
39
|
+
@return sass-utils.deep-merge-all(
|
|
40
|
+
get-unthemable-tokens(),
|
|
41
|
+
get-color-tokens(token-utils.$placeholder-color-config),
|
|
42
|
+
get-typography-tokens(token-utils.$placeholder-typography-config),
|
|
43
|
+
get-density-tokens(token-utils.$placeholder-density-config)
|
|
44
|
+
);
|
|
45
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
@use '../../token-utils';
|
|
2
|
+
@use '../../../style/sass-utils';
|
|
3
|
+
|
|
4
|
+
// The prefix used to generate the fully qualified name for tokens in this file.
|
|
5
|
+
$prefix: (mat, dialog);
|
|
6
|
+
|
|
7
|
+
// Tokens that can't be configured through Angular Material's current theming API,
|
|
8
|
+
// but may be in a future version of the theming API.
|
|
9
|
+
@function get-unthemable-tokens() {
|
|
10
|
+
@return (
|
|
11
|
+
container-max-width: 80vw,
|
|
12
|
+
container-small-max-width: 80vw,
|
|
13
|
+
container-min-width: 0,
|
|
14
|
+
actions-alignment: start,
|
|
15
|
+
actions-padding: 8px,
|
|
16
|
+
content-padding: 20px 24px,
|
|
17
|
+
with-actions-content-padding: 20px 24px,
|
|
18
|
+
|
|
19
|
+
// Note: the CSS class is `title` while the M2 tokens call it `subhead`.
|
|
20
|
+
// M3 calls it `headline` which is what we're aligning with.
|
|
21
|
+
headline-padding: 0 24px 9px,
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// Tokens that can be configured through Angular Material's color theming API.
|
|
26
|
+
@function get-color-tokens($theme) {
|
|
27
|
+
@return ();
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
// Tokens that can be configured through Angular Material's typography theming API.
|
|
31
|
+
@function get-typography-tokens($theme) {
|
|
32
|
+
@return ();
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// Tokens that can be configured through Angular Material's density theming API.
|
|
36
|
+
@function get-density-tokens($theme) {
|
|
37
|
+
@return ();
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
41
|
+
// This is used to create token slots.
|
|
42
|
+
@function get-token-slots() {
|
|
43
|
+
@return sass-utils.deep-merge-all(
|
|
44
|
+
get-unthemable-tokens(),
|
|
45
|
+
get-color-tokens(token-utils.$placeholder-color-config),
|
|
46
|
+
get-typography-tokens(token-utils.$placeholder-typography-config),
|
|
47
|
+
get-density-tokens(token-utils.$placeholder-density-config)
|
|
48
|
+
);
|
|
49
|
+
}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
@use 'sass:map';
|
|
2
|
+
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
3
|
+
@use '../../token-utils';
|
|
4
|
+
@use '../../../theming/theming';
|
|
5
|
+
@use '../../../theming/inspection';
|
|
6
|
+
@use '../../../style/sass-utils';
|
|
7
|
+
@use '../../../mdc-helpers/mdc-helpers';
|
|
8
|
+
|
|
9
|
+
// The prefix used to generate the fully qualified name for tokens in this file.
|
|
10
|
+
$prefix: (mat, fab-small);
|
|
11
|
+
|
|
12
|
+
// Tokens that can't be configured through Angular Material's current theming API,
|
|
13
|
+
// but may be in a future version of the theming API.
|
|
14
|
+
@function get-unthemable-tokens() {
|
|
15
|
+
@return ();
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
// Tokens that can be configured through Angular Material's color theming API.
|
|
19
|
+
@function get-color-tokens($theme) {
|
|
20
|
+
$is-dark: inspection.get-theme-type($theme) == dark;
|
|
21
|
+
$on-surface: if($is-dark, #fff, #000);
|
|
22
|
+
$ripple-opacities: if($is-dark,
|
|
23
|
+
mdc-ripple-theme.$light-ink-opacities,
|
|
24
|
+
mdc-ripple-theme.$dark-ink-opacities
|
|
25
|
+
);
|
|
26
|
+
|
|
27
|
+
@return (
|
|
28
|
+
// Color of icons and text projected into a FAB.
|
|
29
|
+
foreground-color: inspection.get-theme-color($theme, foreground, base),
|
|
30
|
+
|
|
31
|
+
// Color of the element that shows the hover, focus and pressed states.
|
|
32
|
+
state-layer-color: $on-surface,
|
|
33
|
+
|
|
34
|
+
// Color of the element that shows the hover, focus and pressed states while disabled.
|
|
35
|
+
disabled-state-layer-color: $on-surface,
|
|
36
|
+
|
|
37
|
+
// Color of the ripple element.
|
|
38
|
+
ripple-color: rgba($on-surface, 0.1),
|
|
39
|
+
|
|
40
|
+
// Opacity of the ripple when the button is hovered.
|
|
41
|
+
hover-state-layer-opacity: map.get($ripple-opacities, hover),
|
|
42
|
+
|
|
43
|
+
// Opacity of the ripple when the button is focused.
|
|
44
|
+
focus-state-layer-opacity: map.get($ripple-opacities, focus),
|
|
45
|
+
|
|
46
|
+
// Opacity of the ripple when the button is pressed.
|
|
47
|
+
pressed-state-layer-opacity: map.get($ripple-opacities, press),
|
|
48
|
+
|
|
49
|
+
// MDC doesn't have tokens for disabled FABs so we need to implemented them ourselves.
|
|
50
|
+
// Background color of the container when the FAB is disabled.
|
|
51
|
+
disabled-state-container-color: rgba($on-surface, 0.12),
|
|
52
|
+
|
|
53
|
+
// Color of the icons and projected text when the FAB is disabled.
|
|
54
|
+
disabled-state-foreground-color: rgba($on-surface, if($is-dark, 0.5, 0.38)),
|
|
55
|
+
);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
// Generates the mapping for the properties that change based on the FAB palette color.
|
|
59
|
+
@function private-get-color-palette-color-tokens($theme, $palette-name) {
|
|
60
|
+
$is-dark: inspection.get-theme-type($theme) == dark;
|
|
61
|
+
$container-color: inspection.get-theme-color($theme, $palette-name);
|
|
62
|
+
$contrast-tone: mdc-helpers.variable-safe-contrast-tone($container-color, $is-dark);
|
|
63
|
+
$color: if($contrast-tone == 'dark', #000, #fff);
|
|
64
|
+
|
|
65
|
+
@return (
|
|
66
|
+
foreground-color: $color,
|
|
67
|
+
state-layer-color: $color,
|
|
68
|
+
ripple-color: rgba($color, 0.1),
|
|
69
|
+
);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
// Tokens that can be configured through Angular Material's typography theming API.
|
|
73
|
+
@function get-typography-tokens($theme) {
|
|
74
|
+
@return ();
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
// Tokens that can be configured through Angular Material's density theming API.
|
|
78
|
+
@function get-density-tokens($theme) {
|
|
79
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
80
|
+
|
|
81
|
+
@return (
|
|
82
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
83
|
+
);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
87
|
+
// This is used to create token slots.
|
|
88
|
+
@function get-token-slots() {
|
|
89
|
+
@return sass-utils.deep-merge-all(
|
|
90
|
+
get-unthemable-tokens(),
|
|
91
|
+
get-color-tokens(token-utils.$placeholder-color-config),
|
|
92
|
+
get-typography-tokens(token-utils.$placeholder-typography-config),
|
|
93
|
+
get-density-tokens(token-utils.$placeholder-density-config)
|
|
94
|
+
);
|
|
95
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
@use 'sass:map';
|
|
2
2
|
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
3
3
|
@use '../../token-utils';
|
|
4
|
+
@use '../../../theming/theming';
|
|
4
5
|
@use '../../../theming/inspection';
|
|
5
6
|
@use '../../../style/sass-utils';
|
|
6
7
|
@use '../../../mdc-helpers/mdc-helpers';
|
|
@@ -75,7 +76,11 @@ $prefix: (mat, fab);
|
|
|
75
76
|
|
|
76
77
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
77
78
|
@function get-density-tokens($theme) {
|
|
78
|
-
|
|
79
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
80
|
+
|
|
81
|
+
@return (
|
|
82
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
83
|
+
);
|
|
79
84
|
}
|
|
80
85
|
|
|
81
86
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
@use 'sass:map';
|
|
2
2
|
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
3
3
|
@use '../../token-utils';
|
|
4
|
+
@use '../../../theming/theming';
|
|
4
5
|
@use '../../../theming/inspection';
|
|
5
6
|
@use '../../../style/sass-utils';
|
|
6
7
|
@use '../../../mdc-helpers/mdc-helpers';
|
|
@@ -11,7 +12,17 @@ $prefix: (mat, filled-button);
|
|
|
11
12
|
// Tokens that can't be configured through Angular Material's current theming API,
|
|
12
13
|
// but may be in a future version of the theming API.
|
|
13
14
|
@function get-unthemable-tokens() {
|
|
14
|
-
@return (
|
|
15
|
+
@return (
|
|
16
|
+
// Start/end padding of the button.
|
|
17
|
+
horizontal-padding: 16px,
|
|
18
|
+
|
|
19
|
+
// Space between the icon and the button's main content.
|
|
20
|
+
icon-spacing: 8px,
|
|
21
|
+
|
|
22
|
+
// Amount by which to offset the icon so that its presence
|
|
23
|
+
// doesn't increase throw off the horizontal padding.
|
|
24
|
+
icon-offset: -4px,
|
|
25
|
+
);
|
|
15
26
|
}
|
|
16
27
|
|
|
17
28
|
// Tokens that can be configured through Angular Material's color theming API.
|
|
@@ -64,7 +75,11 @@ $prefix: (mat, filled-button);
|
|
|
64
75
|
|
|
65
76
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
66
77
|
@function get-density-tokens($theme) {
|
|
67
|
-
|
|
78
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
79
|
+
|
|
80
|
+
@return (
|
|
81
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
82
|
+
);
|
|
68
83
|
}
|
|
69
84
|
|
|
70
85
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
@use 'sass:meta';
|
|
3
3
|
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
4
4
|
@use '../../token-utils';
|
|
5
|
+
@use '../../../theming/theming';
|
|
5
6
|
@use '../../../theming/inspection';
|
|
6
7
|
@use '../../../style/sass-utils';
|
|
7
8
|
|
|
@@ -61,7 +62,11 @@ $prefix: (mat, icon-button);
|
|
|
61
62
|
|
|
62
63
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
63
64
|
@function get-density-tokens($theme) {
|
|
64
|
-
|
|
65
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
66
|
+
|
|
67
|
+
@return (
|
|
68
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
69
|
+
);
|
|
65
70
|
}
|
|
66
71
|
|
|
67
72
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
@use 'sass:meta';
|
|
3
3
|
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
4
4
|
@use '../../token-utils';
|
|
5
|
+
@use '../../../theming/theming';
|
|
5
6
|
@use '../../../theming/inspection';
|
|
6
7
|
@use '../../../style/sass-utils';
|
|
7
8
|
|
|
@@ -11,7 +12,17 @@ $prefix: (mat, outlined-button);
|
|
|
11
12
|
// Tokens that can't be configured through Angular Material's current theming API,
|
|
12
13
|
// but may be in a future version of the theming API.
|
|
13
14
|
@function get-unthemable-tokens() {
|
|
14
|
-
@return (
|
|
15
|
+
@return (
|
|
16
|
+
// Start/end padding of the button.
|
|
17
|
+
horizontal-padding: 15px, // Normally it's 16px, but -1px for the outline.
|
|
18
|
+
|
|
19
|
+
// Space between the icon and the button's main content.
|
|
20
|
+
icon-spacing: 8px,
|
|
21
|
+
|
|
22
|
+
// Amount by which to offset the icon so that its presence
|
|
23
|
+
// doesn't increase throw off the horizontal padding.
|
|
24
|
+
icon-offset: -4px,
|
|
25
|
+
);
|
|
15
26
|
}
|
|
16
27
|
|
|
17
28
|
// Tokens that can be configured through Angular Material's color theming API.
|
|
@@ -61,7 +72,11 @@ $prefix: (mat, outlined-button);
|
|
|
61
72
|
|
|
62
73
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
63
74
|
@function get-density-tokens($theme) {
|
|
64
|
-
|
|
75
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
76
|
+
|
|
77
|
+
@return (
|
|
78
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
79
|
+
);
|
|
65
80
|
}
|
|
66
81
|
|
|
67
82
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
@use 'sass:map';
|
|
2
2
|
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
3
3
|
@use '../../token-utils';
|
|
4
|
+
@use '../../../theming/theming';
|
|
4
5
|
@use '../../../theming/inspection';
|
|
5
6
|
@use '../../../style/sass-utils';
|
|
6
7
|
@use '../../../mdc-helpers/mdc-helpers';
|
|
@@ -11,7 +12,17 @@ $prefix: (mat, protected-button);
|
|
|
11
12
|
// Tokens that can't be configured through Angular Material's current theming API,
|
|
12
13
|
// but may be in a future version of the theming API.
|
|
13
14
|
@function get-unthemable-tokens() {
|
|
14
|
-
@return (
|
|
15
|
+
@return (
|
|
16
|
+
// Start/end padding of the button.
|
|
17
|
+
horizontal-padding: 16px,
|
|
18
|
+
|
|
19
|
+
// Space between the icon and the button's main content.
|
|
20
|
+
icon-spacing: 8px,
|
|
21
|
+
|
|
22
|
+
// Amount by which to offset the icon so that its presence
|
|
23
|
+
// doesn't increase throw off the horizontal padding.
|
|
24
|
+
icon-offset: -4px,
|
|
25
|
+
);
|
|
15
26
|
}
|
|
16
27
|
|
|
17
28
|
// Tokens that can be configured through Angular Material's color theming API.
|
|
@@ -64,7 +75,11 @@ $prefix: (mat, protected-button);
|
|
|
64
75
|
|
|
65
76
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
66
77
|
@function get-density-tokens($theme) {
|
|
67
|
-
|
|
78
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
79
|
+
|
|
80
|
+
@return (
|
|
81
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
82
|
+
);
|
|
68
83
|
}
|
|
69
84
|
|
|
70
85
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
@use '../../token-utils';
|
|
2
|
+
@use '../../../theming/theming';
|
|
2
3
|
@use '../../../theming/inspection';
|
|
3
4
|
@use '../../../style/sass-utils';
|
|
4
5
|
|
|
@@ -29,7 +30,11 @@ $prefix: (mat, radio);
|
|
|
29
30
|
|
|
30
31
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
31
32
|
@function get-density-tokens($theme) {
|
|
32
|
-
|
|
33
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
34
|
+
|
|
35
|
+
@return (
|
|
36
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
37
|
+
);
|
|
33
38
|
}
|
|
34
39
|
|
|
35
40
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -10,7 +10,12 @@ $prefix: (mat, stepper);
|
|
|
10
10
|
// Tokens that can't be configured through Angular Material's current theming API,
|
|
11
11
|
// but may be in a future version of the theming API.
|
|
12
12
|
@function get-unthemable-tokens() {
|
|
13
|
-
@return (
|
|
13
|
+
@return (
|
|
14
|
+
// Border radius for step header on focus
|
|
15
|
+
header-focus-state-layer-shape: 0,
|
|
16
|
+
// Border radius for step header on hover
|
|
17
|
+
header-hover-state-layer-shape: 0,
|
|
18
|
+
);
|
|
14
19
|
}
|
|
15
20
|
|
|
16
21
|
// Tokens that can be configured through Angular Material's color theming API.
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
@use 'sass:meta';
|
|
3
3
|
@use '@material/ripple/ripple-theme' as mdc-ripple-theme;
|
|
4
4
|
@use '../../token-utils';
|
|
5
|
+
@use '../../../theming/theming';
|
|
5
6
|
@use '../../../theming/inspection';
|
|
6
7
|
@use '../../../style/sass-utils';
|
|
7
8
|
|
|
@@ -11,7 +12,20 @@ $prefix: (mat, text-button);
|
|
|
11
12
|
// Tokens that can't be configured through Angular Material's current theming API,
|
|
12
13
|
// but may be in a future version of the theming API.
|
|
13
14
|
@function get-unthemable-tokens() {
|
|
14
|
-
@return (
|
|
15
|
+
@return (
|
|
16
|
+
// Start/end padding of the button.
|
|
17
|
+
horizontal-padding: 8px,
|
|
18
|
+
|
|
19
|
+
// Start/end padding of the button when it has an icon.
|
|
20
|
+
with-icon-horizontal-padding: 8px,
|
|
21
|
+
|
|
22
|
+
// Space between the icon and the button's main content.
|
|
23
|
+
icon-spacing: 8px,
|
|
24
|
+
|
|
25
|
+
// Amount by which to offset the icon so that its presence
|
|
26
|
+
// doesn't increase throw off the horizontal padding.
|
|
27
|
+
icon-offset: 0,
|
|
28
|
+
);
|
|
15
29
|
}
|
|
16
30
|
|
|
17
31
|
// Tokens that can be configured through Angular Material's color theming API.
|
|
@@ -61,7 +75,11 @@ $prefix: (mat, text-button);
|
|
|
61
75
|
|
|
62
76
|
// Tokens that can be configured through Angular Material's density theming API.
|
|
63
77
|
@function get-density-tokens($theme) {
|
|
64
|
-
|
|
78
|
+
$density-scale: theming.clamp-density(inspection.get-theme-density($theme), -3);
|
|
79
|
+
|
|
80
|
+
@return (
|
|
81
|
+
touch-target-display: if($density-scale < -1, none, block),
|
|
82
|
+
);
|
|
65
83
|
}
|
|
66
84
|
|
|
67
85
|
// Combines the tokens generated by the above functions into a single map with placeholder values.
|
|
@@ -8,12 +8,13 @@ $prefix: (mdc, extended-fab);
|
|
|
8
8
|
|
|
9
9
|
@function get-unthemable-tokens() {
|
|
10
10
|
@return (
|
|
11
|
+
container-height: 48px,
|
|
12
|
+
container-shape: 24px,
|
|
13
|
+
|
|
11
14
|
// =============================================================================================
|
|
12
15
|
// = TOKENS NOT USED IN ANGULAR MATERIAL =
|
|
13
16
|
// =============================================================================================
|
|
14
17
|
container-color: null,
|
|
15
|
-
container-height: null,
|
|
16
|
-
container-shape: null,
|
|
17
18
|
container-surface-tint-layer-color: null,
|
|
18
19
|
focus-icon-color: null,
|
|
19
20
|
focus-label-text-color: null,
|