@paged-media/plugin-sdk 0.2.12-canary.0 → 0.2.13-canary.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/index.js +12 -0
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -129,6 +129,7 @@ var HOST_FEATURES = [
|
|
|
129
129
|
"document.hitTest@1",
|
|
130
130
|
"document.elementGeometry@1",
|
|
131
131
|
"document.elementProperties@1",
|
|
132
|
+
"document.placeholders@1",
|
|
132
133
|
"document.tree@1",
|
|
133
134
|
"document.onDidChange@1",
|
|
134
135
|
"document.getMetadata@1",
|
|
@@ -600,6 +601,17 @@ function createBundleHost(getEditor, manifest, options) {
|
|
|
600
601
|
requireDocRead("document.elementGeometry");
|
|
601
602
|
return getEditor().client.elementGeometry(ids);
|
|
602
603
|
},
|
|
604
|
+
async placeholders() {
|
|
605
|
+
requireDocRead("document.placeholders");
|
|
606
|
+
try {
|
|
607
|
+
const reply = await getEditor().client.send({
|
|
608
|
+
kind: "requestDocumentPlaceholders"
|
|
609
|
+
});
|
|
610
|
+
return reply.kind === "documentPlaceholders" ? reply.payload.items : [];
|
|
611
|
+
} catch {
|
|
612
|
+
return [];
|
|
613
|
+
}
|
|
614
|
+
},
|
|
603
615
|
async elementProperties(id) {
|
|
604
616
|
requireDocRead("document.elementProperties");
|
|
605
617
|
try {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@paged-media/plugin-sdk",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.13-canary.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
}
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"@paged-media/plugin-api": "0.2.
|
|
14
|
+
"@paged-media/plugin-api": "0.2.13-canary.0"
|
|
15
15
|
},
|
|
16
16
|
"peerDependencies": {
|
|
17
17
|
"react": "^18.3.0"
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
|
-
"@paged-media/canvas-wasm": "0.
|
|
25
|
+
"@paged-media/canvas-wasm": "0.43.0",
|
|
26
26
|
"@types/node": "20.19.39",
|
|
27
27
|
"@types/react": "^18.3.12",
|
|
28
28
|
"react": "^18.3.0",
|