@dimaan/ui 0.0.27 → 0.0.29
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/dist/index.cjs +330 -96
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +149 -14
- package/dist/index.d.ts +149 -14
- package/dist/index.js +316 -98
- package/dist/index.js.map +1 -1
- package/dist/preset.css +73 -6
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -213,6 +213,23 @@ interface SidebarNavGroupProps extends Omit<ButtonHTMLAttributes<HTMLButtonEleme
|
|
|
213
213
|
onOpenChange?: (open: boolean) => void;
|
|
214
214
|
children: ReactNode;
|
|
215
215
|
}
|
|
216
|
+
/**
|
|
217
|
+
* Collapsible group of nav links inside a `<SidebarNav>`.
|
|
218
|
+
*
|
|
219
|
+
* Route-aware out of the box: when one of its `<SidebarNavItem>` children
|
|
220
|
+
* matches the current route, the group auto-opens and highlights itself — no
|
|
221
|
+
* need to wire `active`/`open` by hand. It opens on navigation into a child but
|
|
222
|
+
* stays user-closable; pass `open`/`onOpenChange` for full control, or
|
|
223
|
+
* `defaultOpen` / `active` to override the initial/derived state.
|
|
224
|
+
*
|
|
225
|
+
* @example
|
|
226
|
+
* ```tsx
|
|
227
|
+
* <SidebarNavGroup label="Platform" icon={<Settings />}>
|
|
228
|
+
* <SidebarNavItem to="/platform/branches">Branches</SidebarNavItem>
|
|
229
|
+
* <SidebarNavItem to="/platform/warehouses">Warehouses</SidebarNavItem>
|
|
230
|
+
* </SidebarNavGroup>
|
|
231
|
+
* ```
|
|
232
|
+
*/
|
|
216
233
|
declare function SidebarNavGroup({ icon, label, endSlot, active, defaultOpen, open: openProp, onOpenChange, className, children, onClick, ...props }: SidebarNavGroupProps): react_jsx_runtime.JSX.Element;
|
|
217
234
|
|
|
218
235
|
type SidebarNavItemRenderProps = {
|
|
@@ -351,7 +368,15 @@ declare function Avatar({ src, alt, fallback, size, className, ...props }: Avata
|
|
|
351
368
|
|
|
352
369
|
type BadgeVariant = 'default' | 'primary' | 'success' | 'warning' | 'destructive' | 'outline';
|
|
353
370
|
type BadgeSize = 'sm' | 'md';
|
|
371
|
+
type BadgeTone = 'solid' | 'soft';
|
|
354
372
|
declare const badgeVariantClass: Record<BadgeVariant, string>;
|
|
373
|
+
/**
|
|
374
|
+
* Soft / tinted tone — a translucent fill of each status color with dark-on-light
|
|
375
|
+
* (light-on-dark in dark mode) text. Calmer than the solid fills; preferred for
|
|
376
|
+
* status columns in dense data tables. `default` and `outline` are already calm, so
|
|
377
|
+
* their soft tone matches the solid tone.
|
|
378
|
+
*/
|
|
379
|
+
declare const badgeSoftVariantClass: Record<BadgeVariant, string>;
|
|
355
380
|
declare const badgeSizeClass: Record<BadgeSize, string>;
|
|
356
381
|
/** The dot-indicator size for each badge size. */
|
|
357
382
|
declare const badgeDotSizeClass: Record<BadgeSize, string>;
|
|
@@ -360,6 +385,11 @@ declare const badgeBaseClass = "inline-flex shrink-0 items-center rounded-full b
|
|
|
360
385
|
interface BadgeProps extends HTMLAttributes<HTMLSpanElement> {
|
|
361
386
|
variant?: BadgeVariant;
|
|
362
387
|
size?: BadgeSize;
|
|
388
|
+
/**
|
|
389
|
+
* Visual tone. `'solid'` (default) is a full-color fill; `'soft'` is a calmer
|
|
390
|
+
* tinted fill — preferred for status columns in dense data tables.
|
|
391
|
+
*/
|
|
392
|
+
tone?: BadgeTone;
|
|
363
393
|
/** Render a small dot before the label (useful for online/status indicators). */
|
|
364
394
|
dot?: boolean;
|
|
365
395
|
}
|
|
@@ -374,6 +404,12 @@ interface BadgeProps extends HTMLAttributes<HTMLSpanElement> {
|
|
|
374
404
|
* <Badge variant="default">Archived</Badge>
|
|
375
405
|
* ```
|
|
376
406
|
*
|
|
407
|
+
* @example Soft tone — calmer status pills for data tables
|
|
408
|
+
* ```tsx
|
|
409
|
+
* <Badge variant="success" tone="soft">Active</Badge>
|
|
410
|
+
* <Badge variant="warning" tone="soft">Pending</Badge>
|
|
411
|
+
* ```
|
|
412
|
+
*
|
|
377
413
|
* @example With status dot
|
|
378
414
|
* ```tsx
|
|
379
415
|
* <Badge variant="success" dot>Online</Badge>
|
|
@@ -436,6 +472,48 @@ interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
436
472
|
*/
|
|
437
473
|
declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
438
474
|
|
|
475
|
+
type CardProps = HTMLAttributes<HTMLDivElement>;
|
|
476
|
+
/**
|
|
477
|
+
* Elevated content container — a rounded surface with a soft shadow and hairline
|
|
478
|
+
* border, matching the data table and filter panel so everything reads as one
|
|
479
|
+
* system. Compose with `CardHeader` / `CardTitle` / `CardDescription` /
|
|
480
|
+
* `CardContent` / `CardFooter`, or drop any content straight in.
|
|
481
|
+
*
|
|
482
|
+
* @example
|
|
483
|
+
* ```tsx
|
|
484
|
+
* <Card>
|
|
485
|
+
* <CardHeader>
|
|
486
|
+
* <CardTitle>Team members</CardTitle>
|
|
487
|
+
* <CardDescription>Manage who has access.</CardDescription>
|
|
488
|
+
* </CardHeader>
|
|
489
|
+
* <CardContent>…</CardContent>
|
|
490
|
+
* <CardFooter>
|
|
491
|
+
* <Button>Save</Button>
|
|
492
|
+
* </CardFooter>
|
|
493
|
+
* </Card>
|
|
494
|
+
* ```
|
|
495
|
+
*/
|
|
496
|
+
declare const Card: react.ForwardRefExoticComponent<CardProps & react.RefAttributes<HTMLDivElement>>;
|
|
497
|
+
/** Top section of a card — stack a `CardTitle` (+ optional `CardDescription`) here. */
|
|
498
|
+
declare const CardHeader: react.ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & react.RefAttributes<HTMLDivElement>>;
|
|
499
|
+
declare const CardTitle: react.ForwardRefExoticComponent<HTMLAttributes<HTMLHeadingElement> & react.RefAttributes<HTMLHeadingElement>>;
|
|
500
|
+
declare const CardDescription: react.ForwardRefExoticComponent<HTMLAttributes<HTMLParagraphElement> & react.RefAttributes<HTMLParagraphElement>>;
|
|
501
|
+
/** Main body of a card. */
|
|
502
|
+
declare const CardContent: react.ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & react.RefAttributes<HTMLDivElement>>;
|
|
503
|
+
/** Trailing actions row of a card (e.g. buttons). */
|
|
504
|
+
declare const CardFooter: react.ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & react.RefAttributes<HTMLDivElement>>;
|
|
505
|
+
|
|
506
|
+
/**
|
|
507
|
+
* Elevated card surface — soft shadow, hairline border, rounded corners. Matches
|
|
508
|
+
* the data-table / filter-panel elevation so cards read as part of one system.
|
|
509
|
+
*/
|
|
510
|
+
declare const cardBaseClass = "rounded-xl border border-border bg-card text-card-foreground shadow-[var(--shadow-card)]";
|
|
511
|
+
declare const cardHeaderClass = "flex flex-col gap-1.5 p-6";
|
|
512
|
+
declare const cardTitleClass = "text-lg font-semibold leading-none tracking-tight text-foreground";
|
|
513
|
+
declare const cardDescriptionClass = "text-sm text-muted-foreground";
|
|
514
|
+
declare const cardContentClass = "p-6 pt-0";
|
|
515
|
+
declare const cardFooterClass = "flex items-center gap-2 p-6 pt-0";
|
|
516
|
+
|
|
439
517
|
type CheckboxSize = 'sm' | 'md';
|
|
440
518
|
interface CheckboxProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'size' | 'onChange'> {
|
|
441
519
|
/** Tri-state visual: when true, renders a dash and sets `aria-checked="mixed"`. */
|
|
@@ -456,7 +534,7 @@ declare const datePickerTriggerVariantClass: Record<DatePickerVariant, string>;
|
|
|
456
534
|
* Logical properties keep RTL working free.
|
|
457
535
|
*/
|
|
458
536
|
declare const datePickerTriggerSizeClass: Record<DatePickerSize, string>;
|
|
459
|
-
declare const datePickerTriggerBaseClass = "group/datepicker relative inline-flex w-full items-center text-foreground outline-none transition-[background-color,border-color,box-shadow] focus-visible:ring-
|
|
537
|
+
declare const datePickerTriggerBaseClass = "group/datepicker relative inline-flex w-full items-center text-foreground outline-none transition-[background-color,border-color,box-shadow] focus-visible:ring-[3px] focus-visible:ring-primary-glow aria-[invalid=true]:border-destructive aria-[invalid=true]:focus-visible:ring-destructive/40 disabled:pointer-events-none disabled:opacity-50 cursor-pointer";
|
|
460
538
|
/** Empty-state trigger text (placeholder color). */
|
|
461
539
|
declare const datePickerPlaceholderClass = "truncate text-muted-foreground";
|
|
462
540
|
/** Filled-state trigger text. */
|
|
@@ -468,7 +546,7 @@ declare const datePickerCalendarClass = "text-sm";
|
|
|
468
546
|
/** Month/year caption row. */
|
|
469
547
|
declare const datePickerCaptionClass = "flex items-center justify-between gap-2 pb-2 text-sm font-semibold";
|
|
470
548
|
/** Prev/Next nav buttons. */
|
|
471
|
-
declare const datePickerNavButtonClass = "inline-flex
|
|
549
|
+
declare const datePickerNavButtonClass = "inline-flex size-7 items-center justify-center rounded-md border border-input bg-background text-foreground transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/40 disabled:pointer-events-none disabled:opacity-50";
|
|
472
550
|
/** Day cell wrapper (`td`). */
|
|
473
551
|
declare const datePickerDayWrapperClass = "p-0 text-center";
|
|
474
552
|
/**
|
|
@@ -476,7 +554,7 @@ declare const datePickerDayWrapperClass = "p-0 text-center";
|
|
|
476
554
|
* today, outside-month, disabled) are applied to the wrapping day **cell** by
|
|
477
555
|
* react-day-picker and target the button via descendant selectors below.
|
|
478
556
|
*/
|
|
479
|
-
declare const datePickerDayBaseClass = "inline-flex
|
|
557
|
+
declare const datePickerDayBaseClass = "inline-flex size-8 items-center justify-center rounded-md text-sm text-foreground font-normal transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/40";
|
|
480
558
|
/** Day cell modifier — applied to the currently selected day. Targets the inner button. */
|
|
481
559
|
declare const datePickerSelectedClass = "[&_button]:bg-primary [&_button]:text-primary-foreground [&_button]:hover:bg-primary [&_button]:hover:text-primary-foreground";
|
|
482
560
|
/** Day cell modifier — applied to today. */
|
|
@@ -486,7 +564,7 @@ declare const datePickerOutsideClass = "[&_button]:text-muted-foreground [&_butt
|
|
|
486
564
|
/** Day cell modifier — applied to days outside min/max bounds (or custom matcher). */
|
|
487
565
|
declare const datePickerDisabledClass = "[&_button]:pointer-events-none [&_button]:opacity-40";
|
|
488
566
|
/** Weekday header cells. */
|
|
489
|
-
declare const datePickerWeekdayClass = "
|
|
567
|
+
declare const datePickerWeekdayClass = "size-8 text-center text-xs font-medium text-muted-foreground";
|
|
490
568
|
/** Week row. */
|
|
491
569
|
declare const datePickerWeekClass = "flex w-full";
|
|
492
570
|
/** Weekdays row. */
|
|
@@ -707,7 +785,7 @@ declare const detailPageBodyClass = "flex flex-col gap-6";
|
|
|
707
785
|
*/
|
|
708
786
|
declare const detailPageSkeletonRowClass = "h-5 w-full animate-pulse rounded-md bg-muted";
|
|
709
787
|
/** Container around the not-found `<EmptyState>` — matches the ListPage empty surface. */
|
|
710
|
-
declare const detailPageEmptyClass = "rounded-
|
|
788
|
+
declare const detailPageEmptyClass = "rounded-xl border border-border bg-card";
|
|
711
789
|
|
|
712
790
|
/**
|
|
713
791
|
* Modal dialog built on `@radix-ui/react-dialog`. Compound API — same shape as
|
|
@@ -1295,7 +1373,7 @@ type InputVariant = 'default' | 'filled' | 'ghost';
|
|
|
1295
1373
|
type InputSize = 'sm' | 'md' | 'lg';
|
|
1296
1374
|
declare const inputVariantClass: Record<InputVariant, string>;
|
|
1297
1375
|
declare const inputSizeClass: Record<InputSize, string>;
|
|
1298
|
-
declare const inputBaseClass = "group/input relative inline-flex w-full items-center text-foreground outline-none transition-[background-color,border-color,box-shadow] focus-within:ring-
|
|
1376
|
+
declare const inputBaseClass = "group/input relative inline-flex w-full items-center text-foreground outline-none transition-[background-color,border-color,box-shadow] focus-within:ring-[3px] focus-within:ring-primary-glow aria-[invalid=true]:border-destructive aria-[invalid=true]:focus-within:ring-destructive/40 has-[input:disabled]:pointer-events-none has-[input:disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0";
|
|
1299
1377
|
|
|
1300
1378
|
interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'prefix'> {
|
|
1301
1379
|
variant?: InputVariant;
|
|
@@ -1367,8 +1445,8 @@ interface TableSizeClasses {
|
|
|
1367
1445
|
}
|
|
1368
1446
|
declare const tableSizeClass: Record<TableSize, TableSizeClasses>;
|
|
1369
1447
|
declare const tableBaseClass = "w-full caption-bottom border-collapse";
|
|
1370
|
-
declare const selectedRowClass = "bg-
|
|
1371
|
-
declare const sortIconClass = "inline-flex
|
|
1448
|
+
declare const selectedRowClass = "bg-primary/10";
|
|
1449
|
+
declare const sortIconClass = "inline-flex size-3 shrink-0 items-center justify-center";
|
|
1372
1450
|
declare const alignClass: Record<ColumnAlign, string>;
|
|
1373
1451
|
|
|
1374
1452
|
type SortDirection = 'asc' | 'desc';
|
|
@@ -1514,7 +1592,7 @@ declare const selectVariantClass: Record<SelectVariant, string>;
|
|
|
1514
1592
|
* properties keep RTL working free.
|
|
1515
1593
|
*/
|
|
1516
1594
|
declare const selectSizeClass: Record<SelectSize, string>;
|
|
1517
|
-
declare const selectBaseClass = "group/select relative inline-flex w-full items-center text-foreground outline-none transition-[background-color,border-color,box-shadow] focus:ring-
|
|
1595
|
+
declare const selectBaseClass = "group/select relative inline-flex w-full items-center text-foreground outline-none transition-[background-color,border-color,box-shadow] focus:ring-[3px] focus:ring-primary-glow aria-[invalid=true]:border-destructive aria-[invalid=true]:focus:ring-destructive/40 disabled:pointer-events-none disabled:opacity-50 cursor-pointer data-[placeholder]:text-muted-foreground";
|
|
1518
1596
|
|
|
1519
1597
|
interface SelectOption {
|
|
1520
1598
|
value: string;
|
|
@@ -1538,6 +1616,17 @@ interface SelectProps {
|
|
|
1538
1616
|
options?: SelectOptions;
|
|
1539
1617
|
/** Placeholder shown when no value is selected. */
|
|
1540
1618
|
placeholder?: string;
|
|
1619
|
+
/**
|
|
1620
|
+
* Show a loading indicator — in the trigger (when a `value` is set but its
|
|
1621
|
+
* option hasn't arrived yet) and as a row inside the popup. Use it while the
|
|
1622
|
+
* `options` are still being fetched so the control reads as "loading" instead
|
|
1623
|
+
* of blank. Flip back to `false` once the data lands.
|
|
1624
|
+
*/
|
|
1625
|
+
loading?: boolean;
|
|
1626
|
+
/** Message shown while `loading`. Defaults to `'Loading…'`. */
|
|
1627
|
+
loadingText?: ReactNode;
|
|
1628
|
+
/** Message shown when `options` is empty (and not loading). Defaults to `'No options'`. */
|
|
1629
|
+
emptyText?: ReactNode;
|
|
1541
1630
|
/** Controlled value. */
|
|
1542
1631
|
value?: string;
|
|
1543
1632
|
/** Initial value for uncontrolled usage. */
|
|
@@ -1598,6 +1687,19 @@ interface SelectProps {
|
|
|
1598
1687
|
* { label: 'Levant', options: [{ value: 'jo', label: 'Jordan' }] },
|
|
1599
1688
|
* ]} />
|
|
1600
1689
|
* ```
|
|
1690
|
+
*
|
|
1691
|
+
* @example Async options (edit page) — show loading, then the fetched value
|
|
1692
|
+
* ```tsx
|
|
1693
|
+
* <Select
|
|
1694
|
+
* options={categories} // [] until the request resolves
|
|
1695
|
+
* loading={isLoading} // spinner in the trigger + popup meanwhile
|
|
1696
|
+
* value={String(item.categoryId)} // ⚠️ value must be a string that matches an option's value
|
|
1697
|
+
* onValueChange={(v) => setCategoryId(Number(v))}
|
|
1698
|
+
* placeholder="Category"
|
|
1699
|
+
* loadingText="جارٍ التحميل…"
|
|
1700
|
+
* emptyText="لا توجد عناصر"
|
|
1701
|
+
* />
|
|
1702
|
+
* ```
|
|
1601
1703
|
*/
|
|
1602
1704
|
declare const Select: react.ForwardRefExoticComponent<SelectProps & react.RefAttributes<HTMLButtonElement>>;
|
|
1603
1705
|
|
|
@@ -1680,6 +1782,10 @@ interface ListPageLabels extends TableLabels {
|
|
|
1680
1782
|
reset?: string;
|
|
1681
1783
|
/** "Apply" button label — shown in `manual` filter mode (the default). */
|
|
1682
1784
|
apply?: string;
|
|
1785
|
+
/** Filter-panel header title. Defaults to "Filters". */
|
|
1786
|
+
filtersTitle?: string;
|
|
1787
|
+
/** Word after the active-filter count, e.g. "active" → "2 active". */
|
|
1788
|
+
filtersActive?: string;
|
|
1683
1789
|
/** "No results matching filters" title. */
|
|
1684
1790
|
emptyTitle?: string;
|
|
1685
1791
|
/** "No results matching filters" description. */
|
|
@@ -1692,6 +1798,8 @@ interface ListPageLabels extends TableLabels {
|
|
|
1692
1798
|
interface ListPageProps<T> {
|
|
1693
1799
|
title: ReactNode;
|
|
1694
1800
|
description?: ReactNode;
|
|
1801
|
+
/** Small uppercase label above the title (forwarded to `PageHeader`). */
|
|
1802
|
+
eyebrow?: ReactNode;
|
|
1695
1803
|
/** Page-header bordered separator. Defaults to `true`. */
|
|
1696
1804
|
bordered?: boolean;
|
|
1697
1805
|
/** Header action slot — primary "Add" button, etc. */
|
|
@@ -1804,13 +1912,15 @@ interface ListPageProps<T> {
|
|
|
1804
1912
|
* );
|
|
1805
1913
|
* ```
|
|
1806
1914
|
*/
|
|
1807
|
-
declare function ListPage<T>({ title, description, bordered, actions, data, columns, getRowId, isLoading, loadingRowCount, filters, filterValues, onFilterChange, filterMode, enableRowSelection, bulkActions, pagination, onPaginationChange, totalCount, pageSizeOptions, emptyState, noDataState, labels: labelsProp, className, }: ListPageProps<T>): react_jsx_runtime.JSX.Element;
|
|
1915
|
+
declare function ListPage<T>({ title, description, bordered, actions, data, columns, getRowId, isLoading, loadingRowCount, filters, filterValues, onFilterChange, filterMode, enableRowSelection, bulkActions, pagination, onPaginationChange, totalCount, eyebrow, pageSizeOptions, emptyState, noDataState, labels: labelsProp, className, }: ListPageProps<T>): react_jsx_runtime.JSX.Element;
|
|
1808
1916
|
|
|
1809
1917
|
interface MultiSelectLabels {
|
|
1810
1918
|
/** Search input placeholder. Direction-aware default: `"Search…"` / `"بحث…"`. */
|
|
1811
1919
|
search?: string;
|
|
1812
1920
|
/** Empty-state text when the search matches nothing. Default: `"No results"` / `"لا نتائج"`. */
|
|
1813
1921
|
empty?: string;
|
|
1922
|
+
/** Loading text shown while `loading`. Default: `"Loading…"` / `"جارٍ التحميل…"`. */
|
|
1923
|
+
loading?: string;
|
|
1814
1924
|
}
|
|
1815
1925
|
interface MultiSelectProps {
|
|
1816
1926
|
variant?: SelectVariant;
|
|
@@ -1820,6 +1930,12 @@ interface MultiSelectProps {
|
|
|
1820
1930
|
options: SelectOption[];
|
|
1821
1931
|
/** Placeholder shown when nothing is selected. */
|
|
1822
1932
|
placeholder?: string;
|
|
1933
|
+
/**
|
|
1934
|
+
* Show a loading indicator — in the trigger and as a row inside the popup —
|
|
1935
|
+
* while the `options` are still being fetched. Flip back to `false` once the
|
|
1936
|
+
* data lands. The empty state (`labels.empty`) covers a resolved empty list.
|
|
1937
|
+
*/
|
|
1938
|
+
loading?: boolean;
|
|
1823
1939
|
/** Controlled value (array of selected option values). */
|
|
1824
1940
|
value?: string[];
|
|
1825
1941
|
/** Initial value for uncontrolled usage. */
|
|
@@ -1876,6 +1992,17 @@ interface MultiSelectProps {
|
|
|
1876
1992
|
* aria-label="Roles filter"
|
|
1877
1993
|
* />
|
|
1878
1994
|
* ```
|
|
1995
|
+
*
|
|
1996
|
+
* @example Async options — show loading while fetching
|
|
1997
|
+
* ```tsx
|
|
1998
|
+
* <MultiSelect
|
|
1999
|
+
* options={roleOptions} // [] until the request resolves
|
|
2000
|
+
* loading={isLoading} // spinner in the trigger + popup meanwhile
|
|
2001
|
+
* value={roleIds.map(String)} // ⚠️ values must be strings matching option values
|
|
2002
|
+
* onValueChange={setRoleIds}
|
|
2003
|
+
* placeholder="Roles"
|
|
2004
|
+
* />
|
|
2005
|
+
* ```
|
|
1879
2006
|
*/
|
|
1880
2007
|
declare const MultiSelect: react.ForwardRefExoticComponent<MultiSelectProps & react.RefAttributes<HTMLDivElement>>;
|
|
1881
2008
|
|
|
@@ -1927,6 +2054,10 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLElement>, 'title'> {
|
|
|
1927
2054
|
title: ReactNode;
|
|
1928
2055
|
/** Optional secondary text under the title. */
|
|
1929
2056
|
description?: ReactNode;
|
|
2057
|
+
/** Small uppercase label above the title (a category / section eyebrow). */
|
|
2058
|
+
eyebrow?: ReactNode;
|
|
2059
|
+
/** Inline slot right after the title — e.g. a count badge. */
|
|
2060
|
+
titleMeta?: ReactNode;
|
|
1930
2061
|
/** Slot above the title for breadcrumbs (e.g. `<Breadcrumbs items={…} />` or your own JSX). */
|
|
1931
2062
|
breadcrumbs?: ReactNode;
|
|
1932
2063
|
/** Optional back button rendered above the title row. */
|
|
@@ -1999,6 +2130,10 @@ declare const pageHeaderBorderedClass = "border-b border-border pb-4";
|
|
|
1999
2130
|
declare const pageHeaderTitleRowClass = "flex flex-wrap items-start justify-between gap-3 sm:gap-4";
|
|
2000
2131
|
declare const pageHeaderTitleBlockClass = "min-w-0 flex-1 space-y-1";
|
|
2001
2132
|
declare const pageHeaderTitleClass = "text-2xl font-semibold tracking-tight text-foreground";
|
|
2133
|
+
declare const pageHeaderEyebrowClass = "text-xs font-semibold uppercase tracking-wide text-primary";
|
|
2134
|
+
/** Wraps the title and its inline meta slot (e.g. a count badge) on one line. */
|
|
2135
|
+
declare const pageHeaderTitleLineClass = "flex flex-wrap items-center gap-x-2.5 gap-y-1";
|
|
2136
|
+
declare const pageHeaderTitleMetaClass = "shrink-0";
|
|
2002
2137
|
declare const pageHeaderDescriptionClass = "text-sm text-muted-foreground";
|
|
2003
2138
|
declare const pageHeaderActionsClass = "flex shrink-0 flex-wrap items-center gap-2";
|
|
2004
2139
|
declare const pageHeaderBackClass = "inline-flex items-center gap-1.5 self-start text-sm text-muted-foreground transition-colors hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/40 focus-visible:ring-offset-2 focus-visible:ring-offset-background rounded-md";
|
|
@@ -2012,7 +2147,7 @@ declare const radioItemSizeClass: Record<RadioGroupSize, string>;
|
|
|
2012
2147
|
declare const radioIndicatorSizeClass: Record<RadioGroupSize, string>;
|
|
2013
2148
|
/** Label text size that pairs naturally with each radio size. */
|
|
2014
2149
|
declare const radioLabelSizeClass: Record<RadioGroupSize, string>;
|
|
2015
|
-
declare const radioItemBaseClass = "aspect-square shrink-0 rounded-full border border-input bg-background text-primary outline-none transition-colors focus-visible:ring-
|
|
2150
|
+
declare const radioItemBaseClass = "aspect-square shrink-0 rounded-full border border-input bg-background text-primary outline-none transition-colors focus-visible:ring-[3px] focus-visible:ring-primary-glow hover:border-ring disabled:cursor-not-allowed disabled:opacity-50 aria-[invalid=true]:border-destructive aria-[invalid=true]:focus-visible:ring-destructive/40 data-[state=checked]:border-primary";
|
|
2016
2151
|
declare const radioIndicatorBaseClass = "flex h-full w-full items-center justify-center";
|
|
2017
2152
|
declare const radioIndicatorDotClass = "rounded-full bg-primary";
|
|
2018
2153
|
/** Each option row: radio + label + optional description. */
|
|
@@ -2212,7 +2347,7 @@ type SwitchSize = 'sm' | 'md' | 'lg';
|
|
|
2212
2347
|
*/
|
|
2213
2348
|
declare const switchTrackClass: Record<SwitchSize, string>;
|
|
2214
2349
|
declare const switchThumbClass: Record<SwitchSize, string>;
|
|
2215
|
-
declare const switchTrackBaseClass = "relative inline-flex shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent bg-input transition-colors focus-visible:outline-none focus-visible:ring-
|
|
2350
|
+
declare const switchTrackBaseClass = "relative inline-flex shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent bg-input transition-colors focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-primary-glow disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary aria-[invalid=true]:ring-[3px] aria-[invalid=true]:ring-destructive/40";
|
|
2216
2351
|
declare const switchThumbBaseClass = "pointer-events-none block rounded-full bg-background shadow-sm ring-0 transition-transform";
|
|
2217
2352
|
|
|
2218
2353
|
interface SwitchProps {
|
|
@@ -2286,7 +2421,7 @@ type TextareaResize = 'none' | 'vertical' | 'horizontal' | 'both';
|
|
|
2286
2421
|
declare const textareaVariantClass: Record<TextareaVariant, string>;
|
|
2287
2422
|
declare const textareaSizeClass: Record<TextareaSize, string>;
|
|
2288
2423
|
declare const textareaResizeClass: Record<TextareaResize, string>;
|
|
2289
|
-
declare const textareaBaseClass = "group/textarea relative flex w-full text-foreground outline-none transition-[background-color,border-color,box-shadow] focus-within:ring-
|
|
2424
|
+
declare const textareaBaseClass = "group/textarea relative flex w-full text-foreground outline-none transition-[background-color,border-color,box-shadow] focus-within:ring-[3px] focus-within:ring-primary-glow aria-[invalid=true]:border-destructive aria-[invalid=true]:focus-within:ring-destructive/40 has-[textarea:disabled]:pointer-events-none has-[textarea:disabled]:opacity-50";
|
|
2290
2425
|
|
|
2291
2426
|
interface TextareaProps extends Omit<TextareaHTMLAttributes<HTMLTextAreaElement>, 'size'> {
|
|
2292
2427
|
variant?: TextareaVariant;
|
|
@@ -2475,4 +2610,4 @@ declare function useDirection(): Direction;
|
|
|
2475
2610
|
|
|
2476
2611
|
declare function cn(...inputs: ClassValue[]): string;
|
|
2477
2612
|
|
|
2478
|
-
export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, type AlertDialogContentProps, AlertDialogDescription, type AlertDialogDescriptionProps, AlertDialogFooter, type AlertDialogFooterProps, AlertDialogHeader, type AlertDialogHeaderProps, AlertDialogOverlay, type AlertDialogOverlayProps, AlertDialogPortal, AlertDialogTitle, type AlertDialogTitleProps, AlertDialogTrigger, AppShell, type AppShellBrand, type AppShellNavGroup, type AppShellNavItem, type AppShellProps, Avatar, type AvatarProps, Badge, type BadgeProps, type BadgeSize, type BadgeVariant, Button, type ButtonProps, type ButtonSize, type ButtonVariant, Checkbox, type CheckboxProps, type CheckboxSize, type Column, type ColumnAlign, type ConfirmDialogLabels, ConfirmDialogProvider, type ConfirmDialogProviderProps, type ConfirmOptions, type CustomRowAction, DashboardContent, type DashboardContentProps, DashboardHeader, type DashboardHeaderProps, DashboardLayout, type DashboardLayoutContextValue, type DashboardLayoutProps, DashboardMain, type DashboardMainProps, DatePicker, type DatePickerProps, type DatePickerSize, type DatePickerVariant, DetailPage, type DetailPageLabels, type DetailPageNotFoundState, type DetailPageProps, Dialog, DialogClose, DialogContent, type DialogContentProps, DialogDescription, type DialogDescriptionProps, DialogFooter, type DialogFooterProps, DialogHeader, type DialogHeaderProps, DialogOverlay, type DialogOverlayProps, DialogPortal, DialogTitle, type DialogTitleProps, DialogTrigger, type Direction, DropdownMenu, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuItem, type DropdownMenuItemProps, type DropdownMenuItemVariant, DropdownMenuLabel, type DropdownMenuLabelProps, DropdownMenuPortal, DropdownMenuSeparator, type DropdownMenuSeparatorProps, DropdownMenuShortcut, type DropdownMenuShortcutProps, DropdownMenuTrigger, EmptyState, type EmptyStateProps, type EmptyStateSize, Field, type FieldOrientation, type FieldProps, type FieldRHFProps, FileUpload, type FileUploadError, type FileUploadErrorCode, type FileUploadLabels, type FileUploadProps, FormPage, type FormPageLabels, type FormPageProps, HeaderActions, type HeaderActionsProps, HeaderCollapseTrigger, type HeaderCollapseTriggerProps, HeaderMobileTrigger, type HeaderMobileTriggerProps, HeaderSearch, type HeaderSearchProps, HeaderTitle, type HeaderTitleProps, Input, type InputProps, type InputSize, type InputVariant, type LanguageOption, LanguageSwitcher, type LanguageSwitcherProps, ListPage, type ListPageDateFilter, type ListPageEmptyState, type ListPageFilter, type ListPageFilterWidth, type ListPageLabels, type ListPageMultiSelectFilter, type ListPageProps, type ListPageSelectFilter, type ListPageTextFilter, MultiSelect, type MultiSelectLabels, type MultiSelectProps, PageHeader, type PageHeaderBackProps, type PageHeaderBackRenderProps, type PageHeaderHeadingLevel, type PageHeaderProps, type PaginationState, type PresetRowAction, RadioGroup, RadioGroupItem, type RadioGroupOption, type RadioGroupOrientation, type RadioGroupProps, type RadioGroupSize, type RowAction, RowActions, type RowActionsProps, type RowSelectionState, Select, type SelectOption, type SelectProps, type SelectSize, type SelectVariant, Sidebar, SidebarFooter, type SidebarFooterProps, SidebarGroup, type SidebarGroupProps, SidebarHeader, type SidebarHeaderProps, SidebarNav, SidebarNavGroup, type SidebarNavGroupProps, SidebarNavItem, type SidebarNavItemProps, type SidebarNavItemRenderProps, type SidebarNavProps, type SidebarProps, type SortDirection, type SortState, Switch, type SwitchProps, type SwitchSize, Table, type TableLabels, type TableProps, type TableSize, type TableSizeClasses, Textarea, type TextareaProps, type TextareaResize, type TextareaSize, type TextareaVariant, Toaster, type ToasterProps, Tooltip, type TooltipProps, TooltipProvider, type TooltipProviderProps, badgeBaseClass, badgeDotSizeClass, badgeSizeClass, badgeVariantClass, buttonBaseClass, buttonSizeClass, buttonVariantClass, cn, datePickerCalendarClass, datePickerCaptionClass, datePickerContentClass, datePickerDayBaseClass, datePickerDayWrapperClass, datePickerDisabledClass, datePickerMonthClass, datePickerMonthGridClass, datePickerMonthsClass, datePickerNavButtonClass, datePickerNavClass, datePickerOutsideClass, datePickerPlaceholderClass, datePickerSelectedClass, datePickerTodayClass, datePickerTriggerBaseClass, datePickerTriggerSizeClass, datePickerTriggerVariantClass, datePickerValueClass, datePickerWeekClass, datePickerWeekdayClass, datePickerWeekdaysClass, detailPageBaseClass, detailPageBodyClass, detailPageEmptyClass, detailPageSkeletonRowClass, dialogCloseButtonClass, dialogContentClass, dialogDescriptionClass, dialogFooterClass, dialogHeaderClass, dialogOverlayClass, dialogTitleClass, dropdownMenuContentClass, dropdownMenuItemBaseClass, dropdownMenuItemInsetClass, dropdownMenuItemVariantClass, dropdownMenuLabelClass, dropdownMenuSeparatorClass, dropdownMenuShortcutClass, emptyStateActionsSpacingClass, emptyStateBaseClass, emptyStateContainerSizeClass, emptyStateDescriptionSizeClass, emptyStateIconWrapperBaseClass, emptyStateIconWrapperSizeClass, emptyStateTitleSizeClass, fileUploadBaseClass, fileUploadDropzoneClass, fileUploadFileNameClass, fileUploadFileRowClass, fileUploadFileSizeClass, fileUploadHintClass, fileUploadIconClass, fileUploadPromptClass, fileUploadRemoveClass, formPageActionsBarClass, formPageBaseClass, formPageBodyClass, formPageSkeletonRowClass, inputBaseClass, inputSizeClass, inputVariantClass, multiSelectChipClass, multiSelectChipRemoveClass, multiSelectContentClass, multiSelectEmptyClass, multiSelectListClass, multiSelectOptionClass, multiSelectSearchRowClass, multiSelectTriggerSizeClass, multiSelectValueRowClass, pageHeaderActionsClass, pageHeaderBackClass, pageHeaderBackIconClass, pageHeaderBaseClass, pageHeaderBorderedClass, pageHeaderBreadcrumbsClass, pageHeaderDescriptionClass, pageHeaderTitleBlockClass, pageHeaderTitleClass, pageHeaderTitleRowClass, radioGroupBaseClass, radioGroupOrientationClass, radioIndicatorBaseClass, radioIndicatorDotClass, radioIndicatorSizeClass, radioItemBaseClass, radioItemSizeClass, radioLabelSizeClass, radioOptionRowClass, rowActionsBaseClass, rowActionsDestructiveClass, selectBaseClass, selectSizeClass, selectVariantClass, switchThumbBaseClass, switchThumbClass, switchTrackBaseClass, switchTrackClass, alignClass as tableAlignClass, tableBaseClass, selectedRowClass as tableSelectedRowClass, tableSizeClass, sortIconClass as tableSortIconClass, textareaBaseClass, textareaResizeClass, textareaSizeClass, textareaVariantClass, toastClassNames, tooltipArrowClass, tooltipContentClass, useConfirm, useDashboardLayout, useDirection };
|
|
2613
|
+
export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, type AlertDialogContentProps, AlertDialogDescription, type AlertDialogDescriptionProps, AlertDialogFooter, type AlertDialogFooterProps, AlertDialogHeader, type AlertDialogHeaderProps, AlertDialogOverlay, type AlertDialogOverlayProps, AlertDialogPortal, AlertDialogTitle, type AlertDialogTitleProps, AlertDialogTrigger, AppShell, type AppShellBrand, type AppShellNavGroup, type AppShellNavItem, type AppShellProps, Avatar, type AvatarProps, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BadgeVariant, Button, type ButtonProps, type ButtonSize, type ButtonVariant, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, type CheckboxProps, type CheckboxSize, type Column, type ColumnAlign, type ConfirmDialogLabels, ConfirmDialogProvider, type ConfirmDialogProviderProps, type ConfirmOptions, type CustomRowAction, DashboardContent, type DashboardContentProps, DashboardHeader, type DashboardHeaderProps, DashboardLayout, type DashboardLayoutContextValue, type DashboardLayoutProps, DashboardMain, type DashboardMainProps, DatePicker, type DatePickerProps, type DatePickerSize, type DatePickerVariant, DetailPage, type DetailPageLabels, type DetailPageNotFoundState, type DetailPageProps, Dialog, DialogClose, DialogContent, type DialogContentProps, DialogDescription, type DialogDescriptionProps, DialogFooter, type DialogFooterProps, DialogHeader, type DialogHeaderProps, DialogOverlay, type DialogOverlayProps, DialogPortal, DialogTitle, type DialogTitleProps, DialogTrigger, type Direction, DropdownMenu, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuItem, type DropdownMenuItemProps, type DropdownMenuItemVariant, DropdownMenuLabel, type DropdownMenuLabelProps, DropdownMenuPortal, DropdownMenuSeparator, type DropdownMenuSeparatorProps, DropdownMenuShortcut, type DropdownMenuShortcutProps, DropdownMenuTrigger, EmptyState, type EmptyStateProps, type EmptyStateSize, Field, type FieldOrientation, type FieldProps, type FieldRHFProps, FileUpload, type FileUploadError, type FileUploadErrorCode, type FileUploadLabels, type FileUploadProps, FormPage, type FormPageLabels, type FormPageProps, HeaderActions, type HeaderActionsProps, HeaderCollapseTrigger, type HeaderCollapseTriggerProps, HeaderMobileTrigger, type HeaderMobileTriggerProps, HeaderSearch, type HeaderSearchProps, HeaderTitle, type HeaderTitleProps, Input, type InputProps, type InputSize, type InputVariant, type LanguageOption, LanguageSwitcher, type LanguageSwitcherProps, ListPage, type ListPageDateFilter, type ListPageEmptyState, type ListPageFilter, type ListPageFilterWidth, type ListPageLabels, type ListPageMultiSelectFilter, type ListPageProps, type ListPageSelectFilter, type ListPageTextFilter, MultiSelect, type MultiSelectLabels, type MultiSelectProps, PageHeader, type PageHeaderBackProps, type PageHeaderBackRenderProps, type PageHeaderHeadingLevel, type PageHeaderProps, type PaginationState, type PresetRowAction, RadioGroup, RadioGroupItem, type RadioGroupOption, type RadioGroupOrientation, type RadioGroupProps, type RadioGroupSize, type RowAction, RowActions, type RowActionsProps, type RowSelectionState, Select, type SelectOption, type SelectProps, type SelectSize, type SelectVariant, Sidebar, SidebarFooter, type SidebarFooterProps, SidebarGroup, type SidebarGroupProps, SidebarHeader, type SidebarHeaderProps, SidebarNav, SidebarNavGroup, type SidebarNavGroupProps, SidebarNavItem, type SidebarNavItemProps, type SidebarNavItemRenderProps, type SidebarNavProps, type SidebarProps, type SortDirection, type SortState, Switch, type SwitchProps, type SwitchSize, Table, type TableLabels, type TableProps, type TableSize, type TableSizeClasses, Textarea, type TextareaProps, type TextareaResize, type TextareaSize, type TextareaVariant, Toaster, type ToasterProps, Tooltip, type TooltipProps, TooltipProvider, type TooltipProviderProps, badgeBaseClass, badgeDotSizeClass, badgeSizeClass, badgeSoftVariantClass, badgeVariantClass, buttonBaseClass, buttonSizeClass, buttonVariantClass, cardBaseClass, cardContentClass, cardDescriptionClass, cardFooterClass, cardHeaderClass, cardTitleClass, cn, datePickerCalendarClass, datePickerCaptionClass, datePickerContentClass, datePickerDayBaseClass, datePickerDayWrapperClass, datePickerDisabledClass, datePickerMonthClass, datePickerMonthGridClass, datePickerMonthsClass, datePickerNavButtonClass, datePickerNavClass, datePickerOutsideClass, datePickerPlaceholderClass, datePickerSelectedClass, datePickerTodayClass, datePickerTriggerBaseClass, datePickerTriggerSizeClass, datePickerTriggerVariantClass, datePickerValueClass, datePickerWeekClass, datePickerWeekdayClass, datePickerWeekdaysClass, detailPageBaseClass, detailPageBodyClass, detailPageEmptyClass, detailPageSkeletonRowClass, dialogCloseButtonClass, dialogContentClass, dialogDescriptionClass, dialogFooterClass, dialogHeaderClass, dialogOverlayClass, dialogTitleClass, dropdownMenuContentClass, dropdownMenuItemBaseClass, dropdownMenuItemInsetClass, dropdownMenuItemVariantClass, dropdownMenuLabelClass, dropdownMenuSeparatorClass, dropdownMenuShortcutClass, emptyStateActionsSpacingClass, emptyStateBaseClass, emptyStateContainerSizeClass, emptyStateDescriptionSizeClass, emptyStateIconWrapperBaseClass, emptyStateIconWrapperSizeClass, emptyStateTitleSizeClass, fileUploadBaseClass, fileUploadDropzoneClass, fileUploadFileNameClass, fileUploadFileRowClass, fileUploadFileSizeClass, fileUploadHintClass, fileUploadIconClass, fileUploadPromptClass, fileUploadRemoveClass, formPageActionsBarClass, formPageBaseClass, formPageBodyClass, formPageSkeletonRowClass, inputBaseClass, inputSizeClass, inputVariantClass, multiSelectChipClass, multiSelectChipRemoveClass, multiSelectContentClass, multiSelectEmptyClass, multiSelectListClass, multiSelectOptionClass, multiSelectSearchRowClass, multiSelectTriggerSizeClass, multiSelectValueRowClass, pageHeaderActionsClass, pageHeaderBackClass, pageHeaderBackIconClass, pageHeaderBaseClass, pageHeaderBorderedClass, pageHeaderBreadcrumbsClass, pageHeaderDescriptionClass, pageHeaderEyebrowClass, pageHeaderTitleBlockClass, pageHeaderTitleClass, pageHeaderTitleLineClass, pageHeaderTitleMetaClass, pageHeaderTitleRowClass, radioGroupBaseClass, radioGroupOrientationClass, radioIndicatorBaseClass, radioIndicatorDotClass, radioIndicatorSizeClass, radioItemBaseClass, radioItemSizeClass, radioLabelSizeClass, radioOptionRowClass, rowActionsBaseClass, rowActionsDestructiveClass, selectBaseClass, selectSizeClass, selectVariantClass, switchThumbBaseClass, switchThumbClass, switchTrackBaseClass, switchTrackClass, alignClass as tableAlignClass, tableBaseClass, selectedRowClass as tableSelectedRowClass, tableSizeClass, sortIconClass as tableSortIconClass, textareaBaseClass, textareaResizeClass, textareaSizeClass, textareaVariantClass, toastClassNames, tooltipArrowClass, tooltipContentClass, useConfirm, useDashboardLayout, useDirection };
|