@godxjp/ui 22.0.0 → 23.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/README.md +4 -4
- package/dist/app/date-format-labels.d.ts +14 -2
- package/dist/app/date-format-labels.js +1 -1
- package/dist/app/date-formats.d.ts +14 -2
- package/dist/app/date-formats.js +9 -2
- package/dist/components/data-display/data-table.d.ts +8 -1
- package/dist/components/data-display/data-table.js +9 -2
- package/dist/components/data-display/scroll-area.d.ts +24 -4
- package/dist/components/data-display/scroll-area.js +34 -72
- package/dist/components/data-entry/cascader.js +8 -6
- package/dist/components/data-entry/checkbox.js +3 -1
- package/dist/components/data-entry/choice-hit-target.d.ts +24 -0
- package/dist/components/data-entry/choice-hit-target.js +12 -0
- package/dist/components/data-entry/control-surface.d.ts +8 -0
- package/dist/components/data-entry/control-surface.js +10 -1
- package/dist/components/data-entry/form-field.js +5 -4
- package/dist/components/data-entry/input.js +1 -1
- package/dist/components/data-entry/number-input.js +27 -6
- package/dist/components/data-entry/radio.js +4 -3
- package/dist/components/data-entry/search-select.js +225 -95
- package/dist/components/data-entry/select.d.ts +76 -14
- package/dist/components/data-entry/select.js +495 -163
- package/dist/components/data-entry/slider.d.ts +3 -11
- package/dist/components/data-entry/slider.js +582 -93
- package/dist/components/data-entry/switch.js +3 -1
- package/dist/components/feedback/dialog.js +2 -2
- package/dist/components/feedback/sheet.js +2 -22
- package/dist/components/navigation/dropdown-menu.d.ts +11 -3
- package/dist/components/navigation/dropdown-menu.js +190 -15
- package/dist/components/navigation/filter-bar.js +2 -1
- package/dist/components/navigation/index.d.ts +0 -3
- package/dist/components/navigation/index.js +0 -78
- package/dist/components/navigation/tabs.js +16 -4
- package/dist/components/ui/index.d.ts +0 -3
- package/dist/components/ui/index.js +0 -3
- package/dist/components/ui/input-otp.d.ts +1 -1
- package/dist/components/ui/segmented.js +3 -1
- package/dist/components/ui/tag-input.js +3 -5
- package/dist/i18n/messages/en.json +5 -1
- package/dist/i18n/messages/ja.json +5 -1
- package/dist/i18n/messages/vi.json +5 -1
- package/dist/lib/breakpoint-token.d.ts +8 -0
- package/dist/lib/breakpoint-token.js +29 -0
- package/dist/lib/select-options.d.ts +21 -0
- package/dist/lib/select-options.js +46 -0
- package/dist/props/components/data-display.prop.d.ts +17 -7
- package/dist/props/components/data-entry.prop.d.ts +323 -30
- package/dist/props/components/index.d.ts +1 -1
- package/dist/props/components/navigation.prop.d.ts +25 -1
- package/dist/props/registry.d.ts +69 -1
- package/dist/props/registry.js +75 -0
- package/dist/props/vocabulary/data.prop.d.ts +5 -0
- package/dist/props/vocabulary/index.d.ts +1 -1
- package/dist/styles/control.css +246 -28
- package/dist/styles/data-display-layout.css +18 -10
- package/dist/styles/focus-ring.css +28 -0
- package/dist/styles/fonts.css +88 -4
- package/dist/styles/form-layout.css +4 -0
- package/dist/styles/layout.css +2 -1
- package/dist/styles/navigation-layout.css +24 -238
- package/dist/styles/shell-layout.css +148 -139
- package/dist/styles/table-layout.css +12 -5
- package/dist/tokens/components/control.css +12 -3
- package/dist/tokens/components/data-display.css +0 -5
- package/dist/tokens/components/navigation.css +5 -5
- package/dist/tokens/components/scroll-area.css +7 -0
- package/docs/CONSUMER-RULES.md +7 -2
- package/docs/CUSTOMER-THEMING.md +25 -9
- package/docs/DATETIME.md +11 -2
- package/docs/FRAME-COVERAGE-REPORT.md +4 -7
- package/docs/SPACING.md +35 -5
- package/docs/TOKENS.md +1 -1
- package/docs/data-display/data-table/index.tsx +44 -3
- package/docs/data-display/popover.tsx +4 -6
- package/docs/data-display/scroll-area.tsx +51 -45
- package/docs/data-display/table.tsx +1 -1
- package/docs/data-entry/date-picker.tsx +2 -3
- package/docs/data-entry/input-otp.tsx +5 -2
- package/docs/data-entry/segmented-in-filter-row.tsx +77 -0
- package/docs/data-entry/segmented.tsx +40 -1
- package/docs/data-entry/select-matrix.tsx +1 -2
- package/docs/data-entry/select.tsx +108 -3
- package/docs/data-entry/slider.tsx +125 -47
- package/docs/feedback/dialog.tsx +1 -2
- package/docs/feedback/sheet.tsx +1 -2
- package/docs/layout/app-shell-states.tsx +143 -0
- package/docs/navigation/dropdown-menu.tsx +77 -6
- package/docs/navigation/tabs.tsx +72 -0
- package/docs/roadmap/ai-chat-components.md +1 -2
- package/docs/roadmap/parity-audit-data-entry.md +44 -33
- package/docs/roadmap/parity-audit-layout-navigation-general.md +304 -310
- package/docs/roadmap/parity-backlog.md +2 -3
- package/docs/roadmap/tree-components.md +0 -1
- package/package.json +25 -55
- package/scripts/_agent-setup.mjs +18 -0
- package/scripts/guinea-pig-skill.md +12 -6
- package/scripts/ui-audit.mjs +185 -7
- package/scripts/visual-audit-rules.mjs +0 -7
- package/scripts/visual-audit.mjs +6 -27
- package/dist/components/navigation/context-menu.d.ts +0 -21
- package/dist/components/navigation/context-menu.js +0 -149
- package/dist/components/navigation/menubar.d.ts +0 -28
- package/dist/components/navigation/menubar.js +0 -136
- package/dist/components/navigation/navigation-menu.d.ts +0 -10
- package/dist/components/navigation/navigation-menu.js +0 -91
- package/dist/components/ui/context-menu.d.ts +0 -1
- package/dist/components/ui/context-menu.js +0 -2
- package/dist/components/ui/menubar.d.ts +0 -1
- package/dist/components/ui/menubar.js +0 -2
- package/dist/components/ui/navigation-menu.d.ts +0 -1
- package/dist/components/ui/navigation-menu.js +0 -2
- package/docs/FRAME-A11Y-CI.md +0 -349
- package/docs/navigation/context-menu.tsx +0 -128
- package/docs/navigation/menubar.tsx +0 -141
- package/docs/navigation/navigation-menu.tsx +0 -158
|
@@ -7,13 +7,6 @@
|
|
|
7
7
|
|
|
8
8
|
/** Catalog (agent-facing mirror lives in mcp/src/data/visual-rules.ts; kept in sync by a guard). */
|
|
9
9
|
export const VISUAL_RULES = [
|
|
10
|
-
{
|
|
11
|
-
id: "axe-violations",
|
|
12
|
-
severity: "warn",
|
|
13
|
-
category: "a11y",
|
|
14
|
-
standard: "WCAG 2.2 A/AA · WAI-ARIA 1.2 (axe-core engine)",
|
|
15
|
-
fix: "Fix each axe violation at its node — contrast (1.4.3), name/role/value (4.1.2), ARIA, landmarks. axe runs on the REAL DOM, catching what static analysis cannot.",
|
|
16
|
-
},
|
|
17
10
|
{
|
|
18
11
|
id: "target-size-min",
|
|
19
12
|
severity: "warn",
|
package/scripts/visual-audit.mjs
CHANGED
|
@@ -23,8 +23,6 @@ import {
|
|
|
23
23
|
*/
|
|
24
24
|
export const TESTED_VERSIONS = {
|
|
25
25
|
playwright: { range: ">=1.55 <2", tested: "1.61.1" },
|
|
26
|
-
"@axe-core/playwright": { range: ">=4.10 <5", tested: "4.12.1" },
|
|
27
|
-
"axe-core": { range: ">=4.10 <5", tested: "4.12.1" },
|
|
28
26
|
};
|
|
29
27
|
|
|
30
28
|
/** Shape one product finding from a rule id (pure — unit-tested without a browser). */
|
|
@@ -138,9 +136,7 @@ function collectInPage() {
|
|
|
138
136
|
// SPACING exception: undersized is allowed when a 24px-DIAMETER circle centred on the target
|
|
139
137
|
// does not intersect the circle of any other target. Two circles of radius 12 intersect when
|
|
140
138
|
// their centres are closer than 24px, so that is the whole test.
|
|
141
|
-
const crowded = rawTargets.some(
|
|
142
|
-
(o) => o !== t && Math.hypot(o.cx - t.cx, o.cy - t.cy) < 24,
|
|
143
|
-
);
|
|
139
|
+
const crowded = rawTargets.some((o) => o !== t && Math.hypot(o.cx - t.cx, o.cy - t.cy) < 24);
|
|
144
140
|
return { ...t, exempt: crowded ? null : "spacing" };
|
|
145
141
|
});
|
|
146
142
|
|
|
@@ -278,18 +274,13 @@ function collectInPage() {
|
|
|
278
274
|
/** Optional-peer loader — throws a tagged bootstrap error instead of a raw stack. */
|
|
279
275
|
async function loadDeps() {
|
|
280
276
|
try {
|
|
281
|
-
const
|
|
282
|
-
|
|
283
|
-
import("@axe-core/playwright"),
|
|
284
|
-
]);
|
|
285
|
-
return { chromium, AxeBuilder: axe.default ?? axe.AxeBuilder };
|
|
277
|
+
const { chromium } = await import("playwright");
|
|
278
|
+
return { chromium };
|
|
286
279
|
} catch (cause) {
|
|
287
|
-
const err = new Error(
|
|
288
|
-
"visual-audit needs the optional peers `playwright` and `@axe-core/playwright`",
|
|
289
|
-
);
|
|
280
|
+
const err = new Error("visual-audit needs the optional peer `playwright`");
|
|
290
281
|
err.bootstrap = true;
|
|
291
282
|
err.hint =
|
|
292
|
-
"pnpm add -D playwright
|
|
283
|
+
"pnpm add -D playwright && pnpm exec playwright install chromium " +
|
|
293
284
|
"(or set PLAYWRIGHT_CHROMIUM_EXECUTABLE to a system Chromium).";
|
|
294
285
|
err.cause = cause;
|
|
295
286
|
throw err;
|
|
@@ -301,7 +292,7 @@ async function loadDeps() {
|
|
|
301
292
|
* (page/context/browser) is guaranteed via finally on BOTH success and failure.
|
|
302
293
|
*/
|
|
303
294
|
/* c8 ignore start — the browser-driving glue; exercised by scripts/visual-audit-smoke.mjs in CI. */
|
|
304
|
-
async function audit(targets, { chromium
|
|
295
|
+
async function audit(targets, { chromium }) {
|
|
305
296
|
const findings = [];
|
|
306
297
|
const errors = [];
|
|
307
298
|
let browser;
|
|
@@ -331,18 +322,6 @@ async function audit(targets, { chromium, AxeBuilder }) {
|
|
|
331
322
|
}
|
|
332
323
|
|
|
333
324
|
try {
|
|
334
|
-
// 1) axe-core — real WCAG/ARIA engine.
|
|
335
|
-
const { violations } = await new AxeBuilder({ page }).analyze();
|
|
336
|
-
for (const v of violations) {
|
|
337
|
-
findings.push(
|
|
338
|
-
buildFinding(
|
|
339
|
-
"axe-violations",
|
|
340
|
-
url,
|
|
341
|
-
`${v.id} (${v.impact}) — ${v.help} [${v.nodes.length} node(s)] ${v.helpUrl}`,
|
|
342
|
-
),
|
|
343
|
-
);
|
|
344
|
-
}
|
|
345
|
-
|
|
346
325
|
// 2) computed-style / layout heuristics via the PURE rules.
|
|
347
326
|
const m = await page.evaluate(collectInPage);
|
|
348
327
|
for (const a of m.accents) {
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
|
|
3
|
-
export declare const ContextMenu: React.FC<ContextMenuPrimitive.ContextMenuProps>;
|
|
4
|
-
export declare function ContextMenuTrigger(props: React.ComponentProps<typeof ContextMenuPrimitive.Trigger>): React.JSX.Element;
|
|
5
|
-
export declare const ContextMenuPortal: React.FC<ContextMenuPrimitive.ContextMenuPortalProps>;
|
|
6
|
-
export declare const ContextMenuContent: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
-
export declare const ContextMenuItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
8
|
-
inset?: boolean;
|
|
9
|
-
variant?: "default" | "destructive";
|
|
10
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
-
export declare const ContextMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
12
|
-
export declare const ContextMenuRadioGroup: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
-
export declare const ContextMenuRadioItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
14
|
-
export declare const ContextMenuLabel: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
15
|
-
inset?: boolean;
|
|
16
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
17
|
-
export declare const ContextMenuSeparator: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
-
export declare const ContextMenuShortcut: ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => React.JSX.Element;
|
|
19
|
-
export declare const ContextMenuSub: React.FC<ContextMenuPrimitive.ContextMenuSubProps>;
|
|
20
|
-
export declare const ContextMenuSubTrigger: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
21
|
-
export declare const ContextMenuSubContent: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,149 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import * as React from "react";
|
|
4
|
-
import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
|
|
5
|
-
import { Check, ChevronRight, Circle } from "lucide-react";
|
|
6
|
-
import { cn } from "../../lib/utils.js";
|
|
7
|
-
import { useInertHiddenBackground } from "../general/inert-background.js";
|
|
8
|
-
const ContextMenu = ContextMenuPrimitive.Root;
|
|
9
|
-
function ContextMenuTrigger(props) {
|
|
10
|
-
return /* @__PURE__ */ jsx(ContextMenuPrimitive.Trigger, { "data-slot": "context-menu-trigger", ...props });
|
|
11
|
-
}
|
|
12
|
-
const ContextMenuPortal = ContextMenuPrimitive.Portal;
|
|
13
|
-
const ContextMenuContent = React.forwardRef(({ className, ...props }, ref) => {
|
|
14
|
-
const contentRef = useInertHiddenBackground(ref);
|
|
15
|
-
return /* @__PURE__ */ jsx(ContextMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx(
|
|
16
|
-
ContextMenuPrimitive.Content,
|
|
17
|
-
{
|
|
18
|
-
ref: contentRef,
|
|
19
|
-
"data-slot": "context-menu-content",
|
|
20
|
-
className: cn("ui-context-menu-content", className),
|
|
21
|
-
...props
|
|
22
|
-
}
|
|
23
|
-
) });
|
|
24
|
-
});
|
|
25
|
-
ContextMenuContent.displayName = ContextMenuPrimitive.Content.displayName;
|
|
26
|
-
const ContextMenuItem = React.forwardRef(({ className, inset, variant = "default", ...props }, ref) => /* @__PURE__ */ jsx(
|
|
27
|
-
ContextMenuPrimitive.Item,
|
|
28
|
-
{
|
|
29
|
-
ref,
|
|
30
|
-
"data-slot": "context-menu-item",
|
|
31
|
-
"data-inset": inset,
|
|
32
|
-
"data-variant": variant,
|
|
33
|
-
className: cn("ui-context-menu-item", className),
|
|
34
|
-
...props
|
|
35
|
-
}
|
|
36
|
-
));
|
|
37
|
-
ContextMenuItem.displayName = ContextMenuPrimitive.Item.displayName;
|
|
38
|
-
const ContextMenuCheckboxItem = React.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
39
|
-
ContextMenuPrimitive.CheckboxItem,
|
|
40
|
-
{
|
|
41
|
-
ref,
|
|
42
|
-
"data-slot": "context-menu-checkbox-item",
|
|
43
|
-
className: cn("ui-context-menu-checkbox-item", className),
|
|
44
|
-
checked,
|
|
45
|
-
...props,
|
|
46
|
-
children: [
|
|
47
|
-
/* @__PURE__ */ jsx("span", { className: "ui-context-menu-item-indicator", "aria-hidden": "true", children: /* @__PURE__ */ jsx(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Check, { className: "ui-context-menu-check" }) }) }),
|
|
48
|
-
children
|
|
49
|
-
]
|
|
50
|
-
}
|
|
51
|
-
));
|
|
52
|
-
ContextMenuCheckboxItem.displayName = ContextMenuPrimitive.CheckboxItem.displayName;
|
|
53
|
-
const ContextMenuRadioGroup = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
54
|
-
ContextMenuPrimitive.RadioGroup,
|
|
55
|
-
{
|
|
56
|
-
ref,
|
|
57
|
-
"data-slot": "context-menu-radio-group",
|
|
58
|
-
className: cn("ui-context-menu-radio-group", className),
|
|
59
|
-
...props
|
|
60
|
-
}
|
|
61
|
-
));
|
|
62
|
-
ContextMenuRadioGroup.displayName = ContextMenuPrimitive.RadioGroup.displayName;
|
|
63
|
-
const ContextMenuRadioItem = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
64
|
-
ContextMenuPrimitive.RadioItem,
|
|
65
|
-
{
|
|
66
|
-
ref,
|
|
67
|
-
"data-slot": "context-menu-radio-item",
|
|
68
|
-
className: cn("ui-context-menu-radio-item", className),
|
|
69
|
-
...props,
|
|
70
|
-
children: [
|
|
71
|
-
/* @__PURE__ */ jsx("span", { className: "ui-context-menu-item-indicator", "aria-hidden": "true", children: /* @__PURE__ */ jsx(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Circle, { className: "ui-context-menu-dot" }) }) }),
|
|
72
|
-
children
|
|
73
|
-
]
|
|
74
|
-
}
|
|
75
|
-
));
|
|
76
|
-
ContextMenuRadioItem.displayName = ContextMenuPrimitive.RadioItem.displayName;
|
|
77
|
-
const ContextMenuLabel = React.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
78
|
-
ContextMenuPrimitive.Label,
|
|
79
|
-
{
|
|
80
|
-
ref,
|
|
81
|
-
"data-slot": "context-menu-label",
|
|
82
|
-
"data-inset": inset,
|
|
83
|
-
className: cn("ui-context-menu-label", className),
|
|
84
|
-
...props
|
|
85
|
-
}
|
|
86
|
-
));
|
|
87
|
-
ContextMenuLabel.displayName = ContextMenuPrimitive.Label.displayName;
|
|
88
|
-
const ContextMenuSeparator = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
89
|
-
ContextMenuPrimitive.Separator,
|
|
90
|
-
{
|
|
91
|
-
ref,
|
|
92
|
-
"data-slot": "context-menu-separator",
|
|
93
|
-
className: cn("ui-context-menu-separator", className),
|
|
94
|
-
...props
|
|
95
|
-
}
|
|
96
|
-
));
|
|
97
|
-
ContextMenuSeparator.displayName = ContextMenuPrimitive.Separator.displayName;
|
|
98
|
-
const ContextMenuShortcut = ({
|
|
99
|
-
className,
|
|
100
|
-
...props
|
|
101
|
-
}) => /* @__PURE__ */ jsx(
|
|
102
|
-
"span",
|
|
103
|
-
{
|
|
104
|
-
"data-slot": "context-menu-shortcut",
|
|
105
|
-
className: cn("ui-context-menu-shortcut", className),
|
|
106
|
-
...props
|
|
107
|
-
}
|
|
108
|
-
);
|
|
109
|
-
const ContextMenuSub = ContextMenuPrimitive.Sub;
|
|
110
|
-
const ContextMenuSubTrigger = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
111
|
-
ContextMenuPrimitive.SubTrigger,
|
|
112
|
-
{
|
|
113
|
-
ref,
|
|
114
|
-
"data-slot": "context-menu-sub-trigger",
|
|
115
|
-
className: cn("ui-context-menu-sub-trigger", className),
|
|
116
|
-
...props,
|
|
117
|
-
children: [
|
|
118
|
-
children,
|
|
119
|
-
/* @__PURE__ */ jsx(ChevronRight, { className: "ui-context-menu-sub-trigger-icon", "aria-hidden": "true" })
|
|
120
|
-
]
|
|
121
|
-
}
|
|
122
|
-
));
|
|
123
|
-
ContextMenuSubTrigger.displayName = ContextMenuPrimitive.SubTrigger.displayName;
|
|
124
|
-
const ContextMenuSubContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
125
|
-
ContextMenuPrimitive.SubContent,
|
|
126
|
-
{
|
|
127
|
-
ref,
|
|
128
|
-
"data-slot": "context-menu-sub-content",
|
|
129
|
-
className: cn("ui-context-menu-sub-content", className),
|
|
130
|
-
...props
|
|
131
|
-
}
|
|
132
|
-
));
|
|
133
|
-
ContextMenuSubContent.displayName = ContextMenuPrimitive.SubContent.displayName;
|
|
134
|
-
export {
|
|
135
|
-
ContextMenu,
|
|
136
|
-
ContextMenuCheckboxItem,
|
|
137
|
-
ContextMenuContent,
|
|
138
|
-
ContextMenuItem,
|
|
139
|
-
ContextMenuLabel,
|
|
140
|
-
ContextMenuPortal,
|
|
141
|
-
ContextMenuRadioGroup,
|
|
142
|
-
ContextMenuRadioItem,
|
|
143
|
-
ContextMenuSeparator,
|
|
144
|
-
ContextMenuShortcut,
|
|
145
|
-
ContextMenuSub,
|
|
146
|
-
ContextMenuSubContent,
|
|
147
|
-
ContextMenuSubTrigger,
|
|
148
|
-
ContextMenuTrigger
|
|
149
|
-
};
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as MenubarPrimitive from "@radix-ui/react-menubar";
|
|
3
|
-
export declare const Menubar: React.ForwardRefExoticComponent<MenubarPrimitive.MenubarProps & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
-
/**
|
|
5
|
-
* Annotated rather than inferred, and that is load-bearing.
|
|
6
|
-
*
|
|
7
|
-
* Radix types this one through `createContextScope`, so its INFERRED type reaches into
|
|
8
|
-
* `@radix-ui/react-context` for a `Scope` — and TypeScript then refuses to emit a declaration it
|
|
9
|
-
* cannot name portably (TS2883) unless that package is a DIRECT dependency. It was one, purely to
|
|
10
|
-
* satisfy this line: nothing in the tree ever imported it. Naming the props here severs that,
|
|
11
|
-
* which is what let the dependency go.
|
|
12
|
-
*/
|
|
13
|
-
export declare const MenubarMenu: (props: React.ComponentProps<typeof MenubarPrimitive.Menu>) => React.ReactNode;
|
|
14
|
-
export declare function MenubarTrigger(props: React.ComponentProps<typeof MenubarPrimitive.Trigger>): React.JSX.Element;
|
|
15
|
-
export declare const MenubarContent: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
-
export declare const MenubarItem: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
17
|
-
inset?: boolean;
|
|
18
|
-
variant?: "default" | "destructive";
|
|
19
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
20
|
-
export declare const MenubarCheckboxItem: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
21
|
-
export declare const MenubarRadioGroup: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarRadioGroupProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
22
|
-
export declare const MenubarRadioItem: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
23
|
-
export declare const MenubarLabel: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
24
|
-
export declare const MenubarSeparator: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
25
|
-
export declare const MenubarShortcut: ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => React.JSX.Element;
|
|
26
|
-
export declare const MenubarSub: React.FC<MenubarPrimitive.MenubarSubProps>;
|
|
27
|
-
export declare const MenubarSubTrigger: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
28
|
-
export declare const MenubarSubContent: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import * as React from "react";
|
|
4
|
-
import * as MenubarPrimitive from "@radix-ui/react-menubar";
|
|
5
|
-
import { Check, ChevronRight, Circle } from "lucide-react";
|
|
6
|
-
import { cn } from "../../lib/utils.js";
|
|
7
|
-
const Menubar = MenubarPrimitive.Root;
|
|
8
|
-
const MenubarMenu = MenubarPrimitive.Menu;
|
|
9
|
-
function MenubarTrigger(props) {
|
|
10
|
-
return /* @__PURE__ */ jsx(MenubarPrimitive.Trigger, { "data-slot": "menubar-trigger", ...props });
|
|
11
|
-
}
|
|
12
|
-
const MenubarContent = React.forwardRef(({ className, align = "start", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsx(MenubarPrimitive.Portal, { children: /* @__PURE__ */ jsx(
|
|
13
|
-
MenubarPrimitive.Content,
|
|
14
|
-
{
|
|
15
|
-
ref,
|
|
16
|
-
"data-slot": "menubar-content",
|
|
17
|
-
align,
|
|
18
|
-
sideOffset,
|
|
19
|
-
className: cn("ui-menubar-content", className),
|
|
20
|
-
...props
|
|
21
|
-
}
|
|
22
|
-
) }));
|
|
23
|
-
MenubarContent.displayName = MenubarPrimitive.Content.displayName;
|
|
24
|
-
const MenubarItem = React.forwardRef(({ className, inset, variant = "default", ...props }, ref) => /* @__PURE__ */ jsx(
|
|
25
|
-
MenubarPrimitive.Item,
|
|
26
|
-
{
|
|
27
|
-
ref,
|
|
28
|
-
"data-slot": "menubar-item",
|
|
29
|
-
"data-inset": inset,
|
|
30
|
-
"data-variant": variant,
|
|
31
|
-
className: cn("ui-menubar-item", className),
|
|
32
|
-
...props
|
|
33
|
-
}
|
|
34
|
-
));
|
|
35
|
-
MenubarItem.displayName = MenubarPrimitive.Item.displayName;
|
|
36
|
-
const MenubarCheckboxItem = React.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
37
|
-
MenubarPrimitive.CheckboxItem,
|
|
38
|
-
{
|
|
39
|
-
ref,
|
|
40
|
-
"data-slot": "menubar-checkbox-item",
|
|
41
|
-
className: cn("ui-menubar-checkbox-item", className),
|
|
42
|
-
checked,
|
|
43
|
-
...props,
|
|
44
|
-
children: [
|
|
45
|
-
/* @__PURE__ */ jsx("span", { className: "ui-menubar-item-indicator", "aria-hidden": "true", children: /* @__PURE__ */ jsx(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Check, { className: "ui-menubar-check" }) }) }),
|
|
46
|
-
children
|
|
47
|
-
]
|
|
48
|
-
}
|
|
49
|
-
));
|
|
50
|
-
MenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;
|
|
51
|
-
const MenubarRadioGroup = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
52
|
-
MenubarPrimitive.RadioGroup,
|
|
53
|
-
{
|
|
54
|
-
ref,
|
|
55
|
-
"data-slot": "menubar-radio-group",
|
|
56
|
-
className: cn("ui-menubar-radio-group", className),
|
|
57
|
-
...props
|
|
58
|
-
}
|
|
59
|
-
));
|
|
60
|
-
MenubarRadioGroup.displayName = MenubarPrimitive.RadioGroup.displayName;
|
|
61
|
-
const MenubarRadioItem = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
62
|
-
MenubarPrimitive.RadioItem,
|
|
63
|
-
{
|
|
64
|
-
ref,
|
|
65
|
-
"data-slot": "menubar-radio-item",
|
|
66
|
-
className: cn("ui-menubar-radio-item", className),
|
|
67
|
-
...props,
|
|
68
|
-
children: [
|
|
69
|
-
/* @__PURE__ */ jsx("span", { className: "ui-menubar-item-indicator", "aria-hidden": "true", children: /* @__PURE__ */ jsx(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Circle, { className: "ui-menubar-dot" }) }) }),
|
|
70
|
-
children
|
|
71
|
-
]
|
|
72
|
-
}
|
|
73
|
-
));
|
|
74
|
-
MenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;
|
|
75
|
-
const MenubarLabel = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
76
|
-
MenubarPrimitive.Label,
|
|
77
|
-
{
|
|
78
|
-
ref,
|
|
79
|
-
"data-slot": "menubar-label",
|
|
80
|
-
className: cn("ui-menubar-label", className),
|
|
81
|
-
...props
|
|
82
|
-
}
|
|
83
|
-
));
|
|
84
|
-
MenubarLabel.displayName = MenubarPrimitive.Label.displayName;
|
|
85
|
-
const MenubarSeparator = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
86
|
-
MenubarPrimitive.Separator,
|
|
87
|
-
{
|
|
88
|
-
ref,
|
|
89
|
-
"data-slot": "menubar-separator",
|
|
90
|
-
className: cn("ui-menubar-separator", className),
|
|
91
|
-
...props
|
|
92
|
-
}
|
|
93
|
-
));
|
|
94
|
-
MenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;
|
|
95
|
-
const MenubarShortcut = ({ className, ...props }) => /* @__PURE__ */ jsx("span", { "data-slot": "menubar-shortcut", className: cn("ui-menubar-shortcut", className), ...props });
|
|
96
|
-
const MenubarSub = MenubarPrimitive.Sub;
|
|
97
|
-
const MenubarSubTrigger = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
98
|
-
MenubarPrimitive.SubTrigger,
|
|
99
|
-
{
|
|
100
|
-
ref,
|
|
101
|
-
"data-slot": "menubar-sub-trigger",
|
|
102
|
-
className: cn("ui-menubar-sub-trigger", className),
|
|
103
|
-
...props,
|
|
104
|
-
children: [
|
|
105
|
-
children,
|
|
106
|
-
/* @__PURE__ */ jsx(ChevronRight, { className: "ui-menubar-sub-trigger-icon", "aria-hidden": "true" })
|
|
107
|
-
]
|
|
108
|
-
}
|
|
109
|
-
));
|
|
110
|
-
MenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;
|
|
111
|
-
const MenubarSubContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
112
|
-
MenubarPrimitive.SubContent,
|
|
113
|
-
{
|
|
114
|
-
ref,
|
|
115
|
-
"data-slot": "menubar-sub-content",
|
|
116
|
-
className: cn("ui-menubar-sub-content", className),
|
|
117
|
-
...props
|
|
118
|
-
}
|
|
119
|
-
));
|
|
120
|
-
MenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;
|
|
121
|
-
export {
|
|
122
|
-
Menubar,
|
|
123
|
-
MenubarCheckboxItem,
|
|
124
|
-
MenubarContent,
|
|
125
|
-
MenubarItem,
|
|
126
|
-
MenubarLabel,
|
|
127
|
-
MenubarMenu,
|
|
128
|
-
MenubarRadioGroup,
|
|
129
|
-
MenubarRadioItem,
|
|
130
|
-
MenubarSeparator,
|
|
131
|
-
MenubarShortcut,
|
|
132
|
-
MenubarSub,
|
|
133
|
-
MenubarSubContent,
|
|
134
|
-
MenubarSubTrigger,
|
|
135
|
-
MenubarTrigger
|
|
136
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
|
|
3
|
-
export declare const NavigationMenu: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuProps & React.RefAttributes<HTMLElement>>;
|
|
4
|
-
export declare const NavigationMenuList: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuListProps & React.RefAttributes<HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
|
|
5
|
-
export declare const NavigationMenuItem: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuItemProps & React.RefAttributes<HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
6
|
-
export declare const NavigationMenuTrigger: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
7
|
-
export declare const NavigationMenuContent: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
-
export declare const NavigationMenuLink: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuLinkProps & React.RefAttributes<HTMLAnchorElement>, "ref"> & React.RefAttributes<HTMLAnchorElement>>;
|
|
9
|
-
export declare const NavigationMenuIndicator: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuIndicatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
-
export declare const NavigationMenuViewport: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuViewportProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import * as React from "react";
|
|
4
|
-
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
|
|
5
|
-
import { ChevronDown } from "lucide-react";
|
|
6
|
-
import { cn } from "../../lib/utils.js";
|
|
7
|
-
const NavigationMenu = NavigationMenuPrimitive.Root;
|
|
8
|
-
const NavigationMenuList = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
9
|
-
NavigationMenuPrimitive.List,
|
|
10
|
-
{
|
|
11
|
-
ref,
|
|
12
|
-
"data-slot": "navigation-menu-list",
|
|
13
|
-
className: cn("ui-navigation-menu-list", className),
|
|
14
|
-
...props
|
|
15
|
-
}
|
|
16
|
-
));
|
|
17
|
-
NavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;
|
|
18
|
-
const NavigationMenuItem = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
19
|
-
NavigationMenuPrimitive.Item,
|
|
20
|
-
{
|
|
21
|
-
ref,
|
|
22
|
-
"data-slot": "navigation-menu-item",
|
|
23
|
-
className: cn("ui-navigation-menu-item", className),
|
|
24
|
-
...props
|
|
25
|
-
}
|
|
26
|
-
));
|
|
27
|
-
NavigationMenuItem.displayName = NavigationMenuPrimitive.Item.displayName;
|
|
28
|
-
const NavigationMenuTrigger = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
29
|
-
NavigationMenuPrimitive.Trigger,
|
|
30
|
-
{
|
|
31
|
-
ref,
|
|
32
|
-
"data-slot": "navigation-menu-trigger",
|
|
33
|
-
className: cn("ui-navigation-menu-trigger", className),
|
|
34
|
-
...props,
|
|
35
|
-
children: [
|
|
36
|
-
children,
|
|
37
|
-
/* @__PURE__ */ jsx(ChevronDown, { className: "ui-navigation-menu-trigger-icon", "aria-hidden": "true" })
|
|
38
|
-
]
|
|
39
|
-
}
|
|
40
|
-
));
|
|
41
|
-
NavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;
|
|
42
|
-
const NavigationMenuContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
43
|
-
NavigationMenuPrimitive.Content,
|
|
44
|
-
{
|
|
45
|
-
ref,
|
|
46
|
-
"data-slot": "navigation-menu-content",
|
|
47
|
-
className: cn("ui-navigation-menu-content", className),
|
|
48
|
-
...props
|
|
49
|
-
}
|
|
50
|
-
));
|
|
51
|
-
NavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;
|
|
52
|
-
const NavigationMenuLink = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
53
|
-
NavigationMenuPrimitive.Link,
|
|
54
|
-
{
|
|
55
|
-
ref,
|
|
56
|
-
"data-slot": "navigation-menu-link",
|
|
57
|
-
className: cn("ui-navigation-menu-link", className),
|
|
58
|
-
...props
|
|
59
|
-
}
|
|
60
|
-
));
|
|
61
|
-
NavigationMenuLink.displayName = NavigationMenuPrimitive.Link.displayName;
|
|
62
|
-
const NavigationMenuIndicator = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
63
|
-
NavigationMenuPrimitive.Indicator,
|
|
64
|
-
{
|
|
65
|
-
ref,
|
|
66
|
-
"data-slot": "navigation-menu-indicator",
|
|
67
|
-
className: cn("ui-navigation-menu-indicator", className),
|
|
68
|
-
...props
|
|
69
|
-
}
|
|
70
|
-
));
|
|
71
|
-
NavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;
|
|
72
|
-
const NavigationMenuViewport = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
73
|
-
NavigationMenuPrimitive.Viewport,
|
|
74
|
-
{
|
|
75
|
-
ref,
|
|
76
|
-
"data-slot": "navigation-menu-viewport",
|
|
77
|
-
className: cn("ui-navigation-menu-viewport", className),
|
|
78
|
-
...props
|
|
79
|
-
}
|
|
80
|
-
));
|
|
81
|
-
NavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;
|
|
82
|
-
export {
|
|
83
|
-
NavigationMenu,
|
|
84
|
-
NavigationMenuContent,
|
|
85
|
-
NavigationMenuIndicator,
|
|
86
|
-
NavigationMenuItem,
|
|
87
|
-
NavigationMenuLink,
|
|
88
|
-
NavigationMenuList,
|
|
89
|
-
NavigationMenuTrigger,
|
|
90
|
-
NavigationMenuViewport
|
|
91
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "../navigation/context-menu.js";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "../navigation/menubar.js";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "../navigation/navigation-menu.js";
|