@plexui/styles 0.1.23 → 0.1.25
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.
|
@@ -240,14 +240,14 @@
|
|
|
240
240
|
grid-row: 1;
|
|
241
241
|
}/* A framed field in a row: its width cannot follow what is typed, so it has one,
|
|
242
242
|
wider for words than for a number. A ghost has the row for its frame, a Select
|
|
243
|
-
follows its value. */.Field:where([data-row]:not([data-orientation="vertical"])) .Control:has(
|
|
244
|
-
[data-variant]:not([data-variant="ghost"]) > input,
|
|
245
|
-
[data-variant]:not([data-variant="ghost"]) > textarea
|
|
243
|
+
follows its value, and fields set out by a wrapper of their own size themselves. */.Field:where([data-row]:not([data-orientation="vertical"])) .Control:has(
|
|
244
|
+
> [data-variant]:not([data-variant="ghost"]) > input,
|
|
245
|
+
> [data-variant]:not([data-variant="ghost"]) > textarea
|
|
246
246
|
) {
|
|
247
247
|
width: var(--field-row-control-width);
|
|
248
248
|
}.Field:where([data-row]:not([data-orientation="vertical"])) .Control:has(
|
|
249
|
-
[data-variant]:not([data-variant="ghost"]) > input:not([inputmode="decimal"], [inputmode="numeric"], [type="number"]),
|
|
250
|
-
[data-variant]:not([data-variant="ghost"]) > textarea
|
|
249
|
+
> [data-variant]:not([data-variant="ghost"]) > input:not([inputmode="decimal"], [inputmode="numeric"], [type="number"]),
|
|
250
|
+
> [data-variant]:not([data-variant="ghost"]) > textarea
|
|
251
251
|
) {
|
|
252
252
|
width: var(--field-row-text-width);
|
|
253
253
|
}/* An error in a row is the line of words under it: the field keeps its usual frame */.Field:where([data-row]) .Control {
|
|
@@ -274,6 +274,30 @@
|
|
|
274
274
|
box-shadow: none;
|
|
275
275
|
}.Field:where([data-row]:not([data-orientation="vertical"])) .Control > [data-variant="ghost"] > input {
|
|
276
276
|
text-align: end;
|
|
277
|
+
}/* A FieldGroup with `columns`: every value starts at one column, as in an iOS form of
|
|
278
|
+
typed details. A field keeps its width, a ghost takes the rest of the line, a switch
|
|
279
|
+
and an action stay at the end. */[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"]):not(:has(> .Action))),
|
|
280
|
+
[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"]):not(:has(> .Action))):has(
|
|
281
|
+
.Control > [data-variant="ghost"] > input,
|
|
282
|
+
.Control > [data-variant="ghost"] > textarea
|
|
283
|
+
) {
|
|
284
|
+
--field-row-gap: 16px;
|
|
285
|
+
|
|
286
|
+
grid-template-columns: var(--field-row-column-width) minmax(0, 1fr);
|
|
287
|
+
}[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"])) .Control:has(
|
|
288
|
+
> [data-variant]:not([data-variant="ghost"]) > input,
|
|
289
|
+
> [data-variant]:not([data-variant="ghost"]) > textarea,
|
|
290
|
+
> [data-variant][role="button"]
|
|
291
|
+
) {
|
|
292
|
+
justify-self: start;
|
|
293
|
+
}[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"])) .Control > [data-variant="ghost"] > input {
|
|
294
|
+
text-align: start;
|
|
295
|
+
}@media (min-width: 768px) {
|
|
296
|
+
[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"])):has(> .Action) {
|
|
297
|
+
--field-row-gap: 16px;
|
|
298
|
+
|
|
299
|
+
grid-template-columns: var(--field-row-column-width) minmax(0, 1fr) auto;
|
|
300
|
+
}
|
|
277
301
|
}/* On a phone a list takes the width of its own line under the label and the action.
|
|
278
302
|
The row is the frame of every field, as on iOS: the framed fields of the web read
|
|
279
303
|
as the ghost above, with nothing for the author to change. */@media (max-width: 767px) {
|
|
@@ -331,9 +355,50 @@
|
|
|
331
355
|
text-align: end;
|
|
332
356
|
}
|
|
333
357
|
|
|
334
|
-
/* A Select or a date: its value ends at the row's edge */
|
|
358
|
+
/* A Select or a date: its value ends at the row's edge, its mark too, as the row has no pill to sit in */
|
|
335
359
|
.Field:where([data-row]:not([data-orientation="vertical"])) .Control [data-variant="outline"][role="button"] {
|
|
360
|
+
--dropdown-icon-pill-offset: 0px;
|
|
361
|
+
|
|
336
362
|
padding-inline: 0;
|
|
337
363
|
}
|
|
364
|
+
|
|
365
|
+
/* An InputGroup: its value and its unit end at the row's edge too. A button at the end
|
|
366
|
+
reads as the row's text, as a Select's value does: no gutter and no fill */
|
|
367
|
+
.Field:where([data-row]:not([data-orientation="vertical"])) .Control > [data-slot="input-group"][data-variant="outline"] {
|
|
368
|
+
--input-group-gutter: 0px;
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
.Field:where([data-row]:not([data-orientation="vertical"])) .Control > [data-slot="input-group"] > [data-align="inline-end"] > button:last-child {
|
|
372
|
+
--button-gutter: 0px;
|
|
373
|
+
--button-background-color: transparent;
|
|
374
|
+
--button-background-color-active: transparent;
|
|
375
|
+
|
|
376
|
+
margin-inline-end: 0;
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
/* With `columns` the value starts at the column and takes the rest of the row: a unit,
|
|
380
|
+
a Select's mark and an icon end at its edge, as on iOS */
|
|
381
|
+
[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"]):not(:has(> .Action))):has(
|
|
382
|
+
.Control > [data-variant="outline"] > input,
|
|
383
|
+
.Control > [data-variant="outline"] > textarea
|
|
384
|
+
) {
|
|
385
|
+
grid-template-columns: var(--field-row-column-width) minmax(0, 1fr);
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"])) .Control:has(
|
|
389
|
+
> [data-variant]:not([data-variant="ghost"]) > input,
|
|
390
|
+
> [data-variant]:not([data-variant="ghost"]) > textarea,
|
|
391
|
+
> [data-variant][role="button"]
|
|
392
|
+
) {
|
|
393
|
+
justify-self: stretch;
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"])) .Control > [data-variant="outline"] > input {
|
|
397
|
+
text-align: start;
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
[data-field-columns] .Field:where([data-row]:not([data-orientation="vertical"])) .Control > [data-variant="outline"][role="button"] {
|
|
401
|
+
width: 100%;
|
|
402
|
+
}
|
|
338
403
|
}
|
|
339
404
|
}
|
|
@@ -27,6 +27,8 @@
|
|
|
27
27
|
/* The transform-origin computed from the content and arrow positions/offsets */
|
|
28
28
|
transform-origin: var(--radix-dropdown-menu-content-transform-origin);
|
|
29
29
|
will-change: transform;
|
|
30
|
+
|
|
31
|
+
/* A submenu opens 100 ms after the pointer reaches its row, then shows at once */
|
|
30
32
|
}
|
|
31
33
|
|
|
32
34
|
/* Animation states applied to a wrapping parent */
|
|
@@ -56,6 +58,15 @@
|
|
|
56
58
|
transition-duration: var(--motion-exit);
|
|
57
59
|
transition-property: opacity, transform;
|
|
58
60
|
transition-timing-function: var(--cubic-exit-snappy);
|
|
61
|
+
}
|
|
62
|
+
.Menu[data-entering-active] .MenuList[data-submenu],
|
|
63
|
+
.Menu[data-entering][data-interrupted] .MenuList[data-submenu] {
|
|
64
|
+
transition-duration: var(--motion-enter-quick);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.Menu[data-exiting-active] .MenuList[data-submenu],
|
|
68
|
+
.Menu[data-exiting][data-interrupted] .MenuList[data-submenu] {
|
|
69
|
+
transition-duration: var(--motion-exit-quick);
|
|
59
70
|
}.MenuItemContent {
|
|
60
71
|
padding: var(--menu-item-padding);
|
|
61
72
|
}
|
|
@@ -248,6 +248,7 @@
|
|
|
248
248
|
--field-row-control-width: 160px;
|
|
249
249
|
--field-row-text-width: 240px;
|
|
250
250
|
--field-row-label-width: 80px;
|
|
251
|
+
--field-row-column-width: 40%;
|
|
251
252
|
--field-row-row-gap: 2px;
|
|
252
253
|
--field-row-text-display: flex;
|
|
253
254
|
--field-row-label-font-size: var(--font-text-sm-size);
|
|
@@ -384,6 +384,9 @@
|
|
|
384
384
|
--motion-enter-large: 300ms;
|
|
385
385
|
--motion-exit: 150ms;
|
|
386
386
|
--motion-exit-large: 200ms;
|
|
387
|
+
/* A submenu: it opens 100 ms after the pointer arrives, then shows at once */
|
|
388
|
+
--motion-enter-quick: 100ms;
|
|
389
|
+
--motion-exit-quick: 100ms;
|
|
387
390
|
|
|
388
391
|
/* =============================================
|
|
389
392
|
Scrollbar
|
|
@@ -641,6 +644,8 @@
|
|
|
641
644
|
--motion-enter-large: 0ms;
|
|
642
645
|
--motion-exit: 0ms;
|
|
643
646
|
--motion-exit-large: 0ms;
|
|
647
|
+
--motion-enter-quick: 0ms;
|
|
648
|
+
--motion-exit-quick: 0ms;
|
|
644
649
|
}
|
|
645
650
|
}
|
|
646
651
|
}
|