@gears-frontx/ui-kit 0.3.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/NOTICE +49 -0
- package/README.md +75 -0
- package/dist/badge.d.ts +1 -0
- package/dist/badge.js +42 -0
- package/dist/badge.js.map +1 -0
- package/dist/button.d.ts +1 -0
- package/dist/button.js +73 -0
- package/dist/button.js.map +1 -0
- package/dist/card.d.ts +1 -0
- package/dist/card.js +54 -0
- package/dist/card.js.map +1 -0
- package/dist/checkbox.d.ts +1 -0
- package/dist/checkbox.js +46 -0
- package/dist/checkbox.js.map +1 -0
- package/dist/chunks/badge.ej-3-Xs4.css +1 -0
- package/dist/chunks/button.CKfALaMe.css +1 -0
- package/dist/chunks/card.B0AcyAT1.css +1 -0
- package/dist/chunks/checkbox.Dd6YDr20.css +1 -0
- package/dist/chunks/dialog.D6LS2vnG.css +1 -0
- package/dist/chunks/dropdown-menu.DmDZc5gB.css +1 -0
- package/dist/chunks/field.BNZx8HfN.css +1 -0
- package/dist/chunks/input.CrRQ0OAn.css +1 -0
- package/dist/chunks/label.jrB9zD_G.css +1 -0
- package/dist/chunks/radio-group.1Y6B0lXt.css +1 -0
- package/dist/chunks/select.BmyP2S2q.css +1 -0
- package/dist/chunks/separator.DdRRkJW4.css +1 -0
- package/dist/chunks/skeleton.BhWSzPnI.css +1 -0
- package/dist/chunks/switch.B_ebMSxR.css +1 -0
- package/dist/chunks/table.r8ppNt1W.css +1 -0
- package/dist/chunks/tabs.DqJE9cX3.css +1 -0
- package/dist/chunks/textarea.BKWvs6fD.css +1 -0
- package/dist/chunks/toast.DMl31Mq4.css +1 -0
- package/dist/chunks/tooltip.apA3VWHJ.css +1 -0
- package/dist/components/badge/badge.d.ts +11 -0
- package/dist/components/badge/badge.d.ts.map +1 -0
- package/dist/components/badge/public.d.ts +2 -0
- package/dist/components/badge/public.d.ts.map +1 -0
- package/dist/components/button/button.d.ts +50 -0
- package/dist/components/button/button.d.ts.map +1 -0
- package/dist/components/button/public.d.ts +2 -0
- package/dist/components/button/public.d.ts.map +1 -0
- package/dist/components/card/card.d.ts +22 -0
- package/dist/components/card/card.d.ts.map +1 -0
- package/dist/components/card/public.d.ts +2 -0
- package/dist/components/card/public.d.ts.map +1 -0
- package/dist/components/checkbox/checkbox.d.ts +6 -0
- package/dist/components/checkbox/checkbox.d.ts.map +1 -0
- package/dist/components/checkbox/public.d.ts +2 -0
- package/dist/components/checkbox/public.d.ts.map +1 -0
- package/dist/components/dialog/dialog.d.ts +58 -0
- package/dist/components/dialog/dialog.d.ts.map +1 -0
- package/dist/components/dialog/public.d.ts +2 -0
- package/dist/components/dialog/public.d.ts.map +1 -0
- package/dist/components/dropdown-menu/dropdown-menu.d.ts +70 -0
- package/dist/components/dropdown-menu/dropdown-menu.d.ts.map +1 -0
- package/dist/components/dropdown-menu/public.d.ts +2 -0
- package/dist/components/dropdown-menu/public.d.ts.map +1 -0
- package/dist/components/field/field.d.ts +18 -0
- package/dist/components/field/field.d.ts.map +1 -0
- package/dist/components/field/public.d.ts +2 -0
- package/dist/components/field/public.d.ts.map +1 -0
- package/dist/components/input/input.d.ts +6 -0
- package/dist/components/input/input.d.ts.map +1 -0
- package/dist/components/input/public.d.ts +2 -0
- package/dist/components/input/public.d.ts.map +1 -0
- package/dist/components/label/label.d.ts +4 -0
- package/dist/components/label/label.d.ts.map +1 -0
- package/dist/components/label/public.d.ts +2 -0
- package/dist/components/label/public.d.ts.map +1 -0
- package/dist/components/radio-group/public.d.ts +2 -0
- package/dist/components/radio-group/public.d.ts.map +1 -0
- package/dist/components/radio-group/radio-group.d.ts +11 -0
- package/dist/components/radio-group/radio-group.d.ts.map +1 -0
- package/dist/components/select/public.d.ts +2 -0
- package/dist/components/select/public.d.ts.map +1 -0
- package/dist/components/select/select.d.ts +61 -0
- package/dist/components/select/select.d.ts.map +1 -0
- package/dist/components/separator/public.d.ts +2 -0
- package/dist/components/separator/public.d.ts.map +1 -0
- package/dist/components/separator/separator.d.ts +6 -0
- package/dist/components/separator/separator.d.ts.map +1 -0
- package/dist/components/skeleton/public.d.ts +2 -0
- package/dist/components/skeleton/public.d.ts.map +1 -0
- package/dist/components/skeleton/skeleton.d.ts +4 -0
- package/dist/components/skeleton/skeleton.d.ts.map +1 -0
- package/dist/components/switch/public.d.ts +2 -0
- package/dist/components/switch/public.d.ts.map +1 -0
- package/dist/components/switch/switch.d.ts +11 -0
- package/dist/components/switch/switch.d.ts.map +1 -0
- package/dist/components/table/public.d.ts +2 -0
- package/dist/components/table/public.d.ts.map +1 -0
- package/dist/components/table/table.d.ts +38 -0
- package/dist/components/table/table.d.ts.map +1 -0
- package/dist/components/tabs/public.d.ts +2 -0
- package/dist/components/tabs/public.d.ts.map +1 -0
- package/dist/components/tabs/tabs.d.ts +23 -0
- package/dist/components/tabs/tabs.d.ts.map +1 -0
- package/dist/components/textarea/public.d.ts +2 -0
- package/dist/components/textarea/public.d.ts.map +1 -0
- package/dist/components/textarea/textarea.d.ts +4 -0
- package/dist/components/textarea/textarea.d.ts.map +1 -0
- package/dist/components/toast/public.d.ts +2 -0
- package/dist/components/toast/public.d.ts.map +1 -0
- package/dist/components/toast/toast.d.ts +85 -0
- package/dist/components/toast/toast.d.ts.map +1 -0
- package/dist/components/tooltip/public.d.ts +2 -0
- package/dist/components/tooltip/public.d.ts.map +1 -0
- package/dist/components/tooltip/tooltip.d.ts +41 -0
- package/dist/components/tooltip/tooltip.d.ts.map +1 -0
- package/dist/dialog.d.ts +1 -0
- package/dist/dialog.js +84 -0
- package/dist/dialog.js.map +1 -0
- package/dist/docs/badge.md +82 -0
- package/dist/docs/button.md +102 -0
- package/dist/docs/card.md +131 -0
- package/dist/docs/checkbox.md +55 -0
- package/dist/docs/dialog.md +124 -0
- package/dist/docs/dropdown-menu.md +140 -0
- package/dist/docs/field.md +68 -0
- package/dist/docs/input.md +65 -0
- package/dist/docs/label.md +50 -0
- package/dist/docs/radio-group.md +59 -0
- package/dist/docs/select.md +99 -0
- package/dist/docs/separator.md +119 -0
- package/dist/docs/skeleton.md +143 -0
- package/dist/docs/switch.md +51 -0
- package/dist/docs/table.md +276 -0
- package/dist/docs/tabs.md +124 -0
- package/dist/docs/textarea.md +52 -0
- package/dist/docs/toast.md +153 -0
- package/dist/docs/tooltip.md +134 -0
- package/dist/dropdown-menu.d.ts +1 -0
- package/dist/dropdown-menu.js +183 -0
- package/dist/dropdown-menu.js.map +1 -0
- package/dist/field.d.ts +1 -0
- package/dist/field.js +28 -0
- package/dist/field.js.map +1 -0
- package/dist/index.d.ts +48 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +96 -0
- package/dist/index.js.map +1 -0
- package/dist/input.d.ts +1 -0
- package/dist/input.js +30 -0
- package/dist/input.js.map +1 -0
- package/dist/label.d.ts +1 -0
- package/dist/label.js +12 -0
- package/dist/label.js.map +1 -0
- package/dist/radio-group.d.ts +1 -0
- package/dist/radio-group.js +21 -0
- package/dist/radio-group.js.map +1 -0
- package/dist/select.d.ts +1 -0
- package/dist/select.js +175 -0
- package/dist/select.js.map +1 -0
- package/dist/separator.d.ts +1 -0
- package/dist/separator.js +13 -0
- package/dist/separator.js.map +1 -0
- package/dist/skeleton.d.ts +1 -0
- package/dist/skeleton.js +12 -0
- package/dist/skeleton.js.map +1 -0
- package/dist/switch.d.ts +1 -0
- package/dist/switch.js +26 -0
- package/dist/switch.js.map +1 -0
- package/dist/table.d.ts +1 -0
- package/dist/table.js +64 -0
- package/dist/table.js.map +1 -0
- package/dist/tabs.d.ts +1 -0
- package/dist/tabs.js +41 -0
- package/dist/tabs.js.map +1 -0
- package/dist/textarea.d.ts +1 -0
- package/dist/textarea.js +13 -0
- package/dist/textarea.js.map +1 -0
- package/dist/theme.css +485 -0
- package/dist/toast.d.ts +1 -0
- package/dist/toast.js +193 -0
- package/dist/toast.js.map +1 -0
- package/dist/tooltip.d.ts +1 -0
- package/dist/tooltip.js +49 -0
- package/dist/tooltip.js.map +1 -0
- package/llms.txt +148 -0
- package/package.json +85 -0
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
# Tooltip
|
|
2
|
+
|
|
3
|
+
A visual-only hint that appears when its trigger is hovered or focused.
|
|
4
|
+
Wraps the Base UI Tooltip primitives; the popup is portalled, and
|
|
5
|
+
open/close timing, hover/focus interaction, and Escape/outside-press
|
|
6
|
+
dismissal come from Base UI. Base UI disables tooltips on touch devices
|
|
7
|
+
entirely (no reliable touch affordance exists) and does **not** wire an
|
|
8
|
+
ARIA `role`/`aria-describedby` link from the trigger to the popup — its
|
|
9
|
+
own docs are explicit that a tooltip is a supplementary visual label,
|
|
10
|
+
not an accessible description. Give the trigger an accessible name
|
|
11
|
+
(`aria-label`, or visible text) that **closely matches the tooltip's
|
|
12
|
+
content** — Base UI's own guidance warns that a mismatched label leaves
|
|
13
|
+
screen-reader users with a different message than sighted users get from
|
|
14
|
+
the tooltip, not a consistent one.
|
|
15
|
+
|
|
16
|
+
Composition: `Tooltip` (root, holds open state) → `TooltipTrigger` →
|
|
17
|
+
`TooltipContent` (portals a caret plus your content). Optionally wrap a
|
|
18
|
+
subtree in `TooltipProvider` to share delay/grouping across many
|
|
19
|
+
tooltips.
|
|
20
|
+
|
|
21
|
+
## When to use
|
|
22
|
+
|
|
23
|
+
- A short, supplementary label for an icon-only control or truncated
|
|
24
|
+
text — information a sighted mouse/keyboard user can miss without
|
|
25
|
+
losing access to the feature.
|
|
26
|
+
|
|
27
|
+
## When not to use
|
|
28
|
+
|
|
29
|
+
- Content essential to using the page — inline text or `dialog` is
|
|
30
|
+
reachable by touch and screen-reader users; a tooltip is not.
|
|
31
|
+
- An info icon whose only job is to reveal more text — Base UI's own
|
|
32
|
+
guidance is to use a `Popover` with `openOnHover` instead (not in the
|
|
33
|
+
kit's MVP scope), since a tooltip's trigger must have a purpose of its
|
|
34
|
+
own besides opening the popup.
|
|
35
|
+
- A menu of actions anchored to a trigger — use `dropdown-menu`.
|
|
36
|
+
|
|
37
|
+
## Props (kit level)
|
|
38
|
+
|
|
39
|
+
`Tooltip` (root): `open` / `defaultOpen`, `onOpenChange`, `disabled`,
|
|
40
|
+
`trackCursorAxis`, `handle` (for a trigger placed outside the root, see
|
|
41
|
+
Base UI's detached-trigger pattern) — see Base UI Tooltip.Root.
|
|
42
|
+
|
|
43
|
+
`TooltipTrigger`: `delay` (ms before opening on hover, Base UI default
|
|
44
|
+
`600`), `closeDelay` (ms before closing, default `0`), `disabled`
|
|
45
|
+
(suppresses the tooltip only — it does not add the native `disabled`
|
|
46
|
+
attribute to the underlying `<button>`, which stays clickable and
|
|
47
|
+
focusable), `closeOnClick` (`true` default). Renders a native `<button>`.
|
|
48
|
+
|
|
49
|
+
`delay` is measured as hover intent — the timer runs from pointer
|
|
50
|
+
movement over the trigger, not from entry, so sweeping the cursor across
|
|
51
|
+
a toolbar without pausing won't open any of its tooltips. (In tests,
|
|
52
|
+
dispatch a `mousemove` after `mouseenter` to arm it — a bare `mouseenter`
|
|
53
|
+
alone never starts the timer for a non-zero delay.)
|
|
54
|
+
|
|
55
|
+
`TooltipContent`:
|
|
56
|
+
|
|
57
|
+
| Prop | Type | Default |
|
|
58
|
+
|------|------|---------|
|
|
59
|
+
| `side` | `top` \| `bottom` \| `left` \| `right` \| `inline-start` \| `inline-end` | `top` |
|
|
60
|
+
| `align` | `start` \| `center` \| `end` | `center` |
|
|
61
|
+
| `sideOffset` / `alignOffset` | `number` | `4` / `0` |
|
|
62
|
+
| `container` | DOM node to portal the popup into | `<body>` |
|
|
63
|
+
| `positionMethod` | `absolute` \| `fixed` — pass `fixed` when the trigger sits inside a `transform`/`filter` container, where absolute positioning resolves against the wrong box | `absolute` |
|
|
64
|
+
| `collisionBoundary` / `collisionPadding` | see Base UI Tooltip.Positioner — bound and pad the flip/shift collision logic | viewport / `5` |
|
|
65
|
+
| `className` | `string` — merged after the kit class | — |
|
|
66
|
+
|
|
67
|
+
The popup portals to `<body>` by default, so if your theme lives on a
|
|
68
|
+
subtree (`data-theme` on a section instead of `<html>`), pass that
|
|
69
|
+
section as `container` or the popup renders with the root theme — same
|
|
70
|
+
contract as `Dialog`, `Select`, and `DropdownMenu`.
|
|
71
|
+
|
|
72
|
+
`TooltipContent` always renders a small caret against the popup edge
|
|
73
|
+
(Base UI's `Tooltip.Arrow`) — there's no prop to hide it, matching the
|
|
74
|
+
source this component is translated from.
|
|
75
|
+
|
|
76
|
+
### TooltipProvider (optional)
|
|
77
|
+
|
|
78
|
+
Mount `TooltipProvider` once around a group of tooltips (e.g. a toolbar)
|
|
79
|
+
to share open/close delay and grouping: once one tooltip in the group
|
|
80
|
+
opens, adjacent ones open instantly while hovering within `timeout`
|
|
81
|
+
(default `400`ms) of each other. It renders no DOM element itself.
|
|
82
|
+
|
|
83
|
+
By itself, mounting it does **not** change the open delay — Base UI's
|
|
84
|
+
per-trigger default (`600`ms) still applies to the first tooltip opened
|
|
85
|
+
in the group. (This is a deliberate divergence from base-vega's own
|
|
86
|
+
wrapper, which defaults the Provider's `delay` to `0`: that default only
|
|
87
|
+
makes sense in a model where the Provider is mounted once, globally, at
|
|
88
|
+
the app root — here, where it's optional, defaulting to instant-open
|
|
89
|
+
would mean identical trigger markup opens at 600ms or 0ms depending on
|
|
90
|
+
an invisible ancestor.) Pass `delay` explicitly on `TooltipProvider` (or
|
|
91
|
+
on individual `TooltipTrigger`s) to open faster.
|
|
92
|
+
|
|
93
|
+
A lone `Tooltip` works standalone without a `TooltipProvider` — grouping
|
|
94
|
+
is the only thing wrapping one adds.
|
|
95
|
+
|
|
96
|
+
## Examples
|
|
97
|
+
|
|
98
|
+
```tsx
|
|
99
|
+
import {
|
|
100
|
+
Tooltip,
|
|
101
|
+
TooltipContent,
|
|
102
|
+
TooltipProvider,
|
|
103
|
+
TooltipTrigger,
|
|
104
|
+
} from '@gears-frontx/ui-kit';
|
|
105
|
+
|
|
106
|
+
<Tooltip>
|
|
107
|
+
<TooltipTrigger>Add to favorites</TooltipTrigger>
|
|
108
|
+
<TooltipContent>Add to favorites</TooltipContent>
|
|
109
|
+
</Tooltip>;
|
|
110
|
+
|
|
111
|
+
// A toolbar of icon-only buttons (replace the text with your own icons):
|
|
112
|
+
// instant, grouped tooltips once the first one in the group has opened.
|
|
113
|
+
<TooltipProvider>
|
|
114
|
+
<Tooltip>
|
|
115
|
+
<TooltipTrigger aria-label="Bold">B</TooltipTrigger>
|
|
116
|
+
<TooltipContent>Bold</TooltipContent>
|
|
117
|
+
</Tooltip>
|
|
118
|
+
<Tooltip>
|
|
119
|
+
<TooltipTrigger aria-label="Italic">I</TooltipTrigger>
|
|
120
|
+
<TooltipContent>Italic</TooltipContent>
|
|
121
|
+
</Tooltip>
|
|
122
|
+
</TooltipProvider>;
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
## Anti-patterns
|
|
126
|
+
|
|
127
|
+
- Do not put content in a tooltip that a touch or screen-reader user
|
|
128
|
+
needs to complete the task — they cannot reach it. Repeat critical
|
|
129
|
+
information inline or use `dialog`/a visible label instead.
|
|
130
|
+
- Do not rely on the tooltip to name the trigger for assistive
|
|
131
|
+
technology — give the trigger its own `aria-label` (or visible text).
|
|
132
|
+
- Do not wrap a single, standalone tooltip in `TooltipProvider` expecting
|
|
133
|
+
a behavior change — grouping only matters with more than one tooltip
|
|
134
|
+
sharing a provider.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/dropdown-menu/public.js'
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import { jsxs as p, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { Menu as r } from "@base-ui/react/menu";
|
|
3
|
+
import { cx as a, cva as v } from "class-variance-authority";
|
|
4
|
+
import { useContext as x, createContext as D } from "react";
|
|
5
|
+
import './chunks/dropdown-menu.DmDZc5gB.css';const M = "_positioner_14fxt_6", k = "_popup_14fxt_15", w = "_subPopup_14fxt_25", C = "_label_14fxt_107", N = "_item_14fxt_104", T = "_variantDefault_14fxt_150", P = "_variantDestructive_14fxt_164", R = "_checkboxItem_14fxt_104", S = "_radioItem_14fxt_104", L = "_itemIndicator_14fxt_207", G = "_separator_14fxt_218", j = "_shortcut_14fxt_225", B = "_subTrigger_14fxt_105", V = "_subTriggerIcon_14fxt_268", W = "_svgIcon_14fxt_273", n = {
|
|
6
|
+
positioner: M,
|
|
7
|
+
popup: k,
|
|
8
|
+
subPopup: w,
|
|
9
|
+
label: C,
|
|
10
|
+
item: N,
|
|
11
|
+
variantDefault: T,
|
|
12
|
+
variantDestructive: P,
|
|
13
|
+
checkboxItem: R,
|
|
14
|
+
radioItem: S,
|
|
15
|
+
itemIndicator: L,
|
|
16
|
+
separator: G,
|
|
17
|
+
shortcut: j,
|
|
18
|
+
subTrigger: B,
|
|
19
|
+
subTriggerIcon: V,
|
|
20
|
+
svgIcon: W
|
|
21
|
+
}, m = D(void 0);
|
|
22
|
+
function l({ className: t }) {
|
|
23
|
+
return /* @__PURE__ */ e(
|
|
24
|
+
"svg",
|
|
25
|
+
{
|
|
26
|
+
className: a(n.svgIcon, t),
|
|
27
|
+
viewBox: "0 0 24 24",
|
|
28
|
+
fill: "none",
|
|
29
|
+
stroke: "currentColor",
|
|
30
|
+
strokeWidth: "2",
|
|
31
|
+
strokeLinecap: "round",
|
|
32
|
+
strokeLinejoin: "round",
|
|
33
|
+
"aria-hidden": "true",
|
|
34
|
+
children: /* @__PURE__ */ e("path", { d: "M20 6 9 17l-5-5" })
|
|
35
|
+
}
|
|
36
|
+
);
|
|
37
|
+
}
|
|
38
|
+
function y({ className: t }) {
|
|
39
|
+
return /* @__PURE__ */ e(
|
|
40
|
+
"svg",
|
|
41
|
+
{
|
|
42
|
+
className: a(n.svgIcon, t),
|
|
43
|
+
viewBox: "0 0 24 24",
|
|
44
|
+
fill: "none",
|
|
45
|
+
stroke: "currentColor",
|
|
46
|
+
strokeWidth: "2",
|
|
47
|
+
strokeLinecap: "round",
|
|
48
|
+
strokeLinejoin: "round",
|
|
49
|
+
"aria-hidden": "true",
|
|
50
|
+
children: /* @__PURE__ */ e("path", { d: "m9 18 6-6-6-6" })
|
|
51
|
+
}
|
|
52
|
+
);
|
|
53
|
+
}
|
|
54
|
+
const J = r.Root;
|
|
55
|
+
function K({ className: t, ...o }) {
|
|
56
|
+
return /* @__PURE__ */ e(r.Trigger, { className: t, ...o });
|
|
57
|
+
}
|
|
58
|
+
function q({
|
|
59
|
+
className: t,
|
|
60
|
+
children: o,
|
|
61
|
+
container: i,
|
|
62
|
+
side: c = "bottom",
|
|
63
|
+
sideOffset: s = 4,
|
|
64
|
+
align: u = "start",
|
|
65
|
+
alignOffset: _ = 0,
|
|
66
|
+
positionMethod: f,
|
|
67
|
+
collisionBoundary: I,
|
|
68
|
+
collisionPadding: g,
|
|
69
|
+
...h
|
|
70
|
+
}) {
|
|
71
|
+
const b = x(m), d = i ?? b;
|
|
72
|
+
return /* @__PURE__ */ e(m.Provider, { value: d, children: /* @__PURE__ */ e(r.Portal, { container: d, children: /* @__PURE__ */ e(
|
|
73
|
+
r.Positioner,
|
|
74
|
+
{
|
|
75
|
+
side: c,
|
|
76
|
+
sideOffset: s,
|
|
77
|
+
align: u,
|
|
78
|
+
alignOffset: _,
|
|
79
|
+
positionMethod: f,
|
|
80
|
+
collisionBoundary: I,
|
|
81
|
+
collisionPadding: g,
|
|
82
|
+
className: n.positioner,
|
|
83
|
+
children: /* @__PURE__ */ e(r.Popup, { className: a(n.popup, t), ...h, children: o })
|
|
84
|
+
}
|
|
85
|
+
) }) });
|
|
86
|
+
}
|
|
87
|
+
function O({ className: t, ...o }) {
|
|
88
|
+
return /* @__PURE__ */ e(r.Group, { className: t, ...o });
|
|
89
|
+
}
|
|
90
|
+
function Q({ className: t, ...o }) {
|
|
91
|
+
return /* @__PURE__ */ e(r.GroupLabel, { className: a(n.label, t), ...o });
|
|
92
|
+
}
|
|
93
|
+
const z = v(n.item, {
|
|
94
|
+
variants: {
|
|
95
|
+
variant: {
|
|
96
|
+
default: n.variantDefault,
|
|
97
|
+
destructive: n.variantDestructive
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
defaultVariants: {
|
|
101
|
+
variant: "default"
|
|
102
|
+
}
|
|
103
|
+
});
|
|
104
|
+
function U({ className: t, variant: o, ...i }) {
|
|
105
|
+
return /* @__PURE__ */ e(r.Item, { className: z({ variant: o, className: t }), ...i });
|
|
106
|
+
}
|
|
107
|
+
function X({
|
|
108
|
+
className: t,
|
|
109
|
+
children: o,
|
|
110
|
+
...i
|
|
111
|
+
}) {
|
|
112
|
+
return /* @__PURE__ */ p(r.CheckboxItem, { className: a(n.checkboxItem, t), ...i, children: [
|
|
113
|
+
o,
|
|
114
|
+
/* @__PURE__ */ e(r.CheckboxItemIndicator, { className: n.itemIndicator, children: /* @__PURE__ */ e(l, {}) })
|
|
115
|
+
] });
|
|
116
|
+
}
|
|
117
|
+
function Y({ className: t, ...o }) {
|
|
118
|
+
return /* @__PURE__ */ e(r.RadioGroup, { className: t, ...o });
|
|
119
|
+
}
|
|
120
|
+
function Z({
|
|
121
|
+
className: t,
|
|
122
|
+
children: o,
|
|
123
|
+
...i
|
|
124
|
+
}) {
|
|
125
|
+
return /* @__PURE__ */ p(r.RadioItem, { className: a(n.radioItem, t), ...i, children: [
|
|
126
|
+
o,
|
|
127
|
+
/* @__PURE__ */ e(r.RadioItemIndicator, { className: n.itemIndicator, children: /* @__PURE__ */ e(l, {}) })
|
|
128
|
+
] });
|
|
129
|
+
}
|
|
130
|
+
function $({ className: t, ...o }) {
|
|
131
|
+
return /* @__PURE__ */ e(r.Separator, { className: a(n.separator, t), ...o });
|
|
132
|
+
}
|
|
133
|
+
function tt({ className: t, ...o }) {
|
|
134
|
+
return /* @__PURE__ */ e("span", { className: a(n.shortcut, t), ...o });
|
|
135
|
+
}
|
|
136
|
+
const ot = r.SubmenuRoot;
|
|
137
|
+
function et({
|
|
138
|
+
className: t,
|
|
139
|
+
children: o,
|
|
140
|
+
...i
|
|
141
|
+
}) {
|
|
142
|
+
return /* @__PURE__ */ p(r.SubmenuTrigger, { className: a(n.subTrigger, t), ...i, children: [
|
|
143
|
+
o,
|
|
144
|
+
/* @__PURE__ */ e(y, { className: n.subTriggerIcon })
|
|
145
|
+
] });
|
|
146
|
+
}
|
|
147
|
+
function nt({
|
|
148
|
+
className: t,
|
|
149
|
+
side: o = "right",
|
|
150
|
+
align: i = "start",
|
|
151
|
+
sideOffset: c = 0,
|
|
152
|
+
alignOffset: s = -3,
|
|
153
|
+
...u
|
|
154
|
+
}) {
|
|
155
|
+
return /* @__PURE__ */ e(
|
|
156
|
+
q,
|
|
157
|
+
{
|
|
158
|
+
className: a(n.subPopup, t),
|
|
159
|
+
side: o,
|
|
160
|
+
align: i,
|
|
161
|
+
sideOffset: c,
|
|
162
|
+
alignOffset: s,
|
|
163
|
+
...u
|
|
164
|
+
}
|
|
165
|
+
);
|
|
166
|
+
}
|
|
167
|
+
export {
|
|
168
|
+
J as DropdownMenu,
|
|
169
|
+
X as DropdownMenuCheckboxItem,
|
|
170
|
+
q as DropdownMenuContent,
|
|
171
|
+
O as DropdownMenuGroup,
|
|
172
|
+
U as DropdownMenuItem,
|
|
173
|
+
Q as DropdownMenuLabel,
|
|
174
|
+
Y as DropdownMenuRadioGroup,
|
|
175
|
+
Z as DropdownMenuRadioItem,
|
|
176
|
+
$ as DropdownMenuSeparator,
|
|
177
|
+
tt as DropdownMenuShortcut,
|
|
178
|
+
ot as DropdownMenuSub,
|
|
179
|
+
nt as DropdownMenuSubContent,
|
|
180
|
+
et as DropdownMenuSubTrigger,
|
|
181
|
+
K as DropdownMenuTrigger
|
|
182
|
+
};
|
|
183
|
+
//# sourceMappingURL=dropdown-menu.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dropdown-menu.js","sources":["../src/components/dropdown-menu/dropdown-menu.tsx"],"sourcesContent":["import { Menu as MenuPrimitive } from '@base-ui/react/menu';\nimport { cva, cx, type VariantProps } from 'class-variance-authority';\nimport { type ComponentProps, createContext, useContext } from 'react';\n\nimport styles from './dropdown-menu.module.css';\n\n/*\n * Carries DropdownMenuContent's effective portal container down to nested\n * submenus, so a theme scoped to a subtree holds one level deep without the\n * consumer repeating `container` on every DropdownMenuSubContent. An\n * explicit `container` on the submenu still wins.\n */\nconst MenuContainerContext = createContext<MenuPrimitive.Portal.Props['container']>(undefined);\n\n/* Inline lucide paths (ISC) — the kit carries no icon dependency. */\nfunction CheckIcon({ className }: { className?: string }) {\n return (\n <svg\n className={cx(styles.svgIcon, className)}\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n aria-hidden=\"true\"\n >\n <path d=\"M20 6 9 17l-5-5\" />\n </svg>\n );\n}\n\nfunction ChevronRightIcon({ className }: { className?: string }) {\n return (\n <svg\n className={cx(styles.svgIcon, className)}\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n aria-hidden=\"true\"\n >\n <path d=\"m9 18 6-6-6-6\" />\n </svg>\n );\n}\n\nexport const DropdownMenu = MenuPrimitive.Root;\n/**\n * The root is a Base UI pass-through, but its props type is still exported:\n * a consumer writing a typed wrapper imports it from this kit — Base UI is\n * this package's dependency, not necessarily theirs. Same idiom as\n * TooltipProviderProps.\n */\nexport type DropdownMenuProps = MenuPrimitive.Root.Props;\n\nexport interface DropdownMenuTriggerProps extends Omit<MenuPrimitive.Trigger.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuTrigger({ className, ...props }: DropdownMenuTriggerProps) {\n return <MenuPrimitive.Trigger className={className} {...props} />;\n}\n\nexport interface DropdownMenuContentProps\n extends Omit<MenuPrimitive.Popup.Props, 'className'>,\n Pick<\n MenuPrimitive.Positioner.Props,\n // positionMethod/collision*: the escape hatch for popups anchored\n // inside a transform/filter container (an animated panel is the usual\n // case), where the default absolute positioning resolves against the\n // wrong containing block — positionMethod=\"fixed\" is the standard\n // fix, and it must be reachable without bypassing the kit.\n | 'align'\n | 'alignOffset'\n | 'side'\n | 'sideOffset'\n | 'positionMethod'\n | 'collisionBoundary'\n | 'collisionPadding'\n > {\n className?: string;\n /**\n * Where to portal the popup. Defaults to <body>. Pass a themed container\n * when the theme is scoped to a subtree (data-theme on a container that\n * isn't at document root) so the popup inherits its tokens and font.\n * Inherited by nested DropdownMenuSubContent unless it passes its own.\n */\n container?: MenuPrimitive.Portal.Props['container'];\n}\n\nexport function DropdownMenuContent({\n className,\n children,\n container,\n side = 'bottom',\n sideOffset = 4,\n align = 'start',\n alignOffset = 0,\n positionMethod,\n collisionBoundary,\n collisionPadding,\n ...props\n}: DropdownMenuContentProps) {\n const inheritedContainer = useContext(MenuContainerContext);\n const effectiveContainer = container ?? inheritedContainer;\n return (\n <MenuContainerContext.Provider value={effectiveContainer}>\n <MenuPrimitive.Portal container={effectiveContainer}>\n <MenuPrimitive.Positioner\n side={side}\n sideOffset={sideOffset}\n align={align}\n alignOffset={alignOffset}\n positionMethod={positionMethod}\n collisionBoundary={collisionBoundary}\n collisionPadding={collisionPadding}\n className={styles.positioner}\n >\n <MenuPrimitive.Popup className={cx(styles.popup, className)} {...props}>\n {children}\n </MenuPrimitive.Popup>\n </MenuPrimitive.Positioner>\n </MenuPrimitive.Portal>\n </MenuContainerContext.Provider>\n );\n}\n\nexport interface DropdownMenuGroupProps extends Omit<MenuPrimitive.Group.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuGroup({ className, ...props }: DropdownMenuGroupProps) {\n return <MenuPrimitive.Group className={className} {...props} />;\n}\n\nexport interface DropdownMenuLabelProps extends Omit<MenuPrimitive.GroupLabel.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuLabel({ className, ...props }: DropdownMenuLabelProps) {\n return <MenuPrimitive.GroupLabel className={cx(styles.label, className)} {...props} />;\n}\n\nconst itemVariants = cva(styles.item, {\n variants: {\n variant: {\n default: styles.variantDefault,\n destructive: styles.variantDestructive,\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n});\n\nexport interface DropdownMenuItemProps\n extends Omit<MenuPrimitive.Item.Props, 'className'>, VariantProps<typeof itemVariants> {\n className?: string;\n}\n\nexport function DropdownMenuItem({ className, variant, ...props }: DropdownMenuItemProps) {\n return <MenuPrimitive.Item className={itemVariants({ variant, className })} {...props} />;\n}\n\nexport interface DropdownMenuCheckboxItemProps\n extends Omit<MenuPrimitive.CheckboxItem.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuCheckboxItem({\n className,\n children,\n ...props\n}: DropdownMenuCheckboxItemProps) {\n return (\n <MenuPrimitive.CheckboxItem className={cx(styles.checkboxItem, className)} {...props}>\n {children}\n <MenuPrimitive.CheckboxItemIndicator className={styles.itemIndicator}>\n <CheckIcon />\n </MenuPrimitive.CheckboxItemIndicator>\n </MenuPrimitive.CheckboxItem>\n );\n}\n\nexport interface DropdownMenuRadioGroupProps\n extends Omit<MenuPrimitive.RadioGroup.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuRadioGroup({ className, ...props }: DropdownMenuRadioGroupProps) {\n return <MenuPrimitive.RadioGroup className={className} {...props} />;\n}\n\nexport interface DropdownMenuRadioItemProps\n extends Omit<MenuPrimitive.RadioItem.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuRadioItem({\n className,\n children,\n ...props\n}: DropdownMenuRadioItemProps) {\n return (\n <MenuPrimitive.RadioItem className={cx(styles.radioItem, className)} {...props}>\n {children}\n <MenuPrimitive.RadioItemIndicator className={styles.itemIndicator}>\n <CheckIcon />\n </MenuPrimitive.RadioItemIndicator>\n </MenuPrimitive.RadioItem>\n );\n}\n\nexport interface DropdownMenuSeparatorProps\n extends Omit<MenuPrimitive.Separator.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuSeparator({ className, ...props }: DropdownMenuSeparatorProps) {\n return <MenuPrimitive.Separator className={cx(styles.separator, className)} {...props} />;\n}\n\nexport type DropdownMenuShortcutProps = ComponentProps<'span'>;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return <span className={cx(styles.shortcut, className)} {...props} />;\n}\n\nexport const DropdownMenuSub = MenuPrimitive.SubmenuRoot;\n/** Pass-through props type — see DropdownMenuProps. */\nexport type DropdownMenuSubProps = MenuPrimitive.SubmenuRoot.Props;\n\nexport interface DropdownMenuSubTriggerProps\n extends Omit<MenuPrimitive.SubmenuTrigger.Props, 'className'> {\n className?: string;\n}\n\nexport function DropdownMenuSubTrigger({\n className,\n children,\n ...props\n}: DropdownMenuSubTriggerProps) {\n return (\n <MenuPrimitive.SubmenuTrigger className={cx(styles.subTrigger, className)} {...props}>\n {children}\n <ChevronRightIcon className={styles.subTriggerIcon} />\n </MenuPrimitive.SubmenuTrigger>\n );\n}\n\nexport type DropdownMenuSubContentProps = DropdownMenuContentProps;\n\nexport function DropdownMenuSubContent({\n className,\n side = 'right',\n align = 'start',\n sideOffset = 0,\n alignOffset = -3,\n ...props\n}: DropdownMenuSubContentProps) {\n return (\n <DropdownMenuContent\n className={cx(styles.subPopup, className)}\n side={side}\n align={align}\n sideOffset={sideOffset}\n alignOffset={alignOffset}\n {...props}\n />\n );\n}\n"],"names":["MenuContainerContext","createContext","CheckIcon","className","jsx","cx","styles","ChevronRightIcon","DropdownMenu","MenuPrimitive","DropdownMenuTrigger","props","DropdownMenuContent","children","container","side","sideOffset","align","alignOffset","positionMethod","collisionBoundary","collisionPadding","inheritedContainer","useContext","effectiveContainer","DropdownMenuGroup","DropdownMenuLabel","itemVariants","cva","DropdownMenuItem","variant","DropdownMenuCheckboxItem","jsxs","DropdownMenuRadioGroup","DropdownMenuRadioItem","DropdownMenuSeparator","DropdownMenuShortcut","DropdownMenuSub","DropdownMenuSubTrigger","DropdownMenuSubContent"],"mappings":"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"}
|
package/dist/field.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/field/public.js'
|
package/dist/field.js
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { Field as i } from "@base-ui/react/field";
|
|
3
|
+
import { cx as t } from "class-variance-authority";
|
|
4
|
+
import { Label as s } from "./label.js";
|
|
5
|
+
import './chunks/field.BNZx8HfN.css';const c = "_field_t5n7g_6", l = "_description_t5n7g_24", d = "_error_t5n7g_31", n = {
|
|
6
|
+
field: c,
|
|
7
|
+
description: l,
|
|
8
|
+
error: d
|
|
9
|
+
};
|
|
10
|
+
function _({ className: r, ...e }) {
|
|
11
|
+
return /* @__PURE__ */ o(i.Root, { className: t(n.field, r), ...e });
|
|
12
|
+
}
|
|
13
|
+
function u({ className: r, ...e }) {
|
|
14
|
+
return /* @__PURE__ */ o(i.Label, { render: /* @__PURE__ */ o(s, {}), className: r, ...e });
|
|
15
|
+
}
|
|
16
|
+
function F({ className: r, ...e }) {
|
|
17
|
+
return /* @__PURE__ */ o(i.Description, { className: t(n.description, r), ...e });
|
|
18
|
+
}
|
|
19
|
+
function b({ className: r, ...e }) {
|
|
20
|
+
return /* @__PURE__ */ o(i.Error, { className: t(n.error, r), ...e });
|
|
21
|
+
}
|
|
22
|
+
export {
|
|
23
|
+
_ as Field,
|
|
24
|
+
F as FieldDescription,
|
|
25
|
+
b as FieldError,
|
|
26
|
+
u as FieldLabel
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=field.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"field.js","sources":["../src/components/field/field.tsx"],"sourcesContent":["import { Field as FieldPrimitive } from '@base-ui/react/field';\nimport { cx } from 'class-variance-authority';\n\nimport { Label } from '../label/label';\nimport styles from './field.module.css';\n\nexport interface FieldProps extends Omit<FieldPrimitive.Root.Props, 'className'> {\n className?: string;\n}\n\nexport function Field({ className, ...props }: FieldProps) {\n return <FieldPrimitive.Root className={cx(styles.field, className)} {...props} />;\n}\n\nexport interface FieldLabelProps extends Omit<FieldPrimitive.Label.Props, 'className'> {\n className?: string;\n}\n\n/* Renders the kit Label through Base UI Field.Label, which wires htmlFor /\n * id to the field's control automatically. */\nexport function FieldLabel({ className, ...props }: FieldLabelProps) {\n return <FieldPrimitive.Label render={<Label />} className={className} {...props} />;\n}\n\nexport interface FieldDescriptionProps extends Omit<FieldPrimitive.Description.Props, 'className'> {\n className?: string;\n}\n\nexport function FieldDescription({ className, ...props }: FieldDescriptionProps) {\n return <FieldPrimitive.Description className={cx(styles.description, className)} {...props} />;\n}\n\nexport interface FieldErrorProps extends Omit<FieldPrimitive.Error.Props, 'className'> {\n className?: string;\n}\n\nexport function FieldError({ className, ...props }: FieldErrorProps) {\n return <FieldPrimitive.Error className={cx(styles.error, className)} {...props} />;\n}\n"],"names":["Field","className","props","jsx","FieldPrimitive","cx","styles","FieldLabel","Label","FieldDescription","FieldError"],"mappings":";;;;;;;;;AAUO,SAASA,EAAM,EAAE,WAAAC,GAAW,GAAGC,KAAqB;AACzD,SAAO,gBAAAC,EAACC,EAAe,MAAf,EAAoB,WAAWC,EAAGC,EAAO,OAAOL,CAAS,GAAI,GAAGC,EAAA,CAAO;AACjF;AAQO,SAASK,EAAW,EAAE,WAAAN,GAAW,GAAGC,KAA0B;AACnE,SAAO,gBAAAC,EAACC,EAAe,OAAf,EAAqB,0BAASI,GAAA,EAAM,GAAI,WAAAP,GAAuB,GAAGC,EAAA,CAAO;AACnF;AAMO,SAASO,EAAiB,EAAE,WAAAR,GAAW,GAAGC,KAAgC;AAC/E,SAAO,gBAAAC,EAACC,EAAe,aAAf,EAA2B,WAAWC,EAAGC,EAAO,aAAaL,CAAS,GAAI,GAAGC,EAAA,CAAO;AAC9F;AAMO,SAASQ,EAAW,EAAE,WAAAT,GAAW,GAAGC,KAA0B;AACnE,SAAO,gBAAAC,EAACC,EAAe,OAAf,EAAqB,WAAWC,EAAGC,EAAO,OAAOL,CAAS,GAAI,GAAGC,EAAA,CAAO;AAClF;"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @gears-frontx/ui-kit — standard component base for Constructor Fabric
|
|
3
|
+
* templates.
|
|
4
|
+
*
|
|
5
|
+
* Styles ship separately: import '@gears-frontx/ui-kit/theme.css' (design
|
|
6
|
+
* tokens) once in the consumer entry module. Component CSS ships alongside
|
|
7
|
+
* each component's own chunk (see vite.config.ts / scripts/buildPlugin.ts)
|
|
8
|
+
* and needs no separate import — importing a component pulls its styles in
|
|
9
|
+
* with it.
|
|
10
|
+
*
|
|
11
|
+
* This barrel re-exports every component's public.ts rather than declaring
|
|
12
|
+
* exports itself. Each public.ts is also its own build entry (globbed in
|
|
13
|
+
* scripts/buildPlugin.ts), so `export * from './components/x/public'` here
|
|
14
|
+
* re-exports an already-separate chunk instead of inlining one — that's what
|
|
15
|
+
* keeps this barrel tree-shakeable: a consumer importing only `Button` gets
|
|
16
|
+
* a thin dist/index.js that re-exports dist/button.js and 18 sibling chunks
|
|
17
|
+
* it never touches, and their bundler can drop the ones it never imports.
|
|
18
|
+
*
|
|
19
|
+
* Relative specifiers below carry an explicit `.js` extension even though
|
|
20
|
+
* the source files are `.ts` — required because this flows straight into
|
|
21
|
+
* the emitted `dist/index.d.ts`, and a consumer building under
|
|
22
|
+
* `moduleResolution: "nodenext"` rejects extensionless relative specifiers
|
|
23
|
+
* in an ESM package's declarations (TS2305, every symbol invisible). The
|
|
24
|
+
* `.js` specifier still resolves to the local `.ts` file under our own
|
|
25
|
+
* `moduleResolution: "bundler"` (and under Vite/vitest, which special-case
|
|
26
|
+
* a `.js` specifier resolving to a sibling `.ts`/`.tsx`) — it is not a
|
|
27
|
+
* claim that a `.js` file exists here.
|
|
28
|
+
*/
|
|
29
|
+
export * from './components/badge/public.js';
|
|
30
|
+
export * from './components/button/public.js';
|
|
31
|
+
export * from './components/card/public.js';
|
|
32
|
+
export * from './components/checkbox/public.js';
|
|
33
|
+
export * from './components/dialog/public.js';
|
|
34
|
+
export * from './components/dropdown-menu/public.js';
|
|
35
|
+
export * from './components/field/public.js';
|
|
36
|
+
export * from './components/input/public.js';
|
|
37
|
+
export * from './components/label/public.js';
|
|
38
|
+
export * from './components/radio-group/public.js';
|
|
39
|
+
export * from './components/select/public.js';
|
|
40
|
+
export * from './components/separator/public.js';
|
|
41
|
+
export * from './components/skeleton/public.js';
|
|
42
|
+
export * from './components/switch/public.js';
|
|
43
|
+
export * from './components/table/public.js';
|
|
44
|
+
export * from './components/tabs/public.js';
|
|
45
|
+
export * from './components/textarea/public.js';
|
|
46
|
+
export * from './components/toast/public.js';
|
|
47
|
+
export * from './components/tooltip/public.js';
|
|
48
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,cAAc,8BAA8B,CAAC;AAC7C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,oCAAoC,CAAC;AACnD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { Badge as r } from "./badge.js";
|
|
2
|
+
import { Button as a } from "./button.js";
|
|
3
|
+
import { Card as p, CardAction as l, CardContent as i, CardDescription as d, CardFooter as u, CardHeader as T, CardTitle as D } from "./card.js";
|
|
4
|
+
import { Checkbox as g } from "./checkbox.js";
|
|
5
|
+
import { Dialog as b, DialogClose as c, DialogContent as S, DialogDescription as f, DialogFooter as C, DialogHeader as w, DialogTitle as M, DialogTrigger as s } from "./dialog.js";
|
|
6
|
+
import { DropdownMenu as I, DropdownMenuCheckboxItem as B, DropdownMenuContent as G, DropdownMenuGroup as L, DropdownMenuItem as R, DropdownMenuLabel as h, DropdownMenuRadioGroup as H, DropdownMenuRadioItem as k, DropdownMenuSeparator as v, DropdownMenuShortcut as y, DropdownMenuSub as A, DropdownMenuSubContent as E, DropdownMenuSubTrigger as P, DropdownMenuTrigger as U } from "./dropdown-menu.js";
|
|
7
|
+
import { Field as j, FieldDescription as q, FieldError as z, FieldLabel as J } from "./field.js";
|
|
8
|
+
import { Input as N } from "./input.js";
|
|
9
|
+
import { Label as Q } from "./label.js";
|
|
10
|
+
import { RadioGroup as X, RadioGroupItem as Y } from "./radio-group.js";
|
|
11
|
+
import { Select as _, SelectContent as $, SelectGroup as oo, SelectItem as eo, SelectLabel as ro, SelectScrollDownButton as to, SelectScrollUpButton as ao, SelectSeparator as no, SelectTrigger as po, SelectValue as lo } from "./select.js";
|
|
12
|
+
import { Separator as uo } from "./separator.js";
|
|
13
|
+
import { Skeleton as Do } from "./skeleton.js";
|
|
14
|
+
import { Switch as go } from "./switch.js";
|
|
15
|
+
import { Table as bo, TableBody as co, TableCaption as So, TableCell as fo, TableFooter as Co, TableHead as wo, TableHeader as Mo, TableRow as so } from "./table.js";
|
|
16
|
+
import { Tabs as Io, TabsContent as Bo, TabsList as Go, TabsTrigger as Lo } from "./tabs.js";
|
|
17
|
+
import { Textarea as ho } from "./textarea.js";
|
|
18
|
+
import { Toaster as ko, createToastManager as vo, toast as yo, useToastManager as Ao } from "./toast.js";
|
|
19
|
+
import { Tooltip as Po, TooltipContent as Uo, TooltipProvider as Vo, TooltipTrigger as jo } from "./tooltip.js";
|
|
20
|
+
export {
|
|
21
|
+
r as Badge,
|
|
22
|
+
a as Button,
|
|
23
|
+
p as Card,
|
|
24
|
+
l as CardAction,
|
|
25
|
+
i as CardContent,
|
|
26
|
+
d as CardDescription,
|
|
27
|
+
u as CardFooter,
|
|
28
|
+
T as CardHeader,
|
|
29
|
+
D as CardTitle,
|
|
30
|
+
g as Checkbox,
|
|
31
|
+
b as Dialog,
|
|
32
|
+
c as DialogClose,
|
|
33
|
+
S as DialogContent,
|
|
34
|
+
f as DialogDescription,
|
|
35
|
+
C as DialogFooter,
|
|
36
|
+
w as DialogHeader,
|
|
37
|
+
M as DialogTitle,
|
|
38
|
+
s as DialogTrigger,
|
|
39
|
+
I as DropdownMenu,
|
|
40
|
+
B as DropdownMenuCheckboxItem,
|
|
41
|
+
G as DropdownMenuContent,
|
|
42
|
+
L as DropdownMenuGroup,
|
|
43
|
+
R as DropdownMenuItem,
|
|
44
|
+
h as DropdownMenuLabel,
|
|
45
|
+
H as DropdownMenuRadioGroup,
|
|
46
|
+
k as DropdownMenuRadioItem,
|
|
47
|
+
v as DropdownMenuSeparator,
|
|
48
|
+
y as DropdownMenuShortcut,
|
|
49
|
+
A as DropdownMenuSub,
|
|
50
|
+
E as DropdownMenuSubContent,
|
|
51
|
+
P as DropdownMenuSubTrigger,
|
|
52
|
+
U as DropdownMenuTrigger,
|
|
53
|
+
j as Field,
|
|
54
|
+
q as FieldDescription,
|
|
55
|
+
z as FieldError,
|
|
56
|
+
J as FieldLabel,
|
|
57
|
+
N as Input,
|
|
58
|
+
Q as Label,
|
|
59
|
+
X as RadioGroup,
|
|
60
|
+
Y as RadioGroupItem,
|
|
61
|
+
_ as Select,
|
|
62
|
+
$ as SelectContent,
|
|
63
|
+
oo as SelectGroup,
|
|
64
|
+
eo as SelectItem,
|
|
65
|
+
ro as SelectLabel,
|
|
66
|
+
to as SelectScrollDownButton,
|
|
67
|
+
ao as SelectScrollUpButton,
|
|
68
|
+
no as SelectSeparator,
|
|
69
|
+
po as SelectTrigger,
|
|
70
|
+
lo as SelectValue,
|
|
71
|
+
uo as Separator,
|
|
72
|
+
Do as Skeleton,
|
|
73
|
+
go as Switch,
|
|
74
|
+
bo as Table,
|
|
75
|
+
co as TableBody,
|
|
76
|
+
So as TableCaption,
|
|
77
|
+
fo as TableCell,
|
|
78
|
+
Co as TableFooter,
|
|
79
|
+
wo as TableHead,
|
|
80
|
+
Mo as TableHeader,
|
|
81
|
+
so as TableRow,
|
|
82
|
+
Io as Tabs,
|
|
83
|
+
Bo as TabsContent,
|
|
84
|
+
Go as TabsList,
|
|
85
|
+
Lo as TabsTrigger,
|
|
86
|
+
ho as Textarea,
|
|
87
|
+
ko as Toaster,
|
|
88
|
+
Po as Tooltip,
|
|
89
|
+
Uo as TooltipContent,
|
|
90
|
+
Vo as TooltipProvider,
|
|
91
|
+
jo as TooltipTrigger,
|
|
92
|
+
vo as createToastManager,
|
|
93
|
+
yo as toast,
|
|
94
|
+
Ao as useToastManager
|
|
95
|
+
};
|
|
96
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;"}
|
package/dist/input.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/input/public.js'
|
package/dist/input.js
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
2
|
+
import { Input as o } from "@base-ui/react/input";
|
|
3
|
+
import { cx as h } from "class-variance-authority";
|
|
4
|
+
import './chunks/input.CrRQ0OAn.css';const p = "_input_1y6th_6", i = "_searchWrap_1y6th_120", u = "_searchIcon_1y6th_126", _ = "_searchInput_1y6th_137", r = {
|
|
5
|
+
input: p,
|
|
6
|
+
searchWrap: i,
|
|
7
|
+
searchIcon: u,
|
|
8
|
+
searchInput: _
|
|
9
|
+
};
|
|
10
|
+
function d({ className: e, type: s, ...a }) {
|
|
11
|
+
const c = /* @__PURE__ */ t(
|
|
12
|
+
o,
|
|
13
|
+
{
|
|
14
|
+
type: s,
|
|
15
|
+
className: h(r.input, s === "search" && r.searchInput, e),
|
|
16
|
+
...a
|
|
17
|
+
}
|
|
18
|
+
);
|
|
19
|
+
return s !== "search" ? c : /* @__PURE__ */ n("span", { className: r.searchWrap, children: [
|
|
20
|
+
/* @__PURE__ */ n("svg", { className: r.searchIcon, "aria-hidden": "true", viewBox: "0 0 16 16", fill: "none", children: [
|
|
21
|
+
/* @__PURE__ */ t("circle", { cx: "7", cy: "7", r: "4.5", stroke: "currentColor", strokeWidth: "1.5" }),
|
|
22
|
+
/* @__PURE__ */ t("path", { d: "m10.5 10.5 3 3", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
|
|
23
|
+
] }),
|
|
24
|
+
c
|
|
25
|
+
] });
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
d as Input
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=input.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"input.js","sources":["../src/components/input/input.tsx"],"sourcesContent":["import { Input as InputPrimitive } from '@base-ui/react/input';\nimport { cx } from 'class-variance-authority';\n\nimport styles from './input.module.css';\n\nexport interface InputProps extends Omit<InputPrimitive.Props, 'className'> {\n className?: string;\n}\n\nexport function Input({ className, type, ...props }: InputProps) {\n const input = (\n <InputPrimitive\n type={type}\n className={cx(styles.input, type === 'search' && styles.searchInput, className)}\n {...props}\n />\n );\n if (type !== 'search') {\n return input;\n }\n /*\n * The mockups' Field/search type (Figma frame 193:433) is the same field\n * with a leading magnifier. An <input> is a replaced element — no\n * ::before to draw into, and a background-image can't read the theme's\n * color tokens — so the icon needs this presentational wrapper. Only\n * type=\"search\" pays for it: every other type stays a bare <input>, and\n * the consumer className stays on the input either way, so styling\n * targets the same element regardless of type. Field wiring is\n * unaffected — the primitive is still the control Field talks to.\n */\n return (\n <span className={styles.searchWrap}>\n <svg className={styles.searchIcon} aria-hidden=\"true\" viewBox=\"0 0 16 16\" fill=\"none\">\n <circle cx=\"7\" cy=\"7\" r=\"4.5\" stroke=\"currentColor\" strokeWidth=\"1.5\" />\n <path d=\"m10.5 10.5 3 3\" stroke=\"currentColor\" strokeWidth=\"1.5\" strokeLinecap=\"round\" />\n </svg>\n {input}\n </span>\n );\n}\n"],"names":["Input","className","type","props","input","jsx","InputPrimitive","cx","styles","jsxs"],"mappings":";;;;;;;;;AASO,SAASA,EAAM,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,KAAqB;AAC/D,QAAMC,IACJ,gBAAAC;AAAA,IAACC;AAAAA,IAAA;AAAA,MACC,MAAAJ;AAAA,MACA,WAAWK,EAAGC,EAAO,OAAON,MAAS,YAAYM,EAAO,aAAaP,CAAS;AAAA,MAC7E,GAAGE;AAAA,IAAA;AAAA,EAAA;AAGR,SAAID,MAAS,WACJE,IAaP,gBAAAK,EAAC,QAAA,EAAK,WAAWD,EAAO,YACtB,UAAA;AAAA,IAAA,gBAAAC,EAAC,OAAA,EAAI,WAAWD,EAAO,YAAY,eAAY,QAAO,SAAQ,aAAY,MAAK,QAC7E,UAAA;AAAA,MAAA,gBAAAH,EAAC,UAAA,EAAO,IAAG,KAAI,IAAG,KAAI,GAAE,OAAM,QAAO,gBAAe,aAAY,MAAA,CAAM;AAAA,MACtE,gBAAAA,EAAC,UAAK,GAAE,kBAAiB,QAAO,gBAAe,aAAY,OAAM,eAAc,QAAA,CAAQ;AAAA,IAAA,GACzF;AAAA,IACCD;AAAA,EAAA,GACH;AAEJ;"}
|
package/dist/label.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/label/public.js'
|
package/dist/label.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { cx as o } from "class-variance-authority";
|
|
3
|
+
import './chunks/label.jrB9zD_G.css';const t = "_label_1xy7e_10", r = {
|
|
4
|
+
label: t
|
|
5
|
+
};
|
|
6
|
+
function c({ className: l, ...e }) {
|
|
7
|
+
return /* @__PURE__ */ a("label", { className: o(r.label, l), ...e });
|
|
8
|
+
}
|
|
9
|
+
export {
|
|
10
|
+
c as Label
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=label.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"label.js","sources":["../src/components/label/label.tsx"],"sourcesContent":["import { cx } from 'class-variance-authority';\nimport type { ComponentProps } from 'react';\n\nimport styles from './label.module.css';\n\nexport type LabelProps = ComponentProps<'label'>;\n\nexport function Label({ className, ...props }: LabelProps) {\n return <label className={cx(styles.label, className)} {...props} />;\n}\n"],"names":["Label","className","props","jsx","cx","styles"],"mappings":";;;;;AAOO,SAASA,EAAM,EAAE,WAAAC,GAAW,GAAGC,KAAqB;AACzD,SAAO,gBAAAC,EAAC,WAAM,WAAWC,EAAGC,EAAO,OAAOJ,CAAS,GAAI,GAAGC,GAAO;AACnE;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/radio-group/public.js'
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { Radio as a } from "@base-ui/react/radio";
|
|
3
|
+
import { RadioGroup as n } from "@base-ui/react/radio-group";
|
|
4
|
+
import { cx as c } from "class-variance-authority";
|
|
5
|
+
import './chunks/radio-group.1Y6B0lXt.css';const s = "_group_4704v_6", m = "_item_4704v_12", d = "_indicator_4704v_90", e = "_dot_4704v_98", t = {
|
|
6
|
+
group: s,
|
|
7
|
+
item: m,
|
|
8
|
+
indicator: d,
|
|
9
|
+
dot: e
|
|
10
|
+
};
|
|
11
|
+
function f({ className: r, ...i }) {
|
|
12
|
+
return /* @__PURE__ */ o(n, { className: c(t.group, r), ...i });
|
|
13
|
+
}
|
|
14
|
+
function R({ className: r, ...i }) {
|
|
15
|
+
return /* @__PURE__ */ o(a.Root, { className: c(t.item, r), ...i, children: /* @__PURE__ */ o(a.Indicator, { className: t.indicator, children: /* @__PURE__ */ o("span", { className: t.dot }) }) });
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
f as RadioGroup,
|
|
19
|
+
R as RadioGroupItem
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=radio-group.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"radio-group.js","sources":["../src/components/radio-group/radio-group.tsx"],"sourcesContent":["import { Radio as RadioPrimitive } from '@base-ui/react/radio';\nimport { RadioGroup as RadioGroupPrimitive } from '@base-ui/react/radio-group';\nimport { cx } from 'class-variance-authority';\n\nimport styles from './radio-group.module.css';\n\nexport interface RadioGroupProps extends Omit<RadioGroupPrimitive.Props, 'className'> {\n className?: string;\n}\n\nexport function RadioGroup({ className, ...props }: RadioGroupProps) {\n return <RadioGroupPrimitive className={cx(styles.group, className)} {...props} />;\n}\n\nexport interface RadioGroupItemProps extends Omit<RadioPrimitive.Root.Props, 'className'> {\n className?: string;\n}\n\nexport function RadioGroupItem({ className, ...props }: RadioGroupItemProps) {\n return (\n <RadioPrimitive.Root className={cx(styles.item, className)} {...props}>\n <RadioPrimitive.Indicator className={styles.indicator}>\n <span className={styles.dot} />\n </RadioPrimitive.Indicator>\n </RadioPrimitive.Root>\n );\n}\n"],"names":["RadioGroup","className","props","jsx","RadioGroupPrimitive","cx","styles","RadioGroupItem","RadioPrimitive"],"mappings":";;;;;;;;;;AAUO,SAASA,EAAW,EAAE,WAAAC,GAAW,GAAGC,KAA0B;AACnE,SAAO,gBAAAC,EAACC,KAAoB,WAAWC,EAAGC,EAAO,OAAOL,CAAS,GAAI,GAAGC,GAAO;AACjF;AAMO,SAASK,EAAe,EAAE,WAAAN,GAAW,GAAGC,KAA8B;AAC3E,SACE,gBAAAC,EAACK,EAAe,MAAf,EAAoB,WAAWH,EAAGC,EAAO,MAAML,CAAS,GAAI,GAAGC,GAC9D,4BAACM,EAAe,WAAf,EAAyB,WAAWF,EAAO,WAC1C,UAAA,gBAAAH,EAAC,QAAA,EAAK,WAAWG,EAAO,IAAA,CAAK,EAAA,CAC/B,EAAA,CACF;AAEJ;"}
|
package/dist/select.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/select/public.js'
|