minora 0.1.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.
@@ -0,0 +1,659 @@
1
+ /* ============================================================
2
+ ELEGANT MINIMALIST UI KIT — Alert Banner, Inline Message
3
+ & Page Banner Components
4
+ alert.css
5
+
6
+ ANATOMY — ALERT BANNER
7
+ ─────────────────────────────────────────────────────────────
8
+ Structure:
9
+ <div class="alert alert-subtle alert-success">
10
+ <svg class="alert-icon">…</svg>
11
+ <div class="alert-body">
12
+ <strong class="alert-title">Success!</strong>
13
+ <p class="alert-desc">Your changes have been saved.</p>
14
+ <!-- optional: list of items -->
15
+ <ul class="alert-list">
16
+ <li>Item one</li>
17
+ </ul>
18
+ <!-- optional: action link/button -->
19
+ <a class="alert-action" href="#">View details</a>
20
+ </div>
21
+ <button class="alert-close" aria-label="Dismiss">
22
+ <svg>×</svg>
23
+ </button>
24
+ </div>
25
+
26
+ Class layers:
27
+ 1. .alert → Base layout
28
+ 2. .alert-{variant} → Style (subtle/filled/outline)
29
+ 3. .alert-{type} → Color (success/error/warning/info/neutral)
30
+ 4. .alert-compact → Smaller padding
31
+ 5. .alert-icon → Type-appropriate SVG icon
32
+ 6. .alert-body → Title + desc + optional list/action
33
+ 7. .alert-close → Dismiss button
34
+ 8. .alert-action → CTA link/button
35
+ ─────────────────────────────────────────────────────────────
36
+
37
+ ANATOMY — INLINE MESSAGE
38
+ ─────────────────────────────────────────────────────────────
39
+ Structure:
40
+ <div class="inline-message inline-message-success">
41
+ <svg class="inline-message-icon">…</svg>
42
+ <span class="inline-message-text">Saved.</span>
43
+ </div>
44
+ ─────────────────────────────────────────────────────────────
45
+
46
+ ANATOMY — PAGE BANNER
47
+ ─────────────────────────────────────────────────────────────
48
+ Structure:
49
+ <div class="page-banner">
50
+ <span class="page-banner-text">Maintenance notice…</span>
51
+ <a class="page-banner-action" href="#">Learn more</a>
52
+ <button class="page-banner-close" aria-label="Dismiss">
53
+ <svg>×</svg>
54
+ </button>
55
+ </div>
56
+ ─────────────────────────────────────────────────────────────
57
+ ============================================================ */
58
+
59
+ /* ═══════════════════════════════════════════════════════════
60
+ ICON SVGs — Shared for alert types
61
+ ═══════════════════════════════════════════════════════════ */
62
+
63
+ .alert-icon-svg {
64
+ width: var(--alert-icon-size);
65
+ height: var(--alert-icon-size);
66
+ flex-shrink: 0;
67
+ margin-top: var(--space-0-5);
68
+ }
69
+
70
+ /* ═══════════════════════════════════════════════════════════
71
+ ALERT — Base
72
+ ═══════════════════════════════════════════════════════════ */
73
+
74
+ .alert {
75
+ display: flex;
76
+ align-items: flex-start;
77
+ gap: var(--space-3);
78
+ padding: var(--alert-padding);
79
+ border-radius: var(--alert-radius);
80
+ font-size: var(--alert-font-size);
81
+ line-height: var(--leading-relaxed);
82
+ position: relative;
83
+ overflow: hidden;
84
+ max-height: var(--alert-max-h);
85
+ opacity: 1;
86
+ transition: max-height var(--alert-slide-duration) var(--ease-out),
87
+ opacity var(--alert-slide-duration) var(--ease-in-out),
88
+ margin-bottom var(--alert-slide-duration) var(--ease-out),
89
+ padding-top var(--alert-slide-duration) var(--ease-out),
90
+ padding-bottom var(--alert-slide-duration) var(--ease-out);
91
+ }
92
+
93
+ /* Dismiss animation: slide up + fade out + collapse */
94
+ .alert.is-dismissing {
95
+ max-height: 0;
96
+ opacity: 0;
97
+ margin-bottom: 0;
98
+ padding-top: 0;
99
+ padding-bottom: 0;
100
+ pointer-events: none;
101
+ }
102
+
103
+ /* Entrance animation */
104
+ .alert.is-entering {
105
+ animation: alert-slide-in var(--alert-slide-duration) var(--ease-out) forwards;
106
+ }
107
+
108
+ @keyframes alert-slide-in {
109
+ from {
110
+ max-height: 0;
111
+ opacity: 0;
112
+ margin-bottom: 0;
113
+ padding-top: 0;
114
+ padding-bottom: 0;
115
+ }
116
+ to {
117
+ max-height: var(--alert-max-h);
118
+ opacity: 1;
119
+ }
120
+ }
121
+
122
+ /* ═══════════════════════════════════════════════════════════
123
+ ALERT — Body
124
+ ═══════════════════════════════════════════════════════════ */
125
+
126
+ .alert-body {
127
+ flex: 1;
128
+ min-width: 0;
129
+ }
130
+
131
+ .alert-title {
132
+ display: block;
133
+ font-family: var(--font-sans);
134
+ font-size: var(--text-sm);
135
+ font-weight: var(--font-semibold);
136
+ margin-bottom: var(--space-0-5);
137
+ }
138
+
139
+ .alert-desc {
140
+ font-size: var(--text-sm);
141
+ line-height: var(--leading-relaxed);
142
+ margin: 0;
143
+ }
144
+
145
+ .alert-desc + .alert-list {
146
+ margin-top: var(--space-2);
147
+ }
148
+
149
+ /* ═══════════════════════════════════════════════════════════
150
+ ALERT — List of items
151
+ ═══════════════════════════════════════════════════════════ */
152
+
153
+ .alert-list {
154
+ margin: var(--space-2) 0 0 0;
155
+ padding-left: var(--space-4);
156
+ font-size: var(--text-sm);
157
+ line-height: var(--leading-relaxed);
158
+ }
159
+
160
+ .alert-list li {
161
+ margin-bottom: var(--space-0-5);
162
+ }
163
+
164
+ .alert-list li:last-child {
165
+ margin-bottom: 0;
166
+ }
167
+
168
+ /* ═══════════════════════════════════════════════════════════
169
+ ALERT — Action link/button
170
+ ═══════════════════════════════════════════════════════════ */
171
+
172
+ .alert-action {
173
+ display: inline-flex;
174
+ align-items: center;
175
+ font-family: var(--font-sans);
176
+ font-size: var(--text-sm);
177
+ font-weight: var(--font-semibold);
178
+ text-decoration: underline;
179
+ text-underline-offset: var(--space-0-5);
180
+ cursor: pointer;
181
+ margin-top: var(--space-2);
182
+ background: transparent;
183
+ border: none;
184
+ padding: 0;
185
+ }
186
+
187
+ .alert-action:hover {
188
+ text-decoration-thickness: var(--alert-hover-underline);
189
+ }
190
+
191
+ .alert-desc + .alert-action {
192
+ margin-top: var(--space-1);
193
+ }
194
+
195
+ /* ═══════════════════════════════════════════════════════════
196
+ ALERT — Close/dismiss button
197
+ ═══════════════════════════════════════════════════════════ */
198
+
199
+ .alert-close {
200
+ display: inline-flex;
201
+ align-items: center;
202
+ justify-content: center;
203
+ width: var(--space-6);
204
+ height: var(--space-6);
205
+ flex-shrink: 0;
206
+ border: none;
207
+ border-radius: var(--radius-sm);
208
+ background: transparent;
209
+ cursor: pointer;
210
+ padding: 0;
211
+ transition: background-color var(--duration-fast) var(--ease-in-out),
212
+ color var(--duration-fast) var(--ease-in-out);
213
+ }
214
+
215
+ .alert-close svg {
216
+ width: var(--space-3-5);
217
+ height: var(--space-3-5);
218
+ }
219
+
220
+ /* ═══════════════════════════════════════════════════════════
221
+ ALERT — Variant: Subtle
222
+ Light background + thick left accent border
223
+ ═══════════════════════════════════════════════════════════ */
224
+
225
+ .alert-subtle {
226
+ border: var(--border-width) solid transparent;
227
+ border-left: var(--alert-border-accent) solid;
228
+ }
229
+
230
+ /* Subtle type colors */
231
+ .alert-subtle.alert-success {
232
+ background-color: var(--alert-subtle-success-bg);
233
+ border-left-color: var(--alert-subtle-success-accent);
234
+ }
235
+
236
+ .alert-subtle.alert-success .alert-icon-svg {
237
+ color: var(--alert-subtle-success-accent);
238
+ }
239
+
240
+ .alert-subtle.alert-success .alert-action {
241
+ color: var(--alert-subtle-success-accent);
242
+ }
243
+
244
+ .alert-subtle.alert-error {
245
+ background-color: var(--alert-subtle-error-bg);
246
+ border-left-color: var(--alert-subtle-error-accent);
247
+ }
248
+
249
+ .alert-subtle.alert-error .alert-icon-svg {
250
+ color: var(--alert-subtle-error-accent);
251
+ }
252
+
253
+ .alert-subtle.alert-error .alert-action {
254
+ color: var(--alert-subtle-error-accent);
255
+ }
256
+
257
+ .alert-subtle.alert-warning {
258
+ background-color: var(--alert-subtle-warning-bg);
259
+ border-left-color: var(--alert-subtle-warning-accent);
260
+ }
261
+
262
+ .alert-subtle.alert-warning .alert-icon-svg {
263
+ color: var(--alert-subtle-warning-accent);
264
+ }
265
+
266
+ .alert-subtle.alert-warning .alert-action {
267
+ color: var(--alert-subtle-warning-accent);
268
+ }
269
+
270
+ .alert-subtle.alert-info {
271
+ background-color: var(--alert-subtle-info-bg);
272
+ border-left-color: var(--alert-subtle-info-accent);
273
+ }
274
+
275
+ .alert-subtle.alert-info .alert-icon-svg {
276
+ color: var(--alert-subtle-info-accent);
277
+ }
278
+
279
+ .alert-subtle.alert-info .alert-action {
280
+ color: var(--alert-subtle-info-accent);
281
+ }
282
+
283
+ .alert-subtle.alert-neutral {
284
+ background-color: var(--alert-subtle-neutral-bg);
285
+ border-left-color: var(--alert-subtle-neutral-accent);
286
+ }
287
+
288
+ .alert-subtle.alert-neutral .alert-icon-svg {
289
+ color: var(--alert-subtle-neutral-accent);
290
+ }
291
+
292
+ .alert-subtle.alert-neutral .alert-action {
293
+ color: var(--color-neutral-600);
294
+ }
295
+
296
+ /* Subtle close button colors per type */
297
+ .alert-subtle.alert-success .alert-close { color: var(--color-success-dark); }
298
+ .alert-subtle.alert-success .alert-close:hover { background-color: var(--color-success-border); }
299
+
300
+ .alert-subtle.alert-error .alert-close { color: var(--color-error-dark); }
301
+ .alert-subtle.alert-error .alert-close:hover { background-color: var(--color-error-border); }
302
+
303
+ .alert-subtle.alert-warning .alert-close { color: var(--color-warning-dark); }
304
+ .alert-subtle.alert-warning .alert-close:hover { background-color: var(--color-warning-border); }
305
+
306
+ .alert-subtle.alert-info .alert-close { color: var(--color-info-dark); }
307
+ .alert-subtle.alert-info .alert-close:hover { background-color: var(--color-info-border); }
308
+
309
+ .alert-subtle.alert-neutral .alert-close { color: var(--color-neutral-600); }
310
+ .alert-subtle.alert-neutral .alert-close:hover { background-color: var(--color-neutral-200); }
311
+
312
+ /* ═══════════════════════════════════════════════════════════
313
+ ALERT — Variant: Filled
314
+ Full background color, white text
315
+ ═══════════════════════════════════════════════════════════ */
316
+
317
+ .alert-filled {
318
+ border: none;
319
+ color: var(--color-neutral-50);
320
+ }
321
+
322
+ .alert-filled.alert-success {
323
+ background-color: var(--alert-filled-success-bg);
324
+ }
325
+
326
+ .alert-filled.alert-error {
327
+ background-color: var(--alert-filled-error-bg);
328
+ }
329
+
330
+ .alert-filled.alert-warning {
331
+ background-color: var(--alert-filled-warning-bg);
332
+ color: var(--color-neutral-900);
333
+ }
334
+
335
+ .alert-filled.alert-info {
336
+ background-color: var(--alert-filled-info-bg);
337
+ }
338
+
339
+ .alert-filled.alert-neutral {
340
+ background-color: var(--alert-filled-neutral-bg);
341
+ }
342
+
343
+ /* Filled text overrides */
344
+ .alert-filled .alert-title {
345
+ color: inherit;
346
+ }
347
+
348
+ .alert-filled .alert-desc {
349
+ color: inherit;
350
+ opacity: 0.9;
351
+ }
352
+
353
+ .alert-filled .alert-list {
354
+ color: inherit;
355
+ opacity: 0.9;
356
+ }
357
+
358
+ .alert-filled .alert-icon-svg {
359
+ color: inherit;
360
+ }
361
+
362
+ .alert-filled .alert-action {
363
+ color: inherit;
364
+ text-decoration-color: rgba(255, 255, 255, 0.5);
365
+ }
366
+
367
+ .alert-filled .alert-action:hover {
368
+ text-decoration-color: rgba(255, 255, 255, 0.8);
369
+ }
370
+
371
+ .alert-filled.alert-warning .alert-action {
372
+ text-decoration-color: rgba(0, 0, 0, 0.3);
373
+ }
374
+
375
+ .alert-filled .alert-close {
376
+ color: inherit;
377
+ opacity: 0.7;
378
+ }
379
+
380
+ .alert-filled .alert-close:hover {
381
+ background-color: rgba(255, 255, 255, 0.15);
382
+ opacity: 1;
383
+ }
384
+
385
+ .alert-filled.alert-warning .alert-close:hover {
386
+ background-color: rgba(0, 0, 0, 0.1);
387
+ }
388
+
389
+ /* ═══════════════════════════════════════════════════════════
390
+ ALERT — Variant: Outline
391
+ Border only, no colored background
392
+ ═══════════════════════════════════════════════════════════ */
393
+
394
+ .alert-outline {
395
+ background-color: transparent;
396
+ border: var(--border-width) solid;
397
+ }
398
+
399
+ .alert-outline.alert-success {
400
+ border-color: var(--color-success-border);
401
+ }
402
+
403
+ .alert-outline.alert-success .alert-icon-svg {
404
+ color: var(--color-success);
405
+ }
406
+
407
+ .alert-outline.alert-success .alert-action {
408
+ color: var(--color-success);
409
+ }
410
+
411
+ .alert-outline.alert-error {
412
+ border-color: var(--color-error-border);
413
+ }
414
+
415
+ .alert-outline.alert-error .alert-icon-svg {
416
+ color: var(--color-error);
417
+ }
418
+
419
+ .alert-outline.alert-error .alert-action {
420
+ color: var(--color-error);
421
+ }
422
+
423
+ .alert-outline.alert-warning {
424
+ border-color: var(--color-warning-border);
425
+ }
426
+
427
+ .alert-outline.alert-warning .alert-icon-svg {
428
+ color: var(--color-warning);
429
+ }
430
+
431
+ .alert-outline.alert-warning .alert-action {
432
+ color: var(--color-warning);
433
+ }
434
+
435
+ .alert-outline.alert-info {
436
+ border-color: var(--color-info-border);
437
+ }
438
+
439
+ .alert-outline.alert-info .alert-icon-svg {
440
+ color: var(--color-info);
441
+ }
442
+
443
+ .alert-outline.alert-info .alert-action {
444
+ color: var(--color-info);
445
+ }
446
+
447
+ .alert-outline.alert-neutral {
448
+ border-color: var(--color-neutral-300);
449
+ }
450
+
451
+ .alert-outline.alert-neutral .alert-icon-svg {
452
+ color: var(--color-neutral-500);
453
+ }
454
+
455
+ .alert-outline.alert-neutral .alert-action {
456
+ color: var(--color-neutral-600);
457
+ }
458
+
459
+ .alert-outline .alert-close {
460
+ color: var(--color-neutral-500);
461
+ }
462
+
463
+ .alert-outline .alert-close:hover {
464
+ background-color: var(--color-neutral-100);
465
+ }
466
+
467
+ /* ═══════════════════════════════════════════════════════════
468
+ ALERT — Size: Compact
469
+ ═══════════════════════════════════════════════════════════ */
470
+
471
+ .alert-compact {
472
+ padding: var(--alert-padding-compact);
473
+ gap: var(--space-2);
474
+ }
475
+
476
+ .alert-compact .alert-icon-svg {
477
+ width: var(--space-4);
478
+ height: var(--space-4);
479
+ margin-top: 0;
480
+ }
481
+
482
+ .alert-compact .alert-title {
483
+ font-size: var(--text-sm);
484
+ margin-bottom: 0;
485
+ }
486
+
487
+ .alert-compact .alert-desc {
488
+ font-size: var(--text-sm);
489
+ }
490
+
491
+ .alert-compact .alert-action {
492
+ margin-top: var(--space-1);
493
+ }
494
+
495
+ .alert-compact .alert-close {
496
+ width: var(--space-5);
497
+ height: var(--space-5);
498
+ }
499
+
500
+ .alert-compact .alert-close svg {
501
+ width: var(--space-3);
502
+ height: var(--space-3);
503
+ }
504
+
505
+ /* ═══════════════════════════════════════════════════════════
506
+ INLINE MESSAGE — Mini alert for inside components
507
+ ═══════════════════════════════════════════════════════════ */
508
+
509
+ .inline-message {
510
+ display: inline-flex;
511
+ align-items: center;
512
+ gap: var(--space-1-5);
513
+ font-family: var(--font-sans);
514
+ font-size: var(--inline-msg-font-size);
515
+ font-weight: var(--font-medium);
516
+ line-height: var(--leading-tight);
517
+ }
518
+
519
+ .inline-message-icon {
520
+ width: var(--inline-msg-icon-size);
521
+ height: var(--inline-msg-icon-size);
522
+ flex-shrink: 0;
523
+ }
524
+
525
+ /* Inline message type colors */
526
+ .inline-message-success {
527
+ color: var(--color-success);
528
+ }
529
+
530
+ .inline-message-error {
531
+ color: var(--color-error);
532
+ }
533
+
534
+ .inline-message-warning {
535
+ color: var(--color-warning);
536
+ }
537
+
538
+ .inline-message-info {
539
+ color: var(--color-info);
540
+ }
541
+
542
+ .inline-message-neutral {
543
+ color: var(--color-neutral-500);
544
+ }
545
+
546
+ /* ═══════════════════════════════════════════════════════════
547
+ PAGE BANNER — Full-width banner above content
548
+ ═══════════════════════════════════════════════════════════ */
549
+
550
+ .page-banner {
551
+ display: flex;
552
+ align-items: center;
553
+ justify-content: center;
554
+ gap: var(--space-4);
555
+ padding: var(--page-banner-padding);
556
+ background-color: var(--page-banner-bg);
557
+ color: var(--page-banner-color);
558
+ font-family: var(--font-sans);
559
+ font-size: var(--page-banner-font-size);
560
+ line-height: var(--leading-tight);
561
+ position: sticky;
562
+ top: 0;
563
+ z-index: var(--z-overlay);
564
+ overflow: hidden;
565
+ max-height: var(--page-banner-max-h);
566
+ opacity: 1;
567
+ transition: max-height var(--alert-slide-duration) var(--ease-out),
568
+ opacity var(--alert-slide-duration) var(--ease-in-out),
569
+ padding-top var(--alert-slide-duration) var(--ease-out),
570
+ padding-bottom var(--alert-slide-duration) var(--ease-out);
571
+ }
572
+
573
+ .page-banner.is-dismissing {
574
+ max-height: 0;
575
+ opacity: 0;
576
+ padding-top: 0;
577
+ padding-bottom: 0;
578
+ pointer-events: none;
579
+ }
580
+
581
+ .page-banner-text {
582
+ flex: 1;
583
+ text-align: center;
584
+ max-width: var(--page-banner-text-max);
585
+ }
586
+
587
+ .page-banner-text strong {
588
+ font-weight: var(--font-semibold);
589
+ }
590
+
591
+ .page-banner-action {
592
+ flex-shrink: 0;
593
+ font-family: var(--font-sans);
594
+ font-size: var(--text-sm);
595
+ font-weight: var(--font-semibold);
596
+ color: inherit;
597
+ text-decoration: underline;
598
+ text-underline-offset: var(--space-0-5);
599
+ cursor: pointer;
600
+ background: transparent;
601
+ border: none;
602
+ padding: 0;
603
+ transition: opacity var(--duration-fast) var(--ease-in-out);
604
+ }
605
+
606
+ .page-banner-action:hover {
607
+ opacity: 0.8;
608
+ text-decoration-thickness: var(--alert-hover-underline);
609
+ }
610
+
611
+ .page-banner-close {
612
+ flex-shrink: 0;
613
+ display: inline-flex;
614
+ align-items: center;
615
+ justify-content: center;
616
+ width: var(--space-6);
617
+ height: var(--space-6);
618
+ border: none;
619
+ border-radius: var(--radius-sm);
620
+ background: transparent;
621
+ color: inherit;
622
+ opacity: 0.7;
623
+ cursor: pointer;
624
+ padding: 0;
625
+ transition: opacity var(--duration-fast) var(--ease-in-out),
626
+ background-color var(--duration-fast) var(--ease-in-out);
627
+ }
628
+
629
+ .page-banner-close:hover {
630
+ opacity: 1;
631
+ background-color: rgba(255, 255, 255, 0.15);
632
+ }
633
+
634
+ .page-banner-close svg {
635
+ width: var(--space-3-5);
636
+ height: var(--space-3-5);
637
+ }
638
+
639
+ /* Page banner color variants */
640
+ .page-banner-success {
641
+ background-color: var(--color-success);
642
+ }
643
+
644
+ .page-banner-error {
645
+ background-color: var(--color-error);
646
+ }
647
+
648
+ .page-banner-warning {
649
+ background-color: var(--color-warning);
650
+ color: var(--color-neutral-900);
651
+ }
652
+
653
+ .page-banner-info {
654
+ background-color: var(--color-info);
655
+ }
656
+
657
+ .page-banner-neutral {
658
+ background-color: var(--color-neutral-700);
659
+ }