@enerjisaformlibrary/formbuilder-react 1.0.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 +83 -0
- package/index.cjs +6433 -0
- package/index.js +6365 -0
- package/package.json +58 -0
- package/types/client/src/components/form-builder/CanvasField.d.ts +15 -0
- package/types/client/src/components/form-builder/CanvasField.d.ts.map +1 -0
- package/types/client/src/components/form-builder/ComponentLibrary.d.ts +7 -0
- package/types/client/src/components/form-builder/ComponentLibrary.d.ts.map +1 -0
- package/types/client/src/components/form-builder/DragOverlayContent.d.ts +6 -0
- package/types/client/src/components/form-builder/DragOverlayContent.d.ts.map +1 -0
- package/types/client/src/components/form-builder/FormCanvas.d.ts +2 -0
- package/types/client/src/components/form-builder/FormCanvas.d.ts.map +1 -0
- package/types/client/src/components/form-builder/JsonViewerModal.d.ts +9 -0
- package/types/client/src/components/form-builder/JsonViewerModal.d.ts.map +1 -0
- package/types/client/src/components/form-builder/PropertiesPanel.d.ts +2 -0
- package/types/client/src/components/form-builder/PropertiesPanel.d.ts.map +1 -0
- package/types/client/src/components/form-builder/Toolbar.d.ts +6 -0
- package/types/client/src/components/form-builder/Toolbar.d.ts.map +1 -0
- package/types/client/src/components/ui/accordion.d.ts +8 -0
- package/types/client/src/components/ui/accordion.d.ts.map +1 -0
- package/types/client/src/components/ui/alert-dialog.d.ts +21 -0
- package/types/client/src/components/ui/alert-dialog.d.ts.map +1 -0
- package/types/client/src/components/ui/alert.d.ts +9 -0
- package/types/client/src/components/ui/alert.d.ts.map +1 -0
- package/types/client/src/components/ui/aspect-ratio.d.ts +4 -0
- package/types/client/src/components/ui/aspect-ratio.d.ts.map +1 -0
- package/types/client/src/components/ui/avatar.d.ts +7 -0
- package/types/client/src/components/ui/avatar.d.ts.map +1 -0
- package/types/client/src/components/ui/badge.d.ts +10 -0
- package/types/client/src/components/ui/badge.d.ts.map +1 -0
- package/types/client/src/components/ui/breadcrumb.d.ts +20 -0
- package/types/client/src/components/ui/breadcrumb.d.ts.map +1 -0
- package/types/client/src/components/ui/button.d.ts +12 -0
- package/types/client/src/components/ui/button.d.ts.map +1 -0
- package/types/client/src/components/ui/calendar.d.ts +9 -0
- package/types/client/src/components/ui/calendar.d.ts.map +1 -0
- package/types/client/src/components/ui/card.d.ts +9 -0
- package/types/client/src/components/ui/card.d.ts.map +1 -0
- package/types/client/src/components/ui/carousel.d.ts +19 -0
- package/types/client/src/components/ui/carousel.d.ts.map +1 -0
- package/types/client/src/components/ui/chart.d.ts +63 -0
- package/types/client/src/components/ui/chart.d.ts.map +1 -0
- package/types/client/src/components/ui/checkbox.d.ts +5 -0
- package/types/client/src/components/ui/checkbox.d.ts.map +1 -0
- package/types/client/src/components/ui/collapsible.d.ts +6 -0
- package/types/client/src/components/ui/collapsible.d.ts.map +1 -0
- package/types/client/src/components/ui/command.d.ts +81 -0
- package/types/client/src/components/ui/command.d.ts.map +1 -0
- package/types/client/src/components/ui/context-menu.d.ts +28 -0
- package/types/client/src/components/ui/context-menu.d.ts.map +1 -0
- package/types/client/src/components/ui/dialog.d.ts +20 -0
- package/types/client/src/components/ui/dialog.d.ts.map +1 -0
- package/types/client/src/components/ui/drawer.d.ts +23 -0
- package/types/client/src/components/ui/drawer.d.ts.map +1 -0
- package/types/client/src/components/ui/dropdown-menu.d.ts +28 -0
- package/types/client/src/components/ui/dropdown-menu.d.ts.map +1 -0
- package/types/client/src/components/ui/form.d.ts +24 -0
- package/types/client/src/components/ui/form.d.ts.map +1 -0
- package/types/client/src/components/ui/hover-card.d.ts +7 -0
- package/types/client/src/components/ui/hover-card.d.ts.map +1 -0
- package/types/client/src/components/ui/input-otp.d.ts +35 -0
- package/types/client/src/components/ui/input-otp.d.ts.map +1 -0
- package/types/client/src/components/ui/input.d.ts +4 -0
- package/types/client/src/components/ui/input.d.ts.map +1 -0
- package/types/client/src/components/ui/label.d.ts +6 -0
- package/types/client/src/components/ui/label.d.ts.map +1 -0
- package/types/client/src/components/ui/menubar.d.ts +29 -0
- package/types/client/src/components/ui/menubar.d.ts.map +1 -0
- package/types/client/src/components/ui/navigation-menu.d.ts +13 -0
- package/types/client/src/components/ui/navigation-menu.d.ts.map +1 -0
- package/types/client/src/components/ui/pagination.d.ts +29 -0
- package/types/client/src/components/ui/pagination.d.ts.map +1 -0
- package/types/client/src/components/ui/popover.d.ts +7 -0
- package/types/client/src/components/ui/popover.d.ts.map +1 -0
- package/types/client/src/components/ui/progress.d.ts +5 -0
- package/types/client/src/components/ui/progress.d.ts.map +1 -0
- package/types/client/src/components/ui/radio-group.d.ts +6 -0
- package/types/client/src/components/ui/radio-group.d.ts.map +1 -0
- package/types/client/src/components/ui/resizable.d.ts +24 -0
- package/types/client/src/components/ui/resizable.d.ts.map +1 -0
- package/types/client/src/components/ui/scroll-area.d.ts +6 -0
- package/types/client/src/components/ui/scroll-area.d.ts.map +1 -0
- package/types/client/src/components/ui/select.d.ts +14 -0
- package/types/client/src/components/ui/select.d.ts.map +1 -0
- package/types/client/src/components/ui/separator.d.ts +5 -0
- package/types/client/src/components/ui/separator.d.ts.map +1 -0
- package/types/client/src/components/ui/sheet.d.ts +26 -0
- package/types/client/src/components/ui/sheet.d.ts.map +1 -0
- package/types/client/src/components/ui/sidebar.d.ts +70 -0
- package/types/client/src/components/ui/sidebar.d.ts.map +1 -0
- package/types/client/src/components/ui/skeleton.d.ts +3 -0
- package/types/client/src/components/ui/skeleton.d.ts.map +1 -0
- package/types/client/src/components/ui/slider.d.ts +5 -0
- package/types/client/src/components/ui/slider.d.ts.map +1 -0
- package/types/client/src/components/ui/switch.d.ts +5 -0
- package/types/client/src/components/ui/switch.d.ts.map +1 -0
- package/types/client/src/components/ui/table.d.ts +11 -0
- package/types/client/src/components/ui/table.d.ts.map +1 -0
- package/types/client/src/components/ui/tabs.d.ts +8 -0
- package/types/client/src/components/ui/tabs.d.ts.map +1 -0
- package/types/client/src/components/ui/textarea.d.ts +4 -0
- package/types/client/src/components/ui/textarea.d.ts.map +1 -0
- package/types/client/src/components/ui/toast.d.ts +16 -0
- package/types/client/src/components/ui/toast.d.ts.map +1 -0
- package/types/client/src/components/ui/toaster.d.ts +2 -0
- package/types/client/src/components/ui/toaster.d.ts.map +1 -0
- package/types/client/src/components/ui/toggle-group.d.ts +13 -0
- package/types/client/src/components/ui/toggle-group.d.ts.map +1 -0
- package/types/client/src/components/ui/toggle.d.ts +13 -0
- package/types/client/src/components/ui/toggle.d.ts.map +1 -0
- package/types/client/src/components/ui/tooltip.d.ts +8 -0
- package/types/client/src/components/ui/tooltip.d.ts.map +1 -0
- package/types/client/src/hooks/use-mobile.d.ts +2 -0
- package/types/client/src/hooks/use-mobile.d.ts.map +1 -0
- package/types/client/src/hooks/use-toast.d.ts +45 -0
- package/types/client/src/hooks/use-toast.d.ts.map +1 -0
- package/types/client/src/lib/formbuilder/index.d.ts +10 -0
- package/types/client/src/lib/formbuilder/index.d.ts.map +1 -0
- package/types/client/src/lib/queryClient.d.ts +9 -0
- package/types/client/src/lib/queryClient.d.ts.map +1 -0
- package/types/client/src/lib/utils.d.ts +3 -0
- package/types/client/src/lib/utils.d.ts.map +1 -0
- package/types/client/src/store/formStore.d.ts +75 -0
- package/types/client/src/store/formStore.d.ts.map +1 -0
- package/types/lib/index.d.ts +10 -0
- package/types/lib/index.d.ts.map +1 -0
- package/types/shared/schema.d.ts +17303 -0
- package/types/shared/schema.d.ts.map +1 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as ToastPrimitives from "@radix-ui/react-toast";
|
|
3
|
+
import { type VariantProps } from "class-variance-authority";
|
|
4
|
+
declare const ToastProvider: React.FC<ToastPrimitives.ToastProviderProps>;
|
|
5
|
+
declare const ToastViewport: React.ForwardRefExoticComponent<Omit<ToastPrimitives.ToastViewportProps & React.RefAttributes<HTMLOListElement>, "ref"> & React.RefAttributes<HTMLOListElement>>;
|
|
6
|
+
declare const Toast: React.ForwardRefExoticComponent<Omit<ToastPrimitives.ToastProps & React.RefAttributes<HTMLLIElement>, "ref"> & VariantProps<(props?: ({
|
|
7
|
+
variant?: "default" | "destructive" | null | undefined;
|
|
8
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string> & React.RefAttributes<HTMLLIElement>>;
|
|
9
|
+
declare const ToastAction: React.ForwardRefExoticComponent<Omit<ToastPrimitives.ToastActionProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
10
|
+
declare const ToastClose: React.ForwardRefExoticComponent<Omit<ToastPrimitives.ToastCloseProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
11
|
+
declare const ToastTitle: React.ForwardRefExoticComponent<Omit<ToastPrimitives.ToastTitleProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
12
|
+
declare const ToastDescription: React.ForwardRefExoticComponent<Omit<ToastPrimitives.ToastDescriptionProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
type ToastProps = React.ComponentPropsWithoutRef<typeof Toast>;
|
|
14
|
+
type ToastActionElement = React.ReactElement<typeof ToastAction>;
|
|
15
|
+
export { type ToastProps, type ToastActionElement, ToastProvider, ToastViewport, Toast, ToastTitle, ToastDescription, ToastClose, ToastAction, };
|
|
16
|
+
//# sourceMappingURL=toast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toast.d.ts","sourceRoot":"","sources":["../../../../../../client/src/components/ui/toast.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAA;AACxD,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAKjE,QAAA,MAAM,aAAa,8CAA2B,CAAA;AAE9C,QAAA,MAAM,aAAa,kKAYjB,CAAA;AAmBF,QAAA,MAAM,KAAK;;qHAYT,CAAA;AAGF,QAAA,MAAM,WAAW,kKAYf,CAAA;AAGF,QAAA,MAAM,UAAU,iKAed,CAAA;AAGF,QAAA,MAAM,UAAU,2JASd,CAAA;AAGF,QAAA,MAAM,gBAAgB,iKASpB,CAAA;AAGF,KAAK,UAAU,GAAG,KAAK,CAAC,wBAAwB,CAAC,OAAO,KAAK,CAAC,CAAA;AAE9D,KAAK,kBAAkB,GAAG,KAAK,CAAC,YAAY,CAAC,OAAO,WAAW,CAAC,CAAA;AAEhE,OAAO,EACL,KAAK,UAAU,EACf,KAAK,kBAAkB,EACvB,aAAa,EACb,aAAa,EACb,KAAK,EACL,UAAU,EACV,gBAAgB,EAChB,UAAU,EACV,WAAW,GACZ,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toaster.d.ts","sourceRoot":"","sources":["../../../../../../client/src/components/ui/toaster.tsx"],"names":[],"mappings":"AAUA,wBAAgB,OAAO,4CAsBtB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group";
|
|
3
|
+
import { type VariantProps } from "class-variance-authority";
|
|
4
|
+
declare const ToggleGroup: React.ForwardRefExoticComponent<((Omit<ToggleGroupPrimitive.ToggleGroupSingleProps & React.RefAttributes<HTMLDivElement>, "ref"> | Omit<ToggleGroupPrimitive.ToggleGroupMultipleProps & React.RefAttributes<HTMLDivElement>, "ref">) & VariantProps<(props?: ({
|
|
5
|
+
variant?: "default" | "outline" | null | undefined;
|
|
6
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
7
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string>) & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
declare const ToggleGroupItem: React.ForwardRefExoticComponent<Omit<ToggleGroupPrimitive.ToggleGroupItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
|
|
9
|
+
variant?: "default" | "outline" | null | undefined;
|
|
10
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
11
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string> & React.RefAttributes<HTMLButtonElement>>;
|
|
12
|
+
export { ToggleGroup, ToggleGroupItem };
|
|
13
|
+
//# sourceMappingURL=toggle-group.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toggle-group.d.ts","sourceRoot":"","sources":["../../../../../../client/src/components/ui/toggle-group.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,oBAAoB,MAAM,8BAA8B,CAAA;AACpE,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAY5D,QAAA,MAAM,WAAW;;;uHAcf,CAAA;AAIF,QAAA,MAAM,eAAe;;;yHAsBnB,CAAA;AAIF,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as TogglePrimitive from "@radix-ui/react-toggle";
|
|
3
|
+
import { type VariantProps } from "class-variance-authority";
|
|
4
|
+
declare const toggleVariants: (props?: ({
|
|
5
|
+
variant?: "default" | "outline" | null | undefined;
|
|
6
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
7
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
+
declare const Toggle: React.ForwardRefExoticComponent<Omit<TogglePrimitive.ToggleProps & React.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
|
|
9
|
+
variant?: "default" | "outline" | null | undefined;
|
|
10
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
11
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string> & React.RefAttributes<HTMLButtonElement>>;
|
|
12
|
+
export { Toggle, toggleVariants };
|
|
13
|
+
//# sourceMappingURL=toggle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toggle.d.ts","sourceRoot":"","sources":["../../../../../../client/src/components/ui/toggle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAA;AACzD,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAIjE,QAAA,MAAM,cAAc;;;8EAoBnB,CAAA;AAED,QAAA,MAAM,MAAM;;;yHAUV,CAAA;AAIF,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,CAAA"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
3
|
+
declare const TooltipProvider: React.FC<TooltipPrimitive.TooltipProviderProps>;
|
|
4
|
+
declare const Tooltip: React.FC<TooltipPrimitive.TooltipProps>;
|
|
5
|
+
declare const TooltipTrigger: React.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
6
|
+
declare const TooltipContent: React.ForwardRefExoticComponent<Omit<TooltipPrimitive.TooltipContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
|
|
8
|
+
//# sourceMappingURL=tooltip.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../../../../../client/src/components/ui/tooltip.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAA;AAI3D,QAAA,MAAM,eAAe,iDAA4B,CAAA;AAEjD,QAAA,MAAM,OAAO,yCAAwB,CAAA;AAErC,QAAA,MAAM,cAAc,gHAA2B,CAAA;AAE/C,QAAA,MAAM,cAAc,gKAalB,CAAA;AAGF,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,eAAe,EAAE,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-mobile.d.ts","sourceRoot":"","sources":["../../../../../client/src/hooks/use-mobile.tsx"],"names":[],"mappings":"AAIA,wBAAgB,WAAW,YAc1B"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import type { ToastActionElement, ToastProps } from "@/components/ui/toast";
|
|
3
|
+
type ToasterToast = ToastProps & {
|
|
4
|
+
id: string;
|
|
5
|
+
title?: React.ReactNode;
|
|
6
|
+
description?: React.ReactNode;
|
|
7
|
+
action?: ToastActionElement;
|
|
8
|
+
};
|
|
9
|
+
declare const actionTypes: {
|
|
10
|
+
readonly ADD_TOAST: "ADD_TOAST";
|
|
11
|
+
readonly UPDATE_TOAST: "UPDATE_TOAST";
|
|
12
|
+
readonly DISMISS_TOAST: "DISMISS_TOAST";
|
|
13
|
+
readonly REMOVE_TOAST: "REMOVE_TOAST";
|
|
14
|
+
};
|
|
15
|
+
type ActionType = typeof actionTypes;
|
|
16
|
+
type Action = {
|
|
17
|
+
type: ActionType["ADD_TOAST"];
|
|
18
|
+
toast: ToasterToast;
|
|
19
|
+
} | {
|
|
20
|
+
type: ActionType["UPDATE_TOAST"];
|
|
21
|
+
toast: Partial<ToasterToast>;
|
|
22
|
+
} | {
|
|
23
|
+
type: ActionType["DISMISS_TOAST"];
|
|
24
|
+
toastId?: ToasterToast["id"];
|
|
25
|
+
} | {
|
|
26
|
+
type: ActionType["REMOVE_TOAST"];
|
|
27
|
+
toastId?: ToasterToast["id"];
|
|
28
|
+
};
|
|
29
|
+
interface State {
|
|
30
|
+
toasts: ToasterToast[];
|
|
31
|
+
}
|
|
32
|
+
export declare const reducer: (state: State, action: Action) => State;
|
|
33
|
+
type Toast = Omit<ToasterToast, "id">;
|
|
34
|
+
declare function toast({ ...props }: Toast): {
|
|
35
|
+
id: string;
|
|
36
|
+
dismiss: () => void;
|
|
37
|
+
update: (props: ToasterToast) => void;
|
|
38
|
+
};
|
|
39
|
+
declare function useToast(): {
|
|
40
|
+
toast: typeof toast;
|
|
41
|
+
dismiss: (toastId?: string) => void;
|
|
42
|
+
toasts: ToasterToast[];
|
|
43
|
+
};
|
|
44
|
+
export { useToast, toast };
|
|
45
|
+
//# sourceMappingURL=use-toast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-toast.d.ts","sourceRoot":"","sources":["../../../../../client/src/hooks/use-toast.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,KAAK,EACV,kBAAkB,EAClB,UAAU,EACX,MAAM,uBAAuB,CAAA;AAK9B,KAAK,YAAY,GAAG,UAAU,GAAG;IAC/B,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACvB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC7B,MAAM,CAAC,EAAE,kBAAkB,CAAA;CAC5B,CAAA;AAED,QAAA,MAAM,WAAW;;;;;CAKP,CAAA;AASV,KAAK,UAAU,GAAG,OAAO,WAAW,CAAA;AAEpC,KAAK,MAAM,GACP;IACE,IAAI,EAAE,UAAU,CAAC,WAAW,CAAC,CAAA;IAC7B,KAAK,EAAE,YAAY,CAAA;CACpB,GACD;IACE,IAAI,EAAE,UAAU,CAAC,cAAc,CAAC,CAAA;IAChC,KAAK,EAAE,OAAO,CAAC,YAAY,CAAC,CAAA;CAC7B,GACD;IACE,IAAI,EAAE,UAAU,CAAC,eAAe,CAAC,CAAA;IACjC,OAAO,CAAC,EAAE,YAAY,CAAC,IAAI,CAAC,CAAA;CAC7B,GACD;IACE,IAAI,EAAE,UAAU,CAAC,cAAc,CAAC,CAAA;IAChC,OAAO,CAAC,EAAE,YAAY,CAAC,IAAI,CAAC,CAAA;CAC7B,CAAA;AAEL,UAAU,KAAK;IACb,MAAM,EAAE,YAAY,EAAE,CAAA;CACvB;AAoBD,eAAO,MAAM,OAAO,UAAW,KAAK,UAAU,MAAM,KAAG,KAqDtD,CAAA;AAaD,KAAK,KAAK,GAAG,IAAI,CAAC,YAAY,EAAE,IAAI,CAAC,CAAA;AAErC,iBAAS,KAAK,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK;;;oBAGT,YAAY;EAwBpC;AAED,iBAAS,QAAQ;;wBAgBO,MAAM;YAtIpB,YAAY,EAAE;EAwIvB;AAED,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export { FormCanvas } from '../../components/form-builder/FormCanvas';
|
|
2
|
+
export { CanvasField } from '../../components/form-builder/CanvasField';
|
|
3
|
+
export { PropertiesPanel } from '../../components/form-builder/PropertiesPanel';
|
|
4
|
+
export { ComponentLibrary } from '../../components/form-builder/ComponentLibrary';
|
|
5
|
+
export { Toolbar } from '../../components/form-builder/Toolbar';
|
|
6
|
+
export { DragOverlayContent } from '../../components/form-builder/DragOverlayContent';
|
|
7
|
+
export { JsonViewerModal } from '../../components/form-builder/JsonViewerModal';
|
|
8
|
+
export { useFormStore } from '../../store/formStore';
|
|
9
|
+
export * from '@shared/schema';
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../client/src/lib/formbuilder/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,0CAA0C,CAAC;AACtE,OAAO,EAAE,WAAW,EAAE,MAAM,2CAA2C,CAAC;AACxE,OAAO,EAAE,eAAe,EAAE,MAAM,+CAA+C,CAAC;AAChF,OAAO,EAAE,gBAAgB,EAAE,MAAM,gDAAgD,CAAC;AAClF,OAAO,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAChE,OAAO,EAAE,kBAAkB,EAAE,MAAM,kDAAkD,CAAC;AACtF,OAAO,EAAE,eAAe,EAAE,MAAM,+CAA+C,CAAC;AAEhF,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAErD,cAAc,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { QueryClient, QueryFunction } from "@tanstack/react-query";
|
|
2
|
+
export declare function apiRequest(method: string, url: string, data?: unknown | undefined): Promise<Response>;
|
|
3
|
+
type UnauthorizedBehavior = "returnNull" | "throw";
|
|
4
|
+
export declare const getQueryFn: <T>(options: {
|
|
5
|
+
on401: UnauthorizedBehavior;
|
|
6
|
+
}) => QueryFunction<T>;
|
|
7
|
+
export declare const queryClient: QueryClient;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=queryClient.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryClient.d.ts","sourceRoot":"","sources":["../../../../../client/src/lib/queryClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AASnE,wBAAsB,UAAU,CAC9B,MAAM,EAAE,MAAM,EACd,GAAG,EAAE,MAAM,EACX,IAAI,CAAC,EAAE,OAAO,GAAG,SAAS,GACzB,OAAO,CAAC,QAAQ,CAAC,CAUnB;AAED,KAAK,oBAAoB,GAAG,YAAY,GAAG,OAAO,CAAC;AACnD,eAAO,MAAM,UAAU,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE;IACpC,KAAK,EAAE,oBAAoB,CAAC;CAC7B,KAAK,aAAa,CAAC,CAAC,CAalB,CAAC;AAEJ,eAAO,MAAM,WAAW,aAatB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../client/src/lib/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAA;AAG5C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,UAEzC"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import type { FormSchema, FormRow, FormColumn, FormField, Selection, Step, ConditionalLogic, SubmissionConfig, FormSettings } from '@shared/schema';
|
|
2
|
+
type CanvasWidth = 'compact' | 'medium' | 'wide' | 'full';
|
|
3
|
+
interface FormStore {
|
|
4
|
+
form: FormSchema;
|
|
5
|
+
selection: Selection;
|
|
6
|
+
isPreviewMode: boolean;
|
|
7
|
+
currentStepIndex: number;
|
|
8
|
+
currentLanguage: string;
|
|
9
|
+
formValues: Record<string, any>;
|
|
10
|
+
canvasWidth: CanvasWidth;
|
|
11
|
+
history: FormSchema[];
|
|
12
|
+
historyIndex: number;
|
|
13
|
+
undo: () => void;
|
|
14
|
+
redo: () => void;
|
|
15
|
+
canUndo: () => boolean;
|
|
16
|
+
canRedo: () => boolean;
|
|
17
|
+
setCanvasWidth: (width: CanvasWidth) => void;
|
|
18
|
+
setFormName: (name: string) => void;
|
|
19
|
+
setFormDescription: (description: string) => void;
|
|
20
|
+
setSelection: (selection: Selection) => void;
|
|
21
|
+
clearSelection: () => void;
|
|
22
|
+
togglePreviewMode: () => void;
|
|
23
|
+
clearForm: () => void;
|
|
24
|
+
loadForm: (form: FormSchema) => void;
|
|
25
|
+
addRow: (columns?: number, stepId?: string) => void;
|
|
26
|
+
updateRow: (rowId: string, updates: Partial<FormRow>) => void;
|
|
27
|
+
deleteRow: (rowId: string) => void;
|
|
28
|
+
moveRow: (fromIndex: number, toIndex: number, stepId?: string) => void;
|
|
29
|
+
addColumn: (rowId: string) => void;
|
|
30
|
+
updateColumn: (rowId: string, columnId: string, updates: Partial<FormColumn>) => void;
|
|
31
|
+
deleteColumn: (rowId: string, columnId: string) => void;
|
|
32
|
+
duplicateColumn: (rowId: string, columnId: string) => void;
|
|
33
|
+
addField: (rowId: string, columnId: string, field: Omit<FormField, 'id'>) => void;
|
|
34
|
+
addRowWithField: (field: Omit<FormField, 'id'>) => void;
|
|
35
|
+
addFieldToContainer: (rowId: string, columnId: string, containerFieldId: string, containerRowId: string, containerColumnId: string, field: Omit<FormField, 'id'>) => void;
|
|
36
|
+
addFieldToContainerDirect: (rowId: string, columnId: string, containerFieldId: string, field: Omit<FormField, 'id'>) => void;
|
|
37
|
+
updateField: (rowId: string, columnId: string, fieldId: string, updates: Partial<FormField>) => void;
|
|
38
|
+
deleteField: (rowId: string, columnId: string, fieldId: string) => void;
|
|
39
|
+
moveField: (fromRowId: string, fromColumnId: string, fromIndex: number, toRowId: string, toColumnId: string, toIndex: number) => void;
|
|
40
|
+
addStep: () => void;
|
|
41
|
+
updateStep: (stepId: string, updates: Partial<Step>) => void;
|
|
42
|
+
deleteStep: (stepId: string) => void;
|
|
43
|
+
moveStep: (fromIndex: number, toIndex: number) => void;
|
|
44
|
+
setCurrentStep: (index: number) => void;
|
|
45
|
+
nextStep: () => void;
|
|
46
|
+
prevStep: () => void;
|
|
47
|
+
toggleMultiStep: () => void;
|
|
48
|
+
updateSubmissionConfig: (config: Partial<SubmissionConfig>) => void;
|
|
49
|
+
updateFormSettings: (settings: Partial<FormSettings>) => void;
|
|
50
|
+
setCurrentLanguage: (lang: string) => void;
|
|
51
|
+
saveVersion: (changelog?: string) => void;
|
|
52
|
+
restoreVersion: (versionId: string) => void;
|
|
53
|
+
setFieldValue: (fieldKey: string, value: any) => void;
|
|
54
|
+
getFieldValue: (fieldKey: string) => any;
|
|
55
|
+
clearFormValues: () => void;
|
|
56
|
+
getSelectedRow: () => FormRow | undefined;
|
|
57
|
+
getSelectedColumn: () => {
|
|
58
|
+
row: FormRow;
|
|
59
|
+
column: FormColumn;
|
|
60
|
+
} | undefined;
|
|
61
|
+
getSelectedField: () => {
|
|
62
|
+
row: FormRow;
|
|
63
|
+
column: FormColumn;
|
|
64
|
+
field: FormField;
|
|
65
|
+
isInsideContainer?: boolean;
|
|
66
|
+
parentContainerId?: string;
|
|
67
|
+
} | undefined;
|
|
68
|
+
getSelectedStep: () => Step | undefined;
|
|
69
|
+
getAllFields: () => FormField[];
|
|
70
|
+
getFieldByKey: (key: string) => FormField | undefined;
|
|
71
|
+
evaluateCondition: (logic: ConditionalLogic) => boolean;
|
|
72
|
+
}
|
|
73
|
+
export declare const useFormStore: import("zustand").UseBoundStore<import("zustand").StoreApi<FormStore>>;
|
|
74
|
+
export {};
|
|
75
|
+
//# sourceMappingURL=formStore.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formStore.d.ts","sourceRoot":"","sources":["../../../../../client/src/store/formStore.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,UAAU,EACV,OAAO,EACP,UAAU,EACV,SAAS,EACT,SAAS,EACT,IAAI,EACJ,gBAAgB,EAChB,gBAAgB,EAChB,YAAY,EAEb,MAAM,gBAAgB,CAAC;AAExB,KAAK,WAAW,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAC;AAE1D,UAAU,SAAS;IACjB,IAAI,EAAE,UAAU,CAAC;IACjB,SAAS,EAAE,SAAS,CAAC;IACrB,aAAa,EAAE,OAAO,CAAC;IACvB,gBAAgB,EAAE,MAAM,CAAC;IACzB,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAChC,WAAW,EAAE,WAAW,CAAC;IAEzB,OAAO,EAAE,UAAU,EAAE,CAAC;IACtB,YAAY,EAAE,MAAM,CAAC;IAErB,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,OAAO,EAAE,MAAM,OAAO,CAAC;IACvB,OAAO,EAAE,MAAM,OAAO,CAAC;IAEvB,cAAc,EAAE,CAAC,KAAK,EAAE,WAAW,KAAK,IAAI,C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CAAC;IACtD,iBAAiB,EAAE,CAAC,KAAK,EAAE,gBAAgB,KAAK,OAAO,CAAC;CACzD;AA8KD,eAAO,MAAM,YAAY,wEA+hCtB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export { FormCanvas } from '../client/src/components/form-builder/FormCanvas';
|
|
2
|
+
export { CanvasField } from '../client/src/components/form-builder/CanvasField';
|
|
3
|
+
export { PropertiesPanel } from '../client/src/components/form-builder/PropertiesPanel';
|
|
4
|
+
export { ComponentLibrary } from '../client/src/components/form-builder/ComponentLibrary';
|
|
5
|
+
export { Toolbar } from '../client/src/components/form-builder/Toolbar';
|
|
6
|
+
export { DragOverlayContent } from '../client/src/components/form-builder/DragOverlayContent';
|
|
7
|
+
export { JsonViewerModal } from '../client/src/components/form-builder/JsonViewerModal';
|
|
8
|
+
export { useFormStore } from '../client/src/store/formStore';
|
|
9
|
+
export * from '../shared/schema';
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,kDAAkD,CAAC;AAC9E,OAAO,EAAE,WAAW,EAAE,MAAM,mDAAmD,CAAC;AAChF,OAAO,EAAE,eAAe,EAAE,MAAM,uDAAuD,CAAC;AACxF,OAAO,EAAE,gBAAgB,EAAE,MAAM,wDAAwD,CAAC;AAC1F,OAAO,EAAE,OAAO,EAAE,MAAM,+CAA+C,CAAC;AACxE,OAAO,EAAE,kBAAkB,EAAE,MAAM,0DAA0D,CAAC;AAC9F,OAAO,EAAE,eAAe,EAAE,MAAM,uDAAuD,CAAC;AAExF,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAE7D,cAAc,kBAAkB,CAAC"}
|