@inglorious/ui 9.7.3 → 9.8.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.
Files changed (104) hide show
  1. package/package.json +5 -5
  2. package/src/controls/button/style.css +0 -2
  3. package/src/controls/button/template.js +2 -3
  4. package/src/controls/checkbox/style.css +0 -1
  5. package/src/controls/checkbox/template.js +0 -2
  6. package/src/controls/combobox/style.css +0 -14
  7. package/src/controls/combobox/template.js +0 -13
  8. package/src/controls/file-upload/template.js +1 -1
  9. package/src/controls/image-cropper/helpers.js +0 -2
  10. package/src/controls/image-cropper/image.js +0 -2
  11. package/src/controls/image-cropper/style.css +0 -6
  12. package/src/controls/image-cropper/template.js +3 -5
  13. package/src/controls/input/style.css +0 -1
  14. package/src/controls/radio-group/style.css +0 -2
  15. package/src/controls/rating/style.css +0 -3
  16. package/src/controls/select/style.css +0 -6
  17. package/src/controls/slider/style.css +0 -5
  18. package/src/controls/slider/template.js +0 -1
  19. package/src/controls/switch/style.css +0 -1
  20. package/src/controls/switch/template.js +0 -2
  21. package/src/controls/textarea/style.css +0 -2
  22. package/src/data-display/before-after/style.css +0 -4
  23. package/src/data-display/before-after/template.js +3 -3
  24. package/src/data-display/carousel/carousel.stories.js +0 -2
  25. package/src/data-display/carousel/handlers.js +0 -2
  26. package/src/data-display/carousel/style.css +0 -18
  27. package/src/data-display/carousel/template.js +0 -15
  28. package/src/data-display/chat/index.js +0 -1
  29. package/src/data-display/chat/style.css +0 -2
  30. package/src/data-display/chat/template.js +0 -1
  31. package/src/data-display/chip/template.js +0 -1
  32. package/src/data-display/data-grid/base.css +0 -2
  33. package/src/data-display/data-grid/handlers.js +1 -8
  34. package/src/data-display/data-grid/helpers.js +0 -5
  35. package/src/data-display/data-grid/template.js +0 -1
  36. package/src/data-display/data-grid/theme.css +0 -1
  37. package/src/data-display/icon/style.css +0 -7
  38. package/src/data-display/icon/template.js +2 -2
  39. package/src/data-display/table/style.css +0 -2
  40. package/src/data-display/tooltip/style.css +0 -3
  41. package/src/data-display/virtual-list/handlers.js +0 -2
  42. package/src/data-display/virtual-list/template.js +2 -4
  43. package/src/examples/dashboard/before-after-data.js +0 -3
  44. package/src/examples/dashboard/data.js +0 -1
  45. package/src/examples/dashboard/primitive-content.js +0 -2
  46. package/src/examples/dashboard/style.css +0 -3
  47. package/src/feedback/alert/style.css +0 -1
  48. package/src/feedback/dialog/dialog.stories.js +7 -2
  49. package/src/feedback/dialog/style.css +31 -18
  50. package/src/feedback/dialog/template.js +16 -16
  51. package/src/feedback/progress/style.css +0 -6
  52. package/src/feedback/progress/template.js +0 -3
  53. package/src/feedback/snackbar/snackbar.stories.js +0 -1
  54. package/src/feedback/snackbar/style.css +0 -10
  55. package/src/layout/flex/style.css +0 -2
  56. package/src/navigation/bottom-navigation/style.css +0 -7
  57. package/src/navigation/drawer/style.css +0 -21
  58. package/src/navigation/drawer/template.js +10 -9
  59. package/src/navigation/menu/menu.stories.js +0 -2
  60. package/src/navigation/menu/style.css +0 -4
  61. package/src/navigation/menu/template.js +0 -3
  62. package/src/navigation/speed-dial/style.css +0 -4
  63. package/src/navigation/speed-dial/template.js +0 -5
  64. package/src/navigation/tabs/template.js +0 -2
  65. package/src/navigation/view-transitions/index.js +0 -13
  66. package/src/navigation/view-transitions/style.css +0 -2
  67. package/src/shared/icons.js +0 -4
  68. package/src/styles/themes/bootstrap.css +0 -40
  69. package/src/styles/themes/inglorious.css +0 -21
  70. package/src/styles/themes/ios-18.css +0 -47
  71. package/src/styles/themes/ios-26.css +0 -55
  72. package/src/styles/themes/material-3.css +0 -52
  73. package/src/styles/themes/material-ui.css +0 -43
  74. package/src/styles/tokens.css +0 -40
  75. package/src/surfaces/accordion/style.css +0 -2
  76. package/src/surfaces/accordion/template.js +0 -4
  77. package/src/surfaces/app-bar/style.css +0 -3
  78. package/src/surfaces/card/style.css +0 -3
  79. package/types/controls/button-group.d.ts +5 -3
  80. package/types/controls/button.d.ts +3 -1
  81. package/types/controls/combobox.d.ts +13 -0
  82. package/types/controls/fab.d.ts +1 -1
  83. package/types/controls/icon-button.d.ts +7 -21
  84. package/types/controls/input.d.ts +2 -2
  85. package/types/data-display/avatar.d.ts +1 -1
  86. package/types/data-display/badge.d.ts +4 -2
  87. package/types/data-display/chip.d.ts +5 -3
  88. package/types/data-display/icon.d.ts +4 -2
  89. package/types/data-display/tooltip.d.ts +4 -2
  90. package/types/data-display/typography.d.ts +3 -1
  91. package/types/feedback/alert.d.ts +3 -1
  92. package/types/feedback/backdrop.d.ts +4 -2
  93. package/types/feedback/dialog.d.ts +11 -1
  94. package/types/index.d.ts +1 -0
  95. package/types/layout/container.d.ts +3 -1
  96. package/types/layout/flex.d.ts +9 -11
  97. package/types/layout/grid.d.ts +4 -2
  98. package/types/navigation/breadcrumbs.d.ts +1 -1
  99. package/types/navigation/drawer.d.ts +9 -1
  100. package/types/navigation/link.d.ts +4 -2
  101. package/types/shared/renderable.d.ts +12 -0
  102. package/types/surfaces/app-bar.d.ts +3 -1
  103. package/types/surfaces/card.d.ts +4 -2
  104. package/types/surfaces/paper.d.ts +3 -1
@@ -2,17 +2,10 @@
2
2
 
3
3
  .iw-theme-material-3 {
4
4
  --iw-font-family-sans: "Roboto", "Helvetica", "Arial", sans-serif;
5
- /* The theme on the page itself: the element with the theme class, usually
6
- <body>, takes its background, text color and font. */
7
5
  background-color: var(--iw-color-bg);
8
6
  color: var(--iw-color-text);
9
7
  font-family: var(--iw-font-family-sans);
10
8
 
11
- /* ========================================
12
- MATERIAL 3 THEME - Material Design 3 baseline
13
- ======================================== */
14
-
15
- /* Material 3 color roles the shared tokens have no name for */
16
9
  --iw-m3-outline: #79747e;
17
10
  --iw-m3-surface-container-low: #f7f2fa;
18
11
  --iw-m3-surface-container: #f3edf7;
@@ -24,7 +17,6 @@
24
17
  --iw-m3-inverse-on-surface: #f5eff7;
25
18
  --iw-m3-inverse-primary: #d0bcff;
26
19
 
27
- /* Semantic Colors */
28
20
  --iw-color-bg: #fef7ff;
29
21
  --iw-color-bg-secondary: var(--iw-m3-surface-container);
30
22
  --iw-color-bg-tertiary: var(--iw-m3-surface-container-highest);
@@ -52,19 +44,15 @@
52
44
  --iw-color-primary-active: color-mix(in srgb, #6750a4 90%, #ffffff);
53
45
  --iw-color-primary-text: var(--iw-color-white);
54
46
 
55
- /* Material 3's secondary color */
56
47
  --iw-color-accent: #625b71;
57
48
  --iw-color-accent-hover: color-mix(in srgb, #625b71 92%, #ffffff);
58
49
  --iw-color-accent-active: color-mix(in srgb, #625b71 90%, #ffffff);
59
50
 
60
- /* Material 3 defines only an error color: the others are custom colors at
61
- the same tones as the primary */
62
51
  --iw-color-success: #386a20;
63
52
  --iw-color-warning: #7d5700;
64
53
  --iw-color-error: #b3261e;
65
54
  --iw-color-info: #00639a;
66
55
 
67
- /* Elevation levels 1 to 4 */
68
56
  --iw-shadow-sm:
69
57
  0 1px 2px 0 rgba(0, 0, 0, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.15);
70
58
  --iw-shadow-md:
@@ -74,23 +62,16 @@
74
62
  --iw-shadow-xl:
75
63
  0 2px 3px 0 rgba(0, 0, 0, 0.3), 0 6px 10px 4px rgba(0, 0, 0, 0.15);
76
64
 
77
- /* Material 3's shape scale: extra small to extra large */
78
65
  --iw-radius-sm: 4px;
79
66
  --iw-radius-md: 8px;
80
67
  --iw-radius-lg: 12px;
81
68
  --iw-radius-xl: 16px;
82
69
  --iw-radius-2xl: 28px;
83
70
 
84
- /* Labels in the label-large style: medium weight, as written */
85
71
  --iw-label-text-transform: none;
86
72
  --iw-label-letter-spacing: 0.00714em;
87
73
  --iw-label-font-weight: var(--iw-font-weight-medium);
88
74
 
89
- /* ========================================
90
- COMPONENT TOKENS
91
- ======================================== */
92
-
93
- /* Button: filled, in a pill */
94
75
  --iw-button-bg: var(--iw-color-primary);
95
76
  --iw-button-bg-hover: var(--iw-color-primary-hover);
96
77
  --iw-button-bg-active: var(--iw-color-primary-active);
@@ -101,8 +82,6 @@
101
82
  --iw-button-shadow-hover: var(--iw-shadow-sm);
102
83
  --iw-button-shadow-active: none;
103
84
 
104
- /* A button's default color is a filled tonal button, whose outlined and
105
- ghost forms take the primary color */
106
85
  --iw-button-default-color: var(--iw-color-primary);
107
86
  --iw-button-default-bg: var(--iw-m3-secondary-container);
108
87
  --iw-button-default-bg-hover: var(--iw-m3-secondary-container);
@@ -110,7 +89,6 @@
110
89
  --iw-button-default-border: var(--iw-m3-secondary-container);
111
90
  --iw-button-default-text: var(--iw-m3-on-secondary-container);
112
91
 
113
- /* Input: a filled text field */
114
92
  --iw-input-bg: var(--iw-m3-surface-container-highest);
115
93
  --iw-input-bg-hover: color-mix(
116
94
  in srgb,
@@ -124,40 +102,31 @@
124
102
  --iw-input-border-hover: var(--iw-color-text);
125
103
  --iw-input-border-focus: var(--iw-color-primary);
126
104
  --iw-input-radius: var(--iw-radius-sm) var(--iw-radius-sm) 0 0;
127
- /* With the bottom border, a 2px active indicator */
128
105
  --iw-input-shadow-focus: inset 0 -1px 0 var(--iw-input-border-focus);
129
106
 
130
- /* App bar: a top app bar on the surface */
131
107
  --iw-app-bar-bg: var(--iw-color-bg);
132
108
 
133
- /* Drawer: a navigation drawer */
134
109
  --iw-drawer-bg: var(--iw-m3-surface-container-low);
135
110
 
136
- /* Card: an elevated card */
137
111
  --iw-card-bg: var(--iw-m3-surface-container-low);
138
112
  --iw-card-border: transparent;
139
113
  --iw-card-radius: var(--iw-radius-lg);
140
114
  --iw-card-shadow: var(--iw-shadow-sm);
141
115
  --iw-card-shadow-hover: var(--iw-shadow-md);
142
116
 
143
- /* Badge */
144
117
  --iw-badge-radius: var(--iw-radius-full);
145
118
 
146
- /* Chip: outlined, on no background of its own */
147
119
  --iw-chip-bg: transparent;
148
120
 
149
- /* List */
150
121
  --iw-list-item: transparent;
151
122
  --iw-list-item-active: var(--iw-color-surface-hover);
152
123
  --iw-list-item-selected: var(--iw-m3-secondary-container);
153
124
 
154
- /* Alert */
155
125
  --iw-alert-radius: var(--iw-radius-lg);
156
126
  --iw-alert-shadow: none;
157
127
  color-scheme: light;
158
128
  }
159
129
 
160
- /* Dark variant */
161
130
  .iw-theme-material-3.iw-theme-dark {
162
131
  color-scheme: dark;
163
132
 
@@ -196,8 +165,6 @@
196
165
  }
197
166
 
198
167
  .iw-theme-material-3 {
199
- /* Buttons: pills 40px tall. Hovering and pressing lay the label's color
200
- over the container, as Material 3's state layers */
201
168
  .iw-button {
202
169
  padding: 10px 24px;
203
170
  font-size: 0.875rem;
@@ -256,7 +223,6 @@
256
223
  );
257
224
  }
258
225
 
259
- /* Outlined buttons have a neutral outline, whatever their color */
260
226
  &.iw-button-outline {
261
227
  border-color: var(--iw-m3-outline);
262
228
  }
@@ -309,7 +275,6 @@
309
275
  }
310
276
  }
311
277
 
312
- /* On dark, labels on a color are a deep tone of it */
313
278
  &.iw-theme-dark .iw-button {
314
279
  &.iw-button-secondary,
315
280
  &.iw-button-success,
@@ -324,8 +289,6 @@
324
289
  }
325
290
  }
326
291
 
327
- /* Filled text fields: a tinted box with an indicator along its bottom,
328
- 2px and in the primary color while it has focus */
329
292
  .iw-input .iw-input-frame,
330
293
  .iw-select .iw-select-frame,
331
294
  .iw-combobox .iw-combobox-frame,
@@ -388,8 +351,6 @@
388
351
  height: 1.125rem;
389
352
  }
390
353
 
391
- /* Switch: a tall outlined track whose thumb grows and takes the track's
392
- opposite color when on */
393
354
  .iw-switch {
394
355
  .iw-switch-track {
395
356
  width: 3.25rem;
@@ -481,7 +442,6 @@
481
442
  );
482
443
  }
483
444
 
484
- /* Tabs: primary tabs, with a rounded indicator as wide as the label */
485
445
  .iw-tabs-list {
486
446
  gap: 0;
487
447
  }
@@ -514,8 +474,6 @@
514
474
  }
515
475
  }
516
476
 
517
- /* Chips: outlined, with small rounded corners, and filled with the
518
- secondary container when selected */
519
477
  .iw-chip {
520
478
  min-height: 2rem;
521
479
  padding-inline: 16px;
@@ -557,8 +515,6 @@
557
515
  font-weight: var(--iw-font-weight-medium);
558
516
  }
559
517
 
560
- /* Cards: elevated, with no rules between their parts. A sunk card is a
561
- filled one */
562
518
  .iw-card-header,
563
519
  .iw-card-footer {
564
520
  border: 0 none;
@@ -583,8 +539,6 @@
583
539
  color: var(--iw-color-text-secondary);
584
540
  }
585
541
 
586
- /* Alerts: Material 3 has none, so they are tonal containers of their
587
- color, with rounded corners and no border */
588
542
  .iw-alert {
589
543
  padding: 12px 16px;
590
544
  font-size: 0.875rem;
@@ -639,8 +593,6 @@
639
593
  }
640
594
  }
641
595
 
642
- /* Tables: Material 3 has none either, so plain rows ruled by the outline
643
- variant */
644
596
  .iw-table {
645
597
  border: 0 none;
646
598
  background: transparent;
@@ -662,7 +614,6 @@
662
614
  background: var(--iw-m3-surface-container);
663
615
  }
664
616
 
665
- /* Dialogs: a container with extra large corners */
666
617
  .iw-dialog {
667
618
  border: 0 none;
668
619
  border-radius: var(--iw-radius-2xl);
@@ -697,7 +648,6 @@
697
648
  gap: 8px;
698
649
  }
699
650
 
700
- /* Menus, tooltips and snackbars */
701
651
  .iw-menu {
702
652
  padding: 8px 0;
703
653
  border: 0 none;
@@ -726,8 +676,6 @@
726
676
  color: var(--iw-m3-inverse-primary);
727
677
  }
728
678
 
729
- /* App bars: top app bars, flat on the surface, which take a container
730
- color instead of a shadow when raised */
731
679
  .iw-app-bar {
732
680
  border-bottom: 0 none;
733
681
  }
@@ -2,17 +2,10 @@
2
2
 
3
3
  .iw-theme-material-ui {
4
4
  --iw-font-family-sans: "Roboto", "Helvetica", "Arial", sans-serif;
5
- /* The theme on the page itself: the element with the theme class, usually
6
- <body>, takes its background, text color and font. */
7
5
  background-color: var(--iw-color-bg);
8
6
  color: var(--iw-color-text);
9
7
  font-family: var(--iw-font-family-sans);
10
8
 
11
- /* ========================================
12
- MATERIAL UI THEME - Material UI defaults
13
- ======================================== */
14
-
15
- /* Semantic Colors */
16
9
  --iw-color-bg: var(--iw-color-white);
17
10
  --iw-color-bg-secondary: #f5f5f5;
18
11
  --iw-color-bg-tertiary: #eeeeee;
@@ -32,7 +25,6 @@
32
25
  --iw-color-primary-active: #1565c0;
33
26
  --iw-color-primary-text: var(--iw-color-white);
34
27
 
35
- /* Material UI's secondary color */
36
28
  --iw-color-accent: #9c27b0;
37
29
  --iw-color-accent-hover: #7b1fa2;
38
30
  --iw-color-accent-active: #7b1fa2;
@@ -46,7 +38,6 @@
46
38
  --iw-color-info: #0288d1;
47
39
  --iw-color-info-dark: #01579b;
48
40
 
49
- /* Elevations 1, 2, 4, 8 and 24 */
50
41
  --iw-shadow-sm:
51
42
  0 2px 1px -1px rgba(0, 0, 0, 0.2), 0 1px 1px 0 rgba(0, 0, 0, 0.14),
52
43
  0 1px 3px 0 rgba(0, 0, 0, 0.12);
@@ -63,21 +54,14 @@
63
54
  0 11px 15px -7px rgba(0, 0, 0, 0.2), 0 24px 38px 3px rgba(0, 0, 0, 0.14),
64
55
  0 9px 46px 8px rgba(0, 0, 0, 0.12);
65
56
 
66
- /* One corner radius for everything, as Material UI's shape */
67
57
  --iw-radius-sm: 4px;
68
58
  --iw-radius-md: 4px;
69
59
  --iw-radius-lg: 4px;
70
60
 
71
- /* Buttons and tabs carry their labels as Material UI does */
72
61
  --iw-label-text-transform: uppercase;
73
62
  --iw-label-letter-spacing: 0.02857em;
74
63
  --iw-label-font-weight: var(--iw-font-weight-medium);
75
64
 
76
- /* ========================================
77
- COMPONENT TOKENS
78
- ======================================== */
79
-
80
- /* Button */
81
65
  --iw-button-bg: var(--iw-color-primary);
82
66
  --iw-button-bg-hover: var(--iw-color-primary-hover);
83
67
  --iw-button-bg-active: var(--iw-color-primary-active);
@@ -88,7 +72,6 @@
88
72
  --iw-button-shadow-hover: var(--iw-shadow-lg);
89
73
  --iw-button-shadow-active: var(--iw-shadow-xl);
90
74
 
91
- /* A button's default color is primary, as in Material UI */
92
75
  --iw-button-default-color: var(--iw-color-primary);
93
76
  --iw-button-default-bg: var(--iw-color-primary);
94
77
  --iw-button-default-bg-hover: var(--iw-color-primary-hover);
@@ -96,7 +79,6 @@
96
79
  --iw-button-default-border: var(--iw-color-primary);
97
80
  --iw-button-default-text: var(--iw-color-primary-text);
98
81
 
99
- /* Input: an outlined text field */
100
82
  --iw-input-bg: transparent;
101
83
  --iw-input-bg-hover: transparent;
102
84
  --iw-input-bg-focus: transparent;
@@ -106,29 +88,22 @@
106
88
  --iw-input-border-hover: var(--iw-color-text);
107
89
  --iw-input-border-focus: var(--iw-color-primary);
108
90
  --iw-input-radius: var(--iw-radius-md);
109
- /* With the border, a 2px outline */
110
91
  --iw-input-shadow-focus: inset 0 0 0 1px var(--iw-input-border-focus);
111
92
 
112
- /* App bar */
113
93
  --iw-app-bar-bg: #f5f5f5;
114
94
 
115
- /* Drawer */
116
95
  --iw-drawer-bg: var(--iw-color-surface);
117
96
 
118
- /* Card: a Paper at elevation 1 */
119
97
  --iw-card-bg: var(--iw-color-surface);
120
98
  --iw-card-border: transparent;
121
99
  --iw-card-radius: var(--iw-radius-md);
122
100
  --iw-card-shadow: var(--iw-shadow-sm);
123
101
  --iw-card-shadow-hover: var(--iw-shadow-xl);
124
102
 
125
- /* Badge */
126
103
  --iw-badge-radius: var(--iw-radius-full);
127
104
 
128
- /* Chip */
129
105
  --iw-chip-bg: rgba(0, 0, 0, 0.08);
130
106
 
131
- /* List */
132
107
  --iw-list-item: transparent;
133
108
  --iw-list-item-selected: color-mix(
134
109
  in srgb,
@@ -136,20 +111,17 @@
136
111
  transparent
137
112
  );
138
113
 
139
- /* Alert */
140
114
  --iw-alert-radius: var(--iw-radius-md);
141
115
  --iw-alert-shadow: none;
142
116
  color-scheme: light;
143
117
  }
144
118
 
145
- /* Dark variant */
146
119
  .iw-theme-material-ui.iw-theme-dark {
147
120
  color-scheme: dark;
148
121
 
149
122
  --iw-color-bg: #121212;
150
123
  --iw-color-bg-secondary: #1e1e1e;
151
124
  --iw-color-bg-tertiary: #2c2c2c;
152
- /* A raised surface is lightened, as Material UI's elevation overlay */
153
125
  --iw-color-surface: #1e1e1e;
154
126
  --iw-color-surface-hover: rgba(255, 255, 255, 0.08);
155
127
  --iw-color-surface-active: rgba(255, 255, 255, 0.16);
@@ -181,7 +153,6 @@
181
153
  --iw-input-text-placeholder: rgba(255, 255, 255, 0.5);
182
154
  --iw-input-border: rgba(255, 255, 255, 0.23);
183
155
 
184
- /* Dark app bars are surfaces, as Material UI's enableColorOnDark is off */
185
156
  --iw-app-bar-bg: #272727;
186
157
 
187
158
  --iw-chip-bg: rgba(255, 255, 255, 0.16);
@@ -196,7 +167,6 @@
196
167
  }
197
168
 
198
169
  .iw-theme-material-ui {
199
- /* Contained buttons: Material UI's sizes and colors, raised on hover */
200
170
  .iw-button {
201
171
  padding: 6px 16px;
202
172
  font-size: 0.875rem;
@@ -255,7 +225,6 @@
255
225
  &.iw-button-outline {
256
226
  border: 1px solid
257
227
  color-mix(in srgb, var(--iw-button-color) 50%, transparent);
258
- /* One pixel less, for the border */
259
228
  padding: 5px 15px;
260
229
 
261
230
  &.iw-button-sm {
@@ -327,8 +296,6 @@
327
296
  }
328
297
  }
329
298
 
330
- /* Outlined text fields: the label and helper text sit as Material UI's do,
331
- and the label takes the primary color while the field has focus */
332
299
  .iw-input,
333
300
  .iw-select,
334
301
  .iw-textarea-field {
@@ -374,12 +341,10 @@
374
341
  }
375
342
  }
376
343
 
377
- /* Switch: a thin track under a larger, raised thumb that takes the color */
378
344
  .iw-switch {
379
345
  .iw-switch-track {
380
346
  width: 2.125rem;
381
347
  height: 0.875rem;
382
- /* Room for the thumb, which overhangs the track */
383
348
  margin-inline: 3px;
384
349
  padding: 0;
385
350
  overflow: visible;
@@ -450,7 +415,6 @@
450
415
  }
451
416
  }
452
417
 
453
- /* Tabs */
454
418
  .iw-tabs-list {
455
419
  gap: 0;
456
420
  }
@@ -466,7 +430,6 @@
466
430
  color: var(--iw-color-primary);
467
431
  }
468
432
 
469
- /* Chips: Material UI's height, and filled when they have a color */
470
433
  .iw-chip {
471
434
  min-height: 2rem;
472
435
  padding-inline: 12px;
@@ -530,7 +493,6 @@
530
493
  font-weight: var(--iw-font-weight-medium);
531
494
  }
532
495
 
533
- /* Cards: a raised Paper, with no rules between its parts */
534
496
  .iw-card-header,
535
497
  .iw-card-footer {
536
498
  border: 0 none;
@@ -540,7 +502,6 @@
540
502
  background-color: transparent;
541
503
  }
542
504
 
543
- /* Unless given a padding of its own */
544
505
  .iw-card-footer:not([class*="iw-card-footer-padding-"]) {
545
506
  padding: var(--iw-space-2);
546
507
  }
@@ -555,7 +516,6 @@
555
516
  margin: 0;
556
517
  }
557
518
 
558
- /* Alerts: tinted with the color, the text a deep shade of it */
559
519
  .iw-alert {
560
520
  padding: 6px 16px;
561
521
  font-size: 0.875rem;
@@ -614,7 +574,6 @@
614
574
  }
615
575
  }
616
576
 
617
- /* Tables sit on a Paper, which draws no border of its own */
618
577
  .iw-table {
619
578
  border: 0 none;
620
579
  font-size: 0.875rem;
@@ -630,7 +589,6 @@
630
589
  font-weight: var(--iw-font-weight-medium);
631
590
  }
632
591
 
633
- /* Dialogs: a Paper at elevation 24 */
634
592
  .iw-dialog {
635
593
  border: 0 none;
636
594
  box-shadow: var(--iw-shadow-2xl);
@@ -664,7 +622,6 @@
664
622
  padding: 0;
665
623
  }
666
624
 
667
- /* App bars: no border, and raised to elevation 4 */
668
625
  .iw-app-bar {
669
626
  border-bottom: 0 none;
670
627
  }
@@ -1,7 +1,3 @@
1
- /* The writing direction as a number, for what moves sideways: a slide that
2
- goes `translateX(calc(-100% * var(--iw-dir-sign)))` leaves to the left in
3
- English and to the right in Arabic. Set again on any element with a `dir`,
4
- so a subtree in the other direction gets its own. */
5
1
  :root,
6
2
  [dir="ltr"] {
7
3
  --iw-dir-sign: 1;
@@ -12,13 +8,9 @@
12
8
  }
13
9
 
14
10
  :root {
15
- /* ========================================
16
- COLOR PALETTE - Primitive Colors
17
- ======================================== */
18
11
  --iw-color-white: #ffffff;
19
12
  --iw-color-black: #000000;
20
13
 
21
- /* Brand Colors */
22
14
  --iw-color-primary-50: #e6fff0;
23
15
  --iw-color-primary-100: #b3ffd6;
24
16
  --iw-color-primary-200: #80ffbd;
@@ -30,7 +22,6 @@
30
22
  --iw-color-primary-800: #006637;
31
23
  --iw-color-primary-900: #00331c;
32
24
 
33
- /* Neutral Colors */
34
25
  --iw-color-gray-50: #fafafa;
35
26
  --iw-color-gray-100: #f4f4f5;
36
27
  --iw-color-gray-200: #e4e4e7;
@@ -42,7 +33,6 @@
42
33
  --iw-color-gray-800: #27272a;
43
34
  --iw-color-gray-900: #18181b;
44
35
 
45
- /* Semantic Colors */
46
36
  --iw-color-success-light: #d1fae5;
47
37
  --iw-color-success: #10b981;
48
38
  --iw-color-success-dark: #065f46;
@@ -59,9 +49,6 @@
59
49
  --iw-color-info: #3b82f6;
60
50
  --iw-color-info-dark: #1e40af;
61
51
 
62
- /* ========================================
63
- SPACING SCALE
64
- ======================================== */
65
52
  --iw-space-0: 0;
66
53
  --iw-space-1: 0.25rem;
67
54
  --iw-space-2: 0.5rem;
@@ -77,18 +64,12 @@
77
64
  --iw-space-20: 5rem;
78
65
  --iw-space-24: 6rem;
79
66
 
80
- /* ========================================
81
- BREAKPOINTS
82
- ======================================== */
83
67
  --iw-breakpoint-xs: 20rem;
84
68
  --iw-breakpoint-sm: 40rem;
85
69
  --iw-breakpoint-md: 48rem;
86
70
  --iw-breakpoint-lg: 64rem;
87
71
  --iw-breakpoint-xl: 80rem;
88
72
 
89
- /* ========================================
90
- BORDER RADIUS
91
- ======================================== */
92
73
  --iw-radius-none: 0;
93
74
  --iw-radius-sm: 2px;
94
75
  --iw-radius-md: 4px;
@@ -97,9 +78,6 @@
97
78
  --iw-radius-2xl: 16px;
98
79
  --iw-radius-full: 9999px;
99
80
 
100
- /* ========================================
101
- TYPOGRAPHY
102
- ======================================== */
103
81
  --iw-font-family-sans:
104
82
  system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
105
83
  "Helvetica Neue", Arial, sans-serif;
@@ -125,14 +103,10 @@
125
103
  --iw-line-height-normal: 1.5;
126
104
  --iw-line-height-relaxed: 1.75;
127
105
 
128
- /* Labels of buttons and tabs: a theme can set them in capitals. */
129
106
  --iw-label-text-transform: none;
130
107
  --iw-label-letter-spacing: normal;
131
108
  --iw-label-font-weight: var(--iw-font-weight-normal);
132
109
 
133
- /* ========================================
134
- SHADOWS
135
- ======================================== */
136
110
  --iw-shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
137
111
  --iw-shadow-md:
138
112
  0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
@@ -141,12 +115,6 @@
141
115
  --iw-shadow-xl:
142
116
  0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
143
117
 
144
- /* ========================================
145
- TRANSITIONS
146
- ======================================== */
147
- /* A duration and an easing, so that motion can pick one of each. Anything
148
- that has to vary them separately — a page arriving is not eased the way a
149
- page leaving is — composes them rather than reaching for the shorthands. */
150
118
  --iw-duration-fast: 150ms;
151
119
  --iw-duration-normal: 200ms;
152
120
  --iw-duration-page: 250ms;
@@ -155,19 +123,11 @@
155
123
  --iw-easing-accelerate: cubic-bezier(0.4, 0, 1, 1);
156
124
  --iw-easing-decelerate: cubic-bezier(0, 0, 0.2, 1);
157
125
 
158
- /* Shorthands for a plain `ease` at one of the durations above. These keep
159
- working as they always have; reach for the tokens above instead when the
160
- easing has to be anything other than `ease`. The page transitions in
161
- `view-transitions` compose the two on purpose — a page arriving decelerates
162
- and a page leaving accelerates — so they are not a shorthand case. */
163
126
  --iw-transition-fast: var(--iw-duration-fast) ease;
164
127
  --iw-transition-normal: var(--iw-duration-normal) ease;
165
128
  --iw-transition-page: var(--iw-duration-page) ease;
166
129
  --iw-transition-slow: var(--iw-duration-slow) ease;
167
130
 
168
- /* ========================================
169
- Z-INDEX SCALE
170
- ======================================== */
171
131
  --iw-z-dropdown: 1000;
172
132
  --iw-z-sticky: 1020;
173
133
  --iw-z-fixed: 1030;
@@ -11,8 +11,6 @@
11
11
  border-top: 1px solid var(--iw-color-border);
12
12
  }
13
13
 
14
- /* A <summary>: flex drops the browser's disclosure marker, and the caret
15
- stands in for it. */
16
14
  .iw-accordion-trigger {
17
15
  padding: var(--iw-space-3) var(--iw-space-4);
18
16
  display: flex;
@@ -86,12 +86,9 @@ export const Accordion = {
86
86
  name=${props.name || nothing}
87
87
  .open=${isExpanded}
88
88
  @toggle=${(event) => {
89
- // newState is what the browser says; an environment whose toggle
90
- // event lacks it, such as jsdom, still has the element's own state.
91
89
  const isOpen = event.newState
92
90
  ? event.newState === "open"
93
91
  : event.currentTarget.open
94
- // Also fires when isExpanded opened it, which needs no report.
95
92
  if (isOpen === isExpanded) return
96
93
  onToggle?.(item, index, isOpen)
97
94
  props.onItemToggle?.(item, index, isOpen)
@@ -101,7 +98,6 @@ export const Accordion = {
101
98
  class="iw-accordion-trigger"
102
99
  aria-disabled=${isDisabled ? "true" : nothing}
103
100
  @click=${(event) => {
104
- // A summary cannot be disabled, so its toggle is refused instead.
105
101
  if (isDisabled) event.preventDefault()
106
102
  }}
107
103
  >
@@ -2,9 +2,6 @@
2
2
  display: flex;
3
3
  align-items: center;
4
4
  min-height: var(--iw-space-16);
5
- /* gap: var(--iw-space-3); */
6
- /* Room either side of the title and controls, so they do not touch the
7
- edges of the screen. */
8
5
  padding-inline: var(--iw-space-4);
9
6
  background: var(--iw-app-bar-bg, var(--iw-color-surface));
10
7
  color: var(--iw-color-text);
@@ -11,15 +11,12 @@
11
11
  transform var(--iw-transition-normal);
12
12
  }
13
13
 
14
- /* Set into the page rather than raised from it, for content grouped inside
15
- another surface. */
16
14
  .iw-card-sunk {
17
15
  background-color: var(--iw-color-bg-secondary, var(--iw-card-bg));
18
16
  border-color: transparent;
19
17
  box-shadow: none;
20
18
  }
21
19
 
22
- /* Only the grouping: no surface at all. */
23
20
  .iw-card-clear {
24
21
  background-color: transparent;
25
22
  border-color: transparent;
@@ -1,10 +1,12 @@
1
1
  import type { TemplateResult } from "@inglorious/web"
2
2
 
3
+ import type { Renderable } from "../shared/renderable"
4
+
3
5
  export interface ButtonGroupItem {
4
6
  id?: string
5
7
  value?: string
6
8
  label: string
7
- children?: TemplateResult | string | number
9
+ children?: Renderable
8
10
  isDisabled?: boolean
9
11
  variant?: "default" | "outline" | "ghost"
10
12
  color?:
@@ -16,8 +18,8 @@ export interface ButtonGroupItem {
16
18
  | "error"
17
19
  | "info"
18
20
  size?: "sm" | "md" | "lg"
19
- icon?: string
20
- iconAfter?: string
21
+ icon?: TemplateResult | string
22
+ iconAfter?: TemplateResult | string
21
23
  [key: string]: unknown
22
24
  }
23
25
 
@@ -1,9 +1,11 @@
1
1
  import type { TemplateResult } from "@inglorious/web"
2
2
 
3
+ import type { Renderable } from "../shared/renderable"
4
+
3
5
  export interface ButtonProps {
4
6
  id?: string
5
7
  type?: string
6
- children?: TemplateResult | string | number
8
+ children?: Renderable
7
9
  variant?: "default" | "outline" | "ghost"
8
10
  color?:
9
11
  | "default"
@@ -70,3 +70,16 @@ export type ComboboxType = {
70
70
  }
71
71
 
72
72
  export declare const Combobox: ComboboxType
73
+
74
+ export declare function getOptionValue(option: ComboboxOption): string | number
75
+ export declare function getOptionLabel(option: ComboboxOption): string
76
+ export declare function formatOption(option: ComboboxOption): ComboboxOption
77
+ export declare function isOptionSelected(
78
+ option: ComboboxOption,
79
+ selectedValue: ComboboxProps["selectedValue"],
80
+ isMulti?: boolean,
81
+ ): boolean
82
+ export declare function filterOptions(
83
+ options: ComboboxOption[],
84
+ searchTerm: string,
85
+ ): ComboboxOption[]
@@ -16,7 +16,7 @@ export interface FabProps {
16
16
  type?: "button" | "submit" | "reset" | "menu"
17
17
  isExtended?: boolean
18
18
  ariaLabel?: string
19
- onClick?: () => void
19
+ onClick?: (event: MouseEvent) => void
20
20
  [key: string]: unknown
21
21
  }
22
22