@embedpdf/engine-core 3.0.0-next.12 → 3.0.0-next.13
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/{AbortError-CRSooKsk.cjs → AbortError-Cq2igpZ6.cjs} +2 -2
- package/dist/{AbortError-CRSooKsk.cjs.map → AbortError-Cq2igpZ6.cjs.map} +1 -1
- package/dist/{AbortError-8-9JAX1Y.js → AbortError-DHqPBnYc.js} +2 -2
- package/dist/{AbortError-8-9JAX1Y.js.map → AbortError-DHqPBnYc.js.map} +1 -1
- package/dist/{AnnotationListSnapshot-x6tKulNV.d.cts → AnnotationListSnapshot-D3mFut1e.d.cts} +1155 -171
- package/dist/{AnnotationListSnapshot-x6tKulNV.d.ts → AnnotationListSnapshot-D3mFut1e.d.ts} +1155 -171
- package/dist/{DocumentSecurityService-CK0pejAK.d.cts → DocumentSecurityService-ClTZc0zO.d.cts} +2 -2
- package/dist/{DocumentSecurityService-9MawYxP-.d.ts → DocumentSecurityService-_JRjqvoI.d.ts} +2 -2
- package/dist/{Engine-Ds0ytbl6.d.ts → Engine-Bx0NOfmd.d.cts} +166 -11
- package/dist/{Engine--0XF0UAK.d.cts → Engine-DxtpCYcP.d.ts} +166 -11
- package/dist/{PageInsertBlankInput-CzShuSJI.cjs → PageInsertBlankInput-CqXBmFhN.cjs} +37 -2
- package/dist/PageInsertBlankInput-CqXBmFhN.cjs.map +1 -0
- package/dist/{PageInsertBlankInput-WKY0tr6S.js → PageInsertBlankInput-cHq9-i-z.js} +37 -2
- package/dist/PageInsertBlankInput-cHq9-i-z.js.map +1 -0
- package/dist/{builders-8Hl1AYNU.cjs → builders-Bqm8yTpi.cjs} +1470 -4
- package/dist/builders-Bqm8yTpi.cjs.map +1 -0
- package/dist/{builders-DOjcKDWQ.js → builders-Dqo2X-dt.js} +1351 -5
- package/dist/builders-Dqo2X-dt.js.map +1 -0
- package/dist/conformance.cjs +1079 -13
- package/dist/conformance.cjs.map +1 -1
- package/dist/conformance.d.cts +70 -3
- package/dist/conformance.d.ts +70 -3
- package/dist/conformance.js +1079 -14
- package/dist/conformance.js.map +1 -1
- package/dist/{fold-C7I5GpBz.cjs → fold-2V29cxCV.cjs} +2 -2
- package/dist/{fold-C7I5GpBz.cjs.map → fold-2V29cxCV.cjs.map} +1 -1
- package/dist/{fold-BfyxxwS6.js → fold-CdEJTBTn.js} +2 -2
- package/dist/{fold-BfyxxwS6.js.map → fold-CdEJTBTn.js.map} +1 -1
- package/dist/index.cjs +33 -4
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +5 -5
- package/dist/{resolver-D-jumvgM.cjs → resolver-CYVNV4hn.cjs} +216 -10
- package/dist/resolver-CYVNV4hn.cjs.map +1 -0
- package/dist/{resolver-CHG4waXL.js → resolver-inAVzsWt.js} +157 -11
- package/dist/resolver-inAVzsWt.js.map +1 -0
- package/dist/runtime.cjs +34 -5
- package/dist/runtime.d.cts +192 -5
- package/dist/runtime.d.ts +192 -5
- package/dist/runtime.js +6 -6
- package/dist/{schemas-DOyVEPk7.js → schemas-BLARNCgx.js} +420 -4
- package/dist/schemas-BLARNCgx.js.map +1 -0
- package/dist/{schemas-RChsAMWw.cjs → schemas-DIqFMmrC.cjs} +581 -3
- package/dist/schemas-DIqFMmrC.cjs.map +1 -0
- package/dist/wire.cjs +228 -12
- package/dist/wire.cjs.map +1 -1
- package/dist/wire.d.cts +415 -4
- package/dist/wire.d.ts +415 -4
- package/dist/wire.js +199 -13
- package/dist/wire.js.map +1 -1
- package/package.json +1 -1
- package/dist/PageInsertBlankInput-CzShuSJI.cjs.map +0 -1
- package/dist/PageInsertBlankInput-WKY0tr6S.js.map +0 -1
- package/dist/builders-8Hl1AYNU.cjs.map +0 -1
- package/dist/builders-DOjcKDWQ.js.map +0 -1
- package/dist/resolver-CHG4waXL.js.map +0 -1
- package/dist/resolver-D-jumvgM.cjs.map +0 -1
- package/dist/schemas-DOyVEPk7.js.map +0 -1
- package/dist/schemas-RChsAMWw.cjs.map +0 -1
|
@@ -684,7 +684,7 @@ interface AnnotationDraftBase {
|
|
|
684
684
|
* expands these capabilities. PDF bits are NEVER consulted unless
|
|
685
685
|
* `pdf.permissions` is in scope.
|
|
686
686
|
*/
|
|
687
|
-
type DocCapability = 'doc.open' | 'doc.render' | 'doc.text.select' | 'doc.text.copy' | 'doc.text.search' | 'doc.content.copy' | 'doc.download' | 'doc.download.flattened' | 'doc.print' | 'doc.print.high' | 'doc.pages.modify' | 'doc.pages.assemble' | 'doc.forms.read' | 'doc.forms.fill' | 'doc.forms.modify' | 'doc.forms.submit' | 'doc.annotate.read' | 'doc.annotate.modify' | 'doc.metadata.modify' | 'doc.attachments.modify' | 'doc.redact';
|
|
687
|
+
type DocCapability = 'doc.open' | 'doc.render' | 'doc.text.select' | 'doc.text.copy' | 'doc.text.search' | 'doc.content.copy' | 'doc.download' | 'doc.download.flattened' | 'doc.print' | 'doc.print.high' | 'doc.pages.modify' | 'doc.pages.assemble' | 'doc.forms.read' | 'doc.forms.fill' | 'doc.forms.modify' | 'doc.forms.submit' | 'doc.annotate.read' | 'doc.annotate.modify' | 'doc.metadata.modify' | 'doc.attachments.modify' | 'doc.redact' | 'doc.sign' | 'doc.sign.certify';
|
|
688
688
|
/**
|
|
689
689
|
* Single-entity collaboration vocabulary. Only annotations are
|
|
690
690
|
* collab-scoped today; future entities slot into the same grammar.
|
|
@@ -869,6 +869,419 @@ declare class MissingIdentity extends Error {
|
|
|
869
869
|
constructor(scope: string);
|
|
870
870
|
}
|
|
871
871
|
//#endregion
|
|
872
|
+
//#region src/identity/FormFieldRef.d.ts
|
|
873
|
+
/**
|
|
874
|
+
* How callers address a logical form field.
|
|
875
|
+
*
|
|
876
|
+
* - `objectNumber` — the indirect object number of the field dictionary.
|
|
877
|
+
* ISO 32000 guarantees every real AcroForm field dictionary is an
|
|
878
|
+
* indirect object, and the layer runtime never renumbers (frozen base +
|
|
879
|
+
* incremental deltas), so this is the durable identity for the lifetime
|
|
880
|
+
* of a document. Preferred for all engine calls.
|
|
881
|
+
* - `fqn` — the fully qualified field name ("billing.name"). The portable,
|
|
882
|
+
* semantic identity used by interchange formats (FDF/XFDF) and analytics;
|
|
883
|
+
* survives document rewrites but is only as unique as the producer made
|
|
884
|
+
* it. The engine resolves it against the reconciled field tree.
|
|
885
|
+
*/
|
|
886
|
+
type FormFieldRef = {
|
|
887
|
+
kind: 'objectNumber';
|
|
888
|
+
fieldObjectNumber: number;
|
|
889
|
+
} | {
|
|
890
|
+
kind: 'fqn';
|
|
891
|
+
name: string;
|
|
892
|
+
};
|
|
893
|
+
/**
|
|
894
|
+
* URL-safe encoding of a `FormFieldRef`, used by the cloud HTTP surface as
|
|
895
|
+
* the `:fieldKey` route parameter. Decoded by the server back into a
|
|
896
|
+
* `FormFieldRef` via `decodeFieldRefKey`. Mirrors the annotation plane's
|
|
897
|
+
* `encodeStableIdKey` (`obj:42` / `nm:…`) so the two member-key syntaxes
|
|
898
|
+
* read the same on the wire:
|
|
899
|
+
*
|
|
900
|
+
* `{ kind: 'objectNumber', fieldObjectNumber: 12 }` -> `'obj:12'`
|
|
901
|
+
* `{ kind: 'fqn', name: 'billing.name' }` -> `'fqn:billing.name'`
|
|
902
|
+
*
|
|
903
|
+
* The caller is responsible for `encodeURIComponent`-ing the result before
|
|
904
|
+
* splicing it into a URL path; the `wirePaths.layerFormField*` builders
|
|
905
|
+
* already do that. FQNs are opaque strings and may contain anything; the
|
|
906
|
+
* `fqn:` prefix keeps them unambiguous from numeric ids.
|
|
907
|
+
*/
|
|
908
|
+
declare function encodeFieldRefKey(ref: FormFieldRef): string;
|
|
909
|
+
/**
|
|
910
|
+
* Inverse of `encodeFieldRefKey`. Returns `null` for malformed input so the
|
|
911
|
+
* server can answer 400 InvalidArg with a useful message instead of
|
|
912
|
+
* throwing. The input is the already-`decodeURIComponent`-ed segment from
|
|
913
|
+
* the route path. Empty FQNs are rejected: `fqn:` with no suffix is not a
|
|
914
|
+
* valid identity.
|
|
915
|
+
*/
|
|
916
|
+
declare function decodeFieldRefKey(key: string): FormFieldRef | null;
|
|
917
|
+
/** A widget annotation of a field, as the forms subsystem sees it. */
|
|
918
|
+
interface FormWidgetRef {
|
|
919
|
+
/**
|
|
920
|
+
* Indirect object number of the widget annotation — the join key to the
|
|
921
|
+
* annotation subsystem's `objectNumber` refs. `0` when the widget is
|
|
922
|
+
* stored as a direct object (spec-violating; cannot be addressed).
|
|
923
|
+
*/
|
|
924
|
+
annotObjectNumber: number;
|
|
925
|
+
/**
|
|
926
|
+
* Object number of the page whose /Annots array references the widget.
|
|
927
|
+
* `0` when the widget is not reachable from any page ("unplaced").
|
|
928
|
+
*/
|
|
929
|
+
pageObjectNumber: PageObjectNumber;
|
|
930
|
+
}
|
|
931
|
+
//#endregion
|
|
932
|
+
//#region src/dto/CachePins.d.ts
|
|
933
|
+
/**
|
|
934
|
+
* Per-page cache-busting integers embedded in immutable cloud/CDN leaf URLs.
|
|
935
|
+
*
|
|
936
|
+
* These are not page state. They are read coordinates for cacheable endpoints:
|
|
937
|
+
* `/text` uses `contentVersion`; `/annotations` uses `annotationVersion`.
|
|
938
|
+
*/
|
|
939
|
+
interface CachePins {
|
|
940
|
+
contentVersion: number;
|
|
941
|
+
annotationVersion: number;
|
|
942
|
+
}
|
|
943
|
+
//#endregion
|
|
944
|
+
//#region src/revision/WeakAnnotationState.d.ts
|
|
945
|
+
/**
|
|
946
|
+
* Tri-state knowledge about weak annotation identities on a page.
|
|
947
|
+
*
|
|
948
|
+
* `known(false)` is a stronger claim than "we have not looked yet": it means
|
|
949
|
+
* the page's annotations were scanned and every annotation had a durable
|
|
950
|
+
* identity. Cloud/CDN manifests must only publish boolean weak flags from a
|
|
951
|
+
* known state.
|
|
952
|
+
*/
|
|
953
|
+
type WeakAnnotationState = {
|
|
954
|
+
kind: 'unknown';
|
|
955
|
+
} | {
|
|
956
|
+
kind: 'known';
|
|
957
|
+
hasAnyWeakAnnotations: boolean;
|
|
958
|
+
};
|
|
959
|
+
declare const UNKNOWN_WEAK_ANNOTATION_STATE: WeakAnnotationState;
|
|
960
|
+
declare function knownWeakAnnotationState(hasAnyWeakAnnotations: boolean): WeakAnnotationState;
|
|
961
|
+
//#endregion
|
|
962
|
+
//#region src/revision/PageState.d.ts
|
|
963
|
+
/**
|
|
964
|
+
* Per-page liveness envelope returned with annotation reads and mutation
|
|
965
|
+
* metadata. Deliberately scoped to annotation liveness: page identity,
|
|
966
|
+
* weak-ref revision state, and explicit knowledge about weak annotations.
|
|
967
|
+
*
|
|
968
|
+
* Geometry/display order is NOT here — it lives in `PageLayout` (returned by
|
|
969
|
+
* `pages.list()`), joined to this by `pageObjectNumber`. The two change on
|
|
970
|
+
* different cadences (annotation edits vs. structural ops), so they are kept
|
|
971
|
+
* orthogonal and never merged into one struct.
|
|
972
|
+
*/
|
|
973
|
+
interface PageState {
|
|
974
|
+
pageObjectNumber: PageObjectNumber;
|
|
975
|
+
revision: RevisionToken;
|
|
976
|
+
/**
|
|
977
|
+
* Explicit knowledge state for the weak-annotation scan. `unknown` means the
|
|
978
|
+
* page has not been scanned yet; it must not be published as a CDN/cache
|
|
979
|
+
* boolean.
|
|
980
|
+
*/
|
|
981
|
+
weakAnnotationState: WeakAnnotationState;
|
|
982
|
+
}
|
|
983
|
+
//#endregion
|
|
984
|
+
//#region src/mutation/MutationMeta.d.ts
|
|
985
|
+
/**
|
|
986
|
+
* Cache pin patch returned by cloud mutations after the durable DB transaction
|
|
987
|
+
* commits.
|
|
988
|
+
*
|
|
989
|
+
* `previousDocVersion` makes partial page deltas safe: clients may apply the
|
|
990
|
+
* patch only when their cached manifest is exactly at that version. Otherwise
|
|
991
|
+
* they must refresh instead of manufacturing a mixed-version manifest.
|
|
992
|
+
*
|
|
993
|
+
* Deliberately does NOT carry plane scopes: scopes only ever move
|
|
994
|
+
* base → layer, and each mutation kind knows exactly which planes it owns, so
|
|
995
|
+
* the client flips them locally when absorbing this delta (the monotone-flip
|
|
996
|
+
* rule); the manifest is the authoritative source and the 404 → refresh rail
|
|
997
|
+
* the backstop.
|
|
998
|
+
*/
|
|
999
|
+
interface CacheDelta {
|
|
1000
|
+
previousDocVersion: number;
|
|
1001
|
+
docVersion: number;
|
|
1002
|
+
/**
|
|
1003
|
+
* New doc-level bulk annotations pin, present when this mutation bumped
|
|
1004
|
+
* it (annotation CRUD, page insert/delete, redaction, flatten, form
|
|
1005
|
+
* structure — see `DocumentManifest.annotationsVersion`). Absorbing it
|
|
1006
|
+
* keeps the client's cached manifest addressing the fresh bulk leaf
|
|
1007
|
+
* without a 404-refresh round trip.
|
|
1008
|
+
*/
|
|
1009
|
+
annotationsVersion?: number;
|
|
1010
|
+
/**
|
|
1011
|
+
* The layer's write serial after this mutation and whether an artifact
|
|
1012
|
+
* now exists (cloud only). Absorbing them keeps the client's cached
|
|
1013
|
+
* manifest an honest `DocumentVersionRef` source between refreshes.
|
|
1014
|
+
*/
|
|
1015
|
+
layerVersion?: number;
|
|
1016
|
+
working?: boolean;
|
|
1017
|
+
pages: Array<{
|
|
1018
|
+
pageObjectNumber: PageObjectNumber;
|
|
1019
|
+
cache: CachePins;
|
|
1020
|
+
}>;
|
|
1021
|
+
}
|
|
1022
|
+
/**
|
|
1023
|
+
* Base envelope for every layer-mutating operation.
|
|
1024
|
+
*
|
|
1025
|
+
* `affectedPages` is the state delta. `cacheDelta` is the cloud/CDN URL pin
|
|
1026
|
+
* delta and is `null` for local engines.
|
|
1027
|
+
*/
|
|
1028
|
+
interface MutationMeta {
|
|
1029
|
+
affectedPages: PageState[];
|
|
1030
|
+
cacheDelta: CacheDelta | null;
|
|
1031
|
+
}
|
|
1032
|
+
//#endregion
|
|
1033
|
+
//#region src/signature/types.d.ts
|
|
1034
|
+
/**
|
|
1035
|
+
* Digital signatures, read side.
|
|
1036
|
+
*
|
|
1037
|
+
* Three facts, kept apart on purpose (see the signing plan): a signature
|
|
1038
|
+
* is a *bytes* fact (a `/ByteRange` + `/Contents` that seal a byte prefix
|
|
1039
|
+
* of the file), cryptography and trust live in `@embedpdf/core-signature`,
|
|
1040
|
+
* and what changed after a signature is judged per revision. Everything
|
|
1041
|
+
* here is read from the bytes the document was loaded from — for a layer
|
|
1042
|
+
* document, the base followed by the delta it was opened with — never
|
|
1043
|
+
* from unsaved in-memory edits.
|
|
1044
|
+
*/
|
|
1045
|
+
/**
|
|
1046
|
+
* Whether the engine enforces what a document's signatures forbid
|
|
1047
|
+
* (`protect`, the default: document-derived capabilities are subtracted
|
|
1048
|
+
* and locked fields refuse writes) or leaves every edit to the caller
|
|
1049
|
+
* (`permit`: for tools whose job is to produce or test invalid files).
|
|
1050
|
+
* Analysis never depends on it.
|
|
1051
|
+
*/
|
|
1052
|
+
type SignedDocumentPolicy = 'protect' | 'permit';
|
|
1053
|
+
/** Hash algorithms the engine can compute over a byte range. SHA-1 is read-only: legacy signatures verify with it, new ones never use it. */
|
|
1054
|
+
type DigestAlgorithm = 'sha1' | 'sha256' | 'sha384' | 'sha512';
|
|
1055
|
+
/** The two `/SubFilter` values the engine can author. Read-side `subFilter` is the raw name and may be anything. */
|
|
1056
|
+
type SignatureSubFilter = 'adbe.pkcs7.detached' | 'ETSI.CAdES.detached';
|
|
1057
|
+
type SignatureKind = 'signature' | 'timestamp';
|
|
1058
|
+
/**
|
|
1059
|
+
* How the signature's `/ByteRange` relates to the file:
|
|
1060
|
+
* - `whole-revision`: `[0,a) ∪ [b,c)` is exactly one chained revision
|
|
1061
|
+
* and the hole is this signature's own `/Contents`.
|
|
1062
|
+
* - `partial`: well-formed ranges that do not seal a revision.
|
|
1063
|
+
* - `malformed`: unusable ranges or a `/Contents` that is not one DER
|
|
1064
|
+
* object with zero padding.
|
|
1065
|
+
*/
|
|
1066
|
+
type SignatureCoverage = 'whole-revision' | 'partial' | 'malformed';
|
|
1067
|
+
/** DocMDP / `/Lock /P` permission values (ISO 32000-2 Table 257). */
|
|
1068
|
+
type DocMdpPermission = 1 | 2 | 3;
|
|
1069
|
+
/**
|
|
1070
|
+
* The modification level a signed document allows, as a product policy:
|
|
1071
|
+
* - `none`: no byte change at all (not a DocMDP value)
|
|
1072
|
+
* - `lta`: DSS and document timestamps only (P = 1)
|
|
1073
|
+
* - `fill`: + form fill, signatures, new signature fields (P = 2, and how a
|
|
1074
|
+
* validator reads an approval signature)
|
|
1075
|
+
* - `annotate`: + annotations (P = 3)
|
|
1076
|
+
*/
|
|
1077
|
+
type ModificationLevel = 'none' | 'lta' | 'fill' | 'annotate';
|
|
1078
|
+
type FieldLockAction = 'all' | 'include' | 'exclude';
|
|
1079
|
+
/** A FieldMDP transform or a field `/Lock`: which fields it freezes, and an optional `/P` tightening. */
|
|
1080
|
+
interface FieldLockSpec {
|
|
1081
|
+
action: FieldLockAction;
|
|
1082
|
+
/** Fully qualified names; a name covers its descendants (`group` covers `group.total`). Empty for `all`. */
|
|
1083
|
+
fields: string[];
|
|
1084
|
+
permission?: DocMdpPermission;
|
|
1085
|
+
}
|
|
1086
|
+
/**
|
|
1087
|
+
* One saved revision of the file: a byte prefix `[0, end)` closed by a
|
|
1088
|
+
* cross-reference section reachable from the final `startxref`.
|
|
1089
|
+
*/
|
|
1090
|
+
interface PdfRevision {
|
|
1091
|
+
/** 0 = the original document. */
|
|
1092
|
+
index: number;
|
|
1093
|
+
/** File offset just past the `%%EOF` line ending. */
|
|
1094
|
+
end: number;
|
|
1095
|
+
/** File offset of the cross-reference section the revision's startxref names. */
|
|
1096
|
+
xrefOffset: number;
|
|
1097
|
+
/** The signature that seals exactly this revision, when one does. */
|
|
1098
|
+
signatureIndex: number | null;
|
|
1099
|
+
}
|
|
1100
|
+
/** What the signer claimed in the signature dictionary. None of it is verified here; `/M` in particular is a claim. */
|
|
1101
|
+
interface SignatureSigner {
|
|
1102
|
+
name: string | null;
|
|
1103
|
+
reason: string | null;
|
|
1104
|
+
location: string | null;
|
|
1105
|
+
contactInfo: string | null;
|
|
1106
|
+
/** `/M` as written (PDF date string). */
|
|
1107
|
+
claimedTime: string | null;
|
|
1108
|
+
}
|
|
1109
|
+
/** The field's `/SV` seed value: what a signature on this field must satisfy. */
|
|
1110
|
+
interface SignatureSeedValue {
|
|
1111
|
+
/** `/Ff` bits: which of the entries below are requirements rather than suggestions. */
|
|
1112
|
+
requiredFlags: number;
|
|
1113
|
+
/** Which entries are present at all (same bit layout, plus Cert/MDP/TimeStamp). */
|
|
1114
|
+
presentFlags: number;
|
|
1115
|
+
/** `/V`: the seed-value parser capability the signer needs (1 = PDF 1.5, 2 = PDF 1.7). */
|
|
1116
|
+
version: number | null;
|
|
1117
|
+
/** `/MDP /P` when present: 0 = approval signature only. */
|
|
1118
|
+
mdp: 0 | 1 | 2 | 3 | null;
|
|
1119
|
+
filter: string | null;
|
|
1120
|
+
subFilters: string[];
|
|
1121
|
+
digestMethods: string[];
|
|
1122
|
+
reasons: string[];
|
|
1123
|
+
/** A required entry this engine does not implement — signing this field is refused. */
|
|
1124
|
+
unsupportedRequired: boolean;
|
|
1125
|
+
}
|
|
1126
|
+
interface SignatureDTO {
|
|
1127
|
+
/** Position in `SignatureSnapshot.signatures` (field order). */
|
|
1128
|
+
index: number;
|
|
1129
|
+
/** Always an `objectNumber` ref: the durable identity. */
|
|
1130
|
+
field: FormFieldRef;
|
|
1131
|
+
fieldName: string;
|
|
1132
|
+
widget: FormWidgetRef | null;
|
|
1133
|
+
signed: boolean;
|
|
1134
|
+
kind: SignatureKind;
|
|
1135
|
+
/** Raw `/Filter` and `/SubFilter` names. */
|
|
1136
|
+
filter: string | null;
|
|
1137
|
+
subFilter: string | null;
|
|
1138
|
+
byteRange: [number, number, number, number] | null;
|
|
1139
|
+
/** DER length of `/Contents` as its TLV declares (0 when unsigned or malformed). */
|
|
1140
|
+
contentsSize: number;
|
|
1141
|
+
/** `null` when unsigned. */
|
|
1142
|
+
coverage: SignatureCoverage | null;
|
|
1143
|
+
/** Which revision the signature seals; `null` unless coverage is `whole-revision`. */
|
|
1144
|
+
revisionIndex: number | null;
|
|
1145
|
+
signer: SignatureSigner;
|
|
1146
|
+
/** The DocMDP permission the signature carries (its `/Reference`), whether or not the catalog points at it. */
|
|
1147
|
+
docMdp: DocMdpPermission | null;
|
|
1148
|
+
/** `/Root /Perms /DocMDP` names this signature: it is THE certification. */
|
|
1149
|
+
catalogCertification: boolean;
|
|
1150
|
+
/** The FieldMDP transform this signature carries. */
|
|
1151
|
+
fieldMdp: FieldLockSpec | null;
|
|
1152
|
+
/** The field's own `/Lock`. */
|
|
1153
|
+
lock: FieldLockSpec | null;
|
|
1154
|
+
seedValue: SignatureSeedValue | null;
|
|
1155
|
+
}
|
|
1156
|
+
/** A lock an earlier signature established on the current bytes. */
|
|
1157
|
+
interface DocumentFieldLock {
|
|
1158
|
+
signatureIndex: number;
|
|
1159
|
+
source: 'fieldmdp' | 'lock';
|
|
1160
|
+
spec: FieldLockSpec;
|
|
1161
|
+
}
|
|
1162
|
+
/**
|
|
1163
|
+
* What the signatures already in a document mean for what comes after, in
|
|
1164
|
+
* two separate answers:
|
|
1165
|
+
*
|
|
1166
|
+
* - `enforced`: what a signer DECLARED — a certification's /P, a signed
|
|
1167
|
+
* field's /Lock /P. The engine refuses what it forbids (mapped onto
|
|
1168
|
+
* capabilities like encryption permission bits). A plain approval
|
|
1169
|
+
* signature declares nothing: `null`.
|
|
1170
|
+
* - `judged`: what a validator holds later changes to — the declared level,
|
|
1171
|
+
* or the approval baseline (`fill`: form fill-in and signing keep the
|
|
1172
|
+
* signature valid, anything else does not; Acrobat's reading, ISO 32000
|
|
1173
|
+
* is silent) when only approval signatures exist. Never refused, only
|
|
1174
|
+
* judged: an annotation after an approval signature is allowed and then
|
|
1175
|
+
* reads as invalidating, exactly as in Acrobat.
|
|
1176
|
+
*/
|
|
1177
|
+
interface DocumentProtection {
|
|
1178
|
+
/** Declared and enforced; `null` when nothing declared (unsigned, or approval signatures only). */
|
|
1179
|
+
enforced: ModificationLevel | null;
|
|
1180
|
+
/** Judged; `null` when nothing is signed. */
|
|
1181
|
+
judged: ModificationLevel | null;
|
|
1182
|
+
certification: {
|
|
1183
|
+
signatureIndex: number;
|
|
1184
|
+
permission: DocMdpPermission;
|
|
1185
|
+
} | null;
|
|
1186
|
+
fieldLocks: DocumentFieldLock[];
|
|
1187
|
+
/** The versioned product policy that derived this. */
|
|
1188
|
+
policyVersion: number;
|
|
1189
|
+
}
|
|
1190
|
+
interface SignatureSnapshot {
|
|
1191
|
+
/** `false` when the cross-reference chain is broken or was rebuilt: every byte fact is then indeterminate. */
|
|
1192
|
+
chainValid: boolean;
|
|
1193
|
+
/** Oldest first. Empty when `chainValid` is false. */
|
|
1194
|
+
revisions: PdfRevision[];
|
|
1195
|
+
signatures: SignatureDTO[];
|
|
1196
|
+
protection: DocumentProtection;
|
|
1197
|
+
}
|
|
1198
|
+
/**
|
|
1199
|
+
* The saved bytes a session is on. Locally the hash of the loaded bytes
|
|
1200
|
+
* (for a layer session: of its base); on the cloud the document's base
|
|
1201
|
+
* version. A completed signature always produces a new one.
|
|
1202
|
+
*/
|
|
1203
|
+
interface BaseVersionInfo {
|
|
1204
|
+
sha256: string;
|
|
1205
|
+
byteLength: number;
|
|
1206
|
+
}
|
|
1207
|
+
/**
|
|
1208
|
+
* What a signing candidate was built on. Both publish fences are named:
|
|
1209
|
+
* the base the candidate extends and how many edits over it it includes
|
|
1210
|
+
* (the layer's write serial on the cloud, the session's mutation sequence
|
|
1211
|
+
* locally). `complete` must present the same pair.
|
|
1212
|
+
*/
|
|
1213
|
+
interface DocumentVersionRef {
|
|
1214
|
+
baseSha256: string;
|
|
1215
|
+
editsVersion: number;
|
|
1216
|
+
}
|
|
1217
|
+
/**
|
|
1218
|
+
* Widget artwork for the signature, as a page of a PDF (the same path
|
|
1219
|
+
* stamps take: the page is drawn into the widget's appearance stream).
|
|
1220
|
+
*/
|
|
1221
|
+
interface SignatureAppearanceInput {
|
|
1222
|
+
/** A PDF whose page carries the artwork. */
|
|
1223
|
+
pdf: Uint8Array;
|
|
1224
|
+
/** Which page; default 0. */
|
|
1225
|
+
pageIndex?: number;
|
|
1226
|
+
}
|
|
1227
|
+
interface SignaturePrepareInput {
|
|
1228
|
+
field: FormFieldRef;
|
|
1229
|
+
kind?: SignatureKind;
|
|
1230
|
+
subFilter?: SignatureSubFilter;
|
|
1231
|
+
digest?: Exclude<DigestAlgorithm, 'sha1'>;
|
|
1232
|
+
/** Room reserved for the CMS, in bytes (256 .. 4 MiB). Default 8192. */
|
|
1233
|
+
contentsSize?: number;
|
|
1234
|
+
/** What the signature dictionary says about the signer: `/Name`, `/Reason`, `/Location`, `/ContactInfo`. */
|
|
1235
|
+
attribution?: {
|
|
1236
|
+
name?: string;
|
|
1237
|
+
reason?: string;
|
|
1238
|
+
location?: string;
|
|
1239
|
+
contactInfo?: string;
|
|
1240
|
+
};
|
|
1241
|
+
/** PDF date string for `/M`; default: now. */
|
|
1242
|
+
signingTime?: string;
|
|
1243
|
+
/** Make this the certification signature (`/Root /Perms /DocMDP`). Only ever the first signature. */
|
|
1244
|
+
certify?: {
|
|
1245
|
+
permission: DocMdpPermission;
|
|
1246
|
+
};
|
|
1247
|
+
/** FieldMDP for this signature plus a mirroring `/Lock` on the field. */
|
|
1248
|
+
lock?: FieldLockSpec;
|
|
1249
|
+
appearance?: SignatureAppearanceInput;
|
|
1250
|
+
}
|
|
1251
|
+
interface SignaturePrepared {
|
|
1252
|
+
signingId: string;
|
|
1253
|
+
digest: Uint8Array;
|
|
1254
|
+
algorithm: Exclude<DigestAlgorithm, 'sha1'>;
|
|
1255
|
+
byteRange: [number, number, number, number];
|
|
1256
|
+
contentsSize: number;
|
|
1257
|
+
subFilter: SignatureSubFilter | 'ETSI.RFC3161';
|
|
1258
|
+
expectedVersion: DocumentVersionRef;
|
|
1259
|
+
/** ISO timestamp after which the candidate is discarded. */
|
|
1260
|
+
expiresAt: string | null;
|
|
1261
|
+
}
|
|
1262
|
+
interface SignatureCompleteInput {
|
|
1263
|
+
signingId: string;
|
|
1264
|
+
/** The detached CMS (PKCS#7 / CAdES SignedData) over the prepared digest. */
|
|
1265
|
+
cms: Uint8Array;
|
|
1266
|
+
expectedVersion: DocumentVersionRef;
|
|
1267
|
+
}
|
|
1268
|
+
interface SignatureCompleteResult {
|
|
1269
|
+
/** `already-completed` on an idempotent replay with the same CMS. */
|
|
1270
|
+
status: 'completed' | 'already-completed';
|
|
1271
|
+
signature: SignatureDTO;
|
|
1272
|
+
/** The version the sealed bytes became. */
|
|
1273
|
+
version: BaseVersionInfo;
|
|
1274
|
+
/** What it was built on. */
|
|
1275
|
+
previous: DocumentVersionRef;
|
|
1276
|
+
/** What the document's signatures forbid from now on. */
|
|
1277
|
+
protection: DocumentProtection;
|
|
1278
|
+
/** Every page is re-pinned: the session moved to new bytes. */
|
|
1279
|
+
meta: MutationMeta;
|
|
1280
|
+
}
|
|
1281
|
+
interface SignatureAbortResult {
|
|
1282
|
+
status: 'aborted' | 'already-completed' | 'unknown';
|
|
1283
|
+
}
|
|
1284
|
+
//#endregion
|
|
872
1285
|
//#region src/auth/scope/resolver.d.ts
|
|
873
1286
|
/**
|
|
874
1287
|
* Resolved collab subject — the per-record identity bits used to test
|
|
@@ -886,13 +1299,13 @@ interface CollabTarget {
|
|
|
886
1299
|
* Wildcard `*` short-circuits to true. Anything not explicitly granted
|
|
887
1300
|
* (or expanded from `pdf.permissions`) is denied.
|
|
888
1301
|
*/
|
|
889
|
-
declare function checkCapability(capability: DocCapability, rawScope: ReadonlyArray<string>, pdfBits: PdfBits): boolean;
|
|
1302
|
+
declare function checkCapability(capability: DocCapability, rawScope: ReadonlyArray<string>, pdfBits: PdfBits, protection?: DocumentProtection | null): boolean;
|
|
890
1303
|
/**
|
|
891
1304
|
* True iff the scope grants AT LEAST ONE of `capabilities`. Convenience
|
|
892
1305
|
* for routes like `/text` (`doc.text.copy` OR `doc.text.search`) and
|
|
893
1306
|
* `/geometry` (`doc.text.select` OR `doc.text.search`).
|
|
894
1307
|
*/
|
|
895
|
-
declare function checkAnyCapability(capabilities: ReadonlyArray<DocCapability>, rawScope: ReadonlyArray<string>, pdfBits: PdfBits): boolean;
|
|
1308
|
+
declare function checkAnyCapability(capabilities: ReadonlyArray<DocCapability>, rawScope: ReadonlyArray<string>, pdfBits: PdfBits, protection?: DocumentProtection | null): boolean;
|
|
896
1309
|
/**
|
|
897
1310
|
* True iff the scope grants the collab action against the target record.
|
|
898
1311
|
*
|
|
@@ -933,13 +1346,13 @@ declare function checkCollab(action: CollabAction, target: CollabTarget, rawScop
|
|
|
933
1346
|
* before calling this. Returning the expanded set is useful for the
|
|
934
1347
|
* `/access` response's `effectiveScope` and for advisory UI surfacing.
|
|
935
1348
|
*/
|
|
936
|
-
declare function expandedCapabilities(parsed: ReadonlyArray<ParsedScope>, pdfBits: PdfBits): Set<DocCapability>;
|
|
1349
|
+
declare function expandedCapabilities(parsed: ReadonlyArray<ParsedScope>, pdfBits: PdfBits, protection?: DocumentProtection | null): Set<DocCapability>;
|
|
937
1350
|
/**
|
|
938
1351
|
* Convenience wrapper: takes the raw scope array, parses each entry,
|
|
939
1352
|
* returns the expanded capability set. Exposed for the `/access`
|
|
940
1353
|
* endpoint and for the SDK helper that surfaces `effectiveScope`.
|
|
941
1354
|
*/
|
|
942
|
-
declare function expandRawScope(rawScope: ReadonlyArray<string>, pdfBits: PdfBits): Set<DocCapability>;
|
|
1355
|
+
declare function expandRawScope(rawScope: ReadonlyArray<string>, pdfBits: PdfBits, protection?: DocumentProtection | null): Set<DocCapability>;
|
|
943
1356
|
/**
|
|
944
1357
|
* Test a single collab filter against a target record + the caller's
|
|
945
1358
|
* identity. Pure function — no side effects, no implicit rules.
|
|
@@ -1229,7 +1642,37 @@ interface OpenInputShare {
|
|
|
1229
1642
|
sharePassword?: string;
|
|
1230
1643
|
password?: string | null;
|
|
1231
1644
|
}
|
|
1232
|
-
type
|
|
1645
|
+
type OpenInputLayerFileSource = {
|
|
1646
|
+
kind: 'fresh';
|
|
1647
|
+
} | {
|
|
1648
|
+
kind: 'artifact';
|
|
1649
|
+
bytes: Uint8Array | ArrayBuffer;
|
|
1650
|
+
} | {
|
|
1651
|
+
kind: 'artifact-file';
|
|
1652
|
+
path: string;
|
|
1653
|
+
};
|
|
1654
|
+
/**
|
|
1655
|
+
* Local-engine layer open over a base FILE (Node runtimes only): the base
|
|
1656
|
+
* is range-read from disk by PDFium and never loaded into JS, and a
|
|
1657
|
+
* signing candidate for such a session is written beside it rather than
|
|
1658
|
+
* held in memory. What a server does for every document; useful locally
|
|
1659
|
+
* for large files.
|
|
1660
|
+
*
|
|
1661
|
+
* Rejected by `@cloudpdf/engine` and by the wasm runtime.
|
|
1662
|
+
*/
|
|
1663
|
+
interface OpenInputLayerFile {
|
|
1664
|
+
kind: 'layerFile';
|
|
1665
|
+
/** Caller-supplied stable id for this layer document handle. */
|
|
1666
|
+
id: string;
|
|
1667
|
+
/** Optional sharing key for the loaded base. Defaults to the path. */
|
|
1668
|
+
baseKey?: string;
|
|
1669
|
+
basePath: string;
|
|
1670
|
+
/** A verified SHA-256 (hex) of the base file, when the caller has one. */
|
|
1671
|
+
baseSha256?: string;
|
|
1672
|
+
layer?: OpenInputLayerFileSource;
|
|
1673
|
+
password?: string | null;
|
|
1674
|
+
}
|
|
1675
|
+
type OpenInput = OpenInputBytes | OpenInputLayerBytes | OpenInputLayerFile | OpenInputById | OpenInputToken | OpenInputShare;
|
|
1233
1676
|
interface OpenOptions {
|
|
1234
1677
|
password?: string | null;
|
|
1235
1678
|
/**
|
|
@@ -1818,46 +2261,6 @@ interface PageImageBlobSource {
|
|
|
1818
2261
|
}
|
|
1819
2262
|
declare function createPageImageHandle(result: PageImageResult, blobSource: PageImageBlobSource): PageImageHandle;
|
|
1820
2263
|
//#endregion
|
|
1821
|
-
//#region src/revision/WeakAnnotationState.d.ts
|
|
1822
|
-
/**
|
|
1823
|
-
* Tri-state knowledge about weak annotation identities on a page.
|
|
1824
|
-
*
|
|
1825
|
-
* `known(false)` is a stronger claim than "we have not looked yet": it means
|
|
1826
|
-
* the page's annotations were scanned and every annotation had a durable
|
|
1827
|
-
* identity. Cloud/CDN manifests must only publish boolean weak flags from a
|
|
1828
|
-
* known state.
|
|
1829
|
-
*/
|
|
1830
|
-
type WeakAnnotationState = {
|
|
1831
|
-
kind: 'unknown';
|
|
1832
|
-
} | {
|
|
1833
|
-
kind: 'known';
|
|
1834
|
-
hasAnyWeakAnnotations: boolean;
|
|
1835
|
-
};
|
|
1836
|
-
declare const UNKNOWN_WEAK_ANNOTATION_STATE: WeakAnnotationState;
|
|
1837
|
-
declare function knownWeakAnnotationState(hasAnyWeakAnnotations: boolean): WeakAnnotationState;
|
|
1838
|
-
//#endregion
|
|
1839
|
-
//#region src/revision/PageState.d.ts
|
|
1840
|
-
/**
|
|
1841
|
-
* Per-page liveness envelope returned with annotation reads and mutation
|
|
1842
|
-
* metadata. Deliberately scoped to annotation liveness: page identity,
|
|
1843
|
-
* weak-ref revision state, and explicit knowledge about weak annotations.
|
|
1844
|
-
*
|
|
1845
|
-
* Geometry/display order is NOT here — it lives in `PageLayout` (returned by
|
|
1846
|
-
* `pages.list()`), joined to this by `pageObjectNumber`. The two change on
|
|
1847
|
-
* different cadences (annotation edits vs. structural ops), so they are kept
|
|
1848
|
-
* orthogonal and never merged into one struct.
|
|
1849
|
-
*/
|
|
1850
|
-
interface PageState {
|
|
1851
|
-
pageObjectNumber: PageObjectNumber;
|
|
1852
|
-
revision: RevisionToken;
|
|
1853
|
-
/**
|
|
1854
|
-
* Explicit knowledge state for the weak-annotation scan. `unknown` means the
|
|
1855
|
-
* page has not been scanned yet; it must not be published as a CDN/cache
|
|
1856
|
-
* boolean.
|
|
1857
|
-
*/
|
|
1858
|
-
weakAnnotationState: WeakAnnotationState;
|
|
1859
|
-
}
|
|
1860
|
-
//#endregion
|
|
1861
2264
|
//#region src/dto/AnnotationRender.d.ts
|
|
1862
2265
|
/**
|
|
1863
2266
|
* Which `/AP` sub-dictionary to render. PDFium exposes Normal (`/N`),
|
|
@@ -1998,22 +2401,29 @@ interface AnnotationAppearanceManifest {
|
|
|
1998
2401
|
appearances: AnnotationAppearanceManifestEntry[];
|
|
1999
2402
|
}
|
|
2000
2403
|
//#endregion
|
|
2001
|
-
//#region src/dto/CachePins.d.ts
|
|
2002
|
-
/**
|
|
2003
|
-
* Per-page cache-busting integers embedded in immutable cloud/CDN leaf URLs.
|
|
2004
|
-
*
|
|
2005
|
-
* These are not page state. They are read coordinates for cacheable endpoints:
|
|
2006
|
-
* `/text` uses `contentVersion`; `/annotations` uses `annotationVersion`.
|
|
2007
|
-
*/
|
|
2008
|
-
interface CachePins {
|
|
2009
|
-
contentVersion: number;
|
|
2010
|
-
annotationVersion: number;
|
|
2011
|
-
}
|
|
2012
|
-
//#endregion
|
|
2013
2404
|
//#region src/dto/PdfSaveMode.d.ts
|
|
2014
2405
|
type PdfSaveMode = 'incremental' | 'rewrite';
|
|
2015
2406
|
declare const DEFAULT_PDF_SAVE_MODE: PdfSaveMode;
|
|
2016
2407
|
//#endregion
|
|
2408
|
+
//#region src/dto/SessionKind.d.ts
|
|
2409
|
+
/**
|
|
2410
|
+
* The shape a document session takes inside the engine.
|
|
2411
|
+
*
|
|
2412
|
+
* - `layer` (the default): the bytes become an immutable base with a layer of
|
|
2413
|
+
* edits on top. Reads fall through to the base; a write promotes only the
|
|
2414
|
+
* object it touches. A save appends exactly what changed, `download()` on an
|
|
2415
|
+
* unchanged document returns the loaded bytes verbatim, `downloadLayer()`
|
|
2416
|
+
* exports the edits alone, and a signature keeps its validity across later
|
|
2417
|
+
* edits because the signature dictionary is never rewritten.
|
|
2418
|
+
* - `plain`: one in-memory PDFium document, the classic shape. A save rewrites
|
|
2419
|
+
* every loaded object. Kept for comparison and for the rare embedder that
|
|
2420
|
+
* depends on that shape; a document that already carries a signature opens
|
|
2421
|
+
* as `layer` regardless, because a plain save would void it.
|
|
2422
|
+
*
|
|
2423
|
+
* The handle looks the same either way.
|
|
2424
|
+
*/
|
|
2425
|
+
type SessionKind = 'layer' | 'plain';
|
|
2426
|
+
//#endregion
|
|
2017
2427
|
//#region src/dto/FontSpec.d.ts
|
|
2018
2428
|
/**
|
|
2019
2429
|
* Runtime font registration DTOs.
|
|
@@ -2064,15 +2474,123 @@ interface FontSpec {
|
|
|
2064
2474
|
/** Font file bytes (TTF/OTF). */
|
|
2065
2475
|
data: Uint8Array | ArrayBuffer;
|
|
2066
2476
|
}
|
|
2067
|
-
/**
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2477
|
+
/**
|
|
2478
|
+
* The OS/2 `fsType` embedding permission of a registered font. Registration
|
|
2479
|
+
* refuses restricted and bitmap-only fonts outright. A preview-and-print font
|
|
2480
|
+
* renders existing text and may be embedded, but may not author NEW text
|
|
2481
|
+
* (a FreeText naming it fails, and missing-glyph fallback skips it) until
|
|
2482
|
+
* the application asserts a licence with {@link FontService.authorizeEditing}.
|
|
2483
|
+
*/
|
|
2484
|
+
type FontEmbeddingPermission = 'installable' | 'editable' | 'preview-and-print';
|
|
2485
|
+
/**
|
|
2486
|
+
* What the runtime resolved at registration. This is the persistent
|
|
2487
|
+
* identity of the face: a saved document names it by family, weight and
|
|
2488
|
+
* italic (the font descriptor's `/FontFamily`, `/FontWeight`,
|
|
2489
|
+
* `/ItalicAngle`), and a rich text body reads back with the same values, so
|
|
2490
|
+
* a host can map them back to its own `key`.
|
|
2491
|
+
*/
|
|
2492
|
+
interface FontIdentityInfo {
|
|
2493
|
+
/** The family as registered, else the font's own family name. */
|
|
2071
2494
|
readonly familyName: string;
|
|
2072
|
-
/**
|
|
2495
|
+
/** 100..900. */
|
|
2073
2496
|
readonly weight: number;
|
|
2074
2497
|
readonly italic: boolean;
|
|
2498
|
+
readonly embeddingPermission: FontEmbeddingPermission;
|
|
2499
|
+
/** Whether new text may be authored with the font (see the permission). */
|
|
2500
|
+
readonly editingAuthorized: boolean;
|
|
2501
|
+
/** True when the registered program is a static instance made from a
|
|
2502
|
+
* variable font at registration (axes pinned, `wght` to the weight). */
|
|
2503
|
+
readonly instanced: boolean;
|
|
2075
2504
|
}
|
|
2505
|
+
/** A successfully registered font. Returned by {@link FontService.register}. */
|
|
2506
|
+
interface FontHandle extends FontIdentityInfo {
|
|
2507
|
+
readonly key: FontKey;
|
|
2508
|
+
}
|
|
2509
|
+
//#endregion
|
|
2510
|
+
//#region src/dto/RichText.d.ts
|
|
2511
|
+
/**
|
|
2512
|
+
* Rich text of a FreeText annotation (`/RC` + `/DS`), the model the engine
|
|
2513
|
+
* lays out and writes. Runs carry only the style they override (deltas
|
|
2514
|
+
* against the body), exactly as the XHTML spans do, so changing the body
|
|
2515
|
+
* style moves every run that did not override that property.
|
|
2516
|
+
*
|
|
2517
|
+
* Families name faces the way a PDF does: a standard-14 family
|
|
2518
|
+
* (`"Helvetica"`), a font registered through `engine.fonts` (its family, or
|
|
2519
|
+
* its `key` — the engine resolves either), or a family already embedded in
|
|
2520
|
+
* the document. A family that resolves nowhere substitutes Helvetica; the
|
|
2521
|
+
* appearance still renders and the box still edits.
|
|
2522
|
+
*/
|
|
2523
|
+
type RichTextDecoration = 'underline' | 'line-through' | 'word';
|
|
2524
|
+
type RichTextScript = 'normal' | 'sub' | 'super';
|
|
2525
|
+
type RichTextAlign = TextAlignment | 'justify';
|
|
2526
|
+
type RichTextDirection = 'ltr' | 'rtl';
|
|
2527
|
+
interface RichTextRunStyle {
|
|
2528
|
+
family: string;
|
|
2529
|
+
/** 100..900. */
|
|
2530
|
+
weight: number;
|
|
2531
|
+
italic: boolean;
|
|
2532
|
+
/** Points. */
|
|
2533
|
+
size: number;
|
|
2534
|
+
/** `#RRGGBB`. */
|
|
2535
|
+
color: string;
|
|
2536
|
+
decoration: RichTextDecoration[];
|
|
2537
|
+
script: RichTextScript;
|
|
2538
|
+
/** Points, added after every glyph. */
|
|
2539
|
+
letterSpacing: number;
|
|
2540
|
+
/** 1 = normal (`xfa-font-horizontal-scale` / 100). */
|
|
2541
|
+
horizontalScale: number;
|
|
2542
|
+
/** CSS declarations the engine does not model, kept verbatim. */
|
|
2543
|
+
unknown?: string;
|
|
2544
|
+
}
|
|
2545
|
+
interface RichTextMargins {
|
|
2546
|
+
top: number;
|
|
2547
|
+
bottom: number;
|
|
2548
|
+
left: number;
|
|
2549
|
+
right: number;
|
|
2550
|
+
}
|
|
2551
|
+
interface RichTextParagraphProps {
|
|
2552
|
+
align: RichTextAlign;
|
|
2553
|
+
dir: RichTextDirection;
|
|
2554
|
+
/** Points; absent = the normal line box. */
|
|
2555
|
+
lineHeight?: number;
|
|
2556
|
+
margins?: RichTextMargins;
|
|
2557
|
+
textIndent?: number;
|
|
2558
|
+
unknown?: string;
|
|
2559
|
+
}
|
|
2560
|
+
interface RichTextRun {
|
|
2561
|
+
/** May contain `\r`: a hard line break inside the paragraph. */
|
|
2562
|
+
text: string;
|
|
2563
|
+
/** The properties this run overrides. Absent = the body style. */
|
|
2564
|
+
style?: Partial<RichTextRunStyle>;
|
|
2565
|
+
}
|
|
2566
|
+
/** A paragraph: its own alignment/direction when they differ from the body's. */
|
|
2567
|
+
interface RichTextParagraph extends Partial<RichTextParagraphProps> {
|
|
2568
|
+
runs: RichTextRun[];
|
|
2569
|
+
}
|
|
2570
|
+
type RichTextBody = RichTextRunStyle & RichTextParagraphProps;
|
|
2571
|
+
/** What an annotation reads back: a complete body, every paragraph resolved. */
|
|
2572
|
+
interface RichTextDocument {
|
|
2573
|
+
body: RichTextBody;
|
|
2574
|
+
paragraphs: RichTextParagraph[];
|
|
2575
|
+
}
|
|
2576
|
+
/**
|
|
2577
|
+
* What a draft or patch writes. `body` may be omitted (the annotation's
|
|
2578
|
+
* current body style stays — the "plain text replacement" of the patch
|
|
2579
|
+
* table) or partial (missing properties take the engine's defaults:
|
|
2580
|
+
* Helvetica 12 pt black, left-aligned, ltr).
|
|
2581
|
+
*/
|
|
2582
|
+
interface RichTextDocumentInput {
|
|
2583
|
+
body?: Partial<RichTextBody>;
|
|
2584
|
+
paragraphs: RichTextParagraph[];
|
|
2585
|
+
}
|
|
2586
|
+
/** The plain-text projection of a rich document: paragraphs joined by `\r`,
|
|
2587
|
+
* runs concatenated — what the engine writes to `/Contents`. */
|
|
2588
|
+
declare function richTextPlainText(doc: {
|
|
2589
|
+
paragraphs: readonly RichTextParagraph[];
|
|
2590
|
+
}): string;
|
|
2591
|
+
/** Plain text as rich paragraphs: one per line break, one run each, no
|
|
2592
|
+
* overrides (the engine's own `/Contents` fallback shape). */
|
|
2593
|
+
declare function richTextParagraphsFromPlainText(text: string): RichTextParagraph[];
|
|
2076
2594
|
//#endregion
|
|
2077
2595
|
//#region src/errors/EngineErrorCode.d.ts
|
|
2078
2596
|
declare const EngineErrorCode: {
|
|
@@ -2147,6 +2665,41 @@ declare const EngineErrorCode: {
|
|
|
2147
2665
|
* doesn't exist).
|
|
2148
2666
|
*/
|
|
2149
2667
|
readonly MalformedPdf: "MalformedPdf";
|
|
2668
|
+
/**
|
|
2669
|
+
* A signing candidate is parked on this session: every mutation is
|
|
2670
|
+
* refused until `signatures.complete` or `signatures.abort`.
|
|
2671
|
+
*/
|
|
2672
|
+
readonly SigningPending: "SigningPending";
|
|
2673
|
+
/** The candidate's TTL elapsed; prepare again. */
|
|
2674
|
+
readonly SigningExpired: "SigningExpired";
|
|
2675
|
+
/**
|
|
2676
|
+
* `complete` presented a version the candidate was not built on (the
|
|
2677
|
+
* document or the layer moved since `prepare`). The CMS cannot be
|
|
2678
|
+
* reused: it signs a digest of bytes that will never be the head.
|
|
2679
|
+
* Prepare again on the current version.
|
|
2680
|
+
*/
|
|
2681
|
+
readonly SigningVersionMismatch: "SigningVersionMismatch";
|
|
2682
|
+
/**
|
|
2683
|
+
* The engine refused to author the signature: the field is signed,
|
|
2684
|
+
* read-only, or locked by an earlier signature; a certification is
|
|
2685
|
+
* requested after a signature exists; the seed value requires what the
|
|
2686
|
+
* engine does not implement; the request is inconsistent. The message
|
|
2687
|
+
* names the reason.
|
|
2688
|
+
*/
|
|
2689
|
+
readonly SignatureRefused: "SignatureRefused";
|
|
2690
|
+
/**
|
|
2691
|
+
* A signature already in the document forbids this change (a
|
|
2692
|
+
* certification's permission, a FieldMDP or `/Lock`, or the approval
|
|
2693
|
+
* baseline). The message names the signature and the restriction. The
|
|
2694
|
+
* engine option `signedDocumentPolicy: 'permit'` disables the guard.
|
|
2695
|
+
*/
|
|
2696
|
+
readonly ProtectedDocument: "ProtectedDocument";
|
|
2697
|
+
/**
|
|
2698
|
+
* The layer is built on a base version that is no longer the
|
|
2699
|
+
* document's head (another signing completed); it can be read and
|
|
2700
|
+
* edited but not signed from.
|
|
2701
|
+
*/
|
|
2702
|
+
readonly StaleBase: "StaleBase";
|
|
2150
2703
|
};
|
|
2151
2704
|
type EngineErrorCode = (typeof EngineErrorCode)[keyof typeof EngineErrorCode];
|
|
2152
2705
|
//#endregion
|
|
@@ -3052,6 +3605,20 @@ interface DocumentManifest {
|
|
|
3052
3605
|
*/
|
|
3053
3606
|
auditHead: number;
|
|
3054
3607
|
baseSha: string;
|
|
3608
|
+
/**
|
|
3609
|
+
* The layer's write serial (`layers.current_version`; 0 for the base view
|
|
3610
|
+
* and for a never-written layer) — the `editsVersion` half of the
|
|
3611
|
+
* `DocumentVersionRef` a signing pins at `prepare` and checks at `complete`.
|
|
3612
|
+
*/
|
|
3613
|
+
layerVersion: number;
|
|
3614
|
+
/**
|
|
3615
|
+
* An artifact exists: the layer holds edits not yet sealed into a base
|
|
3616
|
+
* version. After a signature publishes a version the layer is clean again
|
|
3617
|
+
* while `layerVersion` keeps counting, so this is the only honest signal.
|
|
3618
|
+
*/
|
|
3619
|
+
working: boolean;
|
|
3620
|
+
/** Byte length of `baseSha`'s file — with the sha, the `BaseVersionInfo` a client signs. */
|
|
3621
|
+
baseByteLength: number;
|
|
3055
3622
|
/**
|
|
3056
3623
|
* Plane scopes (layer manifests only; absent on base manifests and
|
|
3057
3624
|
* on pre-plane servers = all-`'layer'`). Whole-layer by design — edge
|
|
@@ -3120,48 +3687,6 @@ type PdfLinkTargetWritable = Extract<PdfLinkTarget, {
|
|
|
3120
3687
|
kind: 'goto' | 'uri';
|
|
3121
3688
|
}>;
|
|
3122
3689
|
//#endregion
|
|
3123
|
-
//#region src/mutation/MutationMeta.d.ts
|
|
3124
|
-
/**
|
|
3125
|
-
* Cache pin patch returned by cloud mutations after the durable DB transaction
|
|
3126
|
-
* commits.
|
|
3127
|
-
*
|
|
3128
|
-
* `previousDocVersion` makes partial page deltas safe: clients may apply the
|
|
3129
|
-
* patch only when their cached manifest is exactly at that version. Otherwise
|
|
3130
|
-
* they must refresh instead of manufacturing a mixed-version manifest.
|
|
3131
|
-
*
|
|
3132
|
-
* Deliberately does NOT carry plane scopes: scopes only ever move
|
|
3133
|
-
* base → layer, and each mutation kind knows exactly which planes it owns, so
|
|
3134
|
-
* the client flips them locally when absorbing this delta (the monotone-flip
|
|
3135
|
-
* rule); the manifest is the authoritative source and the 404 → refresh rail
|
|
3136
|
-
* the backstop.
|
|
3137
|
-
*/
|
|
3138
|
-
interface CacheDelta {
|
|
3139
|
-
previousDocVersion: number;
|
|
3140
|
-
docVersion: number;
|
|
3141
|
-
/**
|
|
3142
|
-
* New doc-level bulk annotations pin, present when this mutation bumped
|
|
3143
|
-
* it (annotation CRUD, page insert/delete, redaction, flatten, form
|
|
3144
|
-
* structure — see `DocumentManifest.annotationsVersion`). Absorbing it
|
|
3145
|
-
* keeps the client's cached manifest addressing the fresh bulk leaf
|
|
3146
|
-
* without a 404-refresh round trip.
|
|
3147
|
-
*/
|
|
3148
|
-
annotationsVersion?: number;
|
|
3149
|
-
pages: Array<{
|
|
3150
|
-
pageObjectNumber: PageObjectNumber;
|
|
3151
|
-
cache: CachePins;
|
|
3152
|
-
}>;
|
|
3153
|
-
}
|
|
3154
|
-
/**
|
|
3155
|
-
* Base envelope for every layer-mutating operation.
|
|
3156
|
-
*
|
|
3157
|
-
* `affectedPages` is the state delta. `cacheDelta` is the cloud/CDN URL pin
|
|
3158
|
-
* delta and is `null` for local engines.
|
|
3159
|
-
*/
|
|
3160
|
-
interface MutationMeta {
|
|
3161
|
-
affectedPages: PageState[];
|
|
3162
|
-
cacheDelta: CacheDelta | null;
|
|
3163
|
-
}
|
|
3164
|
-
//#endregion
|
|
3165
3690
|
//#region src/mutation/RefetchReason.d.ts
|
|
3166
3691
|
/**
|
|
3167
3692
|
* Why a mutation invalidates the previously returned snapshot. Surfaced on
|
|
@@ -3360,66 +3885,6 @@ interface AnnotationMoveResult {
|
|
|
3360
3885
|
meta: AnnotationListMutationMeta;
|
|
3361
3886
|
}
|
|
3362
3887
|
//#endregion
|
|
3363
|
-
//#region src/identity/FormFieldRef.d.ts
|
|
3364
|
-
/**
|
|
3365
|
-
* How callers address a logical form field.
|
|
3366
|
-
*
|
|
3367
|
-
* - `objectNumber` — the indirect object number of the field dictionary.
|
|
3368
|
-
* ISO 32000 guarantees every real AcroForm field dictionary is an
|
|
3369
|
-
* indirect object, and the layer runtime never renumbers (frozen base +
|
|
3370
|
-
* incremental deltas), so this is the durable identity for the lifetime
|
|
3371
|
-
* of a document. Preferred for all engine calls.
|
|
3372
|
-
* - `fqn` — the fully qualified field name ("billing.name"). The portable,
|
|
3373
|
-
* semantic identity used by interchange formats (FDF/XFDF) and analytics;
|
|
3374
|
-
* survives document rewrites but is only as unique as the producer made
|
|
3375
|
-
* it. The engine resolves it against the reconciled field tree.
|
|
3376
|
-
*/
|
|
3377
|
-
type FormFieldRef = {
|
|
3378
|
-
kind: 'objectNumber';
|
|
3379
|
-
fieldObjectNumber: number;
|
|
3380
|
-
} | {
|
|
3381
|
-
kind: 'fqn';
|
|
3382
|
-
name: string;
|
|
3383
|
-
};
|
|
3384
|
-
/**
|
|
3385
|
-
* URL-safe encoding of a `FormFieldRef`, used by the cloud HTTP surface as
|
|
3386
|
-
* the `:fieldKey` route parameter. Decoded by the server back into a
|
|
3387
|
-
* `FormFieldRef` via `decodeFieldRefKey`. Mirrors the annotation plane's
|
|
3388
|
-
* `encodeStableIdKey` (`obj:42` / `nm:…`) so the two member-key syntaxes
|
|
3389
|
-
* read the same on the wire:
|
|
3390
|
-
*
|
|
3391
|
-
* `{ kind: 'objectNumber', fieldObjectNumber: 12 }` -> `'obj:12'`
|
|
3392
|
-
* `{ kind: 'fqn', name: 'billing.name' }` -> `'fqn:billing.name'`
|
|
3393
|
-
*
|
|
3394
|
-
* The caller is responsible for `encodeURIComponent`-ing the result before
|
|
3395
|
-
* splicing it into a URL path; the `wirePaths.layerFormField*` builders
|
|
3396
|
-
* already do that. FQNs are opaque strings and may contain anything; the
|
|
3397
|
-
* `fqn:` prefix keeps them unambiguous from numeric ids.
|
|
3398
|
-
*/
|
|
3399
|
-
declare function encodeFieldRefKey(ref: FormFieldRef): string;
|
|
3400
|
-
/**
|
|
3401
|
-
* Inverse of `encodeFieldRefKey`. Returns `null` for malformed input so the
|
|
3402
|
-
* server can answer 400 InvalidArg with a useful message instead of
|
|
3403
|
-
* throwing. The input is the already-`decodeURIComponent`-ed segment from
|
|
3404
|
-
* the route path. Empty FQNs are rejected: `fqn:` with no suffix is not a
|
|
3405
|
-
* valid identity.
|
|
3406
|
-
*/
|
|
3407
|
-
declare function decodeFieldRefKey(key: string): FormFieldRef | null;
|
|
3408
|
-
/** A widget annotation of a field, as the forms subsystem sees it. */
|
|
3409
|
-
interface FormWidgetRef {
|
|
3410
|
-
/**
|
|
3411
|
-
* Indirect object number of the widget annotation — the join key to the
|
|
3412
|
-
* annotation subsystem's `objectNumber` refs. `0` when the widget is
|
|
3413
|
-
* stored as a direct object (spec-violating; cannot be addressed).
|
|
3414
|
-
*/
|
|
3415
|
-
annotObjectNumber: number;
|
|
3416
|
-
/**
|
|
3417
|
-
* Object number of the page whose /Annots array references the widget.
|
|
3418
|
-
* `0` when the widget is not reachable from any page ("unplaced").
|
|
3419
|
-
*/
|
|
3420
|
-
pageObjectNumber: PageObjectNumber;
|
|
3421
|
-
}
|
|
3422
|
-
//#endregion
|
|
3423
3888
|
//#region src/forms/value-entry.d.ts
|
|
3424
3889
|
/** Lossless shape of a field's effective PDF `/V` or `/DV` object. */
|
|
3425
3890
|
type FormValueEntry = {
|
|
@@ -3769,11 +4234,20 @@ interface ListBoxFieldDraft extends FormFieldDraftBase {
|
|
|
3769
4234
|
options?: FormFieldOptionInput[];
|
|
3770
4235
|
widget?: WidgetPlacement;
|
|
3771
4236
|
}
|
|
4237
|
+
/**
|
|
4238
|
+
* A signature field: identity and (usually) one widget. Created unsigned;
|
|
4239
|
+
* signing it is `doc.signatures`' job, drawing a mark into it without
|
|
4240
|
+
* signing is `doc.forms.setSignatureAppearance`.
|
|
4241
|
+
*/
|
|
4242
|
+
interface SignatureFieldDraft extends FormFieldDraftBase {
|
|
4243
|
+
family: 'signature';
|
|
4244
|
+
widget?: WidgetPlacement;
|
|
4245
|
+
}
|
|
3772
4246
|
/**
|
|
3773
4247
|
* What `doc.forms.createField` takes: per-family, mirroring the DTO union.
|
|
3774
|
-
* Push buttons
|
|
4248
|
+
* Push buttons are not authorable.
|
|
3775
4249
|
*/
|
|
3776
|
-
type FormFieldDraft = TextFieldDraft | CheckboxFieldDraft | RadioFieldDraft | ComboBoxFieldDraft | ListBoxFieldDraft;
|
|
4250
|
+
type FormFieldDraft = TextFieldDraft | CheckboxFieldDraft | RadioFieldDraft | ComboBoxFieldDraft | ListBoxFieldDraft | SignatureFieldDraft;
|
|
3777
4251
|
//#endregion
|
|
3778
4252
|
//#region src/forms/patch.d.ts
|
|
3779
4253
|
/**
|
|
@@ -3952,6 +4426,488 @@ interface FormEffectsResult {
|
|
|
3952
4426
|
meta: MutationMeta | null;
|
|
3953
4427
|
}
|
|
3954
4428
|
//#endregion
|
|
4429
|
+
//#region src/signature/analysis/types.d.ts
|
|
4430
|
+
/**
|
|
4431
|
+
* The shallow serialisation of a PDF object as the fork's revision diff
|
|
4432
|
+
* emits it, parsed. A stream carries its length and SHA-256 rather than
|
|
4433
|
+
* its data; every nested value is direct (references stay references).
|
|
4434
|
+
*/
|
|
4435
|
+
type PdfValue = {
|
|
4436
|
+
t: 'dict';
|
|
4437
|
+
entries: Record<string, PdfValue>;
|
|
4438
|
+
} | {
|
|
4439
|
+
t: 'array';
|
|
4440
|
+
items: PdfValue[];
|
|
4441
|
+
} | {
|
|
4442
|
+
t: 'ref';
|
|
4443
|
+
num: number;
|
|
4444
|
+
} | {
|
|
4445
|
+
t: 'name';
|
|
4446
|
+
v: string;
|
|
4447
|
+
} | {
|
|
4448
|
+
t: 'string';
|
|
4449
|
+
v: string;
|
|
4450
|
+
} | {
|
|
4451
|
+
t: 'number';
|
|
4452
|
+
v: number;
|
|
4453
|
+
} | {
|
|
4454
|
+
t: 'bool';
|
|
4455
|
+
v: boolean;
|
|
4456
|
+
} | {
|
|
4457
|
+
t: 'null';
|
|
4458
|
+
} | {
|
|
4459
|
+
t: 'stream';
|
|
4460
|
+
length: number;
|
|
4461
|
+
sha256: string;
|
|
4462
|
+
dict: Record<string, PdfValue>;
|
|
4463
|
+
};
|
|
4464
|
+
/**
|
|
4465
|
+
* One inbound reference: the referring object (0 = the trailer) and the
|
|
4466
|
+
* label leading to the reference inside it. Edges are *anchored*: a
|
|
4467
|
+
* reference from an unchanged, non-structural object is resolved through
|
|
4468
|
+
* that object to the nearest changed or structural ancestor, and `via`
|
|
4469
|
+
* lists the objects it was resolved through, from the anchor's side down
|
|
4470
|
+
* to the object. A widget's appearance stream reached through an unchanged
|
|
4471
|
+
* indirect `/AP` dictionary is therefore
|
|
4472
|
+
* `{ parent: widget, label: 'AP/N', via: [apDict] }`.
|
|
4473
|
+
*/
|
|
4474
|
+
interface ObjectReferrer {
|
|
4475
|
+
parent: number;
|
|
4476
|
+
/** Escaped dictionary keys and `[n]` indexes joined by `/`, e.g. `AcroForm/Fields/[0]`, `AP/N`. */
|
|
4477
|
+
label: string;
|
|
4478
|
+
via?: number[];
|
|
4479
|
+
}
|
|
4480
|
+
type ObjectChangeType = 'added' | 'modified' | 'freed';
|
|
4481
|
+
/**
|
|
4482
|
+
* What reading the object from one revision's bytes came to. `failed` is a
|
|
4483
|
+
* live mapping whose bytes do not parse (or a stream whose data cannot be
|
|
4484
|
+
* read): the side is present and its value is NOT evidence - two failed
|
|
4485
|
+
* reads are never "the same value".
|
|
4486
|
+
*/
|
|
4487
|
+
type ObjectReadStatus = 'ok' | 'failed' | 'absent';
|
|
4488
|
+
/**
|
|
4489
|
+
* Facts about one revision as a whole that decide whether later changes to
|
|
4490
|
+
* it can be judged at all. Acrobat treats a document with a sparse
|
|
4491
|
+
* cross-reference table (object numbers below /Size with no entry of any
|
|
4492
|
+
* kind) or a reachable bare-reference object (an indirect object whose
|
|
4493
|
+
* whole body is a reference) as corrupted the moment any revision follows
|
|
4494
|
+
* the signed one; a verdict on such a base would disagree with it.
|
|
4495
|
+
*/
|
|
4496
|
+
interface RevisionHealth {
|
|
4497
|
+
sparseXref: boolean;
|
|
4498
|
+
bareReferences: number;
|
|
4499
|
+
/** False when the reachability walk hit its budget: usage on that side is a lower bound. */
|
|
4500
|
+
referrersComplete: boolean;
|
|
4501
|
+
}
|
|
4502
|
+
type ObjectChangeKind = 'dictionary' | 'stream' | 'array' | 'scalar' | 'xref' | 'objstm' | 'trailer';
|
|
4503
|
+
/**
|
|
4504
|
+
* One object whose cross-reference mapping differs between two revisions,
|
|
4505
|
+
* with its value in both and every object that references it in both.
|
|
4506
|
+
* The trailer is object number 0. Objects that serialise identically are
|
|
4507
|
+
* still listed (their mapping changed): the identical-rewrite rule judges them.
|
|
4508
|
+
*/
|
|
4509
|
+
interface ObjectChange {
|
|
4510
|
+
objectNumber: number;
|
|
4511
|
+
change: ObjectChangeType;
|
|
4512
|
+
kind: ObjectChangeKind;
|
|
4513
|
+
/**
|
|
4514
|
+
* Whether the object exists on each side. Derived from `change` by the
|
|
4515
|
+
* transport (`added` → no old side, `freed` → no new side); the trailer
|
|
4516
|
+
* exists on both sides and carries no generation numbers.
|
|
4517
|
+
*/
|
|
4518
|
+
present: {
|
|
4519
|
+
old: boolean;
|
|
4520
|
+
new: boolean;
|
|
4521
|
+
};
|
|
4522
|
+
generation: {
|
|
4523
|
+
old: number | null;
|
|
4524
|
+
new: number | null;
|
|
4525
|
+
};
|
|
4526
|
+
/**
|
|
4527
|
+
* The values, or null where the side is absent. A present side with a
|
|
4528
|
+
* null value is *missing evidence*: the evaluator treats it as truncated.
|
|
4529
|
+
*/
|
|
4530
|
+
value: {
|
|
4531
|
+
old: PdfValue | null;
|
|
4532
|
+
new: PdfValue | null;
|
|
4533
|
+
truncated: boolean;
|
|
4534
|
+
};
|
|
4535
|
+
/** The serialisation as emitted, for exact comparison. */
|
|
4536
|
+
raw: {
|
|
4537
|
+
old: string | null;
|
|
4538
|
+
new: string | null;
|
|
4539
|
+
};
|
|
4540
|
+
/** Per-side read status; absent on older transports (then `ok` for present sides). */
|
|
4541
|
+
read?: {
|
|
4542
|
+
old: ObjectReadStatus;
|
|
4543
|
+
new: ObjectReadStatus;
|
|
4544
|
+
};
|
|
4545
|
+
streamDataChanged: boolean;
|
|
4546
|
+
/** Anchored inbound edges per side (see `ObjectReferrer`). */
|
|
4547
|
+
usage: {
|
|
4548
|
+
old: ObjectReferrer[];
|
|
4549
|
+
new: ObjectReferrer[];
|
|
4550
|
+
};
|
|
4551
|
+
/**
|
|
4552
|
+
* Set when the transport could not resolve every edge within its budget
|
|
4553
|
+
* (depth, fan-out, total reads). Treated like a truncated value: the step
|
|
4554
|
+
* is indeterminate, never permitted.
|
|
4555
|
+
*/
|
|
4556
|
+
usageIncomplete?: boolean;
|
|
4557
|
+
}
|
|
4558
|
+
interface RevisionField {
|
|
4559
|
+
objectNumber: number;
|
|
4560
|
+
/** Fully qualified name. */
|
|
4561
|
+
name: string;
|
|
4562
|
+
family: FormFieldFamily;
|
|
4563
|
+
/** Widget annotation object numbers (a merged field-widget lists its own number). */
|
|
4564
|
+
widgets: number[];
|
|
4565
|
+
/**
|
|
4566
|
+
* The effective `/Ff` (inherited through the field tree), as the form
|
|
4567
|
+
* model sees it. A lock landing on a field writes `effective | ReadOnly`
|
|
4568
|
+
* into the terminal dictionary, so judging that write needs the effective
|
|
4569
|
+
* flags, not the terminal's own (possibly absent) entry.
|
|
4570
|
+
*/
|
|
4571
|
+
flags?: number;
|
|
4572
|
+
}
|
|
4573
|
+
/**
|
|
4574
|
+
* What one revision looks like structurally: enough to give every object
|
|
4575
|
+
* a role (the catalog, a page, a field, a widget, a signature value)
|
|
4576
|
+
* without walking paths from the root.
|
|
4577
|
+
*/
|
|
4578
|
+
interface RevisionStructure {
|
|
4579
|
+
root: number;
|
|
4580
|
+
acroForm: number;
|
|
4581
|
+
pagesRoot: number;
|
|
4582
|
+
pages: number[];
|
|
4583
|
+
fields: RevisionField[];
|
|
4584
|
+
signatures: SignatureDTO[];
|
|
4585
|
+
}
|
|
4586
|
+
interface ChangeFinding {
|
|
4587
|
+
rule: string;
|
|
4588
|
+
verdict: 'permitted' | 'forbidden' | 'incomplete';
|
|
4589
|
+
objectNumber: number;
|
|
4590
|
+
/** The specific edge (`parent:label`) this finding vouches for or condemns, when it is about one. */
|
|
4591
|
+
edge?: string;
|
|
4592
|
+
detail?: string;
|
|
4593
|
+
}
|
|
4594
|
+
type StepVerdict = 'unchanged' | 'permitted' | 'forbidden' | 'indeterminate';
|
|
4595
|
+
interface RevisionAnalysis {
|
|
4596
|
+
older: number;
|
|
4597
|
+
newer: number;
|
|
4598
|
+
/** The level in force after the restrictions established up to `older`. */
|
|
4599
|
+
levelInForce: ModificationLevel;
|
|
4600
|
+
/** Locks in force for this step (from the signatures in `older`). */
|
|
4601
|
+
locks: DocumentFieldLock[];
|
|
4602
|
+
verdict: StepVerdict;
|
|
4603
|
+
findings: ChangeFinding[];
|
|
4604
|
+
changes: ObjectChange[];
|
|
4605
|
+
}
|
|
4606
|
+
/**
|
|
4607
|
+
* A restriction in force for the judged window: a DocMDP certification or a
|
|
4608
|
+
* FieldMDP/lock, and whose it is. A FieldMDP lock is a promise the locking
|
|
4609
|
+
* signature makes about its own window and binds no other signature's
|
|
4610
|
+
* verdict (corpus v3/85); a certification's level is inherited by every
|
|
4611
|
+
* later window as well (conservative until observed otherwise).
|
|
4612
|
+
*/
|
|
4613
|
+
interface RestrictionAnchor {
|
|
4614
|
+
signatureIndex: number;
|
|
4615
|
+
revisionIndex: number;
|
|
4616
|
+
source: 'docmdp' | 'fieldmdp' | 'lock';
|
|
4617
|
+
/** Declared by the signature being judged, as opposed to inherited. */
|
|
4618
|
+
own: boolean;
|
|
4619
|
+
permission?: DocMdpPermission;
|
|
4620
|
+
fields?: FieldLockSpec;
|
|
4621
|
+
}
|
|
4622
|
+
/** One judgement with its evidence status; `complete: false` never coexists with a passing verdict. */
|
|
4623
|
+
interface Assessment {
|
|
4624
|
+
verdict: StepVerdict;
|
|
4625
|
+
complete: boolean;
|
|
4626
|
+
/** The finding that decided a forbidden or indeterminate verdict, or the most notable permitted one. */
|
|
4627
|
+
primary?: ChangeFinding;
|
|
4628
|
+
findings: ChangeFinding[];
|
|
4629
|
+
}
|
|
4630
|
+
interface AnalyzeInput {
|
|
4631
|
+
/** Start from the revision a signature seals, or from any revision. */
|
|
4632
|
+
since: {
|
|
4633
|
+
signatureIndex: number;
|
|
4634
|
+
} | {
|
|
4635
|
+
revisionIndex: number;
|
|
4636
|
+
};
|
|
4637
|
+
/**
|
|
4638
|
+
* `persisted` (default): the loaded bytes. `working-copy`: the session's
|
|
4639
|
+
* unsaved state, snapshotted the way a save would write it, as one more
|
|
4640
|
+
* revision. A revision index compares against history only.
|
|
4641
|
+
*/
|
|
4642
|
+
until?: 'persisted' | 'working-copy' | {
|
|
4643
|
+
revisionIndex: number;
|
|
4644
|
+
};
|
|
4645
|
+
/**
|
|
4646
|
+
* Exploratory only: evaluate as if this level were in force. The result
|
|
4647
|
+
* is tagged `mode: 'exploratory'` and never becomes a verdict.
|
|
4648
|
+
*/
|
|
4649
|
+
exploratoryLevel?: ModificationLevel;
|
|
4650
|
+
/**
|
|
4651
|
+
* `summary` (default): the verdict and its findings. `full`: also every
|
|
4652
|
+
* pairwise step between `since` and `until`, with each step's changes
|
|
4653
|
+
* (large; for diagnostics and tooling).
|
|
4654
|
+
*/
|
|
4655
|
+
detail?: 'summary' | 'full';
|
|
4656
|
+
}
|
|
4657
|
+
/**
|
|
4658
|
+
* How the judged revision stands against the revision the signature
|
|
4659
|
+
* sealed. The verdict is the NET state - `until` compared with `since`
|
|
4660
|
+
* directly - the way Acrobat judges an approval signature (a page changed
|
|
4661
|
+
* and byte-restored later is unchanged; corpus v2/15, 42, 44, v3/81, 85).
|
|
4662
|
+
* A certification window replays every intervening revision as well
|
|
4663
|
+
* (v3/82-83), and any step's violation joins the verdict.
|
|
4664
|
+
*/
|
|
4665
|
+
interface ChangeAnalysis {
|
|
4666
|
+
mode: 'authoritative' | 'exploratory';
|
|
4667
|
+
policyVersion: number;
|
|
4668
|
+
basis: {
|
|
4669
|
+
version: BaseVersionInfo;
|
|
4670
|
+
editsVersion: number;
|
|
4671
|
+
source: 'persisted' | 'working-copy';
|
|
4672
|
+
};
|
|
4673
|
+
since: {
|
|
4674
|
+
revisionIndex: number;
|
|
4675
|
+
signatureIndex: number | null;
|
|
4676
|
+
};
|
|
4677
|
+
until: {
|
|
4678
|
+
revisionIndex: number;
|
|
4679
|
+
};
|
|
4680
|
+
/** The restrictions this window was judged under (see `RestrictionAnchor`). */
|
|
4681
|
+
restrictions: RestrictionAnchor[];
|
|
4682
|
+
/** THE verdict, with the findings behind it. */
|
|
4683
|
+
current: Assessment & {
|
|
4684
|
+
method: 'net-state' | 'net-state+replay';
|
|
4685
|
+
};
|
|
4686
|
+
/** Facts about the revisions between `since` and `until`; never a verdict. */
|
|
4687
|
+
later: {
|
|
4688
|
+
revisionCount: number;
|
|
4689
|
+
/** Objects rewritten after `since` that hold the sealed value again in `until`. */
|
|
4690
|
+
undoneObjectNumbers: number[];
|
|
4691
|
+
};
|
|
4692
|
+
/** Equals `current.verdict`: one field for every consumer that only needs the answer. */
|
|
4693
|
+
verdict: StepVerdict;
|
|
4694
|
+
/**
|
|
4695
|
+
* The pairwise steps: the single step when one revision follows `since`,
|
|
4696
|
+
* every step of a certification replay, or every step with
|
|
4697
|
+
* `detail: 'full'`. Empty otherwise (a multi-revision approval window in
|
|
4698
|
+
* summary mode is judged on its net state alone).
|
|
4699
|
+
*/
|
|
4700
|
+
steps: RevisionAnalysis[];
|
|
4701
|
+
}
|
|
4702
|
+
/** Everything one pairwise step needs; JSON in, JSON out. */
|
|
4703
|
+
interface StepInput {
|
|
4704
|
+
older: number;
|
|
4705
|
+
newer: number;
|
|
4706
|
+
changes: ObjectChange[];
|
|
4707
|
+
before: RevisionStructure;
|
|
4708
|
+
after: RevisionStructure;
|
|
4709
|
+
/** What the transport learned about each revision as a whole (see `RevisionHealth`). */
|
|
4710
|
+
health?: {
|
|
4711
|
+
old: RevisionHealth;
|
|
4712
|
+
new: RevisionHealth;
|
|
4713
|
+
};
|
|
4714
|
+
/**
|
|
4715
|
+
* The restrictions to judge under. Absent: derived from every signature
|
|
4716
|
+
* in `before` (a revision-anchored analysis). Present: the judged
|
|
4717
|
+
* signature's own locks and the inherited certification level.
|
|
4718
|
+
*/
|
|
4719
|
+
restrictions?: {
|
|
4720
|
+
level: ModificationLevel;
|
|
4721
|
+
locks: DocumentFieldLock[];
|
|
4722
|
+
};
|
|
4723
|
+
/** Overrides the level derived from `before` (exploratory mode only). */
|
|
4724
|
+
levelOverride?: ModificationLevel;
|
|
4725
|
+
}
|
|
4726
|
+
//#endregion
|
|
4727
|
+
//#region src/signature/analysis/pdf-value.d.ts
|
|
4728
|
+
/**
|
|
4729
|
+
* Parse the fork's canonical shallow serialisation:
|
|
4730
|
+
* dict <</Key value/Key2 value>> (keys sorted, `#xx`-escaped)
|
|
4731
|
+
* array [item item]
|
|
4732
|
+
* ref n 0 R
|
|
4733
|
+
* stream stream(length,sha256hex)<<dict>>
|
|
4734
|
+
* name /Name (with #xx escapes)
|
|
4735
|
+
* string (literal with backslash escapes) or <hex>
|
|
4736
|
+
* number -12.5 bool true|false null
|
|
4737
|
+
*/
|
|
4738
|
+
declare function parsePdfValue(text: string): PdfValue;
|
|
4739
|
+
/** Structural equality of two parsed values. */
|
|
4740
|
+
declare function pdfValueEquals(a: PdfValue | null, b: PdfValue | null): boolean;
|
|
4741
|
+
declare function stableStringify(value: PdfValue | null): string;
|
|
4742
|
+
declare function dictEntries(value: PdfValue | null): Record<string, PdfValue> | null;
|
|
4743
|
+
/** Keys whose value differs (added, removed, or changed) between two dictionaries. */
|
|
4744
|
+
declare function changedKeys(a: PdfValue | null, b: PdfValue | null): Set<string>;
|
|
4745
|
+
declare function refsOf(value: PdfValue | null | undefined): number[];
|
|
4746
|
+
//#endregion
|
|
4747
|
+
//#region src/signature/analysis/evaluate.d.ts
|
|
4748
|
+
/** The level a step runs at, and the locks it enforces: what the OLDER revision's signatures established. */
|
|
4749
|
+
declare function restrictionsOf(before: RevisionStructure): {
|
|
4750
|
+
level: ModificationLevel;
|
|
4751
|
+
locks: DocumentFieldLock[];
|
|
4752
|
+
};
|
|
4753
|
+
/**
|
|
4754
|
+
* Judge one pairwise step. Every reference to a changed object, in the
|
|
4755
|
+
* older AND the newer revision, must be claimed by a rule that inspected
|
|
4756
|
+
* that use; an unclaimed reference is `unexplained` and forbidden. A
|
|
4757
|
+
* truncated value is `incomplete`, never permitted. Pure: JSON in, JSON
|
|
4758
|
+
* out, the same code in the browser worker, on the server and in tests.
|
|
4759
|
+
*/
|
|
4760
|
+
declare function evaluateStep(input: StepInput): RevisionAnalysis;
|
|
4761
|
+
/**
|
|
4762
|
+
* Same effective value on both sides: same canonical serialisation (keys
|
|
4763
|
+
* sorted, whitespace normalised - Acrobat compares dictionaries by value,
|
|
4764
|
+
* corpus v3/61-62), same stream data (by bytes, v2/45), and both sides
|
|
4765
|
+
* actually read. A failed read serialises as "null" and would match another
|
|
4766
|
+
* failed read - evidence of nothing.
|
|
4767
|
+
*/
|
|
4768
|
+
declare function sameEffectiveValue(c: ObjectChange): boolean;
|
|
4769
|
+
//#endregion
|
|
4770
|
+
//#region src/signature/analysis/restrictions.d.ts
|
|
4771
|
+
/**
|
|
4772
|
+
* The restrictions a window is judged under, read from the SEALED
|
|
4773
|
+
* revision's structure (what that revision declared, not what the final
|
|
4774
|
+
* file says).
|
|
4775
|
+
*
|
|
4776
|
+
* - `judged` given (a signature-anchored analysis): its own FieldMDP and
|
|
4777
|
+
* /Lock bind the window; other signatures' locks do not (corpus v3/85:
|
|
4778
|
+
* a second signature is valid with a fill of a field the first locked).
|
|
4779
|
+
* Every certification's level, own or earlier, applies (inherited:
|
|
4780
|
+
* conservative until observed otherwise), as does a /Lock's /P.
|
|
4781
|
+
* - no `judged` (a revision-anchored analysis): every signed signature's
|
|
4782
|
+
* locks and levels, as before.
|
|
4783
|
+
*/
|
|
4784
|
+
declare function restrictionsFor(before: RevisionStructure, judged: SignatureDTO | null): {
|
|
4785
|
+
anchors: RestrictionAnchor[];
|
|
4786
|
+
level: ModificationLevel;
|
|
4787
|
+
locks: DocumentFieldLock[];
|
|
4788
|
+
};
|
|
4789
|
+
//#endregion
|
|
4790
|
+
//#region src/signature/analysis/resolve.d.ts
|
|
4791
|
+
/**
|
|
4792
|
+
* Limits on edge resolution. Exceeding any of them makes the object's usage
|
|
4793
|
+
* `incomplete`, which the evaluator turns into an indeterminate step: an
|
|
4794
|
+
* adversary can make evidence expensive, never make it disappear.
|
|
4795
|
+
*/
|
|
4796
|
+
interface EdgeResolverBudget {
|
|
4797
|
+
/** Longest chain of unchanged objects an edge may be resolved through. */
|
|
4798
|
+
maxDepth: number;
|
|
4799
|
+
/** Most anchored edges one object may end up with. */
|
|
4800
|
+
maxEdgesPerObject: number;
|
|
4801
|
+
/** Most referrer reads per resolver (one per side per step). */
|
|
4802
|
+
maxReads: number;
|
|
4803
|
+
}
|
|
4804
|
+
declare const DEFAULT_EDGE_RESOLVER_BUDGET: EdgeResolverBudget;
|
|
4805
|
+
declare const USAGE_INCOMPLETE = "incomplete";
|
|
4806
|
+
type ResolvedUsage = ObjectReferrer[] | typeof USAGE_INCOMPLETE;
|
|
4807
|
+
/**
|
|
4808
|
+
* Resolves the raw inbound edges of an object (from the fork's referrer
|
|
4809
|
+
* index, which covers every reachable object of a revision) into edges
|
|
4810
|
+
* from *anchors*: the changed objects and the structural objects of the
|
|
4811
|
+
* revision (trailer, catalog, AcroForm, page tree root, pages, fields,
|
|
4812
|
+
* widgets). An edge from an unchanged, non-structural parent is replaced by
|
|
4813
|
+
* that parent's own anchored edges with the labels joined, so an
|
|
4814
|
+
* appearance stream under an unchanged indirect `/AP` dictionary reads
|
|
4815
|
+
* `widget:AP/N` rather than `apDict:N`.
|
|
4816
|
+
*
|
|
4817
|
+
* A graph traversal, not a path enumeration: results are memoised per
|
|
4818
|
+
* object, so a lattice of shared unchanged objects costs its size, not the
|
|
4819
|
+
* number of paths through it. Cycle edges contribute no anchors and are
|
|
4820
|
+
* skipped; a result computed while skipping one is not memoised.
|
|
4821
|
+
*/
|
|
4822
|
+
declare class EdgeResolver {
|
|
4823
|
+
private readonly read;
|
|
4824
|
+
private readonly anchors;
|
|
4825
|
+
private readonly budget;
|
|
4826
|
+
private readonly memo;
|
|
4827
|
+
private reads;
|
|
4828
|
+
private exhausted;
|
|
4829
|
+
constructor(read: (objectNumber: number) => ObjectReferrer[], anchors: ReadonlySet<number>, budget?: EdgeResolverBudget);
|
|
4830
|
+
/** Anchored edges of `objectNumber`, or `incomplete` when a budget was exceeded. */
|
|
4831
|
+
resolve(objectNumber: number): ResolvedUsage;
|
|
4832
|
+
private resolveInner;
|
|
4833
|
+
}
|
|
4834
|
+
//#endregion
|
|
4835
|
+
//#region src/signature/analysis/verdict.d.ts
|
|
4836
|
+
/** The worst of several verdicts (a certification replay's steps). */
|
|
4837
|
+
declare function worstVerdict(steps: ReadonlyArray<{
|
|
4838
|
+
verdict: StepVerdict;
|
|
4839
|
+
}>): StepVerdict;
|
|
4840
|
+
/**
|
|
4841
|
+
* One aggregation rule everywhere: a proven violation decides, whatever
|
|
4842
|
+
* else could not be established; missing evidence never becomes a pass.
|
|
4843
|
+
*/
|
|
4844
|
+
declare function conclude(findings: ReadonlyArray<ChangeFinding>, hasEffectiveChanges: boolean): StepVerdict;
|
|
4845
|
+
/** The finding that explains a verdict: the violation, else the gap, else the most notable allowance. */
|
|
4846
|
+
declare function primaryFinding(findings: ReadonlyArray<ChangeFinding>): ChangeFinding | undefined;
|
|
4847
|
+
declare function assessmentOf(step: RevisionAnalysis): Assessment;
|
|
4848
|
+
/**
|
|
4849
|
+
* A certification window: the net verdict and every replayed step, under
|
|
4850
|
+
* the same rule. A step's violation is a violation of the certification
|
|
4851
|
+
* even when the final state no longer shows it (corpus v3/83).
|
|
4852
|
+
*/
|
|
4853
|
+
declare function combine(net: RevisionAnalysis, steps: ReadonlyArray<RevisionAnalysis>): Assessment;
|
|
4854
|
+
//#endregion
|
|
4855
|
+
//#region src/signature/protection.d.ts
|
|
4856
|
+
/**
|
|
4857
|
+
* Bumped whenever the derivation below (or a judgement rule) changes meaning.
|
|
4858
|
+
* Rides every protection and every analysis, and keys the cloud's immutable
|
|
4859
|
+
* analysis URLs. v4 (the `signature-compat` corpus, 91 Acrobat observations):
|
|
4860
|
+
* each signature is judged on the net state of the document against the
|
|
4861
|
+
* revision it sealed; an object written again with the sealed value is not
|
|
4862
|
+
* a modification; an approval signature permits commenting; field
|
|
4863
|
+
* properties are judged per level; a lock binds only the signature that
|
|
4864
|
+
* declares it; a changed shared resource must be allowed by every use.
|
|
4865
|
+
*/
|
|
4866
|
+
declare const SIGNATURE_POLICY_VERSION = 4;
|
|
4867
|
+
/** DocMDP `/P` → the modification level it permits. */
|
|
4868
|
+
declare function levelFromPermission(permission: DocMdpPermission): ModificationLevel;
|
|
4869
|
+
declare function minLevel(a: ModificationLevel, b: ModificationLevel): ModificationLevel;
|
|
4870
|
+
/** Whether `level` (null = unsigned, everything allowed) permits changes of kind `needed`. */
|
|
4871
|
+
declare function levelAllows(level: ModificationLevel | null, needed: ModificationLevel): boolean;
|
|
4872
|
+
/** Hierarchical name match: `group` covers `group.total`. */
|
|
4873
|
+
declare function lockNameCovers(lockedName: string, fieldName: string): boolean;
|
|
4874
|
+
declare function lockCovers(spec: FieldLockSpec, fieldName: string): boolean;
|
|
4875
|
+
/**
|
|
4876
|
+
* Derive what the signatures already in a document mean for what comes
|
|
4877
|
+
* after. Pure and versioned (`SIGNATURE_POLICY_VERSION`); the same function
|
|
4878
|
+
* runs in the browser worker, on the native server, and in the conformance
|
|
4879
|
+
* suite.
|
|
4880
|
+
*
|
|
4881
|
+
* enforced = min(certification P, every signed field's /Lock /P), or null
|
|
4882
|
+
* when nothing was declared. What the engine refuses.
|
|
4883
|
+
* judged = enforced, or the approval baseline when signatures exist
|
|
4884
|
+
* without a declaration, or null when nothing is signed. What
|
|
4885
|
+
* the revision analysis judges later changes against. A
|
|
4886
|
+
* declaration governs the judgement too: a P=3 certifier really
|
|
4887
|
+
* did allow annotations.
|
|
4888
|
+
* fieldLocks = every signed signature's FieldMDP and the /Lock of every
|
|
4889
|
+
* signed field. Unsigned fields' /Lock entries describe a
|
|
4890
|
+
* FUTURE signature and lock nothing yet.
|
|
4891
|
+
*/
|
|
4892
|
+
declare function deriveProtection(signatures: ReadonlyArray<SignatureDTO>): DocumentProtection;
|
|
4893
|
+
/** The lock that freezes `fieldName`, if any. */
|
|
4894
|
+
declare function fieldLockFor(protection: DocumentProtection, fieldName: string): DocumentFieldLock | null;
|
|
4895
|
+
/**
|
|
4896
|
+
* The capabilities a protection removes from every caller, admin scope
|
|
4897
|
+
* included — document-derived authority, exactly like encryption bits.
|
|
4898
|
+
*
|
|
4899
|
+
* Only what was DECLARED is refused: a refusal is a promise a signer made,
|
|
4900
|
+
* never a guess about a validator. A certification (or a lock with /P)
|
|
4901
|
+
* declares what may follow, and everything outside that — page edits,
|
|
4902
|
+
* redaction, field authoring, attachments, and below P=3 annotations, below
|
|
4903
|
+
* P=2 form fill — is refused. A plain approval signature declares nothing:
|
|
4904
|
+
* the same edits stay possible and are then JUDGED, the verdict saying the
|
|
4905
|
+
* signature no longer holds, exactly as Acrobat does. The one exception is a
|
|
4906
|
+
* rewrite: it does not invalidate signatures, it erases them, so any signed
|
|
4907
|
+
* document refuses it. Per-field locks are enforced by the form mutator.
|
|
4908
|
+
*/
|
|
4909
|
+
declare function protectedCapabilities(protection: DocumentProtection | null): Set<DocCapability>;
|
|
4910
|
+
//#endregion
|
|
3955
4911
|
//#region src/mutation/FormMutationResults.d.ts
|
|
3956
4912
|
/**
|
|
3957
4913
|
* Result of a value write (`setValue` / `reset`).
|
|
@@ -5231,6 +6187,12 @@ interface FreeTextDraft extends AnnotationDraftBase {
|
|
|
5231
6187
|
fontFamily: FreeTextFont;
|
|
5232
6188
|
fontSize: number;
|
|
5233
6189
|
textAlign: TextAlignment;
|
|
6190
|
+
/**
|
|
6191
|
+
* Rich text (`/RC`). When given, its body is the annotation's body style
|
|
6192
|
+
* (the `/DA` font and size follow it) and its paragraphs are the text;
|
|
6193
|
+
* `contents`, if also given, must equal its plain projection.
|
|
6194
|
+
*/
|
|
6195
|
+
richText?: RichTextDocumentInput;
|
|
5234
6196
|
/** `/Rect` bounding box — required (computed by the caller/plugin). */
|
|
5235
6197
|
rect: PdfRect;
|
|
5236
6198
|
/** `/DA` colour (border + default text). */
|
|
@@ -5265,12 +6227,24 @@ type FreeTextAnnotationDTO = AnnotationBase & {
|
|
|
5265
6227
|
subtype: 'free-text';
|
|
5266
6228
|
/** `/IT` intent. */
|
|
5267
6229
|
intent: FreeTextIntent;
|
|
5268
|
-
/**
|
|
5269
|
-
|
|
6230
|
+
/**
|
|
6231
|
+
* The body face: a standard font name, the `key` of a registered font
|
|
6232
|
+
* whose family/weight/italic match the body, or — for a face the
|
|
6233
|
+
* document embeds but this session did not register — its family name.
|
|
6234
|
+
*/
|
|
6235
|
+
fontFamily: FreeTextFont;
|
|
5270
6236
|
/** `/DA` font size, in points. */
|
|
5271
6237
|
fontSize: number;
|
|
5272
6238
|
/** `/Q` horizontal text alignment. */
|
|
5273
6239
|
textAlign: TextAlignment;
|
|
6240
|
+
/**
|
|
6241
|
+
* The text, as a rich document — always. The annotation's `/RC` when it has
|
|
6242
|
+
* one, else the same shape synthesised from `/Contents`, `/DA` and `/Q`
|
|
6243
|
+
* (one paragraph per line, no run deltas). `contents` is its plain
|
|
6244
|
+
* projection. Every write goes back through the rich path, so a box has
|
|
6245
|
+
* no "plain mode" to fall out of.
|
|
6246
|
+
*/
|
|
6247
|
+
richText: RichTextDocument;
|
|
5274
6248
|
/** `/DA` colour: the border colour and the default text colour. */
|
|
5275
6249
|
color: Color;
|
|
5276
6250
|
/** Text colour override (`TextColor`). Absent when the text follows `color`. */
|
|
@@ -5305,6 +6279,16 @@ interface FreeTextPatch extends AnnotationPatchBase {
|
|
|
5305
6279
|
fontFamily?: FreeTextFont;
|
|
5306
6280
|
fontSize?: number;
|
|
5307
6281
|
textAlign?: TextAlignment;
|
|
6282
|
+
/**
|
|
6283
|
+
* Rich replacement: `/RC`, `/DS`, `/DA`, `/Contents` and the appearance
|
|
6284
|
+
* are all regenerated. A patch that also carries `contents` must agree
|
|
6285
|
+
* with the rich text's plain projection (`InvalidArg` otherwise). A
|
|
6286
|
+
* `contents`-only patch on an annotation with `/RC` rewrites the rich
|
|
6287
|
+
* text as body-style paragraphs: run formatting is lost by design.
|
|
6288
|
+
* `fontFamily` / `fontSize` / `fontColor` on such an annotation change the
|
|
6289
|
+
* body style; runs are deltas, so every run that did not override follows.
|
|
6290
|
+
*/
|
|
6291
|
+
richText?: RichTextDocumentInput;
|
|
5308
6292
|
rect?: PdfRect;
|
|
5309
6293
|
color?: Color;
|
|
5310
6294
|
fontColor?: Color;
|
|
@@ -5883,5 +6867,5 @@ interface AnnotationListPageSnapshot {
|
|
|
5883
6867
|
annotations: AnnotationDTO[];
|
|
5884
6868
|
}
|
|
5885
6869
|
//#endregion
|
|
5886
|
-
export { CaretDraftSchema as $, FilledStyleFields as $a, Color as $c, FormFieldRef as $i, PageNameResult as $n, AnnotationAppearanceRaster as $o, FormImportResult as $r, PageLayout as $s, CircleDraftSchema as $t, FileAttachmentWireDraftSchema as A, buildCommentThreads as Aa, PDF_BITS as Ac, FormKind as Ai, PdfActionWarning as Al, HighlightDraft as An, AnnotationBase as Ao, toOriginalRange as Ar, glyphLooseQuad as As, LineDraft as At, StampAnnotationDTO as B, PatchOfKind as Ba, ParsedScope as Bc, FormFieldDTO as Bi, DocumentMetadata as Bl, PageDeleteResult as Bn, EngineErrorCode as Bo, TextLayoutFrame as Br, PdfOriginSize as Bs, PolygonPatch as Bt, RedactDraft as C, ManifestPage as Ca, expandedCapabilities as Cc, ComboBoxFieldDraft as Ci, ActionReadBudget as Cl, UnderlineAnnotationDTO as Cn, ANNOTATION_SUBTYPES as Co, wordAt as Cr, PageGeometryGlyph as Cs, LinkAnnotationDTO as Ct, FileAttachmentDTOSchema as D, CommentThread as Da, PermissionDenied as Dc, RadioFieldDraft as Di, PdfActionTargetRef as Dl, HighlightPatchSchema as Dn, PdfAnnotationSubtypeCode as Do, SEARCH_FOLD_VERSION as Dr, RotatedGeometryRun as Ds, LinePatchSchema as Dt, WidgetDraft as E, BuildCommentThreadsOptions as Ea, MissingIdentity as Ec, ListBoxFieldDraft as Ei, PdfActionNode as El, HighlightDraftSchema as En, PDF_SUBTYPE_TO_CODE as Eo, FoldedText as Er, RotatedGeometryGlyph as Es, LineDraftSchema as Et, StampDTOSchema as F, classifyRelation as Fa, CollabFilter as Fc, WidgetStyleFields as Fi, SubmitFormPayload as Fl, RedactionApplyScope as Fn, EngineError as Fo, SearchSlice as Fr, boundaryTextOffset as Fs, PolylineAnnotationDTO as Ft, TextDTOSchema as G, FileAttachmentDraft as Ga, AnnotationRef as Gc, ListBoxFieldDTO as Gi, AnnotationFlattenInput as Gn, PdfSaveMode as Go, expandTextRangeToWord as Gr, pdfQuadFromCorners as Gs, VertexPatchFields as Gt, StampFit as H, AttachmentDeleteResult as Ha, ParsedWildcard as Hc, FormFieldFlags as Hi, PageRotateResult as Hn, FontKey as Ho, TextLayoutRun as Hr, normalizePdfRect as Hs, PolygonDraft as Ht, StampWireDraftSchema as I, refKey as Ia, DocCapability as Ic, WidgetStylePatchFields as Ii, decodeSubmitFormFlags as Il, RedactionApplyStatus as In, EngineErrorOptions as Io, SearchSliceBudget as Ir, charBoundaryAtTextOffset as Is, PolylineDraft as It, TextPatch as J, WireAttachmentFile as Ja, AnnotationBorderStyle as Jc, SignatureFieldDTO as Ji, PageFlattenInput as Jn, AnnotationAppearanceImageOptions as Jo, textSegmentsForRange as Jr, pdfRectSize as Js, SquarePatchSchema as Jt, TextDraftSchema as K, FileAttachmentIcon as Ka, RevisionToken as Kc, PushButtonFieldDTO as Ki, AnnotationFlattenItemResult as Kn, CachePins as Ko, textGlyphAt as Kr, pdfRectFromOriginSize as Ks, SquareDTOSchema as Kt, StampWirePatchSchema as L, AnnotationKindModule as La, IdentityClaims as Lc, CheckboxFieldDTO as Li, PdfDestination as Ll, PAGE_INSERT_BLANK_MAX_COUNT as Ln, SerializedEngineError as Lo, SearchSnippet as Lr, charMapViolation as Ls, PolygonDTOSchema as Lt, FileAttachmentPatch as M, AnnotationRelationKind as Ma, AnnotationActor as Mc, WidgetAppearance as Mi, PdfFieldActions as Ml, MetadataUpdateResult as Mn, AnnotationStableId as Mo, SearchMode as Mr, PageTextSnapshot as Ms, PolylineDraftSchema as Mt, FileAttachmentAnnotationDTO as N, AnnotationThread as Na, CollabAction as Nc, WidgetAppearanceSchema as Ni, PdfPageActions as Nl, RedactionApplyItemResult as Nn, decodeStableIdKey as No, SearchQuery as Nr, CharBoundaryBias as Ns, PolylinePatchSchema as Nt, FileAttachmentIconSchema as O, CommentThreadReview as Oa, parseScope as Oc, TextFieldDraft as Oi, PdfActionTree as Ol, HighlightPatch as On, subtypeFromCode as Oo, SearchMatchRange as Or, UprightGeometryRun as Os, LinePatch as Ot, ResourceRefSchema as P, buildThreads as Pa, CollabEntity as Pc, WidgetStyleDraftFields as Pi, SubmitFormFlags as Pl, RedactionApplyResult as Pn, encodeStableIdKey as Po, SearchRequest as Pr, CharMapAnchor as Ps, PolylinePatch as Pt, CaretDTOSchema as Q, FilledStyleDraftFields as Qa, CaretIntent as Qc, FormValueEntry as Qi, PageFlattenUsage as Qn, AnnotationAppearanceMode as Qo, FormFieldUpdateResult as Qr, PageBoxes as Qs, CircleDTOSchema as Qt, StampPatch as R, DTOOfKind as Ra, ParsedCapability as Rc, ComboBoxFieldDTO as Ri, PageObjectNumber as Rl, PageInsertBlankSpec as Rn, deserializeError as Ro, PageTextLayout as Rr, charRangeForTextOffsets as Rs, PolygonDraftSchema as Rt, RedactAnnotationDTO as S, DocumentManifest as Sa, expandRawScope as Sc, CheckboxFieldDraft as Si, PdfSize as Sl, UnderlinePatch as Sn, resolveBinarySource as So, matchLiteral as Sr, createPageImageHandle as Ss, LinkPatch as St, WidgetAnnotationDTO as T, LayerScopes as Ta, InvalidScope as Tc, FormFieldOptionInput as Ti, NamedJavaScriptAction as Tl, HighlightDTOSchema as Tn, PDF_CODE_TO_SUBTYPE as To, FoldOptions as Tr, PageGeometrySnapshot as Ts, LineDTOSchema as Tt, StampWireDraft as U, AttachmentsCache as Ua, PdfBits as Uc, FormFieldOption as Ui, PageRotateInput as Un, FontSpec as Uo, buildPageTextLayout as Ur, pdfQuadBounds as Us, VertexAnnotationFields as Ut, StampDraft as V, AttachmentCreateResult as Va, ParsedVirtual as Vc, FormFieldFamily as Vi, DocumentMetadataTrapped as Vl, PageDeleteInput as Vn, FontHandle as Vo, TextLayoutGlyph as Vr, PdfQuadCorners as Vs, PolygonAnnotationDTO as Vt, NoteIconSchema as W, normalizeAttachmentFileSource as Wa, AnnotationDraftBase as Wc, FormFieldOrigin as Wi, AnnotationAppearanceExportInput as Wn, DEFAULT_PDF_SAVE_MODE as Wo, expandTextRangeToLine as Wr, pdfQuadCorners as Ws, VertexDraftFields as Wt, NoteIcon as X, ColorStyleFields as Xa, AnnotationReplyType as Xc, ToggleFieldWidget as Xi, PageFlattenResult as Xn, AnnotationAppearanceManifest as Xo, FormFieldCreateResult as Xr, pdfRectWidth as Xs, SquareAnnotationDTO as Xt, TextAnnotationDTO as Y, ColorStyleDraftFields as Ya, AnnotationFlags as Yc, TextFieldDTO as Yi, PageFlattenItemResult as Yn, AnnotationAppearanceImagesResult as Yo, FormDataExport as Yr, pdfRectToOriginSize as Ys, SquarePatch as Yt, TextDraft as Z, ColorStylePatchFields as Za, BlendMode as Zc, UnknownFieldDTO as Zi, PageFlattenStatus as Zn, AnnotationAppearanceManifestEntry as Zo, FormFieldDeleteResult as Zr, PageListSnapshot as Zs, SquareDraft as Zt, UnsupportedPatchSchema as _, RefetchReason as _a, CollabTarget as _c, ComboBoxFieldPatch as _i, LinePoints as _l, SquigglyAnnotationDTO as _n, BinaryPayload as _o, SearchRegexValidation as _r, PageRenderFormat as _s, LinkDraftSchema as _t, AnnotationDTOSchema as a, AnnotationMoveResult as aa, OpenInputById as ac, FormEffectStatus as ai, NO_ANNOTATION_FLAGS as al, ShapeDraftFields as an, AttachmentFileBase as ao, PageMoveInput as ar, WeakAnnotationState as as, FreeTextDraftSchema as at, UnsupportedAnnotationDTO as b, PdfLinkTarget as ba, checkCollab as bc, RadioFieldPatch as bi, PdfRect as bl, UnderlineDraftSchema as bn, WireResource as bo, validateSearchRegex as br, PageRenderTarget as bs, PdfLinkTargetWritableSchema as bt, AnnotationKind as c, AppearanceImpact as ca, OpenInputLayerSource as cc, FormSubmissionEntry as ci, Rect as cl, StrikeoutDraftSchema as cn, EmbeddedFileItem as co, searchRectsForRange as cr, PageImageHandle as cs, FreeTextAnnotationDTO as ct, AnnotationSubtypeOfKind as d, semanticEqual as da, OpenOptions as dc, FormSubmissionReceiptSchema as di, StandardFont as dl, StrikeoutAnnotationDTO as dn, NormalizedPatch as do, buildSnippet as dr, PageImageResult as ds, InkDraftSchema as dt, FormWidgetRef as ea, PageRotation as ec, FormRepairResult as ei, FreeTextFont as el, CirclePatchSchema as en, FilledStylePatchFields as eo, PageNameInput as er, AnnotationAppearanceRenderOptions as es, CaretPatchSchema as et, KIND_BY_SUBTYPE as f, AnnotationMutationKind as fa, TokenSource as fc, FormSubmissionRequest as fi, StrikeoutIntent as fl, StrikeoutDraft as fn, normalizeAnnotationDraft as fo, matchPageText as fr, PageImageSource as fs, InkPatchSchema as ft, UnsupportedDraftSchema as g, AnnotationListMutationMeta as ga, pdfPermissions as gc, CheckboxFieldPatch as gi, InkStroke as gl, SquigglyPatch as gn, sniffBinaryMetadata as go, SearchRegexIssue as gr, PageRenderEncodedFormat as gs, LinkDTOSchema as gt, UnsupportedDTOSchema as h, shiftsExistingAnnotationIndices as ha, materializePdfPermissions as hc, FormFieldValue as hi, InkList as hl, SquigglyPatchSchema as hn, BinaryMimeType as ho, SearchQueryValidation as hr, PageRenderBackground as hs, InkDraft as ht, AnnotationDTO as i, AnnotationDeleteResult as ia, OpenInput as ic, FormEffectResult as ii, LineEndings as il, ShapeAnnotationFields as in, AttachmentContent as io, PageStructureCache as ir, UNKNOWN_WEAK_ANNOTATION_STATE as is, FreeTextDTOSchema as it, WireAttachmentFileSchema as j, isStateAnnotation as ja, decodePdfBits as jc, FormSnapshot as ji, PdfAnnotationActions as jl, MetadataCache as jn, AnnotationIdentityQuality as jo, SearchMatch as jr, isRotatedGeometryRun as js, PolylineDTOSchema as jt, FileAttachmentPatchSchema as k, ReviewStatus as ka, validateScopeArray as kc, WidgetPlacement as ki, PdfActionType as kl, HighlightAnnotationDTO as kn, AnnotationPatchBase as ko, foldText as kr, glyphLooseBounds as ks, LineAnnotationDTO as kt, AnnotationPatch as l, AppearanceOutcome as la, OpenInputShare as lc, FormSubmissionEntrySchema as li, Rotation as ll, StrikeoutPatchSchema as ln, EmbeddedFileRef as lo, searchSegmentsForRange as lr, PageImageObjectUrl as ls, FreeTextDraft as lt, WireAnnotationPatch as m, invalidatesWeakIndexRefs as ma, collab as mc, FormDataFormat as mi, CalloutLine as ml, SquigglyDraftSchema as mn, BinaryMetadata as mo, SearchQueryIssue as mr, PageRaster as ms, InkAnnotationDTO as mt, AnnotationListSnapshotAllPages as n, encodeFieldRefKey as na, NamedPageTarget as nc, FormWidgetLinkResult as ni, InkIntent as nl, CircleAnnotationDTO as nn, GeometryStyleFields as no, PageMoveCache as nr, AnnotationAppearancesResult as ns, CaretAnnotationDTO as nt, AnnotationDraft as o, AnnotationUpdateResult as oa, OpenInputBytes as oc, FormEffectsResult as oi, PdfRectDifferences as ol, ShapePatchFields as on, AttachmentFileInfo as oo, canonicalSearchQuery as or, knownWeakAnnotationState as os, FreeTextPatchSchema as ot, WireAnnotationDraft as p, changesAnnotationList as pa, caps as pc, FormSubmissionRequestSchema as pi, TextAlignment as pl, SquigglyDTOSchema as pn, normalizeAnnotationPatch as po, SEARCH_REGEX_MAX_LENGTH as pr, PageNetworkRenderFormat as ps, InkPatch as pt, TextPatchSchema as q, FileAttachmentWireDraft as qa, revisionTokensEqual as qc, RadioFieldDTO as qi, AnnotationFlattenResult as qn, AnnotationAppearanceImage as qo, textGlyphQuad as qr, pdfRectHeight as qs, SquareDraftSchema as qt, ANNOTATION_KINDS as r, AnnotationCreateResult as ra, MetadataPatch as rc, FormEffect as ri, LineEnding as rl, CircleDraft as rn, GeometryStylePatchFields as ro, PageMoveResult as rr, PageState as rs, CaretDraft as rt, AnnotationDraftSchema as s, AppearanceAction as sa, OpenInputLayerBytes as sc, FormFieldDisplay as si, Point as sl, StrikeoutDTOSchema as sn, AttachmentFileSource as so, searchContentEpoch as sr, PageImageBlobSource as ss, FreeTextPatch as st, AnnotationListPageSnapshot as t, decodeFieldRefKey as ta, NamedPageEntry as tc, FormSetValueResult as ti, FreeTextIntent as tl, CirclePatch as tn, GeometryStyleDraftFields as to, PageRemoveNameInput as tr, AnnotationAppearancesQuery as ts, CaretPatch as tt, AnnotationPatchSchema as u, appearanceImpactOf as ua, OpenInputToken as uc, FormSubmissionReceipt as ui, Size as ul, StrikeoutPatch as un, NormalizedDraft as uo, SEARCH_SNIPPET_CONTEXT as ur, PageImageOptions as us, InkDTOSchema as ut, UnsupportedPatch as v, CacheDelta as va, checkAnyCapability as vc, FormFieldPatch as vi, PdfPoint as vl, SquigglyDraft as vn, BinarySource as vo, matchRegex as vr, PageRenderOptions as vs, LinkPatchSchema as vt, WidgetPatch as w, LayerScopePlane as wa, filterMatches as wc, FormFieldDraft as wi, DocumentActionsSnapshot as wl, UnderlineDraft as wn, AnnotationSubtype as wo, wordBefore as wr, PageGeometryRun as ws, LinkDraft as wt, RedactPatch as x, PdfLinkTargetWritable as xa, checkSetGroup as xc, TextFieldPatch as xi, PdfRotation as xl, UnderlinePatchSchema as xn, WireResourceMap as xo, foldOptionsFor as xr, PageRenderViewport as xs, PdfDestinationSchema as xt, UnsupportedDraft as y, MutationMeta as ya, checkCapability as yc, ListBoxFieldPatch as yi, PdfQuad as yl, UnderlineDTOSchema as yn, ResourceRef as yo, validateSearchQuery as yr, PageRenderQuery as ys, PdfLinkTargetSchema as yt, StampWirePatch as z, DraftOfKind as za, ParsedCollab as zc, FormFieldBase as zi, isValidPageObjectNumber as zl, PageInsertResult as zn, serializeError as zo, PdfTextSegment as zr, sliceTextByChars as zs, PolygonPatchSchema as zt };
|
|
5887
|
-
//# sourceMappingURL=AnnotationListSnapshot-
|
|
6870
|
+
export { CaretDraftSchema as $, semanticEqual as $a, NamedPageEntry as $c, FormFieldDisplay as $i, CachePins as $l, PageNameResult as $n, normalizeAnnotationPatch as $o, FormImportResult as $r, AnnotationAppearanceManifestEntry as $s, CircleDraftSchema as $t, PdfRect as $u, FileAttachmentWireDraftSchema as A, ComboBoxFieldDTO as Aa, PageTextSnapshot as Ac, refsOf as Ai, FieldLockSpec as Al, HighlightDraft as An, normalizeAttachmentFileSource as Ao, toOriginalRange as Ar, RichTextDirection as As, LineDraft as At, BlendMode as Au, StampAnnotationDTO as B, SignatureFieldDTO as Ba, normalizePdfRect as Bc, ObjectReferrer as Bi, SignaturePrepareInput as Bl, PageDeleteResult as Bn, FilledStylePatchFields as Bo, TextLayoutFrame as Br, richTextPlainText as Bs, PolygonPatch as Bt, Point as Bu, RedactDraft as C, FormSnapshot as Ca, PageGeometrySnapshot as Cc, evaluateStep as Ci, BaseVersionInfo as Cl, UnderlineAnnotationDTO as Cn, AnnotationKindModule as Co, wordAt as Cr, SerializedEngineError as Cs, LinkAnnotationDTO as Ct, AnnotationDraftBase as Cu, FileAttachmentDTOSchema as D, WidgetStyleFields as Da, glyphLooseBounds as Dc, dictEntries as Di, DocumentProtection as Dl, HighlightPatchSchema as Dn, AttachmentCreateResult as Do, SEARCH_FOLD_VERSION as Dr, RichTextAlign as Ds, LinePatchSchema as Dt, AnnotationBorderStyle as Du, WidgetDraft as E, WidgetStyleDraftFields as Ea, UprightGeometryRun as Ec, changedKeys as Ei, DocumentFieldLock as El, HighlightDraftSchema as En, PatchOfKind as Eo, FoldedText as Er, EngineErrorCode as Es, LineDraftSchema as Et, revisionTokensEqual as Eu, StampDTOSchema as F, FormFieldOption as Fa, charMapViolation as Fc, ChangeFinding as Fi, SignatureCompleteInput as Fl, RedactionApplyScope as Fn, ColorStyleDraftFields as Fo, SearchSlice as Fr, RichTextParagraphProps as Fs, PolylineAnnotationDTO as Ft, InkIntent as Fu, TextDTOSchema as G, AnnotationCreateResult as Ga, pdfRectHeight as Gc, RevisionHealth as Gi, SignatureSubFilter as Gl, AnnotationFlattenInput as Gn, AttachmentFileBase as Go, expandTextRangeToWord as Gr, FontSpec as Gs, VertexPatchFields as Gt, StrikeoutIntent as Gu, StampFit as H, ToggleFieldWidget as Ha, pdfQuadCorners as Hc, RestrictionAnchor as Hi, SignatureSeedValue as Hl, PageRotateResult as Hn, GeometryStyleFields as Ho, TextLayoutRun as Hr, FontHandle as Hs, PolygonDraft as Ht, Rotation as Hu, StampWireDraftSchema as I, FormFieldOrigin as Ia, charRangeForTextOffsets as Ic, ObjectChange as Ii, SignatureCompleteResult as Il, RedactionApplyStatus as In, ColorStyleFields as Io, SearchSliceBudget as Ir, RichTextRun as Is, PolylineDraft as It, LineEnding as Iu, TextPatch as J, AnnotationUpdateResult as Ja, pdfRectWidth as Jc, StepVerdict as Ji, MutationMeta as Jl, PageFlattenInput as Jn, EmbeddedFileItem as Jo, textSegmentsForRange as Jr, PdfSaveMode as Js, SquarePatchSchema as Jt, InkList as Ju, TextDraftSchema as K, AnnotationDeleteResult as Ka, pdfRectSize as Kc, RevisionStructure as Ki, SignedDocumentPolicy as Kl, AnnotationFlattenItemResult as Kn, AttachmentFileInfo as Ko, textGlyphAt as Kr, SessionKind as Ks, SquareDTOSchema as Kt, TextAlignment as Ku, StampWirePatchSchema as L, ListBoxFieldDTO as La, sliceTextByChars as Lc, ObjectChangeKind as Li, SignatureCoverage as Ll, PAGE_INSERT_BLANK_MAX_COUNT as Ln, ColorStylePatchFields as Lo, SearchSnippet as Lr, RichTextRunStyle as Ls, PolygonDTOSchema as Lt, LineEndings as Lu, FileAttachmentPatch as M, FormFieldDTO as Ma, CharMapAnchor as Mc, AnalyzeInput as Mi, PdfRevision as Ml, MetadataUpdateResult as Mn, FileAttachmentIcon as Mo, SearchMode as Mr, RichTextDocumentInput as Ms, PolylineDraftSchema as Mt, Color as Mu, FileAttachmentAnnotationDTO as N, FormFieldFamily as Na, boundaryTextOffset as Nc, Assessment as Ni, SignatureAbortResult as Nl, RedactionApplyItemResult as Nn, FileAttachmentWireDraft as No, SearchQuery as Nr, RichTextMargins as Ns, PolylinePatchSchema as Nt, FreeTextFont as Nu, FileAttachmentIconSchema as O, WidgetStylePatchFields as Oa, glyphLooseQuad as Oc, parsePdfValue as Oi, DocumentVersionRef as Ol, HighlightPatch as On, AttachmentDeleteResult as Oo, SearchMatchRange as Or, RichTextBody as Os, LinePatch as Ot, AnnotationFlags as Ou, ResourceRefSchema as P, FormFieldFlags as Pa, charBoundaryAtTextOffset as Pc, ChangeAnalysis as Pi, SignatureAppearanceInput as Pl, RedactionApplyResult as Pn, WireAttachmentFile as Po, SearchRequest as Pr, RichTextParagraph as Ps, PolylinePatch as Pt, FreeTextIntent as Pu, CaretDTOSchema as Q, appearanceImpactOf as Qa, PageRotation as Qc, FormEffectsResult as Qi, knownWeakAnnotationState as Ql, PageFlattenUsage as Qn, normalizeAnnotationDraft as Qo, FormFieldUpdateResult as Qr, AnnotationAppearanceManifest as Qs, CircleDTOSchema as Qt, PdfQuad as Qu, StampPatch as R, PushButtonFieldDTO as Ra, PdfOriginSize as Rc, ObjectChangeType as Ri, SignatureDTO as Rl, PageInsertBlankSpec as Rn, FilledStyleDraftFields as Ro, PageTextLayout as Rr, RichTextScript as Rs, PolygonDraftSchema as Rt, NO_ANNOTATION_FLAGS as Ru, RedactAnnotationDTO as S, FormKind as Sa, PageGeometryRun as Sc, restrictionsFor as Si, filterMatches as Sl, UnderlinePatch as Sn, refKey as So, matchLiteral as Sr, EngineErrorOptions as Ss, LinkPatch as St, PdfBits as Su, WidgetAnnotationDTO as T, WidgetAppearanceSchema as Ta, RotatedGeometryRun as Tc, sameEffectiveValue as Ti, DocMdpPermission as Tl, HighlightDTOSchema as Tn, DraftOfKind as To, FoldOptions as Tr, serializeError as Ts, LineDTOSchema as Tt, RevisionToken as Tu, StampWireDraft as U, UnknownFieldDTO as Ua, pdfQuadFromCorners as Uc, RevisionAnalysis as Ui, SignatureSigner as Ul, PageRotateInput as Un, GeometryStylePatchFields as Uo, buildPageTextLayout as Ur, FontIdentityInfo as Us, VertexAnnotationFields as Ut, Size as Uu, StampDraft as V, TextFieldDTO as Va, pdfQuadBounds as Vc, PdfValue as Vi, SignaturePrepared as Vl, PageDeleteInput as Vn, GeometryStyleDraftFields as Vo, TextLayoutGlyph as Vr, FontEmbeddingPermission as Vs, PolygonAnnotationDTO as Vt, Rect as Vu, NoteIconSchema as W, FormValueEntry as Wa, pdfRectFromOriginSize as Wc, RevisionField as Wi, SignatureSnapshot as Wl, AnnotationAppearanceExportInput as Wn, AttachmentContent as Wo, expandTextRangeToLine as Wr, FontKey as Ws, VertexDraftFields as Wt, StandardFont as Wu, NoteIcon as X, AppearanceImpact as Xa, PageBoxes as Xc, FormEffectResult as Xi, UNKNOWN_WEAK_ANNOTATION_STATE as Xl, PageFlattenResult as Xn, NormalizedDraft as Xo, FormFieldCreateResult as Xr, AnnotationAppearanceImageOptions as Xs, SquareAnnotationDTO as Xt, LinePoints as Xu, TextAnnotationDTO as Y, AppearanceAction as Ya, PageListSnapshot as Yc, FormEffect as Yi, PageState as Yl, PageFlattenItemResult as Yn, EmbeddedFileRef as Yo, FormDataExport as Yr, AnnotationAppearanceImage as Ys, SquarePatch as Yt, InkStroke as Yu, TextDraft as Z, AppearanceOutcome as Za, PageLayout as Zc, FormEffectStatus as Zi, WeakAnnotationState as Zl, PageFlattenStatus as Zn, NormalizedPatch as Zo, FormFieldDeleteResult as Zr, AnnotationAppearanceImagesResult as Zs, SquareDraft as Zt, PdfPoint as Zu, UnsupportedPatchSchema as _, FormFieldOptionInput as _a, PageRenderQuery as _c, PageObjectNumber as _d, DEFAULT_EDGE_RESOLVER_BUDGET as _i, checkCapability as _l, SquigglyAnnotationDTO as _n, isStateAnnotation as _o, SearchRegexValidation as _r, AnnotationIdentityQuality as _s, LinkDraftSchema as _t, ParsedCapability as _u, AnnotationDTOSchema as a, FormSubmissionRequestSchema as aa, PageImageBlobSource as ac, PdfActionNode as ad, fieldLockFor as ai, OpenInputLayerBytes as al, ShapeDraftFields as an, RefetchReason as ao, PageMoveInput as ar, ResourceRef as as, FreeTextDraftSchema as at, MissingIdentity as au, UnsupportedAnnotationDTO as b, TextFieldDraft as ba, createPageImageHandle as bc, DocumentMetadataTrapped as bd, ResolvedUsage as bi, expandRawScope as bl, UnderlineDraftSchema as bn, buildThreads as bo, validateSearchRegex as br, encodeStableIdKey as bs, PdfLinkTargetWritableSchema as bt, ParsedVirtual as bu, AnnotationKind as c, CheckboxFieldPatch as ca, PageImageOptions as cc, PdfActionType as cd, lockCovers as ci, OpenInputToken as cl, StrikeoutDraftSchema as cn, DocumentManifest as co, searchRectsForRange as cr, resolveBinarySource as cs, FreeTextAnnotationDTO as ct, validateScopeArray as cu, AnnotationSubtypeOfKind as d, ListBoxFieldPatch as da, PageNetworkRenderFormat as dc, PdfFieldActions as dd, protectedCapabilities as di, caps as dl, StrikeoutAnnotationDTO as dn, LayerScopes as do, buildSnippet as dr, PDF_CODE_TO_SUBTYPE as ds, InkDraftSchema as dt, AnnotationActor as du, FormSubmissionEntry as ea, AnnotationAppearanceMode as ec, PdfRotation as ed, FormRepairResult as ei, NamedPageTarget as el, CirclePatchSchema as en, AnnotationMutationKind as eo, PageNameInput as er, BinaryMetadata as es, CaretPatchSchema as et, FormFieldRef as eu, KIND_BY_SUBTYPE as f, RadioFieldPatch as fa, PageRaster as fc, PdfPageActions as fd, assessmentOf as fi, collab as fl, StrikeoutDraft as fn, BuildCommentThreadsOptions as fo, matchPageText as fr, PDF_SUBTYPE_TO_CODE as fs, InkPatchSchema as ft, CollabAction as fu, UnsupportedDraftSchema as g, FormFieldDraft as ga, PageRenderOptions as gc, PdfDestination as gd, worstVerdict as gi, checkAnyCapability as gl, SquigglyPatch as gn, buildCommentThreads as go, SearchRegexIssue as gr, AnnotationBase as gs, LinkDTOSchema as gt, IdentityClaims as gu, UnsupportedDTOSchema as h, ComboBoxFieldDraft as ha, PageRenderFormat as hc, decodeSubmitFormFlags as hd, primaryFinding as hi, CollabTarget as hl, SquigglyPatchSchema as hn, ReviewStatus as ho, SearchQueryValidation as hr, AnnotationPatchBase as hs, InkDraft as ht, DocCapability as hu, AnnotationDTO as i, FormSubmissionRequest as ia, AnnotationAppearancesResult as ic, NamedJavaScriptAction as id, deriveProtection as ii, OpenInputBytes as il, ShapeAnnotationFields as in, AnnotationListMutationMeta as io, PageStructureCache as ir, BinarySource as is, FreeTextDTOSchema as it, InvalidScope as iu, WireAttachmentFileSchema as j, FormFieldBase as ja, CharBoundaryBias as jc, stableStringify as ji, ModificationLevel as jl, MetadataCache as jn, FileAttachmentDraft as jo, SearchMatch as jr, RichTextDocument as js, PolylineDTOSchema as jt, CaretIntent as ju, FileAttachmentPatchSchema as k, CheckboxFieldDTO as ka, isRotatedGeometryRun as kc, pdfValueEquals as ki, FieldLockAction as kl, HighlightAnnotationDTO as kn, AttachmentsCache as ko, foldText as kr, RichTextDecoration as ks, LineAnnotationDTO as kt, AnnotationReplyType as ku, AnnotationPatch as l, ComboBoxFieldPatch as la, PageImageResult as lc, PdfActionWarning as ld, lockNameCovers as li, OpenOptions as ll, StrikeoutPatchSchema as ln, ManifestPage as lo, searchSegmentsForRange as lr, ANNOTATION_SUBTYPES as ls, FreeTextDraft as lt, PDF_BITS as lu, WireAnnotationPatch as m, CheckboxFieldDraft as ma, PageRenderEncodedFormat as mc, SubmitFormPayload as md, conclude as mi, pdfPermissions as ml, SquigglyDraftSchema as mn, CommentThreadReview as mo, SearchQueryIssue as mr, subtypeFromCode as ms, InkAnnotationDTO as mt, CollabFilter as mu, AnnotationListSnapshotAllPages as n, FormSubmissionReceipt as na, AnnotationAppearanceRenderOptions as nc, ActionReadBudget as nd, FormWidgetLinkResult as ni, OpenInput as nl, CircleAnnotationDTO as nn, invalidatesWeakIndexRefs as no, PageMoveCache as nr, sniffBinaryMetadata as ns, CaretAnnotationDTO as nt, decodeFieldRefKey as nu, AnnotationDraft as o, FormDataFormat as oa, PageImageHandle as oc, PdfActionTargetRef as od, levelAllows as oi, OpenInputLayerSource as ol, ShapePatchFields as on, PdfLinkTarget as oo, canonicalSearchQuery as or, WireResource as os, FreeTextPatchSchema as ot, PermissionDenied as ou, WireAnnotationDraft as p, TextFieldPatch as pa, PageRenderBackground as pc, SubmitFormFlags as pd, combine as pi, materializePdfPermissions as pl, SquigglyDTOSchema as pn, CommentThread as po, SEARCH_REGEX_MAX_LENGTH as pr, PdfAnnotationSubtypeCode as ps, InkPatch as pt, CollabEntity as pu, TextPatchSchema as q, AnnotationMoveResult as qa, pdfRectToOriginSize as qc, StepInput as qi, CacheDelta as ql, AnnotationFlattenResult as qn, AttachmentFileSource as qo, textGlyphQuad as qr, DEFAULT_PDF_SAVE_MODE as qs, SquareDraftSchema as qt, CalloutLine as qu, ANNOTATION_KINDS as r, FormSubmissionReceiptSchema as ra, AnnotationAppearancesQuery as rc, DocumentActionsSnapshot as rd, SIGNATURE_POLICY_VERSION as ri, OpenInputById as rl, CircleDraft as rn, shiftsExistingAnnotationIndices as ro, PageMoveResult as rr, BinaryPayload as rs, CaretDraft as rt, encodeFieldRefKey as ru, AnnotationDraftSchema as s, FormFieldValue as sa, PageImageObjectUrl as sc, PdfActionTree as sd, levelFromPermission as si, OpenInputShare as sl, StrikeoutDTOSchema as sn, PdfLinkTargetWritable as so, searchContentEpoch as sr, WireResourceMap as ss, FreeTextPatch as st, parseScope as su, AnnotationListPageSnapshot as t, FormSubmissionEntrySchema as ta, AnnotationAppearanceRaster as tc, PdfSize as td, FormSetValueResult as ti, MetadataPatch as tl, CirclePatch as tn, changesAnnotationList as to, PageRemoveNameInput as tr, BinaryMimeType as ts, CaretPatch as tt, FormWidgetRef as tu, AnnotationPatchSchema as u, FormFieldPatch as ua, PageImageSource as uc, PdfAnnotationActions as ud, minLevel as ui, TokenSource as ul, StrikeoutPatch as un, LayerScopePlane as uo, SEARCH_SNIPPET_CONTEXT as ur, AnnotationSubtype as us, InkDTOSchema as ut, decodePdfBits as uu, UnsupportedPatch as v, ListBoxFieldDraft as va, PageRenderTarget as vc, isValidPageObjectNumber as vd, EdgeResolver as vi, checkCollab as vl, SquigglyDraft as vn, AnnotationRelationKind as vo, matchRegex as vr, AnnotationStableId as vs, LinkPatchSchema as vt, ParsedCollab as vu, WidgetPatch as w, WidgetAppearance as wa, RotatedGeometryGlyph as wc, restrictionsOf as wi, DigestAlgorithm as wl, UnderlineDraft as wn, DTOOfKind as wo, wordBefore as wr, deserializeError as ws, LinkDraft as wt, AnnotationRef as wu, RedactPatch as x, WidgetPlacement as xa, PageGeometryGlyph as xc, USAGE_INCOMPLETE as xi, expandedCapabilities as xl, UnderlinePatchSchema as xn, classifyRelation as xo, foldOptionsFor as xr, EngineError as xs, PdfDestinationSchema as xt, ParsedWildcard as xu, UnsupportedDraft as y, RadioFieldDraft as ya, PageRenderViewport as yc, DocumentMetadata as yd, EdgeResolverBudget as yi, checkSetGroup as yl, UnderlineDTOSchema as yn, AnnotationThread as yo, validateSearchQuery as yr, decodeStableIdKey as ys, PdfLinkTargetSchema as yt, ParsedScope as yu, StampWirePatch as z, RadioFieldDTO as za, PdfQuadCorners as zc, ObjectReadStatus as zi, SignatureKind as zl, PageInsertResult as zn, FilledStyleFields as zo, PdfTextSegment as zr, richTextParagraphsFromPlainText as zs, PolygonPatchSchema as zt, PdfRectDifferences as zu };
|
|
6871
|
+
//# sourceMappingURL=AnnotationListSnapshot-D3mFut1e.d.ts.map
|