@chaibuilder/sdk 3.1.3 → 3.1.5
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/code-display-Brl9NCVZ.cjs +11 -0
- package/dist/code-display-CX2P1oME.js +620 -0
- package/dist/{code-editor-BpQxKJGQ.js → code-editor-CCtMapeT.js} +1 -1
- package/dist/{code-editor-B5oshOO9.cjs → code-editor-DwJyCB5f.cjs} +1 -1
- package/dist/core.cjs +1 -1
- package/dist/core.d.ts +44 -25
- package/dist/core.js +93 -89
- package/dist/get-chai-builder-tailwind-config-BqaIvg8p.js +74 -0
- package/dist/get-chai-builder-tailwind-config-C6MHaUM0.cjs +1 -0
- package/dist/{index-C9p-YGGl.js → index-DHTitEQZ.js} +1913 -1569
- package/dist/index-ENH8SVib.cjs +151 -0
- package/dist/render.d.ts +2 -2
- package/dist/{rte-widget-modal-_UcsVj49.cjs → rte-widget-modal-7tiucEMf.cjs} +1 -1
- package/dist/{rte-widget-modal-BFbI7jcA.js → rte-widget-modal-BRoDWnTe.js} +1 -1
- package/dist/tailwind.cjs +1 -1
- package/dist/tailwind.js +6 -75
- package/dist/ui.d.ts +13 -13
- package/package.json +5 -4
- package/dist/index-Bcp30Thz.cjs +0 -128
package/dist/core.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-ENH8SVib.cjs"),s=require("./common-functions-BZmyleS1.cjs"),a=require("./apply-binding-CExho6DS.cjs"),i=require("react-i18next"),l=require("i18next");exports.ChaiAddBlocksDialog=e.AddBlocksDialog;exports.ChaiAddBlocksPanel=e.AddBlocksPanel;exports.ChaiAskAiUserPrompt=e.AIUserPrompt;exports.ChaiBlockAttributesEditor=e.BlockAttributesEditor;exports.ChaiBlockPropsEditor=e.BlockSettings;exports.ChaiBlockStyleEditor=e.BlockStyling;exports.ChaiBuilderCanvas=e.CanvasArea;exports.ChaiBuilderEditor=e.ChaiBuilderEditor;exports.ChaiDarkModeSwitcher=e.DarkMode;exports.ChaiDefaultBlocks=e.DefaultChaiBlocks;exports.ChaiExportCodeModal=e.ExportCodeModal;exports.ChaiImportHTML=e.ImportHTML;exports.ChaiOutline=e.ListTree;exports.ChaiScreenSizes=e.Breakpoints;exports.ChaiThemeConfigPanel=e.ThemeConfigPanel;exports.ChaiUILibrariesPanel=e.UILibrariesPanel;exports.ChaiUndoRedo=e.UndoRedo;exports.IfChaiFeatureFlag=e.IfChaiFeatureFlag;exports.PERMISSIONS=e.PERMISSIONS;exports.getClassValueAndUnit=e.getClassValueAndUnit;exports.registerBlockSettingField=e.registerBlockSettingField;exports.registerBlockSettingTemplate=e.registerBlockSettingTemplate;exports.registerBlockSettingWidget=e.registerBlockSettingWidget;exports.registerChaiAddBlockTab=e.registerChaiAddBlockTab;exports.registerChaiFeatureFlag=e.registerChaiFeatureFlag;exports.registerChaiFeatureFlags=e.registerChaiFeatureFlags;exports.registerChaiLibrary=e.registerChaiLibrary;exports.registerChaiMediaManager=e.registerChaiMediaManager;exports.registerChaiPreImportHTMLHook=e.registerChaiPreImportHTMLHook;exports.registerChaiSaveToLibrary=e.registerChaiSaveToLibrary;exports.registerChaiSidebarPanel=e.registerChaiSidebarPanel;exports.registerChaiTopBar=e.registerChaiTopBar;exports.useAddBlock=e.useAddBlock;exports.useAddClassesToBlocks=e.useAddClassesToBlocks;exports.useAskAi=e.useAskAi;exports.useBlockHighlight=e.useBlockHighlight;exports.useBlocksHtmlForAi=e.useBlocksHtmlForAi;exports.useBlocksStore=e.useBlocksStore;exports.useBlocksStoreUndoableActions=e.useBlocksStoreUndoableActions;exports.useBrandingOptions=e.useBrandingOptions;exports.useBuilderProp=e.useBuilderProp;exports.useBuilderReset=e.useBuilderReset;exports.useCanvasDisplayWidth=e.useCanvasDisplayWidth;exports.useCanvasWidth=e.useCanvasWidth;exports.useCanvasZoom=e.useCanvasZoom;exports.useChaiFeatureFlag=e.useChaiFeatureFlag;exports.useChaiFeatureFlags=e.useChaiFeatureFlags;exports.useCodeEditor=e.useCodeEditor;exports.useCopyBlockIds=e.useCopyBlocks;exports.useCopyToClipboard=e.useCopyToClipboard;exports.useCurrentPage=e.useCurrentPage;exports.useCutBlockIds=e.useCutBlockIds;exports.useDarkMode=e.useDarkMode;exports.useDuplicateBlocks=e.useDuplicateBlocks;exports.useHighlightBlockId=e.useHighlightBlockId;exports.useHtmlToBlocks=e.useHtmlToBlocks;exports.useI18nBlocks=e.useI18nBlocks;exports.useInlineEditing=e.useInlineEditing;exports.useIsPageLoaded=e.useIsPageLoaded;exports.useLanguages=e.useLanguages;exports.useLibraryBlocks=e.useLibraryBlocks;exports.useMediaManagerComponent=e.useMediaManagerComponent;exports.usePartailBlocksStore=e.usePartialBlocksStore;exports.usePartialBlocksList=e.usePartialBlocksList;exports.usePasteBlocks=e.usePasteBlocks;exports.usePermissions=e.usePermissions;exports.usePreviewMode=e.usePreviewMode;exports.usePubSub=e.usePubSub;exports.useRemoveAllClassesForBlock=e.useRemoveAllClassesForBlock;exports.useRemoveBlocks=e.useRemoveBlocks;exports.useRemoveClassesFromBlocks=e.useRemoveClassesFromBlocks;exports.useReplaceBlock=e.useReplaceBlock;exports.useResetBlockStyles=e.useResetBlockStyles;exports.useRightPanel=e.useRightPanel;exports.useSavePage=e.useSavePage;exports.useScreenSizeWidth=e.useScreenSizeWidth;exports.useSelectedBlock=e.useSelectedBlock;exports.useSelectedBlockAllClasses=e.useSelectedBlockAllClasses;exports.useSelectedBlockCurrentClasses=e.useSelectedBlockCurrentClasses;exports.useSelectedBlockIds=e.useSelectedBlockIds;exports.useSelectedBlocksDisplayChild=e.useSelectedBlocksDisplayChild;exports.useSelectedBreakpoints=e.useSelectedBreakpoints;exports.useSelectedLibrary=e.useSelectedLibrary;exports.useSelectedStylingBlocks=e.useSelectedStylingBlocks;exports.useSidebarActivePanel=e.useSidebarActivePanel;exports.useStreamMultipleBlocksProps=e.useStreamMultipleBlocksProps;exports.useStylingBreakpoint=e.useStylingBreakpoint;exports.useStylingState=e.useStylingState;exports.useTheme=e.useTheme;exports.useThemeOptions=e.useThemeOptions;exports.useToggleChaiFeatureFlag=e.useToggleChaiFeatureFlag;exports.useUndoManager=e.useUndoManager;exports.useUpdateBlocksProps=e.useUpdateBlocksProps;exports.useUpdateBlocksPropsRealtime=e.useUpdateBlocksPropsRealtime;exports.useWrapperBlock=e.useWrapperBlock;exports.generateBlockId=s.generateUUID;exports.mergeClasses=s.cn;exports.convertHTMLToChaiBlocks=a.getBlocksFromHTML;exports.getBlocksFromHTML=a.getBlocksFromHTML;Object.defineProperty(exports,"useTranslation",{enumerable:!0,get:()=>i.useTranslation});exports.i18n=l;
|
package/dist/core.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { ClassValue } from 'clsx';
|
|
|
2
2
|
import { ComponentType } from 'react';
|
|
3
3
|
import { default as default_2 } from 'react';
|
|
4
4
|
import { default as i18n } from 'i18next';
|
|
5
|
-
import { JSX
|
|
5
|
+
import { JSX } from 'react/jsx-runtime';
|
|
6
6
|
import * as React_2 from 'react';
|
|
7
7
|
import { ReactNode } from 'react';
|
|
8
8
|
import { RESET } from 'jotai/utils';
|
|
@@ -38,18 +38,20 @@ declare type Breakpoint = {
|
|
|
38
38
|
width: number;
|
|
39
39
|
};
|
|
40
40
|
|
|
41
|
-
export declare
|
|
41
|
+
export declare type BreakpointName = "xs" | "sm" | "md" | "lg" | "xl" | "2xl";
|
|
42
|
+
|
|
43
|
+
export declare const ChaiAddBlocksDialog: () => JSX.Element;
|
|
42
44
|
|
|
43
45
|
export declare const ChaiAddBlocksPanel: ({ className, showHeading, parentId, position, }: {
|
|
44
46
|
parentId?: string;
|
|
45
47
|
showHeading?: boolean;
|
|
46
48
|
className?: string;
|
|
47
49
|
position?: number;
|
|
48
|
-
}) =>
|
|
50
|
+
}) => JSX.Element;
|
|
49
51
|
|
|
50
52
|
export declare const ChaiAskAiUserPrompt: ({ blockId }: {
|
|
51
53
|
blockId: string | undefined;
|
|
52
|
-
}) =>
|
|
54
|
+
}) => JSX.Element;
|
|
53
55
|
|
|
54
56
|
declare type ChaiAsset = {
|
|
55
57
|
url: string;
|
|
@@ -79,15 +81,15 @@ declare type ChaiBlock_2<T = Record<string, any>> = {
|
|
|
79
81
|
_partialBlockId?: string;
|
|
80
82
|
} & T;
|
|
81
83
|
|
|
82
|
-
export declare const ChaiBlockAttributesEditor: React_2.MemoExoticComponent<() =>
|
|
84
|
+
export declare const ChaiBlockAttributesEditor: React_2.MemoExoticComponent<() => JSX.Element>;
|
|
83
85
|
|
|
84
86
|
/**
|
|
85
87
|
*
|
|
86
88
|
* @returns Block Setting
|
|
87
89
|
*/
|
|
88
|
-
export declare function ChaiBlockPropsEditor():
|
|
90
|
+
export declare function ChaiBlockPropsEditor(): JSX.Element;
|
|
89
91
|
|
|
90
|
-
export declare function ChaiBlockStyleEditor():
|
|
92
|
+
export declare function ChaiBlockStyleEditor(): JSX.Element;
|
|
91
93
|
|
|
92
94
|
export declare const ChaiBuilderCanvas: default_2.FC;
|
|
93
95
|
|
|
@@ -189,14 +191,6 @@ export declare interface ChaiBuilderEditorProps {
|
|
|
189
191
|
* Locale
|
|
190
192
|
*/
|
|
191
193
|
locale?: string;
|
|
192
|
-
/**
|
|
193
|
-
* Dark mode
|
|
194
|
-
*/
|
|
195
|
-
darkMode?: boolean;
|
|
196
|
-
/**
|
|
197
|
-
* Import HTML support
|
|
198
|
-
*/
|
|
199
|
-
importHTMLSupport?: boolean;
|
|
200
194
|
/**
|
|
201
195
|
* Ask AI callback
|
|
202
196
|
*/
|
|
@@ -266,7 +260,12 @@ export declare interface ChaiBuilderEditorProps {
|
|
|
266
260
|
*/
|
|
267
261
|
flags?: {
|
|
268
262
|
librarySite?: boolean;
|
|
269
|
-
|
|
263
|
+
copyPaste?: boolean;
|
|
264
|
+
exportCode?: boolean;
|
|
265
|
+
darkMode?: boolean;
|
|
266
|
+
dataBinding?: boolean;
|
|
267
|
+
importHtml?: boolean;
|
|
268
|
+
importTheme?: boolean;
|
|
270
269
|
};
|
|
271
270
|
}
|
|
272
271
|
|
|
@@ -287,13 +286,16 @@ declare type ChaiCollectoin = {
|
|
|
287
286
|
sorts?: SortOptions[];
|
|
288
287
|
};
|
|
289
288
|
|
|
290
|
-
export declare function ChaiDarkModeSwitcher():
|
|
289
|
+
export declare function ChaiDarkModeSwitcher(): JSX.Element;
|
|
291
290
|
|
|
292
|
-
export declare const ChaiDefaultBlocks: ({ parentId, position, gridCols, }: {
|
|
291
|
+
export declare const ChaiDefaultBlocks: ({ parentId, position, gridCols, disableBlockGroupsSidebar, }: {
|
|
293
292
|
parentId?: string;
|
|
294
293
|
position?: number;
|
|
295
294
|
gridCols?: string;
|
|
296
|
-
|
|
295
|
+
disableBlockGroupsSidebar?: boolean;
|
|
296
|
+
}) => JSX.Element;
|
|
297
|
+
|
|
298
|
+
export declare const ChaiExportCodeModal: () => JSX.Element;
|
|
297
299
|
|
|
298
300
|
declare type ChaiFlagOptions = {
|
|
299
301
|
key: string;
|
|
@@ -304,7 +306,7 @@ declare type ChaiFlagOptions = {
|
|
|
304
306
|
export declare const ChaiImportHTML: ({ parentId, position }: {
|
|
305
307
|
parentId?: string;
|
|
306
308
|
position?: number;
|
|
307
|
-
}) =>
|
|
309
|
+
}) => JSX.Element;
|
|
308
310
|
|
|
309
311
|
export declare type ChaiLibrary<T = Record<string, any>> = {
|
|
310
312
|
id: string;
|
|
@@ -333,13 +335,13 @@ declare type ChaiLibraryConfig<T> = {
|
|
|
333
335
|
}) => Promise<HTMLString | ChaiBlock_2[]>;
|
|
334
336
|
};
|
|
335
337
|
|
|
336
|
-
export declare const ChaiOutline: () =>
|
|
338
|
+
export declare const ChaiOutline: () => JSX.Element;
|
|
337
339
|
|
|
338
340
|
export declare const ChaiScreenSizes: ({ openDelay, canvas, tooltip, }: {
|
|
339
341
|
openDelay?: number;
|
|
340
342
|
canvas?: boolean;
|
|
341
343
|
tooltip?: boolean;
|
|
342
|
-
}) =>
|
|
344
|
+
}) => JSX.Element;
|
|
343
345
|
|
|
344
346
|
export declare interface ChaiSidebarPanel {
|
|
345
347
|
id: string;
|
|
@@ -393,9 +395,9 @@ export declare type ChaiThemeValues = {
|
|
|
393
395
|
export declare const ChaiUILibrariesPanel: ({ parentId, position }: {
|
|
394
396
|
parentId?: string;
|
|
395
397
|
position?: number;
|
|
396
|
-
}) =>
|
|
398
|
+
}) => JSX.Element;
|
|
397
399
|
|
|
398
|
-
export declare const ChaiUndoRedo: () =>
|
|
400
|
+
export declare const ChaiUndoRedo: () => JSX.Element;
|
|
399
401
|
|
|
400
402
|
declare type ClassDerivedObject = {
|
|
401
403
|
cls: string;
|
|
@@ -439,6 +441,15 @@ declare const getBlocksFromHTML: (html: string) => ChaiBlock[];
|
|
|
439
441
|
export { getBlocksFromHTML as convertHTMLToChaiBlocks }
|
|
440
442
|
export { getBlocksFromHTML }
|
|
441
443
|
|
|
444
|
+
/**
|
|
445
|
+
* Get the value and unit for a tw class
|
|
446
|
+
* @param className
|
|
447
|
+
*/
|
|
448
|
+
export declare const getClassValueAndUnit: (className: string) => {
|
|
449
|
+
unit: string;
|
|
450
|
+
value: string;
|
|
451
|
+
};
|
|
452
|
+
|
|
442
453
|
declare type HexColor = string;
|
|
443
454
|
|
|
444
455
|
declare type HSLColor = string;
|
|
@@ -461,6 +472,10 @@ declare type MediaManagerProps = {
|
|
|
461
472
|
|
|
462
473
|
export declare const mergeClasses: (...inputs: ClassValue[]) => string;
|
|
463
474
|
|
|
475
|
+
declare type Options = {
|
|
476
|
+
EXTRA_CORE_BLOCKS?: string[];
|
|
477
|
+
};
|
|
478
|
+
|
|
464
479
|
declare type PageType = {
|
|
465
480
|
key: string;
|
|
466
481
|
name: string;
|
|
@@ -566,7 +581,7 @@ export declare const useBlockHighlight: () => {
|
|
|
566
581
|
lastHighlighted: HTMLElement;
|
|
567
582
|
};
|
|
568
583
|
|
|
569
|
-
export declare const useBlocksHtmlForAi: () => () => any;
|
|
584
|
+
export declare const useBlocksHtmlForAi: () => (options?: Options) => any;
|
|
570
585
|
|
|
571
586
|
export declare const useBlocksStore: () => [any[], (args_0: any[] | ((prev: any[]) => any[])) => void];
|
|
572
587
|
|
|
@@ -593,6 +608,8 @@ export declare const useBuilderReset: () => () => void;
|
|
|
593
608
|
|
|
594
609
|
export declare const useCanvasDisplayWidth: () => readonly [number, (args_0: number | RESET | ((prev: number) => number | RESET)) => void];
|
|
595
610
|
|
|
611
|
+
export declare const useCanvasWidth: () => readonly [number, BreakpointName];
|
|
612
|
+
|
|
596
613
|
/**
|
|
597
614
|
* Wrapper hook around useAtom
|
|
598
615
|
*/
|
|
@@ -690,6 +707,8 @@ export declare const usePermissions: () => {
|
|
|
690
707
|
*/
|
|
691
708
|
export declare const usePreviewMode: () => [boolean, Function];
|
|
692
709
|
|
|
710
|
+
export declare function usePubSub<T>(eventName: string, callback: (data?: T) => void): void;
|
|
711
|
+
|
|
693
712
|
export declare const useRemoveAllClassesForBlock: () => (block: ChaiBlock, undo?: boolean) => void;
|
|
694
713
|
|
|
695
714
|
export declare const useRemoveBlocks: () => (blockIds: Array<string>) => void;
|
package/dist/core.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { j as e, A as o, f as i, k as l, B as r, e as t, C as u, i as c, D as d, l as B, I as k, L as
|
|
2
|
-
import { g as
|
|
3
|
-
import { h as
|
|
4
|
-
import { useTranslation as
|
|
5
|
-
import { default as
|
|
1
|
+
import { j as e, A as o, f as i, k as l, B as r, e as t, C as u, i as c, D as d, l as C, E as B, I as k, L as n, g, T as h, U as p, h as S, y as m, P, m as F, n as A, o as T, p as M, r as b, z as y, F as I, s as v, t as L, q as f, v as R, w as E, x as H, M as D, O as U, Q as x, R as W, S as O, V as w, aB as z, W as j, X as q, Y as G, aD as V, aC as Z, Z as J, G as K, H as N, u as Q, _ as X, $ as Y, a0 as _, a1 as $, a2 as aa, a3 as sa, a4 as ea, a5 as oa, a6 as ia, a7 as la, a8 as ra, a9 as ta, aa as ua, K as ca, ab as da, ac as Ca, ad as Ba, ae as ka, af as na, ag as ga, ah as ha, ai as pa, aj as Sa, ak as ma, al as Pa, am as Fa, an as Aa, aE as Ta, ao as Ma, ap as ba, aq as ya, a as Ia, ar as va, as as La, aF as fa, at as Ra, aG as Ea, au as Ha, av as Da, aw as Ua, ax as xa, ay as Wa, J as Oa, az as wa, b as za, c as ja, aA as qa } from "./index-DHTitEQZ.js";
|
|
2
|
+
import { g as Va, c as Za } from "./common-functions-BGzDsf1z.js";
|
|
3
|
+
import { h as Ka, h as Na } from "./apply-binding-w7OMcHcu.js";
|
|
4
|
+
import { useTranslation as Xa } from "react-i18next";
|
|
5
|
+
import { default as _a } from "i18next";
|
|
6
6
|
export {
|
|
7
7
|
e as ChaiAddBlocksDialog,
|
|
8
8
|
o as ChaiAddBlocksPanel,
|
|
@@ -13,92 +13,96 @@ export {
|
|
|
13
13
|
u as ChaiBuilderCanvas,
|
|
14
14
|
c as ChaiBuilderEditor,
|
|
15
15
|
d as ChaiDarkModeSwitcher,
|
|
16
|
-
|
|
16
|
+
C as ChaiDefaultBlocks,
|
|
17
|
+
B as ChaiExportCodeModal,
|
|
17
18
|
k as ChaiImportHTML,
|
|
18
|
-
|
|
19
|
+
n as ChaiOutline,
|
|
19
20
|
g as ChaiScreenSizes,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
T as
|
|
33
|
-
|
|
21
|
+
h as ChaiThemeConfigPanel,
|
|
22
|
+
p as ChaiUILibrariesPanel,
|
|
23
|
+
S as ChaiUndoRedo,
|
|
24
|
+
m as IfChaiFeatureFlag,
|
|
25
|
+
P as PERMISSIONS,
|
|
26
|
+
Ka as convertHTMLToChaiBlocks,
|
|
27
|
+
Va as generateBlockId,
|
|
28
|
+
Na as getBlocksFromHTML,
|
|
29
|
+
F as getClassValueAndUnit,
|
|
30
|
+
_a as i18n,
|
|
31
|
+
Za as mergeClasses,
|
|
32
|
+
A as registerBlockSettingField,
|
|
33
|
+
T as registerBlockSettingTemplate,
|
|
34
|
+
M as registerBlockSettingWidget,
|
|
35
|
+
b as registerChaiAddBlockTab,
|
|
34
36
|
y as registerChaiFeatureFlag,
|
|
35
37
|
I as registerChaiFeatureFlags,
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
Z as
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
ya as
|
|
89
|
-
Ia as
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
38
|
+
v as registerChaiLibrary,
|
|
39
|
+
L as registerChaiMediaManager,
|
|
40
|
+
f as registerChaiPreImportHTMLHook,
|
|
41
|
+
R as registerChaiSaveToLibrary,
|
|
42
|
+
E as registerChaiSidebarPanel,
|
|
43
|
+
H as registerChaiTopBar,
|
|
44
|
+
D as useAddBlock,
|
|
45
|
+
U as useAddClassesToBlocks,
|
|
46
|
+
x as useAskAi,
|
|
47
|
+
W as useBlockHighlight,
|
|
48
|
+
O as useBlocksHtmlForAi,
|
|
49
|
+
w as useBlocksStore,
|
|
50
|
+
z as useBlocksStoreUndoableActions,
|
|
51
|
+
j as useBrandingOptions,
|
|
52
|
+
q as useBuilderProp,
|
|
53
|
+
G as useBuilderReset,
|
|
54
|
+
V as useCanvasDisplayWidth,
|
|
55
|
+
Z as useCanvasWidth,
|
|
56
|
+
J as useCanvasZoom,
|
|
57
|
+
K as useChaiFeatureFlag,
|
|
58
|
+
N as useChaiFeatureFlags,
|
|
59
|
+
Q as useCodeEditor,
|
|
60
|
+
X as useCopyBlockIds,
|
|
61
|
+
Y as useCopyToClipboard,
|
|
62
|
+
_ as useCurrentPage,
|
|
63
|
+
$ as useCutBlockIds,
|
|
64
|
+
aa as useDarkMode,
|
|
65
|
+
sa as useDuplicateBlocks,
|
|
66
|
+
ea as useHighlightBlockId,
|
|
67
|
+
oa as useHtmlToBlocks,
|
|
68
|
+
ia as useI18nBlocks,
|
|
69
|
+
la as useInlineEditing,
|
|
70
|
+
ra as useIsPageLoaded,
|
|
71
|
+
ta as useLanguages,
|
|
72
|
+
ua as useLibraryBlocks,
|
|
73
|
+
ca as useMediaManagerComponent,
|
|
74
|
+
da as usePartailBlocksStore,
|
|
75
|
+
Ca as usePartialBlocksList,
|
|
76
|
+
Ba as usePasteBlocks,
|
|
77
|
+
ka as usePermissions,
|
|
78
|
+
na as usePreviewMode,
|
|
79
|
+
ga as usePubSub,
|
|
80
|
+
ha as useRemoveAllClassesForBlock,
|
|
81
|
+
pa as useRemoveBlocks,
|
|
82
|
+
Sa as useRemoveClassesFromBlocks,
|
|
83
|
+
ma as useReplaceBlock,
|
|
84
|
+
Pa as useResetBlockStyles,
|
|
85
|
+
Fa as useRightPanel,
|
|
86
|
+
Aa as useSavePage,
|
|
87
|
+
Ta as useScreenSizeWidth,
|
|
88
|
+
Ma as useSelectedBlock,
|
|
89
|
+
ba as useSelectedBlockAllClasses,
|
|
90
|
+
ya as useSelectedBlockCurrentClasses,
|
|
91
|
+
Ia as useSelectedBlockIds,
|
|
92
|
+
va as useSelectedBlocksDisplayChild,
|
|
93
|
+
La as useSelectedBreakpoints,
|
|
94
|
+
fa as useSelectedLibrary,
|
|
95
|
+
Ra as useSelectedStylingBlocks,
|
|
96
|
+
Ea as useSidebarActivePanel,
|
|
97
|
+
Ha as useStreamMultipleBlocksProps,
|
|
98
|
+
Da as useStylingBreakpoint,
|
|
99
|
+
Ua as useStylingState,
|
|
100
|
+
xa as useTheme,
|
|
101
|
+
Wa as useThemeOptions,
|
|
102
|
+
Oa as useToggleChaiFeatureFlag,
|
|
103
|
+
Xa as useTranslation,
|
|
104
|
+
wa as useUndoManager,
|
|
105
|
+
za as useUpdateBlocksProps,
|
|
106
|
+
ja as useUpdateBlocksPropsRealtime,
|
|
107
|
+
qa as useWrapperBlock
|
|
104
108
|
};
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import o from "@tailwindcss/aspect-ratio";
|
|
2
|
+
import a from "@tailwindcss/forms";
|
|
3
|
+
import e from "@tailwindcss/typography";
|
|
4
|
+
import d from "tailwindcss-animate";
|
|
5
|
+
function n() {
|
|
6
|
+
return {
|
|
7
|
+
colors: {
|
|
8
|
+
border: "hsl(var(--border))",
|
|
9
|
+
input: "hsl(var(--input))",
|
|
10
|
+
ring: "hsl(var(--ring))",
|
|
11
|
+
background: "hsl(var(--background))",
|
|
12
|
+
foreground: "hsl(var(--foreground))",
|
|
13
|
+
primary: {
|
|
14
|
+
DEFAULT: "hsl(var(--primary))",
|
|
15
|
+
foreground: "hsl(var(--primary-foreground))"
|
|
16
|
+
},
|
|
17
|
+
secondary: {
|
|
18
|
+
DEFAULT: "hsl(var(--secondary))",
|
|
19
|
+
foreground: "hsl(var(--secondary-foreground))"
|
|
20
|
+
},
|
|
21
|
+
destructive: {
|
|
22
|
+
DEFAULT: "hsl(var(--destructive))",
|
|
23
|
+
foreground: "hsl(var(--destructive-foreground))"
|
|
24
|
+
},
|
|
25
|
+
muted: {
|
|
26
|
+
DEFAULT: "hsl(var(--muted))",
|
|
27
|
+
foreground: "hsl(var(--muted-foreground))"
|
|
28
|
+
},
|
|
29
|
+
accent: {
|
|
30
|
+
DEFAULT: "hsl(var(--accent))",
|
|
31
|
+
foreground: "hsl(var(--accent-foreground))"
|
|
32
|
+
},
|
|
33
|
+
popover: {
|
|
34
|
+
DEFAULT: "hsl(var(--popover))",
|
|
35
|
+
foreground: "hsl(var(--popover-foreground))"
|
|
36
|
+
},
|
|
37
|
+
card: {
|
|
38
|
+
DEFAULT: "hsl(var(--card))",
|
|
39
|
+
foreground: "hsl(var(--card-foreground))"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
borderRadius: {
|
|
43
|
+
lg: "var(--radius)",
|
|
44
|
+
md: "calc(var(--radius) - 2px)",
|
|
45
|
+
sm: "calc(var(--radius) - 4px)"
|
|
46
|
+
},
|
|
47
|
+
keyframes: {
|
|
48
|
+
"accordion-down": {
|
|
49
|
+
from: { height: "0" },
|
|
50
|
+
to: { height: "var(--radix-accordion-content-height)" }
|
|
51
|
+
},
|
|
52
|
+
"accordion-up": {
|
|
53
|
+
from: { height: "var(--radix-accordion-content-height)" },
|
|
54
|
+
to: { height: "0" }
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
animation: {
|
|
58
|
+
"accordion-down": "accordion-down 0.2s ease-out",
|
|
59
|
+
"accordion-up": "accordion-up 0.2s ease-out"
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
const u = (r) => ({
|
|
64
|
+
darkMode: "class",
|
|
65
|
+
content: [...r, "node_modules/@chaibuilder/sdk/dist/*.{js,cjs}"],
|
|
66
|
+
theme: {
|
|
67
|
+
extend: n()
|
|
68
|
+
},
|
|
69
|
+
plugins: [d, e, a, o]
|
|
70
|
+
});
|
|
71
|
+
export {
|
|
72
|
+
u as g,
|
|
73
|
+
n as s
|
|
74
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("@tailwindcss/aspect-ratio"),a=require("@tailwindcss/forms"),n=require("@tailwindcss/typography"),d=require("tailwindcss-animate");function r(){return{colors:{border:"hsl(var(--border))",input:"hsl(var(--input))",ring:"hsl(var(--ring))",background:"hsl(var(--background))",foreground:"hsl(var(--foreground))",primary:{DEFAULT:"hsl(var(--primary))",foreground:"hsl(var(--primary-foreground))"},secondary:{DEFAULT:"hsl(var(--secondary))",foreground:"hsl(var(--secondary-foreground))"},destructive:{DEFAULT:"hsl(var(--destructive))",foreground:"hsl(var(--destructive-foreground))"},muted:{DEFAULT:"hsl(var(--muted))",foreground:"hsl(var(--muted-foreground))"},accent:{DEFAULT:"hsl(var(--accent))",foreground:"hsl(var(--accent-foreground))"},popover:{DEFAULT:"hsl(var(--popover))",foreground:"hsl(var(--popover-foreground))"},card:{DEFAULT:"hsl(var(--card))",foreground:"hsl(var(--card-foreground))"}},borderRadius:{lg:"var(--radius)",md:"calc(var(--radius) - 2px)",sm:"calc(var(--radius) - 4px)"},keyframes:{"accordion-down":{from:{height:"0"},to:{height:"var(--radix-accordion-content-height)"}},"accordion-up":{from:{height:"var(--radix-accordion-content-height)"},to:{height:"0"}}},animation:{"accordion-down":"accordion-down 0.2s ease-out","accordion-up":"accordion-up 0.2s ease-out"}}}const i=o=>({darkMode:"class",content:[...o,"node_modules/@chaibuilder/sdk/dist/*.{js,cjs}"],theme:{extend:r()},plugins:[d,n,a,e]});exports.getChaiBuilderTailwindConfig=i;exports.shadcnTheme=r;
|