@apliteni/apliteni-ui 0.33.0 → 0.33.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.
- package/package.json +1 -1
- package/react/dist/index.css +2 -1
- package/src/styles/callout.css +8 -1
- package/src/styles/command-palette.css +9 -2
- package/src/styles/confirm.css +9 -2
- package/src/styles/drawer.css +25 -5
- package/src/styles/dropdown.css +4 -1
- package/src/styles/layout.css +9 -3
- package/src/styles/tooltip.css +4 -1
- package/src/styles/topbar.css +10 -3
- package/src/tokens/tokens.css +27 -6
package/package.json
CHANGED
package/react/dist/index.css
CHANGED
|
@@ -44,7 +44,8 @@
|
|
|
44
44
|
.rx-modal {
|
|
45
45
|
width: min(480px, 92vw);
|
|
46
46
|
background: var(--bg-elevated);
|
|
47
|
-
border: 1px solid var(--border);
|
|
47
|
+
border: 1px solid var(--border-strong);
|
|
48
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
48
49
|
border-radius: var(--radius-xl);
|
|
49
50
|
overflow: hidden;
|
|
50
51
|
transform: translateY(8px);
|
package/src/styles/callout.css
CHANGED
|
@@ -44,6 +44,10 @@
|
|
|
44
44
|
width: 100%;
|
|
45
45
|
max-width: var(--panel-md);
|
|
46
46
|
overflow: hidden; /* clips the timer bar + left marker to the rounded corners */
|
|
47
|
+
/* A toast floats. It carries a status rather than the neutral hairline, so each
|
|
48
|
+
style below re-points --elev-edge at its own tint and leaves the outer line
|
|
49
|
+
where it already drew it. why: docs/specification.md#elevation */
|
|
50
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
47
51
|
animation: ui-toast-in var(--dur-med) var(--ease-out) both;
|
|
48
52
|
}
|
|
49
53
|
|
|
@@ -115,6 +119,7 @@
|
|
|
115
119
|
.ui-toast--soft {
|
|
116
120
|
background: var(--toast-glow);
|
|
117
121
|
border: 1px solid color-mix(in srgb, var(--toast-accent) 22%, transparent);
|
|
122
|
+
--elev-edge: color-mix(in srgb, var(--toast-accent) 11%, transparent);
|
|
118
123
|
}
|
|
119
124
|
|
|
120
125
|
/* style: solid — the status at fill strength, inked with the pole opposite it.
|
|
@@ -128,6 +133,8 @@
|
|
|
128
133
|
--toast-ink: var(--signal-solid-ink);
|
|
129
134
|
background: var(--toast-solid);
|
|
130
135
|
color: var(--toast-ink);
|
|
136
|
+
/* No inner line: a solid toast has no outer one either. It keeps the drop. */
|
|
137
|
+
--elev-edge: transparent;
|
|
131
138
|
}
|
|
132
139
|
.ui-toast--solid .ui-toast__title { color: var(--toast-ink); }
|
|
133
140
|
/* The body copy is the quieter of the two, but it stays quiet by dilution the
|
|
@@ -147,7 +154,7 @@
|
|
|
147
154
|
.ui-toast--solid .ui-toast__timer { background: color-mix(in srgb, var(--toast-ink) 55%, transparent); }
|
|
148
155
|
|
|
149
156
|
/* style: outline — elevated card with a status-tinted border */
|
|
150
|
-
.ui-toast--outline { background: var(--bg-elevated); border: 1px solid color-mix(in srgb, var(--toast-accent) 40%, transparent); }
|
|
157
|
+
.ui-toast--outline { background: var(--bg-elevated); border: 1px solid color-mix(in srgb, var(--toast-accent) 40%, transparent); --elev-edge: color-mix(in srgb, var(--toast-accent) 20%, transparent); }
|
|
151
158
|
|
|
152
159
|
/* compact — single line, no body text */
|
|
153
160
|
.ui-toast--compact { align-items: center; padding-top: 10px; padding-bottom: 10px; }
|
|
@@ -69,7 +69,10 @@
|
|
|
69
69
|
flex-direction: column;
|
|
70
70
|
font-family: var(--font-sans);
|
|
71
71
|
background: var(--cmdk-surface);
|
|
72
|
-
|
|
72
|
+
/* The two-step edge and the drop: --border-strong outside, --border one pixel
|
|
73
|
+
inside it, then the broad faint drop. why: docs/specification.md#elevation */
|
|
74
|
+
border: 1px solid var(--border-strong);
|
|
75
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
73
76
|
border-radius: var(--radius-lg);
|
|
74
77
|
overflow: hidden;
|
|
75
78
|
opacity: 0;
|
|
@@ -79,7 +82,11 @@
|
|
|
79
82
|
transform var(--dur-med) var(--ease);
|
|
80
83
|
}
|
|
81
84
|
.ui-cmdk.is-open .ui-cmdk__panel { opacity: 1; transform: translate(-50%, 0); }
|
|
82
|
-
|
|
85
|
+
/* The ring is COMPOSED with the floating treatment, not written over it: a
|
|
86
|
+
box-shadow list replaces the whole list, so `box-shadow: var(--ring)` alone
|
|
87
|
+
took the panel's edge and its drop off for as long as it held focus.
|
|
88
|
+
why: docs/specification.md#elevation */
|
|
89
|
+
.ui-cmdk__panel:focus-visible { outline: none; box-shadow: var(--ring), inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop); }
|
|
83
90
|
|
|
84
91
|
/* -- The text box --------------------------------------------------------- */
|
|
85
92
|
|
package/src/styles/confirm.css
CHANGED
|
@@ -62,7 +62,10 @@
|
|
|
62
62
|
gap: var(--space-2);
|
|
63
63
|
padding: var(--space-5);
|
|
64
64
|
background: var(--confirm-surface);
|
|
65
|
-
|
|
65
|
+
/* The two-step edge and the drop: --border-strong outside, --border one pixel
|
|
66
|
+
inside it, then the broad faint drop. why: docs/specification.md#elevation */
|
|
67
|
+
border: 1px solid var(--border-strong);
|
|
68
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
66
69
|
border-radius: var(--radius-lg);
|
|
67
70
|
opacity: 0;
|
|
68
71
|
transform: translateY(8px);
|
|
@@ -71,7 +74,11 @@
|
|
|
71
74
|
transform var(--dur-med) var(--ease);
|
|
72
75
|
}
|
|
73
76
|
.ui-confirm.is-open .ui-confirm__panel { opacity: 1; transform: none; }
|
|
74
|
-
|
|
77
|
+
/* The ring is COMPOSED with the floating treatment, not written over it: a
|
|
78
|
+
box-shadow list replaces the whole list, so `box-shadow: var(--ring)` alone
|
|
79
|
+
took the panel's edge and its drop off for as long as it held focus.
|
|
80
|
+
why: docs/specification.md#elevation */
|
|
81
|
+
.ui-confirm__panel:focus-visible { outline: none; box-shadow: var(--ring), inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop); }
|
|
75
82
|
|
|
76
83
|
/* -- Slots ----------------------------------------------------------------- */
|
|
77
84
|
/* The question and the answers keep their size; the consequence between them is
|
package/src/styles/drawer.css
CHANGED
|
@@ -58,9 +58,19 @@
|
|
|
58
58
|
display: flex;
|
|
59
59
|
flex-direction: column;
|
|
60
60
|
background: var(--drawer-surface);
|
|
61
|
+
/* A drawer is flush to a screen edge, so it has one edge rather than four and the
|
|
62
|
+
two-step edge runs along that one: --border-strong on the edge rule below, the
|
|
63
|
+
inner line one pixel inside it. This is the one floating surface that writes no
|
|
64
|
+
inset RING — a full ring would draw 1px lines across the top and bottom of a
|
|
65
|
+
full-height panel, where there is no edge — so it composes its own directional
|
|
66
|
+
line with the drops instead. The line is a variable so the focus rule can
|
|
67
|
+
compose all three layers without knowing which edge it is on; its default is a
|
|
68
|
+
no-op layer rather than `none`, which is valid only alone and would invalidate
|
|
69
|
+
the list. why: docs/specification.md#elevation */
|
|
70
|
+
--drawer-line: 0 0 0 0 transparent;
|
|
71
|
+
box-shadow: var(--drawer-line), var(--elev-drop);
|
|
61
72
|
transition: transform var(--dur-med) var(--ease);
|
|
62
73
|
}
|
|
63
|
-
.ui-drawer__panel:focus-visible { outline: none; box-shadow: var(--ring); }
|
|
64
74
|
.ui-drawer.is-open .ui-drawer__panel { transform: none; }
|
|
65
75
|
|
|
66
76
|
/* -- Edge anchoring + slide-in direction ---------------------------------- */
|
|
@@ -72,12 +82,14 @@
|
|
|
72
82
|
}
|
|
73
83
|
.ui-drawer--right .ui-drawer__panel {
|
|
74
84
|
right: 0;
|
|
75
|
-
border-left: 1px solid var(--border);
|
|
85
|
+
border-left: 1px solid var(--border-strong);
|
|
86
|
+
--drawer-line: inset 1px 0 0 var(--border);
|
|
76
87
|
transform: translateX(100%);
|
|
77
88
|
}
|
|
78
89
|
.ui-drawer--left .ui-drawer__panel {
|
|
79
90
|
left: 0;
|
|
80
|
-
border-right: 1px solid var(--border);
|
|
91
|
+
border-right: 1px solid var(--border-strong);
|
|
92
|
+
--drawer-line: inset -1px 0 0 var(--border);
|
|
81
93
|
transform: translateX(-100%);
|
|
82
94
|
}
|
|
83
95
|
.ui-drawer--top .ui-drawer__panel,
|
|
@@ -88,15 +100,23 @@
|
|
|
88
100
|
}
|
|
89
101
|
.ui-drawer--top .ui-drawer__panel {
|
|
90
102
|
top: 0;
|
|
91
|
-
border-bottom: 1px solid var(--border);
|
|
103
|
+
border-bottom: 1px solid var(--border-strong);
|
|
104
|
+
--drawer-line: inset 0 -1px 0 var(--border);
|
|
92
105
|
transform: translateY(-100%);
|
|
93
106
|
}
|
|
94
107
|
.ui-drawer--bottom .ui-drawer__panel {
|
|
95
108
|
bottom: 0;
|
|
96
|
-
border-top: 1px solid var(--border);
|
|
109
|
+
border-top: 1px solid var(--border-strong);
|
|
110
|
+
--drawer-line: inset 0 1px 0 var(--border);
|
|
97
111
|
transform: translateY(100%);
|
|
98
112
|
}
|
|
99
113
|
|
|
114
|
+
/* The ring is COMPOSED with the floating treatment rather than written over it — a
|
|
115
|
+
box-shadow list replaces the whole list, so a bare `box-shadow: var(--ring)` would
|
|
116
|
+
take the drawer's edge and its drop off for as long as it held focus.
|
|
117
|
+
why: docs/specification.md#elevation */
|
|
118
|
+
.ui-drawer__panel:focus-visible { outline: none; box-shadow: var(--ring), var(--drawer-line), var(--elev-drop); }
|
|
119
|
+
|
|
100
120
|
/* -- Sizes ----------------------------------------------------------------- */
|
|
101
121
|
/* left|right → width; top|bottom → height. Same names, axis chosen by side. */
|
|
102
122
|
.ui-drawer--right.ui-drawer--sm, .ui-drawer--left.ui-drawer--sm { --drawer-w: var(--panel-sm); }
|
package/src/styles/dropdown.css
CHANGED
|
@@ -60,7 +60,10 @@
|
|
|
60
60
|
/* The floating step, not the sunken one — a panel held open over a card cannot be
|
|
61
61
|
painted the colour of an inset. why: docs/specification.md#elevation */
|
|
62
62
|
background: var(--bg-elevated);
|
|
63
|
-
|
|
63
|
+
/* The two-step edge and the drop: --border-strong outside, --border one pixel
|
|
64
|
+
inside it, then the broad faint drop. why: docs/specification.md#elevation */
|
|
65
|
+
border: 1px solid var(--border-strong);
|
|
66
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
64
67
|
border-radius: var(--radius-lg);
|
|
65
68
|
padding: 6px;
|
|
66
69
|
opacity: 0;
|
package/src/styles/layout.css
CHANGED
|
@@ -238,10 +238,16 @@
|
|
|
238
238
|
/* The label IS the chip. `fixed` is the fallback placement, out of the rail's own
|
|
239
239
|
clip; the @supports branch below pins it to the row and is the only one that
|
|
240
240
|
survives a scroll. The toggle's selector is unscoped, because it is wordless at
|
|
241
|
-
both widths.
|
|
241
|
+
both widths.
|
|
242
|
+
|
|
243
|
+
It floats by role — a readout placed over the page for as long as a pointer
|
|
244
|
+
rests on a row — so it takes the floating treatment the hover readout takes,
|
|
245
|
+
which is the same shape on the same step: the two-step edge and the drops.
|
|
246
|
+
why: docs/specification.md#the-page-shell
|
|
247
|
+
why: docs/specification.md#elevation */
|
|
242
248
|
:where(.ui-app.is-collapsed) .ui-app__rail .ui-nav__item:is(:hover, :focus-visible) > .ui-nav__label,
|
|
243
249
|
:where(.ui-app.is-collapsed) .ui-app__rail .ui-app__user-trigger:is(:hover, :focus-visible) > .ui-app__who,
|
|
244
|
-
.ui-app__rail .ui-app__fold:is(:hover, :focus-visible) > .ui-nav__label { position: fixed; left: calc(var(--ui-rail-w) + var(--space-2)); z-index: var(--z-dropdown); width: max-content; max-width: 15rem; margin-block: -7px; padding: 6px 10px; border: 1px solid var(--border); border-radius: var(--radius-xs); background: var(--surface-3); color: var(--strong);
|
|
250
|
+
.ui-app__rail .ui-app__fold:is(:hover, :focus-visible) > .ui-nav__label { position: fixed; left: calc(var(--ui-rail-w) + var(--space-2)); z-index: var(--z-dropdown); width: max-content; max-width: 15rem; margin-block: -7px; padding: 6px 10px; border: 1px solid var(--border-strong); box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop); border-radius: var(--radius-xs); background: var(--surface-3); color: var(--strong); opacity: 1; pointer-events: none; }
|
|
245
251
|
@supports (anchor-name: --a) and (anchor-scope: --a) {
|
|
246
252
|
.ui-app.is-collapsed,
|
|
247
253
|
.ui-app:has(.ui-app__fold) { anchor-scope: --ui-rail; }
|
|
@@ -343,7 +349,7 @@
|
|
|
343
349
|
.ui-app__rail .ui-nav__item,
|
|
344
350
|
.ui-app__rail .ui-app__user-trigger { min-height: 44px; }
|
|
345
351
|
.ui-app__rail .ui-nav__item:is(:hover, :focus-visible) > .ui-nav__label,
|
|
346
|
-
.ui-app__rail .ui-app__user-trigger:is(:hover, :focus-visible) > .ui-app__who { position: fixed; left: calc(var(--ui-rail-w) + var(--space-2)); z-index: var(--z-dropdown); width: max-content; max-width: 15rem; margin-block: -7px; padding: 6px 10px; border: 1px solid var(--border); border-radius: var(--radius-xs); background: var(--surface-3); color: var(--strong);
|
|
352
|
+
.ui-app__rail .ui-app__user-trigger:is(:hover, :focus-visible) > .ui-app__who { position: fixed; left: calc(var(--ui-rail-w) + var(--space-2)); z-index: var(--z-dropdown); width: max-content; max-width: 15rem; margin-block: -7px; padding: 6px 10px; border: 1px solid var(--border-strong); box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop); border-radius: var(--radius-xs); background: var(--surface-3); color: var(--strong); opacity: 1; pointer-events: none; }
|
|
347
353
|
@supports (anchor-name: --a) and (anchor-scope: --a) {
|
|
348
354
|
.ui-app { anchor-scope: --ui-rail; }
|
|
349
355
|
.ui-app__rail { anchor-name: --ui-rail; }
|
package/src/styles/tooltip.css
CHANGED
|
@@ -26,7 +26,10 @@
|
|
|
26
26
|
max-width: var(--prose-caption);
|
|
27
27
|
padding: var(--space-2) var(--space-3);
|
|
28
28
|
background: var(--ui-tip-bg);
|
|
29
|
-
|
|
29
|
+
/* The two-step edge and the drop: --border-strong outside, --border one pixel
|
|
30
|
+
inside it, then the broad faint drop. why: docs/specification.md#elevation */
|
|
31
|
+
border: 1px solid var(--border-strong);
|
|
32
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
30
33
|
border-radius: var(--radius-sm);
|
|
31
34
|
font-family: var(--font-sans);
|
|
32
35
|
font-size: var(--text-xs);
|
package/src/styles/topbar.css
CHANGED
|
@@ -123,7 +123,10 @@
|
|
|
123
123
|
left: 0;
|
|
124
124
|
min-width: 266px;
|
|
125
125
|
background: var(--bg-elevated); /* the floating step — see dropdown.css. #295 */
|
|
126
|
-
|
|
126
|
+
/* The two-step edge and the drop: --border-strong outside, --border one pixel
|
|
127
|
+
inside it, then the broad faint drop. why: docs/specification.md#elevation */
|
|
128
|
+
border: 1px solid var(--border-strong);
|
|
129
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
127
130
|
border-radius: 16px;
|
|
128
131
|
padding: 6px;
|
|
129
132
|
opacity: 0;
|
|
@@ -177,7 +180,8 @@
|
|
|
177
180
|
transition: background var(--dur-fast) var(--ease);
|
|
178
181
|
}
|
|
179
182
|
/* The menu is raised, so a hovered row takes the step ABOVE it — see
|
|
180
|
-
src/styles/dropdown.css:
|
|
183
|
+
src/styles/dropdown.css:144 `.ui-dropdown__item:hover`.
|
|
184
|
+
why: docs/specification.md#elevation */
|
|
181
185
|
.vopt:hover { background: var(--surface-3); }
|
|
182
186
|
.vopt .vname { font-family: var(--font-sans); font-size: 12.5px; color: var(--strong); font-weight: 600; letter-spacing: 0.01em; }
|
|
183
187
|
.vopt .vmeta { font-size: 11px; color: var(--muted); margin-top: 2px; }
|
|
@@ -222,7 +226,10 @@
|
|
|
222
226
|
right: 0; top: 44px;
|
|
223
227
|
width: 252px;
|
|
224
228
|
background: var(--bg-elevated); /* the floating step — see dropdown.css. #295 */
|
|
225
|
-
|
|
229
|
+
/* The two-step edge and the drop: --border-strong outside, --border one pixel
|
|
230
|
+
inside it, then the broad faint drop. why: docs/specification.md#elevation */
|
|
231
|
+
border: 1px solid var(--border-strong);
|
|
232
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
226
233
|
border-radius: 14px;
|
|
227
234
|
overflow: hidden;
|
|
228
235
|
opacity: 0;
|
package/src/tokens/tokens.css
CHANGED
|
@@ -133,9 +133,10 @@
|
|
|
133
133
|
--pink: #e97ca5;
|
|
134
134
|
--amber: #ffcf6a;
|
|
135
135
|
|
|
136
|
-
/* The elevation ladder, bottom to top.
|
|
137
|
-
with
|
|
138
|
-
|
|
136
|
+
/* The elevation ladder, bottom to top. A surface says how high it is with its step and
|
|
137
|
+
with the hairline around it, and --muted caps how far the ladder can go. Nothing casts
|
|
138
|
+
below the floating step; the floating step itself adds --elev-drop under its inner
|
|
139
|
+
line and nothing else in the kit does. why: docs/specification.md#elevation */
|
|
139
140
|
--bg: #0e0d14;
|
|
140
141
|
--surface-2: #161520; /* SUNKEN — fields, tracks, disabled, code */
|
|
141
142
|
--surface: #211e2d; /* the card */
|
|
@@ -214,9 +215,10 @@
|
|
|
214
215
|
--signal-solid-info: var(--cyan);
|
|
215
216
|
--signal-solid-neutral: var(--muted);
|
|
216
217
|
|
|
217
|
-
/* DEPRECATED since #295:
|
|
218
|
-
|
|
219
|
-
|
|
218
|
+
/* DEPRECATED since #295: no surface below the floating step casts, and the floating
|
|
219
|
+
step reads --elev-drop rather than any of these. Published still, so a consumer
|
|
220
|
+
reading one gets nothing rather than an unresolved var(), and a consumer who wants a
|
|
221
|
+
cast shadow sets them. Nothing in src/ reads them.
|
|
220
222
|
|
|
221
223
|
A transparent shadow, not `none`, because these are read in a LIST. The kit's own
|
|
222
224
|
pre-0.32 pattern was `box-shadow: var(--shadow-lg), var(--ring)`, and `none` is only
|
|
@@ -239,6 +241,18 @@
|
|
|
239
241
|
--shadow-ink: #000000;
|
|
240
242
|
--sheen: #ffffff;
|
|
241
243
|
|
|
244
|
+
/* The drops of the floating treatment, in Primer's --shadow-floating-* order:
|
|
245
|
+
the inner half of the two-step edge, then these. The line is NOT in this
|
|
246
|
+
token and cannot be — a var() inside a custom property is substituted on the
|
|
247
|
+
element that DECLARES it, so an --elev-edge read here resolves at :root and
|
|
248
|
+
nothing below could re-point it. A floating surface writes the pair itself:
|
|
249
|
+
box-shadow: inset 0 0 0 1px var(--elev-edge, var(--border)), var(--elev-drop);
|
|
250
|
+
Dark spends 62% / 50% of the ink and reaches 1.20 at the drop's core, having
|
|
251
|
+
nowhere to go on a near-black page. why: docs/specification.md#elevation */
|
|
252
|
+
--elev-drop:
|
|
253
|
+
0 14px 30px -12px color-mix(in srgb, var(--shadow-ink) 62%, transparent),
|
|
254
|
+
0 3px 9px -4px color-mix(in srgb, var(--shadow-ink) 50%, transparent);
|
|
255
|
+
|
|
242
256
|
/* Backdrop that dims the page behind an overlay (drawer, modal, composer). */
|
|
243
257
|
--scrim: rgba(0, 0, 0, 0.58);
|
|
244
258
|
|
|
@@ -345,6 +359,13 @@
|
|
|
345
359
|
--shadow-ink: #1e1e32;
|
|
346
360
|
--sheen: #ffffff;
|
|
347
361
|
|
|
362
|
+
/* 18% / 10% against dark's 62% / 50%. Light's ink is #1e1e32 on a card at
|
|
363
|
+
#f8f9fc, and 18% is what puts the drop core at #d1d2d8 — 1.44, the strongest
|
|
364
|
+
separation either theme gets. why: docs/specification.md#elevation */
|
|
365
|
+
--elev-drop:
|
|
366
|
+
0 14px 30px -12px color-mix(in srgb, var(--shadow-ink) 18%, transparent),
|
|
367
|
+
0 3px 9px -4px color-mix(in srgb, var(--shadow-ink) 10%, transparent);
|
|
368
|
+
|
|
348
369
|
--scrim: rgba(20, 22, 40, 0.38);
|
|
349
370
|
|
|
350
371
|
--grad-from: var(--purple-light);
|