@weaverse/core 0.7.11 → 0.7.12

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.d.ts CHANGED
@@ -46,7 +46,6 @@ declare const isReactNative: boolean;
46
46
  declare const isBrowser: boolean;
47
47
  declare const isIframe: boolean;
48
48
 
49
- declare type TODO = any;
50
49
  interface ProjectDataType {
51
50
  items: ElementData[];
52
51
  rootId: string;
@@ -64,10 +63,10 @@ interface InitializeData {
64
63
  projectKey?: string;
65
64
  studioUrl?: string;
66
65
  }
67
- declare type BreakPoints = {
66
+ interface BreakPoints {
68
67
  mobile: string;
69
68
  desktop: string;
70
- };
69
+ }
71
70
  interface WeaverseType {
72
71
  mediaBreakPoints?: BreakPoints;
73
72
  appUrl?: string;
@@ -95,7 +94,6 @@ interface ElementCatalog {
95
94
  }
96
95
  declare type FlagType = "draggable" | "resizable" | "sortable" | "droppable" | "deletable" | "duplicable";
97
96
  declare type ElementFlags = Partial<Record<FlagType, boolean>>;
98
- declare type ToolbarAction = "duplicate" | "delete" | "copy-styles" | "paste-styles";
99
97
  interface ChildElement {
100
98
  label: string;
101
99
  selector: string;
@@ -105,6 +103,7 @@ declare type GridSize = {
105
103
  rowSpan: number;
106
104
  colSpan: number;
107
105
  };
106
+ declare type ToolbarAction = "duplicate" | "delete" | "copy-styles" | "paste-styles";
108
107
  interface ElementSchema {
109
108
  title: string;
110
109
  type: string;
@@ -135,18 +134,21 @@ interface ElementInspector {
135
134
  settings?: (AdvancedGroup | BasicGroup)[];
136
135
  styles?: (AdvancedGroup | BasicGroup)[];
137
136
  }
138
- declare type AdvancedGroup = {
139
- groupType: AdvancedInput;
140
- };
141
- declare type BasicGroup = {
137
+ interface AdvancedGroup {
138
+ groupType: AdvancedGroupType;
139
+ }
140
+ interface BasicGroup {
142
141
  groupType: "basic";
143
142
  groupHeader: string;
144
143
  inputs: BasicInput[];
145
- };
146
- declare type AdvancedInput = "border" | "alignment" | "background" | "dimensions" | "spacing" | "visibility";
144
+ }
145
+ declare type AdvancedGroupType = "border" | "alignment" | "background" | "dimensions" | "spacing" | "typography" | "visibility";
147
146
  interface BasicInput {
148
147
  type: InputType;
149
148
  label: string;
149
+ /**
150
+ * The key of the value in the element data or css
151
+ */
150
152
  name: string;
151
153
  defaultValue?: string;
152
154
  placeholder?: string;
@@ -166,6 +168,10 @@ interface BasicInput {
166
168
  min?: number;
167
169
  max?: number;
168
170
  step?: number;
171
+ /**
172
+ * For `sortable` input
173
+ */
174
+ visibleType?: boolean;
169
175
  /**
170
176
  * Only display if condition matches.
171
177
  *
@@ -183,8 +189,8 @@ interface BasicInput {
183
189
  declare type InputType = "color" | "datepicker" | "image" | "range" | "select" | "sortable" | "switch" | "text" | "textarea" | "toggle-group" | "form" | "product" | "custom.html" | "instagram";
184
190
  declare global {
185
191
  interface Window {
186
- WeaverseStudioBridge: TODO;
187
- weaverseShopifyProducts: TODO;
192
+ WeaverseStudioBridge: any;
193
+ weaverseShopifyProducts: any;
188
194
  }
189
195
  }
190
196
 
@@ -314,4 +320,4 @@ declare class Weaverse {
314
320
  initProjectItemData(): void;
315
321
  }
316
322
 
317
- export { AdvancedGroup, AdvancedInput, BasicGroup, BasicInput, BreakPoints, CatalogGroup, ChildElement, ChildElementCSS, ElementCSS, ElementCatalog, ElementData, ElementFlags, ElementInspector, ElementSchema, ElementsMap, FlagType, GridSize, InitializeData, InputType, ParentType, ProjectDataType, TODO, ToolbarAction, Weaverse, WeaverseCSSProperties, WeaverseElement, WeaverseItemStore, WeaverseType, isBrowser, isIframe, isReactNative, loadScript, stichesUtils };
323
+ export { AdvancedGroup, AdvancedGroupType, BasicGroup, BasicInput, BreakPoints, CatalogGroup, ChildElement, ChildElementCSS, ElementCSS, ElementCatalog, ElementData, ElementFlags, ElementInspector, ElementSchema, ElementsMap, FlagType, GridSize, InitializeData, InputType, ParentType, ProjectDataType, ToolbarAction, Weaverse, WeaverseCSSProperties, WeaverseElement, WeaverseItemStore, WeaverseType, isBrowser, isIframe, isReactNative, loadScript, stichesUtils };
package/dist/index.js CHANGED
File without changes
package/dist/index.mjs CHANGED
File without changes
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.7.11",
2
+ "version": "0.7.12",
3
3
  "license": "MIT",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",