@elderbyte/ngx-starter 19.1.0-beta.3 → 19.1.0-beta.30

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.
Files changed (64) hide show
  1. package/_index.scss +1 -1
  2. package/fesm2022/elderbyte-ngx-starter.mjs +1196 -1116
  3. package/fesm2022/elderbyte-ngx-starter.mjs.map +1 -1
  4. package/lib/common/utils/public_api.d.ts +1 -0
  5. package/lib/components/data-view/base/elder-data-view-base.d.ts +14 -0
  6. package/lib/components/data-view/table/elder-table/elder-table.component.d.ts +2 -1
  7. package/lib/components/layout/pane/header/pane-actions.component.d.ts +5 -0
  8. package/lib/components/layout/pane/header/pane-header.component.d.ts +7 -0
  9. package/lib/components/layout/pane/header/pane-title.component.d.ts +5 -0
  10. package/lib/components/layout/pane/pane-content.component.d.ts +5 -0
  11. package/lib/components/layout/pane/pane.component.d.ts +1 -1
  12. package/lib/components/layout/public_api.d.ts +4 -0
  13. package/lib/components/select/single/elder-select/elder-select.component.d.ts +1 -1
  14. package/package.json +1 -1
  15. package/src/lib/components/card-organizer/card-stack/elder-card-stack.component.scss +7 -11
  16. package/src/lib/components/data-transfer/http-data-transfer-overview/http-data-transfer-overview.component.scss +20 -11
  17. package/src/lib/components/data-view/common/elder-data-toolbar/elder-data-toolbar.component.scss +3 -0
  18. package/src/lib/components/data-view/grid/elder-grid/elder-grid.component.scss +70 -82
  19. package/src/lib/components/data-view/table/elder-table/elder-table.component.scss +3 -217
  20. package/src/lib/components/files/drag-n-drop/elder-drop-zone/elder-drop-zone.component.scss +4 -4
  21. package/src/lib/components/forms/search/search-box/elder-search-box.component.scss +1 -0
  22. package/src/lib/components/labels/labels-input/labels-input.component.scss +0 -3
  23. package/src/lib/components/navigation/nav/nav-group/elder-nav-group.component.scss +20 -5
  24. package/src/lib/components/navigation/nav/nav-link/elder-nav-link.component.scss +33 -6
  25. package/src/lib/components/panels/elder-dialog-panel/elder-dialog-panel.component.scss +2 -2
  26. package/src/lib/components/panels/toggle-panel/elder-toggle-panel.component.scss +3 -0
  27. package/src/lib/components/select/filter/elder-filter-chip-template/elder-filter-chip-template.component.scss +0 -77
  28. package/src/lib/components/select/multi/elder-multi-select-chip-options/elder-multi-select-chip-options.component.scss +0 -48
  29. package/src/lib/components/select/multi/elder-multi-select-chips/elder-multi-select-chips.component.scss +0 -60
  30. package/src/lib/components/select/single/elder-select/elder-select.component.scss +14 -51
  31. package/src/lib/components/select-chip-list/chip-list-select/elder-chip-list-select.component.scss +0 -11
  32. package/src/lib/components/shell/header/elder-app-header/elder-app-header.component.scss +1 -1
  33. package/src/lib/components/toasts/standard-toast/standard-toast.component.scss +1 -1
  34. package/theming/abstracts/_elder-design-tokens.scss +225 -0
  35. package/theming/{system/_elder-config.scss → abstracts/_elder-scss-variables.scss} +34 -0
  36. package/theming/{system/_elder-defaults.scss → abstracts/_elder-set-defaults-fn.scss} +8 -8
  37. package/theming/abstracts/_elder-starter-theme.scss +49 -0
  38. package/theming/abstracts/_elder-theme-main.scss +96 -0
  39. package/theming/{style-tweaks/_elder-common.scss → base/_elder-common-base.scss} +20 -45
  40. package/theming/base/_elder-fixes-base.scss +199 -0
  41. package/theming/{style-tweaks/_elder-form.scss → base/_elder-form-base.scss} +18 -3
  42. package/theming/base/_elder-root-base.scss +40 -0
  43. package/theming/components/_elder-chip-theme.scss +297 -0
  44. package/theming/components/_elder-select-theme.scss +75 -0
  45. package/theming/components/_elder-table-theme.scss +209 -0
  46. package/theming/components/_elder-toolbar-theme.scss +75 -0
  47. package/theming/{utility-classes/_elder-color-helpers.scss → utilities/_elder-color-utils.scss} +7 -14
  48. package/theming/utilities/_elder-common-utils.scss +52 -0
  49. package/theming/{utility-classes/_elder-flex-layout.scss → utilities/_elder-flex-layout-utils.scss} +2 -2
  50. package/theming/{utility-classes/_elder-layout-system.scss → utilities/_elder-layout-utils.scss} +226 -201
  51. package/theming/{utility-classes/_elder-typography-helpers.scss → utilities/_elder-typography-utils.scss} +1 -1
  52. package/lib/components/m3-sidenav/m3-sidenav.component.d.ts +0 -5
  53. package/src/lib/components/chips/_elder-chip-theme.scss +0 -129
  54. package/src/lib/components/navigation/nav/_elder-nav-theme.scss +0 -66
  55. package/src/lib/components/select/_elder-select-base.scss +0 -28
  56. package/theming/style-tweaks/_elder-color-variants.scss +0 -31
  57. package/theming/style-tweaks/_elder-component-themes.scss +0 -22
  58. package/theming/style-tweaks/_elder-reset.scss +0 -13
  59. package/theming/style-tweaks/_elder-style-fixes.scss +0 -381
  60. package/theming/system/_elder-design-tokens.scss +0 -101
  61. package/theming/system/_elder-m3-theme.scss +0 -156
  62. package/theming/system/_elder-starter-theme.scss +0 -45
  63. package/theming/utility-classes/_elder-common-helpers.scss +0 -11
  64. /package/theming/{style-tweaks/_elder-style-tweak-mixins.scss → base/_elder-base-mixins.scss} +0 -0
@@ -0,0 +1,297 @@
1
+ @use 'sass:map';
2
+ @use 'sass:color';
3
+ @use '@angular/material' as mat;
4
+ @use '../abstracts/elder-scss-variables' as config;
5
+
6
+ @mixin theme($config-or-theme) {
7
+ @include mat-chip-fixes();
8
+ @include chip-colors();
9
+
10
+ .elder-chip-text {
11
+ overflow: hidden;
12
+ text-overflow: ellipsis;
13
+ white-space: nowrap;
14
+ }
15
+
16
+ .elder-trailing-icon {
17
+ color: var(--mdc-chip-with-trailing-icon-trailing-icon-color);
18
+ opacity: 0.54;
19
+ }
20
+ }
21
+
22
+ @mixin mat-chip-fixes {
23
+ /******************************
24
+ Material Chip fix
25
+ *******************************/
26
+
27
+ .mat-mdc-chip {
28
+ // Fixes default avatar on attribute usage (<mat-chip-avatar> vs matChipAvatar) which is broken in Angular Material 15.0.0
29
+ mat-chip-avatar {
30
+ .mat-icon {
31
+ width: 18px;
32
+ height: 18px;
33
+ line-height: 18px;
34
+ font-size: 18px;
35
+ }
36
+
37
+ img {
38
+ width: 18px;
39
+ height: 18px;
40
+ overflow: hidden;
41
+ border-radius: 9px;
42
+ }
43
+ }
44
+ }
45
+
46
+ /******************************
47
+ Material chip make regular chips clickable when applying this class
48
+ *******************************/
49
+
50
+ .clickable-chip {
51
+ .mat-mdc-chip-action {
52
+ cursor: pointer;
53
+ }
54
+ }
55
+
56
+ /******************************
57
+ chip-avatar-xl
58
+ *******************************/
59
+ .mat-mdc-chip .mat-mdc-chip-avatar {
60
+ // Maximizes the avatar icon / image size in a chip.
61
+ &.chip-avatar-xl {
62
+ width: 28px;
63
+ height: 28px;
64
+ margin-left: -4px;
65
+ margin-right: -4px;
66
+
67
+ img {
68
+ width: 28px;
69
+ height: 28px;
70
+ overflow: hidden;
71
+ border-radius: 14px;
72
+ }
73
+
74
+ .mat-icon {
75
+ width: 28px !important;
76
+ height: 28px !important;
77
+ line-height: 28px !important;
78
+ font-size: 28px !important;
79
+ }
80
+ }
81
+ }
82
+ }
83
+
84
+ @mixin standard-chip-content-color-variant($color) {
85
+ @include mat.chips-overrides(
86
+ (
87
+ outline-color: $color,
88
+ label-text-color: $color,
89
+ //selected-label-text-color: $color,
90
+ with-icon-icon-color: $color,
91
+ //with-icon-selected-icon-color: $color,
92
+ with-trailing-icon-trailing-icon-color: $color,
93
+ focus-outline-color: #aaa,
94
+ //selected-trailing-icon-color: $color,
95
+ selected-trailing-icon-color: $color,
96
+ )
97
+ );
98
+ }
99
+
100
+ @mixin chip-colors {
101
+ $colorStateNone: var(--elder-chip-color-state-none);
102
+ // $colorStateNone: transparent;
103
+ $colorStateOpen: var(--elder-chip-color-state-open);
104
+
105
+ $colorStateInProgress: var(--elder-chip-color-state-in-progress);
106
+ $colorStateCompleted: var(--elder-chip-color-state-completed);
107
+ $colorStateWarn: var(--elder-chip-color-state-warn);
108
+ $colorStateError: var(--elder-chip-color-state-error);
109
+ $colorStateOther: var(--elder-chip-color-state-other);
110
+
111
+ $level-low: $colorStateCompleted;
112
+ $level-medium: $colorStateInProgress;
113
+ $level-high: $colorStateWarn;
114
+ $level-critical: $colorStateError;
115
+
116
+ // light theme elder progress chip colors
117
+ $colorStateNoneLightContent: map.get(config.$chip-colors-dark, state-none);
118
+ $colorStateOpenLightContent: map.get(config.$chip-colors-dark, state-open);
119
+ $colorStateInProgressLightContent: map.get(config.$chip-colors-dark, state-in-progress);
120
+ $colorStateCompletedLightContent: map.get(config.$chip-colors-dark, state-completed);
121
+ $colorStateWarnLightContent: map.get(config.$chip-colors-dark, state-warn);
122
+ $colorStateErrorLightContent: map.get(config.$chip-colors-dark, state-error);
123
+ $colorStateOtherLightContent: map.get(config.$chip-colors-dark, state-other);
124
+
125
+ // map to level colors
126
+ $levelLowLightContent: $colorStateCompletedLightContent;
127
+ $levelMediumLightContent: $colorStateInProgressLightContent;
128
+ $levelHighLightContent: $colorStateWarnLightContent;
129
+ $levelCriticalLightContent: $colorStateErrorLightContent;
130
+
131
+ .mat-mdc-chip.mat-mdc-chip {
132
+ &.elder-chip-state-none {
133
+ background-color: $colorStateNone;
134
+ }
135
+
136
+ &.elder-chip-state-open,
137
+ &.state-open {
138
+ background-color: $colorStateOpen;
139
+ }
140
+
141
+ &.elder-chip-state-in-progress,
142
+ &.state-in-progress {
143
+ background-color: $colorStateInProgress;
144
+ }
145
+
146
+ &.elder-chip-state-completed,
147
+ &.state-completed {
148
+ background-color: $colorStateCompleted;
149
+ }
150
+
151
+ &.elder-chip-state-warn,
152
+ &.state-warn {
153
+ background-color: $colorStateWarn;
154
+ }
155
+
156
+ &.elder-chip-state-error,
157
+ &.state-error {
158
+ background-color: $colorStateError;
159
+ }
160
+
161
+ &.elder-chip-state-other,
162
+ &.state-other {
163
+ background-color: $colorStateOther;
164
+ }
165
+
166
+ // ---
167
+
168
+ &.elder-chip-level-low,
169
+ &.level-low {
170
+ background-color: $level-low;
171
+ }
172
+ &.elder-chip-level-medium,
173
+ &.level-medium {
174
+ background-color: $level-medium;
175
+ }
176
+ &.elder-chip-level-high,
177
+ &.level-high {
178
+ background-color: $level-high;
179
+ }
180
+ &.elder-chip-level-critical,
181
+ &.level-critical {
182
+ background-color: $level-critical;
183
+ }
184
+ }
185
+
186
+ &.elder-light-theme .mat-mdc-chip.mat-mdc-chip {
187
+ &.mat-mdc-chip-highlighted {
188
+ $col: map.get(config.$palettes, primary, 30);
189
+ @include standard-chip-content-color-variant($col);
190
+ }
191
+ &[color='primary'] {
192
+ $col: map.get(config.$palettes, primary, 30);
193
+ @include standard-chip-content-color-variant($col);
194
+ }
195
+ &[color='accent'] {
196
+ $col: map.get(config.$palettes, tertiary, 40);
197
+ @include standard-chip-content-color-variant($col);
198
+ }
199
+ &[color='warn'] {
200
+ $col: map.get(config.$palettes, error, 40);
201
+ @include standard-chip-content-color-variant($col);
202
+ }
203
+ }
204
+
205
+ &.elder-dark-theme .mat-mdc-chip.mat-mdc-chip:not(.mat-mdc-chip-highlighted) {
206
+ // &.mat-mdc-chip-highlighted {
207
+ // $col: map.get(config.$palettes, primary, 30);
208
+ // @include standard-chip-content-color-variant($col);
209
+ // }
210
+ &[color='primary'] {
211
+ $col: map.get(config.$palettes, primary, 50);
212
+ @include standard-chip-content-color-variant($col);
213
+ }
214
+ &[color='accent'] {
215
+ $col: map.get(config.$palettes, tertiary, 50);
216
+ @include standard-chip-content-color-variant($col);
217
+ }
218
+ &[color='warn'] {
219
+ $col: map.get(config.$palettes, error, 50);
220
+ @include standard-chip-content-color-variant($col);
221
+ }
222
+ }
223
+
224
+ &.elder-light-theme .mat-mdc-chip.mat-mdc-chip {
225
+ &.elder-chip-state-none,
226
+ &.none {
227
+ @include chip-content-color-variant($colorStateNoneLightContent); // TODO
228
+ &.mat-mdc-chip-highlighted {
229
+ background-color: $colorStateNone;
230
+ }
231
+ }
232
+
233
+ &.elder-chip-state-open,
234
+ &.state-open {
235
+ @include chip-content-color-variant($colorStateOpenLightContent);
236
+ }
237
+
238
+ &.elder-chip-state-in-progress,
239
+ &.state-in-progress {
240
+ @include chip-content-color-variant($colorStateInProgressLightContent);
241
+ }
242
+
243
+ &.elder-chip-state-completed,
244
+ &.state-completed {
245
+ @include chip-content-color-variant($colorStateCompletedLightContent);
246
+ }
247
+
248
+ &.elder-chip-state-warn,
249
+ &.state-warn {
250
+ @include chip-content-color-variant($colorStateWarnLightContent);
251
+ }
252
+
253
+ &.elder-chip-state-error,
254
+ &.state-error {
255
+ @include chip-content-color-variant($colorStateErrorLightContent);
256
+ }
257
+
258
+ &.elder-chip-state-other,
259
+ &.state-other {
260
+ @include chip-content-color-variant($colorStateOtherLightContent);
261
+ }
262
+
263
+ // level -------------
264
+
265
+ &.elder-chip-level-low,
266
+ &.level-low {
267
+ @include chip-content-color-variant($levelLowLightContent);
268
+ }
269
+ &.elder-chip-level-medium,
270
+ &.level-medium {
271
+ @include chip-content-color-variant($levelMediumLightContent);
272
+ }
273
+ &.elder-chip-level-high,
274
+ &.level-high {
275
+ @include chip-content-color-variant($levelHighLightContent);
276
+ }
277
+ &.elder-chip-level-critical,
278
+ &.level-critical {
279
+ @include chip-content-color-variant($levelCriticalLightContent);
280
+ }
281
+ }
282
+ }
283
+
284
+ @mixin chip-content-color-variant($color, $inverse: false) {
285
+ $color-dark: color.adjust($color, $lightness: -12%);
286
+ @if $inverse {
287
+ $color-dark: color.adjust($color, $lightness: 12%);
288
+ }
289
+ @include mat.chips-overrides(
290
+ (
291
+ outline-color: $color,
292
+ label-text-color: $color-dark,
293
+ with-icon-icon-color: $color-dark,
294
+ with-trailing-icon-trailing-icon-color: $color-dark,
295
+ )
296
+ );
297
+ }
@@ -0,0 +1,75 @@
1
+ @use 'sass:map';
2
+ @use '@angular/material' as mat;
3
+
4
+
5
+ @mixin theme($config-or-theme) {
6
+ $line-height-em: var(--md-sys-typescale-body-medium-line-height);
7
+
8
+ // typography ----------------------------------------------------------
9
+ $icon-size: 16px;
10
+ $arrow-icon-size: 24px;
11
+
12
+ .elder-input-prefix-icon-container {
13
+ height: $line-height-em !important;
14
+ min-width: $line-height-em !important;
15
+ }
16
+
17
+ .elder-select-arrow {
18
+ width: $arrow-icon-size !important;
19
+ height: $arrow-icon-size !important;
20
+ line-height: $arrow-icon-size !important;
21
+ font-size: $arrow-icon-size !important;
22
+ }
23
+
24
+ .elder-icon-small {
25
+ width: $icon-size !important;
26
+ height: $icon-size !important;
27
+ line-height: $icon-size !important;
28
+ font-size: $icon-size !important;
29
+ }
30
+
31
+ // select --------------------------------------------------------------
32
+ .elder-select {
33
+ font-family: var(--md-sys-typescale-body-medium-font);
34
+
35
+ .elder-input-prefix-icon-container {
36
+ padding-right: 3px;
37
+ }
38
+ }
39
+
40
+ .elder-select-input {
41
+ height: $line-height-em;
42
+ font: inherit;
43
+ }
44
+
45
+ .elder-select-arrow {
46
+ cursor: pointer;
47
+ }
48
+
49
+ // multi-select --------------------------------------------------------------
50
+ .elder-multi-select {
51
+ font-family: var(--md-sys-typescale-body-medium-font);
52
+
53
+ .elder-select-input {
54
+ height: var(--md-sys-typescale-body-medium-line-height);
55
+ }
56
+
57
+ .elder-prefix-icon {
58
+ margin-left: 3px;
59
+ }
60
+
61
+ .elder-chip-input {
62
+ flex: 1 0 auto;
63
+ padding-left: 8px;
64
+ }
65
+
66
+ .elder-chip-input-select {
67
+ flex: 1 0 140px;
68
+ max-width: 100%;
69
+ }
70
+
71
+ .elder-browse-icon {
72
+ margin-right: 4px;
73
+ }
74
+ }
75
+ }
@@ -0,0 +1,209 @@
1
+ @mixin theme($config-or-theme) {
2
+ elder-table {
3
+ .elder-mat-inner-table {
4
+ width: 100%;
5
+ }
6
+
7
+ .elder-table-row.dense {
8
+ height: 42px !important;
9
+ }
10
+
11
+ .elder-mat-table-container {
12
+ border-radius: var(--elder-border-radius-sm);
13
+ overflow: hidden;
14
+ }
15
+
16
+ /**
17
+ * Style for the select column
18
+ */
19
+ .mat-column-select {
20
+ overflow: initial;
21
+ min-width: 72px;
22
+ max-width: 5%;
23
+ width: 72px;
24
+ }
25
+
26
+ .elder-row-removing {
27
+ text-decoration: line-through;
28
+ }
29
+
30
+ .elder-row-hidden {
31
+ display: none;
32
+ }
33
+
34
+ /******************************
35
+ Clickable row
36
+ *******************************/
37
+
38
+ .elder-table-row {
39
+ cursor: pointer;
40
+ }
41
+
42
+ .elder-table-hint {
43
+ color: gray;
44
+ }
45
+
46
+ .elder-table-footer {
47
+ height: var(--elder-data-element-footer-height);
48
+ }
49
+
50
+ .elder-table-checkbox {
51
+ opacity: 0.25;
52
+ transition: opacity 0.5s ease-in-out;
53
+ }
54
+
55
+ .elder-table-row:hover .elder-table-checkbox {
56
+ opacity: 0.9;
57
+ }
58
+
59
+ .elder-table-checkbox-visible {
60
+ opacity: 1;
61
+ }
62
+
63
+ .elder-table-inner {
64
+ background-color: var(--md-sys-color-surface-container-lowest);
65
+ }
66
+
67
+ .elder-table-row:focus {
68
+ // Disable browser focus style
69
+ box-shadow: none;
70
+ outline-style: none;
71
+ td {
72
+ background-color: var(--elder-color-highlight-strong);
73
+ border-bottom: var(--md-sys-color-tertiary-fixed);
74
+ }
75
+ }
76
+ .elder-table-row.elder-table-row-activated {
77
+ background-color: var(--elder-color-highlight-strong);
78
+ }
79
+
80
+ .elder-table-row.elder-table-row-selected {
81
+ background-color: var(--elder-color-highlight-variant);
82
+ }
83
+
84
+ .elder-table-row:hover {
85
+ background-color: var(--elder-color-highlight-light);
86
+ cursor: pointer;
87
+ }
88
+
89
+ .elder-mat-table-flat {
90
+ border: var(--elder-border-light);
91
+ }
92
+
93
+ .elder-table {
94
+ background-color: var(--mat-table-background-color);
95
+
96
+ // Fix line height of paginator section
97
+ // Fix line height of paginator section
98
+ .mat-mdc-paginator {
99
+ .mat-mdc-form-field,
100
+ .mat-mdc-floating-label {
101
+ line-height: unset;
102
+ }
103
+
104
+ .mat-mdc-select {
105
+ line-height: unset;
106
+ }
107
+ }
108
+
109
+ $pad: 8px;
110
+ $pad-right: 12px;
111
+
112
+ @include _inner-table($pad, $pad-right);
113
+ }
114
+
115
+ .mat-mdc-row {
116
+ background-color: var(--md-sys-color-surface-container-lowest);
117
+ }
118
+
119
+ .mat-mdc-header-row {
120
+ background: var(--md-sys-color-surface-container-lowest) !important;
121
+ }
122
+
123
+ .elder-table-dense-horizontal {
124
+ $pad: 8px;
125
+ $pad-right: 4px;
126
+ @include _inner-table($pad, $pad-right);
127
+ }
128
+ }
129
+ }
130
+
131
+ @mixin _inner-table($pad, $pad-right) {
132
+ .elder-mat-inner-table.mat-mdc-table {
133
+ .mat-mdc-header-cell {
134
+ padding-left: $pad;
135
+ padding-right: $pad-right;
136
+
137
+ // configure automatic wrapping of too long strings
138
+ overflow-wrap: normal;
139
+ word-wrap: normal;
140
+ word-break: normal;
141
+ white-space: unset;
142
+ hyphens: auto;
143
+
144
+ &:first-of-type {
145
+ padding-left: $pad + $pad-right;
146
+ }
147
+
148
+ &:last-of-type {
149
+ padding-right: $pad; // TODO: This can lead to overflows in some cases, is there a better solution?
150
+
151
+ &[mat-sort-header]:not([arrowposition='before']) {
152
+ padding-right: $pad;
153
+ }
154
+ }
155
+
156
+ &[mat-sort-header] {
157
+ &[arrowposition='before'] {
158
+ padding-left: 0px;
159
+ }
160
+
161
+ &:not([arrowposition='before']) {
162
+ padding-right: $pad-right;
163
+ }
164
+ }
165
+
166
+ & > .mat-sort-header-container {
167
+ display: inline-flex;
168
+ }
169
+ }
170
+
171
+ .mat-mdc-cell {
172
+ padding-left: $pad;
173
+ padding-right: $pad-right;
174
+
175
+ overflow-wrap: normal;
176
+ word-wrap: normal;
177
+ word-break: normal;
178
+ white-space: unset;
179
+ hyphens: auto;
180
+
181
+ &:first-of-type {
182
+ padding-left: $pad + $pad-right;
183
+ }
184
+
185
+ &:last-of-type {
186
+ padding-right: $pad;
187
+ }
188
+ }
189
+
190
+ .mat-mdc-footer-cell {
191
+ padding-left: $pad;
192
+ padding-right: $pad-right;
193
+ font-weight: bold;
194
+
195
+ &:first-of-type {
196
+ padding-left: $pad + $pad-right;
197
+ }
198
+
199
+ &:last-of-type {
200
+ padding-right: $pad;
201
+ }
202
+
203
+ .mat-mdc-paginator {
204
+ margin-left: -$pad;
205
+ margin-right: -$pad;
206
+ }
207
+ }
208
+ }
209
+ }
@@ -0,0 +1,75 @@
1
+ @mixin theme($config-or-theme) {
2
+ &.elder-light-theme,
3
+ &.elder-dark-theme {
4
+ .mat-toolbar {
5
+ &.mat-primary {
6
+ --mat-toolbar-container-text-color: var(--md-sys-color-on-primary);
7
+ --mat-toolbar-container-background-color: var(--md-sys-color-primary);
8
+ .mat-mdc-icon-button {
9
+ color: var(--md-sys-color-on-primary);
10
+ }
11
+ }
12
+ &.mat-accent {
13
+ --mat-toolbar-container-text-color: var(--md-sys-color-on-tertiary);
14
+ --mat-toolbar-container-background-color: var(--md-sys-color-tertiary);
15
+ .mat-mdc-icon-button {
16
+ color: var(--md-sys-color-on-tertiary);
17
+ }
18
+ }
19
+ }
20
+
21
+ .mat-toolbar.elder-toolbar-main-nav-button-container {
22
+ &.mat-primary,
23
+ &.mat-accent {
24
+ background-color: var(--elder-toolbar-main-nav-button-container-bg-color);
25
+
26
+ .mat-mdc-icon-button {
27
+ color: var(--elder-toolbar-main-nav-button-color);
28
+ }
29
+ }
30
+ }
31
+ }
32
+
33
+ &.elder-light-theme {
34
+ .mat-toolbar.mat-primary .mat-mdc-input-element::placeholder {
35
+ color: var(--md-sys-color-inverse-on-surface) !important; // fix placeholder color
36
+ }
37
+ }
38
+
39
+ &.elder-dark-theme {
40
+ .mat-toolbar {
41
+ * {
42
+ color: var(--md-sys-color-on-surface) !important;
43
+ }
44
+ .elder-toolbar-main-nav-button .mat-icon {
45
+ color: var(--md-sys-color-primary) !important;
46
+ }
47
+ }
48
+ .mat-toolbar {
49
+ background-color: var(--elder-dark-gray) !important;
50
+ }
51
+ .mat-toolbar.mat-primary {
52
+ background-color: var(--md-sys-color-secondary-container) !important;
53
+ }
54
+ .mat-toolbar.mat-accent {
55
+ background-color: var(--elder-color-highlight-variant) !important;
56
+ }
57
+
58
+ elder-app-header .elder-panel {
59
+ color: var(--md-sys-color-on-surface) !important;
60
+ }
61
+
62
+ // .mat-toolbar,
63
+ // .mat-toolbar.mat-primary,
64
+ // .mat-toolbar.mat-accent {
65
+ // background-color: var(--md-sys-color-secondary-container) !important;
66
+ // }
67
+ .elder-main-toolbar {
68
+ .mat-toolbar,
69
+ .mat-toolbar.mat-primary,
70
+ .mat-toolbar.mat-accent {
71
+ background-color: var(--elder-dark-gray) !important;
72
+ }
73
+ }
74
+ }
75
+ }
@@ -1,4 +1,4 @@
1
- @mixin elder-color-helpers() {
1
+ @mixin elder-color-utils() {
2
2
  $color-variables: (
3
3
  'background': var(--md-sys-color-background),
4
4
  'error': var(--md-sys-color-error),
@@ -52,13 +52,17 @@
52
52
  );
53
53
 
54
54
  // background colors
55
+ .elder-pane-bg-color {
56
+ background-color: var(--elder-pane-bg-color);
57
+ }
58
+
55
59
  @each $name, $value in $color-variables {
56
- .elder-bg-#{$name} {
60
+ .bg-#{$name} {
57
61
  background-color: #{$value};
58
62
  }
59
63
  }
60
64
 
61
- .elder-bg-transparent {
65
+ .bg-transparent {
62
66
  background-color: transparent;
63
67
  }
64
68
 
@@ -68,15 +72,4 @@
68
72
  color: #{$value};
69
73
  }
70
74
  }
71
-
72
- // border colors
73
- @each $name, $value in $color-variables {
74
- .elder-border-#{$name} {
75
- border-color: #{$value};
76
- }
77
- }
78
-
79
- .elder-pane-bg-color {
80
- background-color: var(--elder-pane-bg-color);
81
- }
82
75
  }