jenosize-ui 0.1.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/LICENSE +28 -0
- package/README.md +100 -0
- package/THIRD-PARTY-NOTICES.md +163 -0
- package/dist/Button-Bt7pzM4R.d.ts +82 -0
- package/dist/PaymentInput-CKPIPNWH.d.ts +141 -0
- package/dist/Select-CVbEQ2Ep.d.ts +118 -0
- package/dist/TagInput-CTJYOB4J.d.ts +90 -0
- package/dist/avatar.d.ts +161 -0
- package/dist/avatar.js +11 -0
- package/dist/badge.d.ts +109 -0
- package/dist/badge.js +10 -0
- package/dist/breadcrumb.d.ts +58 -0
- package/dist/breadcrumb.js +7 -0
- package/dist/button.d.ts +54 -0
- package/dist/button.js +14 -0
- package/dist/calendar.d.ts +368 -0
- package/dist/calendar.js +21 -0
- package/dist/callout.d.ts +70 -0
- package/dist/callout.js +16 -0
- package/dist/card-nWicloNi.d.ts +80 -0
- package/dist/card.d.ts +2 -0
- package/dist/card.js +7 -0
- package/dist/checkbox.d.ts +133 -0
- package/dist/checkbox.js +11 -0
- package/dist/chunk-24TO7E32.js +42 -0
- package/dist/chunk-3Y5X7B5C.js +146 -0
- package/dist/chunk-4OLULPQG.js +202 -0
- package/dist/chunk-4P2NBLBW.js +103 -0
- package/dist/chunk-52IFGFTL.js +11 -0
- package/dist/chunk-5FATN5YD.js +115 -0
- package/dist/chunk-5NOBSXJN.js +297 -0
- package/dist/chunk-5RAPA22E.js +106 -0
- package/dist/chunk-7EUAMHMU.js +16 -0
- package/dist/chunk-7EWQKTNQ.js +1336 -0
- package/dist/chunk-7HOIZ3UO.js +110 -0
- package/dist/chunk-7IU5TMFL.js +452 -0
- package/dist/chunk-7JBNLEJ7.js +29 -0
- package/dist/chunk-7S2TBALK.js +23 -0
- package/dist/chunk-BJUZVYQC.js +188 -0
- package/dist/chunk-BVJWBYIG.js +66 -0
- package/dist/chunk-CME4DIML.js +65 -0
- package/dist/chunk-CYPPEUX5.js +73 -0
- package/dist/chunk-D5BTFSL7.js +71 -0
- package/dist/chunk-D6TPWNRK.js +387 -0
- package/dist/chunk-DJSXIAFH.js +66 -0
- package/dist/chunk-DRZCJCBO.js +46 -0
- package/dist/chunk-DWKILXHE.js +17 -0
- package/dist/chunk-E7ZSWBAK.js +70 -0
- package/dist/chunk-EDSK6FEH.js +8 -0
- package/dist/chunk-F2K7VJUV.js +114 -0
- package/dist/chunk-F6NLE6XJ.js +40 -0
- package/dist/chunk-FHHAPGCR.js +32 -0
- package/dist/chunk-FXIBGTS5.js +14 -0
- package/dist/chunk-GCVA3OIV.js +72 -0
- package/dist/chunk-GFOAJVW5.js +336 -0
- package/dist/chunk-GRLSUQQE.js +136 -0
- package/dist/chunk-GTHJWR3Q.js +77 -0
- package/dist/chunk-HMUZE6EK.js +67 -0
- package/dist/chunk-I7WU4GTY.js +503 -0
- package/dist/chunk-J2BCKBHC.js +151 -0
- package/dist/chunk-J36M3KRX.js +1315 -0
- package/dist/chunk-J7ZQQFPT.js +113 -0
- package/dist/chunk-JP26LPCY.js +234 -0
- package/dist/chunk-JTNFJLIY.js +1046 -0
- package/dist/chunk-JVJRHBTD.js +50 -0
- package/dist/chunk-JYGR44ZC.js +133 -0
- package/dist/chunk-KDLPXXD2.js +173 -0
- package/dist/chunk-KMSYEE23.js +224 -0
- package/dist/chunk-KNYKWUYX.js +52 -0
- package/dist/chunk-LME57Z6J.js +138 -0
- package/dist/chunk-MFJP5FA7.js +20 -0
- package/dist/chunk-MKC5HNA7.js +1692 -0
- package/dist/chunk-MQGD2OUF.js +39 -0
- package/dist/chunk-MUFHLP4S.js +566 -0
- package/dist/chunk-O2LG3PNI.js +74 -0
- package/dist/chunk-O4GRKO3I.js +66 -0
- package/dist/chunk-OHUFNYGN.js +791 -0
- package/dist/chunk-PWKWNDBS.js +243 -0
- package/dist/chunk-QA74ITR4.js +103 -0
- package/dist/chunk-R6RGJF4L.js +170 -0
- package/dist/chunk-S7NNXWIN.js +7 -0
- package/dist/chunk-SV56BSUQ.js +162 -0
- package/dist/chunk-T7FCG7XV.js +435 -0
- package/dist/chunk-THC2ISYP.js +57 -0
- package/dist/chunk-VWC72TR3.js +115 -0
- package/dist/chunk-W46K56XU.js +216 -0
- package/dist/chunk-W5GGOUUI.js +75 -0
- package/dist/chunk-WEUJYDCV.js +269 -0
- package/dist/chunk-WFY7DKQD.js +279 -0
- package/dist/chunk-WZQFC7ZN.js +448 -0
- package/dist/chunk-Z3ETJN5G.js +136 -0
- package/dist/chunk-ZOOX3TUB.js +192 -0
- package/dist/chunk-ZSNJ6UA3.js +42 -0
- package/dist/chunk-ZZA2LUTL.js +130 -0
- package/dist/chunk-ZZT2E5VT.js +24 -0
- package/dist/color-CtSxc1Rh.d.ts +6 -0
- package/dist/combobox.d.ts +184 -0
- package/dist/combobox.js +21 -0
- package/dist/date-input.d.ts +83 -0
- package/dist/date-input.js +16 -0
- package/dist/date-picker.d.ts +249 -0
- package/dist/date-picker.js +29 -0
- package/dist/date-utils-7hTFTXNK.d.ts +34 -0
- package/dist/date-vMJBKAFK.d.ts +22 -0
- package/dist/dialog.d.ts +86 -0
- package/dist/dialog.js +15 -0
- package/dist/drawer.d.ts +77 -0
- package/dist/drawer.js +14 -0
- package/dist/dropdown-menu.d.ts +218 -0
- package/dist/dropdown-menu.js +10 -0
- package/dist/file-trigger.d.ts +42 -0
- package/dist/file-trigger.js +3 -0
- package/dist/form.d.ts +487 -0
- package/dist/form.js +1179 -0
- package/dist/header-navigation.d.ts +74 -0
- package/dist/header-navigation.js +23 -0
- package/dist/icons/app.d.ts +48 -0
- package/dist/icons/app.js +282 -0
- package/dist/icons/flag.d.ts +817 -0
- package/dist/icons/flag.js +58336 -0
- package/dist/icons/integration.d.ts +36 -0
- package/dist/icons/integration.js +531 -0
- package/dist/icons/payment.d.ts +116 -0
- package/dist/icons/payment.js +2418 -0
- package/dist/icons.d.ts +2013 -0
- package/dist/icons.js +2012 -0
- package/dist/illustration.d.ts +48 -0
- package/dist/illustration.js +4 -0
- package/dist/index.d.ts +68 -0
- package/dist/index.js +73 -0
- package/dist/indicator.d.ts +51 -0
- package/dist/indicator.js +7 -0
- package/dist/input.d.ts +66 -0
- package/dist/input.js +15 -0
- package/dist/multi-value-CJb_tnvi.d.ts +8 -0
- package/dist/nav-Bla0o_-1.d.ts +98 -0
- package/dist/number-input.d.ts +80 -0
- package/dist/number-input.js +15 -0
- package/dist/options-CPEIgjtd.d.ts +68 -0
- package/dist/overflow-Df0h42Oi.d.ts +29 -0
- package/dist/pagination.d.ts +77 -0
- package/dist/pagination.js +17 -0
- package/dist/payment-input.d.ts +7 -0
- package/dist/payment-input.js +15 -0
- package/dist/popover.d.ts +60 -0
- package/dist/popover.js +14 -0
- package/dist/progress.d.ts +87 -0
- package/dist/progress.js +5 -0
- package/dist/radio.d.ts +77 -0
- package/dist/radio.js +12 -0
- package/dist/select.d.ts +68 -0
- package/dist/select.js +24 -0
- package/dist/shared-BNXAdgh2.d.ts +9 -0
- package/dist/shared-BYXJPnsN.d.ts +11 -0
- package/dist/shared-Dc-GgA16.d.ts +42 -0
- package/dist/sidebar-navigation.d.ts +129 -0
- package/dist/sidebar-navigation.js +15 -0
- package/dist/styles.css +2 -0
- package/dist/switch.d.ts +23 -0
- package/dist/switch.js +7 -0
- package/dist/table.d.ts +692 -0
- package/dist/table.js +44 -0
- package/dist/tabs.d.ts +111 -0
- package/dist/tabs.js +8 -0
- package/dist/tag-input.d.ts +12 -0
- package/dist/tag-input.js +19 -0
- package/dist/tag.d.ts +98 -0
- package/dist/tag.js +9 -0
- package/dist/textarea.d.ts +40 -0
- package/dist/textarea.js +12 -0
- package/dist/theme-script.d.ts +29 -0
- package/dist/theme-script.js +15 -0
- package/dist/theme.css +929 -0
- package/dist/theme.d.ts +71 -0
- package/dist/theme.js +15 -0
- package/dist/toast.d.ts +242 -0
- package/dist/toast.js +15 -0
- package/dist/tooltip.d.ts +70 -0
- package/dist/tooltip.js +6 -0
- package/dist/tree.d.ts +308 -0
- package/dist/tree.js +11 -0
- package/package.json +352 -0
package/dist/table.js
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use client";export { Table, expansionChildren, expansionDetail, flattenColumns, hasColumnGroups, isColumnGroup, useTable } from './chunk-MKC5HNA7.js';
|
|
2
|
+
import './chunk-WFY7DKQD.js';
|
|
3
|
+
import './chunk-BVJWBYIG.js';
|
|
4
|
+
import './chunk-OHUFNYGN.js';
|
|
5
|
+
import './chunk-PWKWNDBS.js';
|
|
6
|
+
import './chunk-THC2ISYP.js';
|
|
7
|
+
import './chunk-CYPPEUX5.js';
|
|
8
|
+
import './chunk-J7ZQQFPT.js';
|
|
9
|
+
import './chunk-FXIBGTS5.js';
|
|
10
|
+
import './chunk-JP26LPCY.js';
|
|
11
|
+
import './chunk-F6NLE6XJ.js';
|
|
12
|
+
import './chunk-ZOOX3TUB.js';
|
|
13
|
+
import './chunk-GTHJWR3Q.js';
|
|
14
|
+
import './chunk-MFJP5FA7.js';
|
|
15
|
+
import './chunk-W46K56XU.js';
|
|
16
|
+
import './chunk-CME4DIML.js';
|
|
17
|
+
import './chunk-MQGD2OUF.js';
|
|
18
|
+
import './chunk-JVJRHBTD.js';
|
|
19
|
+
import './chunk-7HOIZ3UO.js';
|
|
20
|
+
import './chunk-7EUAMHMU.js';
|
|
21
|
+
import './chunk-T7FCG7XV.js';
|
|
22
|
+
import './chunk-7S2TBALK.js';
|
|
23
|
+
import './chunk-LME57Z6J.js';
|
|
24
|
+
import './chunk-S7NNXWIN.js';
|
|
25
|
+
import './chunk-ZZT2E5VT.js';
|
|
26
|
+
import './chunk-FHHAPGCR.js';
|
|
27
|
+
import './chunk-7JBNLEJ7.js';
|
|
28
|
+
import './chunk-R6RGJF4L.js';
|
|
29
|
+
import './chunk-W5GGOUUI.js';
|
|
30
|
+
import './chunk-4P2NBLBW.js';
|
|
31
|
+
import './chunk-DWKILXHE.js';
|
|
32
|
+
import './chunk-QA74ITR4.js';
|
|
33
|
+
import './chunk-KNYKWUYX.js';
|
|
34
|
+
import './chunk-52IFGFTL.js';
|
|
35
|
+
import './chunk-O2LG3PNI.js';
|
|
36
|
+
import './chunk-EDSK6FEH.js';
|
|
37
|
+
import './chunk-J2BCKBHC.js';
|
|
38
|
+
import './chunk-24TO7E32.js';
|
|
39
|
+
import './chunk-ZZA2LUTL.js';
|
|
40
|
+
import './chunk-O4GRKO3I.js';
|
|
41
|
+
import './chunk-GCVA3OIV.js';
|
|
42
|
+
import './chunk-ZSNJ6UA3.js';
|
|
43
|
+
//# sourceMappingURL=table.js.map
|
|
44
|
+
//# sourceMappingURL=table.js.map
|
package/dist/tabs.d.ts
ADDED
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
type TabsVariant = "underline" | "pill";
|
|
4
|
+
type TabsSize = "sm" | "md" | "lg";
|
|
5
|
+
type TabsOrientation = "horizontal" | "vertical";
|
|
6
|
+
interface TabItem<V extends string = string> {
|
|
7
|
+
/** **Required.** Unique id; wires the tab to its panel and is the `value`. Generic so the strip's
|
|
8
|
+
* `value`/`defaultValue` can be checked against the tabs you actually declared. */
|
|
9
|
+
value: V;
|
|
10
|
+
/** Tab label (keep to a short string). Omit for an icon-only tab + `ariaLabel`. */
|
|
11
|
+
label?: React.ReactNode;
|
|
12
|
+
/** Accessible name for the tab. **Required** for an icon-only tab (no `label`), and the escape
|
|
13
|
+
* hatch when the composed name reads poorly: a `trailing` count is announced (it is real
|
|
14
|
+
* information — see `docs/slot-policy.md`), so `label="Projects"` + a `8` chip says
|
|
15
|
+
* "Projects 8"; set `ariaLabel="Projects, 8 open"` to name it properly. Wins over the composed
|
|
16
|
+
* content whenever it is set. */
|
|
17
|
+
ariaLabel?: string;
|
|
18
|
+
/** Optional leading icon; auto-sized per `size` and recolored to match tab state. */
|
|
19
|
+
leading?: React.ReactNode;
|
|
20
|
+
/** Optional trailing node (icon/dot/count `<Badge seamless shape="pill" size="sm">`) — the
|
|
21
|
+
* free-form counterpart of `leading`. `seamless` makes the badge inherit the TAB's color, so the
|
|
22
|
+
* chip tracks both the variant (`underline` → brand when active, `pill` → `fg`) and the
|
|
23
|
+
* idle/active state on its own — like a `seamless` control in an `<Input>` add-on slot. The
|
|
24
|
+
* `shape`/`size` are still the caller's to pass (CSS inheritance can't carry a padding step):
|
|
25
|
+
* `pill`+`sm` is the count chip, matching SidebarNavigation and Breadcrumb. */
|
|
26
|
+
trailing?: React.ReactNode;
|
|
27
|
+
/** Disable this single tab (focusable per the ARIA pattern, but never activates). */
|
|
28
|
+
disabled?: boolean;
|
|
29
|
+
/** Layout/spacing overrides for THIS tab button only (e.g. `flex-1`), merged via `cn()`. */
|
|
30
|
+
className?: string;
|
|
31
|
+
/** Keep THIS panel mounted (hidden) when inactive — overrides the root `keepMounted`. */
|
|
32
|
+
keepMounted?: boolean;
|
|
33
|
+
/** Panel content for this tab. A function is evaluated lazily — only when the panel
|
|
34
|
+
* actually mounts (i.e. on activation, unless `keepMounted`). Omit for strip-only nav. */
|
|
35
|
+
content?: React.ReactNode | (() => React.ReactNode);
|
|
36
|
+
}
|
|
37
|
+
interface TabsProps<V extends string = string> {
|
|
38
|
+
/** The tabs (and, optionally, their panel `content`), in strip order. */
|
|
39
|
+
items: readonly TabItem<V>[];
|
|
40
|
+
/** Controlled active tab value. **Checked against `items`** — `V` is inferred from the values you
|
|
41
|
+
* declared there, so pointing at a tab that does not exist is a compile error instead of a strip
|
|
42
|
+
* with nothing active. `NoInfer` keeps this prop out of inference so the union can't widen to
|
|
43
|
+
* admit it. A widened `items` annotation leaves `V = string` (unchanged behaviour).
|
|
44
|
+
* See `docs/type-safety-policy.md`. */
|
|
45
|
+
value?: NoInfer<V>;
|
|
46
|
+
/** Initial active tab (uncontrolled) — checked against `items` like {@link value}.
|
|
47
|
+
* @default the first item's value */
|
|
48
|
+
defaultValue?: NoInfer<V>;
|
|
49
|
+
/** Fires when the active tab changes. */
|
|
50
|
+
onValueChange?: (value: V, event: Event) => void;
|
|
51
|
+
/** Visual style of the tab strip. @default "underline" */
|
|
52
|
+
variant?: TabsVariant;
|
|
53
|
+
/** Tab padding, text, icon, and badge scale. @default "md" */
|
|
54
|
+
size?: TabsSize;
|
|
55
|
+
/** Lay tabs in a row or a column. @default "horizontal" */
|
|
56
|
+
orientation?: TabsOrientation;
|
|
57
|
+
/** Keep inactive panels mounted (hidden) to preserve their state/scroll. Per-item
|
|
58
|
+
* `keepMounted` overrides this. @default false */
|
|
59
|
+
keepMounted?: boolean;
|
|
60
|
+
/** Accessible name for the tablist. Provide this or `aria-labelledby`. */
|
|
61
|
+
"aria-label"?: string;
|
|
62
|
+
/** Names the tablist from a visible heading's id (instead of `aria-label`). */
|
|
63
|
+
"aria-labelledby"?: string;
|
|
64
|
+
/** Tabs share the strip's main axis evenly — every tab is the SAME width (the mobile-style
|
|
65
|
+
* segmented layout), whether that means growing into free space or shrinking out of an
|
|
66
|
+
* overflow. The bounded replacement for hand-stretching the strip through a class hook; pair
|
|
67
|
+
* it with `className="w-full"` to fill the container. Equal width is unconditional, so a
|
|
68
|
+
* label too long for its share **truncates** (the `leading`/`trailing` slots never shrink) and
|
|
69
|
+
* a fitted strip therefore never scrolls — that is the trade for the guarantee. On
|
|
70
|
+
* `orientation="vertical"` it shares the column's HEIGHT instead; labels are unaffected.
|
|
71
|
+
* @default false */
|
|
72
|
+
fitted?: boolean;
|
|
73
|
+
/** Pin the tab strip while its panels scroll past it, so the tabs stay reachable in a long view.
|
|
74
|
+
*
|
|
75
|
+
* **Two things are the HOST's, and both arrive as CSS custom properties** rather than props,
|
|
76
|
+
* because only the caller knows them and a component-picked constant is wrong everywhere else.
|
|
77
|
+
* Set them through the root class hook (`className`), where they inherit down to the strip:
|
|
78
|
+
*
|
|
79
|
+
* - **`--tabs-sticky-top`** (@default `0px`) — the offset the strip docks at. `0` is right inside
|
|
80
|
+
* a scroll container; under an app header it is that header's height:
|
|
81
|
+
* `className="[--tabs-sticky-top:3.5rem]"`. Stacked chrome adds up (a 56px topbar + a 44px
|
|
82
|
+
* sub-bar ⇒ `6.25rem`).
|
|
83
|
+
* - **`--tabs-sticky-bg`** (@default `var(--color-bg-primary)`) — the backdrop the pinned strip paints so
|
|
84
|
+
* panel content does not show through it. The default is the page surface; on any other host
|
|
85
|
+
* hand it that host's role (`className="[--tabs-sticky-bg:var(--color-bg-sunken)]"`), or the
|
|
86
|
+
* seam shows where the two surfaces meet.
|
|
87
|
+
*
|
|
88
|
+
* **It sticks to the nearest scrollable ancestor, not to the viewport** — that is CSS, not a
|
|
89
|
+
* choice. Inside a `Dialog`/`Drawer` the scrollport is the panel body (so the offset is `0`, not
|
|
90
|
+
* the app header's height); inside any `overflow-x-auto` wrapper it is that box. An
|
|
91
|
+
* `overflow-hidden` ancestor captures the strip and never scrolls, so it can never pin — a
|
|
92
|
+
* dev-mode warning reports that, since nothing about it is visible in the markup.
|
|
93
|
+
*
|
|
94
|
+
* The strip pins at `z-4`: above panel content and above a `<Table stickyHeader>`'s own `z-3`
|
|
95
|
+
* header inside a panel, and below the `z-10`+ range an app's chrome and the library's popups
|
|
96
|
+
* use, so your header always wins. On `orientation="vertical"` the rail pins with **no backdrop**
|
|
97
|
+
* (nothing scrolls under a rail that sits beside the panel) and shrinks to its content height —
|
|
98
|
+
* a rail stretched to the panel's full height has nowhere to slide.
|
|
99
|
+
* @default false */
|
|
100
|
+
sticky?: boolean;
|
|
101
|
+
/** Layout/spacing overrides for the root container (margin, width, gap), merged via `cn()` —
|
|
102
|
+
* the ONE class hook, like every other flat control. Per-tab layout is the item's own
|
|
103
|
+
* `className`; there is no `listClassName`/`panelClassName`. Never restyles internals. */
|
|
104
|
+
className?: string;
|
|
105
|
+
}
|
|
106
|
+
declare function Tabs<V extends string = string>(props: TabsProps<V>): React.JSX.Element;
|
|
107
|
+
declare namespace Tabs {
|
|
108
|
+
var displayName: string;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export { type TabItem, Tabs, type TabsOrientation, type TabsProps, type TabsSize, type TabsVariant };
|
package/dist/tabs.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use client";export { Tabs } from './chunk-4OLULPQG.js';
|
|
2
|
+
import './chunk-52IFGFTL.js';
|
|
3
|
+
import './chunk-O2LG3PNI.js';
|
|
4
|
+
import './chunk-EDSK6FEH.js';
|
|
5
|
+
import './chunk-GCVA3OIV.js';
|
|
6
|
+
import './chunk-ZSNJ6UA3.js';
|
|
7
|
+
//# sourceMappingURL=tabs.js.map
|
|
8
|
+
//# sourceMappingURL=tabs.js.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { d as TagInputBaseProps } from './TagInput-CTJYOB4J.js';
|
|
2
|
+
export { T as TagInput, a as TagInputProps, b as TagInputSeparator, c as TagInputSize } from './TagInput-CTJYOB4J.js';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
|
|
5
|
+
type TagInputOuterProps = TagInputBaseProps;
|
|
6
|
+
/** Tag input with removable pills rendered in a block BELOW the field.
|
|
7
|
+
* Type + Enter/comma to add; Backspace/ArrowLeft on an empty draft focuses the
|
|
8
|
+
* last pill (UUI roving model) — Delete/Backspace then removes it, ArrowRight
|
|
9
|
+
* returns to the input. */
|
|
10
|
+
declare function TagInputOuter(props: TagInputOuterProps): React.JSX.Element;
|
|
11
|
+
|
|
12
|
+
export { TagInputOuter, type TagInputOuterProps };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use client";export { TagInputOuter } from './chunk-VWC72TR3.js';
|
|
2
|
+
export { TagInput } from './chunk-WEUJYDCV.js';
|
|
3
|
+
import './chunk-R6RGJF4L.js';
|
|
4
|
+
import './chunk-W5GGOUUI.js';
|
|
5
|
+
import './chunk-4P2NBLBW.js';
|
|
6
|
+
import './chunk-DWKILXHE.js';
|
|
7
|
+
import './chunk-QA74ITR4.js';
|
|
8
|
+
import './chunk-KNYKWUYX.js';
|
|
9
|
+
import './chunk-52IFGFTL.js';
|
|
10
|
+
import './chunk-O2LG3PNI.js';
|
|
11
|
+
import './chunk-EDSK6FEH.js';
|
|
12
|
+
import './chunk-J2BCKBHC.js';
|
|
13
|
+
import './chunk-24TO7E32.js';
|
|
14
|
+
import './chunk-ZZA2LUTL.js';
|
|
15
|
+
import './chunk-O4GRKO3I.js';
|
|
16
|
+
import './chunk-GCVA3OIV.js';
|
|
17
|
+
import './chunk-ZSNJ6UA3.js';
|
|
18
|
+
//# sourceMappingURL=tag-input.js.map
|
|
19
|
+
//# sourceMappingURL=tag-input.js.map
|
package/dist/tag.d.ts
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { O as OverflowMode } from './overflow-Df0h42Oi.js';
|
|
3
|
+
import { b as Option } from './options-CPEIgjtd.js';
|
|
4
|
+
|
|
5
|
+
type TagSize = "sm" | "md" | "lg";
|
|
6
|
+
|
|
7
|
+
interface TagProps extends Omit<React.ComponentPropsWithoutRef<"span">, "children" | "color"> {
|
|
8
|
+
/** Label (keep short). */
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
/** Control size. @default "md" */
|
|
11
|
+
size?: TagSize;
|
|
12
|
+
/** Leading node (decorative) — a status `<Indicator/>`, a 16px `<Avatar size="xxs"/>`, or an
|
|
13
|
+
* icon. The caller composes and sizes the node; the tag just places it (`aria-hidden`, `shrink-0`). */
|
|
14
|
+
leading?: React.ReactNode;
|
|
15
|
+
/** Trailing node — a count `<Badge seamless size="sm">`, a glyph. `seamless` makes the badge take
|
|
16
|
+
* the pill's own color (it inherits it) instead of its `color`/`variant`, exactly like a `seamless`
|
|
17
|
+
* control in an `<Input>` add-on slot. Rendered before the close button.
|
|
18
|
+
*
|
|
19
|
+
* The chip's `size` is the caller's (inheritance can't carry a padding step) and it steps with the
|
|
20
|
+
* TAG, not with itself: `sm`/`md` tags take `size="sm"`, an `lg` tag takes `size="md"` — UUI's own
|
|
21
|
+
* count span is `text-xs` at the first two sizes and `text-sm` at `lg`. Unlike a tab or sidebar
|
|
22
|
+
* chip this one keeps the default `shape="badge"` (UUI's tight bespoke span, not the pill badge). */
|
|
23
|
+
trailing?: React.ReactNode;
|
|
24
|
+
/** When set, renders a trailing close `<button>` that calls this on activate. */
|
|
25
|
+
onRemove?: () => void;
|
|
26
|
+
/** Accessible label for the close button. @default `Remove ${children}` (string label) or "Remove tag". */
|
|
27
|
+
removeLabel?: string;
|
|
28
|
+
/** Take the close button out of the tab order (removal is driven elsewhere, e.g. `TagInput`'s Backspace). @default false */
|
|
29
|
+
removeExcludeFromTabOrder?: boolean;
|
|
30
|
+
/** `cursor-not-allowed` + disables the close button (the pill keeps full color, per UUI). @default false */
|
|
31
|
+
disabled?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* What the label does when it exceeds the pill's width — see {@link OverflowMode}. Either
|
|
34
|
+
* non-`visible` mode needs a bounded width (a `max-w-*` in `className`, or a constrained
|
|
35
|
+
* parent) to have anything to act against. When wrapping, the leading slot, count, and close
|
|
36
|
+
* button stay **vertically centered** against the whole multi-line pill. @default "visible"
|
|
37
|
+
*/
|
|
38
|
+
overflow?: OverflowMode;
|
|
39
|
+
/** **Layout/spacing only** (margin, alignment, order), merged via `cn()`. Never restyles internals. */
|
|
40
|
+
className?: string;
|
|
41
|
+
}
|
|
42
|
+
declare function Tag(props: TagProps): React.JSX.Element;
|
|
43
|
+
declare namespace Tag {
|
|
44
|
+
var displayName: string;
|
|
45
|
+
}
|
|
46
|
+
/** A data-first option for `TagGroup` `options` — the flat-props shape each
|
|
47
|
+
* selectable pill takes. `label` (base `Option.label`) becomes the pill content. */
|
|
48
|
+
interface TagOption<V extends string = string> extends Option<V> {
|
|
49
|
+
/** Leading node (decorative) — a status `<Indicator/>`, a 16px `<Avatar size="xxs"/>`, or an icon. */
|
|
50
|
+
leading?: React.ReactNode;
|
|
51
|
+
/** Trailing node — a count `<Badge seamless size="sm">` (inherits the pill's color; `size="md"`
|
|
52
|
+
* under an `lg` tag), a glyph. */
|
|
53
|
+
trailing?: React.ReactNode;
|
|
54
|
+
/** How this item's label handles an over-long value. Overrides the group's `overflow`. */
|
|
55
|
+
overflow?: OverflowMode;
|
|
56
|
+
/** **Layout/spacing only** for this pill (margin, order, basis), merged via `cn()`. Never restyles internals. */
|
|
57
|
+
className?: string;
|
|
58
|
+
}
|
|
59
|
+
interface TagGroupProps<V extends string = string> extends Omit<React.ComponentPropsWithoutRef<"div">, "defaultValue" | "onChange" | "dir" | "color" | "children"> {
|
|
60
|
+
/** Controlled selected keys. **Checked against `options`** — `V` is inferred from the values you
|
|
61
|
+
* passed there, so a key that matches no pill is a compile error rather than a selection that
|
|
62
|
+
* never shows. `NoInfer` keeps this prop out of inference so the union can't widen to admit it.
|
|
63
|
+
* A widened `options` annotation leaves `V = string`. See `docs/type-safety-policy.md`. */
|
|
64
|
+
value?: NoInfer<V>[];
|
|
65
|
+
/** Initial selected keys (uncontrolled) — checked against `options` like {@link value}. @default [] */
|
|
66
|
+
defaultValue?: NoInfer<V>[];
|
|
67
|
+
/** Fires with the full selected-key array whenever it changes. */
|
|
68
|
+
onValueChange?: (value: V[]) => void;
|
|
69
|
+
/** Allow more than one selected tag at a time. `false` = single-select, which
|
|
70
|
+
* also disallows an empty selection (clicking the pressed tag keeps it, per UUI). @default true */
|
|
71
|
+
multiple?: boolean;
|
|
72
|
+
/** Control size; inherited by every pill. @default "md" */
|
|
73
|
+
size?: TagSize;
|
|
74
|
+
/** Disables every item in the group. @default false */
|
|
75
|
+
disabled?: boolean;
|
|
76
|
+
/** Show the persistent mini checkbox on every item (UUI's selection indicator).
|
|
77
|
+
* Set `false` to fall back to the house brand-tint selected look instead. @default true */
|
|
78
|
+
showCheck?: boolean;
|
|
79
|
+
/** Loop arrow-key focus at the ends. @default true */
|
|
80
|
+
loopFocus?: boolean;
|
|
81
|
+
/** How every item's label handles an over-long value (group default; a `TagOption` can
|
|
82
|
+
* override). Needs a bounded item width to act against. @default "visible" */
|
|
83
|
+
overflow?: OverflowMode;
|
|
84
|
+
/** Data-first options — the canonical (and only) API: renders one selectable
|
|
85
|
+
* pill per entry. `TagGroup` is flat-only (no compound parts). */
|
|
86
|
+
options?: readonly TagOption<V>[];
|
|
87
|
+
/** **Layout/spacing only**, merged via `cn()`. */
|
|
88
|
+
className?: string;
|
|
89
|
+
}
|
|
90
|
+
declare function TagGroupRoot<V extends string = string>(props: TagGroupProps<V>): React.JSX.Element;
|
|
91
|
+
declare namespace TagGroupRoot {
|
|
92
|
+
var displayName: string;
|
|
93
|
+
}
|
|
94
|
+
/** Data-first, flat-only (AGENTS §11 / docs/api-policy.md): `<TagGroup options=… />`
|
|
95
|
+
* renders the whole selectable-pill set from data. No public compound parts. */
|
|
96
|
+
declare const TagGroup: typeof TagGroupRoot;
|
|
97
|
+
|
|
98
|
+
export { Tag, TagGroup, type TagGroupProps, type TagOption, type TagProps, type TagSize };
|
package/dist/tag.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use client";export { Tag, TagGroup } from './chunk-R6RGJF4L.js';
|
|
2
|
+
import './chunk-4P2NBLBW.js';
|
|
3
|
+
import './chunk-DWKILXHE.js';
|
|
4
|
+
import './chunk-52IFGFTL.js';
|
|
5
|
+
import './chunk-24TO7E32.js';
|
|
6
|
+
import './chunk-GCVA3OIV.js';
|
|
7
|
+
import './chunk-ZSNJ6UA3.js';
|
|
8
|
+
//# sourceMappingURL=tag.js.map
|
|
9
|
+
//# sourceMappingURL=tag.js.map
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
type TextareaSize = "sm" | "md" | "lg";
|
|
4
|
+
type TextareaResize = "none" | "vertical";
|
|
5
|
+
interface TextareaProps extends Omit<React.ComponentPropsWithoutRef<"textarea">, "rows" | "size"> {
|
|
6
|
+
/** Padding/text/radius and the fixed visible row count. @default "md" */
|
|
7
|
+
size?: TextareaSize;
|
|
8
|
+
/** Override the visible row count from the size map (sm=3 · md=4 · lg=5) —
|
|
9
|
+
* an escape hatch for a taller/shorter fixed-height box (UUI forwards `rows` freely). */
|
|
10
|
+
rows?: number;
|
|
11
|
+
/** Whether the field column takes `w-full`. Only OBSERVABLE where the parent would otherwise let
|
|
12
|
+
* the column shrink-to-fit (a flex row / grid cell) — in a plain block container it fills either
|
|
13
|
+
* way. Bound the field with a width in `className` (`max-w-prose`). @default true */
|
|
14
|
+
fullWidth?: boolean;
|
|
15
|
+
/** Visible label (`Field.Label`), auto-associated with the control. */
|
|
16
|
+
label?: string;
|
|
17
|
+
/** Help-circle tooltip after the label (title line). @see tooltipDescription */
|
|
18
|
+
tooltip?: string;
|
|
19
|
+
/** Optional secondary line under {@link tooltip} in the tooltip surface. */
|
|
20
|
+
tooltipDescription?: string;
|
|
21
|
+
/** Helper text under the field (`Field.Description`). Hidden while an `error` shows. */
|
|
22
|
+
hint?: React.ReactNode;
|
|
23
|
+
/** Suppress the visual `*` while keeping `required` semantics — for forms where every
|
|
24
|
+
* field is required and the asterisks become noise (UUI parity). @default false */
|
|
25
|
+
hideRequiredIndicator?: boolean;
|
|
26
|
+
/** Error state: red border + error ring and `aria-invalid`. @default false */
|
|
27
|
+
invalid?: boolean;
|
|
28
|
+
/** Optional error message (`Field.Error`). A truthy `error` also implies `invalid`. */
|
|
29
|
+
error?: string;
|
|
30
|
+
/** Grow to fit content; removes the manual resize handle (forces `resize="none"`). @default false */
|
|
31
|
+
autoResize?: boolean;
|
|
32
|
+
/** Manual resize affordance. Ignored when `autoResize` is `true`. @default "vertical" */
|
|
33
|
+
resize?: TextareaResize;
|
|
34
|
+
/** Fade the top/bottom edge of overflowing text as a scroll hint (moves the border onto a
|
|
35
|
+
* wrapper so it stays crisp). No effect with `autoResize` (it grows instead of scrolling). @default false */
|
|
36
|
+
scrollFade?: boolean;
|
|
37
|
+
}
|
|
38
|
+
declare function Textarea(props: TextareaProps): React.JSX.Element;
|
|
39
|
+
|
|
40
|
+
export { Textarea, type TextareaProps, type TextareaResize, type TextareaSize };
|
package/dist/textarea.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use client";export { Textarea } from './chunk-KDLPXXD2.js';
|
|
2
|
+
import './chunk-7EUAMHMU.js';
|
|
3
|
+
import './chunk-O2LG3PNI.js';
|
|
4
|
+
import './chunk-EDSK6FEH.js';
|
|
5
|
+
import './chunk-J2BCKBHC.js';
|
|
6
|
+
import './chunk-24TO7E32.js';
|
|
7
|
+
import './chunk-ZZA2LUTL.js';
|
|
8
|
+
import './chunk-O4GRKO3I.js';
|
|
9
|
+
import './chunk-GCVA3OIV.js';
|
|
10
|
+
import './chunk-ZSNJ6UA3.js';
|
|
11
|
+
//# sourceMappingURL=textarea.js.map
|
|
12
|
+
//# sourceMappingURL=textarea.js.map
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
|
|
3
|
+
type Theme = "light" | "dark" | "system";
|
|
4
|
+
|
|
5
|
+
interface ThemeScriptOptions {
|
|
6
|
+
/** localStorage key holding the preference. @default "jz-theme" */
|
|
7
|
+
storageKey?: string;
|
|
8
|
+
/** Preference when nothing is stored. @default "system" */
|
|
9
|
+
defaultTheme?: Theme;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* A self-contained IIFE that resolves the theme and applies `.dark` +
|
|
13
|
+
* `color-scheme` to <html> BEFORE first paint — eliminating the light/dark flash.
|
|
14
|
+
* Inline it in the document <head> (see <ThemeScript>). No React, no deps.
|
|
15
|
+
*/
|
|
16
|
+
declare function buildThemeScript(options?: ThemeScriptOptions): string;
|
|
17
|
+
|
|
18
|
+
interface ThemeScriptProps extends ThemeScriptOptions {
|
|
19
|
+
/** CSP nonce, if your app uses one. */
|
|
20
|
+
nonce?: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Hook-free, server-renderable no-flash script. Place it in the document <head>
|
|
24
|
+
* (Next: in the server root layout) and add `suppressHydrationWarning` to <html>,
|
|
25
|
+
* since this script mutates the class/style before React hydrates.
|
|
26
|
+
*/
|
|
27
|
+
declare function ThemeScript({ storageKey, defaultTheme, nonce }: ThemeScriptProps): react.JSX.Element;
|
|
28
|
+
|
|
29
|
+
export { type Theme, ThemeScript, type ThemeScriptOptions, type ThemeScriptProps, buildThemeScript };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
|
|
3
|
+
// src/theme/script.ts
|
|
4
|
+
function buildThemeScript(options = {}) {
|
|
5
|
+
const storageKey = JSON.stringify(options.storageKey ?? "jz-theme");
|
|
6
|
+
const defaultTheme = JSON.stringify(options.defaultTheme ?? "system");
|
|
7
|
+
return `(function(){try{var k=${storageKey},d=${defaultTheme};var t=localStorage.getItem(k);if(t!=="light"&&t!=="dark"&&t!=="system"){t=d;}var s=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";var r=t==="system"?s:t;var e=document.documentElement;e.classList.toggle("dark",r==="dark");e.style.colorScheme=r;}catch(e){}})();`;
|
|
8
|
+
}
|
|
9
|
+
function ThemeScript({ storageKey, defaultTheme, nonce }) {
|
|
10
|
+
return /* @__PURE__ */ jsx("script", { nonce, dangerouslySetInnerHTML: { __html: buildThemeScript({ storageKey, defaultTheme }) } });
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { ThemeScript, buildThemeScript };
|
|
14
|
+
//# sourceMappingURL=theme-script.js.map
|
|
15
|
+
//# sourceMappingURL=theme-script.js.map
|