mtxuilib 0.0.308 → 0.0.310
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/App.cjs +17 -1
- package/dist/MtmButton.cjs +2 -1
- package/dist/NovelEditorLoader.cjs +8 -4
- package/dist/browser/index.min.js +2 -1
- package/dist/common/FullCenter.cjs +2 -1
- package/dist/common/MtImage.cjs +2 -1
- package/dist/common/mtlink.cjs +2 -1
- package/dist/common/table/cells/ExpenderCell.cjs +9 -4
- package/dist/common/table/cells/SelectCell.cjs +8 -4
- package/dist/common/table/cells/Text.cjs +2 -1
- package/dist/common/table/cells/ViewLink.cjs +8 -4
- package/dist/common/table/cells/container/cellWrapper.cjs +2 -1
- package/dist/common/table/cells/number.cjs +2 -1
- package/dist/common/table/cells/string.cjs +2 -1
- package/dist/common/table/data-table-pagination.cjs +89 -51
- package/dist/common/table/data-table-view-options.cjs +32 -22
- package/dist/common/tailwind-indicator.cjs +9 -1
- package/dist/entry-client.cjs +2 -1
- package/dist/entry-server.cjs +2 -1
- package/dist/esm/App.js +17 -1
- package/dist/esm/MtmButton.js +2 -1
- package/dist/esm/NovelEditorLoader.js +8 -4
- package/dist/esm/common/FullCenter.js +2 -1
- package/dist/esm/common/MtImage.js +2 -1
- package/dist/esm/common/mtlink.js +2 -1
- package/dist/esm/common/table/cells/ExpenderCell.js +9 -4
- package/dist/esm/common/table/cells/SelectCell.js +8 -4
- package/dist/esm/common/table/cells/Text.js +2 -1
- package/dist/esm/common/table/cells/ViewLink.js +8 -4
- package/dist/esm/common/table/cells/container/cellWrapper.js +2 -1
- package/dist/esm/common/table/cells/number.js +2 -1
- package/dist/esm/common/table/cells/string.js +2 -1
- package/dist/esm/common/table/data-table-pagination.js +89 -51
- package/dist/esm/common/table/data-table-view-options.js +32 -22
- package/dist/esm/common/tailwind-indicator.js +9 -1
- package/dist/esm/entry-client.js +2 -1
- package/dist/esm/entry-server.js +2 -1
- package/dist/esm/icons/icons.js +41 -31
- package/dist/esm/index.js +2 -1
- package/dist/esm/lib/connectquery/use-transport.js +2 -1
- package/dist/esm/lib/render copy.js +2 -1
- package/dist/esm/lib/render.js +2 -1
- package/dist/esm/store/MtConnectProvider.js +2 -1
- package/dist/esm/store/ReactQueryProvider.js +18 -10
- package/dist/esm/store/StorybookDecorator.js +5 -4
- package/dist/esm/store/appContext.js +28 -18
- package/dist/esm/store/hydrateCore.js +6 -5
- package/dist/esm/store/logger.context.js +3 -2
- package/dist/esm/store/pageMeta.js +5 -1
- package/dist/esm/tailwind.d.cts +88 -1
- package/dist/esm/ui/accordion.js +19 -11
- package/dist/esm/ui/alert copy.js +4 -3
- package/dist/esm/ui/alert-dialog.js +21 -17
- package/dist/esm/ui/alert.js +4 -3
- package/dist/esm/ui/avatar.js +4 -3
- package/dist/esm/ui/badge.js +2 -2
- package/dist/esm/ui/button.js +2 -1
- package/dist/esm/ui/calendar.js +4 -4
- package/dist/esm/ui/card.js +7 -6
- package/dist/esm/ui/checkbox.js +15 -10
- package/dist/esm/ui/command.js +25 -18
- package/dist/esm/ui/context-menu.js +35 -22
- package/dist/esm/ui/dialog.js +30 -17
- package/dist/esm/ui/drawer.js +28 -18
- package/dist/esm/ui/dropdown-menu.js +35 -22
- package/dist/esm/ui/form copy.js +14 -9
- package/dist/esm/ui/form.js +14 -9
- package/dist/esm/ui/hover-card.js +2 -1
- package/dist/esm/ui/input.js +2 -1
- package/dist/esm/ui/label.js +2 -1
- package/dist/esm/ui/menubar.js +37 -24
- package/dist/esm/ui/navigation-menu.js +36 -25
- package/dist/esm/ui/novel/novel/src/components/editor-bubble-item.js +2 -1
- package/dist/esm/ui/novel/novel/src/components/editor-bubble.js +5 -1
- package/dist/esm/ui/novel/novel/src/components/editor-command-item.js +5 -4
- package/dist/esm/ui/novel/novel/src/components/editor-command.js +21 -14
- package/dist/esm/ui/novel/novel/src/components/editor.js +7 -6
- package/dist/esm/ui/novel/novel/src/extensions/image-resizer.js +2 -1
- package/dist/esm/ui/novel/tailwind/advanced-editor.js +58 -35
- package/dist/esm/ui/novel/tailwind/generative/ai-completion-command.js +45 -30
- package/dist/esm/ui/novel/tailwind/generative/ai-selector-commands.js +37 -28
- package/dist/esm/ui/novel/tailwind/generative/ai-selector.js +58 -43
- package/dist/esm/ui/novel/tailwind/generative/generative-menu-switch.js +23 -15
- package/dist/esm/ui/novel/tailwind/selectors/color-selector.js +78 -55
- package/dist/esm/ui/novel/tailwind/selectors/link-selector.js +58 -50
- package/dist/esm/ui/novel/tailwind/selectors/node-selector.js +31 -19
- package/dist/esm/ui/novel/tailwind/selectors/text-buttons.js +13 -12
- package/dist/esm/ui/novel/tailwind/slash-command.js +12 -11
- package/dist/esm/ui/novel/tailwind/ui/button.js +2 -1
- package/dist/esm/ui/novel/tailwind/ui/command.js +25 -18
- package/dist/esm/ui/novel/tailwind/ui/dialog.js +30 -17
- package/dist/esm/ui/novel/tailwind/ui/icons/crazy-spinner.js +6 -1
- package/dist/esm/ui/novel/tailwind/ui/icons/font-default.js +20 -17
- package/dist/esm/ui/novel/tailwind/ui/icons/font-mono.js +20 -17
- package/dist/esm/ui/novel/tailwind/ui/icons/font-serif.js +20 -17
- package/dist/esm/ui/novel/tailwind/ui/icons/github.js +5 -4
- package/dist/esm/ui/novel/tailwind/ui/icons/loading-circle.js +20 -17
- package/dist/esm/ui/novel/tailwind/ui/icons/magic.js +27 -24
- package/dist/esm/ui/novel/tailwind/ui/menu.js +28 -16
- package/dist/esm/ui/novel/tailwind/ui/popover.js +3 -2
- package/dist/esm/ui/novel/tailwind/ui/scroll-area.js +18 -10
- package/dist/esm/ui/novel/tailwind/ui/separator.js +2 -1
- package/dist/esm/ui/pagination.js +32 -19
- package/dist/esm/ui/popover.js +3 -2
- package/dist/esm/ui/progress.js +15 -10
- package/dist/esm/ui/radio-group.js +7 -5
- package/dist/esm/ui/resizable.js +10 -5
- package/dist/esm/ui/scroll-area.js +26 -18
- package/dist/esm/ui/select.js +37 -26
- package/dist/esm/ui/separator.js +2 -1
- package/dist/esm/ui/sheet.js +24 -14
- package/dist/esm/ui/skeleton.js +2 -1
- package/dist/esm/ui/slider.js +12 -5
- package/dist/esm/ui/sonner.js +2 -1
- package/dist/esm/ui/switch.js +12 -11
- package/dist/esm/ui/table.js +10 -9
- package/dist/esm/ui/tabs.js +4 -3
- package/dist/esm/ui/textarea.js +2 -1
- package/dist/esm/ui/toast.js +14 -9
- package/dist/esm/ui/toaster.js +18 -4
- package/dist/esm/ui/toggle.js +2 -1
- package/dist/esm/ui/tooltip.js +2 -1
- package/dist/esm/ui/ui-mt/NavTag.js +5 -4
- package/dist/esm/ui/ui-mt/SimpleModel.js +12 -11
- package/dist/esm/ui/ui-mt/inputField/InputField.js +27 -20
- package/dist/esm/ui/ui-mt/inputField/SingleUploadForm.js +67 -56
- package/dist/esm/ui/ui-mt/inputField/TextArea.js +20 -16
- package/dist/esm/ui/ui-mt/inputField/TextFileInput.js +18 -15
- package/dist/esm/ui/ui-mt/inputField/select/InputSelect.js +35 -27
- package/dist/esm/ui/ui-mt/inputs/SearchInput.js +2 -1
- package/dist/esm/ui/ui-mt/inputs/searchBar.js +12 -8
- package/dist/esm/ui/ui-mt/skeleton/skeleton-card.js +9 -4
- package/dist/esm/ui/ui-mt/skeleton/skeleton2.js +5 -1
- package/dist/esm/ui/ui-mt/skeleton/skeletons.js +9 -1
- package/dist/esm/ui/ui-vamp/alert.js +30 -24
- package/dist/esm/ui/ui-vamp/avatar.js +12 -7
- package/dist/esm/ui/ui-vamp/button.js +2 -1
- package/dist/esm/ui/ui-vamp/card.js +15 -8
- package/dist/esm/ui/ui-vamp/checkbox.js +15 -8
- package/dist/esm/ui/ui-vamp/chip.js +2 -1
- package/dist/esm/ui/ui-vamp/dropdown.js +7 -6
- package/dist/esm/ui/ui-vamp/external-link.js +9 -4
- package/dist/esm/ui/ui-vamp/headline.js +5 -1
- package/dist/esm/ui/ui-vamp/input.js +3 -2
- package/dist/esm/ui/ui-vamp/keyvalue.js +5 -1
- package/dist/esm/ui/ui-vamp/label.js +2 -1
- package/dist/esm/ui/ui-vamp/mobile-nav-button.js +6 -5
- package/dist/esm/ui/ui-vamp/modal.js +17 -13
- package/dist/esm/ui/ui-vamp/pagination.js +57 -35
- package/dist/esm/ui/ui-vamp/scroll-area.js +5 -4
- package/dist/esm/ui/ui-vamp/skeleton.js +2 -2
- package/dist/esm/ui/ui-vamp/stripe-not-connected-modal.js +13 -2
- package/dist/esm/ui/ui-vamp/textarea.js +12 -8
- package/dist/esm/ui/ui-vamp/toggle-group.js +3 -2
- package/dist/icons/icons.cjs +41 -31
- package/dist/index.cjs +2 -1
- package/dist/lib/connectquery/use-transport.cjs +2 -1
- package/dist/lib/render copy.cjs +2 -1
- package/dist/lib/render.cjs +2 -1
- package/dist/store/MtConnectProvider.cjs +2 -1
- package/dist/store/ReactQueryProvider.cjs +18 -10
- package/dist/store/StorybookDecorator.cjs +5 -4
- package/dist/store/appContext.cjs +28 -28
- package/dist/store/hydrateCore.cjs +6 -5
- package/dist/store/logger.context.cjs +3 -2
- package/dist/store/pageMeta.cjs +5 -1
- package/dist/tailwind.cjs +72 -2
- package/dist/tsconfig.type.tsbuildinfo +1 -1
- package/dist/ui/accordion.cjs +19 -11
- package/dist/ui/alert copy.cjs +4 -3
- package/dist/ui/alert-dialog.cjs +21 -17
- package/dist/ui/alert.cjs +4 -3
- package/dist/ui/avatar.cjs +4 -3
- package/dist/ui/badge.cjs +2 -12
- package/dist/ui/button.cjs +2 -1
- package/dist/ui/calendar.cjs +4 -14
- package/dist/ui/card.cjs +7 -6
- package/dist/ui/checkbox.cjs +15 -10
- package/dist/ui/command.cjs +25 -18
- package/dist/ui/context-menu.cjs +35 -22
- package/dist/ui/dialog.cjs +30 -17
- package/dist/ui/drawer.cjs +28 -18
- package/dist/ui/dropdown-menu.cjs +35 -22
- package/dist/ui/form copy.cjs +14 -9
- package/dist/ui/form.cjs +14 -9
- package/dist/ui/hover-card.cjs +2 -1
- package/dist/ui/input.cjs +2 -1
- package/dist/ui/label.cjs +2 -1
- package/dist/ui/menubar.cjs +37 -24
- package/dist/ui/navigation-menu.cjs +36 -25
- package/dist/ui/novel/novel/src/components/editor-bubble-item.cjs +2 -1
- package/dist/ui/novel/novel/src/components/editor-bubble.cjs +5 -1
- package/dist/ui/novel/novel/src/components/editor-command-item.cjs +5 -4
- package/dist/ui/novel/novel/src/components/editor-command.cjs +21 -14
- package/dist/ui/novel/novel/src/components/editor.cjs +7 -6
- package/dist/ui/novel/novel/src/extensions/image-resizer.cjs +2 -1
- package/dist/ui/novel/tailwind/advanced-editor.cjs +58 -35
- package/dist/ui/novel/tailwind/generative/ai-completion-command.cjs +45 -30
- package/dist/ui/novel/tailwind/generative/ai-selector-commands.cjs +37 -28
- package/dist/ui/novel/tailwind/generative/ai-selector.cjs +58 -43
- package/dist/ui/novel/tailwind/generative/generative-menu-switch.cjs +23 -15
- package/dist/ui/novel/tailwind/selectors/color-selector.cjs +78 -55
- package/dist/ui/novel/tailwind/selectors/link-selector.cjs +58 -50
- package/dist/ui/novel/tailwind/selectors/node-selector.cjs +31 -19
- package/dist/ui/novel/tailwind/selectors/text-buttons.cjs +13 -12
- package/dist/ui/novel/tailwind/slash-command.cjs +12 -11
- package/dist/ui/novel/tailwind/ui/button.cjs +2 -1
- package/dist/ui/novel/tailwind/ui/command.cjs +25 -18
- package/dist/ui/novel/tailwind/ui/dialog.cjs +30 -17
- package/dist/ui/novel/tailwind/ui/icons/crazy-spinner.cjs +6 -1
- package/dist/ui/novel/tailwind/ui/icons/font-default.cjs +20 -17
- package/dist/ui/novel/tailwind/ui/icons/font-mono.cjs +20 -17
- package/dist/ui/novel/tailwind/ui/icons/font-serif.cjs +20 -17
- package/dist/ui/novel/tailwind/ui/icons/github.cjs +5 -4
- package/dist/ui/novel/tailwind/ui/icons/loading-circle.cjs +20 -17
- package/dist/ui/novel/tailwind/ui/icons/magic.cjs +27 -24
- package/dist/ui/novel/tailwind/ui/menu.cjs +28 -16
- package/dist/ui/novel/tailwind/ui/popover.cjs +3 -2
- package/dist/ui/novel/tailwind/ui/scroll-area.cjs +18 -10
- package/dist/ui/novel/tailwind/ui/separator.cjs +2 -1
- package/dist/ui/pagination.cjs +32 -19
- package/dist/ui/popover.cjs +3 -2
- package/dist/ui/progress.cjs +15 -10
- package/dist/ui/radio-group.cjs +7 -5
- package/dist/ui/resizable.cjs +10 -5
- package/dist/ui/scroll-area.cjs +26 -18
- package/dist/ui/select.cjs +37 -26
- package/dist/ui/separator.cjs +2 -1
- package/dist/ui/sheet.cjs +24 -14
- package/dist/ui/skeleton.cjs +2 -1
- package/dist/ui/slider.cjs +12 -5
- package/dist/ui/sonner.cjs +2 -1
- package/dist/ui/switch.cjs +12 -11
- package/dist/ui/table.cjs +10 -9
- package/dist/ui/tabs.cjs +4 -3
- package/dist/ui/textarea.cjs +2 -1
- package/dist/ui/toast.cjs +14 -9
- package/dist/ui/toaster.cjs +18 -4
- package/dist/ui/toggle.cjs +2 -1
- package/dist/ui/tooltip.cjs +2 -1
- package/dist/ui/ui-mt/NavTag.cjs +5 -4
- package/dist/ui/ui-mt/SimpleModel.cjs +12 -11
- package/dist/ui/ui-mt/inputField/InputField.cjs +27 -20
- package/dist/ui/ui-mt/inputField/SingleUploadForm.cjs +67 -56
- package/dist/ui/ui-mt/inputField/TextArea.cjs +20 -16
- package/dist/ui/ui-mt/inputField/TextFileInput.cjs +18 -25
- package/dist/ui/ui-mt/inputField/select/InputSelect.cjs +35 -27
- package/dist/ui/ui-mt/inputs/SearchInput.cjs +2 -1
- package/dist/ui/ui-mt/inputs/searchBar.cjs +12 -8
- package/dist/ui/ui-mt/skeleton/skeleton-card.cjs +9 -4
- package/dist/ui/ui-mt/skeleton/skeleton2.cjs +5 -1
- package/dist/ui/ui-mt/skeleton/skeletons.cjs +9 -1
- package/dist/ui/ui-vamp/alert.cjs +30 -24
- package/dist/ui/ui-vamp/avatar.cjs +12 -7
- package/dist/ui/ui-vamp/button.cjs +2 -1
- package/dist/ui/ui-vamp/card.cjs +15 -18
- package/dist/ui/ui-vamp/checkbox.cjs +15 -8
- package/dist/ui/ui-vamp/chip.cjs +2 -1
- package/dist/ui/ui-vamp/dropdown.cjs +7 -6
- package/dist/ui/ui-vamp/external-link.cjs +9 -4
- package/dist/ui/ui-vamp/headline.cjs +5 -1
- package/dist/ui/ui-vamp/input.cjs +3 -2
- package/dist/ui/ui-vamp/keyvalue.cjs +5 -1
- package/dist/ui/ui-vamp/label.cjs +2 -1
- package/dist/ui/ui-vamp/mobile-nav-button.cjs +6 -5
- package/dist/ui/ui-vamp/modal.cjs +17 -13
- package/dist/ui/ui-vamp/pagination.cjs +57 -35
- package/dist/ui/ui-vamp/scroll-area.cjs +5 -4
- package/dist/ui/ui-vamp/skeleton.cjs +2 -12
- package/dist/ui/ui-vamp/stripe-not-connected-modal.cjs +13 -2
- package/dist/ui/ui-vamp/textarea.cjs +12 -8
- package/dist/ui/ui-vamp/toggle-group.cjs +3 -2
- package/package.json +5 -4
package/dist/ui/context-menu.cjs
CHANGED
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
var __create = Object.create;
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
|
+
var __defProps = Object.defineProperties;
|
|
5
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
6
8
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
9
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
8
10
|
var __getProtoOf = Object.getPrototypeOf;
|
|
@@ -20,6 +22,7 @@ var __spreadValues = (a, b) => {
|
|
|
20
22
|
}
|
|
21
23
|
return a;
|
|
22
24
|
};
|
|
25
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
26
|
var __objRest = (source, exclude) => {
|
|
24
27
|
var target = {};
|
|
25
28
|
for (var prop in source)
|
|
@@ -72,6 +75,7 @@ __export(context_menu_exports, {
|
|
|
72
75
|
ContextMenuTrigger: () => ContextMenuTrigger
|
|
73
76
|
});
|
|
74
77
|
module.exports = __toCommonJS(context_menu_exports);
|
|
78
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
75
79
|
var ContextMenuPrimitive = __toESM(require("@radix-ui/react-context-menu"), 1);
|
|
76
80
|
var import_react_icons = require("@radix-ui/react-icons");
|
|
77
81
|
var React = __toESM(require("react"), 1);
|
|
@@ -84,24 +88,27 @@ const ContextMenuSub = ContextMenuPrimitive.Sub;
|
|
|
84
88
|
const ContextMenuRadioGroup = ContextMenuPrimitive.RadioGroup;
|
|
85
89
|
const ContextMenuSubTrigger = React.forwardRef((_a, ref) => {
|
|
86
90
|
var _b = _a, { className, inset, children } = _b, props = __objRest(_b, ["className", "inset", "children"]);
|
|
87
|
-
return /* @__PURE__ */
|
|
91
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
88
92
|
ContextMenuPrimitive.SubTrigger,
|
|
89
|
-
__spreadValues({
|
|
93
|
+
__spreadProps(__spreadValues({
|
|
90
94
|
ref,
|
|
91
95
|
className: (0, import_utils.cn)(
|
|
92
96
|
"focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none",
|
|
93
97
|
inset && "pl-8",
|
|
94
98
|
className
|
|
95
99
|
)
|
|
96
|
-
}, props),
|
|
97
|
-
|
|
98
|
-
|
|
100
|
+
}, props), {
|
|
101
|
+
children: [
|
|
102
|
+
children,
|
|
103
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.ChevronRightIcon, { className: "ml-auto size-4" })
|
|
104
|
+
]
|
|
105
|
+
})
|
|
99
106
|
);
|
|
100
107
|
});
|
|
101
108
|
ContextMenuSubTrigger.displayName = ContextMenuPrimitive.SubTrigger.displayName;
|
|
102
109
|
const ContextMenuSubContent = React.forwardRef((_c, ref) => {
|
|
103
110
|
var _d = _c, { className } = _d, props = __objRest(_d, ["className"]);
|
|
104
|
-
return /* @__PURE__ */
|
|
111
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
105
112
|
ContextMenuPrimitive.SubContent,
|
|
106
113
|
__spreadValues({
|
|
107
114
|
ref,
|
|
@@ -115,7 +122,7 @@ const ContextMenuSubContent = React.forwardRef((_c, ref) => {
|
|
|
115
122
|
ContextMenuSubContent.displayName = ContextMenuPrimitive.SubContent.displayName;
|
|
116
123
|
const ContextMenuContent = React.forwardRef((_e, ref) => {
|
|
117
124
|
var _f = _e, { className } = _f, props = __objRest(_f, ["className"]);
|
|
118
|
-
return /* @__PURE__ */
|
|
125
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ContextMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
119
126
|
ContextMenuPrimitive.Content,
|
|
120
127
|
__spreadValues({
|
|
121
128
|
ref,
|
|
@@ -124,12 +131,12 @@ const ContextMenuContent = React.forwardRef((_e, ref) => {
|
|
|
124
131
|
className
|
|
125
132
|
)
|
|
126
133
|
}, props)
|
|
127
|
-
));
|
|
134
|
+
) });
|
|
128
135
|
});
|
|
129
136
|
ContextMenuContent.displayName = ContextMenuPrimitive.Content.displayName;
|
|
130
137
|
const ContextMenuItem = React.forwardRef((_g, ref) => {
|
|
131
138
|
var _h = _g, { className, inset } = _h, props = __objRest(_h, ["className", "inset"]);
|
|
132
|
-
return /* @__PURE__ */
|
|
139
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
133
140
|
ContextMenuPrimitive.Item,
|
|
134
141
|
__spreadValues({
|
|
135
142
|
ref,
|
|
@@ -144,40 +151,46 @@ const ContextMenuItem = React.forwardRef((_g, ref) => {
|
|
|
144
151
|
ContextMenuItem.displayName = ContextMenuPrimitive.Item.displayName;
|
|
145
152
|
const ContextMenuCheckboxItem = React.forwardRef((_i, ref) => {
|
|
146
153
|
var _j = _i, { className, children, checked } = _j, props = __objRest(_j, ["className", "children", "checked"]);
|
|
147
|
-
return /* @__PURE__ */
|
|
154
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
148
155
|
ContextMenuPrimitive.CheckboxItem,
|
|
149
|
-
__spreadValues({
|
|
156
|
+
__spreadProps(__spreadValues({
|
|
150
157
|
ref,
|
|
151
158
|
className: (0, import_utils.cn)(
|
|
152
159
|
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
153
160
|
className
|
|
154
161
|
),
|
|
155
162
|
checked
|
|
156
|
-
}, props),
|
|
157
|
-
|
|
158
|
-
|
|
163
|
+
}, props), {
|
|
164
|
+
children: [
|
|
165
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.CheckIcon, { className: "size-4" }) }) }),
|
|
166
|
+
children
|
|
167
|
+
]
|
|
168
|
+
})
|
|
159
169
|
);
|
|
160
170
|
});
|
|
161
171
|
ContextMenuCheckboxItem.displayName = ContextMenuPrimitive.CheckboxItem.displayName;
|
|
162
172
|
const ContextMenuRadioItem = React.forwardRef((_k, ref) => {
|
|
163
173
|
var _l = _k, { className, children } = _l, props = __objRest(_l, ["className", "children"]);
|
|
164
|
-
return /* @__PURE__ */
|
|
174
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
165
175
|
ContextMenuPrimitive.RadioItem,
|
|
166
|
-
__spreadValues({
|
|
176
|
+
__spreadProps(__spreadValues({
|
|
167
177
|
ref,
|
|
168
178
|
className: (0, import_utils.cn)(
|
|
169
179
|
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
170
180
|
className
|
|
171
181
|
)
|
|
172
|
-
}, props),
|
|
173
|
-
|
|
174
|
-
|
|
182
|
+
}, props), {
|
|
183
|
+
children: [
|
|
184
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.DotFilledIcon, { className: "size-4 fill-current" }) }) }),
|
|
185
|
+
children
|
|
186
|
+
]
|
|
187
|
+
})
|
|
175
188
|
);
|
|
176
189
|
});
|
|
177
190
|
ContextMenuRadioItem.displayName = ContextMenuPrimitive.RadioItem.displayName;
|
|
178
191
|
const ContextMenuLabel = React.forwardRef((_m, ref) => {
|
|
179
192
|
var _n = _m, { className, inset } = _n, props = __objRest(_n, ["className", "inset"]);
|
|
180
|
-
return /* @__PURE__ */
|
|
193
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
181
194
|
ContextMenuPrimitive.Label,
|
|
182
195
|
__spreadValues({
|
|
183
196
|
ref,
|
|
@@ -192,7 +205,7 @@ const ContextMenuLabel = React.forwardRef((_m, ref) => {
|
|
|
192
205
|
ContextMenuLabel.displayName = ContextMenuPrimitive.Label.displayName;
|
|
193
206
|
const ContextMenuSeparator = React.forwardRef((_o, ref) => {
|
|
194
207
|
var _p = _o, { className } = _p, props = __objRest(_p, ["className"]);
|
|
195
|
-
return /* @__PURE__ */
|
|
208
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
196
209
|
ContextMenuPrimitive.Separator,
|
|
197
210
|
__spreadValues({
|
|
198
211
|
ref,
|
|
@@ -207,7 +220,7 @@ const ContextMenuShortcut = (_q) => {
|
|
|
207
220
|
} = _r, props = __objRest(_r, [
|
|
208
221
|
"className"
|
|
209
222
|
]);
|
|
210
|
-
return /* @__PURE__ */
|
|
223
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
211
224
|
"span",
|
|
212
225
|
__spreadValues({
|
|
213
226
|
className: (0, import_utils.cn)(
|
package/dist/ui/dialog.cjs
CHANGED
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
var __create = Object.create;
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
|
+
var __defProps = Object.defineProperties;
|
|
5
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
6
8
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
9
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
8
10
|
var __getProtoOf = Object.getPrototypeOf;
|
|
@@ -20,6 +22,7 @@ var __spreadValues = (a, b) => {
|
|
|
20
22
|
}
|
|
21
23
|
return a;
|
|
22
24
|
};
|
|
25
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
26
|
var __objRest = (source, exclude) => {
|
|
24
27
|
var target = {};
|
|
25
28
|
for (var prop in source)
|
|
@@ -67,6 +70,7 @@ __export(dialog_exports, {
|
|
|
67
70
|
DialogTrigger: () => DialogTrigger
|
|
68
71
|
});
|
|
69
72
|
module.exports = __toCommonJS(dialog_exports);
|
|
73
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
70
74
|
var DialogPrimitive = __toESM(require("@radix-ui/react-dialog"), 1);
|
|
71
75
|
var import_react_icons = require("@radix-ui/react-icons");
|
|
72
76
|
var React = __toESM(require("react"), 1);
|
|
@@ -77,7 +81,7 @@ const DialogPortal = DialogPrimitive.Portal;
|
|
|
77
81
|
const DialogClose = DialogPrimitive.Close;
|
|
78
82
|
const DialogOverlay = React.forwardRef((_a, ref) => {
|
|
79
83
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
80
|
-
return /* @__PURE__ */
|
|
84
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
81
85
|
DialogPrimitive.Overlay,
|
|
82
86
|
__spreadValues({
|
|
83
87
|
ref,
|
|
@@ -91,18 +95,27 @@ const DialogOverlay = React.forwardRef((_a, ref) => {
|
|
|
91
95
|
DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
|
|
92
96
|
const DialogContent = React.forwardRef((_c, ref) => {
|
|
93
97
|
var _d = _c, { className, children } = _d, props = __objRest(_d, ["className", "children"]);
|
|
94
|
-
return /* @__PURE__ */
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
className
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
98
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DialogPortal, { children: [
|
|
99
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogOverlay, {}),
|
|
100
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
101
|
+
DialogPrimitive.Content,
|
|
102
|
+
__spreadProps(__spreadValues({
|
|
103
|
+
ref,
|
|
104
|
+
className: (0, import_utils.cn)(
|
|
105
|
+
"bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] fixed left-1/2 top-1/2 z-50 grid w-full max-w-lg -translate-x-1/2 -translate-y-1/2 gap-4 border p-6 shadow-lg duration-200 sm:rounded-lg md:w-full",
|
|
106
|
+
className
|
|
107
|
+
)
|
|
108
|
+
}, props), {
|
|
109
|
+
children: [
|
|
110
|
+
children,
|
|
111
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DialogPrimitive.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:pointer-events-none", children: [
|
|
112
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.Cross2Icon, { className: "size-4" }),
|
|
113
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "sr-only", children: "Close" })
|
|
114
|
+
] })
|
|
115
|
+
]
|
|
116
|
+
})
|
|
117
|
+
)
|
|
118
|
+
] });
|
|
106
119
|
});
|
|
107
120
|
DialogContent.displayName = DialogPrimitive.Content.displayName;
|
|
108
121
|
const DialogHeader = (_e) => {
|
|
@@ -111,7 +124,7 @@ const DialogHeader = (_e) => {
|
|
|
111
124
|
} = _f, props = __objRest(_f, [
|
|
112
125
|
"className"
|
|
113
126
|
]);
|
|
114
|
-
return /* @__PURE__ */
|
|
127
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
115
128
|
"div",
|
|
116
129
|
__spreadValues({
|
|
117
130
|
className: (0, import_utils.cn)(
|
|
@@ -128,7 +141,7 @@ const DialogFooter = (_g) => {
|
|
|
128
141
|
} = _h, props = __objRest(_h, [
|
|
129
142
|
"className"
|
|
130
143
|
]);
|
|
131
|
-
return /* @__PURE__ */
|
|
144
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
132
145
|
"div",
|
|
133
146
|
__spreadValues({
|
|
134
147
|
className: (0, import_utils.cn)(
|
|
@@ -141,7 +154,7 @@ const DialogFooter = (_g) => {
|
|
|
141
154
|
DialogFooter.displayName = "DialogFooter";
|
|
142
155
|
const DialogTitle = React.forwardRef((_i, ref) => {
|
|
143
156
|
var _j = _i, { className } = _j, props = __objRest(_j, ["className"]);
|
|
144
|
-
return /* @__PURE__ */
|
|
157
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
145
158
|
DialogPrimitive.Title,
|
|
146
159
|
__spreadValues({
|
|
147
160
|
ref,
|
|
@@ -155,7 +168,7 @@ const DialogTitle = React.forwardRef((_i, ref) => {
|
|
|
155
168
|
DialogTitle.displayName = DialogPrimitive.Title.displayName;
|
|
156
169
|
const DialogDescription = React.forwardRef((_k, ref) => {
|
|
157
170
|
var _l = _k, { className } = _l, props = __objRest(_l, ["className"]);
|
|
158
|
-
return /* @__PURE__ */
|
|
171
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
159
172
|
DialogPrimitive.Description,
|
|
160
173
|
__spreadValues({
|
|
161
174
|
ref,
|
package/dist/ui/drawer.cjs
CHANGED
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
var __create = Object.create;
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
|
+
var __defProps = Object.defineProperties;
|
|
5
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
6
8
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
9
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
8
10
|
var __getProtoOf = Object.getPrototypeOf;
|
|
@@ -20,6 +22,7 @@ var __spreadValues = (a, b) => {
|
|
|
20
22
|
}
|
|
21
23
|
return a;
|
|
22
24
|
};
|
|
25
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
26
|
var __objRest = (source, exclude) => {
|
|
24
27
|
var target = {};
|
|
25
28
|
for (var prop in source)
|
|
@@ -67,6 +70,7 @@ __export(drawer_exports, {
|
|
|
67
70
|
DrawerTrigger: () => DrawerTrigger
|
|
68
71
|
});
|
|
69
72
|
module.exports = __toCommonJS(drawer_exports);
|
|
73
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
70
74
|
var React = __toESM(require("react"), 1);
|
|
71
75
|
var import_vaul = require("vaul");
|
|
72
76
|
var import_utils = require("../lib/utils");
|
|
@@ -76,7 +80,7 @@ const Drawer = (_a) => {
|
|
|
76
80
|
} = _b, props = __objRest(_b, [
|
|
77
81
|
"shouldScaleBackground"
|
|
78
82
|
]);
|
|
79
|
-
return /* @__PURE__ */
|
|
83
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
80
84
|
import_vaul.Drawer.Root,
|
|
81
85
|
__spreadValues({
|
|
82
86
|
shouldScaleBackground
|
|
@@ -89,7 +93,7 @@ const DrawerPortal = import_vaul.Drawer.Portal;
|
|
|
89
93
|
const DrawerClose = import_vaul.Drawer.Close;
|
|
90
94
|
const DrawerOverlay = React.forwardRef((_c, ref) => {
|
|
91
95
|
var _d = _c, { className } = _d, props = __objRest(_d, ["className"]);
|
|
92
|
-
return /* @__PURE__ */
|
|
96
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
93
97
|
import_vaul.Drawer.Overlay,
|
|
94
98
|
__spreadValues({
|
|
95
99
|
ref,
|
|
@@ -100,18 +104,24 @@ const DrawerOverlay = React.forwardRef((_c, ref) => {
|
|
|
100
104
|
DrawerOverlay.displayName = import_vaul.Drawer.Overlay.displayName;
|
|
101
105
|
const DrawerContent = React.forwardRef((_e, ref) => {
|
|
102
106
|
var _f = _e, { className, children } = _f, props = __objRest(_f, ["className", "children"]);
|
|
103
|
-
return /* @__PURE__ */
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
className
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
107
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DrawerPortal, { children: [
|
|
108
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DrawerOverlay, {}),
|
|
109
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
110
|
+
import_vaul.Drawer.Content,
|
|
111
|
+
__spreadProps(__spreadValues({
|
|
112
|
+
ref,
|
|
113
|
+
className: (0, import_utils.cn)(
|
|
114
|
+
"bg-background fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border",
|
|
115
|
+
className
|
|
116
|
+
)
|
|
117
|
+
}, props), {
|
|
118
|
+
children: [
|
|
119
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "bg-muted mx-auto mt-4 h-2 w-[100px] rounded-full" }),
|
|
120
|
+
children
|
|
121
|
+
]
|
|
122
|
+
})
|
|
123
|
+
)
|
|
124
|
+
] });
|
|
115
125
|
});
|
|
116
126
|
DrawerContent.displayName = "DrawerContent";
|
|
117
127
|
const DrawerHeader = (_g) => {
|
|
@@ -120,7 +130,7 @@ const DrawerHeader = (_g) => {
|
|
|
120
130
|
} = _h, props = __objRest(_h, [
|
|
121
131
|
"className"
|
|
122
132
|
]);
|
|
123
|
-
return /* @__PURE__ */
|
|
133
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
124
134
|
"div",
|
|
125
135
|
__spreadValues({
|
|
126
136
|
className: (0, import_utils.cn)("grid gap-1.5 p-4 text-center sm:text-left", className)
|
|
@@ -134,7 +144,7 @@ const DrawerFooter = (_i) => {
|
|
|
134
144
|
} = _j, props = __objRest(_j, [
|
|
135
145
|
"className"
|
|
136
146
|
]);
|
|
137
|
-
return /* @__PURE__ */
|
|
147
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
138
148
|
"div",
|
|
139
149
|
__spreadValues({
|
|
140
150
|
className: (0, import_utils.cn)("mt-auto flex flex-col gap-2 p-4", className)
|
|
@@ -144,7 +154,7 @@ const DrawerFooter = (_i) => {
|
|
|
144
154
|
DrawerFooter.displayName = "DrawerFooter";
|
|
145
155
|
const DrawerTitle = React.forwardRef((_k, ref) => {
|
|
146
156
|
var _l = _k, { className } = _l, props = __objRest(_l, ["className"]);
|
|
147
|
-
return /* @__PURE__ */
|
|
157
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
148
158
|
import_vaul.Drawer.Title,
|
|
149
159
|
__spreadValues({
|
|
150
160
|
ref,
|
|
@@ -158,7 +168,7 @@ const DrawerTitle = React.forwardRef((_k, ref) => {
|
|
|
158
168
|
DrawerTitle.displayName = import_vaul.Drawer.Title.displayName;
|
|
159
169
|
const DrawerDescription = React.forwardRef((_m, ref) => {
|
|
160
170
|
var _n = _m, { className } = _n, props = __objRest(_n, ["className"]);
|
|
161
|
-
return /* @__PURE__ */
|
|
171
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
162
172
|
import_vaul.Drawer.Description,
|
|
163
173
|
__spreadValues({
|
|
164
174
|
ref,
|
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
var __create = Object.create;
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
|
+
var __defProps = Object.defineProperties;
|
|
5
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
6
8
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
9
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
8
10
|
var __getProtoOf = Object.getPrototypeOf;
|
|
@@ -20,6 +22,7 @@ var __spreadValues = (a, b) => {
|
|
|
20
22
|
}
|
|
21
23
|
return a;
|
|
22
24
|
};
|
|
25
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
26
|
var __objRest = (source, exclude) => {
|
|
24
27
|
var target = {};
|
|
25
28
|
for (var prop in source)
|
|
@@ -72,6 +75,7 @@ __export(dropdown_menu_exports, {
|
|
|
72
75
|
DropdownMenuTrigger: () => DropdownMenuTrigger
|
|
73
76
|
});
|
|
74
77
|
module.exports = __toCommonJS(dropdown_menu_exports);
|
|
78
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
75
79
|
var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"), 1);
|
|
76
80
|
var import_react_icons = require("@radix-ui/react-icons");
|
|
77
81
|
var React = __toESM(require("react"), 1);
|
|
@@ -84,24 +88,27 @@ const DropdownMenuSub = DropdownMenuPrimitive.Sub;
|
|
|
84
88
|
const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;
|
|
85
89
|
const DropdownMenuSubTrigger = React.forwardRef((_a, ref) => {
|
|
86
90
|
var _b = _a, { className, inset, children } = _b, props = __objRest(_b, ["className", "inset", "children"]);
|
|
87
|
-
return /* @__PURE__ */
|
|
91
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
88
92
|
DropdownMenuPrimitive.SubTrigger,
|
|
89
|
-
__spreadValues({
|
|
93
|
+
__spreadProps(__spreadValues({
|
|
90
94
|
ref,
|
|
91
95
|
className: (0, import_utils.cn)(
|
|
92
96
|
"focus:bg-accent data-[state=open]:bg-accent flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none",
|
|
93
97
|
inset && "pl-8",
|
|
94
98
|
className
|
|
95
99
|
)
|
|
96
|
-
}, props),
|
|
97
|
-
|
|
98
|
-
|
|
100
|
+
}, props), {
|
|
101
|
+
children: [
|
|
102
|
+
children,
|
|
103
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.ChevronRightIcon, { className: "ml-auto h-4 w-4" })
|
|
104
|
+
]
|
|
105
|
+
})
|
|
99
106
|
);
|
|
100
107
|
});
|
|
101
108
|
DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;
|
|
102
109
|
const DropdownMenuSubContent = React.forwardRef((_c, ref) => {
|
|
103
110
|
var _d = _c, { className } = _d, props = __objRest(_d, ["className"]);
|
|
104
|
-
return /* @__PURE__ */
|
|
111
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
105
112
|
DropdownMenuPrimitive.SubContent,
|
|
106
113
|
__spreadValues({
|
|
107
114
|
ref,
|
|
@@ -115,7 +122,7 @@ const DropdownMenuSubContent = React.forwardRef((_c, ref) => {
|
|
|
115
122
|
DropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;
|
|
116
123
|
const DropdownMenuContent = React.forwardRef((_e, ref) => {
|
|
117
124
|
var _f = _e, { className, sideOffset = 4 } = _f, props = __objRest(_f, ["className", "sideOffset"]);
|
|
118
|
-
return /* @__PURE__ */
|
|
125
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
119
126
|
DropdownMenuPrimitive.Content,
|
|
120
127
|
__spreadValues({
|
|
121
128
|
ref,
|
|
@@ -126,12 +133,12 @@ const DropdownMenuContent = React.forwardRef((_e, ref) => {
|
|
|
126
133
|
className
|
|
127
134
|
)
|
|
128
135
|
}, props)
|
|
129
|
-
));
|
|
136
|
+
) });
|
|
130
137
|
});
|
|
131
138
|
DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
|
|
132
139
|
const DropdownMenuItem = React.forwardRef((_g, ref) => {
|
|
133
140
|
var _h = _g, { className, inset } = _h, props = __objRest(_h, ["className", "inset"]);
|
|
134
|
-
return /* @__PURE__ */
|
|
141
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
135
142
|
DropdownMenuPrimitive.Item,
|
|
136
143
|
__spreadValues({
|
|
137
144
|
ref,
|
|
@@ -146,40 +153,46 @@ const DropdownMenuItem = React.forwardRef((_g, ref) => {
|
|
|
146
153
|
DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
|
|
147
154
|
const DropdownMenuCheckboxItem = React.forwardRef((_i, ref) => {
|
|
148
155
|
var _j = _i, { className, children, checked } = _j, props = __objRest(_j, ["className", "children", "checked"]);
|
|
149
|
-
return /* @__PURE__ */
|
|
156
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
150
157
|
DropdownMenuPrimitive.CheckboxItem,
|
|
151
|
-
__spreadValues({
|
|
158
|
+
__spreadProps(__spreadValues({
|
|
152
159
|
ref,
|
|
153
160
|
className: (0, import_utils.cn)(
|
|
154
161
|
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
155
162
|
className
|
|
156
163
|
),
|
|
157
164
|
checked
|
|
158
|
-
}, props),
|
|
159
|
-
|
|
160
|
-
|
|
165
|
+
}, props), {
|
|
166
|
+
children: [
|
|
167
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.CheckIcon, { className: "h-4 w-4" }) }) }),
|
|
168
|
+
children
|
|
169
|
+
]
|
|
170
|
+
})
|
|
161
171
|
);
|
|
162
172
|
});
|
|
163
173
|
DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;
|
|
164
174
|
const DropdownMenuRadioItem = React.forwardRef((_k, ref) => {
|
|
165
175
|
var _l = _k, { className, children } = _l, props = __objRest(_l, ["className", "children"]);
|
|
166
|
-
return /* @__PURE__ */
|
|
176
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
167
177
|
DropdownMenuPrimitive.RadioItem,
|
|
168
|
-
__spreadValues({
|
|
178
|
+
__spreadProps(__spreadValues({
|
|
169
179
|
ref,
|
|
170
180
|
className: (0, import_utils.cn)(
|
|
171
181
|
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
172
182
|
className
|
|
173
183
|
)
|
|
174
|
-
}, props),
|
|
175
|
-
|
|
176
|
-
|
|
184
|
+
}, props), {
|
|
185
|
+
children: [
|
|
186
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_icons.DotFilledIcon, { className: "h-4 w-4 fill-current" }) }) }),
|
|
187
|
+
children
|
|
188
|
+
]
|
|
189
|
+
})
|
|
177
190
|
);
|
|
178
191
|
});
|
|
179
192
|
DropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;
|
|
180
193
|
const DropdownMenuLabel = React.forwardRef((_m, ref) => {
|
|
181
194
|
var _n = _m, { className, inset } = _n, props = __objRest(_n, ["className", "inset"]);
|
|
182
|
-
return /* @__PURE__ */
|
|
195
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
183
196
|
DropdownMenuPrimitive.Label,
|
|
184
197
|
__spreadValues({
|
|
185
198
|
ref,
|
|
@@ -194,7 +207,7 @@ const DropdownMenuLabel = React.forwardRef((_m, ref) => {
|
|
|
194
207
|
DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
|
|
195
208
|
const DropdownMenuSeparator = React.forwardRef((_o, ref) => {
|
|
196
209
|
var _p = _o, { className } = _p, props = __objRest(_p, ["className"]);
|
|
197
|
-
return /* @__PURE__ */
|
|
210
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
198
211
|
DropdownMenuPrimitive.Separator,
|
|
199
212
|
__spreadValues({
|
|
200
213
|
ref,
|
|
@@ -209,7 +222,7 @@ const DropdownMenuShortcut = (_q) => {
|
|
|
209
222
|
} = _r, props = __objRest(_r, [
|
|
210
223
|
"className"
|
|
211
224
|
]);
|
|
212
|
-
return /* @__PURE__ */
|
|
225
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
213
226
|
"span",
|
|
214
227
|
__spreadValues({
|
|
215
228
|
className: (0, import_utils.cn)("ml-auto text-xs tracking-widest opacity-60", className)
|
package/dist/ui/form copy.cjs
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __create = Object.create;
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
|
+
var __defProps = Object.defineProperties;
|
|
4
5
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
5
7
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
8
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
7
9
|
var __getProtoOf = Object.getPrototypeOf;
|
|
@@ -19,6 +21,7 @@ var __spreadValues = (a, b) => {
|
|
|
19
21
|
}
|
|
20
22
|
return a;
|
|
21
23
|
};
|
|
24
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
22
25
|
var __objRest = (source, exclude) => {
|
|
23
26
|
var target = {};
|
|
24
27
|
for (var prop in source)
|
|
@@ -64,6 +67,7 @@ __export(form_copy_exports, {
|
|
|
64
67
|
useFormField: () => useFormField
|
|
65
68
|
});
|
|
66
69
|
module.exports = __toCommonJS(form_copy_exports);
|
|
70
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
67
71
|
var import_react_slot = require("@radix-ui/react-slot");
|
|
68
72
|
var React = __toESM(require("react"), 1);
|
|
69
73
|
var import_react_hook_form = require("react-hook-form");
|
|
@@ -75,7 +79,7 @@ const FormFieldContext = React.createContext(
|
|
|
75
79
|
);
|
|
76
80
|
const FormField = (_a) => {
|
|
77
81
|
var props = __objRest(_a, []);
|
|
78
|
-
return /* @__PURE__ */
|
|
82
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_hook_form.Controller, __spreadValues({}, props)) });
|
|
79
83
|
};
|
|
80
84
|
const useFormField = () => {
|
|
81
85
|
const fieldContext = React.useContext(FormFieldContext);
|
|
@@ -100,13 +104,13 @@ const FormItemContext = React.createContext(
|
|
|
100
104
|
const FormItem = React.forwardRef((_b, ref) => {
|
|
101
105
|
var _c = _b, { className } = _c, props = __objRest(_c, ["className"]);
|
|
102
106
|
const id = React.useId();
|
|
103
|
-
return /* @__PURE__ */
|
|
107
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", __spreadValues({ ref, className: (0, import_utils.cn)("space-y-2", className) }, props)) });
|
|
104
108
|
});
|
|
105
109
|
FormItem.displayName = "FormItem";
|
|
106
110
|
const FormLabel = React.forwardRef((_d, ref) => {
|
|
107
111
|
var _e = _d, { className } = _e, props = __objRest(_e, ["className"]);
|
|
108
112
|
const { error, formItemId } = useFormField();
|
|
109
|
-
return /* @__PURE__ */
|
|
113
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
110
114
|
import_label.Label,
|
|
111
115
|
__spreadValues({
|
|
112
116
|
ref,
|
|
@@ -119,7 +123,7 @@ FormLabel.displayName = "FormLabel";
|
|
|
119
123
|
const FormControl = React.forwardRef((_f, ref) => {
|
|
120
124
|
var props = __objRest(_f, []);
|
|
121
125
|
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
122
|
-
return /* @__PURE__ */
|
|
126
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
123
127
|
import_react_slot.Slot,
|
|
124
128
|
__spreadValues({
|
|
125
129
|
ref,
|
|
@@ -133,7 +137,7 @@ FormControl.displayName = "FormControl";
|
|
|
133
137
|
const FormDescription = React.forwardRef((_g, ref) => {
|
|
134
138
|
var _h = _g, { className } = _h, props = __objRest(_h, ["className"]);
|
|
135
139
|
const { formDescriptionId } = useFormField();
|
|
136
|
-
return /* @__PURE__ */
|
|
140
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
137
141
|
"p",
|
|
138
142
|
__spreadValues({
|
|
139
143
|
ref,
|
|
@@ -150,14 +154,15 @@ const FormMessage = React.forwardRef((_i, ref) => {
|
|
|
150
154
|
if (!body) {
|
|
151
155
|
return null;
|
|
152
156
|
}
|
|
153
|
-
return /* @__PURE__ */
|
|
157
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
154
158
|
"p",
|
|
155
|
-
__spreadValues({
|
|
159
|
+
__spreadProps(__spreadValues({
|
|
156
160
|
ref,
|
|
157
161
|
id: formMessageId,
|
|
158
162
|
className: (0, import_utils.cn)("text-destructive text-[0.8rem] font-medium", className)
|
|
159
|
-
}, props),
|
|
160
|
-
|
|
163
|
+
}, props), {
|
|
164
|
+
children: body
|
|
165
|
+
})
|
|
161
166
|
);
|
|
162
167
|
});
|
|
163
168
|
FormMessage.displayName = "FormMessage";
|