ngx-strata 0.5.0 → 0.5.1

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,79 +1,261 @@
1
1
  st-notification {
2
- --st-notification-background-color: var(--st-color-bg-raised);
3
- --st-notification-text-color: var(--st-color-text-primary);
2
+ --st-notification-bg: var(--st-color-bg-raised);
3
+ --st-notification-border-color: var(--st-color-border-subtle);
4
+ --st-notification-border-width: var(--st-border-width);
5
+ --st-notification-border-style: solid;
6
+ --st-notification-shadow: var(--st-shadow-3);
4
7
  --st-notification-border-radius: var(--st-border-radius-lg);
8
+ --st-notification-text-primary: var(--st-color-text-primary);
9
+ --st-notification-text-secondary: var(--st-color-text-secondary);
10
+ --st-notification-min-width: 320px;
11
+ --st-notification-max-width: var(--st-breakpoint-sm);
12
+ --st-notification-min-height: calc(var(--st-space-12) + var(--st-space-1));
13
+ --st-notification-padding-y: var(--st-space-3);
14
+ --st-notification-padding-right: var(--st-space-4);
15
+ --st-notification-accent-color: var(--st-color-feedback-info-default);
16
+ --st-notification-accent-width: var(--st-space-1);
17
+ --st-notification-accent-inset: var(--st-space-3);
18
+ --st-notification-accent-radius: var(--st-border-radius-full);
19
+ --st-notification-padding-left: calc(var(--st-notification-accent-inset) * 2 + var(--st-notification-accent-width));
20
+ --st-notification-gap: var(--st-space-3);
21
+ --st-notification-content-gap: var(--st-space-1);
22
+
23
+ --st-notification-icon-bg: var(--st-color-feedback-info-subtle);
24
+ --st-notification-icon-color: var(--st-color-feedback-info-default);
25
+ --st-notification-icon-size: var(--st-space-8);
26
+ --st-notification-icon-glyph-size: var(--st-space-4);
27
+ --st-notification-icon-radius: var(--st-border-radius-md);
28
+ --st-notification-icon-offset-y: var(--st-size-xxxxs);
29
+
30
+ --st-notification-title-font-size: var(--st-font-md);
31
+ --st-notification-title-font-weight: var(--st-font-weight-semibold);
32
+ --st-notification-title-line-height: 1.25;
33
+
34
+ --st-notification-message-font-size: var(--st-font-md);
35
+ --st-notification-message-line-height: 1.4;
36
+
37
+ --st-notification-actions-gap: var(--st-space-2);
38
+ --st-notification-actions-margin-top: var(--st-space-2);
39
+
40
+ --st-notification-close-size: var(--st-interactive-element-height-sm);
41
+ --st-notification-close-glyph-size: var(--st-font-md);
42
+ --st-notification-close-radius: var(--st-border-radius-sm);
43
+ --st-notification-close-color: var(--st-color-text-tertiary);
44
+ --st-notification-close-hover-color: var(--st-color-text-primary);
45
+ --st-notification-close-hover-bg: var(--st-color-control-bg-hover);
46
+
47
+ --st-notification-focus-ring-width: var(--st-focus-ring-width);
48
+ --st-notification-focus-ring-style: var(--st-focus-ring-style);
49
+ --st-notification-focus-ring-color: var(--st-color-border-strong);
50
+ --st-notification-focus-ring-offset: var(--st-focus-ring-offset);
51
+
52
+ --st-notification-progress-color: var(--st-color-feedback-info-default);
53
+ --st-notification-progress-height: 3px;
54
+
55
+ position: relative;
5
56
  display: flex;
6
57
  flex-direction: row;
7
- padding: var(--st-size-sm);
8
- min-width: 250px;
9
- min-height: var(--st-size-lg);
10
- box-shadow: var(--st-shadow-2);
11
- background-color: var(--st-notification-background-color);
12
- color: var(--st-notification-text-color);
13
- align-content: center;
14
58
  align-items: center;
15
- justify-content: flex-start;
59
+ padding: var(--st-notification-padding-y) var(--st-notification-padding-right) var(--st-notification-padding-y) var(--st-notification-padding-left);
60
+ min-width: var(--st-notification-min-width);
61
+ max-width: var(--st-notification-max-width);
62
+ min-height: var(--st-notification-min-height);
63
+ box-sizing: border-box;
64
+ background-color: var(--st-notification-bg);
65
+ border: var(--st-notification-border-width) var(--st-notification-border-style) var(--st-notification-border-color);
66
+ box-shadow: var(--st-notification-shadow);
16
67
  border-radius: var(--st-notification-border-radius);
17
- gap: 8px;
18
- font-size: 16px;
68
+ color: var(--st-notification-text-primary);
69
+ gap: var(--st-notification-gap);
70
+ overflow: hidden;
19
71
  pointer-events: auto;
20
72
 
21
- .notification-message {
73
+ &::before {
74
+ content: '';
75
+ position: absolute;
76
+ top: var(--st-notification-accent-inset);
77
+ bottom: var(--st-notification-accent-inset);
78
+ left: var(--st-notification-accent-inset);
79
+ width: var(--st-notification-accent-width);
80
+ border-radius: var(--st-notification-accent-radius);
81
+ background-color: var(--st-notification-accent-color);
82
+ }
83
+
84
+ .st-notification-icon-wrapper {
85
+ display: flex;
86
+ align-items: center;
87
+ justify-content: center;
88
+ flex-shrink: 0;
89
+ width: var(--st-notification-icon-size);
90
+ height: var(--st-notification-icon-size);
91
+ border-radius: var(--st-notification-icon-radius);
92
+ background-color: var(--st-notification-icon-bg);
93
+ color: var(--st-notification-icon-color);
94
+
95
+ st-icon {
96
+ --st-icon-size: var(--st-notification-icon-glyph-size);
97
+ }
98
+ }
99
+
100
+ .st-notification-content {
101
+ display: flex;
102
+ flex-direction: column;
22
103
  flex: 1;
104
+ min-width: 0;
105
+ gap: var(--st-notification-content-gap);
106
+
107
+ .st-notification-title {
108
+ font-size: var(--st-notification-title-font-size);
109
+ font-weight: var(--st-notification-title-font-weight);
110
+ color: var(--st-notification-text-primary);
111
+ line-height: var(--st-notification-title-line-height);
112
+ }
113
+
114
+ .st-notification-message {
115
+ font-size: var(--st-notification-message-font-size);
116
+ color: var(--st-notification-text-secondary);
117
+ line-height: var(--st-notification-message-line-height);
118
+ word-break: break-word;
119
+ }
120
+
121
+ .st-notification-actions {
122
+ display: flex;
123
+ flex-wrap: wrap;
124
+ gap: var(--st-notification-actions-gap);
125
+ margin-top: var(--st-notification-actions-margin-top);
126
+ }
23
127
  }
24
128
 
25
- .notification-close-btn {
129
+ .st-notification-close-btn {
26
130
  display: inline-flex;
27
131
  align-items: center;
28
132
  justify-content: center;
133
+ flex-shrink: 0;
134
+ width: var(--st-notification-close-size);
135
+ height: var(--st-notification-close-size);
136
+ margin-left: auto;
29
137
  background: none;
30
138
  border: none;
31
139
  padding: 0;
32
- margin-left: auto;
33
- color: inherit;
34
- opacity: 0.7;
140
+ color: var(--st-notification-close-color);
35
141
  cursor: pointer;
36
- border-radius: var(--st-border-radius-sm);
37
- transition: opacity var(--st-transition-fast), background-color var(--st-transition-fast);
142
+ border-radius: var(--st-notification-close-radius);
143
+ transition: color var(--st-transition-fast), background-color var(--st-transition-fast);
38
144
 
39
145
  &:hover {
40
- opacity: 1;
146
+ color: var(--st-notification-close-hover-color);
147
+ background-color: var(--st-notification-close-hover-bg);
41
148
  }
42
149
 
43
150
  &:focus-visible {
44
- outline: 2px solid currentColor;
45
- outline-offset: 2px;
151
+ outline: var(--st-notification-focus-ring-width) var(--st-notification-focus-ring-style) var(--st-notification-focus-ring-color);
152
+ outline-offset: var(--st-notification-focus-ring-offset);
153
+ }
154
+
155
+ st-icon {
156
+ --st-icon-size: var(--st-notification-close-glyph-size);
46
157
  }
47
158
  }
48
159
 
49
- &.st-theme-brand {
50
- --st-notification-background-color: var(--st-color-accent-subtle);
51
- --st-notification-text-color: var(--st-color-accent-text);
160
+ &:has(.st-notification-actions),
161
+ &:has(.st-notification-title) {
162
+ align-items: flex-start;
163
+
164
+ .st-notification-icon-wrapper {
165
+ margin-top: var(--st-notification-icon-offset-y);
166
+ }
167
+
168
+ .st-notification-close-btn {
169
+ margin-top: 0;
170
+ }
171
+ }
172
+
173
+ .st-notification-progress-bar {
174
+ position: absolute;
175
+ bottom: 0;
176
+ left: 0;
177
+ right: 0;
178
+ height: var(--st-notification-progress-height);
179
+ background-color: var(--st-notification-progress-color);
180
+ transform-origin: left;
181
+ animation: st-notification-progress-anim var(--st-notification-duration, 3000ms) linear forwards;
182
+ }
183
+
184
+ &.st-is-paused .st-notification-progress-bar {
185
+ animation-play-state: paused;
52
186
  }
53
187
 
54
188
  &.st-theme-info {
55
- --st-notification-background-color: var(--st-color-feedback-info-subtle);
56
- --st-notification-text-color: var(--st-color-feedback-info-text);
189
+ --st-notification-accent-color: var(--st-color-feedback-info-default);
190
+ --st-notification-icon-bg: var(--st-color-feedback-info-subtle);
191
+ --st-notification-icon-color: var(--st-color-feedback-info-default);
192
+ --st-notification-progress-color: var(--st-color-feedback-info-default);
57
193
  }
58
194
 
59
195
  &.st-theme-success {
60
- --st-notification-background-color: var(--st-color-feedback-success-subtle);
61
- --st-notification-text-color: var(--st-color-feedback-success-text);
196
+ --st-notification-accent-color: var(--st-color-feedback-success-default);
197
+ --st-notification-icon-bg: var(--st-color-feedback-success-subtle);
198
+ --st-notification-icon-color: var(--st-color-feedback-success-default);
199
+ --st-notification-progress-color: var(--st-color-feedback-success-default);
200
+ }
201
+
202
+ &.st-theme-warning {
203
+ --st-notification-accent-color: var(--st-color-feedback-warning-default);
204
+ --st-notification-icon-bg: var(--st-color-feedback-warning-subtle);
205
+ --st-notification-icon-color: var(--st-color-feedback-warning-default);
206
+ --st-notification-progress-color: var(--st-color-feedback-warning-default);
62
207
  }
63
208
 
64
209
  &.st-theme-danger {
65
- --st-notification-background-color: var(--st-color-feedback-error-subtle);
66
- --st-notification-text-color: var(--st-color-feedback-error-text);
210
+ --st-notification-accent-color: var(--st-color-feedback-error-default);
211
+ --st-notification-icon-bg: var(--st-color-feedback-error-subtle);
212
+ --st-notification-icon-color: var(--st-color-feedback-error-default);
213
+ --st-notification-progress-color: var(--st-color-feedback-error-default);
67
214
  }
68
215
 
69
- &.st-theme-warning {
70
- --st-notification-background-color: var(--st-color-feedback-warning-subtle);
71
- --st-notification-text-color: var(--st-color-feedback-warning-text);
216
+ &.st-theme-brand {
217
+ --st-notification-accent-color: var(--st-color-accent-default);
218
+ --st-notification-icon-bg: var(--st-color-accent-subtle);
219
+ --st-notification-icon-color: var(--st-color-accent-default);
220
+ --st-notification-progress-color: var(--st-color-accent-default);
72
221
  }
73
222
  }
74
223
 
224
+ @keyframes st-notification-progress-anim {
225
+ from {
226
+ transform: scaleX(1);
227
+ }
228
+ to {
229
+ transform: scaleX(0);
230
+ }
231
+ }
75
232
 
76
233
  st-notification-container {
234
+ --st-notification-container-gap: var(--st-space-2);
235
+ --st-notification-container-padding-mobile: var(--st-space-3);
236
+ --st-notification-container-padding-desktop: var(--st-space-4);
237
+ --st-notification-container-z-index: 1100;
238
+
239
+ --st-notification-overflow-bg: var(--st-color-bg-raised);
240
+ --st-notification-overflow-border-color: var(--st-color-border-subtle);
241
+ --st-notification-overflow-border-width: var(--st-border-width);
242
+ --st-notification-overflow-border-style: solid;
243
+ --st-notification-overflow-shadow: var(--st-shadow-2);
244
+ --st-notification-overflow-text-color: var(--st-color-text-secondary);
245
+ --st-notification-overflow-font-size: var(--st-font-sm);
246
+ --st-notification-overflow-font-weight: var(--st-font-weight-medium);
247
+ --st-notification-overflow-line-height: 1.4;
248
+ --st-notification-overflow-padding-y: var(--st-space-1);
249
+ --st-notification-overflow-padding-x: var(--st-space-3);
250
+ --st-notification-overflow-gap: var(--st-space-2);
251
+ --st-notification-overflow-radius: var(--st-border-radius-full);
252
+ --st-notification-overflow-clear-size: calc(var(--st-space-4) + var(--st-size-xxxxs));
253
+ --st-notification-overflow-clear-glyph-size: var(--st-font-sm);
254
+ --st-notification-overflow-clear-radius: var(--st-border-radius-full);
255
+ --st-notification-overflow-clear-color: var(--st-color-text-tertiary);
256
+ --st-notification-overflow-clear-hover-color: var(--st-color-text-primary);
257
+ --st-notification-overflow-clear-hover-bg: var(--st-color-control-bg-hover);
258
+
77
259
  width: 100%;
78
260
  height: 100%;
79
261
  position: fixed;
@@ -81,21 +263,66 @@ st-notification-container {
81
263
  left: 0;
82
264
  overflow: hidden;
83
265
  display: flex;
84
- z-index: 1100;
266
+ z-index: var(--st-notification-container-z-index);
85
267
  pointer-events: none;
86
- gap: var(--st-size-xs);
87
-
88
- // Small screen defaults: top center, full width
268
+ gap: var(--st-notification-container-gap);
89
269
  flex-direction: column;
90
270
  align-items: stretch;
91
271
  justify-content: flex-start;
92
- padding: var(--st-size-sm);
272
+ padding: var(--st-notification-container-padding-mobile);
93
273
 
94
- // Big screen overrides: bottom right, stacking upwards
95
274
  @media (min-width: 768px) {
96
275
  flex-direction: column-reverse;
97
276
  align-items: flex-end;
98
277
  justify-content: flex-start;
99
- padding: var(--st-size-md);
278
+ padding: var(--st-notification-container-padding-desktop);
279
+ }
280
+
281
+ .st-notification-overflow {
282
+ display: inline-flex;
283
+ align-items: center;
284
+ align-self: center;
285
+ gap: var(--st-notification-overflow-gap);
286
+ padding: var(--st-notification-overflow-padding-y) var(--st-notification-overflow-padding-x);
287
+ background-color: var(--st-notification-overflow-bg);
288
+ border: var(--st-notification-overflow-border-width) var(--st-notification-overflow-border-style) var(--st-notification-overflow-border-color);
289
+ border-radius: var(--st-notification-overflow-radius);
290
+ box-shadow: var(--st-notification-overflow-shadow);
291
+ color: var(--st-notification-overflow-text-color);
292
+ font-size: var(--st-notification-overflow-font-size);
293
+ font-weight: var(--st-notification-overflow-font-weight);
294
+ pointer-events: auto;
295
+
296
+ @media (min-width: 768px) {
297
+ align-self: flex-end;
298
+ }
299
+
300
+ .st-notification-overflow-text {
301
+ line-height: var(--st-notification-overflow-line-height);
302
+ }
303
+
304
+ .st-notification-overflow-clear {
305
+ display: inline-flex;
306
+ align-items: center;
307
+ justify-content: center;
308
+ width: var(--st-notification-overflow-clear-size);
309
+ height: var(--st-notification-overflow-clear-size);
310
+ padding: 0;
311
+ border: none;
312
+ background: transparent;
313
+ border-radius: var(--st-notification-overflow-clear-radius);
314
+ color: var(--st-notification-overflow-clear-color);
315
+ cursor: pointer;
316
+ transition: color var(--st-transition-fast), background-color var(--st-transition-fast);
317
+
318
+ &:hover {
319
+ color: var(--st-notification-overflow-clear-hover-color);
320
+ background-color: var(--st-notification-overflow-clear-hover-bg);
321
+ }
322
+
323
+ st-icon {
324
+ --st-icon-size: var(--st-notification-overflow-clear-glyph-size);
325
+ }
326
+ }
100
327
  }
101
328
  }
@@ -129,6 +129,7 @@ st-segmented-control {
129
129
  display: flex;
130
130
  align-items: center;
131
131
  justify-content: center;
132
+ gap: var(--st-space-2, 8px);
132
133
  height: var(--st-segmented-control-item-height);
133
134
  padding: 0 var(--st-segmented-control-padding-x);
134
135
  border-radius: calc(var(--st-segmented-control-border-radius) - 2px);
@@ -138,11 +139,30 @@ st-segmented-control {
138
139
  transition: background-color var(--st-transition-fast), color var(--st-transition-fast);
139
140
  }
140
141
 
142
+ st-segmented-control-item {
143
+ position: relative;
144
+ z-index: 1;
145
+
146
+ &[aria-selected="true"] {
147
+ color: var(--st-color-control-primary-text);
148
+
149
+ &:hover {
150
+ background-color: transparent;
151
+ }
152
+ }
153
+
154
+ st-badge {
155
+ flex-shrink: 0;
156
+ }
157
+ }
158
+
141
159
  #selection-indicator {
142
160
  cursor: default;
143
161
  position: absolute;
144
162
  top: 0;
145
163
  left: 0;
164
+ z-index: 0;
165
+ pointer-events: none;
146
166
  border-radius: calc(var(--st-segmented-control-border-radius) - 2px);
147
167
  background-color: var(--st-color-control-primary-bg);
148
168
  color: var(--st-color-control-primary-text);
@@ -52,8 +52,15 @@ st-sidemenu {
52
52
  opacity: 0.5;
53
53
  }
54
54
 
55
- st-tag {
55
+ st-tag,
56
+ st-badge {
56
57
  margin-left: auto;
58
+ flex-shrink: 0;
59
+ }
60
+
61
+ st-tag + .st-sidemenu-item-secondary-action,
62
+ st-badge + .st-sidemenu-item-secondary-action {
63
+ margin-left: var(--st-space-2, 8px);
57
64
  }
58
65
 
59
66
  st-icon:not(.st-sidemenu-item-group-icon) {
@@ -13,6 +13,9 @@ st-tabs {
13
13
  }
14
14
 
15
15
  st-tab-item {
16
+ display: inline-flex;
17
+ align-items: center;
18
+ gap: var(--st-space-2, 8px);
16
19
  padding: 12px 16px;
17
20
  font-size: 14px;
18
21
  font-weight: 500;
@@ -25,6 +28,10 @@ st-tabs {
25
28
  margin-bottom: -1px;
26
29
  outline: none;
27
30
 
31
+ st-badge {
32
+ flex-shrink: 0;
33
+ }
34
+
28
35
  &:focus,
29
36
  &:active {
30
37
  outline: none;
@@ -27,6 +27,7 @@
27
27
  @use "./components/item";
28
28
  @use "./components/modal";
29
29
  @use "./components/number-display";
30
+ @use "./components/number-stepper";
30
31
  @use "./components/notification";
31
32
  @use "./components/overlay";
32
33
  @use "./components/pagination";
@@ -34,6 +35,7 @@
34
35
  @use "./components/radio";
35
36
  @use "./components/segmented-control";
36
37
  @use "./components/select";
38
+ @use "./components/skeleton";
37
39
  @use "./components/slider";
38
40
  @use "./components/spinner";
39
41
  @use "./components/table";
@@ -76,6 +76,10 @@
76
76
  --st-color-control-primary-bg: var(--st-color-neutral-900);
77
77
  --st-color-control-primary-bg-hover: var(--st-color-neutral-800);
78
78
  --st-color-control-primary-text: var(--st-color-neutral-0);
79
+
80
+ /* --- Skeleton Placeholder --- */
81
+ --st-color-skeleton-bg: var(--st-color-neutral-200);
82
+ --st-color-skeleton-shimmer: var(--st-color-neutral-50);
79
83
  }
80
84
 
81
85
 
@@ -156,4 +160,8 @@
156
160
  --st-color-control-primary-bg: var(--st-color-neutral-50);
157
161
  --st-color-control-primary-bg-hover: var(--st-color-neutral-200);
158
162
  --st-color-control-primary-text: var(--st-color-neutral-900);
163
+
164
+ /* --- Skeleton Placeholder --- */
165
+ --st-color-skeleton-bg: var(--st-color-neutral-700);
166
+ --st-color-skeleton-shimmer: var(--st-color-neutral-600);
159
167
  }