@measured/puck-plugin-emotion-cache 0.19.0-canary.c79f5db8 → 0.19.0-canary.cb4b6ee5

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
@@ -14,6 +14,7 @@ type BaseField = {
14
14
  label?: string;
15
15
  labelIcon?: ReactElement;
16
16
  metadata?: Metadata;
17
+ visible?: boolean;
17
18
  };
18
19
  type TextField = BaseField & {
19
20
  type: "text";
@@ -100,16 +101,17 @@ type ExternalField<Props extends {
100
101
  filterFields?: Record<string, Field>;
101
102
  initialFilters?: Record<string, any>;
102
103
  };
103
- type CustomField<Props extends any = {}> = BaseField & {
104
+ type CustomFieldRender<Value extends any> = (props: {
105
+ field: CustomField<Value>;
106
+ name: string;
107
+ id: string;
108
+ value: Value;
109
+ onChange: (value: Value) => void;
110
+ readOnly?: boolean;
111
+ }) => ReactElement;
112
+ type CustomField<Value extends any> = BaseField & {
104
113
  type: "custom";
105
- render: (props: {
106
- field: CustomField<Props>;
107
- name: string;
108
- id: string;
109
- value: Props;
110
- onChange: (value: Props) => void;
111
- readOnly?: boolean;
112
- }) => ReactElement;
114
+ render: CustomFieldRender<Value>;
113
115
  };
114
116
  type SlotField = BaseField & {
115
117
  type: "slot";
package/dist/index.d.ts CHANGED
@@ -14,6 +14,7 @@ type BaseField = {
14
14
  label?: string;
15
15
  labelIcon?: ReactElement;
16
16
  metadata?: Metadata;
17
+ visible?: boolean;
17
18
  };
18
19
  type TextField = BaseField & {
19
20
  type: "text";
@@ -100,16 +101,17 @@ type ExternalField<Props extends {
100
101
  filterFields?: Record<string, Field>;
101
102
  initialFilters?: Record<string, any>;
102
103
  };
103
- type CustomField<Props extends any = {}> = BaseField & {
104
+ type CustomFieldRender<Value extends any> = (props: {
105
+ field: CustomField<Value>;
106
+ name: string;
107
+ id: string;
108
+ value: Value;
109
+ onChange: (value: Value) => void;
110
+ readOnly?: boolean;
111
+ }) => ReactElement;
112
+ type CustomField<Value extends any> = BaseField & {
104
113
  type: "custom";
105
- render: (props: {
106
- field: CustomField<Props>;
107
- name: string;
108
- id: string;
109
- value: Props;
110
- onChange: (value: Props) => void;
111
- readOnly?: boolean;
112
- }) => ReactElement;
114
+ render: CustomFieldRender<Value>;
113
115
  };
114
116
  type SlotField = BaseField & {
115
117
  type: "slot";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@measured/puck-plugin-emotion-cache",
3
- "version": "0.19.0-canary.c79f5db8",
3
+ "version": "0.19.0-canary.cb4b6ee5",
4
4
  "author": "Chris Villa <chris@puckeditor.com>",
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.c79f5db8",
26
+ "@measured/puck": "^0.19.0-canary.cb4b6ee5",
27
27
  "@types/react": "^19.0.1",
28
28
  "@types/react-dom": "^19.0.2",
29
29
  "eslint": "^7.32.0",