@apliteni/apliteni-ui 0.196.1 → 0.197.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.
- package/docs/components.md +11 -3
- package/docs/foundations.md +9 -4
- package/guidelines/button-labels.md +1 -1
- package/guidelines/component-choice.md +4 -4
- package/package.json +1 -1
- package/react/dist/index.css +11 -1
- package/react/dist/index.js +17 -4
- package/src/styles/callout.css +5 -2
- package/src/styles/card.css +6 -2
- package/src/styles/code.css +3 -0
- package/src/styles/command-palette.css +5 -2
- package/src/styles/confirm.css +4 -1
- package/src/styles/dropdown.css +38 -13
- package/src/styles/feedback.css +7 -4
- package/src/styles/input.css +10 -5
- package/src/styles/layout.css +6 -2
- package/src/styles/pagination.css +5 -1
- package/src/styles/success.css +4 -1
- package/src/styles/tooltip.css +4 -1
- package/src/styles/topbar.css +6 -3
package/docs/components.md
CHANGED
|
@@ -596,8 +596,15 @@ picker or by drop. `accept` only filters the system picker, so check the file be
|
|
|
596
596
|
**`Field` with your own control.** The child function gets the `id`, `required`, `aria-invalid`
|
|
597
597
|
and `aria-describedby`. Spread them on the control. A dropdown or date picker trigger then has the
|
|
598
598
|
label and the value as its name, and the error gives it the invalid edge. In a field, a dropdown
|
|
599
|
-
trigger has the height of a text input and keeps the pill corner.
|
|
600
|
-
|
|
599
|
+
trigger has the height of a text input and keeps the pill corner. It fits its longest option up to
|
|
600
|
+
the field width, so a value change does not change its width. A native select has the same width
|
|
601
|
+
rule. In vanilla markup, put the placeholder and each option's shown words, with its state
|
|
602
|
+
word, in the hidden `ui-dropdown__fit` element. A long
|
|
603
|
+
value stays on one line and ends with an ellipsis.
|
|
604
|
+
|
|
605
|
+
**Corners.** A one-line field has the 16px field corner. A text area and message box have the
|
|
606
|
+
24px message corner. Cards and floating panels have the 12px surface corner. Where supported,
|
|
607
|
+
these corners use the squircle shape. Other browsers use round corners.
|
|
601
608
|
|
|
602
609
|
**A list of options in `SelectField`.** The browser draws the open list, so the kit does not
|
|
603
610
|
style an `<option>`. For an option that the user can still pick but that is no longer current,
|
|
@@ -1119,7 +1126,8 @@ destructive question.
|
|
|
1119
1126
|
```
|
|
1120
1127
|
|
|
1121
1128
|
**What the user sees.** A raised surface over a deep scrim, at most 96% of the viewport high. The
|
|
1122
|
-
body scrolls
|
|
1129
|
+
body scrolls and is a keyboard stop, so a keyboard reader can reach it with Tab and scroll it. The
|
|
1130
|
+
title, the close control and the footer stay visible. The title is an `h2`.
|
|
1123
1131
|
`initialFocusRef` chooses the first focus.
|
|
1124
1132
|
|
|
1125
1133
|
`size="sm"` gives a 360px panel for a short sign-in form. Without `size`, Modal uses its default
|
package/docs/foundations.md
CHANGED
|
@@ -78,10 +78,15 @@ bar, a wordless button takes the row's height and stays a circle. The kit's padd
|
|
|
78
78
|
glyphs, units and the focus ring inside the rounded edge. Give a control of your own the same
|
|
79
79
|
corner.
|
|
80
80
|
|
|
81
|
-
**Every field that a reader types into has the field corner, `--radius-
|
|
82
|
-
field, a search field of each size, the search field in a dropdown panel
|
|
83
|
-
|
|
84
|
-
but it keeps the pill
|
|
81
|
+
**Every one-line field that a reader types into has the field corner, `--radius-lg`.** This covers
|
|
82
|
+
a text field, a search field of each size, the search field in a dropdown panel and the page
|
|
83
|
+
field of a pager. A text area and message box use `--radius-2xl`. In a form, a dropdown trigger
|
|
84
|
+
has the height of the text field beside it, but it keeps the pill and fits its longest option up to
|
|
85
|
+
the field width. Give a field of your own the same corner.
|
|
86
|
+
|
|
87
|
+
**Cards and floating panels use `--radius-md`.** This includes dialogs, dropdown panels, menus,
|
|
88
|
+
callouts, toasts, success surfaces, code blocks and hover readouts. The round corner is the
|
|
89
|
+
fallback. Where the browser supports it, these surfaces and typed fields use a squircle corner.
|
|
85
90
|
|
|
86
91
|
These parts keep another corner:
|
|
87
92
|
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
|
|
55
55
|
**Why:** One shape marks what a reader can use.
|
|
56
56
|
|
|
57
|
-
**Except:** A
|
|
57
|
+
**Except:** A typed field has its field corner because it holds text.
|
|
58
58
|
|
|
59
59
|
**Do:** A search field with the field corner beside pill buttons.
|
|
60
60
|
|
|
@@ -86,12 +86,12 @@
|
|
|
86
86
|
|
|
87
87
|
<!-- rule: dropdown-search -->
|
|
88
88
|
|
|
89
|
-
**Rule:** Give a dropdown a search field at ten options, or whenever its options come from data.
|
|
89
|
+
**Rule:** Give a dropdown a search field at ten options, or whenever its options come from data, and size a form dropdown or native select to its longest option up to the field width.
|
|
90
90
|
|
|
91
|
-
**Why:** Ten options
|
|
91
|
+
**Why:** Ten options need scrolling, and data lists need search; matching finds later words.
|
|
92
92
|
|
|
93
|
-
**Except:** Below six options, search adds
|
|
93
|
+
**Except:** Below six options, search adds a stop. At six to nine, authors decide.
|
|
94
94
|
|
|
95
|
-
**Do:** For
|
|
95
|
+
**Do:** For 29 currencies, type “dollar”.
|
|
96
96
|
|
|
97
97
|
**Don't:** Show only seven of twenty-nine currencies without search when dollars are scattered through the list.
|
package/package.json
CHANGED
package/react/dist/index.css
CHANGED
|
@@ -211,7 +211,7 @@
|
|
|
211
211
|
background: var(--ui-tip-bg);
|
|
212
212
|
border: 1px solid var(--float-edge);
|
|
213
213
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
214
|
-
border-radius: var(--radius-
|
|
214
|
+
border-radius: var(--radius-md);
|
|
215
215
|
font-family: var(--font-sans);
|
|
216
216
|
font-size: var(--text-xs);
|
|
217
217
|
line-height: 1.45;
|
|
@@ -222,6 +222,11 @@
|
|
|
222
222
|
visibility: hidden;
|
|
223
223
|
transition: opacity var(--dur-fast) var(--ease), visibility var(--dur-fast) linear;
|
|
224
224
|
}
|
|
225
|
+
@supports (corner-shape: squircle) {
|
|
226
|
+
.ui-tip {
|
|
227
|
+
corner-shape: squircle;
|
|
228
|
+
}
|
|
229
|
+
}
|
|
225
230
|
.ui-tip.is-below {
|
|
226
231
|
translate: -50% var(--ui-tip-gap);
|
|
227
232
|
}
|
|
@@ -290,6 +295,11 @@
|
|
|
290
295
|
.rx-scrim.is-open .rx-modal {
|
|
291
296
|
transform: none;
|
|
292
297
|
}
|
|
298
|
+
@supports (corner-shape: squircle) {
|
|
299
|
+
.rx-modal {
|
|
300
|
+
corner-shape: squircle;
|
|
301
|
+
}
|
|
302
|
+
}
|
|
293
303
|
.rx-modal--sm {
|
|
294
304
|
width: min(calc(var(--panel-sm) + var(--space-10)), 96vw);
|
|
295
305
|
}
|
package/react/dist/index.js
CHANGED
|
@@ -1040,9 +1040,9 @@ function Modal({ open, title, onClose, footer, children, initialFocusRef, role =
|
|
|
1040
1040
|
children: [
|
|
1041
1041
|
/* @__PURE__ */ jsxs9("div", { className: "rx-modal__head", children: [
|
|
1042
1042
|
/* @__PURE__ */ jsx13("h2", { className: "rx-modal__title", id: titleId, children: title }),
|
|
1043
|
-
/* @__PURE__ */ jsx13(Button, { variant: "ghost", size: "sm", iconOnly: true, icon: "x", "aria-label": "Close", onClick: onClose })
|
|
1043
|
+
/* @__PURE__ */ jsx13(Button, { variant: "ghost", size: "sm", iconOnly: true, icon: "x", "aria-label": "Close", title: "Close", onClick: onClose })
|
|
1044
1044
|
] }),
|
|
1045
|
-
/* @__PURE__ */ jsx13("div", { className: "rx-modal__body", id: bodyId, ref: body, children }),
|
|
1045
|
+
/* @__PURE__ */ jsx13("div", { className: "rx-modal__body", id: bodyId, ref: body, tabIndex: 0, children }),
|
|
1046
1046
|
footer && /* @__PURE__ */ jsx13("div", { className: "rx-modal__foot", children: footer })
|
|
1047
1047
|
]
|
|
1048
1048
|
}
|
|
@@ -3222,6 +3222,7 @@ function Dropdown({
|
|
|
3222
3222
|
const auto = useId12().replace(/:/g, "");
|
|
3223
3223
|
const uid = id ?? auto;
|
|
3224
3224
|
const inField = useContext3(FieldContext);
|
|
3225
|
+
const inForm = Boolean(inField && id === inField.id);
|
|
3225
3226
|
const fieldName = inField && id === inField.id && !(ariaLabel && triggerContent != null) ? { id: `${uid}-trigger`, labelId: inField.labelId, labelledBy: `${inField.labelId} ${uid}-trigger` } : null;
|
|
3226
3227
|
const byContent = !fieldName && !ariaLabel && triggerContent != null ? `${uid}-trigger` : void 0;
|
|
3227
3228
|
const setOpen = useCallback6((next) => {
|
|
@@ -3665,12 +3666,24 @@ function Dropdown({
|
|
|
3665
3666
|
setOpen(!open);
|
|
3666
3667
|
},
|
|
3667
3668
|
children: [
|
|
3668
|
-
triggerContent != null ? typeof triggerContent === "string" ? /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__text", children: triggerContent }) : triggerContent : /* @__PURE__ */ jsxs22(
|
|
3669
|
+
triggerContent != null ? typeof triggerContent === "string" ? /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__text", children: triggerContent }) : triggerContent : /* @__PURE__ */ jsxs22("span", { className: "ui-dropdown__line", children: [
|
|
3669
3670
|
marked2 && (chosen?.avatar ? /* @__PURE__ */ jsx26(Avatar, { personKey: chosen.avatar.key, name: chosen.avatar.name, src: chosen.avatar.src, empty: chosen.avatar.empty }) : /* @__PURE__ */ jsx26(Avatar, { empty: true })),
|
|
3670
3671
|
label && /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__pre", children: label }),
|
|
3671
3672
|
/* @__PURE__ */ jsx26("span", { className: cx6("ui-dropdown__value", marked2 && !chosen && "is-placeholder"), children: shown != null ? shown : placeholder })
|
|
3672
3673
|
] }),
|
|
3673
|
-
chevron && /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__chevron", "aria-hidden": "true" })
|
|
3674
|
+
chevron && /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__chevron", "aria-hidden": "true" }),
|
|
3675
|
+
inForm && isSelect && /* @__PURE__ */ jsxs22("span", { className: "ui-dropdown__fit", "aria-hidden": "true", children: [
|
|
3676
|
+
/* @__PURE__ */ jsxs22("span", { className: "ui-dropdown__line", children: [
|
|
3677
|
+
marked2 && /* @__PURE__ */ jsx26(Avatar, { empty: true }),
|
|
3678
|
+
label && /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__pre", children: label }),
|
|
3679
|
+
/* @__PURE__ */ jsx26("span", { className: cx6("ui-dropdown__value", marked2 && "is-placeholder"), children: placeholder })
|
|
3680
|
+
] }),
|
|
3681
|
+
rows.map((item, index) => /* @__PURE__ */ jsxs22("span", { className: "ui-dropdown__line", children: [
|
|
3682
|
+
marked2 && (item.avatar ? /* @__PURE__ */ jsx26(Avatar, { personKey: item.avatar.key, name: item.avatar.name, src: item.avatar.src, empty: item.avatar.empty }) : /* @__PURE__ */ jsx26(Avatar, { empty: true })),
|
|
3683
|
+
label && /* @__PURE__ */ jsx26("span", { className: "ui-dropdown__pre", children: label }),
|
|
3684
|
+
/* @__PURE__ */ jsx26("span", { className: "ui-dropdown__value", children: shownOf(item) })
|
|
3685
|
+
] }, index))
|
|
3686
|
+
] })
|
|
3674
3687
|
]
|
|
3675
3688
|
}
|
|
3676
3689
|
),
|
package/src/styles/callout.css
CHANGED
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
align-items: flex-start; /* every part centres on the first line: a glyph or a button never drifts to the middle of a wrapped text */
|
|
40
40
|
gap: 12px;
|
|
41
41
|
padding: var(--space-3);
|
|
42
|
-
border-radius: var(--radius-
|
|
42
|
+
border-radius: var(--radius-md);
|
|
43
43
|
color: var(--text);
|
|
44
44
|
font-size: var(--text-base);
|
|
45
45
|
width: 100%;
|
|
@@ -128,7 +128,7 @@
|
|
|
128
128
|
|
|
129
129
|
/* Success panel — centered confirmation, used after form submit */
|
|
130
130
|
.ui-success {
|
|
131
|
-
border-radius: var(--radius-
|
|
131
|
+
border-radius: var(--radius-md);
|
|
132
132
|
padding: 30px;
|
|
133
133
|
text-align: center;
|
|
134
134
|
background: var(--glow-green); /* code-bg: inherit — a wash paints over a ground and behind a chip, so the opaque ground below it is the step. */
|
|
@@ -138,6 +138,9 @@
|
|
|
138
138
|
width: 28px; height: 28px;
|
|
139
139
|
margin: 0 auto 14px;
|
|
140
140
|
}
|
|
141
|
+
@supports (corner-shape: squircle) {
|
|
142
|
+
.ui-callout, .ui-toast, .ui-success { corner-shape: squircle; }
|
|
143
|
+
}
|
|
141
144
|
.ui-success__check .ui-sx__check { width: 100%; height: 100%; }
|
|
142
145
|
/* `circled` is one status size everywhere, this panel included: the box narrows to
|
|
143
146
|
the 20px success() draws it at, rather than stretching a status mark to fill the
|
package/src/styles/card.css
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
background: var(--surface);
|
|
15
15
|
border: 1px solid var(--card-edge);
|
|
16
16
|
box-shadow: var(--elev-rest);
|
|
17
|
-
border-radius: var(--radius-
|
|
17
|
+
border-radius: var(--radius-md);
|
|
18
18
|
padding: var(--space-6);
|
|
19
19
|
position: relative;
|
|
20
20
|
}
|
|
@@ -134,7 +134,7 @@
|
|
|
134
134
|
max-height: none;
|
|
135
135
|
/* With the scroll box's own 4px band at the sides and bottom, an even 24px inset. */
|
|
136
136
|
padding: var(--space-6) var(--space-5) var(--space-5);
|
|
137
|
-
border-radius: 0 0 calc(var(--radius-
|
|
137
|
+
border-radius: 0 0 calc(var(--radius-md) - 1px) calc(var(--radius-md) - 1px);
|
|
138
138
|
}
|
|
139
139
|
/* A4 at the least, so a short document still reads as a page and not as a panel.
|
|
140
140
|
The page carries the light palette in both themes (src/tokens/tokens.css), so its
|
|
@@ -154,6 +154,10 @@
|
|
|
154
154
|
--table-code-bg: var(--code-chip-surface);
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
+
@supports (corner-shape: squircle) {
|
|
158
|
+
.ui-card, .ui-card__viewer > .ui-table-scroll { corner-shape: squircle; }
|
|
159
|
+
}
|
|
160
|
+
|
|
157
161
|
/* Interactive card (link / button semantics) */
|
|
158
162
|
.ui-card--interactive {
|
|
159
163
|
cursor: pointer;
|
package/src/styles/code.css
CHANGED
|
@@ -12,6 +12,9 @@
|
|
|
12
12
|
block holds the button in flow beside the code. */
|
|
13
13
|
position: relative;
|
|
14
14
|
}
|
|
15
|
+
@supports (corner-shape: squircle) {
|
|
16
|
+
.ui-snippet { corner-shape: squircle; }
|
|
17
|
+
}
|
|
15
18
|
/* #850: with no title the copy button reserves its own space instead of floating
|
|
16
19
|
over the code, so a short command is never covered at any width. The block is a
|
|
17
20
|
flex row: the code grows, and the button sits at the row's end. */
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
why: docs/foundations.md#elevation */
|
|
76
76
|
border: 1px solid var(--float-edge);
|
|
77
77
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
78
|
-
border-radius: var(--radius-
|
|
78
|
+
border-radius: var(--radius-md);
|
|
79
79
|
overflow: hidden;
|
|
80
80
|
opacity: 0;
|
|
81
81
|
transform: translate(-50%, -8px);
|
|
@@ -98,13 +98,16 @@
|
|
|
98
98
|
padding: 0 var(--space-4);
|
|
99
99
|
border-bottom: 1px solid var(--border);
|
|
100
100
|
/* The panel's inner corner, so the inward ring follows it. */
|
|
101
|
-
border-radius: calc(var(--radius-
|
|
101
|
+
border-radius: calc(var(--radius-md) - 1px) calc(var(--radius-md) - 1px) 0 0;
|
|
102
102
|
}
|
|
103
103
|
.ui-cmdk__search-ic {
|
|
104
104
|
display: inline-flex;
|
|
105
105
|
/* muted-ink: glyph — search icon */ color: var(--muted);
|
|
106
106
|
flex: none;
|
|
107
107
|
}
|
|
108
|
+
@supports (corner-shape: squircle) {
|
|
109
|
+
.ui-cmdk__panel, .ui-cmdk__search { corner-shape: squircle; }
|
|
110
|
+
}
|
|
108
111
|
/* 2.2 of a 24 box drawn at 17px = 1.56 CSS px, which is what keeps the mark a
|
|
109
112
|
graphic rather than a smudge. why: docs/foundations.md#icons-and-glyphs */
|
|
110
113
|
.ui-cmdk__search-ic svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 2.2; }
|
package/src/styles/confirm.css
CHANGED
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
why: docs/foundations.md#elevation */
|
|
69
69
|
border: 1px solid var(--float-edge);
|
|
70
70
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
71
|
-
border-radius: var(--radius-
|
|
71
|
+
border-radius: var(--radius-md);
|
|
72
72
|
opacity: 0;
|
|
73
73
|
transform: translateY(8px);
|
|
74
74
|
transition:
|
|
@@ -76,6 +76,9 @@
|
|
|
76
76
|
transform var(--dur-med) var(--ease);
|
|
77
77
|
}
|
|
78
78
|
.ui-confirm.is-open .ui-confirm__panel { opacity: 1; transform: none; }
|
|
79
|
+
@supports (corner-shape: squircle) {
|
|
80
|
+
.ui-confirm__panel { corner-shape: squircle; }
|
|
81
|
+
}
|
|
79
82
|
/* The ring leaves the panel's own elevation alone: it is an outline since #578, so
|
|
80
83
|
it no longer has to be composed into the box-shadow list that carries the edge and
|
|
81
84
|
the drop — and the list no longer has to be restated here to survive focus.
|
package/src/styles/dropdown.css
CHANGED
|
@@ -184,7 +184,7 @@
|
|
|
184
184
|
why: docs/foundations.md#elevation */
|
|
185
185
|
border: 1px solid var(--float-edge);
|
|
186
186
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
187
|
-
border-radius: var(--radius-
|
|
187
|
+
border-radius: var(--radius-md);
|
|
188
188
|
padding: var(--ui-dropdown-pad);
|
|
189
189
|
/* The cap, and the whole of #489: a panel took its content's height until that
|
|
190
190
|
height ran off the screen, and then it took what was left. Two numbers decide
|
|
@@ -455,12 +455,12 @@
|
|
|
455
455
|
.ui-dropdown__panel > .ui-dropdown__head {
|
|
456
456
|
margin: calc(var(--ui-dropdown-pad) * -1) calc(var(--ui-dropdown-pad) * -1) 5px;
|
|
457
457
|
border-bottom: 1px solid var(--border);
|
|
458
|
-
border-radius: var(--radius-
|
|
458
|
+
border-radius: var(--radius-md) var(--radius-md) 0 0;
|
|
459
459
|
}
|
|
460
460
|
.ui-dropdown__panel > .ui-dropdown__foot {
|
|
461
461
|
margin: 5px calc(var(--ui-dropdown-pad) * -1) calc(var(--ui-dropdown-pad) * -1);
|
|
462
462
|
border-top: 1px solid var(--border);
|
|
463
|
-
border-radius: 0 0 var(--radius-
|
|
463
|
+
border-radius: 0 0 var(--radius-md) var(--radius-md);
|
|
464
464
|
}
|
|
465
465
|
|
|
466
466
|
/* Search — `search: true` pins a field above the rows and filters them as the
|
|
@@ -497,7 +497,7 @@
|
|
|
497
497
|
/* The ground and line .ui-input takes. why: docs/foundations.md#elevation */
|
|
498
498
|
background: var(--field-bg); /* code-bg: inherit — control paint; the containing surface is the ground, for a chip and for a band alike. */
|
|
499
499
|
border: 1px solid var(--field-edge);
|
|
500
|
-
border-radius: var(--radius-
|
|
500
|
+
border-radius: var(--radius-lg); /* The one-line field corner, as .ui-input. #836 */
|
|
501
501
|
padding: 8px 12px 8px 34px;
|
|
502
502
|
/* The height Chromium paints (38.25px), stated so the target-size gate, which
|
|
503
503
|
cannot see an <input>'s line of text, reads the box a reader hits. */
|
|
@@ -551,7 +551,7 @@
|
|
|
551
551
|
shows the dashed ring beside the placeholder in the placeholder ink. The mark's own
|
|
552
552
|
margins give back the room it takes, so the trigger keeps its height.
|
|
553
553
|
why: docs/components.md#avatar */
|
|
554
|
-
.ui-dropdown__trigger
|
|
554
|
+
.ui-dropdown__trigger .ui-avatar {
|
|
555
555
|
--ui-avatar-pull: 4px;
|
|
556
556
|
--ui-avatar-pull-start: 10px;
|
|
557
557
|
margin-block: calc(var(--ui-avatar-pull) * -1);
|
|
@@ -559,16 +559,41 @@
|
|
|
559
559
|
}
|
|
560
560
|
.ui-dropdown__value.is-placeholder { /* muted-ink: placeholder — no person chosen */ color: var(--muted); font-weight: var(--weight-medium); }
|
|
561
561
|
|
|
562
|
-
/*
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
.ui-
|
|
562
|
+
/* The shown value and each hidden measurement row keep one line and one gap, so a
|
|
563
|
+
form dropdown measures its value exactly as it draws it.
|
|
564
|
+
why: docs/components.md#fields */
|
|
565
|
+
.ui-dropdown__line { display: inline-flex; align-items: center; gap: 8px; min-inline-size: 0; }
|
|
566
|
+
|
|
567
|
+
/* A form dropdown fits its longest option, up to the field width. Its panel is at
|
|
568
|
+
least as wide as its trigger. why: docs/components.md#fields */
|
|
569
|
+
.ui-field > .ui-dropdown { display: inline-grid; grid-template-columns: minmax(0, max-content); max-width: 100%; }
|
|
570
|
+
/* The hidden rows live inside the trigger, so they inherit its size at every
|
|
571
|
+
breakpoint and draw the same mark and classes as the shown value. A row longer
|
|
572
|
+
than the field truncates inside the trigger, so it never widens the page.
|
|
573
|
+
why: docs/components.md#fields */
|
|
574
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger > .ui-dropdown__fit {
|
|
575
|
+
grid-area: 1 / 1;
|
|
576
|
+
display: grid; grid-template-columns: minmax(0, max-content);
|
|
577
|
+
visibility: hidden; min-inline-size: 0; overflow: hidden;
|
|
578
|
+
}
|
|
579
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger > .ui-dropdown__fit > * { grid-area: 1 / 1; }
|
|
580
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger > .ui-dropdown__line { grid-area: 1 / 1; }
|
|
581
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger > .ui-dropdown__chevron { grid-area: 1 / 2; }
|
|
566
582
|
.ui-field > .ui-dropdown > .ui-dropdown__panel { inline-size: 100%; min-width: 0; }
|
|
583
|
+
|
|
584
|
+
@supports (corner-shape: squircle) {
|
|
585
|
+
.ui-dropdown__panel,
|
|
586
|
+
.ui-dropdown__panel > .ui-dropdown__head,
|
|
587
|
+
.ui-dropdown__panel > .ui-dropdown__foot,
|
|
588
|
+
.ui-dropdown__search-input { corner-shape: squircle; }
|
|
589
|
+
}
|
|
567
590
|
/* In a form the trigger takes the text input's block padding and type, so the two
|
|
568
591
|
stand at one height. It keeps the pill, and the input has the field corner. #812, #836
|
|
569
592
|
why: docs/components.md#fields */
|
|
570
593
|
@property --ui-dropdown-line { syntax: "<length>"; inherits: true; initial-value: 0px; }
|
|
571
594
|
.ui-field > .ui-dropdown > .ui-dropdown__trigger {
|
|
595
|
+
grid-area: 1 / 1; max-width: 100%;
|
|
596
|
+
display: grid; grid-template-columns: minmax(0, max-content) max-content;
|
|
572
597
|
padding: var(--space-3) var(--space-4);
|
|
573
598
|
font-size: var(--text-base); line-height: normal;
|
|
574
599
|
min-inline-size: 0;
|
|
@@ -577,8 +602,8 @@
|
|
|
577
602
|
}
|
|
578
603
|
/* A long value keeps one line from the left and ends in an ellipsis, as the select
|
|
579
604
|
does, so the trigger keeps the input's height at every length. */
|
|
580
|
-
.ui-field > .ui-dropdown > .ui-dropdown__trigger
|
|
581
|
-
.ui-field > .ui-dropdown > .ui-dropdown__trigger
|
|
605
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger .ui-dropdown__value,
|
|
606
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger .ui-dropdown__text {
|
|
582
607
|
min-inline-size: 0;
|
|
583
608
|
overflow: hidden;
|
|
584
609
|
white-space: nowrap;
|
|
@@ -588,9 +613,9 @@
|
|
|
588
613
|
/* The chosen value takes the text input's regular weight and normal spacing. No colour:
|
|
589
614
|
the value keeps --strong, a disabled value its off ink and a placeholder its muted ink.
|
|
590
615
|
rev_67189e20ee1f/d5 why: docs/components.md#fields */
|
|
591
|
-
.ui-field > .ui-dropdown > .ui-dropdown__trigger
|
|
616
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger .ui-dropdown__value { font-weight: var(--weight-normal); letter-spacing: normal; }
|
|
592
617
|
/* The mark stands as far from the left edge as from the top and bottom edges. */
|
|
593
|
-
.ui-field > .ui-dropdown > .ui-dropdown__trigger
|
|
618
|
+
.ui-field > .ui-dropdown > .ui-dropdown__trigger .ui-avatar {
|
|
594
619
|
--ui-avatar-pull-start: calc(var(--space-4) - var(--space-3) - (var(--ui-dropdown-line) - var(--ui-avatar-size)) / 2);
|
|
595
620
|
}
|
|
596
621
|
/* The input beside it is 16px on a touch screen, so the trigger follows it. A flat
|
package/src/styles/feedback.css
CHANGED
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
/* The composer panel (bottom-centre) */
|
|
68
68
|
.ui-fbcomposer {
|
|
69
69
|
position: fixed; z-index: 71; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(14px);
|
|
70
|
-
width: min(520px, calc(100vw - 32px)); background: var(--bg-elevated); border-radius:
|
|
70
|
+
width: min(520px, calc(100vw - 32px)); background: var(--bg-elevated); border-radius: var(--radius-md);
|
|
71
71
|
/* The shadow was its only edge until #295, which replaced it with the hairline; since
|
|
72
72
|
#490 light is back on the drop and dark keeps the line.
|
|
73
73
|
why: docs/foundations.md#elevation */
|
|
@@ -85,13 +85,13 @@
|
|
|
85
85
|
.ui-fbc__x:hover { color: var(--strong); }
|
|
86
86
|
.ui-fbc__x:focus-visible { outline: var(--ring); outline-offset: var(--ring-offset); }
|
|
87
87
|
.ui-fbc__x svg { width: 14px; height: 14px; stroke-width: 2.7; }
|
|
88
|
-
.ui-fbc__quote { margin: 14px 20px 0; background: var(--surface); /* code-bg: inherit — decorative or text-only paint; nothing nested reads a ground from it. */ border-radius:
|
|
88
|
+
.ui-fbc__quote { margin: 14px 20px 0; background: var(--surface); /* code-bg: inherit — decorative or text-only paint; nothing nested reads a ground from it. */ border-radius: var(--radius-md); padding: 12px 15px; display: flex; gap: 11px; }
|
|
89
89
|
.ui-fbc__qm { color: var(--text); font-size: var(--text-xl); font-weight: var(--weight-bold); line-height: .9; flex: none; opacity: .55; }
|
|
90
90
|
.ui-fbc__quote q { quotes: none; color: var(--text); font-style: italic; font-size: var(--text-sm); line-height: 1.55; }
|
|
91
91
|
.ui-fbc__body { padding: 14px 20px 0; }
|
|
92
92
|
.ui-fbcomposer textarea {
|
|
93
93
|
width: 100%; min-height: 96px; resize: vertical; font-family: var(--font-sans); font-size: var(--text-base); line-height: 1.55;
|
|
94
|
-
color: var(--strong); background: var(--surface); /* code-bg: inherit — control paint; the containing surface is the ground, for a chip and for a band alike. */ border: 1px solid var(--field-edge); border-radius:
|
|
94
|
+
color: var(--strong); background: var(--surface); /* code-bg: inherit — control paint; the containing surface is the ground, for a chip and for a band alike. */ border: 1px solid var(--field-edge); border-radius: var(--radius-2xl); padding: 13px 15px; transition: box-shadow var(--dur-fast) var(--ease);
|
|
95
95
|
}
|
|
96
96
|
.ui-fbcomposer textarea::placeholder { /* muted-ink: placeholder — empty feedback field */ color: var(--muted); }
|
|
97
97
|
.ui-fbcomposer textarea:focus-visible { outline: var(--ring); outline-offset: var(--ring-offset); }
|
|
@@ -130,7 +130,10 @@
|
|
|
130
130
|
@keyframes uiFbCkSpring { 0% { transform: scale(1.32); } 62% { transform: scale(.965); } 82% { transform: scale(1.02); } 100% { transform: scale(1); } }
|
|
131
131
|
|
|
132
132
|
/* Error banner */
|
|
133
|
-
.ui-fbc__err { margin: 14px 20px 0; background: color-mix(in srgb, var(--pink) 14%, transparent); /* code-bg: inherit — text-only validation message has no nested focus target. */ color: var(--chip-danger-ink); font-size: var(--text-sm); padding: 11px 15px; border-radius:
|
|
133
|
+
.ui-fbc__err { margin: 14px 20px 0; background: color-mix(in srgb, var(--pink) 14%, transparent); /* code-bg: inherit — text-only validation message has no nested focus target. */ color: var(--chip-danger-ink); font-size: var(--text-sm); padding: 11px 15px; border-radius: var(--radius-md); display: none; }
|
|
134
|
+
@supports (corner-shape: squircle) {
|
|
135
|
+
.ui-fbcomposer, .ui-fbc__quote, .ui-fbcomposer textarea, .ui-fbc__err { corner-shape: squircle; }
|
|
136
|
+
}
|
|
134
137
|
.ui-fbc__err.show { display: block; /* motion: still — the React Feedback renders the error already shown; its fade is the is-entering animation beside it. */ }
|
|
135
138
|
/* A failed send's line fades in; wireFeedback() adds the class as it shows it. */
|
|
136
139
|
.ui-fbc__err.is-entering { animation: m-fade var(--dur-fast) var(--ease-out) both; }
|
package/src/styles/input.css
CHANGED
|
@@ -31,11 +31,11 @@
|
|
|
31
31
|
width: 100%;
|
|
32
32
|
transition: border-color var(--dur-med) var(--ease), box-shadow var(--dur-med) var(--ease);
|
|
33
33
|
}
|
|
34
|
-
/*
|
|
35
|
-
control the reader presses, so it keeps the pill below. #836
|
|
34
|
+
/* A one-line field has the large field corner. A text area has the larger message corner.
|
|
35
|
+
The select is a control the reader presses, so it keeps the pill below. #836
|
|
36
36
|
why: docs/foundations.md#control-corners */
|
|
37
|
-
.ui-input
|
|
38
|
-
.ui-textarea { border-radius: var(--radius-
|
|
37
|
+
.ui-input { border-radius: var(--radius-lg); }
|
|
38
|
+
.ui-textarea { border-radius: var(--radius-2xl); }
|
|
39
39
|
.ui-textarea { resize: vertical; min-height: 96px; line-height: 1.55; }
|
|
40
40
|
|
|
41
41
|
.ui-input:hover,
|
|
@@ -123,6 +123,11 @@
|
|
|
123
123
|
padding-right: 40px;
|
|
124
124
|
cursor: pointer;
|
|
125
125
|
}
|
|
126
|
+
.ui-field > .ui-select { width: fit-content; max-width: 100%; }
|
|
127
|
+
|
|
128
|
+
@supports (corner-shape: squircle) {
|
|
129
|
+
.ui-input, .ui-textarea { corner-shape: squircle; }
|
|
130
|
+
}
|
|
126
131
|
:root[data-theme="light"] .ui-select {
|
|
127
132
|
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='-6 -6 12 12' fill='none' stroke='%235c6270' stroke-width='1.6'%3E%3Cpath d='M-5.09 -2.83L0 2.26l5.09-5.09'/%3E%3C/svg%3E");
|
|
128
133
|
}
|
|
@@ -351,7 +356,7 @@
|
|
|
351
356
|
line-height: var(--leading-tight);
|
|
352
357
|
min-height: var(--btn-height-sm);
|
|
353
358
|
padding: var(--space-1) var(--space-3);
|
|
354
|
-
border-radius: var(--radius-
|
|
359
|
+
border-radius: var(--radius-lg); /* why: docs/foundations.md#control-corners */
|
|
355
360
|
}
|
|
356
361
|
}
|
|
357
362
|
@media (pointer: coarse) {
|
package/src/styles/layout.css
CHANGED
|
@@ -377,7 +377,7 @@
|
|
|
377
377
|
.ui-app__search:focus-visible { outline: var(--ring); outline-offset: var(--ring-offset); }
|
|
378
378
|
/* The same glyph the palette draws in its own search box, at the same box and the
|
|
379
379
|
same stroke: the trigger and the thing it opens are not two search marks.
|
|
380
|
-
src/styles/command-palette.css:
|
|
380
|
+
src/styles/command-palette.css:113 `.ui-cmdk__search-ic svg` */
|
|
381
381
|
.ui-app__search-ic { display: flex; flex: none; }
|
|
382
382
|
.ui-app__search-ic svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 2.2; }
|
|
383
383
|
/* Part of the button's name, so it is squeezed rather than dropped: an ellipsis
|
|
@@ -730,7 +730,7 @@
|
|
|
730
730
|
background: var(--bg-elevated);
|
|
731
731
|
border: 1px solid var(--float-edge);
|
|
732
732
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
733
|
-
border-radius:
|
|
733
|
+
border-radius: var(--radius-md);
|
|
734
734
|
padding: 38px 36px 32px;
|
|
735
735
|
}
|
|
736
736
|
.ui-auth__brand { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 26px; }
|
|
@@ -878,3 +878,7 @@
|
|
|
878
878
|
/* A folded sub-row has no glyph, so its floating name took the row's only line box with it
|
|
879
879
|
and the row shrank under the pointer. It keeps one line and its padding (#843). */
|
|
880
880
|
:where(.ui-app.is-collapsed) .ui-app__rail .ui-nav__item:not(:has(.ui-nav__ic)) { min-height: calc(1lh + 18px); /* one line plus the row's 9px padding, top and bottom */ }
|
|
881
|
+
|
|
882
|
+
@supports (corner-shape: squircle) {
|
|
883
|
+
.ui-auth__card { corner-shape: squircle; }
|
|
884
|
+
}
|
|
@@ -110,10 +110,14 @@
|
|
|
110
110
|
min-height: var(--space-8);
|
|
111
111
|
padding: var(--space-1) var(--space-2);
|
|
112
112
|
font-size: var(--text-sm);
|
|
113
|
-
border-radius: var(--radius-
|
|
113
|
+
border-radius: var(--radius-lg); /* The one-line field corner, as .ui-input. #836 */
|
|
114
114
|
text-align: center;
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
+
@supports (corner-shape: squircle) {
|
|
118
|
+
.ui-pager__jump-input { corner-shape: squircle; }
|
|
119
|
+
}
|
|
120
|
+
|
|
117
121
|
/* A pager directly after a table stands off it. The strip owns no margin of its
|
|
118
122
|
own — it is dropped under lists and cards too, and a component that carries
|
|
119
123
|
spacing everywhere is one every caller has to cancel somewhere — so the gap is
|
package/src/styles/success.css
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
--sx-green: var(--green);
|
|
16
16
|
position: relative;
|
|
17
17
|
overflow: hidden;
|
|
18
|
-
border-radius:
|
|
18
|
+
border-radius: var(--radius-md);
|
|
19
19
|
background: var(--bg-elevated); /* Elevated surface for the confirmation and its actions. */
|
|
20
20
|
/* The floating treatment, like every other surface on that step.
|
|
21
21
|
why: docs/foundations.md#elevation */
|
|
@@ -26,6 +26,9 @@
|
|
|
26
26
|
|
|
27
27
|
/* ---- Layout shell -------------------------------------------------------- */
|
|
28
28
|
.ui-sx__inner { position: relative; z-index: 1; }
|
|
29
|
+
@supports (corner-shape: squircle) {
|
|
30
|
+
.ui-sx { corner-shape: squircle; }
|
|
31
|
+
}
|
|
29
32
|
.ui-sx__content { min-width: 0; }
|
|
30
33
|
.ui-sx__title {
|
|
31
34
|
color: var(--strong); font-size: var(--text-xl); font-weight: var(--weight-semibold);
|
package/src/styles/tooltip.css
CHANGED
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
why: docs/foundations.md#elevation */
|
|
44
44
|
border: 1px solid var(--float-edge);
|
|
45
45
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
46
|
-
border-radius: var(--radius-
|
|
46
|
+
border-radius: var(--radius-md);
|
|
47
47
|
font-family: var(--font-sans);
|
|
48
48
|
font-size: var(--text-xs);
|
|
49
49
|
line-height: 1.45;
|
|
@@ -62,6 +62,9 @@
|
|
|
62
62
|
/* `linear`: visibility is discrete, the rule the dropdown panel states. */
|
|
63
63
|
visibility var(--dur-fast) linear;
|
|
64
64
|
}
|
|
65
|
+
@supports (corner-shape: squircle) {
|
|
66
|
+
.ui-tip { corner-shape: squircle; }
|
|
67
|
+
}
|
|
65
68
|
|
|
66
69
|
/* The readout uses the floating panel surface in both themes. Its edge
|
|
67
70
|
and shadow separate it from the card underneath.
|
package/src/styles/topbar.css
CHANGED
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
why: docs/foundations.md#elevation */
|
|
145
145
|
border: 1px solid var(--float-edge);
|
|
146
146
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
147
|
-
border-radius:
|
|
147
|
+
border-radius: var(--radius-md);
|
|
148
148
|
padding: 6px;
|
|
149
149
|
/* The same cap `.ui-dropdown__panel` writes itself, in bespoke clothes: this
|
|
150
150
|
menu is `wireDropdown()` too, so wireDropdown() measures it the same way and
|
|
@@ -329,7 +329,7 @@
|
|
|
329
329
|
why: docs/foundations.md#elevation */
|
|
330
330
|
border: 1px solid var(--float-edge);
|
|
331
331
|
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--float-edge-inner)), var(--elev-drop);
|
|
332
|
-
border-radius:
|
|
332
|
+
border-radius: var(--radius-md);
|
|
333
333
|
/* #519 chose no clip over padding: `overflow: hidden` with no room cut the ring down to
|
|
334
334
|
the one pixel of border this panel had, so the rule took the clip away instead and let
|
|
335
335
|
the ring cross the edge. #489's cap takes that choice away — `overflow-y: auto` clips
|
|
@@ -382,10 +382,13 @@
|
|
|
382
382
|
padding: 13px 15px;
|
|
383
383
|
margin: -6px -6px 5px;
|
|
384
384
|
border-bottom: 1px solid var(--border);
|
|
385
|
-
border-radius:
|
|
385
|
+
border-radius: var(--radius-md) var(--radius-md) 0 0;
|
|
386
386
|
display: flex; align-items: center; gap: 11px;
|
|
387
387
|
}
|
|
388
388
|
.amenu .ui-dropdown__sep { margin: 5px 0; }
|
|
389
|
+
@supports (corner-shape: squircle) {
|
|
390
|
+
.vsw__menu, .amenu, .amenu .ahead { corner-shape: squircle; }
|
|
391
|
+
}
|
|
389
392
|
.amenu .ahead .avatar { cursor: default; }
|
|
390
393
|
.amenu .ahead .aw { min-width: 0; display: flex; flex-direction: column; gap: 1px; line-height: 1.35; }
|
|
391
394
|
.amenu .ahead .anm { color: var(--strong); font-size: var(--text-sm); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|