@mandolop97/constructor-nexora 1.0.9 → 1.1.3

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 (33) hide show
  1. package/dist/NexoraBuilderApp.d.ts +9 -1
  2. package/dist/components/builder/BuilderCanvas.d.ts +8 -1
  3. package/dist/components/builder/BuilderEditorShell.d.ts +5 -1
  4. package/dist/components/builder/CustomStylesInjector.d.ts +12 -0
  5. package/dist/components/builder/GradientEditor.d.ts +6 -0
  6. package/dist/components/builder/ImageUploadField.d.ts +7 -0
  7. package/dist/components/builder/Inspector.d.ts +3 -1
  8. package/dist/components/builder/LayersPanel.d.ts +2 -1
  9. package/dist/components/builder/MediaGallery.d.ts +7 -0
  10. package/dist/components/builder/ProductPicker.d.ts +19 -0
  11. package/dist/components/schema/PageRenderer.d.ts +6 -2
  12. package/dist/components/schema/SortableNodeWrapper.d.ts +6 -1
  13. package/dist/components/schema/nodes/ContentNodes.d.ts +3 -0
  14. package/dist/components/ui/badge.d.ts +1 -1
  15. package/dist/components/ui/button.d.ts +2 -2
  16. package/dist/components/ui/command.d.ts +1 -1
  17. package/dist/components/ui/input-otp.d.ts +2 -2
  18. package/dist/components/ui/resizable.d.ts +1 -1
  19. package/dist/components/ui/sheet.d.ts +1 -1
  20. package/dist/components/ui/sidebar.d.ts +1 -1
  21. package/dist/components/ui/toggle-group.d.ts +2 -2
  22. package/dist/components/ui/toggle.d.ts +2 -2
  23. package/dist/index-CnxzP-Eg.js +18350 -0
  24. package/dist/index.css +1 -1
  25. package/dist/index.d.ts +6 -1
  26. package/dist/index.js +40 -15726
  27. package/dist/integrations/supabase/client.d.ts +78 -0
  28. package/dist/integrations/supabase/types.d.ts +78 -0
  29. package/dist/lib/block-registry.d.ts +18 -34
  30. package/dist/lib/style-utils.d.ts +16 -0
  31. package/dist/lucide-react-Bp2-WcqC.js +19114 -0
  32. package/dist/types/schema.d.ts +102 -39
  33. package/package.json +4 -2
@@ -1,6 +1,84 @@
1
1
  import type { Database } from './types';
2
2
  export declare const supabase: import("@supabase/supabase-js").SupabaseClient<Database, "public", "public", {
3
3
  Tables: {
4
+ media_files: {
5
+ Row: {
6
+ alt_text: string | null;
7
+ created_at: string;
8
+ file_name: string;
9
+ file_size: number | null;
10
+ file_type: string | null;
11
+ file_url: string;
12
+ folder: string | null;
13
+ id: string;
14
+ };
15
+ Insert: {
16
+ alt_text?: string | null;
17
+ created_at?: string;
18
+ file_name: string;
19
+ file_size?: number | null;
20
+ file_type?: string | null;
21
+ file_url: string;
22
+ folder?: string | null;
23
+ id?: string;
24
+ };
25
+ Update: {
26
+ alt_text?: string | null;
27
+ created_at?: string;
28
+ file_name?: string;
29
+ file_size?: number | null;
30
+ file_type?: string | null;
31
+ file_url?: string;
32
+ folder?: string | null;
33
+ id?: string;
34
+ };
35
+ Relationships: [];
36
+ };
37
+ products: {
38
+ Row: {
39
+ badge: string | null;
40
+ category: string | null;
41
+ created_at: string;
42
+ description: string | null;
43
+ id: string;
44
+ image_url: string | null;
45
+ in_stock: boolean | null;
46
+ name: string;
47
+ original_price: number | null;
48
+ price: number;
49
+ sku: string | null;
50
+ updated_at: string;
51
+ };
52
+ Insert: {
53
+ badge?: string | null;
54
+ category?: string | null;
55
+ created_at?: string;
56
+ description?: string | null;
57
+ id?: string;
58
+ image_url?: string | null;
59
+ in_stock?: boolean | null;
60
+ name: string;
61
+ original_price?: number | null;
62
+ price?: number;
63
+ sku?: string | null;
64
+ updated_at?: string;
65
+ };
66
+ Update: {
67
+ badge?: string | null;
68
+ category?: string | null;
69
+ created_at?: string;
70
+ description?: string | null;
71
+ id?: string;
72
+ image_url?: string | null;
73
+ in_stock?: boolean | null;
74
+ name?: string;
75
+ original_price?: number | null;
76
+ price?: number;
77
+ sku?: string | null;
78
+ updated_at?: string;
79
+ };
80
+ Relationships: [];
81
+ };
4
82
  published_pages: {
5
83
  Row: {
6
84
  content_json: import("./types").Json;
@@ -7,6 +7,84 @@ export type Database = {
7
7
  };
8
8
  public: {
9
9
  Tables: {
10
+ media_files: {
11
+ Row: {
12
+ alt_text: string | null;
13
+ created_at: string;
14
+ file_name: string;
15
+ file_size: number | null;
16
+ file_type: string | null;
17
+ file_url: string;
18
+ folder: string | null;
19
+ id: string;
20
+ };
21
+ Insert: {
22
+ alt_text?: string | null;
23
+ created_at?: string;
24
+ file_name: string;
25
+ file_size?: number | null;
26
+ file_type?: string | null;
27
+ file_url: string;
28
+ folder?: string | null;
29
+ id?: string;
30
+ };
31
+ Update: {
32
+ alt_text?: string | null;
33
+ created_at?: string;
34
+ file_name?: string;
35
+ file_size?: number | null;
36
+ file_type?: string | null;
37
+ file_url?: string;
38
+ folder?: string | null;
39
+ id?: string;
40
+ };
41
+ Relationships: [];
42
+ };
43
+ products: {
44
+ Row: {
45
+ badge: string | null;
46
+ category: string | null;
47
+ created_at: string;
48
+ description: string | null;
49
+ id: string;
50
+ image_url: string | null;
51
+ in_stock: boolean | null;
52
+ name: string;
53
+ original_price: number | null;
54
+ price: number;
55
+ sku: string | null;
56
+ updated_at: string;
57
+ };
58
+ Insert: {
59
+ badge?: string | null;
60
+ category?: string | null;
61
+ created_at?: string;
62
+ description?: string | null;
63
+ id?: string;
64
+ image_url?: string | null;
65
+ in_stock?: boolean | null;
66
+ name: string;
67
+ original_price?: number | null;
68
+ price?: number;
69
+ sku?: string | null;
70
+ updated_at?: string;
71
+ };
72
+ Update: {
73
+ badge?: string | null;
74
+ category?: string | null;
75
+ created_at?: string;
76
+ description?: string | null;
77
+ id?: string;
78
+ image_url?: string | null;
79
+ in_stock?: boolean | null;
80
+ name?: string;
81
+ original_price?: number | null;
82
+ price?: number;
83
+ sku?: string | null;
84
+ updated_at?: string;
85
+ };
86
+ Relationships: [];
87
+ };
10
88
  published_pages: {
11
89
  Row: {
12
90
  content_json: Json;
@@ -5,13 +5,29 @@ export interface InspectorFieldDef {
5
5
  key: string;
6
6
  /** Display label */
7
7
  label: string;
8
- /** Field type: text input, select dropdown, or color picker */
9
- type: 'text' | 'select' | 'color' | 'number';
8
+ /** Field type */
9
+ type: 'text' | 'select' | 'color' | 'number' | 'image' | 'toggle' | 'slider' | 'textarea' | 'link' | 'icon' | 'spacing' | 'group';
10
10
  /** Options for 'select' type */
11
11
  options?: {
12
12
  label: string;
13
13
  value: string;
14
14
  }[];
15
+ /** Min value for 'slider' and 'number' */
16
+ min?: number;
17
+ /** Max value for 'slider' and 'number' */
18
+ max?: number;
19
+ /** Step for 'slider' and 'number' */
20
+ step?: number;
21
+ /** Placeholder for 'text', 'textarea', 'link' */
22
+ placeholder?: string;
23
+ /** Rows for 'textarea' */
24
+ rows?: number;
25
+ /** Accept string for 'image' (e.g. "image/*") */
26
+ accept?: string;
27
+ /** Child fields for 'group' type */
28
+ children?: InspectorFieldDef[];
29
+ /** Default value */
30
+ defaultValue?: any;
15
31
  }
16
32
  export interface BlockDefinition {
17
33
  type: NodeType;
@@ -21,48 +37,16 @@ export interface BlockDefinition {
21
37
  canHaveChildren: boolean;
22
38
  defaultProps: NodeProps;
23
39
  defaultStyle: NodeStyle;
24
- /**
25
- * Which parent node types this block can be dropped into.
26
- * Empty array = can go anywhere (root or any container).
27
- * undefined = can go anywhere.
28
- */
29
40
  allowedParents?: NodeType[];
30
- /**
31
- * Which child node types this container accepts.
32
- * undefined = accepts anything allowed.
33
- * Only relevant for canHaveChildren=true blocks.
34
- */
35
41
  allowedChildren?: NodeType[];
36
- /**
37
- * Custom inspector fields for this block type.
38
- * When defined, these fields are rendered in the Props tab of the inspector.
39
- * Only relevant for custom/host-defined blocks.
40
- */
41
42
  inspectorFields?: InspectorFieldDef[];
42
- /**
43
- * Restrict this block to specific template types.
44
- * If undefined or empty, the block appears in all template types.
45
- */
46
43
  allowedTemplateTypes?: TemplateType[];
47
44
  }
48
45
  export declare const blockRegistry: BlockDefinition[];
49
46
  export declare function getBlockDef(type: NodeType): BlockDefinition | undefined;
50
- /**
51
- * Register a custom block definition at runtime.
52
- * It will appear in the blocks palette and support drag-and-drop.
53
- * If a block with the same type already exists it will be replaced.
54
- */
55
47
  export declare function registerBlock(def: BlockDefinition): void;
56
- /** Register multiple custom blocks at once. */
57
48
  export declare function registerBlocks(defs: BlockDefinition[]): void;
58
49
  export declare function getCategories(): string[];
59
50
  export declare function getBlocksByCategory(category: string, templateType?: TemplateType): BlockDefinition[];
60
- /** Get categories that have at least one block for the given templateType */
61
51
  export declare function getCategoriesForTemplate(templateType?: TemplateType): string[];
62
- /**
63
- * Check if a child node type can be placed inside a given parent node type.
64
- * - If child has allowedParents defined, parent must be in that list OR be the root.
65
- * - If parent has allowedChildren defined, child must be in that list.
66
- * - Otherwise, parent must be a container (canHaveChildren).
67
- */
68
52
  export declare function canDropInto(childType: NodeType, parentType: NodeType, isRoot: boolean): boolean;
@@ -0,0 +1,16 @@
1
+ import { NodeStyle } from '@/types/schema';
2
+ import React from 'react';
3
+ /**
4
+ * Convert a NodeStyle object into a valid React.CSSProperties object,
5
+ * handling virtual properties like backgroundGradient.
6
+ */
7
+ export declare function nodeStyleToCSS(style: NodeStyle): React.CSSProperties;
8
+ /**
9
+ * Generate CSS rules for hover/focus/active pseudo-states for a node.
10
+ * Returns a CSS string to inject into a <style> tag.
11
+ */
12
+ export declare function generatePseudoStateCSS(nodeId: string, style: NodeStyle): string;
13
+ /**
14
+ * Generate @container query CSS for responsive overrides.
15
+ */
16
+ export declare function generateResponsiveCSS(nodeId: string, style: NodeStyle): string;