@tangible/ui 0.2.36 → 0.2.37
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.
- package/components/SearchInput/SearchInput.d.ts +2 -0
- package/components/SearchInput/SearchInput.js +34 -12
- package/components/SearchInput/types.d.ts +24 -0
- package/figma-tokens.json +1 -1
- package/icons/icons.svg +19 -1
- package/icons/manifest.json +144 -0
- package/icons/registry.d.ts +36 -0
- package/icons/registry.js +18 -0
- package/icons/sprite-registry.js +18 -0
- package/icons/sprite-version.js +1 -1
- package/icons/sprite.php +1 -1
- package/icons/system/index.d.ts +36 -0
- package/icons/system/index.js +198 -0
- package/icons/system.svg +18 -0
- package/package.json +1 -1
- package/styles/all.css +1 -1
- package/styles/all.expanded.css +49 -3
- package/styles/all.expanded.unlayered.css +49 -3
- package/styles/all.unlayered.css +1 -1
- package/styles/components/nav-menu.scss +9 -3
- package/styles/components/search-input.scss +66 -0
- package/styles/components/table.scss +3 -2
- package/tui-manifest.json +20 -5
|
@@ -149,7 +149,11 @@ $_knob-defaults: (
|
|
|
149
149
|
// --tui-nav-menu-bar-item-* (top-level bar rows)
|
|
150
150
|
// --tui-nav-menu-flyout-item-* (rows in a flyout panel; fg
|
|
151
151
|
// defaults to the panel's fg)
|
|
152
|
-
// --tui-nav-menu-icon-size Icon size (default:
|
|
152
|
+
// --tui-nav-menu-icon-size Icon and chevron size (default: 1.25em
|
|
153
|
+
// of the row font, Button's icon:label
|
|
154
|
+
// ratio: 20px on a 16px row. The glyphs
|
|
155
|
+
// fill the middle 16 of a 24 box, so
|
|
156
|
+
// 16px drew them at ~10.7px)
|
|
153
157
|
// --tui-nav-menu-indicator-width Current-item indicator. Opt-in: 0 by
|
|
154
158
|
// default. Vertical: a leading bar on
|
|
155
159
|
// the page (try 3px). Horizontal: an
|
|
@@ -296,7 +300,7 @@ $_knob-defaults: (
|
|
|
296
300
|
:where(.#{sys.$prefix}interface) .#{sys.$prefix}nav-menu__icon {
|
|
297
301
|
display: inline-flex;
|
|
298
302
|
flex: none;
|
|
299
|
-
font-size: var(--#{sys.$prefix}nav-menu-icon-size,
|
|
303
|
+
font-size: var(--#{sys.$prefix}nav-menu-icon-size, 1.25em);
|
|
300
304
|
}
|
|
301
305
|
|
|
302
306
|
:where(.#{sys.$prefix}interface) .#{sys.$prefix}nav-menu__label {
|
|
@@ -400,7 +404,7 @@ $_knob-defaults: (
|
|
|
400
404
|
:where(.#{sys.$prefix}interface) .#{sys.$prefix}nav-menu__chevron {
|
|
401
405
|
display: inline-flex;
|
|
402
406
|
flex: none;
|
|
403
|
-
font-size: var(--#{sys.$prefix}nav-menu-icon-size,
|
|
407
|
+
font-size: var(--#{sys.$prefix}nav-menu-icon-size, 1.25em);
|
|
404
408
|
transition: transform var(--#{sys.$prefix}motion-duration) var(--#{sys.$prefix}motion-timing);
|
|
405
409
|
}
|
|
406
410
|
|
|
@@ -419,6 +423,8 @@ $_knob-defaults: (
|
|
|
419
423
|
margin: 0;
|
|
420
424
|
padding-inline: var(--#{sys.$prefix}spacing-xxs);
|
|
421
425
|
border: 0;
|
|
426
|
+
// Same font as its row, so the chevron's em-based size matches the row's.
|
|
427
|
+
font-size: var(--#{sys.$prefix}nav-menu-item-font-size, var(--#{sys.$prefix}typography-size-md));
|
|
422
428
|
border-radius: var(--#{sys.$prefix}nav-menu-item-radius, var(--#{sys.$prefix}radius-sm));
|
|
423
429
|
// Only ever in the bar, so it reads the bar knobs like its row.
|
|
424
430
|
@include _item-knobs(bar);
|
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
/* @tui-tokens
|
|
4
4
|
--tui-search-input-button-radius
|
|
5
|
+
--tui-search-input-suffix-gap
|
|
6
|
+
--tui-search-input-shortcut-fg
|
|
7
|
+
--tui-search-input-shortcut-bg
|
|
8
|
+
--tui-search-input-shortcut-border
|
|
9
|
+
--tui-search-input-shortcut-radius
|
|
5
10
|
*/
|
|
6
11
|
|
|
7
12
|
// =============================================================================
|
|
@@ -16,6 +21,10 @@
|
|
|
16
21
|
//
|
|
17
22
|
// Component API tokens (never defined here, only read via fallback):
|
|
18
23
|
// --tui-search-input-button-radius Clear/submit button hit-area radius
|
|
24
|
+
// --tui-search-input-suffix-gap Space between `suffix` content and the
|
|
25
|
+
// clear button / shortcut hint
|
|
26
|
+
// --tui-search-input-shortcut-fg / -bg / -border / -radius
|
|
27
|
+
// The `shortcut` hint's <kbd> chip
|
|
19
28
|
//
|
|
20
29
|
// =============================================================================
|
|
21
30
|
|
|
@@ -33,6 +42,9 @@
|
|
|
33
42
|
// still sizes with the control text inside the padded box.
|
|
34
43
|
min-inline-size: 1.5rem;
|
|
35
44
|
min-block-size: 1.5rem;
|
|
45
|
+
// ...and eat the group's padding-block, so the 24px floor doesn't push a
|
|
46
|
+
// sm field to 34px against the 32px control ladder (SecretInput does the same).
|
|
47
|
+
margin-block: calc(-1 * var(--_py));
|
|
36
48
|
padding: 0.1875em;
|
|
37
49
|
border: 0;
|
|
38
50
|
border-radius: var(--#{sys.$prefix}search-input-button-radius, var(--#{sys.$prefix}radius-full, 999px));
|
|
@@ -101,4 +113,58 @@
|
|
|
101
113
|
color: var(--#{sys.$prefix}color-fg);
|
|
102
114
|
}
|
|
103
115
|
}
|
|
116
|
+
|
|
117
|
+
// Trailing slot: consumer `suffix` content, then the clear button or the
|
|
118
|
+
// shortcut hint. Adds a gap the shared slot rule doesn't set; full
|
|
119
|
+
// specificity per the host-rule convention.
|
|
120
|
+
.#{sys.$prefix}interface .#{sys.$prefix}search-input > .#{sys.$prefix}input-group__suffix {
|
|
121
|
+
gap: var(--#{sys.$prefix}search-input-suffix-gap, var(--#{sys.$prefix}spacing-xxs));
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
// Consumer suffix content: the shared slot only re-enables pointer events for
|
|
125
|
+
// buttons and links, so a select or switch here would swallow clicks.
|
|
126
|
+
.#{sys.$prefix}interface .#{sys.$prefix}search-input__suffix {
|
|
127
|
+
display: inline-flex;
|
|
128
|
+
align-items: center;
|
|
129
|
+
gap: var(--#{sys.$prefix}search-input-suffix-gap, var(--#{sys.$prefix}spacing-xxs));
|
|
130
|
+
pointer-events: auto;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
// Hint and clear button stacked in one cell: the slot is as wide as the
|
|
134
|
+
// wider one whichever is showing, so the input never reflows.
|
|
135
|
+
.#{sys.$prefix}interface .#{sys.$prefix}search-input__trailing {
|
|
136
|
+
display: inline-grid;
|
|
137
|
+
align-items: center;
|
|
138
|
+
justify-items: end;
|
|
139
|
+
|
|
140
|
+
> * {
|
|
141
|
+
grid-area: 1 / 1;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
// Shortcut hint (e.g. ⌘K). Decorative and aria-hidden, but it still carries
|
|
146
|
+
// information for sighted users, so its text keeps fg-secondary rather than a
|
|
147
|
+
// muted tone. Full specificity with explicit margin/font resets: wp-admin
|
|
148
|
+
// styles bare `kbd` (padding, margin, background, 13px).
|
|
149
|
+
.#{sys.$prefix}interface .#{sys.$prefix}search-input__shortcut {
|
|
150
|
+
display: inline-flex;
|
|
151
|
+
align-items: center;
|
|
152
|
+
margin: 0;
|
|
153
|
+
padding-block: 0;
|
|
154
|
+
padding-inline: 0.375em;
|
|
155
|
+
border: var(--#{sys.$prefix}border-width) solid var(--#{sys.$prefix}search-input-shortcut-border, var(--#{sys.$prefix}color-border));
|
|
156
|
+
border-radius: var(--#{sys.$prefix}search-input-shortcut-radius, var(--#{sys.$prefix}radius-sm));
|
|
157
|
+
background: var(--#{sys.$prefix}search-input-shortcut-bg, var(--#{sys.$prefix}color-fill-subtle));
|
|
158
|
+
color: var(--#{sys.$prefix}search-input-shortcut-fg, var(--#{sys.$prefix}color-fg-secondary));
|
|
159
|
+
font: inherit;
|
|
160
|
+
font-size: 0.75em;
|
|
161
|
+
line-height: 1.5;
|
|
162
|
+
white-space: nowrap;
|
|
163
|
+
pointer-events: none;
|
|
164
|
+
|
|
165
|
+
@media (forced-colors: active) {
|
|
166
|
+
border-color: CanvasText;
|
|
167
|
+
color: CanvasText;
|
|
168
|
+
}
|
|
169
|
+
}
|
|
104
170
|
}
|
|
@@ -18,7 +18,8 @@
|
|
|
18
18
|
// Component API tokens (never defined here, only read via fallback):
|
|
19
19
|
// --tui-table-border Border color
|
|
20
20
|
// --tui-table-bg Background color
|
|
21
|
-
// --tui-table-bg-head Header background
|
|
21
|
+
// --tui-table-bg-head Header and footer background (default: bg-muted, so
|
|
22
|
+
// the head reads as one on tinted pages too)
|
|
22
23
|
// --tui-table-fg Text color (header/footer always; body inherits unless set)
|
|
23
24
|
// --tui-table-selected-bg Selected row background
|
|
24
25
|
// --tui-table-selected-fg Selected row text color
|
|
@@ -36,7 +37,7 @@
|
|
|
36
37
|
// subtle when contexts darken --tui-color-border for control contrast.
|
|
37
38
|
--_border: var(--#{sys.$prefix}table-border, var(--#{sys.$prefix}color-divider));
|
|
38
39
|
--_bg: var(--#{sys.$prefix}table-bg, transparent);
|
|
39
|
-
--_bg-head: var(--#{sys.$prefix}table-bg-head, var(--#{sys.$prefix}color-bg-
|
|
40
|
+
--_bg-head: var(--#{sys.$prefix}table-bg-head, var(--#{sys.$prefix}color-bg-muted));
|
|
40
41
|
--_fg: var(--#{sys.$prefix}table-fg, var(--#{sys.$prefix}color-fg));
|
|
41
42
|
--_padding: var(--#{sys.$prefix}table-padding, var(--#{sys.$prefix}spacing-sm));
|
|
42
43
|
|
package/tui-manifest.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.2.
|
|
3
|
-
"generated": "2026-11-
|
|
2
|
+
"version": "0.2.37",
|
|
3
|
+
"generated": "2026-11-19T19:56:48.924Z",
|
|
4
4
|
"components": {
|
|
5
5
|
"Accordion": {
|
|
6
6
|
"props": {
|
|
@@ -2928,10 +2928,25 @@
|
|
|
2928
2928
|
"type": "ReactNode",
|
|
2929
2929
|
"required": false,
|
|
2930
2930
|
"description": "Override the leading icon. Defaults to the `system/search` glyph."
|
|
2931
|
+
},
|
|
2932
|
+
"suffix": {
|
|
2933
|
+
"type": "ReactNode",
|
|
2934
|
+
"required": false,
|
|
2935
|
+
"description": "Trailing content, placed before the clear button (e.g. a filter toggle or a\nresult count).\n@remarks Rendered as given and NOT hidden from assistive tech, so a control\nplaced here must carry its own accessible name. Size a Button/IconButton one\ntier below the field. For a keyboard-shortcut hint use `shortcut` instead,\nwhich is decorative. A string renders as plain text beside the clear\nbutton, not as TextInput's boxed `.is-text` addon."
|
|
2936
|
+
},
|
|
2937
|
+
"shortcut": {
|
|
2938
|
+
"type": "string",
|
|
2939
|
+
"required": false,
|
|
2940
|
+
"description": "Keyboard-shortcut hint shown at the trailing edge, e.g. `'⌘K'` or `'/'`.\n@remarks Decorative: rendered as an `aria-hidden` `<kbd>`, only while the\nfield is empty and enabled; the clear button takes its place once there is\na value. Announce the shortcut itself with `aria-keyshortcuts` on the field\n(e.g. `aria-keyshortcuts=\"Meta+K\"`), which SearchInput passes through.\nKeep the two in step: nothing links them.\n\nSearchInput does not bind the key. Listen for it yourself and focus the\nfield through its ref."
|
|
2931
2941
|
}
|
|
2932
2942
|
},
|
|
2933
2943
|
"cssTokens": [
|
|
2934
|
-
"--tui-search-input-button-radius"
|
|
2944
|
+
"--tui-search-input-button-radius",
|
|
2945
|
+
"--tui-search-input-suffix-gap",
|
|
2946
|
+
"--tui-search-input-shortcut-fg",
|
|
2947
|
+
"--tui-search-input-shortcut-bg",
|
|
2948
|
+
"--tui-search-input-shortcut-border",
|
|
2949
|
+
"--tui-search-input-shortcut-radius"
|
|
2935
2950
|
],
|
|
2936
2951
|
"story": {
|
|
2937
2952
|
"title": "Forms/SearchInput",
|
|
@@ -4381,9 +4396,9 @@
|
|
|
4381
4396
|
"membersync": 22,
|
|
4382
4397
|
"player": 24,
|
|
4383
4398
|
"reaction": 36,
|
|
4384
|
-
"system":
|
|
4399
|
+
"system": 141
|
|
4385
4400
|
},
|
|
4386
|
-
"total":
|
|
4401
|
+
"total": 280,
|
|
4387
4402
|
"manifest": "./icons/manifest.json"
|
|
4388
4403
|
}
|
|
4389
4404
|
}
|