@elementor/editor-variables 3.32.0-55 → 3.32.0-57
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 +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +9 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +9 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +12 -12
- package/src/components/variable-creation.tsx +2 -0
- package/src/components/variable-edit.tsx +2 -0
- package/src/components/variable-restore.tsx +2 -0
- package/src/variables-registry/create-variable-type-registry.ts +2 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elementor/editor-variables",
|
|
3
|
-
"version": "3.32.0-
|
|
3
|
+
"version": "3.32.0-57",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "Elementor Team",
|
|
6
6
|
"homepage": "https://elementor.com/",
|
|
@@ -39,18 +39,18 @@
|
|
|
39
39
|
"dev": "tsup --config=../../tsup.dev.ts"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@elementor/editor": "3.32.0-
|
|
43
|
-
"@elementor/editor-canvas": "3.32.0-
|
|
44
|
-
"@elementor/editor-controls": "3.32.0-
|
|
45
|
-
"@elementor/editor-current-user": "3.32.0-
|
|
46
|
-
"@elementor/editor-editing-panel": "3.32.0-
|
|
47
|
-
"@elementor/editor-panels": "3.32.0-
|
|
48
|
-
"@elementor/editor-props": "3.32.0-
|
|
49
|
-
"@elementor/editor-ui": "3.32.0-
|
|
50
|
-
"@elementor/editor-v1-adapters": "3.32.0-
|
|
51
|
-
"@elementor/http-client": "3.32.0-
|
|
42
|
+
"@elementor/editor": "3.32.0-57",
|
|
43
|
+
"@elementor/editor-canvas": "3.32.0-57",
|
|
44
|
+
"@elementor/editor-controls": "3.32.0-57",
|
|
45
|
+
"@elementor/editor-current-user": "3.32.0-57",
|
|
46
|
+
"@elementor/editor-editing-panel": "3.32.0-57",
|
|
47
|
+
"@elementor/editor-panels": "3.32.0-57",
|
|
48
|
+
"@elementor/editor-props": "3.32.0-57",
|
|
49
|
+
"@elementor/editor-ui": "3.32.0-57",
|
|
50
|
+
"@elementor/editor-v1-adapters": "3.32.0-57",
|
|
51
|
+
"@elementor/http-client": "3.32.0-57",
|
|
52
52
|
"@elementor/icons": "1.46.0",
|
|
53
|
-
"@elementor/schema": "3.32.0-
|
|
53
|
+
"@elementor/schema": "3.32.0-57",
|
|
54
54
|
"@elementor/ui": "1.36.8",
|
|
55
55
|
"@wordpress/i18n": "^5.13.0"
|
|
56
56
|
},
|
|
@@ -26,6 +26,7 @@ export const VariableCreation = ( { onGoBack, onClose }: Props ) => {
|
|
|
26
26
|
const { icon: VariableIcon, valueField: ValueField, variableType, propTypeUtil } = useVariableType();
|
|
27
27
|
|
|
28
28
|
const { setValue: setVariable, path } = useBoundProp( propTypeUtil );
|
|
29
|
+
const { propType } = useBoundProp();
|
|
29
30
|
|
|
30
31
|
const initialValue = useInitialValue();
|
|
31
32
|
|
|
@@ -134,6 +135,7 @@ export const VariableCreation = ( { onGoBack, onClose }: Props ) => {
|
|
|
134
135
|
setValueFieldError( '' );
|
|
135
136
|
} }
|
|
136
137
|
onValidationChange={ setValueFieldError }
|
|
138
|
+
propType={ propType }
|
|
137
139
|
/>
|
|
138
140
|
</FormField>
|
|
139
141
|
|
|
@@ -31,6 +31,7 @@ export const VariableEdit = ( { onClose, onGoBack, onSubmit, editId }: Props ) =
|
|
|
31
31
|
const { icon: VariableIcon, valueField: ValueField, variableType, propTypeUtil } = useVariableType();
|
|
32
32
|
|
|
33
33
|
const { setValue: notifyBoundPropChange, value: assignedValue } = useBoundProp( propTypeUtil );
|
|
34
|
+
const { propType } = useBoundProp();
|
|
34
35
|
const [ isMessageSuppressed, suppressMessage ] = useSuppressedMessage( EDIT_CONFIRMATION_DIALOG_ID );
|
|
35
36
|
const [ deleteConfirmation, setDeleteConfirmation ] = useState( false );
|
|
36
37
|
const [ editConfirmation, setEditConfirmation ] = useState( false );
|
|
@@ -201,6 +202,7 @@ export const VariableEdit = ( { onClose, onGoBack, onSubmit, editId }: Props ) =
|
|
|
201
202
|
setValueFieldError( '' );
|
|
202
203
|
} }
|
|
203
204
|
onValidationChange={ setValueFieldError }
|
|
205
|
+
propType={ propType }
|
|
204
206
|
/>
|
|
205
207
|
</FormField>
|
|
206
208
|
|
|
@@ -25,6 +25,7 @@ export const VariableRestore = ( { variableId, onClose, onSubmit }: Props ) => {
|
|
|
25
25
|
const { icon: VariableIcon, valueField: ValueField, variableType, propTypeUtil } = useVariableType();
|
|
26
26
|
|
|
27
27
|
const { setValue: notifyBoundPropChange } = useBoundProp( propTypeUtil );
|
|
28
|
+
const { propType } = useBoundProp();
|
|
28
29
|
|
|
29
30
|
const variable = useVariable( variableId );
|
|
30
31
|
|
|
@@ -114,6 +115,7 @@ export const VariableRestore = ( { variableId, onClose, onSubmit }: Props ) => {
|
|
|
114
115
|
setValueFieldError( '' );
|
|
115
116
|
} }
|
|
116
117
|
onValidationChange={ setValueFieldError }
|
|
118
|
+
propType={ propType }
|
|
117
119
|
/>
|
|
118
120
|
</FormField>
|
|
119
121
|
|
|
@@ -18,6 +18,7 @@ type ValueFieldProps = {
|
|
|
18
18
|
value: string;
|
|
19
19
|
onChange: ( value: string ) => void;
|
|
20
20
|
onValidationChange?: ( value: string ) => void;
|
|
21
|
+
propType?: PropType;
|
|
21
22
|
};
|
|
22
23
|
|
|
23
24
|
type FallbackPropTypeUtil = ReturnType< typeof createPropUtils >;
|
|
@@ -25,7 +26,7 @@ type FallbackPropTypeUtil = ReturnType< typeof createPropUtils >;
|
|
|
25
26
|
type VariableTypeOptions = {
|
|
26
27
|
icon: ForwardRefExoticComponent< Omit< SvgIconProps, 'ref' > & RefAttributes< SVGSVGElement > >;
|
|
27
28
|
startIcon?: ( { value }: { value: string } ) => JSX.Element;
|
|
28
|
-
valueField: ( { value, onChange, onValidationChange }: ValueFieldProps ) => JSX.Element;
|
|
29
|
+
valueField: ( { value, onChange, onValidationChange, propType }: ValueFieldProps ) => JSX.Element;
|
|
29
30
|
variableType: string;
|
|
30
31
|
fallbackPropTypeUtil: FallbackPropTypeUtil;
|
|
31
32
|
propTypeUtil: PropTypeUtil< string, string >;
|