source: trip-planner-front/node_modules/@angular/material/core/ripple/_ripple-theme.scss@ e29cc2e

Last change on this file since e29cc2e was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 1.0 KB
Line 
1@use 'sass:map';
2@use 'sass:meta';
3@use '../theming/theming';
4
5// Colors for the ripple elements.
6@mixin color($config-or-theme) {
7 $config: theming.get-color-config($config-or-theme);
8 $foreground: map.get($config, foreground);
9 $foreground-base: map.get($foreground, base);
10 $color-opacity: 0.1;
11
12 .mat-ripple-element {
13 // If the ripple color is resolves to a color *type*, we can use it directly, otherwise
14 // (e.g. it resolves to a CSS variable) we fall back to using the color and setting an opacity.
15 @if (meta.type-of($foreground-base) == color) {
16 background-color: rgba($foreground-base, $color-opacity);
17 }
18 @else {
19 background-color: $foreground-base;
20 opacity: $color-opacity;
21 }
22 }
23}
24
25@mixin theme($theme-or-color-config) {
26 $theme: theming.private-legacy-get-theme($theme-or-color-config);
27 @include theming.private-check-duplicate-theme-styles($theme, 'mat-ripple') {
28 $color: theming.get-color-config($theme);
29 @if $color != null {
30 @include color($color);
31 }
32 }
33}
Note: See TracBrowser for help on using the repository browser.