@embedpdf/plugin-annotation 3.0.0-next.21 → 3.0.0-next.23
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/contract/host.cjs +2 -2
- package/dist/contract/host.d.cts +3 -3
- package/dist/contract/host.d.ts +3 -3
- package/dist/contract/host.js +2 -2
- package/dist/{contract-Cm0cfAzG.d.cts → contract-BK2g1Rem.d.ts} +85 -68
- package/dist/{contract-CPzpRG3h.cjs → contract-BtAl3Yo2.cjs} +4 -4
- package/dist/contract-BtAl3Yo2.cjs.map +1 -0
- package/dist/{contract-QAvnfm2b.d.ts → contract-CBYEqnev.d.cts} +85 -68
- package/dist/{contract-b2e_LZvu.js → contract-OwgW3JE8.js} +4 -4
- package/dist/contract-OwgW3JE8.js.map +1 -0
- package/dist/contract.cjs +1 -1
- package/dist/contract.d.cts +2 -2
- package/dist/contract.d.ts +2 -2
- package/dist/contract.js +1 -1
- package/dist/{host-contract-DY9jFPPF.cjs → host-contract-BzM2upsA.cjs} +2 -2
- package/dist/host-contract-BzM2upsA.cjs.map +1 -0
- package/dist/{host-contract-BDwyBNrs.d.cts → host-contract-COF2Prd-.d.ts} +33 -29
- package/dist/{host-contract-CxrQPcPj.js → host-contract-CSKiuu3g.js} +2 -2
- package/dist/host-contract-CSKiuu3g.js.map +1 -0
- package/dist/{host-contract-BUub1Un-.d.ts → host-contract-CxOrR_pp.d.cts} +33 -29
- package/dist/index.cjs +249 -103
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +250 -104
- package/dist/index.js.map +1 -1
- package/package.json +12 -12
- package/dist/contract-CPzpRG3h.cjs.map +0 -1
- package/dist/contract-b2e_LZvu.js.map +0 -1
- package/dist/host-contract-CxrQPcPj.js.map +0 -1
- package/dist/host-contract-DY9jFPPF.cjs.map +0 -1
package/dist/contract/host.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_contract = require("../contract-
|
|
3
|
-
const require_host_contract = require("../host-contract-
|
|
2
|
+
const require_contract = require("../contract-BtAl3Yo2.cjs");
|
|
3
|
+
const require_host_contract = require("../host-contract-BzM2upsA.cjs");
|
|
4
4
|
let _embedpdf_engine_core_public = require("@embedpdf/engine-core/public");
|
|
5
5
|
exports.ANNOTATION_DEFAULTS = require_contract.ANNOTATION_DEFAULTS;
|
|
6
6
|
exports.ANNOTATION_DRAW_PRIORITY = require_host_contract.ANNOTATION_DRAW_PRIORITY;
|
package/dist/contract/host.d.cts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { $ as Color, A as AnnotationResources, At as AnnotationState, B as AnnotationTool, C as AnnotationPatch, Ct as StampPlacement, D as AnnotationRef, Dt as ThreadDeleteResult, E as AnnotationProperty, Et as TextItem, F as AnnotationSelectionChangedEvent, G as ArmedStampInfo, H as AnnotationTransfer, I as AnnotationSettings, J as AttachmentFileSource, Jt as
|
|
2
|
-
import { a as CapturedAnnotationDraft, c as ANNOTATION_DRAW_PRIORITY, d as ANNOTATION_PLACE_PRIORITY, f as AnnotationModel, i as AnnotationToken, l as ANNOTATION_EDIT_PRIORITY, n as AnnotationHostCapability, o as RecalibrationReport, r as AnnotationLender, s as previewBucket, t as AnnotationAppearancePicture, u as ANNOTATION_MARQUEE_PRIORITY } from "../host-contract-
|
|
3
|
-
export { ANNOTATION_DEFAULTS, ANNOTATION_DRAW_PRIORITY, ANNOTATION_EDIT_PRIORITY, ANNOTATION_MARQUEE_PRIORITY, ANNOTATION_PLACE_PRIORITY, ARMED_STAMP_TOOL_ID, AfterCreateSettings, type Annotation, AnnotationAnchor, AnnotationAppearancePicture, type AnnotationBundle, AnnotationCapability, AnnotationConfig, AnnotationCreatedEvent, AnnotationDeletedEvent, type AnnotationDraft,
|
|
1
|
+
import { $ as Color, A as AnnotationResources, At as AnnotationState, B as AnnotationTool, C as AnnotationPatch, Ct as StampPlacement, D as AnnotationRef, Dt as ThreadDeleteResult, E as AnnotationProperty, Et as TextItem, F as AnnotationSelectionChangedEvent, G as ArmedStampInfo, H as AnnotationTransfer, I as AnnotationSettings, J as AttachmentFileSource, Jt as TextFormat, K as ArmedStampPreview, L as AnnotationStampsCapability, M as AnnotationRotationAnchor, N as AnnotationSelectionAnchor, Nt as ARMED_STAMP_TOOL_ID, O as AnnotationReorderedEvent, Ot as ToolDefaults, P as AnnotationSelectionCapability, Q as ClickCreate, R as AnnotationSubtype, S as AnnotationOption, St as StampInput, T as AnnotationProperties, Tt as TextAlign, U as AnnotationUpdatedEvent, V as AnnotationToolsCapability, W as AnnotationWriteFailedEvent, X as BlendMode, Y as Behavior, Yt as TextSelection, Z as ChromeSettings, _ as AnnotationHoverChangedEvent, _t as MarkupSubtype, a as AnnotationBundle, at as EditableKind, b as AnnotationImportResult, bt as ReviewStatus, c as AnnotationCreatedEvent, ct as FilePickerProvider, d as AnnotationDraftCapability, dt as HandleRole, et as CommentThread, f as AnnotationDraftChangedEvent, ft as ImageGhost, g as AnnotationFlags, gt as LinkNavItem, h as AnnotationFilter, ht as LineStyle, i as AnnotationAnchor, it as CreationDraft, j as AnnotationResyncedEvent, jt as annotationState, k as AnnotationResourceRole, kt as ToolDefaultsChangedEvent, l as AnnotationDeletedEvent, lt as FilePromptRequest, m as AnnotationExportSelection, mt as LineEndings, n as AfterCreateSettings, nt as CommentThreadReview, o as AnnotationCapability, ot as EditableKinds, p as AnnotationEditingChangedEvent, pt as LineEnding, q as AttachmentContent, qt as Face, r as Annotation, rt as CommentsCapability, s as AnnotationConfig, st as FieldValues, t as ANNOTATION_DEFAULTS, tt as CommentThreadChangedEvent, u as AnnotationDraft, ut as FlagKey, v as AnnotationImportDrop, vt as MeasurementIntent, w as AnnotationPosition, wt as StampPreviewProvider, x as AnnotationLinksCapability, xt as SnapSettings, y as AnnotationImportOptions, yt as PdfLinkTarget, z as AnnotationTextCapability } from "../contract-CBYEqnev.cjs";
|
|
2
|
+
import { a as CapturedAnnotationDraft, c as ANNOTATION_DRAW_PRIORITY, d as ANNOTATION_PLACE_PRIORITY, f as AnnotationModel, i as AnnotationToken, l as ANNOTATION_EDIT_PRIORITY, n as AnnotationHostCapability, o as RecalibrationReport, r as AnnotationLender, s as previewBucket, t as AnnotationAppearancePicture, u as ANNOTATION_MARQUEE_PRIORITY } from "../host-contract-CxOrR_pp.cjs";
|
|
3
|
+
export { ANNOTATION_DEFAULTS, ANNOTATION_DRAW_PRIORITY, ANNOTATION_EDIT_PRIORITY, ANNOTATION_MARQUEE_PRIORITY, ANNOTATION_PLACE_PRIORITY, ARMED_STAMP_TOOL_ID, AfterCreateSettings, type Annotation, AnnotationAnchor, AnnotationAppearancePicture, type AnnotationBundle, AnnotationCapability, AnnotationConfig, AnnotationCreatedEvent, AnnotationDeletedEvent, type AnnotationDraft, AnnotationDraftCapability, AnnotationDraftChangedEvent, AnnotationEditingChangedEvent, AnnotationExportSelection, AnnotationFilter, type AnnotationFlags, AnnotationHostCapability, AnnotationHoverChangedEvent, type AnnotationImportDrop, type AnnotationImportOptions, AnnotationImportResult, AnnotationLender, AnnotationLinksCapability, type AnnotationModel, type AnnotationOption, type AnnotationPatch, type AnnotationPosition, AnnotationProperties, type AnnotationProperty, type AnnotationRef, AnnotationReorderedEvent, type AnnotationResourceRole, type AnnotationResources, AnnotationResyncedEvent, AnnotationRotationAnchor, AnnotationSelectionAnchor, AnnotationSelectionCapability, AnnotationSelectionChangedEvent, AnnotationSettings, AnnotationStampsCapability, type AnnotationState, type AnnotationSubtype, AnnotationTextCapability, AnnotationToken, AnnotationTool, AnnotationToolsCapability, AnnotationTransfer, AnnotationUpdatedEvent, AnnotationWriteFailedEvent, ArmedStampInfo, ArmedStampPreview, type AttachmentContent, type AttachmentFileSource, Behavior, type BlendMode, CapturedAnnotationDraft, ChromeSettings, type ClickCreate, type Color, type CommentThread, CommentThreadChangedEvent, type CommentThreadReview, CommentsCapability, CreationDraft, type EditableKind, type EditableKinds, type Face, type FieldValues, FilePickerProvider, FilePromptRequest, type FlagKey, type HandleRole, ImageGhost, type LineEnding, type LineEndings, LineStyle, LinkNavItem, MarkupSubtype, type MeasurementIntent, type PdfLinkTarget, RecalibrationReport, type ReviewStatus, type SnapSettings, StampInput, StampPlacement, StampPreviewProvider, type TextAlign, type TextFormat, TextItem, type TextSelection, ThreadDeleteResult, ToolDefaults, ToolDefaultsChangedEvent, annotationState, previewBucket };
|
package/dist/contract/host.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { $ as Color, A as AnnotationResources, At as AnnotationState, B as AnnotationTool, C as AnnotationPatch, Ct as StampPlacement, D as AnnotationRef, Dt as ThreadDeleteResult, E as AnnotationProperty, Et as TextItem, F as AnnotationSelectionChangedEvent, G as ArmedStampInfo, H as AnnotationTransfer, I as AnnotationSettings, J as AttachmentFileSource, Jt as
|
|
2
|
-
import { a as CapturedAnnotationDraft, c as ANNOTATION_DRAW_PRIORITY, d as ANNOTATION_PLACE_PRIORITY, f as AnnotationModel, i as AnnotationToken, l as ANNOTATION_EDIT_PRIORITY, n as AnnotationHostCapability, o as RecalibrationReport, r as AnnotationLender, s as previewBucket, t as AnnotationAppearancePicture, u as ANNOTATION_MARQUEE_PRIORITY } from "../host-contract-
|
|
3
|
-
export { ANNOTATION_DEFAULTS, ANNOTATION_DRAW_PRIORITY, ANNOTATION_EDIT_PRIORITY, ANNOTATION_MARQUEE_PRIORITY, ANNOTATION_PLACE_PRIORITY, ARMED_STAMP_TOOL_ID, AfterCreateSettings, type Annotation, AnnotationAnchor, AnnotationAppearancePicture, type AnnotationBundle, AnnotationCapability, AnnotationConfig, AnnotationCreatedEvent, AnnotationDeletedEvent, type AnnotationDraft,
|
|
1
|
+
import { $ as Color, A as AnnotationResources, At as AnnotationState, B as AnnotationTool, C as AnnotationPatch, Ct as StampPlacement, D as AnnotationRef, Dt as ThreadDeleteResult, E as AnnotationProperty, Et as TextItem, F as AnnotationSelectionChangedEvent, G as ArmedStampInfo, H as AnnotationTransfer, I as AnnotationSettings, J as AttachmentFileSource, Jt as TextFormat, K as ArmedStampPreview, L as AnnotationStampsCapability, M as AnnotationRotationAnchor, N as AnnotationSelectionAnchor, Nt as ARMED_STAMP_TOOL_ID, O as AnnotationReorderedEvent, Ot as ToolDefaults, P as AnnotationSelectionCapability, Q as ClickCreate, R as AnnotationSubtype, S as AnnotationOption, St as StampInput, T as AnnotationProperties, Tt as TextAlign, U as AnnotationUpdatedEvent, V as AnnotationToolsCapability, W as AnnotationWriteFailedEvent, X as BlendMode, Y as Behavior, Yt as TextSelection, Z as ChromeSettings, _ as AnnotationHoverChangedEvent, _t as MarkupSubtype, a as AnnotationBundle, at as EditableKind, b as AnnotationImportResult, bt as ReviewStatus, c as AnnotationCreatedEvent, ct as FilePickerProvider, d as AnnotationDraftCapability, dt as HandleRole, et as CommentThread, f as AnnotationDraftChangedEvent, ft as ImageGhost, g as AnnotationFlags, gt as LinkNavItem, h as AnnotationFilter, ht as LineStyle, i as AnnotationAnchor, it as CreationDraft, j as AnnotationResyncedEvent, jt as annotationState, k as AnnotationResourceRole, kt as ToolDefaultsChangedEvent, l as AnnotationDeletedEvent, lt as FilePromptRequest, m as AnnotationExportSelection, mt as LineEndings, n as AfterCreateSettings, nt as CommentThreadReview, o as AnnotationCapability, ot as EditableKinds, p as AnnotationEditingChangedEvent, pt as LineEnding, q as AttachmentContent, qt as Face, r as Annotation, rt as CommentsCapability, s as AnnotationConfig, st as FieldValues, t as ANNOTATION_DEFAULTS, tt as CommentThreadChangedEvent, u as AnnotationDraft, ut as FlagKey, v as AnnotationImportDrop, vt as MeasurementIntent, w as AnnotationPosition, wt as StampPreviewProvider, x as AnnotationLinksCapability, xt as SnapSettings, y as AnnotationImportOptions, yt as PdfLinkTarget, z as AnnotationTextCapability } from "../contract-BK2g1Rem.js";
|
|
2
|
+
import { a as CapturedAnnotationDraft, c as ANNOTATION_DRAW_PRIORITY, d as ANNOTATION_PLACE_PRIORITY, f as AnnotationModel, i as AnnotationToken, l as ANNOTATION_EDIT_PRIORITY, n as AnnotationHostCapability, o as RecalibrationReport, r as AnnotationLender, s as previewBucket, t as AnnotationAppearancePicture, u as ANNOTATION_MARQUEE_PRIORITY } from "../host-contract-COF2Prd-.js";
|
|
3
|
+
export { ANNOTATION_DEFAULTS, ANNOTATION_DRAW_PRIORITY, ANNOTATION_EDIT_PRIORITY, ANNOTATION_MARQUEE_PRIORITY, ANNOTATION_PLACE_PRIORITY, ARMED_STAMP_TOOL_ID, AfterCreateSettings, type Annotation, AnnotationAnchor, AnnotationAppearancePicture, type AnnotationBundle, AnnotationCapability, AnnotationConfig, AnnotationCreatedEvent, AnnotationDeletedEvent, type AnnotationDraft, AnnotationDraftCapability, AnnotationDraftChangedEvent, AnnotationEditingChangedEvent, AnnotationExportSelection, AnnotationFilter, type AnnotationFlags, AnnotationHostCapability, AnnotationHoverChangedEvent, type AnnotationImportDrop, type AnnotationImportOptions, AnnotationImportResult, AnnotationLender, AnnotationLinksCapability, type AnnotationModel, type AnnotationOption, type AnnotationPatch, type AnnotationPosition, AnnotationProperties, type AnnotationProperty, type AnnotationRef, AnnotationReorderedEvent, type AnnotationResourceRole, type AnnotationResources, AnnotationResyncedEvent, AnnotationRotationAnchor, AnnotationSelectionAnchor, AnnotationSelectionCapability, AnnotationSelectionChangedEvent, AnnotationSettings, AnnotationStampsCapability, type AnnotationState, type AnnotationSubtype, AnnotationTextCapability, AnnotationToken, AnnotationTool, AnnotationToolsCapability, AnnotationTransfer, AnnotationUpdatedEvent, AnnotationWriteFailedEvent, ArmedStampInfo, ArmedStampPreview, type AttachmentContent, type AttachmentFileSource, Behavior, type BlendMode, CapturedAnnotationDraft, ChromeSettings, type ClickCreate, type Color, type CommentThread, CommentThreadChangedEvent, type CommentThreadReview, CommentsCapability, CreationDraft, type EditableKind, type EditableKinds, type Face, type FieldValues, FilePickerProvider, FilePromptRequest, type FlagKey, type HandleRole, ImageGhost, type LineEnding, type LineEndings, LineStyle, LinkNavItem, MarkupSubtype, type MeasurementIntent, type PdfLinkTarget, RecalibrationReport, type ReviewStatus, type SnapSettings, StampInput, StampPlacement, StampPreviewProvider, type TextAlign, type TextFormat, TextItem, type TextSelection, ThreadDeleteResult, ToolDefaults, ToolDefaultsChangedEvent, annotationState, previewBucket };
|
package/dist/contract/host.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as AnnotationTransfer, r as ARMED_STAMP_TOOL_ID, s as annotationState, t as ANNOTATION_DEFAULTS } from "../contract-
|
|
2
|
-
import { a as ANNOTATION_MARQUEE_PRIORITY, i as ANNOTATION_EDIT_PRIORITY, n as previewBucket, o as ANNOTATION_PLACE_PRIORITY, r as ANNOTATION_DRAW_PRIORITY, t as AnnotationToken } from "../host-contract-
|
|
1
|
+
import { n as AnnotationTransfer, r as ARMED_STAMP_TOOL_ID, s as annotationState, t as ANNOTATION_DEFAULTS } from "../contract-OwgW3JE8.js";
|
|
2
|
+
import { a as ANNOTATION_MARQUEE_PRIORITY, i as ANNOTATION_EDIT_PRIORITY, n as previewBucket, o as ANNOTATION_PLACE_PRIORITY, r as ANNOTATION_DRAW_PRIORITY, t as AnnotationToken } from "../host-contract-CSKiuu3g.js";
|
|
3
3
|
export { ANNOTATION_DEFAULTS, ANNOTATION_DRAW_PRIORITY, ANNOTATION_EDIT_PRIORITY, ANNOTATION_MARQUEE_PRIORITY, ANNOTATION_PLACE_PRIORITY, ARMED_STAMP_TOOL_ID, AnnotationToken, AnnotationTransfer, annotationState, previewBucket };
|
|
@@ -1,17 +1,25 @@
|
|
|
1
|
-
import { AnnotationFlags, AnnotationFlags as AnnotationFlags$1, AnnotationOption, AnnotationProperty, AnnotationProperty as AnnotationProperty$1, BlendMode, ClickCreate, ClickCreate as ClickCreate$1, CreationDraftAnchor, EditableKind, EditableKinds, EditableKinds as EditableKinds$1, FieldValues, FieldValues as FieldValues$1, FlagKey, HandleRole, InkStraightenOptions, KindName, LineEnding, LineEndings, MeasurementIntent, Rect, RichTextRange, RotationAnchor, SnapSettings, SnapSettings as SnapSettings$1, TextAlign, ViewEnv } from "@embedpdf/core-annotation";
|
|
2
1
|
import { BatchResult, DeepPartial, EventHook, EventOrigin, OperationOptions, PluginErrorInfo, ResourceStatus, SettingsApi, Unsubscribe } from "@embedpdf/core";
|
|
3
|
-
import { Point as Point$1 } from "@embedpdf/core-geometry";
|
|
4
2
|
import { MountableFontProgram } from "@embedpdf/plugin-fonts/contract";
|
|
3
|
+
import { AnnotationTransfer } from "@embedpdf/engine-core/public";
|
|
5
4
|
import { Annotation, Annotation as Annotation$1, AnnotationBundle, AnnotationBundle as AnnotationBundle$1, AnnotationDraft, AnnotationDraft as AnnotationDraft$1, AnnotationImportDrop, AnnotationImportDrop as AnnotationImportDrop$1, AnnotationImportOptions, AnnotationImportOptions as AnnotationImportOptions$1, AnnotationPatch, AnnotationPatch as AnnotationPatch$1, AnnotationPosition, AnnotationPosition as AnnotationPosition$1, AnnotationRef, AnnotationRef as AnnotationRef$1, AnnotationResourceRole, AnnotationResourceRole as AnnotationResourceRole$1, AnnotationResources, AnnotationResources as AnnotationResources$1, AnnotationSubtype, AnnotationSubtype as AnnotationSubtype$1, AttachmentContent, AttachmentFileSource, AttachmentFileSource as AttachmentFileSource$1, BinarySource, Color, CommentThread, CommentThread as CommentThread$1, CommentThreadReview, PageRef, PdfActionTree, PdfLinkTarget, PdfLinkTarget as PdfLinkTarget$1, ReviewStatus, RichTextBody, RichTextParagraph, WidgetAppearance } from "@embedpdf/engine-core/runtime";
|
|
5
|
+
import { AnnotationFlags, AnnotationFlags as AnnotationFlags$1, AnnotationOption, AnnotationProperty, AnnotationProperty as AnnotationProperty$1, BlendMode, ClickCreate, ClickCreate as ClickCreate$1, CreationDraftAnchor, EditableKind, EditableKinds, EditableKinds as EditableKinds$1, FieldValues, FieldValues as FieldValues$1, FlagKey, HandleRole, InkStraightenOptions, KindName, LineEnding, LineEndings, MeasurementIntent, Rect, RichTextRange, RichTextStyleDelta, RotationAnchor, SnapSettings, SnapSettings as SnapSettings$1, TextAlign, ViewEnv } from "@embedpdf/core-annotation";
|
|
6
6
|
import "@embedpdf/plugin-interaction/contract";
|
|
7
|
-
import {
|
|
7
|
+
import { Point as Point$1 } from "@embedpdf/core-geometry";
|
|
8
8
|
//#region src/rich-text.d.ts
|
|
9
9
|
type TextFormat = 'bold' | 'italic' | 'underline';
|
|
10
10
|
/** The editor's selection inside one free-text annotation: flat offsets over
|
|
11
|
-
* the plain projection (paragraphs joined by `\
|
|
11
|
+
* the plain projection (paragraphs joined by `\n`). */
|
|
12
12
|
interface TextSelection extends RichTextRange {
|
|
13
13
|
id: string;
|
|
14
14
|
}
|
|
15
|
+
/**
|
|
16
|
+
* The editor's selection as the plugin keeps it: at a caret, with the style
|
|
17
|
+
* chosen there for the text typed next. A selection that moves is a new one,
|
|
18
|
+
* without it.
|
|
19
|
+
*/
|
|
20
|
+
interface EditorSelection extends TextSelection {
|
|
21
|
+
readonly typing?: RichTextStyleDelta;
|
|
22
|
+
}
|
|
15
23
|
/** The face a run or a body names. */
|
|
16
24
|
interface Face {
|
|
17
25
|
family: string;
|
|
@@ -144,7 +152,7 @@ type ToolDefaultsFor<K extends ToolAuthoringKind> = ToolDraftOf<K> & (K extends
|
|
|
144
152
|
* optional: the common cases are "configure a built-in" (`{ id, defaults }`) and
|
|
145
153
|
* "add a preset" (`{ id, extends, defaults }`).
|
|
146
154
|
*/
|
|
147
|
-
interface
|
|
155
|
+
interface AnnotationToolDefinition<K extends ToolAuthoringKind = ToolAuthoringKind> {
|
|
148
156
|
/** Stable tool id — the value passed to `activateTool` and the `defaults` key. */
|
|
149
157
|
id: string;
|
|
150
158
|
/** Inherit `subtype` / `fieldsKind` / `cursor` / `enables` / `source` /
|
|
@@ -256,15 +264,15 @@ interface BuiltinToolKindMap {
|
|
|
256
264
|
attachment: 'file-attachment';
|
|
257
265
|
link: 'link';
|
|
258
266
|
}
|
|
259
|
-
type DirectToolDef = { [K in ToolAuthoringKind]: Omit<
|
|
267
|
+
type DirectToolDef = { [K in ToolAuthoringKind]: Omit<AnnotationToolDefinition<K>, 'subtype'> & {
|
|
260
268
|
subtype: K;
|
|
261
269
|
}; }[ToolAuthoringKind];
|
|
262
|
-
type BuiltinToolOverride = { [I in keyof BuiltinToolKindMap]: Omit<
|
|
270
|
+
type BuiltinToolOverride = { [I in keyof BuiltinToolKindMap]: Omit<AnnotationToolDefinition<BuiltinToolKindMap[I]>, 'id' | 'extends' | 'subtype'> & {
|
|
263
271
|
id: I;
|
|
264
272
|
extends?: undefined;
|
|
265
273
|
subtype?: undefined;
|
|
266
274
|
}; }[keyof BuiltinToolKindMap];
|
|
267
|
-
type ExtendedBuiltinToolDef = { [I in keyof BuiltinToolKindMap]: Omit<
|
|
275
|
+
type ExtendedBuiltinToolDef = { [I in keyof BuiltinToolKindMap]: Omit<AnnotationToolDefinition<BuiltinToolKindMap[I]>, 'extends' | 'subtype'> & {
|
|
268
276
|
extends: I;
|
|
269
277
|
subtype?: undefined;
|
|
270
278
|
}; }[keyof BuiltinToolKindMap];
|
|
@@ -282,19 +290,19 @@ interface ResolvedTool {
|
|
|
282
290
|
cursor: string;
|
|
283
291
|
enables: ReadonlySet<string>;
|
|
284
292
|
defaults?: FieldValues;
|
|
285
|
-
/** `/F` seed for created annotations (see {@link
|
|
293
|
+
/** `/F` seed for created annotations (see {@link AnnotationToolDefinition.flags}). */
|
|
286
294
|
flags?: Partial<AnnotationFlags>;
|
|
287
295
|
source?: StampSourceSpec;
|
|
288
296
|
selection?: SelectionAuthoring;
|
|
289
297
|
ink?: InkAuthoringOptions;
|
|
290
298
|
/** Counter-rotate creations against the page's display rotation (see
|
|
291
|
-
* {@link
|
|
299
|
+
* {@link AnnotationToolDefinition.upright}). */
|
|
292
300
|
upright: boolean;
|
|
293
301
|
/** What a bare click creates, or `false` for drag-only. */
|
|
294
302
|
clickCreate: ClickCreate | false;
|
|
295
303
|
/** The tool's ghost ({@link GhostPolicy}): how opaque it paints, or `false` for none. */
|
|
296
304
|
ghost: ResolvedGhost;
|
|
297
|
-
/** Its own `afterCreate` (see {@link
|
|
305
|
+
/** Its own `afterCreate` (see {@link AnnotationToolDefinition.afterCreate}), over the setting. */
|
|
298
306
|
afterCreate?: Partial<AfterCreateSettings>;
|
|
299
307
|
/** A line gesture is captured, not created ({@link CAPTURE_TOOLS}). */
|
|
300
308
|
capture: boolean;
|
|
@@ -387,7 +395,10 @@ interface ChromeSettings {
|
|
|
387
395
|
/** Line width of both kinds, px. */
|
|
388
396
|
readonly width: number;
|
|
389
397
|
};
|
|
390
|
-
/**
|
|
398
|
+
/**
|
|
399
|
+
* The box you drag to select several annotations, one value: a change
|
|
400
|
+
* replaces it whole, and a color it leaves out is `null` again.
|
|
401
|
+
*/
|
|
391
402
|
readonly marquee: {
|
|
392
403
|
/** `null`: `accent` at 8%. */
|
|
393
404
|
readonly fill: string | null;
|
|
@@ -409,7 +420,8 @@ interface ChromeSettings {
|
|
|
409
420
|
* fields most tools have are typed, the rest read as `unknown`.
|
|
410
421
|
*/
|
|
411
422
|
interface ToolDefaults {
|
|
412
|
-
|
|
423
|
+
/** `null` on a shape or line tool: no stroke. */
|
|
424
|
+
readonly color?: string | null;
|
|
413
425
|
readonly interiorColor?: string | null;
|
|
414
426
|
readonly opacity?: number;
|
|
415
427
|
readonly strokeWidth?: number;
|
|
@@ -467,13 +479,13 @@ type AnnotationConfig = DeepPartial<AnnotationSettings>;
|
|
|
467
479
|
* with the page's items (`source: 'ghost'`).
|
|
468
480
|
*/
|
|
469
481
|
interface ImageGhost {
|
|
470
|
-
page: PageRef;
|
|
482
|
+
readonly page: PageRef;
|
|
471
483
|
/** The box the stamp's placement would use, before its turn. */
|
|
472
|
-
box: Rect;
|
|
484
|
+
readonly box: Rect;
|
|
473
485
|
/** The tool's upright turn at this hover (degrees clockwise). */
|
|
474
|
-
rot: number;
|
|
486
|
+
readonly rot: number;
|
|
475
487
|
/** How opaque it paints (0–1); `--epdf-ghost-opacity` wins over it. */
|
|
476
|
-
opacity: number;
|
|
488
|
+
readonly opacity: number;
|
|
477
489
|
}
|
|
478
490
|
/**
|
|
479
491
|
* One clickable link area on a page (page space): a standalone link
|
|
@@ -482,10 +494,10 @@ interface ImageGhost {
|
|
|
482
494
|
*/
|
|
483
495
|
interface LinkNavItem {
|
|
484
496
|
/** Stable per-page key: the annot id, `#n`-suffixed for attached segments. */
|
|
485
|
-
id: string;
|
|
497
|
+
readonly id: string;
|
|
486
498
|
/** The clickable area in page space. */
|
|
487
|
-
bounds: Rect;
|
|
488
|
-
target: PdfLinkTarget;
|
|
499
|
+
readonly bounds: Rect;
|
|
500
|
+
readonly target: PdfLinkTarget;
|
|
489
501
|
/**
|
|
490
502
|
* True for a link child riding an editable annotation (an `/RT /Group`
|
|
491
503
|
* subordinate): a property of its parent while authoring, a nav behavior
|
|
@@ -493,17 +505,17 @@ interface LinkNavItem {
|
|
|
493
505
|
* items whenever the active tool enables `annotation-edit`, so the parent
|
|
494
506
|
* stays selectable/movable; standalone document links navigate regardless.
|
|
495
507
|
*/
|
|
496
|
-
attached: boolean;
|
|
508
|
+
readonly attached: boolean;
|
|
497
509
|
/** The full payload-carrying `/A` tree, when one exists: the action
|
|
498
510
|
* engine's dispatch input. `target` remains its root projection. */
|
|
499
|
-
activate?: PdfActionTree;
|
|
511
|
+
readonly activate?: PdfActionTree;
|
|
500
512
|
/** The annotation ref, carried for ActionSource context. */
|
|
501
|
-
ref?: AnnotationRef;
|
|
513
|
+
readonly ref?: AnnotationRef;
|
|
502
514
|
/** Which `/AA` hover trees this link carries: the nav layer's pump flags
|
|
503
515
|
* (tree-less hover must cost zero dispatches). Links are behavior-inert
|
|
504
516
|
* to the annotation plane's hover feed while navigable, so their
|
|
505
517
|
* cursorEnter/cursorExit can only fire from the LinkLayer anchors. */
|
|
506
|
-
hoverEvents?: {
|
|
518
|
+
readonly hoverEvents?: {
|
|
507
519
|
enter: boolean;
|
|
508
520
|
exit: boolean;
|
|
509
521
|
};
|
|
@@ -514,7 +526,7 @@ interface LinkNavItem {
|
|
|
514
526
|
* are not geometry-editable. Not engaged, they are edited like any other.
|
|
515
527
|
*/
|
|
516
528
|
interface Behavior {
|
|
517
|
-
id: string;
|
|
529
|
+
readonly id: string;
|
|
518
530
|
/** Whether this behavior is about the annotation at all. */
|
|
519
531
|
matches(annotation: Annotation): boolean;
|
|
520
532
|
/** Whether it owns the annotation now (read live: the active tool, the app's mode). */
|
|
@@ -548,17 +560,17 @@ interface AnnotationProperties {
|
|
|
548
560
|
* live view matches the baked appearance.
|
|
549
561
|
*/
|
|
550
562
|
interface TextItem {
|
|
551
|
-
id: string;
|
|
552
|
-
ref: AnnotationRef | null;
|
|
553
|
-
box: Rect;
|
|
554
|
-
contents: string;
|
|
563
|
+
readonly id: string;
|
|
564
|
+
readonly ref: AnnotationRef | null;
|
|
565
|
+
readonly box: Rect;
|
|
566
|
+
readonly contents: string;
|
|
555
567
|
/** The rich paragraphs the editor renders and edits (run deltas over the
|
|
556
568
|
* body, which `css` carries). `contents` is their plain projection. */
|
|
557
|
-
richText: {
|
|
569
|
+
readonly richText: {
|
|
558
570
|
paragraphs: RichTextParagraph[];
|
|
559
571
|
};
|
|
560
572
|
/** The face of its text without one of its own: the body's. */
|
|
561
|
-
face: {
|
|
573
|
+
readonly face: {
|
|
562
574
|
family: string;
|
|
563
575
|
weight: number;
|
|
564
576
|
italic: boolean;
|
|
@@ -568,12 +580,12 @@ interface TextItem {
|
|
|
568
580
|
* families name them): mount them where the box is drawn
|
|
569
581
|
* (`createFontMounts` in `@embedpdf/web`). Empty without the fonts plugin.
|
|
570
582
|
*/
|
|
571
|
-
programs: readonly MountableFontProgram[];
|
|
572
|
-
editing: boolean;
|
|
583
|
+
readonly programs: readonly MountableFontProgram[];
|
|
584
|
+
readonly editing: boolean;
|
|
573
585
|
/** Applied rotation (deg, CW). `box` is the unrotated text box; the framework
|
|
574
586
|
* rotates the editable element about its centre by this. 0/undefined = none. */
|
|
575
|
-
rot?: number;
|
|
576
|
-
css: {
|
|
587
|
+
readonly rot?: number;
|
|
588
|
+
readonly css: {
|
|
577
589
|
fontFamily: string;
|
|
578
590
|
/** Content units (the framework multiplies by the page scale). The line
|
|
579
591
|
* height is not here: the editor binding states the engine's line model
|
|
@@ -590,8 +602,8 @@ interface TextItem {
|
|
|
590
602
|
}
|
|
591
603
|
/** What `comments.deleteThread()` did: everything went, or nothing did and `failed` says why. */
|
|
592
604
|
interface ThreadDeleteResult {
|
|
593
|
-
deleted: AnnotationRef[];
|
|
594
|
-
failed: Array<{
|
|
605
|
+
readonly deleted: AnnotationRef[];
|
|
606
|
+
readonly failed: Array<{
|
|
595
607
|
ref: AnnotationRef;
|
|
596
608
|
error: unknown;
|
|
597
609
|
}>;
|
|
@@ -696,7 +708,7 @@ interface ToolDefaultsChangedEvent {
|
|
|
696
708
|
/** A thread changed through this viewer. */
|
|
697
709
|
interface CommentThreadChangedEvent {
|
|
698
710
|
readonly rootRef: AnnotationRef;
|
|
699
|
-
readonly
|
|
711
|
+
readonly type: 'reply' | 'text' | 'status' | 'marked' | 'deleted';
|
|
700
712
|
}
|
|
701
713
|
/** Which annotations `list()` returns: every field narrows. */
|
|
702
714
|
interface AnnotationFilter {
|
|
@@ -724,9 +736,9 @@ interface AnnotationExportSelection {
|
|
|
724
736
|
readonly pages?: readonly (PageRef | number)[];
|
|
725
737
|
}
|
|
726
738
|
/** The selection: what is selected, and the verbs that change it as one. */
|
|
727
|
-
interface
|
|
739
|
+
interface AnnotationSelectionCapability {
|
|
728
740
|
/** Select these annotations; an annotation in a group brings its group. */
|
|
729
|
-
|
|
741
|
+
select(refs: readonly AnnotationRef[]): void;
|
|
730
742
|
/** Add these annotations to the selection, with their groups. */
|
|
731
743
|
add(refs: readonly AnnotationRef[]): void;
|
|
732
744
|
/** Select everything that can be selected, on one page or in the whole document. */
|
|
@@ -741,13 +753,14 @@ interface AnnotationSelectionApi {
|
|
|
741
753
|
/** Clear the selection. */
|
|
742
754
|
clear(): void;
|
|
743
755
|
/** The selected annotations, as the user sees them. */
|
|
744
|
-
|
|
756
|
+
getSelected(): readonly Annotation[];
|
|
745
757
|
/**
|
|
746
758
|
* Change the selected annotations: each takes the fields its kind has, and
|
|
747
|
-
* skips the rest. A function changes each relative to itself.
|
|
748
|
-
*
|
|
749
|
-
*
|
|
750
|
-
*
|
|
759
|
+
* skips the rest. A function changes each relative to itself. A text box's
|
|
760
|
+
* font, size, colour and formats change all of its text; while words are
|
|
761
|
+
* selected in a text box being typed in, those words, and at its caret, the
|
|
762
|
+
* text typed there next. Resolves once the engine wrote every change, with
|
|
763
|
+
* what it refused in `failed`.
|
|
751
764
|
*/
|
|
752
765
|
update(changes: AnnotationPatch | ((annotation: Annotation) => AnnotationPatch), options?: OperationOptions): Promise<BatchResult<AnnotationRef, AnnotationRef>>;
|
|
753
766
|
/** Link the selected annotations to a page or a website, or remove their links with `null`. */
|
|
@@ -777,7 +790,7 @@ interface AnnotationSelectionApi {
|
|
|
777
790
|
getRotationAnchor(): AnnotationRotationAnchor | null;
|
|
778
791
|
}
|
|
779
792
|
/** A polygon or polyline being drawn, a click per point. */
|
|
780
|
-
interface
|
|
793
|
+
interface AnnotationDraftCapability {
|
|
781
794
|
/** The shape being drawn, or `null`. */
|
|
782
795
|
get(): CreationDraft | null;
|
|
783
796
|
/** End the shape and create it, as a double-click does. Resolves `null` when there was none to make. */
|
|
@@ -788,18 +801,22 @@ interface AnnotationDraftApi {
|
|
|
788
801
|
cancel(): void;
|
|
789
802
|
}
|
|
790
803
|
/** Typing in a text box. */
|
|
791
|
-
interface
|
|
804
|
+
interface AnnotationTextCapability {
|
|
792
805
|
/** Start typing in a text box, as a double-click does. */
|
|
793
806
|
begin(ref: AnnotationRef): void;
|
|
794
807
|
/** Stop typing, and save what was typed. */
|
|
795
808
|
end(options?: OperationOptions): Promise<void>;
|
|
796
809
|
/** The text box being typed in, or `null`. */
|
|
797
810
|
getEditing(): Annotation | null;
|
|
798
|
-
/**
|
|
811
|
+
/**
|
|
812
|
+
* Bold, italic or underline on or off: for the selected words, the text
|
|
813
|
+
* typed next at the caret, or all the text of each selected box. On, unless
|
|
814
|
+
* all of it already has it.
|
|
815
|
+
*/
|
|
799
816
|
toggleFormat(format: TextFormat, options?: OperationOptions): Promise<void>;
|
|
800
817
|
}
|
|
801
818
|
/** The tools: what a click or a drag creates, with which defaults. */
|
|
802
|
-
interface
|
|
819
|
+
interface AnnotationToolsCapability {
|
|
803
820
|
/** Every tool, the built-in ones and yours. */
|
|
804
821
|
list(): readonly AnnotationTool[];
|
|
805
822
|
/** One tool, or `null`. */
|
|
@@ -850,18 +867,18 @@ interface StampInput {
|
|
|
850
867
|
/** Where `stamps.place()` puts a stamp, without a click. */
|
|
851
868
|
interface StampPlacement {
|
|
852
869
|
/** The page, as a ref or an index. */
|
|
853
|
-
page: PageRef | number;
|
|
870
|
+
readonly page: PageRef | number;
|
|
854
871
|
/** Where its middle goes, in page space. The size comes from the picture. */
|
|
855
|
-
center: Point$1;
|
|
872
|
+
readonly center: Point$1;
|
|
856
873
|
/** Placed width in PDF points; default the picture's own (or the stamp's `targetWidth`). */
|
|
857
|
-
targetWidth?: number;
|
|
874
|
+
readonly targetWidth?: number;
|
|
858
875
|
/** Its turn, degrees clockwise. Default 0. */
|
|
859
|
-
rotation?: number;
|
|
876
|
+
readonly rotation?: number;
|
|
860
877
|
/** Select it, as placing it with a click would. Default false: code never changes the selection. */
|
|
861
|
-
select?: boolean;
|
|
878
|
+
readonly select?: boolean;
|
|
862
879
|
}
|
|
863
880
|
/** Stamps placed from bytes: armed for the next click, or placed from code. */
|
|
864
|
-
interface
|
|
881
|
+
interface AnnotationStampsCapability {
|
|
865
882
|
/**
|
|
866
883
|
* Arm a stamp's bytes so the next click places them, as the `stamp` tool
|
|
867
884
|
* does after picking a file. Rejects `invalid-input` for bytes that aren't
|
|
@@ -884,7 +901,7 @@ interface AnnotationStampsApi {
|
|
|
884
901
|
}>;
|
|
885
902
|
}
|
|
886
903
|
/** Links attached to annotations (a link child), or a link annotation's own target. */
|
|
887
|
-
interface
|
|
904
|
+
interface AnnotationLinksCapability {
|
|
888
905
|
/** Where an annotation links to, or `null`. */
|
|
889
906
|
get(ref: AnnotationRef): PdfLinkTarget | null;
|
|
890
907
|
/** Link an annotation to a page or a website. */
|
|
@@ -897,7 +914,7 @@ interface AnnotationLinksApi {
|
|
|
897
914
|
* annotation create, change or delete, so other people's changes, this
|
|
898
915
|
* viewer's and reloads all show in `listThreads()`.
|
|
899
916
|
*/
|
|
900
|
-
interface
|
|
917
|
+
interface CommentsCapability {
|
|
901
918
|
/** Every thread, in reading order: by page, then from the top of the page. */
|
|
902
919
|
listThreads(): readonly CommentThread[];
|
|
903
920
|
/** The thread a comment is in (its first comment, a reply or a review state), or `null`. */
|
|
@@ -1042,13 +1059,13 @@ interface AnnotationCapability extends SettingsApi<AnnotationSettings> {
|
|
|
1042
1059
|
* that isn't here, `invalid-input` for a role its kind doesn't have.
|
|
1043
1060
|
*/
|
|
1044
1061
|
downloadResource(ref: AnnotationRef, role: AnnotationResourceRole, options?: OperationOptions): Promise<Uint8Array>;
|
|
1045
|
-
readonly links:
|
|
1046
|
-
readonly selection:
|
|
1047
|
-
readonly draft:
|
|
1048
|
-
readonly text:
|
|
1049
|
-
readonly tools:
|
|
1050
|
-
readonly stamps:
|
|
1051
|
-
readonly comments:
|
|
1062
|
+
readonly links: AnnotationLinksCapability;
|
|
1063
|
+
readonly selection: AnnotationSelectionCapability;
|
|
1064
|
+
readonly draft: AnnotationDraftCapability;
|
|
1065
|
+
readonly text: AnnotationTextCapability;
|
|
1066
|
+
readonly tools: AnnotationToolsCapability;
|
|
1067
|
+
readonly stamps: AnnotationStampsCapability;
|
|
1068
|
+
readonly comments: CommentsCapability;
|
|
1052
1069
|
/**
|
|
1053
1070
|
* Set the function that gives the `stamp` and `attachment` tools their
|
|
1054
1071
|
* file, `null` to make them do nothing. Returns a function that removes it.
|
|
@@ -1105,8 +1122,8 @@ interface ArmedStampInfo {
|
|
|
1105
1122
|
}
|
|
1106
1123
|
/** The armed stamp's paintable preview, for the render layer's ghost `<img>`. */
|
|
1107
1124
|
interface ArmedStampPreview {
|
|
1108
|
-
bytes: Uint8Array;
|
|
1109
|
-
mimeType?: string;
|
|
1125
|
+
readonly bytes: Uint8Array;
|
|
1126
|
+
readonly mimeType?: string;
|
|
1110
1127
|
}
|
|
1111
1128
|
/**
|
|
1112
1129
|
* Resolution-aware ghost preview: "give me this stamp at `devicePixelWidth`
|
|
@@ -1148,5 +1165,5 @@ interface FilePromptRequest {
|
|
|
1148
1165
|
*/
|
|
1149
1166
|
type FilePickerProvider = (request: FilePromptRequest) => Promise<AttachmentFileSource | null>;
|
|
1150
1167
|
//#endregion
|
|
1151
|
-
export { Color as $, AnnotationResources$1 as A, AnnotationState as At, AnnotationTool as B, ResolvedGhost as Bt, AnnotationPatch$1 as C, StampPlacement as Ct, AnnotationRef$1 as D, ThreadDeleteResult as Dt, AnnotationProperty$1 as E, TextItem as Et, AnnotationSelectionChangedEvent as F, AnnotationToolInput as Ft, ArmedStampInfo as G, ToolDefaultsFor as Gt, AnnotationTransfer as H, SelectionAuthoring as Ht, AnnotationSettings as I, DEFAULT_TOOLS as It, AttachmentFileSource$1 as J,
|
|
1152
|
-
//# sourceMappingURL=contract-
|
|
1168
|
+
export { Color as $, AnnotationResources$1 as A, AnnotationState as At, AnnotationTool as B, ResolvedGhost as Bt, AnnotationPatch$1 as C, StampPlacement as Ct, AnnotationRef$1 as D, ThreadDeleteResult as Dt, AnnotationProperty$1 as E, TextItem as Et, AnnotationSelectionChangedEvent as F, AnnotationToolInput as Ft, ArmedStampInfo as G, ToolDefaultsFor as Gt, AnnotationTransfer as H, SelectionAuthoring as Ht, AnnotationSettings as I, DEFAULT_TOOLS as It, AttachmentFileSource$1 as J, TextFormat as Jt, ArmedStampPreview as K, EditorSelection as Kt, AnnotationStampsCapability as L, GhostPolicy as Lt, AnnotationRotationAnchor as M, AnnotationToken as Mt, AnnotationSelectionAnchor as N, ARMED_STAMP_TOOL_ID as Nt, AnnotationReorderedEvent as O, ToolDefaults as Ot, AnnotationSelectionCapability as P, AnnotationToolDefinition as Pt, ClickCreate$1 as Q, AnnotationSubtype$1 as R, InkAuthoringOptions as Rt, AnnotationOption as S, StampInput as St, AnnotationProperties as T, TextAlign as Tt, AnnotationUpdatedEvent as U, StampSourceSpec as Ut, AnnotationToolsCapability as V, ResolvedTool as Vt, AnnotationWriteFailedEvent as W, ToolAuthoringKind as Wt, BlendMode as X, Behavior as Y, TextSelection as Yt, ChromeSettings as Z, AnnotationHoverChangedEvent as _, MarkupSubtype as _t, AnnotationBundle$1 as a, EditableKind as at, AnnotationImportResult as b, ReviewStatus as bt, AnnotationCreatedEvent as c, FilePickerProvider as ct, AnnotationDraftCapability as d, HandleRole as dt, CommentThread$1 as et, AnnotationDraftChangedEvent as f, ImageGhost as ft, AnnotationFlags$1 as g, LinkNavItem as gt, AnnotationFilter as h, LineStyle as ht, AnnotationAnchor as i, CreationDraft as it, AnnotationResyncedEvent as j, annotationState as jt, AnnotationResourceRole$1 as k, ToolDefaultsChangedEvent as kt, AnnotationDeletedEvent as l, FilePromptRequest as lt, AnnotationExportSelection as m, LineEndings as mt, AfterCreateSettings as n, CommentThreadReview as nt, AnnotationCapability as o, EditableKinds$1 as ot, AnnotationEditingChangedEvent as p, LineEnding as pt, AttachmentContent as q, Face as qt, Annotation$1 as r, CommentsCapability as rt, AnnotationConfig as s, FieldValues$1 as st, ANNOTATION_DEFAULTS as t, CommentThreadChangedEvent as tt, AnnotationDraft$1 as u, FlagKey as ut, AnnotationImportDrop$1 as v, MeasurementIntent as vt, AnnotationPosition$1 as w, StampPreviewProvider as wt, AnnotationLinksCapability as x, SnapSettings$1 as xt, AnnotationImportOptions$1 as y, PdfLinkTarget$1 as yt, AnnotationTextCapability as z, PromptSourceSpec as zt };
|
|
1169
|
+
//# sourceMappingURL=contract-BK2g1Rem.d.ts.map
|
|
@@ -49,7 +49,7 @@ const AnnotationToken = (0, _embedpdf_core.createCapabilityToken)("annotation",
|
|
|
49
49
|
const annotationState = (0, _embedpdf_core.defineState)(AnnotationToken, {
|
|
50
50
|
read: (annotation) => ({
|
|
51
51
|
status: annotation.getStatus(),
|
|
52
|
-
selected: annotation.selection.
|
|
52
|
+
selected: annotation.selection.getSelected(),
|
|
53
53
|
hovered: annotation.getHovered(),
|
|
54
54
|
editing: annotation.text.getEditing()
|
|
55
55
|
}),
|
|
@@ -633,7 +633,7 @@ const ANNOTATION_DEFAULTS = {
|
|
|
633
633
|
},
|
|
634
634
|
snap: {
|
|
635
635
|
alignment: true,
|
|
636
|
-
|
|
636
|
+
alignmentThresholdPx: 6,
|
|
637
637
|
rotation: true,
|
|
638
638
|
rotationAngles: [
|
|
639
639
|
0,
|
|
@@ -641,7 +641,7 @@ const ANNOTATION_DEFAULTS = {
|
|
|
641
641
|
180,
|
|
642
642
|
270
|
|
643
643
|
],
|
|
644
|
-
|
|
644
|
+
rotationThresholdDeg: 4
|
|
645
645
|
},
|
|
646
646
|
editable: true
|
|
647
647
|
};
|
|
@@ -689,4 +689,4 @@ Object.defineProperty(exports, "toolTouchOf", {
|
|
|
689
689
|
}
|
|
690
690
|
});
|
|
691
691
|
|
|
692
|
-
//# sourceMappingURL=contract-
|
|
692
|
+
//# sourceMappingURL=contract-BtAl3Yo2.cjs.map
|