@wix/editor 1.544.0 → 1.546.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/cjs/index.js +32 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +32 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/statics/docs-ts-model.json +181 -181
- package/dist/statics/index.js +32 -1
- package/dist/statics/index.js.map +1 -1
- package/dist/types/index.d.ts +11 -1
- package/package.json +5 -5
package/dist/cjs/index.js
CHANGED
|
@@ -1523,6 +1523,10 @@ class BindingsPublicSDKShape extends BaseSDKShape {
|
|
|
1523
1523
|
this.childPath = childPath;
|
|
1524
1524
|
}
|
|
1525
1525
|
// uses the bindings map to bind component props to provider items
|
|
1526
|
+
/**
|
|
1527
|
+
* @deprecated Use {@link setBinding} instead, which takes a flat
|
|
1528
|
+
* property-name -> binding dictionary with provider details inlined.
|
|
1529
|
+
*/
|
|
1526
1530
|
async bind(bindings) {
|
|
1527
1531
|
const privateAPI = await this.getPlatformPrivateAPI();
|
|
1528
1532
|
const manifestContextId = await this.getRequiredManifestContextId();
|
|
@@ -1533,6 +1537,16 @@ class BindingsPublicSDKShape extends BaseSDKShape {
|
|
|
1533
1537
|
);
|
|
1534
1538
|
return result;
|
|
1535
1539
|
}
|
|
1540
|
+
async setBinding(bindings) {
|
|
1541
|
+
const privateAPI = await this.getPlatformPrivateAPI();
|
|
1542
|
+
const manifestContextId = await this.getRequiredManifestContextId();
|
|
1543
|
+
const result = await privateAPI.bindings.setBinding(
|
|
1544
|
+
manifestContextId,
|
|
1545
|
+
this.childPath,
|
|
1546
|
+
bindings
|
|
1547
|
+
);
|
|
1548
|
+
return result;
|
|
1549
|
+
}
|
|
1536
1550
|
// removes the bindings of specific props from the component and provider bindings map
|
|
1537
1551
|
// if props is 'ALL' - unbinds all props from the component
|
|
1538
1552
|
async unbind(props) {
|
|
@@ -1548,6 +1562,10 @@ class BindingsPublicSDKShape extends BaseSDKShape {
|
|
|
1548
1562
|
// gets the binding map for all attached providers of the editor pointer
|
|
1549
1563
|
// providerTypes: optionally filter by provider types
|
|
1550
1564
|
// includeDisplayNames: optionally add props and context items display names
|
|
1565
|
+
/**
|
|
1566
|
+
* @deprecated Use {@link getBinding} instead, which returns a flat
|
|
1567
|
+
* property-name -> binding dictionary with provider details inlined.
|
|
1568
|
+
*/
|
|
1551
1569
|
async listBindings(options) {
|
|
1552
1570
|
const privateAPI = await this.getPlatformPrivateAPI();
|
|
1553
1571
|
const manifestContextId = await this.getRequiredManifestContextId();
|
|
@@ -1558,6 +1576,19 @@ class BindingsPublicSDKShape extends BaseSDKShape {
|
|
|
1558
1576
|
);
|
|
1559
1577
|
return result;
|
|
1560
1578
|
}
|
|
1579
|
+
// gets the flat property-name -> binding map for all attached providers of the editor pointer
|
|
1580
|
+
// providerTypes: optionally filter by provider types
|
|
1581
|
+
// includeDisplayNames: optionally add context items display names
|
|
1582
|
+
async getBinding(options) {
|
|
1583
|
+
const privateAPI = await this.getPlatformPrivateAPI();
|
|
1584
|
+
const manifestContextId = await this.getRequiredManifestContextId();
|
|
1585
|
+
const result = await privateAPI.bindings.getBinding(
|
|
1586
|
+
manifestContextId,
|
|
1587
|
+
this.childPath,
|
|
1588
|
+
options
|
|
1589
|
+
);
|
|
1590
|
+
return result;
|
|
1591
|
+
}
|
|
1561
1592
|
async findBindingCandidates(bindingTargetDetails, options) {
|
|
1562
1593
|
const privateAPI = await this.getPlatformPrivateAPI();
|
|
1563
1594
|
const manifestContextId = await this.getRequiredManifestContextId();
|
|
@@ -1580,7 +1611,7 @@ class BindingsPublicSDKShape extends BaseSDKShape {
|
|
|
1580
1611
|
}
|
|
1581
1612
|
const bindingsPublicSDKShape = new PlatformSDKShape(
|
|
1582
1613
|
BindingsPublicSDKShape
|
|
1583
|
-
).withPublicMethod("bind").withPublicMethod("unbind").withPublicMethod("listBindings").withPublicMethod("findBindingCandidates").withPublicMethod("selectBinding").build();
|
|
1614
|
+
).withPublicMethod("bind").withPublicMethod("setBinding").withPublicMethod("unbind").withPublicMethod("listBindings").withPublicMethod("getBinding").withPublicMethod("findBindingCandidates").withPublicMethod("selectBinding").build();
|
|
1584
1615
|
|
|
1585
1616
|
class Workspace {
|
|
1586
1617
|
constructor(applicationContext) {
|