@elderbyte/ngx-starter 18.12.7 → 18.13.0-beta.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 +18 -6
- package/esm2022/lib/common/data/datasource/local/local-list-data-source.mjs +8 -2
- package/esm2022/lib/common/data/datasource/rest/rest-client.mjs +7 -1
- package/esm2022/lib/components/data-transfer/http-data-transfer-indicator/http-data-transfer-indicator.component.mjs +3 -3
- package/esm2022/lib/components/data-transfer/http-data-transfer-overview/http-data-transfer-overview.component.mjs +3 -3
- package/esm2022/lib/components/page/exit-guard/page-exit-lock-indicator/page-exit-lock-indicator.component.mjs +3 -3
- package/esm2022/lib/components/select/filter/elder-filter-chip-template/elder-filter-chip-template.component.mjs +3 -3
- package/esm2022/lib/components/select/multi/elder-multi-select-chip-options/elder-multi-select-chip-options.component.mjs +3 -3
- package/esm2022/lib/components/select/multi/elder-multi-select-chips/elder-multi-select-chips.component.mjs +3 -3
- package/esm2022/lib/components/select/popup/templated-selection-dialog/templated-selection-dialog.component.mjs +3 -3
- package/esm2022/lib/components/select/single/elder-select/elder-select.component.mjs +3 -3
- package/esm2022/lib/components/shell/header/elder-app-header/elder-app-header.component.mjs +5 -3
- package/esm2022/lib/components/time/elder-interval-picker/elder-interval-picker.component.mjs +3 -3
- package/fesm2022/elderbyte-ngx-starter.mjs +35 -21
- package/fesm2022/elderbyte-ngx-starter.mjs.map +1 -1
- package/lib/components/shell/header/elder-app-header/elder-app-header.component.d.ts +2 -1
- package/package.json +1 -1
- package/src/lib/components/button-group/elder-button-group/elder-button-group.component.scss +1 -7
- package/src/lib/components/card-organizer/card-stack/elder-card-stack.component.scss +3 -14
- package/src/lib/components/cards/elder-card/elder-card.component.scss +2 -8
- package/src/lib/components/chips/_elder-chip-theme-old.scss +122 -0
- package/src/lib/components/chips/_elder-chip-theme.scss +101 -12
- package/src/lib/components/data-transfer/http-data-transfer-indicator/http-data-transfer-indicator.component.scss +0 -6
- package/src/lib/components/data-transfer/http-data-transfer-overview/http-data-transfer-overview.component.scss +11 -0
- package/src/lib/components/data-view/grid/elder-grid/elder-grid.component.scss +15 -22
- package/src/lib/components/data-view/table/elder-table/elder-table.component.scss +11 -18
- package/src/lib/components/errors/exception-detail/elder-exception-detail.component.scss +2 -9
- package/src/lib/components/expand-toggle-button/elder-expand-toggle-button.component.scss +2 -8
- package/src/lib/components/files/drag-n-drop/elder-drop-zone/elder-drop-zone.component.scss +7 -10
- package/src/lib/components/iframes/iframe-host/iframe-host.component.scss +0 -4
- package/src/lib/components/navigation/nav/_elder-nav-theme.scss +12 -24
- package/src/lib/components/page/exit-guard/page-exit-lock-indicator/page-exit-lock-indicator.component.scss +1 -4
- package/src/lib/components/panels/card-panel/elder-card-panel.component.scss +3 -12
- package/src/lib/components/panels/elder-dialog-panel/elder-dialog-panel.component.scss +4 -12
- package/src/lib/components/panels/flat/_elder-panel-theme.scss +26 -9
- package/src/lib/components/select/_elder-select-base.scss +1 -9
- package/src/lib/components/select/filter/elder-filter-chip-template/elder-filter-chip-template.component.scss +1 -4
- package/src/lib/components/select/multi/elder-multi-select-chip-options/elder-multi-select-chip-options.component.scss +10 -39
- package/src/lib/components/select/multi/elder-multi-select-chips/elder-multi-select-chips.component.scss +19 -52
- package/src/lib/components/select/single/elder-select/elder-select.component.scss +24 -40
- package/src/lib/components/time/_elder-time-input.theme.scss +0 -3
- package/theming/_elder-color-variants.scss +26 -0
- package/theming/_elder-common.scss +6 -399
- package/theming/_elder-defaults.scss +3 -7
- package/theming/_elder-form.scss +308 -0
- package/theming/_elder-layout-system.scss +242 -0
- package/theming/_elder-m3-theme.scss +754 -0
- package/theming/_elder-mdc-support.scss +59 -142
- package/theming/_elder-scrollbar-theme.scss +2 -12
- package/theming/_elder-style-fixes.scss +46 -109
- package/theming/_elder-typography-utils.scss +0 -11
- package/theming/_mixins.scss +35 -0
- package/theming/_elder-palettes.scss +0 -148
- package/theming/_elder-theme.scss +0 -51
- package/theming/_elder-toast-theme.scss +0 -46
- package/theming/_mat-icon-button-size.scss +0 -34
|
@@ -1,172 +1,43 @@
|
|
|
1
1
|
@use 'sass:map';
|
|
2
2
|
@use '@angular/material' as mat;
|
|
3
|
-
@use '
|
|
4
|
-
@use '../theming/elder-typography-utils' as elder-typography;
|
|
3
|
+
@use './elder-typography-utils' as elder-typography;
|
|
5
4
|
|
|
6
5
|
@mixin mdc-theme-support($config-or-theme) {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
@if $color != null {
|
|
11
|
-
@include _color-support($color);
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
@if $typography != null {
|
|
15
|
-
@include _typography-support($typography);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
/**
|
|
19
|
-
* This class should be applied to "controls"
|
|
20
|
-
* which themself contain a mat-form-field.
|
|
21
|
-
*/
|
|
22
|
-
.elder-form-field-host {
|
|
23
|
-
display: inline-flex;
|
|
24
|
-
flex-direction: column;
|
|
25
|
-
min-width: 0;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
@mixin _typography-support($typography-config) {
|
|
30
|
-
$config: $typography-config;
|
|
31
|
-
|
|
32
|
-
// The unit-less line-height from the font config.
|
|
33
|
-
$line-height: mat.m2-line-height($config, body-1);
|
|
34
|
-
$font-size: mat.m2-font-size($config, body-1);
|
|
35
|
-
$line-height-em: elder-typography.coerce-unitless-to-em($line-height);
|
|
36
|
-
|
|
37
|
-
// $control-button-size: 24px; // $line-height-em
|
|
38
|
-
$control-button-size: var(--mdc-typography-body1-line-height, 24px);
|
|
39
|
-
$control-icon-size: 20px;
|
|
40
|
-
|
|
41
|
-
.elder-mdc-input-fix {
|
|
42
|
-
max-height: $control-button-size;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.mat-mdc-icon-button.elder-control-icon-button {
|
|
46
|
-
@include icon-button-size.matIconButtonSize($control-button-size, $control-icon-size); // 0.6
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.mat-datepicker-toggle.elder-control-icon-button {
|
|
50
|
-
max-height: $control-button-size;
|
|
51
|
-
max-width: $control-button-size;
|
|
52
|
-
|
|
53
|
-
.mat-mdc-icon-button {
|
|
54
|
-
@include icon-button-size.matIconButtonSize($control-button-size, $control-icon-size); // 0.6
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
@mixin _color-support($color-config) {
|
|
60
|
-
@include _mdc-control-icon($color-config);
|
|
61
|
-
@include _mdc-mat-toolbar($color-config);
|
|
62
|
-
@include _mdc-mat-snack-bar($color-config);
|
|
6
|
+
@include _mdc-mat-toolbar();
|
|
7
|
+
@include _mdc-control-icon();
|
|
63
8
|
}
|
|
64
9
|
|
|
65
|
-
|
|
66
|
-
* The snackbar has a light background in dark, and a dark background in light theme.
|
|
67
|
-
* Therefore, text/contrast colors need to be inverted inside the snackbar.
|
|
68
|
-
*/
|
|
69
|
-
@mixin _mdc-mat-snack-bar($color-config) {
|
|
70
|
-
$is-dark-theme: map.get($color-config, is-dark);
|
|
71
|
-
$snackbar-text-color: if(
|
|
72
|
-
$is-dark-theme,
|
|
73
|
-
var(--mdc-theme-text-primary-on-light),
|
|
74
|
-
var(--mdc-theme-text-primary-on-dark)
|
|
75
|
-
);
|
|
76
|
-
|
|
77
|
-
.mat-mdc-snack-bar-container {
|
|
78
|
-
color: $snackbar-text-color; // Fix the default text color in snackbar
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
@mixin _mdc-mat-toolbar($color-config) {
|
|
83
|
-
$foreground: map.get($color-config, foreground);
|
|
84
|
-
$background: map.get($color-config, background);
|
|
85
|
-
$primary: map.get($color-config, primary);
|
|
86
|
-
$accent: map.get($color-config, accent);
|
|
87
|
-
$warn: map.get($color-config, warn);
|
|
88
|
-
|
|
10
|
+
@mixin _mdc-mat-toolbar() {
|
|
89
11
|
.mat-toolbar {
|
|
90
12
|
&.mat-primary {
|
|
91
|
-
@include _form-field-palette(
|
|
13
|
+
@include _form-field-palette(primary);
|
|
92
14
|
}
|
|
93
15
|
|
|
94
16
|
&.mat-accent {
|
|
95
|
-
@include _form-field-palette(
|
|
17
|
+
@include _form-field-palette(accent);
|
|
96
18
|
}
|
|
97
19
|
|
|
98
20
|
&.mat-warn {
|
|
99
|
-
@include _form-field-palette(
|
|
21
|
+
@include _form-field-palette(warn);
|
|
100
22
|
}
|
|
101
23
|
}
|
|
102
24
|
}
|
|
103
25
|
|
|
104
|
-
@mixin
|
|
105
|
-
$
|
|
106
|
-
$
|
|
107
|
-
$
|
|
108
|
-
$accent: map.get($color-config, accent);
|
|
109
|
-
$warn: map.get($color-config, warn);
|
|
110
|
-
|
|
111
|
-
.elder-mdc-control-icon {
|
|
112
|
-
color: mat.m2-get-color-from-palette($foreground, secondary-text);
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
.mat-mdc-form-field {
|
|
116
|
-
&.mat-focused {
|
|
117
|
-
&.mat-primary {
|
|
118
|
-
.elder-mdc-control-icon,
|
|
119
|
-
.elder-control-icon-button {
|
|
120
|
-
color: mat.m2-get-color-from-palette($primary, text);
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
&.mat-accent {
|
|
125
|
-
.elder-mdc-control-icon,
|
|
126
|
-
.elder-control-icon-button {
|
|
127
|
-
color: mat.m2-get-color-from-palette($accent, text);
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
&.mat-warn {
|
|
132
|
-
.elder-mdc-control-icon,
|
|
133
|
-
.elder-control-icon-button {
|
|
134
|
-
color: mat.m2-get-color-from-palette($warn, text);
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
&.mat-form-field-invalid {
|
|
140
|
-
.elder-mdc-control-icon,
|
|
141
|
-
.elder-control-icon-button {
|
|
142
|
-
color: mat.m2-get-color-from-palette($warn, text);
|
|
143
|
-
}
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
&.mat-form-field-disabled {
|
|
147
|
-
.elder-mdc-control-icon,
|
|
148
|
-
.elder-control-icon-button {
|
|
149
|
-
color: mat.m2-get-color-from-palette($foreground, disabled-text);
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
@mixin _form-field-palette($palette) {
|
|
156
|
-
$contrast-color: mat.m2-get-color-from-palette($palette, default-contrast);
|
|
157
|
-
$contrast-color-inactive: rgba($contrast-color, 0.5);
|
|
26
|
+
@mixin _form-field-palette($baseColor) {
|
|
27
|
+
$contrast-color: var(--md-sys-color-on-primary);
|
|
28
|
+
$contrast-color-inactive: var(--md-sys-color-outline-variant);
|
|
29
|
+
$bg-color-extra: transparent;
|
|
158
30
|
|
|
159
31
|
.mat-mdc-slide-toggle .mdc-form-field {
|
|
160
|
-
background: mat.m2-get-color-from-palette($palette);
|
|
161
32
|
color: $contrast-color;
|
|
162
33
|
}
|
|
163
34
|
|
|
164
35
|
.mat-mdc-form-field.mat-form-field-appearance-outline {
|
|
165
|
-
background:
|
|
36
|
+
background: $bg-color-extra;
|
|
166
37
|
color: $contrast-color;
|
|
167
38
|
|
|
168
39
|
.mdc-text-field__input {
|
|
169
|
-
background:
|
|
40
|
+
background: $bg-color-extra;
|
|
170
41
|
color: $contrast-color;
|
|
171
42
|
caret-color: currentColor;
|
|
172
43
|
}
|
|
@@ -233,3 +104,49 @@
|
|
|
233
104
|
}
|
|
234
105
|
}
|
|
235
106
|
}
|
|
107
|
+
|
|
108
|
+
@mixin _mdc-control-icon() {
|
|
109
|
+
.elder-mdc-control-icon {
|
|
110
|
+
color: var(--md-sys-color-on-surface-variant, var(--md-sys-color-on-surface));
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.mat-mdc-form-field {
|
|
114
|
+
&.mat-focused {
|
|
115
|
+
&.mat-primary {
|
|
116
|
+
.elder-mdc-control-icon,
|
|
117
|
+
.elder-control-icon-button {
|
|
118
|
+
color: var(--md-sys-color-primary);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
&.mat-accent {
|
|
123
|
+
.elder-mdc-control-icon,
|
|
124
|
+
.elder-control-icon-button {
|
|
125
|
+
color: var(--md-sys-color-tertiary);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
&.mat-warn {
|
|
130
|
+
.elder-mdc-control-icon,
|
|
131
|
+
.elder-control-icon-button {
|
|
132
|
+
color: var(--md-sys-color-error);
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
&.mat-form-field-invalid {
|
|
138
|
+
.elder-mdc-control-icon,
|
|
139
|
+
.elder-control-icon-button {
|
|
140
|
+
color: var(--md-sys-color-error);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
&.mat-form-field-disabled {
|
|
145
|
+
.elder-mdc-control-icon,
|
|
146
|
+
.elder-control-icon-button {
|
|
147
|
+
color: var(--md-sys-color-on-surface, var(--md-sys-color-outline));
|
|
148
|
+
opacity: 0.38;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
}
|
|
@@ -9,11 +9,6 @@
|
|
|
9
9
|
$scrollbarStyling: map.get($theme, elder, scrollbar-styling);
|
|
10
10
|
|
|
11
11
|
@if $scrollbarStyling {
|
|
12
|
-
$primary: map-get($theme, primary);
|
|
13
|
-
$accent: map-get($theme, accent);
|
|
14
|
-
$warn: map-get($theme, warn);
|
|
15
|
-
$background: map-get($theme, background);
|
|
16
|
-
$foreground: map-get($theme, foreground);
|
|
17
12
|
$commonSizes: map.get($theme, elder, common-sizes);
|
|
18
13
|
|
|
19
14
|
@include scrollbar-width(map.get($commonSizes, sm)); // default
|
|
@@ -42,20 +37,15 @@
|
|
|
42
37
|
@include scrollbar-width(map.get($commonSizes, xxl));
|
|
43
38
|
}
|
|
44
39
|
|
|
45
|
-
/* Track */
|
|
46
|
-
::-webkit-scrollbar-track {
|
|
47
|
-
// background: mat.get-color-from-palette($background, background);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
40
|
/* Handle */
|
|
51
41
|
::-webkit-scrollbar-thumb {
|
|
52
|
-
background:
|
|
42
|
+
background: var(--md-sys-color-primary);
|
|
53
43
|
border-radius: 5px;
|
|
54
44
|
}
|
|
55
45
|
|
|
56
46
|
/* Handle on hover */
|
|
57
47
|
::-webkit-scrollbar-thumb:hover {
|
|
58
|
-
background:
|
|
48
|
+
background: var(--md-sys-color-primary-fixed);
|
|
59
49
|
}
|
|
60
50
|
}
|
|
61
51
|
}
|
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
@use '@angular/material' as mat;
|
|
2
|
-
@use 'mixins' as mixins;
|
|
2
|
+
@use './mixins' as mixins;
|
|
3
3
|
@use 'sass:map';
|
|
4
4
|
|
|
5
5
|
@mixin elder-style-fixes($theme) {
|
|
6
6
|
@include _ng-style-fixes;
|
|
7
7
|
@include _mat-style-fixes($theme);
|
|
8
|
+
@include _mat3-fixes($theme);
|
|
9
|
+
|
|
10
|
+
// elder custom icons fill color
|
|
11
|
+
.mat-icon.svg-icon-inherit-color svg * {
|
|
12
|
+
fill: currentColor !important;
|
|
13
|
+
}
|
|
8
14
|
}
|
|
9
15
|
|
|
10
16
|
@mixin _ng-style-fixes {
|
|
@@ -85,88 +91,6 @@
|
|
|
85
91
|
z-index: 1;
|
|
86
92
|
}
|
|
87
93
|
|
|
88
|
-
.mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper {
|
|
89
|
-
padding-left: 0 !important;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper {
|
|
93
|
-
padding-right: 0 !important;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.mat-mdc-form-field:not(.mat-mdc-form-field.elder-dense) {
|
|
97
|
-
$density: map-get($theme, elder, density, form-field);
|
|
98
|
-
|
|
99
|
-
/******************************
|
|
100
|
-
Fix big paddings for dense form fields
|
|
101
|
-
*******************************/
|
|
102
|
-
|
|
103
|
-
.mat-mdc-text-field-wrapper {
|
|
104
|
-
padding-left: calc-side-paddings($density);
|
|
105
|
-
padding-right: calc-side-paddings($density);
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
/******************************
|
|
109
|
-
Fix icon size and placement in mat label
|
|
110
|
-
*******************************/
|
|
111
|
-
|
|
112
|
-
@include mixins.form-field-icons($density);
|
|
113
|
-
|
|
114
|
-
/******************************
|
|
115
|
-
Fix text and hover placement of small filled form fields
|
|
116
|
-
*******************************/
|
|
117
|
-
|
|
118
|
-
$mat-mdc-form-field-label-transform: 0.75;
|
|
119
|
-
$mat-mdc-form-field-label-offset-x: -16px;
|
|
120
|
-
$form-field-density: map-get($theme, elder, density, form-field);
|
|
121
|
-
|
|
122
|
-
@if $form-field-density < -1 {
|
|
123
|
-
.mdc-text-field--filled {
|
|
124
|
-
.mdc-floating-label--float-above {
|
|
125
|
-
transform: var(
|
|
126
|
-
$mat-mdc-form-field-label-transform,
|
|
127
|
-
translateY(-50%)
|
|
128
|
-
translateX(calc(1 * (44px + var($mat-mdc-form-field-label-offset-x, 0px))))
|
|
129
|
-
) !important;
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
.mat-mdc-form-field-infix {
|
|
133
|
-
padding-top: calc-padding-top-form-field-inflix($form-field-density) !important;
|
|
134
|
-
padding-bottom: 2px !important;
|
|
135
|
-
min-height: 40px; // (24 + 2*16) = 56px by default
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
/******************************
|
|
141
|
-
Material Form Field Label stealing clicks
|
|
142
|
-
*******************************/
|
|
143
|
-
|
|
144
|
-
.mat-mdc-floating-label.mdc-floating-label {
|
|
145
|
-
pointer-events: none !important;
|
|
146
|
-
|
|
147
|
-
mat-label {
|
|
148
|
-
pointer-events: none !important;
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
.mdc-notched-outline__notch {
|
|
153
|
-
pointer-events: none !important;
|
|
154
|
-
|
|
155
|
-
.mdc-floating-label {
|
|
156
|
-
pointer-events: none !important;
|
|
157
|
-
|
|
158
|
-
mat-label {
|
|
159
|
-
pointer-events: none !important;
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
.mat-mdc-form-field-error-wrapper {
|
|
165
|
-
display: flex;
|
|
166
|
-
padding-right: 0;
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
|
|
170
94
|
/******************************
|
|
171
95
|
Material chip make regular chips clickable when applying this class
|
|
172
96
|
*******************************/
|
|
@@ -176,36 +100,49 @@
|
|
|
176
100
|
cursor: pointer;
|
|
177
101
|
}
|
|
178
102
|
}
|
|
179
|
-
}
|
|
180
103
|
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
104
|
+
/******************************
|
|
105
|
+
Styling toast messages
|
|
106
|
+
*******************************/
|
|
107
|
+
.elder-primary-text {
|
|
108
|
+
color: var(--md-sys-color-primary);
|
|
109
|
+
}
|
|
184
110
|
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
@if $density == -4 {
|
|
193
|
-
@return $paddingDensityNeg4;
|
|
194
|
-
} @else if $density == -3 {
|
|
195
|
-
@return $paddingDensityNeg3;
|
|
196
|
-
} @else if $density == -2 {
|
|
197
|
-
@return $paddingDensityNeg2;
|
|
198
|
-
} @else if $density == -1 {
|
|
199
|
-
@return $paddingDensityNeg1;
|
|
200
|
-
} @else if $density == 0 {
|
|
201
|
-
@return $paddingDensity0;
|
|
111
|
+
.elder-accent-text {
|
|
112
|
+
color: var(--md-sys-color-tertiary);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.elder-warn-text {
|
|
116
|
+
color: var(--md-sys-color-error);
|
|
202
117
|
}
|
|
203
118
|
}
|
|
204
119
|
|
|
205
|
-
@
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
120
|
+
@mixin _mat3-fixes($theme) {
|
|
121
|
+
--mat-sidenav-container-width: auto; // is set to around 300px by default in MAT 3 (MAT 2 was auto by default)
|
|
122
|
+
--mat-badge-small-size-text-size: 9px; // this is the mat2 setting, mat3 somehow sets this to 0, which hides the font, unclear why.
|
|
123
|
+
--mdc-dialog-container-shape: 16px; // make border-radius of dialog container smaller (default is 28px)
|
|
124
|
+
--mat-dialog-container-max-width: 80vw; // 80vw is mat 2 default, mat 3 default is very narrow: 560px;
|
|
125
|
+
--mat-toolbar-title-text-tracking: 0; // mat toolbar typography
|
|
126
|
+
--mat-toolbar-title-text-weight: 500; // mat toolbar typography
|
|
127
|
+
|
|
128
|
+
.mat-toolbar {
|
|
129
|
+
&.mat-primary {
|
|
130
|
+
--mat-toolbar-container-text-color: var(--md-sys-color-on-primary);
|
|
131
|
+
--mat-toolbar-container-background-color: var(--md-sys-color-primary);
|
|
132
|
+
.mat-mdc-icon-button {
|
|
133
|
+
color: var(--md-sys-color-on-primary);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
&.mat-accent {
|
|
137
|
+
--mat-toolbar-container-text-color: var(--md-sys-color-on-tertiary);
|
|
138
|
+
--mat-toolbar-container-background-color: var(--md-sys-color-tertiary);
|
|
139
|
+
.mat-mdc-icon-button {
|
|
140
|
+
color: var(--md-sys-color-on-tertiary);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.mat-toolbar .mat-mdc-icon-button {
|
|
146
|
+
color: inherit;
|
|
210
147
|
}
|
|
211
148
|
}
|
|
@@ -10,14 +10,3 @@
|
|
|
10
10
|
@function coerce-unitless-to-em($value) {
|
|
11
11
|
@return if(math.is-unitless($value), 1em * $value, $value);
|
|
12
12
|
}
|
|
13
|
-
|
|
14
|
-
@function get-typography-config($config) {
|
|
15
|
-
$typography: mat.m2-get-typography-config($config);
|
|
16
|
-
|
|
17
|
-
// If no actual typography configuration has been specified, create a default one.
|
|
18
|
-
@if not $typography {
|
|
19
|
-
$typography: mat.m2-define-typography-config();
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
@return $typography;
|
|
23
|
-
}
|
package/theming/_mixins.scss
CHANGED
|
@@ -50,3 +50,38 @@
|
|
|
50
50
|
@return 40px;
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Based on https://github.com/btxtiger/mat-icon-button-sizes
|
|
56
|
+
* The default factor between button and icon size is *= 0.6
|
|
57
|
+
*/
|
|
58
|
+
@mixin matIconButtonSize($buttonSize, $iconSize) {
|
|
59
|
+
width: $buttonSize !important;
|
|
60
|
+
height: $buttonSize !important;
|
|
61
|
+
padding: 0 !important;
|
|
62
|
+
display: inline-flex !important;
|
|
63
|
+
align-items: center;
|
|
64
|
+
justify-content: center;
|
|
65
|
+
|
|
66
|
+
.mat-icon,
|
|
67
|
+
img {
|
|
68
|
+
width: $iconSize;
|
|
69
|
+
height: $iconSize;
|
|
70
|
+
font-size: $iconSize;
|
|
71
|
+
|
|
72
|
+
svg {
|
|
73
|
+
width: $iconSize;
|
|
74
|
+
height: $iconSize;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
svg {
|
|
79
|
+
width: $iconSize;
|
|
80
|
+
height: $iconSize;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.mat-mdc-button-touch-target {
|
|
84
|
+
width: $buttonSize !important;
|
|
85
|
+
height: $buttonSize !important;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
@@ -1,148 +0,0 @@
|
|
|
1
|
-
@use '@angular/material' as mat;
|
|
2
|
-
@use 'sass:map';
|
|
3
|
-
|
|
4
|
-
/***************************************************************************
|
|
5
|
-
* *
|
|
6
|
-
* Overriding Material Base Variables *
|
|
7
|
-
* *
|
|
8
|
-
**************************************************************************/
|
|
9
|
-
|
|
10
|
-
$dark-primary-text: rgba(black, 0.87);
|
|
11
|
-
$light-primary-text: white;
|
|
12
|
-
|
|
13
|
-
/***************************************************************************
|
|
14
|
-
* *
|
|
15
|
-
* Material Color Palettes *
|
|
16
|
-
* *
|
|
17
|
-
**************************************************************************/
|
|
18
|
-
|
|
19
|
-
// ElderByte Theme
|
|
20
|
-
|
|
21
|
-
$elder-blue: (
|
|
22
|
-
50: #dfe3e8,
|
|
23
|
-
100: #b3bcc8,
|
|
24
|
-
200: #8593a7,
|
|
25
|
-
300: #546883,
|
|
26
|
-
400: #2f4869,
|
|
27
|
-
500: #0b284f,
|
|
28
|
-
// Official Main Color tone: #002852 (#0B284F)
|
|
29
|
-
600: #0a2448,
|
|
30
|
-
700: #092040,
|
|
31
|
-
800: #081c38,
|
|
32
|
-
900: #061529,
|
|
33
|
-
A100: #809ec5,
|
|
34
|
-
A200: #5179bf,
|
|
35
|
-
A400: #004390,
|
|
36
|
-
A700: #00006b,
|
|
37
|
-
contrast: (
|
|
38
|
-
50: $dark-primary-text,
|
|
39
|
-
100: $dark-primary-text,
|
|
40
|
-
200: $dark-primary-text,
|
|
41
|
-
300: $dark-primary-text,
|
|
42
|
-
400: $light-primary-text,
|
|
43
|
-
500: $light-primary-text,
|
|
44
|
-
600: $light-primary-text,
|
|
45
|
-
700: $light-primary-text,
|
|
46
|
-
800: $light-primary-text,
|
|
47
|
-
900: $light-primary-text,
|
|
48
|
-
A100: $light-primary-text,
|
|
49
|
-
A200: $light-primary-text,
|
|
50
|
-
A400: $light-primary-text,
|
|
51
|
-
A700: $light-primary-text,
|
|
52
|
-
),
|
|
53
|
-
);
|
|
54
|
-
|
|
55
|
-
$elder-gold: (
|
|
56
|
-
50: #f6f3ec,
|
|
57
|
-
100: #e8e1d1,
|
|
58
|
-
200: #dacfb4,
|
|
59
|
-
300: #ccbc96,
|
|
60
|
-
400: #c1ad80,
|
|
61
|
-
500: #b69f6a,
|
|
62
|
-
// Official ElderByte Accent tone
|
|
63
|
-
600: #a69160,
|
|
64
|
-
700: #948156,
|
|
65
|
-
800: #81714b,
|
|
66
|
-
900: #5f5337,
|
|
67
|
-
A100: #e1d1a9,
|
|
68
|
-
A200: #efd08f,
|
|
69
|
-
A400: #dbbe7a,
|
|
70
|
-
A700: #af9144,
|
|
71
|
-
contrast: (
|
|
72
|
-
50: $dark-primary-text,
|
|
73
|
-
100: $dark-primary-text,
|
|
74
|
-
200: $dark-primary-text,
|
|
75
|
-
300: $dark-primary-text,
|
|
76
|
-
400: $dark-primary-text,
|
|
77
|
-
500: $dark-primary-text,
|
|
78
|
-
600: $dark-primary-text,
|
|
79
|
-
700: $dark-primary-text,
|
|
80
|
-
800: $dark-primary-text,
|
|
81
|
-
900: $dark-primary-text,
|
|
82
|
-
A100: $dark-primary-text,
|
|
83
|
-
A200: $dark-primary-text,
|
|
84
|
-
A400: $dark-primary-text,
|
|
85
|
-
A700: $dark-primary-text,
|
|
86
|
-
),
|
|
87
|
-
);
|
|
88
|
-
|
|
89
|
-
/***************************************************************************
|
|
90
|
-
* *
|
|
91
|
-
* Dark Theme Palettes *
|
|
92
|
-
* *
|
|
93
|
-
**************************************************************************/
|
|
94
|
-
|
|
95
|
-
$grey-palette: mat.$m2-grey-palette;
|
|
96
|
-
$light-primary-text: rgba(white, 0.87);
|
|
97
|
-
$light-secondary-text: rgba(white, 0.4);
|
|
98
|
-
$light-disabled-text: rgba(white, 0.38);
|
|
99
|
-
$light-dividers: rgba(white, 0.12);
|
|
100
|
-
$light-focused: rgba(white, 0.12);
|
|
101
|
-
|
|
102
|
-
$dark-background-dp-01: #1f1f1f; // 5%
|
|
103
|
-
$dark-background-dp-02: #222222; // 7%
|
|
104
|
-
$dark-background-dp-03: #262626; // 8%
|
|
105
|
-
$dark-background-dp-04: #272727; // 9%
|
|
106
|
-
$dark-background-dp-06: #2c2c2c; // 11%
|
|
107
|
-
$dark-background-dp-08: #2d2d2d; // 12%
|
|
108
|
-
$dark-background-dp-12: #333333; // 14%
|
|
109
|
-
|
|
110
|
-
// Background palette for dark themes.
|
|
111
|
-
$elder-dark-theme-background: (
|
|
112
|
-
status-bar: black,
|
|
113
|
-
app-bar: $dark-background-dp-01,
|
|
114
|
-
background: #121212,
|
|
115
|
-
// #121212
|
|
116
|
-
hover: rgba(white, 0.04),
|
|
117
|
-
card: $dark-background-dp-03,
|
|
118
|
-
dialog: $dark-background-dp-12,
|
|
119
|
-
// $my-dark-dp-06
|
|
120
|
-
disabled-button: rgba(white, 0.12),
|
|
121
|
-
raised-button: map.get($grey-palette, 800),
|
|
122
|
-
focused-button: $light-focused,
|
|
123
|
-
selected-button: map.get($grey-palette, 900),
|
|
124
|
-
selected-disabled-button: map.get($grey-palette, 800),
|
|
125
|
-
disabled-button-toggle: black,
|
|
126
|
-
unselected-chip: map.get($grey-palette, 800),
|
|
127
|
-
disabled-list-option: rgba(white, 0.12),
|
|
128
|
-
tooltip: map.get($grey-palette, 800),
|
|
129
|
-
);
|
|
130
|
-
|
|
131
|
-
// Foreground palette for dark themes.
|
|
132
|
-
$elder-dark-theme-foreground: (
|
|
133
|
-
base: rgba(white, 0.87),
|
|
134
|
-
divider: $light-dividers,
|
|
135
|
-
dividers: $light-dividers,
|
|
136
|
-
disabled: $light-disabled-text,
|
|
137
|
-
disabled-button: rgba(white, 0.38),
|
|
138
|
-
disabled-text: $light-disabled-text,
|
|
139
|
-
elevation: black,
|
|
140
|
-
hint-text: $light-disabled-text,
|
|
141
|
-
secondary-text: $light-secondary-text,
|
|
142
|
-
icon: rgba(white, 0.87),
|
|
143
|
-
icons: rgba(white, 0.87),
|
|
144
|
-
text: rgba(white, 0.87),
|
|
145
|
-
slider-min: rgba(white, 0.87),
|
|
146
|
-
slider-off: rgba(white, 0.38),
|
|
147
|
-
slider-off-active: rgba(white, 0.38),
|
|
148
|
-
);
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
@use '@angular/material' as mat;
|
|
2
|
-
@use 'sass:map';
|
|
3
|
-
@use 'elder-palettes' as palettes;
|
|
4
|
-
|
|
5
|
-
/***************************************************************************
|
|
6
|
-
* *
|
|
7
|
-
* Public API *
|
|
8
|
-
* *
|
|
9
|
-
**************************************************************************/
|
|
10
|
-
|
|
11
|
-
@function define-dark-elder-theme($config) {
|
|
12
|
-
$result: $config;
|
|
13
|
-
@if map.get($config, color) {
|
|
14
|
-
$color-settings: map.get($config, color);
|
|
15
|
-
$primary: map.get($color-settings, primary);
|
|
16
|
-
$accent: map.get($color-settings, accent);
|
|
17
|
-
$warn: map.get($color-settings, warn);
|
|
18
|
-
$result: map.merge(
|
|
19
|
-
$config,
|
|
20
|
-
(
|
|
21
|
-
color: _mat-create-dark-color-config($primary, $accent, $warn),
|
|
22
|
-
)
|
|
23
|
-
);
|
|
24
|
-
}
|
|
25
|
-
@return _create-backwards-compatibility-theme($result);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/***************************************************************************
|
|
29
|
-
* *
|
|
30
|
-
* Private functions *
|
|
31
|
-
* *
|
|
32
|
-
**************************************************************************/
|
|
33
|
-
|
|
34
|
-
@function _mat-create-dark-color-config($primary, $accent, $warn: null) {
|
|
35
|
-
@return (
|
|
36
|
-
primary: $primary,
|
|
37
|
-
accent: $accent,
|
|
38
|
-
warn: if($warn != null, $warn, mat.m2-define-palette(mat.$m2-red-palette)),
|
|
39
|
-
is-dark: true,
|
|
40
|
-
foreground: palettes.$elder-dark-theme-foreground,
|
|
41
|
-
background: palettes.$elder-dark-theme-background
|
|
42
|
-
);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
@function _create-backwards-compatibility-theme($theme) {
|
|
46
|
-
@if not map.get($theme, color) {
|
|
47
|
-
@return $theme;
|
|
48
|
-
}
|
|
49
|
-
$color: map.get($theme, color);
|
|
50
|
-
@return map.merge($theme, $color);
|
|
51
|
-
}
|