@elementor/editor-variables 4.2.0-917 → 4.2.0-919
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 +10 -1
- package/dist/index.d.ts +10 -1
- package/dist/index.js +9 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +15 -15
- package/src/components/variables-selection.tsx +1 -0
- package/src/index.ts +1 -0
- package/src/utils/tracking.ts +8 -1
package/dist/index.d.mts
CHANGED
|
@@ -149,6 +149,15 @@ declare function getMenuActionsForVariable(variableType: string, context: MenuAc
|
|
|
149
149
|
|
|
150
150
|
declare const hasVariable: (key: string) => boolean;
|
|
151
151
|
|
|
152
|
+
type VariablesManagerOpenSource = 'vars-popover' | 'system-panel';
|
|
153
|
+
type VariablesManagerEventData = {
|
|
154
|
+
action: 'openManager' | 'add' | 'saveChanges' | 'delete' | 'duplicate';
|
|
155
|
+
source?: VariablesManagerOpenSource;
|
|
156
|
+
varType?: string;
|
|
157
|
+
controlPath?: string;
|
|
158
|
+
};
|
|
159
|
+
declare const trackVariablesManagerEvent: ({ action, source, varType, controlPath }: VariablesManagerEventData) => void;
|
|
160
|
+
|
|
152
161
|
declare const Utils: {
|
|
153
162
|
readonly globalVariablesLLMResolvers: {
|
|
154
163
|
'global-color-variable': (value: unknown) => {
|
|
@@ -166,4 +175,4 @@ declare const Utils: {
|
|
|
166
175
|
};
|
|
167
176
|
};
|
|
168
177
|
|
|
169
|
-
export { GLOBAL_VARIABLES_URI, type MenuActionContext, type MenuActionsFactory, Utils, type VariableManagerMenuAction, VariablesManagerPanelEmbedded, type VariablesManagerPanelEmbeddedProps, getMenuActionsForVariable, hasVariable, init, registerVariableType, registerVariableTypes, service, sizeVariablePropTypeUtil };
|
|
178
|
+
export { GLOBAL_VARIABLES_URI, type MenuActionContext, type MenuActionsFactory, Utils, type VariableManagerMenuAction, VariablesManagerPanelEmbedded, type VariablesManagerPanelEmbeddedProps, getMenuActionsForVariable, hasVariable, init, registerVariableType, registerVariableTypes, service, sizeVariablePropTypeUtil, trackVariablesManagerEvent };
|
package/dist/index.d.ts
CHANGED
|
@@ -149,6 +149,15 @@ declare function getMenuActionsForVariable(variableType: string, context: MenuAc
|
|
|
149
149
|
|
|
150
150
|
declare const hasVariable: (key: string) => boolean;
|
|
151
151
|
|
|
152
|
+
type VariablesManagerOpenSource = 'vars-popover' | 'system-panel';
|
|
153
|
+
type VariablesManagerEventData = {
|
|
154
|
+
action: 'openManager' | 'add' | 'saveChanges' | 'delete' | 'duplicate';
|
|
155
|
+
source?: VariablesManagerOpenSource;
|
|
156
|
+
varType?: string;
|
|
157
|
+
controlPath?: string;
|
|
158
|
+
};
|
|
159
|
+
declare const trackVariablesManagerEvent: ({ action, source, varType, controlPath }: VariablesManagerEventData) => void;
|
|
160
|
+
|
|
152
161
|
declare const Utils: {
|
|
153
162
|
readonly globalVariablesLLMResolvers: {
|
|
154
163
|
'global-color-variable': (value: unknown) => {
|
|
@@ -166,4 +175,4 @@ declare const Utils: {
|
|
|
166
175
|
};
|
|
167
176
|
};
|
|
168
177
|
|
|
169
|
-
export { GLOBAL_VARIABLES_URI, type MenuActionContext, type MenuActionsFactory, Utils, type VariableManagerMenuAction, VariablesManagerPanelEmbedded, type VariablesManagerPanelEmbeddedProps, getMenuActionsForVariable, hasVariable, init, registerVariableType, registerVariableTypes, service, sizeVariablePropTypeUtil };
|
|
178
|
+
export { GLOBAL_VARIABLES_URI, type MenuActionContext, type MenuActionsFactory, Utils, type VariableManagerMenuAction, VariablesManagerPanelEmbedded, type VariablesManagerPanelEmbeddedProps, getMenuActionsForVariable, hasVariable, init, registerVariableType, registerVariableTypes, service, sizeVariablePropTypeUtil, trackVariablesManagerEvent };
|
package/dist/index.js
CHANGED
|
@@ -39,7 +39,8 @@ __export(index_exports, {
|
|
|
39
39
|
registerVariableType: () => registerVariableType,
|
|
40
40
|
registerVariableTypes: () => registerVariableTypes,
|
|
41
41
|
service: () => service,
|
|
42
|
-
sizeVariablePropTypeUtil: () => sizeVariablePropTypeUtil
|
|
42
|
+
sizeVariablePropTypeUtil: () => sizeVariablePropTypeUtil,
|
|
43
|
+
trackVariablesManagerEvent: () => trackVariablesManagerEvent
|
|
43
44
|
});
|
|
44
45
|
module.exports = __toCommonJS(index_exports);
|
|
45
46
|
|
|
@@ -70,7 +71,7 @@ var trackVariableEvent = ({ varType, controlPath, action }) => {
|
|
|
70
71
|
action_type: name
|
|
71
72
|
});
|
|
72
73
|
};
|
|
73
|
-
var trackVariablesManagerEvent = ({ action, varType, controlPath }) => {
|
|
74
|
+
var trackVariablesManagerEvent = ({ action, source, varType, controlPath }) => {
|
|
74
75
|
const { dispatchEvent, config } = (0, import_events.getMixpanel)();
|
|
75
76
|
if (!config?.names?.variables?.[action]) {
|
|
76
77
|
return;
|
|
@@ -81,6 +82,9 @@ var trackVariablesManagerEvent = ({ action, varType, controlPath }) => {
|
|
|
81
82
|
trigger: config?.triggers?.click || "",
|
|
82
83
|
action_type: name
|
|
83
84
|
};
|
|
85
|
+
if (source) {
|
|
86
|
+
eventData.source = source;
|
|
87
|
+
}
|
|
84
88
|
if (varType) {
|
|
85
89
|
eventData.var_type = varType;
|
|
86
90
|
}
|
|
@@ -2987,6 +2991,7 @@ var VariablesSelection = ({ closePopover, onAdd, onEdit, onSettings, disabled =
|
|
|
2987
2991
|
onSettings();
|
|
2988
2992
|
trackVariablesManagerEvent({
|
|
2989
2993
|
action: "openManager",
|
|
2994
|
+
source: "vars-popover",
|
|
2990
2995
|
varType: variableType,
|
|
2991
2996
|
controlPath: path.join(".")
|
|
2992
2997
|
});
|
|
@@ -4607,6 +4612,7 @@ var Utils = {
|
|
|
4607
4612
|
registerVariableType,
|
|
4608
4613
|
registerVariableTypes,
|
|
4609
4614
|
service,
|
|
4610
|
-
sizeVariablePropTypeUtil
|
|
4615
|
+
sizeVariablePropTypeUtil,
|
|
4616
|
+
trackVariablesManagerEvent
|
|
4611
4617
|
});
|
|
4612
4618
|
//# sourceMappingURL=index.js.map
|