@apliteni/apliteni-ui 0.78.0 → 0.80.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/guidelines/component-choice.md +1 -1
- package/guidelines/drawer.md +17 -3
- package/package.json +1 -1
- package/react/README.md +86 -0
- package/react/dist/index.css +178 -2
- package/react/dist/index.d.ts +64 -1
- package/react/dist/index.js +797 -326
- package/src/styles/tap-zone.css +33 -2
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
|
|
21
21
|
**Why:** A confirm keeps keyboard focus until answered; a callout does not interrupt.
|
|
22
22
|
|
|
23
|
-
**Except:** Use a content-sized modal for a short form and a
|
|
23
|
+
**Except:** Use a content-sized modal or a drawer for a short form, and a page for a long one.
|
|
24
24
|
|
|
25
25
|
**Do:** Ask “Rotate this token?” in a confirm with “Keep token” and “Rotate token” buttons.
|
|
26
26
|
|
package/guidelines/drawer.md
CHANGED
|
@@ -8,11 +8,25 @@
|
|
|
8
8
|
|
|
9
9
|
**Why:** Closing the drawer returns the user to the opened row.
|
|
10
10
|
|
|
11
|
-
**Do:**
|
|
11
|
+
**Do:** Open one for a quick edit, a new key, a filter, or a peek at a row’s detail.
|
|
12
12
|
|
|
13
|
-
**Don't:**
|
|
13
|
+
**Don't:** Open one for a long form, several steps, or a view with its own address and Back.
|
|
14
14
|
|
|
15
|
-
**Except:**
|
|
15
|
+
**Except:** A two-answer question uses confirm, not a drawer.
|
|
16
|
+
|
|
17
|
+
## Drawer or page
|
|
18
|
+
|
|
19
|
+
<!-- rule: drawer-or-page -->
|
|
20
|
+
|
|
21
|
+
**Rule:** Use a page to edit more than one group, and a drawer for one short change.
|
|
22
|
+
|
|
23
|
+
**Why:** Several groups need room to move between them and check them before saving.
|
|
24
|
+
|
|
25
|
+
**Do:** Edit the roles and the per-unit switches on a page, under a way back to the list.
|
|
26
|
+
|
|
27
|
+
**Don't:** Edit the same groups in a drawer, stacked in one narrow panel over the list.
|
|
28
|
+
|
|
29
|
+
**Except:** Change one field inline, without a panel. A drawer may show groups a reader only reads.
|
|
16
30
|
|
|
17
31
|
## Grouped content
|
|
18
32
|
|
package/package.json
CHANGED
package/react/README.md
CHANGED
|
@@ -700,3 +700,89 @@ the accent from a checked box.
|
|
|
700
700
|
<Checkbox label="Full access" type="radio" name="scope" value="full" />
|
|
701
701
|
<Switch label="Email notifications" checked={email} onChange={event => setEmail(event.currentTarget.checked)} />
|
|
702
702
|
```
|
|
703
|
+
|
|
704
|
+
## DatePicker
|
|
705
|
+
|
|
706
|
+
`DatePicker` picks one month (`mode="month"`, the default), a range of months
|
|
707
|
+
(`mode="range"`), one date (`mode="day"`) or a range of dates (`mode="day-range"`). It
|
|
708
|
+
uses the dropdown's own trigger and panel, so it sits beside a `Dropdown` as the same
|
|
709
|
+
control. Periods are ISO strings in the mode's grain: `'2026-08'` for months,
|
|
710
|
+
`'2026-08-14'` for dates. Pass `value`/`onChange` for the single-period modes and
|
|
711
|
+
`range`/`onRangeChange` for the two range modes, or `defaultValue`/`defaultRange` to
|
|
712
|
+
leave the state to the component. Import both the kit CSS and the React CSS.
|
|
713
|
+
|
|
714
|
+
```tsx
|
|
715
|
+
<DatePicker value={month} onChange={setMonth}
|
|
716
|
+
min="2025-01" max="2026-12" disabledPeriods={['2026-07']} />
|
|
717
|
+
|
|
718
|
+
<DatePicker mode="range" range={span} onRangeChange={setSpan}
|
|
719
|
+
presets={[{ label: 'This year', range: { start: '2026-01', end: '2026-12' } }]} />
|
|
720
|
+
|
|
721
|
+
<DatePicker mode="day-range" range={span} onRangeChange={setSpan}
|
|
722
|
+
presets={[{ label: 'This week', range: { start: '2026-09-14', end: '2026-09-20' } }]} />
|
|
723
|
+
```
|
|
724
|
+
|
|
725
|
+
**The trigger shows the value and nothing else.** There is no field name in front of it:
|
|
726
|
+
"Period: Apr 2026 – Aug 2026" says "period" twice, and the picker has no word to add that
|
|
727
|
+
the value does not already carry. Where the surrounding screen leaves the control
|
|
728
|
+
unexplained, name it with `ariaLabel`, which names the trigger and the panel without
|
|
729
|
+
drawing anything.
|
|
730
|
+
|
|
731
|
+
**The grid has one tab stop.** The arrows move one period and one row, Home and End go to
|
|
732
|
+
the ends of the row — they never leave the month, so the blank slots a day grid pads its
|
|
733
|
+
first and last weeks with are not somewhere they can take you — Page Up and Page Down
|
|
734
|
+
move a year in the month modes and a month in day mode, Enter and Space pick, and Escape
|
|
735
|
+
closes and returns focus to the trigger. A move past the edge of the shown year or month
|
|
736
|
+
turns the page and keeps the reader on the period they moved to. Each cell's accessible
|
|
737
|
+
name says what the cell is: `selected` for the pick in every mode, plus `range start`,
|
|
738
|
+
`range end` and `in range` in range mode, and `this month` or `today`.
|
|
739
|
+
|
|
740
|
+
**Bounds hold against your code as well as the reader's.** `min`, `max` and
|
|
741
|
+
`disabledPeriods` are `string`, so a period in the other grain is converted rather than
|
|
742
|
+
dropped: in day mode `min="2026-09"` is 1 September and `max="2026-09"` is the 30th, and
|
|
743
|
+
`disabledPeriods={['2026-09']}` blocks the whole month; in month mode a date means the
|
|
744
|
+
month it falls in. Blocked cells get `aria-disabled` and refuse the press while staying
|
|
745
|
+
focusable. A page step with nowhere to go is disabled.
|
|
746
|
+
|
|
747
|
+
**A range mode takes a start, then an end**, staying open in between; a second pick above
|
|
748
|
+
or below the first always reads as the same range, so the ends swap rather than
|
|
749
|
+
restarting. `range` and `day-range` differ only in grain — a range may run past the page
|
|
750
|
+
it started on, and the span is painted on both pages.
|
|
751
|
+
`onRangeChange` fires on each end, so `{ start, end: null }` reaches you too. `presets`
|
|
752
|
+
set both ends at once and are held to the same bounds the grid is: a preset that overruns
|
|
753
|
+
them is clamped, one with no overlap at all is disabled, and one whose end lands on a
|
|
754
|
+
blocked period is disabled too rather than quietly moved inwards. A blocked period between
|
|
755
|
+
the two ends is still inside the range you are handed — `{ start, end }` is a pair and
|
|
756
|
+
spans it — and says so in its accessible name; only the tint is withheld, because the
|
|
757
|
+
disabled ink over it cannot be read. To exclude a period, split the range and show two
|
|
758
|
+
pickers.
|
|
759
|
+
|
|
760
|
+
**Blocked beats every other state in the paint, and the label is struck through.** Block
|
|
761
|
+
the period your own `value` names and the cell goes bare, keeping its place by weight
|
|
762
|
+
rather than wearing the accent fill under disabled ink; the strike is what says
|
|
763
|
+
unavailable before the pointer is anywhere near it. A cell under the pointer takes the
|
|
764
|
+
kit's neutral row hover, so the accent stays on the pick and the span. Its name still
|
|
765
|
+
says `selected` and the gridcell still carries `aria-selected`: it is still your value,
|
|
766
|
+
it just cannot be pressed.
|
|
767
|
+
|
|
768
|
+
**The period you are in now wears a ring** — hollow for the period you are in, filled for
|
|
769
|
+
the one you chose — and the cell's own name says "this month" or "today". Nothing is drawn
|
|
770
|
+
under the grid to explain it: a key is a second place to read, and these marks are the
|
|
771
|
+
ones a calendar has always drawn. There is no slot for a consumer's own note on a period
|
|
772
|
+
either; a 5px dot can only be read against a key, and a note about a period belongs on the
|
|
773
|
+
surface that shows that period's numbers. The month grid draws its twelve names at one
|
|
774
|
+
length — "Sep", not en-GB's "Sept" — so no cell reads as emphasised; a locale that numbers
|
|
775
|
+
its months keeps its own names.
|
|
776
|
+
|
|
777
|
+
**Below 560px the panel is a bottom `Drawer`**, so the sheet has the kit's scrim, close
|
|
778
|
+
control and focus trap and the page behind it is inert. Pass `sheet` to force that at any
|
|
779
|
+
width — a host that already knows it is on a phone, or one rendering where no viewport
|
|
780
|
+
can be read, should, because the picker reads the viewport with `matchMedia` and starts
|
|
781
|
+
as the popover until it has.
|
|
782
|
+
|
|
783
|
+
Pass `today` (a `'YYYY-MM-DD'` date) to fix what the grid calls today — stories and tests
|
|
784
|
+
use it to stay the same whenever they run. `locale` names the months and weekdays,
|
|
785
|
+
`weekStartsOn` sets the first column in day mode, and `align="end"` hangs the panel off
|
|
786
|
+
the trigger's trailing edge. Without `ariaLabel` the trigger's own text is its accessible
|
|
787
|
+
name, so a control reading "17 September 2026" is heard as that rather than as its
|
|
788
|
+
placeholder. The popover stays mounted while closed, and is `inert` while it is.
|
package/react/dist/index.css
CHANGED
|
@@ -31,14 +31,15 @@
|
|
|
31
31
|
--tap-min: 44px;
|
|
32
32
|
--tap-aa: 24px;
|
|
33
33
|
--tap-gap: var(--space-5, 20px);
|
|
34
|
+
--tap-gap-bordered: calc(var(--tap-min) - var(--tap-aa) + 2px);
|
|
34
35
|
--tap-clear-x: 0px;
|
|
35
36
|
--tap-clear-y: 0px;
|
|
36
37
|
}
|
|
37
38
|
@media (max-width: 560px) and (pointer: coarse) {
|
|
38
|
-
:where(.ui-seg button, .ui-tabs__tab, .ui-dropdown__trigger, .ui-toast__action, .ui-drawer__close, .ui-snippet__copy, .ui-footer__social) {
|
|
39
|
+
:where(.ui-seg button, .ui-tabs__tab, .ui-dropdown__trigger, .ui-toast__action, .ui-drawer__close, .ui-snippet__copy, .ui-footer__social, .ui-datepicker__opt) {
|
|
39
40
|
position: relative;
|
|
40
41
|
}
|
|
41
|
-
:where(.ui-btn, .ui-seg button, .ui-tabs__tab, .ui-dropdown__trigger, .ui-toast__action, .ui-drawer__close, .ui-snippet__copy, .ui-footer__social, .ui-switch)::after {
|
|
42
|
+
:where(.ui-btn, .ui-seg button, .ui-tabs__tab, .ui-dropdown__trigger, .ui-toast__action, .ui-drawer__close, .ui-snippet__copy, .ui-footer__social, .ui-switch, .ui-datepicker__opt)::after {
|
|
42
43
|
content: "";
|
|
43
44
|
position: absolute;
|
|
44
45
|
left: 50%;
|
|
@@ -109,6 +110,19 @@
|
|
|
109
110
|
row-gap: var(--tap-gap) !important;
|
|
110
111
|
--tap-clear-y: var(--tap-gap);
|
|
111
112
|
}
|
|
113
|
+
.ui-datepicker__grid {
|
|
114
|
+
row-gap: var(--tap-gap) !important;
|
|
115
|
+
--tap-clear-x: var(--space-1, 4px);
|
|
116
|
+
--tap-clear-y: var(--tap-gap);
|
|
117
|
+
}
|
|
118
|
+
.ui-datepicker__head {
|
|
119
|
+
--tap-clear-x: var(--tap-gap-bordered);
|
|
120
|
+
--tap-clear-y: var(--tap-gap-bordered);
|
|
121
|
+
}
|
|
122
|
+
.ui-datepicker__presets {
|
|
123
|
+
--tap-clear-x: var(--space-1, 4px);
|
|
124
|
+
--tap-clear-y: var(--tap-gap-bordered);
|
|
125
|
+
}
|
|
112
126
|
.ui-footer__socials,
|
|
113
127
|
.ui-drawer__header {
|
|
114
128
|
gap: var(--tap-gap) !important;
|
|
@@ -284,6 +298,168 @@
|
|
|
284
298
|
}
|
|
285
299
|
}
|
|
286
300
|
|
|
301
|
+
/* src/DatePicker.css */
|
|
302
|
+
.ui-datepicker__panel {
|
|
303
|
+
--ui-dropdown-pad: var(--space-3);
|
|
304
|
+
width: max-content;
|
|
305
|
+
min-width: 0;
|
|
306
|
+
max-width: 92vw;
|
|
307
|
+
}
|
|
308
|
+
.ui-datepicker__body {
|
|
309
|
+
display: flex;
|
|
310
|
+
align-items: flex-start;
|
|
311
|
+
gap: var(--space-4);
|
|
312
|
+
}
|
|
313
|
+
.ui-datepicker__calendar {
|
|
314
|
+
display: grid;
|
|
315
|
+
gap: var(--space-3);
|
|
316
|
+
}
|
|
317
|
+
.ui-datepicker__head {
|
|
318
|
+
display: flex;
|
|
319
|
+
align-items: center;
|
|
320
|
+
justify-content: space-between;
|
|
321
|
+
gap: var(--space-2);
|
|
322
|
+
}
|
|
323
|
+
.ui-datepicker__caption {
|
|
324
|
+
font-size: var(--text-sm);
|
|
325
|
+
font-weight: var(--weight-semibold);
|
|
326
|
+
color: var(--strong);
|
|
327
|
+
}
|
|
328
|
+
.ui-datepicker__grid {
|
|
329
|
+
display: grid;
|
|
330
|
+
gap: var(--space-1);
|
|
331
|
+
}
|
|
332
|
+
.ui-datepicker__row {
|
|
333
|
+
display: grid;
|
|
334
|
+
grid-template-columns: repeat(3, minmax(0, 1fr));
|
|
335
|
+
gap: var(--space-1);
|
|
336
|
+
}
|
|
337
|
+
.ui-datepicker__grid.is-days .ui-datepicker__row {
|
|
338
|
+
grid-template-columns: repeat(7, minmax(0, 1fr));
|
|
339
|
+
}
|
|
340
|
+
.ui-datepicker__weekday {
|
|
341
|
+
display: flex;
|
|
342
|
+
align-items: center;
|
|
343
|
+
justify-content: center;
|
|
344
|
+
font-size: var(--text-xs);
|
|
345
|
+
font-weight: var(--weight-semibold);
|
|
346
|
+
color: var(--text);
|
|
347
|
+
}
|
|
348
|
+
.ui-datepicker__cell {
|
|
349
|
+
display: flex;
|
|
350
|
+
}
|
|
351
|
+
.ui-datepicker__opt {
|
|
352
|
+
position: relative;
|
|
353
|
+
flex: 1;
|
|
354
|
+
display: inline-flex;
|
|
355
|
+
align-items: center;
|
|
356
|
+
justify-content: center;
|
|
357
|
+
min-width: 34px;
|
|
358
|
+
min-height: 34px;
|
|
359
|
+
padding: var(--space-2);
|
|
360
|
+
font-size: var(--text-sm);
|
|
361
|
+
font-weight: var(--weight-medium);
|
|
362
|
+
font-variant-numeric: tabular-nums;
|
|
363
|
+
color: var(--text);
|
|
364
|
+
background: transparent;
|
|
365
|
+
border: 1px solid transparent;
|
|
366
|
+
border-radius: var(--radius-xs);
|
|
367
|
+
cursor: pointer;
|
|
368
|
+
transition:
|
|
369
|
+
background var(--dur-fast) var(--ease),
|
|
370
|
+
border-color var(--dur-fast) var(--ease),
|
|
371
|
+
color var(--dur-fast) var(--ease);
|
|
372
|
+
}
|
|
373
|
+
.ui-datepicker__grid.is-days .ui-datepicker__opt {
|
|
374
|
+
min-width: 30px;
|
|
375
|
+
}
|
|
376
|
+
.ui-datepicker__opt:hover {
|
|
377
|
+
outline: 1px solid var(--control-edge);
|
|
378
|
+
outline-offset: -1px;
|
|
379
|
+
background: var(--surface);
|
|
380
|
+
color: var(--strong);
|
|
381
|
+
}
|
|
382
|
+
.ui-datepicker__opt:focus-visible {
|
|
383
|
+
outline: 2px solid transparent;
|
|
384
|
+
}
|
|
385
|
+
.ui-datepicker__opt.is-inside {
|
|
386
|
+
background: color-mix(in srgb, var(--accent) 14%, var(--bg-elevated));
|
|
387
|
+
}
|
|
388
|
+
.ui-datepicker__opt.is-selected {
|
|
389
|
+
background: var(--accent-strong);
|
|
390
|
+
border-color: var(--accent-strong);
|
|
391
|
+
color: var(--accent-contrast);
|
|
392
|
+
}
|
|
393
|
+
.ui-datepicker__opt.is-selected:hover {
|
|
394
|
+
outline-color: transparent;
|
|
395
|
+
background: var(--accent-strong);
|
|
396
|
+
color: var(--accent-contrast);
|
|
397
|
+
}
|
|
398
|
+
.ui-datepicker__opt.is-today {
|
|
399
|
+
border-color: var(--accent);
|
|
400
|
+
}
|
|
401
|
+
.ui-datepicker__opt.is-today:hover {
|
|
402
|
+
outline-color: transparent;
|
|
403
|
+
}
|
|
404
|
+
.ui-datepicker__opt.is-selected.is-today {
|
|
405
|
+
border-color: var(--accent-contrast);
|
|
406
|
+
}
|
|
407
|
+
.ui-datepicker__opt.is-disabled {
|
|
408
|
+
color: var(--disabled-ink-bare);
|
|
409
|
+
cursor: not-allowed;
|
|
410
|
+
}
|
|
411
|
+
.ui-datepicker__opt.is-disabled .ui-datepicker__num {
|
|
412
|
+
text-decoration: line-through;
|
|
413
|
+
}
|
|
414
|
+
.ui-datepicker__opt.is-disabled:hover {
|
|
415
|
+
outline-color: transparent;
|
|
416
|
+
background: transparent;
|
|
417
|
+
border-color: transparent;
|
|
418
|
+
color: var(--disabled-ink-bare);
|
|
419
|
+
}
|
|
420
|
+
.ui-datepicker__opt.is-disabled.is-selected,
|
|
421
|
+
.ui-datepicker__opt.is-disabled.is-selected:hover,
|
|
422
|
+
.ui-datepicker__opt.is-disabled.is-inside,
|
|
423
|
+
.ui-datepicker__opt.is-disabled.is-inside:hover {
|
|
424
|
+
background: transparent;
|
|
425
|
+
border-color: transparent;
|
|
426
|
+
color: var(--disabled-ink-bare);
|
|
427
|
+
}
|
|
428
|
+
.ui-datepicker__opt.is-disabled.is-selected {
|
|
429
|
+
font-weight: var(--weight-bold);
|
|
430
|
+
}
|
|
431
|
+
.ui-datepicker__opt.is-disabled.is-today,
|
|
432
|
+
.ui-datepicker__opt.is-disabled.is-today:hover {
|
|
433
|
+
border-color: var(--accent);
|
|
434
|
+
}
|
|
435
|
+
.ui-datepicker__presets {
|
|
436
|
+
display: grid;
|
|
437
|
+
align-content: start;
|
|
438
|
+
gap: var(--space-1);
|
|
439
|
+
padding: 0 var(--space-3) 0 0;
|
|
440
|
+
border-inline-end: 1px solid var(--border);
|
|
441
|
+
}
|
|
442
|
+
.ui-datepicker__preset {
|
|
443
|
+
justify-content: flex-start;
|
|
444
|
+
}
|
|
445
|
+
.ui-datepicker__body.is-sheet {
|
|
446
|
+
flex-direction: column;
|
|
447
|
+
align-items: stretch;
|
|
448
|
+
}
|
|
449
|
+
.ui-datepicker__body.is-sheet .ui-datepicker__presets {
|
|
450
|
+
grid-auto-flow: column;
|
|
451
|
+
grid-auto-columns: max-content;
|
|
452
|
+
overflow-x: auto;
|
|
453
|
+
scroll-padding-inline: var(--space-1);
|
|
454
|
+
padding: var(--space-3) var(--space-1);
|
|
455
|
+
border-inline-end: 0;
|
|
456
|
+
border-block-end: 1px solid var(--border);
|
|
457
|
+
}
|
|
458
|
+
.ui-datepicker__body.is-sheet .ui-datepicker__presets:focus-visible {
|
|
459
|
+
outline: var(--ring-scroll);
|
|
460
|
+
outline-offset: var(--ring-scroll-offset);
|
|
461
|
+
}
|
|
462
|
+
|
|
287
463
|
/* src/KeyValueList.css */
|
|
288
464
|
.ui-kv {
|
|
289
465
|
display: grid;
|
package/react/dist/index.d.ts
CHANGED
|
@@ -325,6 +325,69 @@ type DeniedProps = {
|
|
|
325
325
|
};
|
|
326
326
|
declare function Denied({ title, sub, need, icon, className, children, }: DeniedProps): react.JSX.Element;
|
|
327
327
|
|
|
328
|
+
/**
|
|
329
|
+
* `'month'` and `'range'` work in whole months, `'day'` and `'day-range'` in
|
|
330
|
+
* whole dates. The two range modes behave alike: a start, then an end, with the
|
|
331
|
+
* days or months between them shown as the span.
|
|
332
|
+
*/
|
|
333
|
+
type DatePickerMode = 'month' | 'range' | 'day' | 'day-range';
|
|
334
|
+
/** Either end may be null while the reader is still picking. */
|
|
335
|
+
type DatePickerRange = {
|
|
336
|
+
start: string | null;
|
|
337
|
+
end: string | null;
|
|
338
|
+
};
|
|
339
|
+
type DatePickerPreset = {
|
|
340
|
+
label: string;
|
|
341
|
+
range: DatePickerRange;
|
|
342
|
+
};
|
|
343
|
+
type DatePickerProps = {
|
|
344
|
+
mode?: DatePickerMode;
|
|
345
|
+
/** `'YYYY-MM'` in month mode, `'YYYY-MM-DD'` in day mode. Controlled. */
|
|
346
|
+
value?: string | null;
|
|
347
|
+
/** Where an uncontrolled picker starts. */
|
|
348
|
+
defaultValue?: string | null;
|
|
349
|
+
onChange?: (value: string | null) => void;
|
|
350
|
+
/** Range mode, controlled. */
|
|
351
|
+
range?: DatePickerRange;
|
|
352
|
+
defaultRange?: DatePickerRange;
|
|
353
|
+
/** Fires on each end, so a half-picked range is visible to the host too. */
|
|
354
|
+
onRangeChange?: (range: DatePickerRange) => void;
|
|
355
|
+
/** Bounds, inclusive, in the mode's own grain. */
|
|
356
|
+
min?: string;
|
|
357
|
+
max?: string;
|
|
358
|
+
/** Periods that cannot be picked, in the mode's own grain. */
|
|
359
|
+
disabledPeriods?: readonly string[];
|
|
360
|
+
/** Range mode: the shortcuts beside the grid. */
|
|
361
|
+
presets?: readonly DatePickerPreset[];
|
|
362
|
+
placeholder?: string;
|
|
363
|
+
/**
|
|
364
|
+
* Names the trigger and the panel where the screen around them does not.
|
|
365
|
+
* With a value, the trigger's own text is already its name.
|
|
366
|
+
*/
|
|
367
|
+
ariaLabel?: string;
|
|
368
|
+
id?: string;
|
|
369
|
+
disabled?: boolean;
|
|
370
|
+
/** The edge the panel hugs. */
|
|
371
|
+
align?: 'start' | 'end';
|
|
372
|
+
/** Month and weekday names come from here. */
|
|
373
|
+
locale?: string;
|
|
374
|
+
/** 0 is Sunday. Day mode only. */
|
|
375
|
+
weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
376
|
+
/** `'YYYY-MM-DD'`. Given one, the grid marks it; stories and tests pass it to stay fixed. */
|
|
377
|
+
today?: string;
|
|
378
|
+
/**
|
|
379
|
+
* Render the sheet rather than the popover whatever the viewport is. Left
|
|
380
|
+
* out, the picker follows the kit's narrowest step. A host that already knows
|
|
381
|
+
* it is on a phone — or renders on a server, where no viewport is readable —
|
|
382
|
+
* says so here.
|
|
383
|
+
*/
|
|
384
|
+
sheet?: boolean;
|
|
385
|
+
open?: boolean;
|
|
386
|
+
defaultOpen?: boolean;
|
|
387
|
+
onOpenChange?: (open: boolean) => void;
|
|
388
|
+
};
|
|
389
|
+
declare function DatePicker({ mode, value, defaultValue, onChange, range, defaultRange, onRangeChange, min, max, disabledPeriods, presets, placeholder, ariaLabel, id, disabled, align, locale, weekStartsOn, today, sheet, open: openProp, defaultOpen, onOpenChange, }: DatePickerProps): react.JSX.Element;
|
|
390
|
+
|
|
328
391
|
type DropdownBadge = string | {
|
|
329
392
|
text: string;
|
|
330
393
|
tone?: string;
|
|
@@ -868,4 +931,4 @@ declare const SidebarNav: react.ForwardRefExoticComponent<Omit<Omit<react.Detail
|
|
|
868
931
|
declare const PAGE_SIZES: readonly number[];
|
|
869
932
|
declare const DEFAULT_PAGE_SIZE: number;
|
|
870
933
|
|
|
871
|
-
export { AppShell, type AppShellProps, type AppShellSection, BackLink, type BackLinkOwnProps, type BackLinkProps, Badge, BusyRegion, type BusyRegionProps, Button, type ButtonLinkProps, type ButtonProps, Callout, type CalloutProps, type CalloutVariant, Card, Checkbox, type CheckboxProps, type Column, type CommandGroup, type CommandItem, CommandPalette, type CommandPaletteProps, Confirm, type ConfirmProps, DEFAULT_PAGE_SIZE, DataTable, type DataTableProps, DeltaValue, type DeltaValueProps, Denied, type DeniedProps, Drawer, type DrawerProps, DrawerSection, type DrawerSectionProps, Dropdown, type DropdownBadge, type DropdownEntry, type DropdownItem, type DropdownProps, type DropdownRowProps, type DropdownSearch, type DropdownSection, type DropdownSeparator, EmptyState, type EmptyStateProps, type EmptyStateVariant, Field, type FieldControlProps, type FieldProps, FileDrop, type FileDropFile, type FileDropProps, type FileDropStatus, FileField, type FileFieldProps, type Filter, FilterBar, type FilterBarProps, Icon, KeyValueList, type KeyValueListProps, type KeyValueRow, Modal, type ModalProps, type NativeButtonProps, NumericValue, type NumericValueProps, PAGE_SIZES, Pagination, type PaginationProps, Pill, type PillProps, RowIdentity, type RowIdentityProps, SearchField, type SearchFieldProps, type SegmentOption, Segmented, type SegmentedProps, SelectField, type SelectFieldProps, SidebarNav, type SidebarNavBadge, type SidebarNavItem, type SidebarNavLeaf, type SidebarNavProps, type SidebarNavSection, Skeleton, type SkeletonProps, SkeletonTable, type SkeletonTableProps, Snippet, type SnippetProps, StatBand, type StatBandProps, type StatDelta, type StatFigure, type StatTone, type StatVariant, StatusDot, type StatusDotProps, Success, SuccessCheck, type SuccessCheckProps, type SuccessCountdown, SuccessPanel, type SuccessPanelProps, type SuccessProps, Switch, type SwitchProps, THEME_INIT_SCRIPT, type TabItem, type TableSort, Tabs, type TabsProps, TextArea, type TextAreaProps, TextField, type TextFieldProps, ThemeToggle, type ThemeToggleProps, Timeline, type TimelineEvent, type TimelineEventKind, type TimelineProps, Toast, type ToastNotice, type ToastProps, Tooltip, type TooltipProps, sortTableRows, useToast };
|
|
934
|
+
export { AppShell, type AppShellProps, type AppShellSection, BackLink, type BackLinkOwnProps, type BackLinkProps, Badge, BusyRegion, type BusyRegionProps, Button, type ButtonLinkProps, type ButtonProps, Callout, type CalloutProps, type CalloutVariant, Card, Checkbox, type CheckboxProps, type Column, type CommandGroup, type CommandItem, CommandPalette, type CommandPaletteProps, Confirm, type ConfirmProps, DEFAULT_PAGE_SIZE, DataTable, type DataTableProps, DatePicker, type DatePickerMode, type DatePickerPreset, type DatePickerProps, type DatePickerRange, DeltaValue, type DeltaValueProps, Denied, type DeniedProps, Drawer, type DrawerProps, DrawerSection, type DrawerSectionProps, Dropdown, type DropdownBadge, type DropdownEntry, type DropdownItem, type DropdownProps, type DropdownRowProps, type DropdownSearch, type DropdownSection, type DropdownSeparator, EmptyState, type EmptyStateProps, type EmptyStateVariant, Field, type FieldControlProps, type FieldProps, FileDrop, type FileDropFile, type FileDropProps, type FileDropStatus, FileField, type FileFieldProps, type Filter, FilterBar, type FilterBarProps, Icon, KeyValueList, type KeyValueListProps, type KeyValueRow, Modal, type ModalProps, type NativeButtonProps, NumericValue, type NumericValueProps, PAGE_SIZES, Pagination, type PaginationProps, Pill, type PillProps, RowIdentity, type RowIdentityProps, SearchField, type SearchFieldProps, type SegmentOption, Segmented, type SegmentedProps, SelectField, type SelectFieldProps, SidebarNav, type SidebarNavBadge, type SidebarNavItem, type SidebarNavLeaf, type SidebarNavProps, type SidebarNavSection, Skeleton, type SkeletonProps, SkeletonTable, type SkeletonTableProps, Snippet, type SnippetProps, StatBand, type StatBandProps, type StatDelta, type StatFigure, type StatTone, type StatVariant, StatusDot, type StatusDotProps, Success, SuccessCheck, type SuccessCheckProps, type SuccessCountdown, SuccessPanel, type SuccessPanelProps, type SuccessProps, Switch, type SwitchProps, THEME_INIT_SCRIPT, type TabItem, type TableSort, Tabs, type TabsProps, TextArea, type TextAreaProps, TextField, type TextFieldProps, ThemeToggle, type ThemeToggleProps, Timeline, type TimelineEvent, type TimelineEventKind, type TimelineProps, Toast, type ToastNotice, type ToastProps, Tooltip, type TooltipProps, sortTableRows, useToast };
|