@embedpdf/plugin-form 3.0.0-next.14 → 3.0.0-next.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/contract/host.cjs +29 -2
- package/dist/contract/host.cjs.map +1 -0
- package/dist/contract/host.d.cts +3 -2
- package/dist/contract/host.d.ts +3 -2
- package/dist/contract/host.js +14 -2
- package/dist/contract/host.js.map +1 -0
- package/dist/contract-BwcgtCOD.d.ts +566 -0
- package/dist/contract-CU0jrI_D.cjs +56 -0
- package/dist/contract-CU0jrI_D.cjs.map +1 -0
- package/dist/contract-D-yQxw3H.d.cts +566 -0
- package/dist/contract-DcncvPcF.js +45 -0
- package/dist/contract-DcncvPcF.js.map +1 -0
- package/dist/contract.cjs +17 -6
- package/dist/contract.d.cts +2 -8
- package/dist/contract.d.ts +2 -8
- package/dist/contract.js +2 -7
- package/dist/controller-CS6tV2m1.cjs +514 -0
- package/dist/controller-CS6tV2m1.cjs.map +1 -0
- package/dist/controller-Sr5M_8G8.js +497 -0
- package/dist/controller-Sr5M_8G8.js.map +1 -0
- package/dist/host-contract-1epLfK1S.d.cts +87 -0
- package/dist/host-contract-BRYUbpT_.d.ts +87 -0
- package/dist/index.cjs +2917 -1205
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +46 -17
- package/dist/index.d.ts +46 -17
- package/dist/index.js +2896 -1206
- package/dist/index.js.map +1 -1
- package/dist/scripting.cjs +3 -484
- package/dist/scripting.d.cts +58 -22
- package/dist/scripting.d.ts +58 -22
- package/dist/scripting.js +1 -482
- package/package.json +15 -14
- package/dist/contract.cjs.map +0 -1
- package/dist/contract.js.map +0 -1
- package/dist/internal.cjs +0 -4
- package/dist/internal.d.cts +0 -3
- package/dist/internal.d.ts +0 -3
- package/dist/internal.js +0 -3
- package/dist/scripting.cjs.map +0 -1
- package/dist/scripting.js.map +0 -1
- package/dist/types-Bpc32Qmx.d.cts +0 -309
- package/dist/types-C1uIIYfn.cjs +0 -16
- package/dist/types-C1uIIYfn.cjs.map +0 -1
- package/dist/types-DRirhZKr.d.ts +0 -309
- package/dist/types-DkQmmcTG.js +0 -12
- package/dist/types-DkQmmcTG.js.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,24 +1,53 @@
|
|
|
1
|
-
import { _ as
|
|
2
|
-
import {
|
|
1
|
+
import { A as FormRepairResult, B as FormValidationRejectedEvent, C as FormImportDrop, D as FormKind, E as FormImportResult, F as FormSettings, G as WidgetAnnotation, H as FormWidgetAddResult, I as FormSnapshot, J as FormWidgetItem, K as toFieldRef, L as FormTransfer, M as FormResyncedEvent, N as FormSetValueResult, O as FormPlainValue, P as FormSetValueStatus, Q as WidgetHit, R as FormUiEffect, S as FormFilter, T as FormImportOptions, U as WidgetActivationResult, V as FormValueChangedEvent, W as WidgetAddress, X as FormWidgetLook, Y as Box, _ as FormFieldResult, a as FormCommitResult, b as FormFieldUpdatedEvent, c as FormExportSelection, d as FormFieldDeletedEvent, f as FormFieldDraft, g as FormFieldRef, h as FormFieldPatch, i as FormCapability, j as FormResetResult, k as FormRepairOptions, l as FormFieldCreatedEvent, m as FormFieldFlagSetting, n as FillableFields, o as FormCommitStatus, p as FormFieldFamily, q as FormToken, r as FormBundle, s as FormConfig, t as FORM_DEFAULTS, u as FormFieldDTO, v as FormFieldSetting, w as FormImportDropReason, x as FormFieldValue, y as FormFieldSettings, z as FormValidation } from "./contract-D-yQxw3H.cjs";
|
|
2
|
+
import { t as FormHostCapability } from "./host-contract-1epLfK1S.cjs";
|
|
3
3
|
import { FormScriptingController, createFormScriptingController } from "./scripting.cjs";
|
|
4
|
-
import {
|
|
4
|
+
import { FormFieldDTO as FormFieldDTO$1, FormFieldFamily as FormFieldFamily$1, WidgetAppearance } from "@embedpdf/engine-core/runtime";
|
|
5
|
+
import { ClickCreate } from "@embedpdf/plugin-annotation/contract";
|
|
5
6
|
//#region src/form.plugin.d.ts
|
|
6
7
|
/**
|
|
7
|
-
* The form plugin: the
|
|
8
|
-
* interaction hub.
|
|
9
|
-
* geometry is read from the engine's widget
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* widgets
|
|
8
|
+
* The form plugin: the field plane. Document-scoped; requires the
|
|
9
|
+
* interaction hub. Filling works without the annotation plugin, because
|
|
10
|
+
* widget geometry is read from the engine's widget records. The active tool
|
|
11
|
+
* is the mode switch: while it carries 'form-fill' (the built-in pointer and
|
|
12
|
+
* pan tools do, so filling is the resting state), the form layer draws and
|
|
13
|
+
* fills every widget. Design mode is the 'form-edit' and palette tools: with
|
|
14
|
+
* the annotation plugin present, the form lends it the widgets, which its
|
|
15
|
+
* tools then select, move, restyle and delete. The render plugin draws the
|
|
16
|
+
* widgets' pictures in both modes. `config` is the settings the app
|
|
17
|
+
* registers, over {@link FORM_DEFAULTS}.
|
|
16
18
|
*/
|
|
17
|
-
declare const formPlugin: (
|
|
19
|
+
declare const formPlugin: (config?: FormConfig) => import("@embedpdf/core").PluginDef<Readonly<Record<string, never>>, FormHostCapability, FormSettings>;
|
|
18
20
|
//#endregion
|
|
19
|
-
//#region src/
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
//#region src/state.d.ts
|
|
22
|
+
declare const formState: import("@embedpdf/core").StateDeclaration<FormCapability, {
|
|
23
|
+
fields: readonly FormFieldDTO$1[];
|
|
24
|
+
status: import("@embedpdf/core").ResourceStatus;
|
|
25
|
+
formKind: import("@embedpdf/engine-core/runtime").FormKind;
|
|
26
|
+
selectedField: FormFieldDTO$1 | null;
|
|
27
|
+
}>;
|
|
22
28
|
//#endregion
|
|
23
|
-
|
|
29
|
+
//#region src/tools/definitions.d.ts
|
|
30
|
+
/** The families the palette places. */
|
|
31
|
+
type AuthorableFormFamily = Exclude<FormFieldFamily$1, 'unknown'>;
|
|
32
|
+
interface FormToolDef {
|
|
33
|
+
id: string;
|
|
34
|
+
/** The field family the tool places (the form plane's vocabulary). */
|
|
35
|
+
family: AuthorableFormFamily;
|
|
36
|
+
/** The client kind the annotation registry routes on (props panel).
|
|
37
|
+
* Not a PDF subtype — every widget is PDF `widget`; this is the view. */
|
|
38
|
+
visualKind: 'widget-text' | 'widget-choice' | 'widget-button' | 'widget-toggle' | 'widget-radio' | 'widget-box';
|
|
39
|
+
/** What a bare click places (box policies only — fields are boxes). */
|
|
40
|
+
clickCreate: Extract<ClickCreate, {
|
|
41
|
+
width: number;
|
|
42
|
+
}>;
|
|
43
|
+
/** Seed drawing defaults, the widget's appearance fields: a placed field is
|
|
44
|
+
* visible (white box, gray border) and restylable per tool through the
|
|
45
|
+
* shared style panel. */
|
|
46
|
+
defaults: WidgetAppearance;
|
|
47
|
+
cursor: string;
|
|
48
|
+
}
|
|
49
|
+
declare const FORM_TOOLS: readonly FormToolDef[];
|
|
50
|
+
declare const FORM_TOOL_BY_ID: ReadonlyMap<string, FormToolDef>;
|
|
51
|
+
//#endregion
|
|
52
|
+
export { type AuthorableFormFamily, type Box, FORM_DEFAULTS, FORM_TOOLS, FORM_TOOL_BY_ID, FillableFields, type FormBundle, FormCapability, FormCommitResult, FormCommitStatus, FormConfig, FormExportSelection, FormFieldCreatedEvent, type FormFieldDTO, FormFieldDeletedEvent, type FormFieldDraft, type FormFieldFamily, FormFieldFlagSetting, type FormFieldPatch, type FormFieldRef, FormFieldResult, FormFieldSetting, FormFieldSettings, FormFieldUpdatedEvent, type FormFieldValue, FormFilter, type FormImportDrop, type FormImportDropReason, type FormImportOptions, FormImportResult, type FormKind, FormPlainValue, type FormRepairOptions, type FormRepairResult, FormResetResult, FormResyncedEvent, FormScriptingController, FormSetValueResult, FormSetValueStatus, FormSettings, type FormSnapshot, FormToken, type FormToolDef, FormTransfer, FormUiEffect, FormValidation, FormValidationRejectedEvent, FormValueChangedEvent, FormWidgetAddResult, type FormWidgetItem, type FormWidgetLook, WidgetActivationResult, WidgetAddress, type WidgetAnnotation, type WidgetHit, createFormScriptingController, formPlugin, formState, toFieldRef };
|
|
24
53
|
//# sourceMappingURL=index.d.cts.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1,24 +1,53 @@
|
|
|
1
|
-
import { _ as
|
|
2
|
-
import {
|
|
1
|
+
import { A as FormRepairResult, B as FormValidationRejectedEvent, C as FormImportDrop, D as FormKind, E as FormImportResult, F as FormSettings, G as WidgetAnnotation, H as FormWidgetAddResult, I as FormSnapshot, J as FormWidgetItem, K as toFieldRef, L as FormTransfer, M as FormResyncedEvent, N as FormSetValueResult, O as FormPlainValue, P as FormSetValueStatus, Q as WidgetHit, R as FormUiEffect, S as FormFilter, T as FormImportOptions, U as WidgetActivationResult, V as FormValueChangedEvent, W as WidgetAddress, X as FormWidgetLook, Y as Box, _ as FormFieldResult, a as FormCommitResult, b as FormFieldUpdatedEvent, c as FormExportSelection, d as FormFieldDeletedEvent, f as FormFieldDraft, g as FormFieldRef, h as FormFieldPatch, i as FormCapability, j as FormResetResult, k as FormRepairOptions, l as FormFieldCreatedEvent, m as FormFieldFlagSetting, n as FillableFields, o as FormCommitStatus, p as FormFieldFamily, q as FormToken, r as FormBundle, s as FormConfig, t as FORM_DEFAULTS, u as FormFieldDTO, v as FormFieldSetting, w as FormImportDropReason, x as FormFieldValue, y as FormFieldSettings, z as FormValidation } from "./contract-BwcgtCOD.js";
|
|
2
|
+
import { t as FormHostCapability } from "./host-contract-BRYUbpT_.js";
|
|
3
3
|
import { FormScriptingController, createFormScriptingController } from "./scripting.js";
|
|
4
|
-
import {
|
|
4
|
+
import { ClickCreate } from "@embedpdf/plugin-annotation/contract";
|
|
5
|
+
import { FormFieldDTO as FormFieldDTO$1, FormFieldFamily as FormFieldFamily$1, WidgetAppearance } from "@embedpdf/engine-core/runtime";
|
|
5
6
|
//#region src/form.plugin.d.ts
|
|
6
7
|
/**
|
|
7
|
-
* The form plugin: the
|
|
8
|
-
* interaction hub.
|
|
9
|
-
* geometry is read from the engine's widget
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* widgets
|
|
8
|
+
* The form plugin: the field plane. Document-scoped; requires the
|
|
9
|
+
* interaction hub. Filling works without the annotation plugin, because
|
|
10
|
+
* widget geometry is read from the engine's widget records. The active tool
|
|
11
|
+
* is the mode switch: while it carries 'form-fill' (the built-in pointer and
|
|
12
|
+
* pan tools do, so filling is the resting state), the form layer draws and
|
|
13
|
+
* fills every widget. Design mode is the 'form-edit' and palette tools: with
|
|
14
|
+
* the annotation plugin present, the form lends it the widgets, which its
|
|
15
|
+
* tools then select, move, restyle and delete. The render plugin draws the
|
|
16
|
+
* widgets' pictures in both modes. `config` is the settings the app
|
|
17
|
+
* registers, over {@link FORM_DEFAULTS}.
|
|
16
18
|
*/
|
|
17
|
-
declare const formPlugin: (
|
|
19
|
+
declare const formPlugin: (config?: FormConfig) => import("@embedpdf/core").PluginDef<Readonly<Record<string, never>>, FormHostCapability, FormSettings>;
|
|
18
20
|
//#endregion
|
|
19
|
-
//#region src/
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
//#region src/state.d.ts
|
|
22
|
+
declare const formState: import("@embedpdf/core").StateDeclaration<FormCapability, {
|
|
23
|
+
fields: readonly FormFieldDTO$1[];
|
|
24
|
+
status: import("@embedpdf/core").ResourceStatus;
|
|
25
|
+
formKind: import("@embedpdf/engine-core/runtime").FormKind;
|
|
26
|
+
selectedField: FormFieldDTO$1 | null;
|
|
27
|
+
}>;
|
|
22
28
|
//#endregion
|
|
23
|
-
|
|
29
|
+
//#region src/tools/definitions.d.ts
|
|
30
|
+
/** The families the palette places. */
|
|
31
|
+
type AuthorableFormFamily = Exclude<FormFieldFamily$1, 'unknown'>;
|
|
32
|
+
interface FormToolDef {
|
|
33
|
+
id: string;
|
|
34
|
+
/** The field family the tool places (the form plane's vocabulary). */
|
|
35
|
+
family: AuthorableFormFamily;
|
|
36
|
+
/** The client kind the annotation registry routes on (props panel).
|
|
37
|
+
* Not a PDF subtype — every widget is PDF `widget`; this is the view. */
|
|
38
|
+
visualKind: 'widget-text' | 'widget-choice' | 'widget-button' | 'widget-toggle' | 'widget-radio' | 'widget-box';
|
|
39
|
+
/** What a bare click places (box policies only — fields are boxes). */
|
|
40
|
+
clickCreate: Extract<ClickCreate, {
|
|
41
|
+
width: number;
|
|
42
|
+
}>;
|
|
43
|
+
/** Seed drawing defaults, the widget's appearance fields: a placed field is
|
|
44
|
+
* visible (white box, gray border) and restylable per tool through the
|
|
45
|
+
* shared style panel. */
|
|
46
|
+
defaults: WidgetAppearance;
|
|
47
|
+
cursor: string;
|
|
48
|
+
}
|
|
49
|
+
declare const FORM_TOOLS: readonly FormToolDef[];
|
|
50
|
+
declare const FORM_TOOL_BY_ID: ReadonlyMap<string, FormToolDef>;
|
|
51
|
+
//#endregion
|
|
52
|
+
export { type AuthorableFormFamily, type Box, FORM_DEFAULTS, FORM_TOOLS, FORM_TOOL_BY_ID, FillableFields, type FormBundle, FormCapability, FormCommitResult, FormCommitStatus, FormConfig, FormExportSelection, FormFieldCreatedEvent, type FormFieldDTO, FormFieldDeletedEvent, type FormFieldDraft, type FormFieldFamily, FormFieldFlagSetting, type FormFieldPatch, type FormFieldRef, FormFieldResult, FormFieldSetting, FormFieldSettings, FormFieldUpdatedEvent, type FormFieldValue, FormFilter, type FormImportDrop, type FormImportDropReason, type FormImportOptions, FormImportResult, type FormKind, FormPlainValue, type FormRepairOptions, type FormRepairResult, FormResetResult, FormResyncedEvent, FormScriptingController, FormSetValueResult, FormSetValueStatus, FormSettings, type FormSnapshot, FormToken, type FormToolDef, FormTransfer, FormUiEffect, FormValidation, FormValidationRejectedEvent, FormValueChangedEvent, FormWidgetAddResult, type FormWidgetItem, type FormWidgetLook, WidgetActivationResult, WidgetAddress, type WidgetAnnotation, type WidgetHit, createFormScriptingController, formPlugin, formState, toFieldRef };
|
|
24
53
|
//# sourceMappingURL=index.d.ts.map
|