@tech_carthagos/page-builder 1.0.12 → 1.0.13

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/index.cjs.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-D4XJbhVx.cjs");exports.ApiConfigProvider=e.ApiConfigProvider;exports.DEVICE_ORDER=e.DEVICE_ORDER;exports.DeviceSizeProvider=e.DeviceSizeProvider;exports.EventDataProvider=e.EventDataProvider;exports.PageBuilder=e.PageBuilder;exports.PreviewModal=e.PreviewModal;exports.TEMPLATE_VARIABLES=e.TEMPLATE_VARIABLES;exports.getPlaceholderPaths=e.getPlaceholderPaths;exports.getResponsiveValue=e.getResponsiveValue;exports.hasTemplatePlaceholders=e.hasTemplatePlaceholders;exports.processTemplate=e.processTemplate;exports.useApiConfig=e.useApiConfig;exports.useDeviceSize=e.useDeviceSize;exports.useEventData=e.useEventData;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-GH-PwMSN.cjs");exports.ApiConfigProvider=e.ApiConfigProvider;exports.DEVICE_ORDER=e.DEVICE_ORDER;exports.DeviceSizeProvider=e.DeviceSizeProvider;exports.EventDataProvider=e.EventDataProvider;exports.PageBuilder=e.PageBuilder;exports.PreviewModal=e.PreviewModal;exports.TEMPLATE_VARIABLES=e.TEMPLATE_VARIABLES;exports.getPlaceholderPaths=e.getPlaceholderPaths;exports.getResponsiveValue=e.getResponsiveValue;exports.hasTemplatePlaceholders=e.hasTemplatePlaceholders;exports.processTemplate=e.processTemplate;exports.useApiConfig=e.useApiConfig;exports.useDeviceSize=e.useDeviceSize;exports.useEventData=e.useEventData;
package/dist/index.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { a4 as s, a8 as i, _ as r, $ as o, a2 as t, a3 as l, ac as v, ab as P, a7 as E, aa as d, a9 as p, a5 as c, a6 as D, X as g } from "./index-B9a24yCs.js";
1
+ import { a5 as s, a9 as i, $ as r, a0 as o, a3 as t, a4 as l, ad as v, ac as P, a8 as d, ab as E, aa as p, a6 as c, a7 as D, Y as g } from "./index-DWRynqVc.js";
2
2
  export {
3
3
  s as ApiConfigProvider,
4
4
  i as DEVICE_ORDER,
@@ -8,8 +8,8 @@ export {
8
8
  l as PreviewModal,
9
9
  v as TEMPLATE_VARIABLES,
10
10
  P as getPlaceholderPaths,
11
- E as getResponsiveValue,
12
- d as hasTemplatePlaceholders,
11
+ d as getResponsiveValue,
12
+ E as hasTemplatePlaceholders,
13
13
  p as processTemplate,
14
14
  c as useApiConfig,
15
15
  D as useDeviceSize,
@@ -2,7 +2,7 @@ import { VariantProps } from 'class-variance-authority';
2
2
  import * as React from "react";
3
3
  declare const buttonVariants: (props?: ({
4
4
  variant?: "default" | "link" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
5
- size?: "default" | "icon" | "sm" | "lg" | "xl" | null | undefined;
5
+ size?: "default" | "sm" | "lg" | "xl" | "icon" | null | undefined;
6
6
  } & import('class-variance-authority/types').ClassProp) | undefined) => string;
7
7
  export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
8
8
  asChild?: boolean;
@@ -1,25 +1,48 @@
1
1
  import { Node } from '@craftjs/core';
2
- import { ReactNode, HTMLAttributes } from 'react';
2
+ import { DivProps } from './Div';
3
3
 
4
4
  export declare const Container: {
5
- ({ children, className }: {
6
- children?: React.ReactNode;
7
- className?: string;
8
- }): import("react/jsx-runtime").JSX.Element;
5
+ ({ className, backgroundColor, backgroundImage, backgroundSize, backgroundRepeat, padding, margin, width, minHeight, maxWidth, display, flexDirection, justifyContent, alignItems, gap, borderRadius, borderWidth, borderColor, borderStyle, boxShadow, children, }: DivProps): import("react/jsx-runtime").JSX.Element;
9
6
  craft: {
10
7
  isCanvas: boolean;
11
- props: {};
8
+ props: {
9
+ backgroundColor: string;
10
+ backgroundImage: string;
11
+ backgroundSize: string;
12
+ backgroundRepeat: string;
13
+ padding: {
14
+ top: number;
15
+ right: number;
16
+ bottom: number;
17
+ left: number;
18
+ };
19
+ margin: {
20
+ top: number;
21
+ right: number;
22
+ bottom: number;
23
+ left: number;
24
+ };
25
+ width: string;
26
+ minHeight: number;
27
+ maxWidth: string;
28
+ display: string;
29
+ flexDirection: string;
30
+ justifyContent: string;
31
+ alignItems: string;
32
+ gap: number;
33
+ borderRadius: number;
34
+ borderWidth: number;
35
+ borderColor: string;
36
+ borderStyle: string;
37
+ boxShadow: string;
38
+ };
12
39
  displayName: string;
40
+ related: {
41
+ settings: () => import("react/jsx-runtime").JSX.Element;
42
+ };
13
43
  rules: {
14
44
  canMoveIn: (incomingNodes: Node[]) => boolean;
15
45
  };
16
46
  };
17
47
  };
18
- type SectionProps = {
19
- children: ReactNode;
20
- addMarginBottom?: boolean;
21
- maxWidth?: string;
22
- } & HTMLAttributes<HTMLDivElement>;
23
- export declare const Section: ({ children, className, addMarginBottom, maxWidth, style, ...restProps }: SectionProps) => import("react/jsx-runtime").JSX.Element;
24
- export {};
25
48
  //# sourceMappingURL=Container.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Container.d.ts","sourceRoot":"","sources":["../../src/user/Container.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAW,MAAM,eAAe,CAAC;AAG9C,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAEvD,eAAO,MAAM,SAAS;8BAA6B;QAAE,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;QAAC,SAAS,CAAC,EAAC,MAAM,CAAA;KAAE;;;;;;uCA4BrE,IAAI,EAAE;;;CARpC,CAAC;AAcF,KAAK,YAAY,GAAG;IAClB,QAAQ,EAAE,SAAS,CAAC;IACpB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAEnC,eAAO,MAAM,OAAO,GAAI,yEAOrB,YAAY,4CAYd,CAAC"}
1
+ {"version":3,"file":"Container.d.ts","sourceRoot":"","sources":["../../src/user/Container.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAW,MAAM,eAAe,CAAC;AAE9C,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAIjC,eAAO,MAAM,SAAS;yQAsBnB,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uCA+EoB,IAAI,EAAE;;;CA5BpC,CAAC"}
@@ -1,5 +1,8 @@
1
- export function Container({ background, padding, margin, width, minHeight, maxWidth, display, flexDirection, justifyContent, alignItems, gap, borderRadius, borderWidth, borderColor, borderStyle, boxShadow, children }: {
2
- background?: string | undefined;
1
+ export function Container({ backgroundColor, backgroundImage, backgroundSize, backgroundRepeat, padding, margin, width, minHeight, maxWidth, display, flexDirection, justifyContent, alignItems, gap, borderRadius, borderWidth, borderColor, borderStyle, boxShadow, children, }: {
2
+ backgroundColor?: string | undefined;
3
+ backgroundImage?: string | undefined;
4
+ backgroundSize?: string | undefined;
5
+ backgroundRepeat?: string | undefined;
3
6
  padding?: {
4
7
  top: number;
5
8
  right: number;
@@ -31,7 +34,10 @@ export namespace Container {
31
34
  namespace craft {
32
35
  let displayName: string;
33
36
  namespace props {
34
- let background: string;
37
+ let backgroundColor: string;
38
+ let backgroundImage: string;
39
+ let backgroundSize: string;
40
+ let backgroundRepeat: string;
35
41
  namespace padding {
36
42
  let top: number;
37
43
  let right: number;
@@ -67,6 +73,5 @@ export namespace Container {
67
73
  }
68
74
  }
69
75
  }
70
- declare function ContainerSettings(): import("react/jsx-runtime").JSX.Element;
71
- export {};
76
+ export function ContainerSettings(): import("react/jsx-runtime").JSX.Element;
72
77
  //# sourceMappingURL=ContainerOld.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ContainerOld.d.ts","sourceRoot":"","sources":["../../src/user/ContainerOld.jsx"],"names":[],"mappings":"AAaO;;;;;;;;;;;;;;;;;;;;;;;;;;;;4CAyDN;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAED,8EAuCC"}
1
+ {"version":3,"file":"ContainerOld.d.ts","sourceRoot":"","sources":["../../src/user/ContainerOld.jsx"],"names":[],"mappings":"AAaO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4CAuEN;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEM,6EA2IN"}
@@ -1,19 +1,77 @@
1
- import { ReactElement } from 'react';
1
+ import { JSXElementConstructor, ReactElement, ReactNode, ReactPortal } from 'react';
2
2
 
3
- type DivProps = {
4
- className: string;
5
- children?: ReactElement;
6
- style?: Record<string, string>;
3
+ export type DivProps = {
4
+ className?: string;
5
+ backgroundColor?: string;
6
+ backgroundImage?: string;
7
+ backgroundSize?: string;
8
+ backgroundRepeat?: string;
9
+ padding?: number | {
10
+ top: number;
11
+ right: number;
12
+ bottom: number;
13
+ left: number;
14
+ };
15
+ margin?: number | {
16
+ top: number;
17
+ right: number;
18
+ bottom: number;
19
+ left: number;
20
+ };
21
+ width?: string;
22
+ minHeight?: number;
23
+ maxWidth?: string;
24
+ display?: string;
25
+ flexDirection?: "row" | "column" | "row-reverse" | "column-reverse";
26
+ justifyContent?: string;
27
+ alignItems?: string;
28
+ gap?: number;
29
+ borderRadius?: number;
30
+ borderWidth?: number;
31
+ borderColor?: string;
32
+ borderStyle?: string;
33
+ boxShadow?: string;
34
+ children?: ((string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal | ReactNode[]) & (string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal)) | null | undefined;
7
35
  };
8
36
  export declare const Div: {
9
- ({ className, style, children }: DivProps): import("react/jsx-runtime").JSX.Element;
37
+ ({ className, backgroundColor, backgroundImage, backgroundSize, backgroundRepeat, padding, margin, width, minHeight, maxWidth, display, flexDirection, justifyContent, alignItems, gap, borderRadius, borderWidth, borderColor, borderStyle, boxShadow, children, }: DivProps): import("react/jsx-runtime").JSX.Element;
10
38
  craft: {
11
39
  isCanvas: boolean;
12
40
  props: {
13
41
  ClassNames: string;
14
- style: {};
42
+ backgroundColor: string;
43
+ backgroundImage: string;
44
+ backgroundSize: string;
45
+ backgroundRepeat: string;
46
+ padding: {
47
+ top: number;
48
+ right: number;
49
+ bottom: number;
50
+ left: number;
51
+ };
52
+ margin: {
53
+ top: number;
54
+ right: number;
55
+ bottom: number;
56
+ left: number;
57
+ };
58
+ width: string;
59
+ minHeight: number;
60
+ maxWidth: string;
61
+ display: string;
62
+ flexDirection: string;
63
+ justifyContent: string;
64
+ alignItems: string;
65
+ gap: number;
66
+ borderRadius: number;
67
+ borderWidth: number;
68
+ borderColor: string;
69
+ borderStyle: string;
70
+ boxShadow: string;
71
+ };
72
+ related: {
73
+ settings: () => import("react/jsx-runtime").JSX.Element;
15
74
  };
16
75
  };
17
76
  };
18
- export {};
19
77
  //# sourceMappingURL=Div.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Div.d.ts","sourceRoot":"","sources":["../../src/user/Div.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AACrC,KAAK,QAAQ,GAAG;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CAC/B,CAAC;AAEF,eAAO,MAAM,GAAG;qCAAoC,QAAQ;;;;;;;;CAiB3D,CAAC"}
1
+ {"version":3,"file":"Div.d.ts","sourceRoot":"","sources":["../../src/user/Div.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,qBAAqB,EACrB,YAAY,EACZ,SAAS,EACT,WAAW,EACZ,MAAM,OAAO,CAAC;AAEf,MAAM,MAAM,Q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,CACd,GACC,CACI,MAAM,GACN,MAAM,GACN,OAAO,GACP,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,qBAAqB,CAAC,GAAG,CAAC,CAAC,GACtD,QAAQ,CAAC,SAAS,CAAC,GACnB,WAAW,CACd,CAAC,GACJ,IAAI,GACJ,SAAS,CAAC;CACf,CAAC;AAEF,eAAO,MAAM,GAAG;yQAsBb,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgDV,CAAC"}
@@ -1,7 +1,7 @@
1
- import { HTMLAttributes, ReactNode } from 'react';
1
+ import { HTMLAttributes, JSXElementConstructor, ReactElement, ReactNode, ReactPortal } from 'react';
2
2
 
3
3
  type SectionProps = {
4
- children?: ReactNode;
4
+ children?: ((string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal | ReactNode[]) & (string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal)) | null | undefined;
5
5
  } & HTMLAttributes<HTMLDivElement>;
6
6
  export declare const Section: {
7
7
  ({ children, className }: SectionProps): import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"Section.d.ts","sourceRoot":"","sources":["../../src/user/Section.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAOlD,KAAK,YAAY,GAAG;IAClB,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAEnC,eAAO,MAAM,OAAO;8BAA6B,YAAY;;;;;;;;CAmC5D,CAAC"}
1
+ {"version":3,"file":"Section.d.ts","sourceRoot":"","sources":["../../src/user/Section.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,qBAAqB,EACrB,YAAY,EACZ,SAAS,EACT,WAAW,EACZ,MAAM,OAAO,CAAC;AAOf,KAAK,YAAY,GAAG;IAClB,QAAQ,CAAC,EACL,CAAC,CACG,MAAM,GACN,MAAM,GACN,OAAO,GACP,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,qBAAqB,CAAC,GAAG,CAAC,CAAC,GACtD,QAAQ,CAAC,SAAS,CAAC,GACnB,WAAW,GACX,SAAS,EAAE,CACd,GACC,CACI,MAAM,GACN,MAAM,GACN,OAAO,GACP,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,qBAAqB,CAAC,GAAG,CAAC,CAAC,GACtD,QAAQ,CAAC,SAAS,CAAC,GACnB,WAAW,CACd,CAAC,GACJ,IAAI,GACJ,SAAS,CAAC;CACf,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAEnC,eAAO,MAAM,OAAO;8BAA6B,YAAY;;;;;;;;CAkC5D,CAAC"}
@@ -1,18 +1,48 @@
1
1
  import { Node } from '@craftjs/core';
2
- import { ReactNode, HTMLAttributes } from 'react';
2
+ import { DivProps } from './Div';
3
3
 
4
- type WrapperProps = {
5
- children?: ReactNode;
6
- } & HTMLAttributes<HTMLDivElement>;
7
4
  export declare const Wrapper: {
8
- ({ children, className, ...restProps }: WrapperProps): import("react/jsx-runtime").JSX.Element;
5
+ ({ className, backgroundColor, backgroundImage, backgroundSize, backgroundRepeat, padding, margin, width, minHeight, maxWidth, display, flexDirection, justifyContent, alignItems, gap, borderRadius, borderWidth, borderColor, borderStyle, boxShadow, children, }: DivProps): import("react/jsx-runtime").JSX.Element;
9
6
  craft: {
10
- props: {};
7
+ props: {
8
+ backgroundColor: string;
9
+ backgroundImage: string;
10
+ backgroundSize: string;
11
+ backgroundRepeat: string;
12
+ padding: {
13
+ top: number;
14
+ right: number;
15
+ bottom: number;
16
+ left: number;
17
+ };
18
+ margin: {
19
+ top: number;
20
+ right: number;
21
+ bottom: number;
22
+ left: number;
23
+ };
24
+ width: string;
25
+ minHeight: number;
26
+ maxWidth: string;
27
+ display: string;
28
+ flexDirection: string;
29
+ justifyContent: string;
30
+ alignItems: string;
31
+ gap: number;
32
+ borderRadius: number;
33
+ borderWidth: number;
34
+ borderColor: string;
35
+ borderStyle: string;
36
+ boxShadow: string;
37
+ };
11
38
  displayName: string;
12
39
  isCanvas: boolean;
13
40
  rules: {
14
41
  canMoveIn: (incomingNodes: Node[]) => boolean;
15
42
  };
43
+ related: {
44
+ settings: () => import("react/jsx-runtime").JSX.Element;
45
+ };
16
46
  };
17
47
  };
18
48
  export default Wrapper;
@@ -1 +1 @@
1
- {"version":3,"file":"Wrapper.d.ts","sourceRoot":"","sources":["../../src/user/Wrapper.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAW,MAAM,eAAe,CAAC;AAG9C,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAEvD,KAAK,YAAY,GAAG;IAClB,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAEnC,eAAO,MAAM,OAAO;4CAIjB,YAAY;;;;;;uCA6BgB,IAAI,EAAE;;;CAPpC,CAAC;AAeF,eAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"Wrapper.d.ts","sourceRoot":"","sources":["../../src/user/Wrapper.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAW,MAAM,eAAe,CAAC;AAG9C,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAGjC,eAAO,MAAM,OAAO;yQAsBjB,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uCA8EoB,IAAI,EAAE;;;;;;CA3BpC,CAAC;AAoCF,eAAe,OAAO,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tech_carthagos/page-builder",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs.js",
6
6
  "module": "./dist/index.es.js",