@chaibuilder/sdk 2.0.0-beta.34 → 2.0.0-beta.36

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.
Files changed (36) hide show
  1. package/dist/{ChaiThemeFn--DgGggh_.js → ChaiThemeFn-BUgkaTMi.js} +1 -1
  2. package/dist/{ChaiThemeFn-bugxb1Cl.cjs → ChaiThemeFn-B_ATMTMa.cjs} +3 -3
  3. package/dist/CodeEditor-DCZWTNZX.cjs +1 -0
  4. package/dist/CodeEditor-iLT-zqjH.js +77 -0
  5. package/dist/Topbar-Bk4vqKpP.cjs +1 -0
  6. package/dist/Topbar-DMCtQiUj.js +22 -0
  7. package/dist/{context-menu-EDKTnqIV.js → context-menu-CxioWiWD.js} +1 -1
  8. package/dist/{context-menu-0lRey9QY.cjs → context-menu-t34dYg4a.cjs} +1 -1
  9. package/dist/core.cjs +4 -4
  10. package/dist/core.d.ts +13 -13
  11. package/dist/core.js +1245 -1327
  12. package/dist/{iconBase-Ief2hJUZ.js → iconBase-DHfFLkem.js} +6 -12
  13. package/dist/jsx-runtime-BYECrxsp.cjs +30 -0
  14. package/dist/{jsx-runtime-Sp0orL4X.js → jsx-runtime-DGlMoOmv.js} +241 -242
  15. package/dist/mockServiceWorker.js +39 -24
  16. package/dist/{plugin-GuIj4Ul0.js → plugin-OOaLfdkf.js} +1 -1
  17. package/dist/{plugin-4xaTkTNB.cjs → plugin-fWX0IMr4.cjs} +1 -1
  18. package/dist/render.cjs +2 -2
  19. package/dist/render.js +63 -62
  20. package/dist/style.css +1 -1
  21. package/dist/tailwind.cjs +1 -1
  22. package/dist/tailwind.js +5 -7
  23. package/dist/ui.cjs +1 -1
  24. package/dist/ui.d.ts +2 -47
  25. package/dist/ui.js +199 -356
  26. package/dist/web-blocks.cjs +2 -2
  27. package/dist/web-blocks.js +78 -81
  28. package/package.json +5 -1
  29. package/dist/CodeEditor-4lhmWkV8.js +0 -125
  30. package/dist/CodeEditor-TiCZr6Ta.cjs +0 -1
  31. package/dist/Topbar-Rar8liE-.cjs +0 -1
  32. package/dist/Topbar-iARshVmF.js +0 -72
  33. package/dist/jsx-runtime-JYMCiFoE.cjs +0 -27
  34. /package/dist/{STRINGS-BnWT5XcX.js → STRINGS-DtEft2kY.js} +0 -0
  35. /package/dist/{STRINGS-26RPxXyi.cjs → STRINGS-n7COZtKr.cjs} +0 -0
  36. /package/dist/{iconBase-aZzpqff_.cjs → iconBase-Cn2BsTrq.cjs} +0 -0
package/dist/core.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { ClassValue } from 'clsx';
2
- import i18n from 'i18next';
2
+ import { default as default_2 } from 'react';
3
+ import { default as i18n } from 'i18next';
3
4
  import { JSX as JSX_2 } from 'react/jsx-runtime';
4
5
  import * as React_2 from 'react';
5
- import { default as React_3 } from 'react';
6
6
  import { ReactNode } from 'react';
7
7
  import { registerChaiBlock } from '@chaibuilder/runtime';
8
8
  import { RESET } from 'jotai/utils';
@@ -53,7 +53,7 @@ declare type Breakpoint = {
53
53
  title: string;
54
54
  content: string;
55
55
  breakpoint: "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | string;
56
- icon: React_3.ReactNode | Element;
56
+ icon: default_2.ReactNode | Element;
57
57
  width: number;
58
58
  };
59
59
 
@@ -71,12 +71,12 @@ export declare type ChaiBlock<T = Record<string, any>> = {
71
71
  _type: string;
72
72
  } & T;
73
73
 
74
- export declare const ChaiBuilderCanvas: React_3.FC;
74
+ export declare const ChaiBuilderCanvas: default_2.FC;
75
75
 
76
76
  /**
77
77
  * ChaiBuilder is the main entry point for the Chai Builder Studio.
78
78
  */
79
- export declare const ChaiBuilderEditor: React_3.FC<ChaiBuilderEditorProps>;
79
+ export declare const ChaiBuilderEditor: default_2.FC<ChaiBuilderEditorProps>;
80
80
 
81
81
  export declare interface ChaiBuilderEditorProps {
82
82
  themePresets?: Record<string, Partial<ChaiBuilderThemeValues>>[];
@@ -99,7 +99,7 @@ export declare interface ChaiBuilderEditorProps {
99
99
  /**
100
100
  * Custom layout component
101
101
  */
102
- layout?: React_3.ComponentType;
102
+ layout?: default_2.ComponentType;
103
103
  /**
104
104
  * Layout variant. Not supported with custom layout
105
105
  */
@@ -107,7 +107,7 @@ export declare interface ChaiBuilderEditorProps {
107
107
  /**
108
108
  * Custom media Manager component
109
109
  */
110
- mediaManagerComponent?: React_3.ComponentType<{
110
+ mediaManagerComponent?: default_2.ComponentType<{
111
111
  onSelect: (url: string) => void;
112
112
  }>;
113
113
  /**
@@ -326,7 +326,7 @@ export declare const mergeClasses: (...inputs: ClassValue[]) => string;
326
326
  export declare const Outline: () => JSX_2.Element;
327
327
 
328
328
  declare type OutlineMenuItem = {
329
- item: React_3.ComponentType<{
329
+ item: default_2.ComponentType<{
330
330
  blockId: string;
331
331
  }>;
332
332
  tooltip: string | ReactNode;
@@ -345,7 +345,7 @@ declare type PageTypeItem = {
345
345
  slug?: string;
346
346
  };
347
347
 
348
- declare type ReactComponentType = React_3.ComponentType<any>;
348
+ declare type ReactComponentType = default_2.ComponentType<any>;
349
349
 
350
350
  export { registerChaiBlock }
351
351
 
@@ -446,7 +446,7 @@ export declare const useCanvasWidth: () => [number, string, Function];
446
446
  /**
447
447
  * Wrapper hook around useAtom
448
448
  */
449
- export declare const useCanvasZoom: () => [number, (args_0: number | typeof RESET | ((prev: number) => number | typeof RESET)) => void];
449
+ export declare const useCanvasZoom: () => [number, (args_0: number | RESET | ((prev: number) => number | RESET)) => void];
450
450
 
451
451
  /**
452
452
  * Custom hook to access the current state of the code editor.
@@ -455,7 +455,7 @@ export declare const useCanvasZoom: () => [number, (args_0: number | typeof RESE
455
455
  */
456
456
  export declare const useCodeEditor: () => [CodeEditorProps, never];
457
457
 
458
- export declare const useCopyBlockIds: () => [string[], (blockIds: Array<string>) => void];
458
+ export declare const useCopyBlockIds: () => [Array<string>, (blockIds: Array<string>) => void];
459
459
 
460
460
  export declare const useCopyToClipboard: () => [CopiedValue, CopyFn];
461
461
 
@@ -500,7 +500,7 @@ export declare const useLanguages: () => {
500
500
  setSelectedLang: (lang: string) => void;
501
501
  };
502
502
 
503
- export declare const useLayoutVariant: () => readonly [LayoutVariant, (args_0: LayoutVariant | typeof RESET | ((prev: LayoutVariant) => LayoutVariant | typeof RESET)) => void];
503
+ export declare const useLayoutVariant: () => readonly [LayoutVariant, (args_0: LayoutVariant | RESET | ((prev: LayoutVariant) => LayoutVariant | RESET)) => void];
504
504
 
505
505
  export declare const usePasteBlocks: () => {
506
506
  canPaste: (newParentId: string) => Promise<boolean>;
@@ -554,7 +554,7 @@ export declare const useSelectedBreakpoints: () => [string[], Function];
554
554
  */
555
555
  export declare const useSelectedStylingBlocks: () => [TStyleBlock[], (args_0: TStyleBlock[] | ((prev: TStyleBlock[]) => TStyleBlock[])) => void];
556
556
 
557
- export declare const useStylingBreakpoint: () => [string, (args_0: string | typeof RESET | ((prev: string) => string | typeof RESET)) => void];
557
+ export declare const useStylingBreakpoint: () => [string, (args_0: string | RESET | ((prev: string) => string | RESET)) => void];
558
558
 
559
559
  export declare const useStylingState: () => [unknown, (...args: unknown[]) => unknown];
560
560