@measured/puck-plugin-emotion-cache 0.19.0-canary.32a6f78 → 0.19.0-canary.4b545576

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.mts CHANGED
@@ -12,6 +12,8 @@ type FieldOption = {
12
12
  type FieldOptions = Array<FieldOption> | ReadonlyArray<FieldOption>;
13
13
  type BaseField = {
14
14
  label?: string;
15
+ labelIcon?: ReactElement;
16
+ metadata?: Metadata;
15
17
  };
16
18
  type TextField = BaseField & {
17
19
  type: "text";
@@ -22,6 +24,7 @@ type NumberField = BaseField & {
22
24
  placeholder?: string;
23
25
  min?: number;
24
26
  max?: number;
27
+ step?: number;
25
28
  };
26
29
  type TextareaField = BaseField & {
27
30
  type: "textarea";
@@ -108,6 +111,11 @@ type CustomField<Props extends any = {}> = BaseField & {
108
111
  readOnly?: boolean;
109
112
  }) => ReactElement;
110
113
  };
114
+ type SlotField = BaseField & {
115
+ type: "slot";
116
+ allow?: string[];
117
+ disallow?: string[];
118
+ };
111
119
  type Field<Props extends any = any> = TextField | NumberField | TextareaField | SelectField | RadioField | ArrayField<Props extends {
112
120
  [key: string]: any;
113
121
  } ? Props : any> | ObjectField<Props extends {
@@ -116,7 +124,7 @@ type Field<Props extends any = any> = TextField | NumberField | TextareaField |
116
124
  [key: string]: any;
117
125
  } ? Props : any> | ExternalFieldWithAdaptor<Props extends {
118
126
  [key: string]: any;
119
- } ? Props : any> | CustomField<Props>;
127
+ } ? Props : any> | CustomField<Props> | SlotField;
120
128
  type FieldProps<F = Field<any>, ValueType = any> = {
121
129
  field: F;
122
130
  value: ValueType;
@@ -125,6 +133,10 @@ type FieldProps<F = Field<any>, ValueType = any> = {
125
133
  readOnly?: boolean;
126
134
  };
127
135
 
136
+ type Metadata = {
137
+ [key: string]: any;
138
+ };
139
+
128
140
  type ItemWithId = {
129
141
  _arrayId: string;
130
142
  _originalIndex: number;
package/dist/index.d.ts CHANGED
@@ -12,6 +12,8 @@ type FieldOption = {
12
12
  type FieldOptions = Array<FieldOption> | ReadonlyArray<FieldOption>;
13
13
  type BaseField = {
14
14
  label?: string;
15
+ labelIcon?: ReactElement;
16
+ metadata?: Metadata;
15
17
  };
16
18
  type TextField = BaseField & {
17
19
  type: "text";
@@ -22,6 +24,7 @@ type NumberField = BaseField & {
22
24
  placeholder?: string;
23
25
  min?: number;
24
26
  max?: number;
27
+ step?: number;
25
28
  };
26
29
  type TextareaField = BaseField & {
27
30
  type: "textarea";
@@ -108,6 +111,11 @@ type CustomField<Props extends any = {}> = BaseField & {
108
111
  readOnly?: boolean;
109
112
  }) => ReactElement;
110
113
  };
114
+ type SlotField = BaseField & {
115
+ type: "slot";
116
+ allow?: string[];
117
+ disallow?: string[];
118
+ };
111
119
  type Field<Props extends any = any> = TextField | NumberField | TextareaField | SelectField | RadioField | ArrayField<Props extends {
112
120
  [key: string]: any;
113
121
  } ? Props : any> | ObjectField<Props extends {
@@ -116,7 +124,7 @@ type Field<Props extends any = any> = TextField | NumberField | TextareaField |
116
124
  [key: string]: any;
117
125
  } ? Props : any> | ExternalFieldWithAdaptor<Props extends {
118
126
  [key: string]: any;
119
- } ? Props : any> | CustomField<Props>;
127
+ } ? Props : any> | CustomField<Props> | SlotField;
120
128
  type FieldProps<F = Field<any>, ValueType = any> = {
121
129
  field: F;
122
130
  value: ValueType;
@@ -125,6 +133,10 @@ type FieldProps<F = Field<any>, ValueType = any> = {
125
133
  readOnly?: boolean;
126
134
  };
127
135
 
136
+ type Metadata = {
137
+ [key: string]: any;
138
+ };
139
+
128
140
  type ItemWithId = {
129
141
  _arrayId: string;
130
142
  _originalIndex: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@measured/puck-plugin-emotion-cache",
3
- "version": "0.19.0-canary.32a6f78",
3
+ "version": "0.19.0-canary.4b545576",
4
4
  "author": "Measured Corporation Ltd <hello@measured.co>",
5
5
  "repository": "measuredco/puck",
6
6
  "bugs": "https://github.com/measuredco/puck/issues",
@@ -23,7 +23,7 @@
23
23
  ],
24
24
  "devDependencies": {
25
25
  "@emotion/react": "^11.13.3",
26
- "@measured/puck": "^0.19.0-canary.32a6f78",
26
+ "@measured/puck": "^0.19.0-canary.4b545576",
27
27
  "@types/react": "^19.0.1",
28
28
  "@types/react-dom": "^19.0.2",
29
29
  "eslint": "^7.32.0",