@embedpdf/plugin-annotation 3.0.0-next.10 → 3.0.0-next.11
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/authoring-BhtyfsMx.d.cts +37 -0
- package/dist/authoring-R4ezdnXd.d.ts +37 -0
- package/dist/authoring.cjs +16 -0
- package/dist/authoring.d.cts +2 -0
- package/dist/authoring.d.ts +2 -0
- package/dist/authoring.js +3 -0
- package/dist/{capability-Cl9x8oLS.cjs → capability-Csb9WMm-.cjs} +256 -348
- package/dist/capability-Csb9WMm-.cjs.map +1 -0
- package/dist/{capability-BRf0HrOi.js → capability-DBsr2D-L.js} +191 -259
- package/dist/capability-DBsr2D-L.js.map +1 -0
- package/dist/contract/host.cjs +3 -0
- package/dist/contract/host.d.cts +2 -0
- package/dist/contract/host.d.ts +2 -0
- package/dist/contract/host.js +2 -0
- package/dist/contract.cjs +8 -0
- package/dist/contract.cjs.map +1 -0
- package/dist/contract.d.cts +10 -0
- package/dist/contract.d.ts +10 -0
- package/dist/contract.js +8 -0
- package/dist/contract.js.map +1 -0
- package/dist/index.cjs +22 -23
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -46
- package/dist/index.d.ts +4 -46
- package/dist/index.js +12 -13
- package/dist/index.js.map +1 -1
- package/dist/internal.cjs +4 -2
- package/dist/internal.d.cts +2 -1
- package/dist/internal.d.ts +2 -1
- package/dist/internal.js +3 -1
- package/dist/seam-6pJeKOOJ.cjs +296 -0
- package/dist/seam-6pJeKOOJ.cjs.map +1 -0
- package/dist/seam-C4L_7rDt.js +225 -0
- package/dist/seam-C4L_7rDt.js.map +1 -0
- package/dist/types-CwytT-TI.js +13 -0
- package/dist/types-CwytT-TI.js.map +1 -0
- package/dist/types-DimcLIic.cjs +17 -0
- package/dist/types-DimcLIic.cjs.map +1 -0
- package/dist/{types-Due7UgzE.d.cts → types-eLTpocXz.d.cts} +37 -9
- package/dist/{types-DITX_3CG.d.ts → types-otwv-Cdl.d.ts} +36 -8
- package/package.json +21 -7
- package/dist/capability-BRf0HrOi.js.map +0 -1
- package/dist/capability-Cl9x8oLS.cjs.map +0 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { DocumentEvent, PageObjectNumber } from "@embedpdf/core";
|
|
2
|
-
import {
|
|
2
|
+
import { AnnotCommitEntry, AnnotCommitResult } from "@embedpdf/plugin-actions/contract/host";
|
|
3
|
+
import { AnnotationAppearanceImage, AnnotationDTO, AnnotationDraft, AnnotationPatch, AnnotationRef, AttachmentContent, AttachmentFileSource, BinarySource, CommentThread, InkIntent, PdfActionTree, PdfLinkTarget, PdfRect } from "@embedpdf/engine-core/runtime";
|
|
3
4
|
import { AnnotationFlags, AnnotationProps, AnnotationPropsPatch, ChromeNode, ClickCreate, CreationDraftAnchor, Geom, Id, InkStraightenOptions, Model, PropKey, PropSpec, Rect, RenderItem, SnapSettings, Subtype, TextEndAnchor, TextQuad, Vec, ViewEnv } from "@embedpdf/core-annotation";
|
|
4
5
|
import { PageRotation } from "@embedpdf/core-geometry";
|
|
5
6
|
//#region src/tools.d.ts
|
|
@@ -429,6 +430,19 @@ interface LinkNavItem {
|
|
|
429
430
|
* stays selectable/movable; standalone document links navigate regardless.
|
|
430
431
|
*/
|
|
431
432
|
attached: boolean;
|
|
433
|
+
/** The full payload-carrying `/A` tree, when one exists — the action
|
|
434
|
+
* engine's dispatch input. `target` remains its root projection. */
|
|
435
|
+
activate?: PdfActionTree;
|
|
436
|
+
/** The annotation ref, carried for ActionSource context. */
|
|
437
|
+
ref?: AnnotationRef;
|
|
438
|
+
/** Which `/AA` hover trees this link carries — the nav layer's pump flags
|
|
439
|
+
* (tree-less hover must cost zero dispatches). Links are behavior-inert
|
|
440
|
+
* to the annotation plane's hover feed while navigable, so THEIR
|
|
441
|
+
* cursorEnter/cursorExit can only fire from the LinkLayer anchors. */
|
|
442
|
+
hoverEvents?: {
|
|
443
|
+
enter: boolean;
|
|
444
|
+
exit: boolean;
|
|
445
|
+
};
|
|
432
446
|
}
|
|
433
447
|
interface Behavior {
|
|
434
448
|
id: string;
|
|
@@ -490,8 +504,9 @@ interface TextItem {
|
|
|
490
504
|
* package root (`@embedpdf/plugin-annotation`).
|
|
491
505
|
*
|
|
492
506
|
* Framework-only plumbing (render projection, pointer gestures, behavior
|
|
493
|
-
* registration) lives on {@link AnnotationHostCapability}, reachable
|
|
494
|
-
*
|
|
507
|
+
* registration) lives on {@link AnnotationHostCapability}, reachable through
|
|
508
|
+
* `@embedpdf/plugin-annotation/contract/host` (and the framework's `/internal`
|
|
509
|
+
* entry). Both are the SAME runtime
|
|
495
510
|
* object — two typed lenses on one token — so app code simply can't see the host
|
|
496
511
|
* methods.
|
|
497
512
|
*/
|
|
@@ -818,8 +833,9 @@ type FilePickerProvider = (req: FilePromptRequest) => Promise<AttachmentFileSour
|
|
|
818
833
|
/**
|
|
819
834
|
* The HOST (framework) surface: everything the render layer, the interaction hub,
|
|
820
835
|
* and sibling plugins need, on top of the public {@link AnnotationCapability}.
|
|
821
|
-
*
|
|
822
|
-
*
|
|
836
|
+
* Host-only — sibling plugins import the token from
|
|
837
|
+
* `@embedpdf/plugin-annotation/contract/host`; framework implementation code may
|
|
838
|
+
* use `/internal`. Never use either from application code.
|
|
823
839
|
*/
|
|
824
840
|
interface AnnotationHostCapability extends AnnotationCapability {
|
|
825
841
|
/** `view` (the page's scale + total display rotation, from its transform)
|
|
@@ -1046,13 +1062,25 @@ interface AnnotationHostCapability extends AnnotationCapability {
|
|
|
1046
1062
|
* gesture and the created annotation's PDF kind. Falls back to the id. */
|
|
1047
1063
|
toolSubtype(id: string): Subtype;
|
|
1048
1064
|
registerBehavior(b: Behavior): () => void;
|
|
1065
|
+
/**
|
|
1066
|
+
* The actions plane's session-visibility write (Hide actions, script
|
|
1067
|
+
* `annot.hidden`): resolve annotation OBJECT NUMBERS to loaded model ids
|
|
1068
|
+
* (the `obj:` refKey seam) and merge session-hidden overrides. Returns how
|
|
1069
|
+
* many resolved — unresolved numbers (unloaded pages, nm/index refs) are
|
|
1070
|
+
* the caller's diagnostics. Session state only; never an engine write.
|
|
1071
|
+
*/
|
|
1072
|
+
/** The script/Hide DOCUMENT-commit door (full ISO): engine updates +
|
|
1073
|
+
* model reconciliation, per entry, stop-on-failure. Never enqueues,
|
|
1074
|
+
* never touches the script host — the D2 sink contract. */
|
|
1075
|
+
commitScriptEffects(entries: AnnotCommitEntry[]): Promise<AnnotCommitResult>;
|
|
1049
1076
|
}
|
|
1050
1077
|
/**
|
|
1051
1078
|
* The annotation capability token. Typed to the full {@link AnnotationHostCapability}
|
|
1052
|
-
* here (the package internals
|
|
1053
|
-
* root re-exports the SAME token narrowed to
|
|
1079
|
+
* here (the package internals, `/contract/host`, and `/internal` use this view).
|
|
1080
|
+
* The package root re-exports the SAME token narrowed to
|
|
1081
|
+
* {@link AnnotationCapability}.
|
|
1054
1082
|
*/
|
|
1055
1083
|
declare const AnnotationToken: import("@embedpdf/core").CapabilityToken<AnnotationHostCapability>;
|
|
1056
1084
|
//#endregion
|
|
1057
1085
|
export { StampSourceSpec as A, AnnotationToolInput as C, PromptSourceSpec as D, InkAuthoringOptions as E, ToolDefaultsFor as M, buildToolRegistry as N, ResolvedTool as O, AnnotationToolDef as S, GhostPolicy as T, SelectionProps as _, AnnotationHydration as a, ThreadDeleteResult as b, Behavior as c, CommentPermissions as d, CommentsApi as f, SelectionFlags as g, LinkNavItem as h, AnnotationHostCapability as i, ToolAuthoringKind as j, SelectionAuthoring as k, ChromeSettings as l, FilePromptRequest as m, AnnotationCapability as n, AnnotationState as o, FilePickerProvider as p, AnnotationConfig as r, AnnotationToken as s, AnnotationAction as t, ChromeSettingsPatch as u, StampToolInput as v, DEFAULT_TOOLS as w, ToolGhost as x, TextItem as y };
|
|
1058
|
-
//# sourceMappingURL=types-
|
|
1086
|
+
//# sourceMappingURL=types-otwv-Cdl.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@embedpdf/plugin-annotation",
|
|
3
|
-
"version": "3.0.0-next.
|
|
3
|
+
"version": "3.0.0-next.11",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Annotation feature plugin: the pure annotation-core wired to the engine repository (optimistic create/patch/delete) + the interaction hub (ambient edit + draw tools). Behaviors (forms) plug in here.",
|
|
6
6
|
"type": "module",
|
|
@@ -12,6 +12,18 @@
|
|
|
12
12
|
"import": "./dist/index.js",
|
|
13
13
|
"require": "./dist/index.cjs"
|
|
14
14
|
},
|
|
15
|
+
"./authoring": {
|
|
16
|
+
"import": "./dist/authoring.js",
|
|
17
|
+
"require": "./dist/authoring.cjs"
|
|
18
|
+
},
|
|
19
|
+
"./contract": {
|
|
20
|
+
"import": "./dist/contract.js",
|
|
21
|
+
"require": "./dist/contract.cjs"
|
|
22
|
+
},
|
|
23
|
+
"./contract/host": {
|
|
24
|
+
"import": "./dist/contract/host.js",
|
|
25
|
+
"require": "./dist/contract/host.cjs"
|
|
26
|
+
},
|
|
15
27
|
"./internal": {
|
|
16
28
|
"import": "./dist/internal.js",
|
|
17
29
|
"require": "./dist/internal.cjs"
|
|
@@ -22,12 +34,14 @@
|
|
|
22
34
|
"dist"
|
|
23
35
|
],
|
|
24
36
|
"dependencies": {
|
|
25
|
-
"@embedpdf/core-annotation": "3.0.0-next.
|
|
26
|
-
"@embedpdf/core": "3.0.0-next.
|
|
27
|
-
"@embedpdf/core
|
|
28
|
-
"@embedpdf/plugin-
|
|
29
|
-
"@embedpdf/
|
|
30
|
-
"@embedpdf/
|
|
37
|
+
"@embedpdf/core-annotation": "3.0.0-next.11",
|
|
38
|
+
"@embedpdf/core-geometry": "3.0.0-next.11",
|
|
39
|
+
"@embedpdf/core": "3.0.0-next.11",
|
|
40
|
+
"@embedpdf/plugin-selection": "3.0.0-next.11",
|
|
41
|
+
"@embedpdf/plugin-interaction": "3.0.0-next.11",
|
|
42
|
+
"@embedpdf/engine-core": "3.0.0-next.11",
|
|
43
|
+
"@embedpdf/core-acrojs": "3.0.0-next.11",
|
|
44
|
+
"@embedpdf/plugin-actions": "3.0.0-next.11"
|
|
31
45
|
},
|
|
32
46
|
"devDependencies": {
|
|
33
47
|
"typescript": "^5.0.0",
|