@elderbyte/ngx-starter 19.1.1 → 19.1.3

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.
@@ -1,4 +1,4 @@
1
1
  /**
2
- * Defined in _elder-defaults.scss
2
+ * Defined in _elder-scss-variables.scss
3
3
  */
4
4
  export type ElderSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elderbyte/ngx-starter",
3
- "version": "19.1.1",
3
+ "version": "19.1.3",
4
4
  "peerDependencies": {
5
5
  "@angular/core": "^18.0.0 || ^19.0.0",
6
6
  "@angular/common": "^18.0.0 || ^19.0.0",
@@ -1,11 +1,15 @@
1
1
  @use 'sass:map';
2
+ @use '@angular/material' as mat;
2
3
  @use './elder-scss-variables' as config;
3
4
 
4
5
  @mixin elder-design-tokens() {
5
6
  @include elder-badge-sizing();
6
7
 
7
- & {
8
- --md-sys-color-background: var(--md-sys-color-surface-container-highest);
8
+ @include m3-color-tokens();
9
+
10
+ &.elder-light-theme,
11
+ &.elder-dark-theme {
12
+ --md-sys-color-background: var(--md-sys-color-surface-container);
9
13
  --mat-app-background-color: var(--md-sys-color-background);
10
14
 
11
15
  // mat variables
@@ -21,6 +25,7 @@
21
25
  --mat-sidenav-container-background-color: var(--mat-app-background-color);
22
26
  --mdc-dialog-container-color: var(--md-sys-color-surface-container-lowest);
23
27
  --mat-tab-header-divider-height: 0; // remove tab header divider
28
+ --mat-menu-container-color: var(--md-sys-color-surface-container-lowest);
24
29
 
25
30
  // import fix for overflow of mat-icons, default is 40px in m3, in m2 it was 48px
26
31
  --mdc-icon-button-state-layer-size: 48px;
@@ -32,13 +37,13 @@
32
37
  --mat-dialog-container-elevation-shadow: 0 0 34px 0 rgba(0, 0, 0, 0.6);
33
38
  }
34
39
 
35
- // elder custom variables
40
+ // // elder custom variables
36
41
  --elder-border-radius-sm: 4px; // typical small border radius, inspired by mat 2
37
42
  --elder-border-light: 1px solid var(--md-sys-color-outline-variant);
38
43
  --elder-box-shadow-default: var(--mat-app-elevation-shadow-level-8);
39
44
  --elder-scrollbar-width: 8px;
40
45
  --elder-lightened-transparent-bg: rgba(255, 255, 255, 0.15);
41
- --elder-main-nav-bg: var(--md-sys-color-surface);
46
+ --elder-main-nav-bg: var(--md-sys-color-surface-container-lowest);
42
47
  --elder-nav-item-height: 54px;
43
48
  --elder-button-horizontal-padding: 19px;
44
49
 
@@ -51,7 +56,7 @@
51
56
  --elder-nav-link-hover-color: var(--elder-backdrop-highlight-color);
52
57
  --elder-nav-link-active-color: var(--elder-backdrop-highlight-color);
53
58
 
54
- // elder pane
59
+ // // elder pane
55
60
  --elder-pane-padding: #{map.get(config.$sizes, sm)};
56
61
  --elder-pane-gap: #{map.get(config.$sizes, sm)};
57
62
  --elder-pane-border-radius: var(--mdc-outlined-card-container-shape, 12px);
@@ -86,6 +91,9 @@
86
91
  --elder-gold-light: #{map.get(config.$custom-colors, elder-gold-light)};
87
92
  --elder-gray-medium: #{map.get(config.$custom-colors, elder-gray-medium)};
88
93
 
94
+ --elder-blue: var(--md-sys-color-primary);
95
+ --md-sys-color-tertiary: var(--elder-gold);
96
+
89
97
  --elder-color-highlight-strong: hsl(214, 18%, 85%);
90
98
  --elder-color-highlight-strong: var(--elder-gold-light);
91
99
  --elder-color-highlight-light: #ebebeb;
@@ -113,6 +121,18 @@
113
121
  --mat-toolbar-title-text-line-height: 36px;
114
122
  }
115
123
 
124
+ // light theme overwrites
125
+ &.elder-light-theme {
126
+ //--md-sys-color-primary: var(--elder-blue);
127
+ --md-sys-color-tertiary: var(--elder-gold);
128
+ --md-sys-color-tertiary-container: var(--elder-gold-light);
129
+ --md-sys-color-on-tertiary: var(--md-sys-color-on-surface);
130
+ --md-sys-color-secondary-container: hsl(214, 44%, 84%);
131
+ --md-sys-color-secondary-fixed: hsl(214, 44%, 89%);
132
+ //--md-sys-color-primary-container: #a6c7ed;
133
+ //--md-sys-color-primary: #0b284f;
134
+ }
135
+
116
136
  // chip colors light
117
137
  &.elder-light-theme {
118
138
  --elder-chip-color-state-none: #{map.get(config.$chip-colors, state-none)};
@@ -142,32 +162,25 @@
142
162
 
143
163
  &.elder-dark-theme {
144
164
  // dark theme blue
145
- --md-sys-color-primary: hsl(222, 45%, 74%);
146
- }
147
-
148
- // light theme overwrites
149
- &.elder-light-theme {
150
- --md-sys-color-primary: var(--elder-blue);
151
- --md-sys-color-tertiary: var(--elder-gold);
152
- --md-sys-color-tertiary-container: var(--elder-gold-light);
153
- --md-sys-color-on-tertiary: var(--md-sys-color-on-surface);
154
- --md-sys-color-secondary-container: hsl(214, 44%, 84%);
155
- --md-sys-color-secondary-fixed: hsl(214, 44%, 89%);
156
- --md-sys-color-primary-container: #a6c7ed;
165
+ --md-sys-color-primary: hsl(222, 45%, 74%); // dim primary color
157
166
  }
158
167
 
159
168
  // dark theme overwrites
160
169
  &.elder-dark-theme {
170
+ --md-sys-color-background: var(--md-sys-color-surface-container-highest);
161
171
  --elder-round-form-field-outline: solid 1px var(--md-sys-color-outline);
162
172
  --mat-sidenav-scrim-color: rgba(255, 255, 255, 0.4);
163
173
  --elder-color-highlight-light: var(--elder-gray-medium);
164
174
  --elder-color-highlight-strong: var(--elder-gold-semi-dark);
165
175
  --elder-color-highlight-variant: var(--elder-gold-dark);
166
176
  --md-sys-color-tertiary-container: var(--elder-gold-semi-dark);
167
- --md-sys-color-surface-container-highest: #191919;
168
- --md-sys-color-surface-container-lowest: #232324;
177
+ --md-sys-color-surface-container-highest: #181818;
169
178
  --md-sys-color-surface-container: #1e1f20;
170
179
  --md-sys-color-surface-container-low: #1b1c1e;
180
+ --md-sys-color-surface-container-lowest: #232324;
181
+
182
+ // --md-sys-color-surface-container: #1e1f20;
183
+ // --md-sys-color-surface-container-low: #1b1c1e;
171
184
  --md-sys-color-error: #ff897d;
172
185
  --md-sys-color-inverse-primary: var(--md-sys-color-primary-container);
173
186
  --md-sys-color-surface-tint: var(--elder-gold-dark);
@@ -211,3 +224,132 @@
211
224
  --mat-badge-large-size-line-height: var(--mat-badge-legacy-large-size-container-size);
212
225
  }
213
226
  }
227
+
228
+ @mixin m3-color-tokens() {
229
+ &.elder-light-theme,
230
+ &.elder-dark-theme {
231
+ @include mat.theme-overrides(
232
+ (
233
+ primary: #475f89,
234
+ on-primary: #ffffff,
235
+ primary-container: #d7e3ff,
236
+ on-primary-container: #001b3e,
237
+ inverse-primary: #afc7f7,
238
+ primary-fixed: #d7e3ff,
239
+ primary-fixed-dim: #afc7f7,
240
+ on-primary-fixed: #001b3e,
241
+ on-primary-fixed-variant: #2f476f,
242
+ secondary: #565e71,
243
+ on-secondary: #ffffff,
244
+ secondary-container: #dae2f9,
245
+ on-secondary-container: #131b2c,
246
+ secondary-fixed: #dae2f9,
247
+ secondary-fixed-dim: #bec6dc,
248
+ on-secondary-fixed: #131b2c,
249
+ on-secondary-fixed-variant: #3f4759,
250
+ tertiary: #6f5c2e,
251
+ on-tertiary: #ffffff,
252
+ tertiary-container: #fae0a5,
253
+ on-tertiary-container: #251a00,
254
+ tertiary-fixed: #fae0a5,
255
+ tertiary-fixed-dim: #ddc48c,
256
+ on-tertiary-fixed: #251a00,
257
+ on-tertiary-fixed-variant: #564518,
258
+ background: #fcf8f8,
259
+ on-background: #1c1b1c,
260
+ surface: #fcf8f8,
261
+ surface-dim: #ddd9d9,
262
+ surface-bright: #fcf8f8,
263
+ surface-container-lowest: #ffffff,
264
+ surface-container-low: #f7f3f2,
265
+ surface-container: #f1eded,
266
+ surface-container-high: #ebe7e7,
267
+ surface-container-highest: #e5e2e1,
268
+ on-surface: #1c1b1c,
269
+ shadow: #000000,
270
+ scrim: #000000,
271
+ surface-tint: #5e5e62,
272
+ inverse-surface: #313030,
273
+ inverse-on-surface: #f4f0f0,
274
+ outline: #76777b,
275
+ outline-variant: #c6c6cb,
276
+ neutral: #787676,
277
+ neutral10: #1c1b1c,
278
+ error: #ba1a1a,
279
+ error-container: #ffdad6,
280
+ on-error: #ffffff,
281
+ on-error-container: #410002,
282
+ surface-variant: #e2e2e7,
283
+ on-surface-variant: #45474b,
284
+ neutral-variant: #76777c,
285
+ neutral-variant20: #2f3034,
286
+ inverse-secondary: #bec6dc,
287
+ inverse-tertiary: #ddc48c,
288
+ ),
289
+ 'md-sys-color'
290
+ );
291
+ }
292
+
293
+ &.elder-dark-theme {
294
+ @include mat.theme-overrides(
295
+ (
296
+ primary: #afc7f7,
297
+ on-primary: #163057,
298
+ primary-container: #2f476f,
299
+ on-primary-container: #d7e3ff,
300
+ inverse-primary: #475f89,
301
+ primary-fixed: #d7e3ff,
302
+ primary-fixed-dim: #afc7f7,
303
+ on-primary-fixed: #001b3e,
304
+ on-primary-fixed-variant: #2f476f,
305
+ secondary: #bec6dc,
306
+ on-secondary: #283042,
307
+ secondary-container: #3f4759,
308
+ on-secondary-container: #dae2f9,
309
+ secondary-fixed: #dae2f9,
310
+ secondary-fixed-dim: #bec6dc,
311
+ on-secondary-fixed: #131b2c,
312
+ on-secondary-fixed-variant: #3f4759,
313
+ tertiary: #ddc48c,
314
+ on-tertiary: #3d2e04,
315
+ tertiary-container: #564518,
316
+ on-tertiary-container: #fae0a5,
317
+ tertiary-fixed: #fae0a5,
318
+ tertiary-fixed-dim: #ddc48c,
319
+ on-tertiary-fixed: #251a00,
320
+ on-tertiary-fixed-variant: #564518,
321
+ background: #141313,
322
+ on-background: #e5e2e1,
323
+ surface: #141313,
324
+ surface-dim: #141313,
325
+ surface-bright: #3a3939,
326
+ surface-container-lowest: #0e0e0e,
327
+ surface-container-low: #1c1b1c,
328
+ surface-container: #201f20,
329
+ surface-container-high: #2a2a2a,
330
+ surface-container-highest: #353435,
331
+ on-surface: #e5e2e1,
332
+ shadow: #000000,
333
+ scrim: #000000,
334
+ surface-tint: #c7c6ca,
335
+ inverse-surface: #e5e2e1,
336
+ inverse-on-surface: #313030,
337
+ outline: #909095,
338
+ outline-variant: #45474b,
339
+ neutral: #787676,
340
+ neutral10: #1c1b1c,
341
+ error: #ffb4ab,
342
+ error-container: #93000a,
343
+ on-error: #690005,
344
+ on-error-container: #ffdad6,
345
+ surface-variant: #45474b,
346
+ on-surface-variant: #c6c6cb,
347
+ neutral-variant: #76777c,
348
+ neutral-variant20: #2f3034,
349
+ inverse-secondary: #565e71,
350
+ inverse-tertiary: #6f5c2e,
351
+ ),
352
+ 'md-sys-color'
353
+ );
354
+ }
355
+ }
@@ -16,6 +16,8 @@
16
16
  @use '../components/elder-select-theme' as elder-select;
17
17
  @use '../components/elder-toolbar-theme' as elder-toolbar;
18
18
  @use '../components/elder-table-theme' as elder-table;
19
+ @use '../components/elder-scrollbar-theme' as elder-scrollbar;
20
+
19
21
 
20
22
  // Create a theme.
21
23
  @mixin starter-theme($theme) {
@@ -46,4 +48,5 @@
46
48
  @include elder-select.theme($theme);
47
49
  @include elder-toolbar.theme($theme);
48
50
  @include elder-table.theme($theme);
51
+ @include elder-scrollbar.theme();
49
52
  }
@@ -33,14 +33,14 @@
33
33
  .elder-light-theme,
34
34
  .elder-dark-theme {
35
35
  @include mat.all-component-themes($elder-light-theme);
36
- @include mat.system-level-colors($elder-light-theme);
36
+ //@include mat.system-level-colors($elder-light-theme);
37
37
  @include mat.system-level-typography($elder-light-theme);
38
38
  @include mat.color-variants-backwards-compatibility($elder-light-theme);
39
39
  }
40
40
 
41
41
  .elder-dark-theme {
42
42
  @include mat.all-component-colors($elder-dark-theme);
43
- @include mat.system-level-colors($elder-dark-theme);
43
+ //@include mat.system-level-colors($elder-dark-theme);
44
44
  @include mat.color-variants-backwards-compatibility($elder-dark-theme);
45
45
  }
46
46
 
@@ -2,20 +2,7 @@
2
2
  @use './elder-base-mixins' as mixins;
3
3
  @use 'sass:map';
4
4
 
5
- @mixin elder-fixes-base($theme) {// scrollbar styling
6
- ::-webkit-scrollbar {
7
- width: var(--elder-scrollbar-width);
8
- }
9
-
10
- ::-webkit-scrollbar-thumb {
11
- background: var(--md-sys-color-outline-variant);
12
- border-radius: 5px;
13
- }
14
-
15
- ::-webkit-scrollbar-thumb:hover {
16
- background: var(--md-sys-color-outline);
17
- }
18
-
5
+ @mixin elder-fixes-base($theme) {
19
6
  .mat-app-background {
20
7
  display: block;
21
8
  }
@@ -118,6 +105,7 @@
118
105
  .elder-card-title {
119
106
  padding-bottom: 0 !important;
120
107
  margin-bottom: 6px !important;
108
+ //font-weight: 500;
121
109
  }
122
110
 
123
111
  /**************************************************************************
@@ -168,7 +156,8 @@
168
156
  }
169
157
 
170
158
  &.elder-light-theme .mdc-linear-progress__buffer-bar {
171
- --mdc-linear-progress-track-color: #f3f3f3;
159
+ --mdc-linear-progress-track-color: #f8f8f8;
160
+ --mdc-linear-progress-track-color: var(--md-sys-color-secondary-fixed-dim);
172
161
  }
173
162
 
174
163
  &.elder-light-theme elder-data-transfer-aggregate .mdc-linear-progress__buffer-bar {
@@ -197,4 +186,8 @@
197
186
  // --mdc-switch-selected-hover-handle-color: color-mix(in hsl, var(--md-sys-color-tertiary), black 16%);
198
187
  }
199
188
  }
189
+
190
+ &.elder-light-theme .main-nav-logo{
191
+ filter: brightness(1.09) saturate(1.07);
192
+ }
200
193
  }
@@ -0,0 +1,45 @@
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() {
7
+ // scrollbar styling
8
+ ::-webkit-scrollbar {
9
+ width: var(--elder-scrollbar-width);
10
+ }
11
+
12
+ ::-webkit-scrollbar-thumb {
13
+ background: var(--md-sys-color-outline-variant);
14
+ border-radius: 5px;
15
+ }
16
+
17
+ ::-webkit-scrollbar-thumb:hover {
18
+ background: var(--md-sys-color-outline);
19
+ }
20
+
21
+ .scrollbar-xs {
22
+ @include scrollbar-width(map.get(config.$sizes, xs));
23
+ }
24
+ .scrollbar-sm {
25
+ @include scrollbar-width(map.get(config.$sizes, sm));
26
+ }
27
+ .scrollbar-md {
28
+ @include scrollbar-width(map.get(config.$sizes, md));
29
+ }
30
+ .scrollbar-lg {
31
+ @include scrollbar-width(map.get(config.$sizes, lg));
32
+ }
33
+ .scrollbar-xl {
34
+ @include scrollbar-width(map.get(config.$sizes, xl));
35
+ }
36
+ .scrollbar-xxl {
37
+ @include scrollbar-width(map.get(config.$sizes, xxl));
38
+ }
39
+ }
40
+
41
+ @mixin scrollbar-width($width) {
42
+ &::-webkit-scrollbar {
43
+ width: $width;
44
+ }
45
+ }
@@ -74,6 +74,19 @@
74
74
  background-color: var(--elder-pane-bg-color);
75
75
  }
76
76
 
77
+ .bg-highlight-light {
78
+ background-color: var(--elder-color-highlight-light);
79
+ }
80
+
81
+ .bg-highlight-strong {
82
+ background-color: var(--elder-color-highlight-strong);
83
+ }
84
+
85
+ .bg-highlight-variant {
86
+ background-color: var(--elder-color-highlight-variant);
87
+ }
88
+
89
+
77
90
  // text colors
78
91
  @each $name, $value in $color-variables {
79
92
  .elder-text-#{$name} {
@@ -2,21 +2,31 @@
2
2
  .border-none {
3
3
  border: none;
4
4
  }
5
+
6
+ .bold {
7
+ font-weight: bold;
8
+ }
9
+
5
10
  .border-radius-0 {
6
11
  border-radius: 0;
7
12
  }
13
+
8
14
  .display-none {
9
15
  display: none;
10
16
  }
17
+
11
18
  .text-center {
12
19
  text-align: center;
13
20
  }
21
+
14
22
  .overflow-hidden {
15
23
  overflow: hidden;
16
24
  }
25
+
17
26
  .overflow-auto {
18
27
  overflow: auto;
19
28
  }
29
+
20
30
  .full-width {
21
31
  width: 100%; // legacy, keep for now
22
32
  }