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/esm/ui/toaster.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
+
var __defProps = Object.defineProperties;
|
|
4
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
3
5
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
4
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
7
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -15,6 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
15
17
|
}
|
|
16
18
|
return a;
|
|
17
19
|
};
|
|
20
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
18
21
|
var __objRest = (source, exclude) => {
|
|
19
22
|
var target = {};
|
|
20
23
|
for (var prop in source)
|
|
@@ -27,6 +30,7 @@ var __objRest = (source, exclude) => {
|
|
|
27
30
|
}
|
|
28
31
|
return target;
|
|
29
32
|
};
|
|
33
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
30
34
|
import {
|
|
31
35
|
Toast,
|
|
32
36
|
ToastClose,
|
|
@@ -38,10 +42,20 @@ import {
|
|
|
38
42
|
import { useToast } from "./use-toast";
|
|
39
43
|
function Toaster() {
|
|
40
44
|
const { toasts } = useToast();
|
|
41
|
-
return /* @__PURE__ */
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
+
return /* @__PURE__ */ jsxs(ToastProvider, { children: [
|
|
46
|
+
toasts.map(function(_a) {
|
|
47
|
+
var _b = _a, { id, title, description, action } = _b, props = __objRest(_b, ["id", "title", "description", "action"]);
|
|
48
|
+
return /* @__PURE__ */ jsxs(Toast, __spreadProps(__spreadValues({}, props), { children: [
|
|
49
|
+
/* @__PURE__ */ jsxs("div", { className: "grid gap-1", children: [
|
|
50
|
+
title && /* @__PURE__ */ jsx(ToastTitle, { children: title }),
|
|
51
|
+
description && /* @__PURE__ */ jsx(ToastDescription, { children: description })
|
|
52
|
+
] }),
|
|
53
|
+
action,
|
|
54
|
+
/* @__PURE__ */ jsx(ToastClose, {})
|
|
55
|
+
] }), id);
|
|
56
|
+
}),
|
|
57
|
+
/* @__PURE__ */ jsx(ToastViewport, {})
|
|
58
|
+
] });
|
|
45
59
|
}
|
|
46
60
|
export {
|
|
47
61
|
Toaster
|
package/dist/esm/ui/toggle.js
CHANGED
|
@@ -27,6 +27,7 @@ var __objRest = (source, exclude) => {
|
|
|
27
27
|
}
|
|
28
28
|
return target;
|
|
29
29
|
};
|
|
30
|
+
import { jsx } from "react/jsx-runtime";
|
|
30
31
|
import * as TogglePrimitive from "@radix-ui/react-toggle";
|
|
31
32
|
import { cva } from "class-variance-authority";
|
|
32
33
|
import * as React from "react";
|
|
@@ -53,7 +54,7 @@ const toggleVariants = cva(
|
|
|
53
54
|
);
|
|
54
55
|
const Toggle = React.forwardRef((_a, ref) => {
|
|
55
56
|
var _b = _a, { className, variant, size } = _b, props = __objRest(_b, ["className", "variant", "size"]);
|
|
56
|
-
return /* @__PURE__ */
|
|
57
|
+
return /* @__PURE__ */ jsx(
|
|
57
58
|
TogglePrimitive.Root,
|
|
58
59
|
__spreadValues({
|
|
59
60
|
ref,
|
package/dist/esm/ui/tooltip.js
CHANGED
|
@@ -27,6 +27,7 @@ var __objRest = (source, exclude) => {
|
|
|
27
27
|
}
|
|
28
28
|
return target;
|
|
29
29
|
};
|
|
30
|
+
import { jsx } from "react/jsx-runtime";
|
|
30
31
|
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
31
32
|
import * as React from "react";
|
|
32
33
|
import { cn } from "../lib/utils";
|
|
@@ -35,7 +36,7 @@ const Tooltip = TooltipPrimitive.Root;
|
|
|
35
36
|
const TooltipTrigger = TooltipPrimitive.Trigger;
|
|
36
37
|
const TooltipContent = React.forwardRef((_a, ref) => {
|
|
37
38
|
var _b = _a, { className, sideOffset = 4 } = _b, props = __objRest(_b, ["className", "sideOffset"]);
|
|
38
|
-
return /* @__PURE__ */
|
|
39
|
+
return /* @__PURE__ */ jsx(
|
|
39
40
|
TooltipPrimitive.Content,
|
|
40
41
|
__spreadValues({
|
|
41
42
|
ref,
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
3
|
import Link from "next/link";
|
|
3
4
|
import { usePathname } from "next/navigation";
|
|
4
5
|
import { cn } from "../../lib/utils";
|
|
5
6
|
const dynamic = "force-dynamic";
|
|
6
7
|
const NavTag = ({ children, href }) => {
|
|
7
8
|
const pathName = usePathname();
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
+
return /* @__PURE__ */ jsx(
|
|
9
10
|
Link,
|
|
10
11
|
{
|
|
11
12
|
href,
|
|
12
13
|
className: cn(
|
|
13
14
|
"basis-32 content-center justify-center border bg-slate-200 p-1 px-2 text-center",
|
|
14
15
|
pathName == href && "bg-blue-200"
|
|
15
|
-
)
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
),
|
|
17
|
+
children
|
|
18
|
+
}
|
|
18
19
|
);
|
|
19
20
|
};
|
|
20
21
|
export {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
3
|
import { useCallback, useRef, useEffect } from "react";
|
|
3
4
|
import { useRouter } from "next/navigation";
|
|
4
5
|
function SimpleModel({ children }) {
|
|
@@ -28,21 +29,21 @@ function SimpleModel({ children }) {
|
|
|
28
29
|
document.addEventListener("keydown", onKeyDown);
|
|
29
30
|
return () => document.removeEventListener("keydown", onKeyDown);
|
|
30
31
|
}, [onKeyDown]);
|
|
31
|
-
return /* @__PURE__ */
|
|
32
|
+
return /* @__PURE__ */ jsx(
|
|
32
33
|
"div",
|
|
33
34
|
{
|
|
34
35
|
ref: overlay,
|
|
35
36
|
className: "fixed inset-0 z-10 mx-auto bg-black/60",
|
|
36
|
-
onClick
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
37
|
+
onClick,
|
|
38
|
+
children: /* @__PURE__ */ jsx(
|
|
39
|
+
"div",
|
|
40
|
+
{
|
|
41
|
+
ref: wrapper,
|
|
42
|
+
className: "absolute left-1/2 top-1/2 w-full -translate-x-1/2 -translate-y-1/2 p-6 sm:w-10/12 md:w-8/12 lg:w-1/2",
|
|
43
|
+
children
|
|
44
|
+
}
|
|
45
|
+
)
|
|
46
|
+
}
|
|
46
47
|
);
|
|
47
48
|
}
|
|
48
49
|
export {
|
|
@@ -29,6 +29,7 @@ var __objRest = (source, exclude) => {
|
|
|
29
29
|
}
|
|
30
30
|
return target;
|
|
31
31
|
};
|
|
32
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
32
33
|
import React from "react";
|
|
33
34
|
import { useFormContext } from "react-hook-form";
|
|
34
35
|
import { cn } from "../../../lib/utils";
|
|
@@ -40,10 +41,10 @@ const InputField = React.forwardRef(
|
|
|
40
41
|
var _a2, _b2;
|
|
41
42
|
const formMethods = useFormContext();
|
|
42
43
|
if (!formMethods) {
|
|
43
|
-
return /* @__PURE__ */
|
|
44
|
+
return /* @__PURE__ */ jsx("div", { className: "bg-red-100", children: "missing form context" });
|
|
44
45
|
}
|
|
45
46
|
if (type == "hidden") {
|
|
46
|
-
return /* @__PURE__ */
|
|
47
|
+
return /* @__PURE__ */ jsx(
|
|
47
48
|
"input",
|
|
48
49
|
__spreadProps(__spreadValues({}, formMethods.register(name)), {
|
|
49
50
|
type: "hidden",
|
|
@@ -51,27 +52,33 @@ const InputField = React.forwardRef(
|
|
|
51
52
|
})
|
|
52
53
|
);
|
|
53
54
|
} else {
|
|
54
|
-
return /* @__PURE__ */
|
|
55
|
+
return /* @__PURE__ */ jsxs("div", { className: cn(
|
|
55
56
|
"group relative my-2",
|
|
56
57
|
// "max-w-[fit-content]",
|
|
57
58
|
className
|
|
58
|
-
)
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
59
|
+
), children: [
|
|
60
|
+
/* @__PURE__ */ jsx(
|
|
61
|
+
Input,
|
|
62
|
+
__spreadValues({
|
|
63
|
+
type,
|
|
64
|
+
className: cn(
|
|
65
|
+
"peer p-4 outline-none",
|
|
66
|
+
"focus-visible:ring-0",
|
|
67
|
+
"focus-visible:border-none",
|
|
68
|
+
"border-none ring-0"
|
|
69
|
+
),
|
|
70
|
+
placeholder: " "
|
|
71
|
+
}, formMethods.register(name))
|
|
72
|
+
),
|
|
73
|
+
/* @__PURE__ */ jsx(Label, { className: cn(
|
|
74
|
+
"pointer-events-none absolute left-[9px] top-px -translate-y-1/2 px-1 text-sm text-gray-500 transition-all duration-300 group-focus-within:!top-px group-focus-within:!text-sm group-focus-within:!text-blue-500 peer-placeholder-shown:top-1/2 peer-placeholder-shown:text-xl"
|
|
75
|
+
), children: label }),
|
|
76
|
+
/* @__PURE__ */ jsx("fieldset", { className: cn(
|
|
77
|
+
"pointer-events-none invisible absolute inset-0 mt-[-9px] rounded border border-gray-400 group-focus-within:border-2 group-focus-within:!border-blue-500 group-hover:border-gray-700 peer-placeholder-shown:visible"
|
|
78
|
+
), children: /* @__PURE__ */ jsx("legend", { className: "invisible ml-2 max-w-[0.01px] whitespace-nowrap px-0 text-sm transition-all duration-300 group-focus-within:max-w-full group-focus-within:px-1", children: label }) }),
|
|
79
|
+
/* @__PURE__ */ jsx("fieldset", { className: cn("pointer-events-none visible absolute inset-0 mt-[-9px] rounded border border-gray-400 group-focus-within:border-2 group-focus-within:!border-blue-500 group-hover:border-gray-700 peer-placeholder-shown:invisible"), children: /* @__PURE__ */ jsx("legend", { className: "invisible ml-2 max-w-full whitespace-nowrap px-1 text-sm", children: label }) }),
|
|
80
|
+
((_a2 = formMethods.formState.errors[name]) == null ? void 0 : _a2.message) && /* @__PURE__ */ jsx("p", { className: "text-red-700", children: /* @__PURE__ */ jsx(Fragment, { children: (_b2 = formMethods.formState.errors[name]) == null ? void 0 : _b2.message }) })
|
|
81
|
+
] });
|
|
75
82
|
}
|
|
76
83
|
}
|
|
77
84
|
);
|
|
@@ -19,6 +19,7 @@ var __async = (__this, __arguments, generator) => {
|
|
|
19
19
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
20
20
|
});
|
|
21
21
|
};
|
|
22
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
22
23
|
import Image from "next/image";
|
|
23
24
|
import { useState } from "react";
|
|
24
25
|
const SingleFileUploadForm = () => {
|
|
@@ -78,65 +79,75 @@ const SingleFileUploadForm = () => {
|
|
|
78
79
|
alert("Sorry! something went wrong.");
|
|
79
80
|
}
|
|
80
81
|
});
|
|
81
|
-
return /* @__PURE__ */
|
|
82
|
+
return /* @__PURE__ */ jsx(
|
|
82
83
|
"form",
|
|
83
84
|
{
|
|
84
85
|
className: "w-full border border-dashed border-gray-500 p-3",
|
|
85
|
-
onSubmit: (e) => e.preventDefault()
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
86
|
+
onSubmit: (e) => e.preventDefault(),
|
|
87
|
+
children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1.5 md:flex-row md:py-4", children: [
|
|
88
|
+
/* @__PURE__ */ jsx("div", { className: "grow", children: previewUrl ? /* @__PURE__ */ jsx("div", { className: "mx-auto w-80", children: /* @__PURE__ */ jsx(
|
|
89
|
+
Image,
|
|
90
|
+
{
|
|
91
|
+
alt: "file uploader preview",
|
|
92
|
+
objectFit: "cover",
|
|
93
|
+
src: previewUrl,
|
|
94
|
+
width: 320,
|
|
95
|
+
height: 218,
|
|
96
|
+
layout: "fixed"
|
|
97
|
+
}
|
|
98
|
+
) }) : /* @__PURE__ */ jsxs("label", { className: "flex h-full cursor-pointer flex-col items-center justify-center py-3 transition-colors duration-150 hover:text-gray-600", children: [
|
|
99
|
+
/* @__PURE__ */ jsx(
|
|
100
|
+
"svg",
|
|
101
|
+
{
|
|
102
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
103
|
+
className: "h-14 w-14",
|
|
104
|
+
fill: "none",
|
|
105
|
+
viewBox: "0 0 24 24",
|
|
106
|
+
stroke: "currentColor",
|
|
107
|
+
strokeWidth: 2,
|
|
108
|
+
children: /* @__PURE__ */ jsx(
|
|
109
|
+
"path",
|
|
110
|
+
{
|
|
111
|
+
strokeLinecap: "round",
|
|
112
|
+
strokeLinejoin: "round",
|
|
113
|
+
d: "M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"
|
|
114
|
+
}
|
|
115
|
+
)
|
|
116
|
+
}
|
|
117
|
+
),
|
|
118
|
+
/* @__PURE__ */ jsx("strong", { className: "text-sm font-medium", children: "Select an image" }),
|
|
119
|
+
/* @__PURE__ */ jsx(
|
|
120
|
+
"input",
|
|
121
|
+
{
|
|
122
|
+
className: "block h-0 w-0",
|
|
123
|
+
name: "file",
|
|
124
|
+
type: "file",
|
|
125
|
+
onChange: onFileUploadChange
|
|
126
|
+
}
|
|
127
|
+
)
|
|
128
|
+
] }) }),
|
|
129
|
+
/* @__PURE__ */ jsxs("div", { className: "mt-4 flex justify-center gap-1.5 md:mt-0 md:flex-col", children: [
|
|
130
|
+
/* @__PURE__ */ jsx(
|
|
131
|
+
"button",
|
|
132
|
+
{
|
|
133
|
+
disabled: !previewUrl,
|
|
134
|
+
onClick: onCancelFile,
|
|
135
|
+
className: "w-1/2 rounded-sm bg-gray-700 px-4 py-3 text-sm font-medium text-white transition-colors duration-300 hover:bg-gray-600 disabled:bg-gray-400 md:w-auto md:text-base",
|
|
136
|
+
children: "Cancel file"
|
|
137
|
+
}
|
|
138
|
+
),
|
|
139
|
+
/* @__PURE__ */ jsx(
|
|
140
|
+
"button",
|
|
141
|
+
{
|
|
142
|
+
disabled: !previewUrl,
|
|
143
|
+
onClick: onUploadFile,
|
|
144
|
+
className: "w-1/2 rounded-sm bg-gray-700 px-4 py-3 text-sm font-medium text-white transition-colors duration-300 hover:bg-gray-600 disabled:bg-gray-400 md:w-auto md:text-base",
|
|
145
|
+
children: "Upload file"
|
|
146
|
+
}
|
|
147
|
+
)
|
|
148
|
+
] })
|
|
149
|
+
] })
|
|
150
|
+
}
|
|
140
151
|
);
|
|
141
152
|
};
|
|
142
153
|
var SingleUploadForm_default = SingleFileUploadForm;
|
|
@@ -26,6 +26,7 @@ var __objRest = (source, exclude) => {
|
|
|
26
26
|
}
|
|
27
27
|
return target;
|
|
28
28
|
};
|
|
29
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
29
30
|
import { Label } from "@radix-ui/react-context-menu";
|
|
30
31
|
import React from "react";
|
|
31
32
|
import { useFormContext } from "react-hook-form";
|
|
@@ -35,22 +36,25 @@ const TextAreaField = React.forwardRef(
|
|
|
35
36
|
(_a) => {
|
|
36
37
|
var _b = _a, { name, label, className, type, placeholder } = _b, rest = __objRest(_b, ["name", "label", "className", "type", "placeholder"]);
|
|
37
38
|
const methods = useFormContext();
|
|
38
|
-
return /* @__PURE__ */
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
39
|
+
return /* @__PURE__ */ jsxs("div", { className: "group relative", children: [
|
|
40
|
+
/* @__PURE__ */ jsx(
|
|
41
|
+
Textarea,
|
|
42
|
+
__spreadValues({
|
|
43
|
+
className: cn(
|
|
44
|
+
"mt-2",
|
|
45
|
+
"peer p-4 outline-none"
|
|
46
|
+
// "focus-visible:ring-0",
|
|
47
|
+
// "focus-visible:border-none",
|
|
48
|
+
// "border-none ring-0"
|
|
49
|
+
),
|
|
50
|
+
placeholder: " "
|
|
51
|
+
}, methods.register(name))
|
|
52
|
+
),
|
|
53
|
+
/* @__PURE__ */ jsx(Label, { className: cn(
|
|
54
|
+
"pointer-events-none absolute left-[9px] top-px -translate-y-1/2 px-1 text-sm text-gray-500 transition-all duration-300",
|
|
55
|
+
"group-focus-within:!top-2 group-focus-within:!text-sm group-focus-within:!text-blue-500 peer-placeholder-shown:top-1/2 peer-placeholder-shown:text-xl"
|
|
56
|
+
), children: label })
|
|
57
|
+
] });
|
|
54
58
|
}
|
|
55
59
|
);
|
|
56
60
|
TextAreaField.displayName = "TextAreaField";
|
|
@@ -50,10 +50,10 @@ var __async = (__this, __arguments, generator) => {
|
|
|
50
50
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
51
51
|
});
|
|
52
52
|
};
|
|
53
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
53
54
|
import { useRef } from "react";
|
|
54
55
|
import { useFormContext } from "react-hook-form";
|
|
55
56
|
import { Slot } from "@radix-ui/react-slot";
|
|
56
|
-
import React from "react";
|
|
57
57
|
const TextFileInput = (_a) => {
|
|
58
58
|
var _b = _a, { onOpenFile, name, asChild } = _b, props = __objRest(_b, ["onOpenFile", "name", "asChild"]);
|
|
59
59
|
const formMethods = useFormContext();
|
|
@@ -81,20 +81,23 @@ const TextFileInput = (_a) => {
|
|
|
81
81
|
fileReader.readAsText(uploadedFile);
|
|
82
82
|
};
|
|
83
83
|
const Comp = asChild ? Slot : "input";
|
|
84
|
-
return /* @__PURE__ */
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
84
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
85
|
+
/* @__PURE__ */ jsx(Comp, __spreadProps(__spreadValues({}, props), { onClick: (e) => {
|
|
86
|
+
var _a2;
|
|
87
|
+
(_a2 = fileRef.current) == null ? void 0 : _a2.click();
|
|
88
|
+
e.preventDefault();
|
|
89
|
+
} })),
|
|
90
|
+
/* @__PURE__ */ jsx(
|
|
91
|
+
"input",
|
|
92
|
+
{
|
|
93
|
+
style: { display: "none" },
|
|
94
|
+
ref: fileRef,
|
|
95
|
+
accept: "json/*",
|
|
96
|
+
type: "file",
|
|
97
|
+
onChange: handleFileChange
|
|
98
|
+
}
|
|
99
|
+
)
|
|
100
|
+
] });
|
|
98
101
|
};
|
|
99
102
|
export {
|
|
100
103
|
TextFileInput
|
|
@@ -13,6 +13,7 @@ var __objRest = (source, exclude) => {
|
|
|
13
13
|
}
|
|
14
14
|
return target;
|
|
15
15
|
};
|
|
16
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
16
17
|
import { Label } from "@radix-ui/react-context-menu";
|
|
17
18
|
import { Select, SelectContent, SelectTrigger, SelectValue } from "@radix-ui/react-select";
|
|
18
19
|
import React from "react";
|
|
@@ -26,36 +27,43 @@ const InputSelectField = React.forwardRef(
|
|
|
26
27
|
const handleValueChange = (value2) => {
|
|
27
28
|
methods.setValue(name, value2);
|
|
28
29
|
};
|
|
29
|
-
return /* @__PURE__ */
|
|
30
|
+
return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs("div", { className: cn(
|
|
30
31
|
"group relative my-2",
|
|
31
32
|
"flex flex-1 items-center justify-center"
|
|
32
33
|
// "max-w-[fit-content]",
|
|
33
|
-
)
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
34
|
+
), children: [
|
|
35
|
+
/* @__PURE__ */ jsxs(
|
|
36
|
+
Select,
|
|
37
|
+
{
|
|
38
|
+
name,
|
|
39
|
+
onValueChange: handleValueChange,
|
|
40
|
+
defaultValue: methods.getValues(name),
|
|
41
|
+
children: [
|
|
42
|
+
/* @__PURE__ */ jsx(FormControl, { className: cn(
|
|
43
|
+
" border-input-none peer px-4 outline-none focus-visible:ring-0",
|
|
44
|
+
"focus-visible:border-none",
|
|
45
|
+
"focus:ring-none border-none ring-0"
|
|
46
|
+
), children: /* @__PURE__ */ jsx(SelectTrigger, { className: cn(
|
|
47
|
+
" border-input-none peer px-4 outline-none focus-visible:ring-0",
|
|
48
|
+
"focus:ring-0 focus-visible:border-none",
|
|
49
|
+
"focus:ring-none border-none ring-0"
|
|
50
|
+
), children: /* @__PURE__ */ jsx(SelectValue, { placeholder: " " }) }) }),
|
|
51
|
+
/* @__PURE__ */ jsx(SelectContent, {})
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
),
|
|
55
|
+
/* @__PURE__ */ jsx(Label, { className: cn(
|
|
56
|
+
"absolute left-[9px] top-px px-1 text-sm text-gray-500 transition-all duration-300 ",
|
|
57
|
+
"pointer-events-none -translate-y-1/2 group-focus-within:!top-px group-focus-within:!text-sm group-focus-within:!text-blue-500 peer-placeholder-shown:top-1/2 peer-placeholder-shown:text-xl"
|
|
58
|
+
), children: label }),
|
|
59
|
+
/* @__PURE__ */ jsx("fieldset", { className: cn(
|
|
60
|
+
"pointer-events-none invisible absolute inset-0 mt-[-9px] rounded border border-gray-400 group-focus-within:border-2 group-focus-within:!border-blue-500 group-hover:border-gray-700 peer-placeholder-shown:visible"
|
|
61
|
+
), children: /* @__PURE__ */ jsx("legend", { className: "invisible ml-2 max-w-[0.01px] whitespace-nowrap px-0 text-sm transition-all duration-300 group-focus-within:max-w-full group-focus-within:px-1", children: label }) }),
|
|
62
|
+
/* @__PURE__ */ jsx("fieldset", { className: cn(
|
|
63
|
+
"pointer-events-none absolute inset-0 rounded border border-gray-400 ",
|
|
64
|
+
"visible mt-[-10px] group-focus-within:border-2 group-focus-within:!border-blue-500 group-hover:border-gray-700 peer-placeholder-shown:invisible"
|
|
65
|
+
), children: /* @__PURE__ */ jsx("legend", { className: "invisible ml-2 max-w-full whitespace-nowrap px-1 text-sm", children: label }) })
|
|
66
|
+
] }) });
|
|
59
67
|
}
|
|
60
68
|
);
|
|
61
69
|
InputSelectField.displayName = "InputSelectField";
|
|
@@ -27,12 +27,13 @@ var __objRest = (source, exclude) => {
|
|
|
27
27
|
}
|
|
28
28
|
return target;
|
|
29
29
|
};
|
|
30
|
+
import { jsx } from "react/jsx-runtime";
|
|
30
31
|
import * as React from "react";
|
|
31
32
|
import { cn } from "../../../lib/utils";
|
|
32
33
|
const SearchInput = React.forwardRef(
|
|
33
34
|
(_a, ref) => {
|
|
34
35
|
var _b = _a, { className, type } = _b, props = __objRest(_b, ["className", "type"]);
|
|
35
|
-
return /* @__PURE__ */
|
|
36
|
+
return /* @__PURE__ */ jsx(
|
|
36
37
|
"input",
|
|
37
38
|
__spreadValues({
|
|
38
39
|
type,
|
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
3
|
import { SearchIcon } from "lucide-react";
|
|
3
4
|
import { Button } from "../../button";
|
|
4
5
|
import { Input } from "../../input";
|
|
5
6
|
const SearchBar = () => {
|
|
6
|
-
return /* @__PURE__ */
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
return /* @__PURE__ */ jsxs("div", { className: "relative mb-1 flex items-center justify-center rounded-md border bg-slate-50", children: [
|
|
8
|
+
/* @__PURE__ */ jsx(
|
|
9
|
+
Input,
|
|
10
|
+
{
|
|
11
|
+
type: "search",
|
|
12
|
+
className: "border-1 w-full rounded",
|
|
13
|
+
placeholder: "search"
|
|
14
|
+
}
|
|
15
|
+
),
|
|
16
|
+
/* @__PURE__ */ jsx(Button, { variant: "ghost", className: "", children: /* @__PURE__ */ jsx(SearchIcon, { className: "h-4 w-4 " }) })
|
|
17
|
+
] });
|
|
14
18
|
};
|
|
15
19
|
export {
|
|
16
20
|
SearchBar
|
|
@@ -1,12 +1,17 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
1
2
|
import clsx from "clsx";
|
|
2
|
-
const SkeletonCard = ({ isLoading }) => /* @__PURE__ */
|
|
3
|
+
const SkeletonCard = ({ isLoading }) => /* @__PURE__ */ jsx(
|
|
3
4
|
"div",
|
|
4
5
|
{
|
|
5
6
|
className: clsx("rounded-2xl bg-gray-900/80 p-4", {
|
|
6
7
|
"relative overflow-hidden before:absolute before:inset-0 before:-translate-x-full before:animate-[shimmer_1.5s_infinite] before:bg-gradient-to-r before:from-transparent before:via-white/10 before:to-transparent": isLoading
|
|
7
|
-
})
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
}),
|
|
9
|
+
children: /* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
|
|
10
|
+
/* @__PURE__ */ jsx("div", { className: "h-14 rounded-lg bg-gray-700" }),
|
|
11
|
+
/* @__PURE__ */ jsx("div", { className: "h-3 w-11/12 rounded-lg bg-gray-700" }),
|
|
12
|
+
/* @__PURE__ */ jsx("div", { className: "h-3 w-8/12 rounded-lg bg-gray-700" })
|
|
13
|
+
] })
|
|
14
|
+
}
|
|
10
15
|
);
|
|
11
16
|
export {
|
|
12
17
|
SkeletonCard
|