@wix/public-editor-platform-interfaces 1.135.0 → 1.137.0
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/Bindings.d.ts +57 -7
- package/dist/Bindings.js +12 -1
- package/package.json +3 -3
package/dist/Bindings.d.ts
CHANGED
|
@@ -16,7 +16,10 @@ export interface BindingProperties {
|
|
|
16
16
|
/**
|
|
17
17
|
* @deprecated Used by the deprecated `bind` / `listBindings`. Use {@link BindingDetailsMap} instead.
|
|
18
18
|
*/
|
|
19
|
-
export type ProviderBindingsMap = Record<string, PropertyBinding
|
|
19
|
+
export type ProviderBindingsMap = Record<string, PropertyBinding & {
|
|
20
|
+
transformConfig?: TransformConfig;
|
|
21
|
+
transformType?: BindingType.ArrayTransform | BindingType.ObjectTransform;
|
|
22
|
+
}>;
|
|
20
23
|
export type PropertyBinding = MethodBinding | ProviderItemBinding;
|
|
21
24
|
export interface ProviderItemBinding {
|
|
22
25
|
bindingItemType: BindingItemType.ItemBinding;
|
|
@@ -35,15 +38,43 @@ export declare enum BindingItemType {
|
|
|
35
38
|
ItemBinding = "ItemBinding",
|
|
36
39
|
MethodBinding = "MethodBinding"
|
|
37
40
|
}
|
|
38
|
-
export type BindingArgument = ProviderItemBindingArgument | StaticArgument;
|
|
41
|
+
export type BindingArgument = ArrayItemBindingArgument | ArrayItemIndexBindingArgument | ArrayTransformBindingArgument | ObjectPropertyBindingArgument | ObjectTransformBindingArgument | ProviderItemBindingArgument | StaticArgument;
|
|
39
42
|
export interface CallOptions {
|
|
40
43
|
arguments: BindingArgument[];
|
|
41
44
|
asCallback: boolean;
|
|
42
45
|
}
|
|
43
46
|
export declare enum ArgumentType {
|
|
47
|
+
ArrayItem = "ArrayItemBinding",
|
|
48
|
+
ArrayItemIndex = "ArrayItemIndexBinding",
|
|
49
|
+
ArrayTransform = "ArrayTransformBinding",
|
|
50
|
+
ObjectProperty = "ObjectPropertyBinding",
|
|
51
|
+
ObjectTransform = "ObjectTransformBinding",
|
|
44
52
|
ProviderBinding = "ProviderBindingItem",
|
|
45
53
|
Static = "StaticArgItem"
|
|
46
54
|
}
|
|
55
|
+
export interface ArrayTransformBindingArgument {
|
|
56
|
+
source: ProviderItemBindingArgument;
|
|
57
|
+
transformConfig: TransformConfig;
|
|
58
|
+
type: ArgumentType.ArrayTransform;
|
|
59
|
+
}
|
|
60
|
+
export interface ObjectTransformBindingArgument {
|
|
61
|
+
source?: ProviderItemBindingArgument;
|
|
62
|
+
transformConfig: TransformConfig;
|
|
63
|
+
type: ArgumentType.ObjectTransform;
|
|
64
|
+
}
|
|
65
|
+
export interface ObjectPropertyBindingArgument {
|
|
66
|
+
displayName?: string;
|
|
67
|
+
propertyPath?: string;
|
|
68
|
+
type: ArgumentType.ObjectProperty;
|
|
69
|
+
}
|
|
70
|
+
export interface ArrayItemBindingArgument {
|
|
71
|
+
itemPath?: string;
|
|
72
|
+
type: ArgumentType.ArrayItem;
|
|
73
|
+
}
|
|
74
|
+
export interface ArrayItemIndexBindingArgument {
|
|
75
|
+
type: ArgumentType.ArrayItemIndex;
|
|
76
|
+
}
|
|
77
|
+
export type TransformConfig = Record<string, BindingArgument>;
|
|
47
78
|
export interface ProviderItemBindingArgument {
|
|
48
79
|
displayName?: string;
|
|
49
80
|
providerIdentifier: string;
|
|
@@ -131,15 +162,34 @@ export type BindingCandidate = {
|
|
|
131
162
|
};
|
|
132
163
|
export type BindingTargetDetails = ElementDataDefinition | FunctionParameter;
|
|
133
164
|
export type ReferencedProviders = Partial<Record<ProviderType, Record<string, Pick<Provider, 'displayName' | 'providerIdentifier' | 'providerType'>>>>;
|
|
134
|
-
|
|
135
|
-
providerType: ProviderType;
|
|
136
|
-
providerIdentifier: string;
|
|
137
|
-
providerItem: PropertyBinding;
|
|
138
|
-
providerDisplayName?: string;
|
|
165
|
+
type BaseBindingDetails = {
|
|
139
166
|
bindingDisplayName?: string;
|
|
140
167
|
bindingItemType?: DataType;
|
|
141
168
|
referencedProviders?: ReferencedProviders;
|
|
142
169
|
};
|
|
170
|
+
export declare enum BindingType {
|
|
171
|
+
ArrayTransform = "ArrayTransformBinding",
|
|
172
|
+
ObjectTransform = "ObjectTransformBinding",
|
|
173
|
+
ProviderBinding = "ProviderBindingItem"
|
|
174
|
+
}
|
|
175
|
+
export type ProviderBindingDetails = BaseBindingDetails & {
|
|
176
|
+
bindingType: BindingType.ProviderBinding;
|
|
177
|
+
providerDisplayName?: string;
|
|
178
|
+
providerIdentifier: string;
|
|
179
|
+
providerItem: PropertyBinding;
|
|
180
|
+
providerType: ProviderType;
|
|
181
|
+
};
|
|
182
|
+
export type ArrayTransformBindingDetails = BaseBindingDetails & {
|
|
183
|
+
bindingType: BindingType.ArrayTransform;
|
|
184
|
+
source: ProviderItemBindingArgument;
|
|
185
|
+
transformConfig: TransformConfig;
|
|
186
|
+
};
|
|
187
|
+
export type ObjectTransformBindingDetails = BaseBindingDetails & {
|
|
188
|
+
bindingType: BindingType.ObjectTransform;
|
|
189
|
+
source?: ProviderItemBindingArgument;
|
|
190
|
+
transformConfig: TransformConfig;
|
|
191
|
+
};
|
|
192
|
+
export type BindingDetails = ArrayTransformBindingDetails | ObjectTransformBindingDetails | ProviderBindingDetails;
|
|
143
193
|
export type BindingDetailsMap = Record<string, BindingDetails>;
|
|
144
194
|
export type SelectBindingOptions = {
|
|
145
195
|
bindingTargetDetails: BindingTargetDetails;
|
package/dist/Bindings.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ArgumentType = exports.BindingItemType = exports.UNBIND_ALL = void 0;
|
|
3
|
+
exports.BindingType = exports.ArgumentType = exports.BindingItemType = exports.UNBIND_ALL = void 0;
|
|
4
4
|
const trusted_1 = require("@wix/app-extensions/trusted");
|
|
5
5
|
exports.UNBIND_ALL = 'ALL';
|
|
6
6
|
var BindingItemType;
|
|
@@ -10,6 +10,17 @@ var BindingItemType;
|
|
|
10
10
|
})(BindingItemType || (exports.BindingItemType = BindingItemType = {}));
|
|
11
11
|
var ArgumentType;
|
|
12
12
|
(function (ArgumentType) {
|
|
13
|
+
ArgumentType["ArrayItem"] = "ArrayItemBinding";
|
|
14
|
+
ArgumentType["ArrayItemIndex"] = "ArrayItemIndexBinding";
|
|
15
|
+
ArgumentType["ArrayTransform"] = "ArrayTransformBinding";
|
|
16
|
+
ArgumentType["ObjectProperty"] = "ObjectPropertyBinding";
|
|
17
|
+
ArgumentType["ObjectTransform"] = "ObjectTransformBinding";
|
|
13
18
|
ArgumentType["ProviderBinding"] = "ProviderBindingItem";
|
|
14
19
|
ArgumentType["Static"] = "StaticArgItem";
|
|
15
20
|
})(ArgumentType || (exports.ArgumentType = ArgumentType = {}));
|
|
21
|
+
var BindingType;
|
|
22
|
+
(function (BindingType) {
|
|
23
|
+
BindingType["ArrayTransform"] = "ArrayTransformBinding";
|
|
24
|
+
BindingType["ObjectTransform"] = "ObjectTransformBinding";
|
|
25
|
+
BindingType["ProviderBinding"] = "ProviderBindingItem";
|
|
26
|
+
})(BindingType || (exports.BindingType = BindingType = {}));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/public-editor-platform-interfaces",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.137.0",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"contributors": [
|
|
6
6
|
{
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"*.{js,ts}": "yarn lint"
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@wix/app-extensions": "^1.0.
|
|
26
|
+
"@wix/app-extensions": "^1.0.200",
|
|
27
27
|
"@wix/sdk-types": "^1.17.12"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
@@ -52,5 +52,5 @@
|
|
|
52
52
|
]
|
|
53
53
|
}
|
|
54
54
|
},
|
|
55
|
-
"falconPackageHash": "
|
|
55
|
+
"falconPackageHash": "8bfba3ba5a51bb18ecfb61ad12b9e7f5d9e901cfe70b62671f0ec95f"
|
|
56
56
|
}
|