@gct-paas/word 1.0.2 → 1.0.3-beta.1
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/README.md +27 -13
- package/dist/browser.js +1 -1
- package/dist/chunks/{ModelEditor-CXoezurC.js → ModelEditor-DqavEAJg.js} +113 -4
- package/dist/chunks/ModelEditor-DqavEAJg.js.map +1 -0
- package/dist/chunks/NodeFactory-DzFnWaWf.js +500 -0
- package/dist/chunks/NodeFactory-DzFnWaWf.js.map +1 -0
- package/dist/chunks/QuickFillPanel-BNZwXlnL.js +336 -0
- package/dist/chunks/QuickFillPanel-BNZwXlnL.js.map +1 -0
- package/dist/chunks/{browser-DY0wE3Uz.js → browser-DkEIriBA.js} +1462 -772
- package/dist/chunks/browser-DkEIriBA.js.map +1 -0
- package/dist/chunks/legacy-template-converter-DFsd-elN.js +125 -0
- package/dist/chunks/legacy-template-converter-DFsd-elN.js.map +1 -0
- package/dist/chunks/migrate-YJTylIpz.js +5193 -0
- package/dist/chunks/migrate-YJTylIpz.js.map +1 -0
- package/dist/chunks/{sdk-Dz96Ca_-.js → sdk-D9n5KeaD.js} +1284 -660
- package/dist/chunks/sdk-D9n5KeaD.js.map +1 -0
- package/dist/chunks/src-BFXPGLus.js +3338 -0
- package/dist/chunks/src-BFXPGLus.js.map +1 -0
- package/dist/chunks/{table-borders-Dwuj7lFp.js → table-borders-B9bZMj5o.js} +2 -2
- package/dist/chunks/{table-borders-Dwuj7lFp.js.map → table-borders-B9bZMj5o.js.map} +1 -1
- package/dist/chunks/templates-Djcl21k4.js.map +1 -1
- package/dist/chunks/{types-Bq4hbWKT.js → types-CzOaf1gP.js} +90 -56
- package/dist/chunks/types-CzOaf1gP.js.map +1 -0
- package/dist/chunks/{NodeFactory-D9gVGSok.js → validation-DkCy8wHI.js} +10 -495
- package/dist/chunks/validation-DkCy8wHI.js.map +1 -0
- package/dist/docx.js +3 -2
- package/dist/docx.js.map +1 -1
- package/dist/index.js +6 -5
- package/dist/legacy.js +1 -0
- package/dist/platform.js +2 -2
- package/dist/style.css +1066 -679
- package/dist/types/adapters/browser/canvas/CanvasPages.d.ts +1 -1
- package/dist/types/adapters/browser/canvas/paint-context.d.ts +4 -0
- package/dist/types/adapters/browser/canvas/paint-signature.d.ts +4 -0
- package/dist/types/adapters/browser/index.d.ts +1 -0
- package/dist/types/adapters/browser/input/CanvasFieldBrackets.d.ts +10 -0
- package/dist/types/adapters/browser/input/CanvasTextInput.d.ts +5 -2
- package/dist/types/adapters/browser/input/ChoiceFieldInput.d.ts +7 -2
- package/dist/types/adapters/browser/input/FieldInputValidation.d.ts +1 -1
- package/dist/types/adapters/browser/input/InlineFieldInput.d.ts +1 -1
- package/dist/types/adapters/browser/input/SignatureFieldInput.d.ts +10 -1
- package/dist/types/adapters/browser/input/business/FieldPopover.d.ts +6 -0
- package/dist/types/adapters/browser/input/business/materials/CanvasMaterialTableActions.d.ts +3 -0
- package/dist/types/adapters/browser/input/business/materials/attach-canvas-materials.d.ts +3 -1
- package/dist/types/adapters/browser/input/business/tables/CanvasBusinessTableActions.d.ts +3 -0
- package/dist/types/adapters/browser/input/business/tables/CanvasBusinessTablePanel.d.ts +4 -0
- package/dist/types/adapters/browser/input/business/tables/CanvasQuickFillDialog.d.ts +9 -8
- package/dist/types/adapters/browser/input/business/tables/attach-canvas-business-table.d.ts +4 -1
- package/dist/types/adapters/browser/input/business/tables/quick-fill-panel.d.ts +22 -0
- package/dist/types/adapters/browser/input/business/tables/table-action-anchors.d.ts +3 -3
- package/dist/types/adapters/browser/input/business/tables/table-action-pages.d.ts +26 -0
- package/dist/types/adapters/browser/input/business/tables/table-actions-renderer.d.ts +4 -0
- package/dist/types/adapters/browser/input/field-panel-geometry.d.ts +12 -0
- package/dist/types/adapters/browser/input/signature-panel.d.ts +6 -0
- package/dist/types/adapters/browser/input/types.d.ts +4 -4
- package/dist/types/adapters/browser/input/validation/CanvasValidationComments.d.ts +19 -0
- package/dist/types/adapters/browser/input/validation/CanvasValidationPanel.d.ts +12 -8
- package/dist/types/adapters/browser/input/validation/validation-issue-key.d.ts +3 -0
- package/dist/types/adapters/browser/input/word-error-text.d.ts +12 -2
- package/dist/types/adapters/document/types.d.ts +2 -1
- package/dist/types/adapters/platform/field-catalog/field-business-rules.d.ts +1 -1
- package/dist/types/adapters/platform/index.d.ts +1 -0
- package/dist/types/adapters/platform/template-reference-migration.d.ts +6 -0
- package/dist/types/adapters/platform/templates.d.ts +13 -1
- package/dist/types/adapters/vue/GctWordPrintRenderer.vue.d.ts +1 -1
- package/dist/types/adapters/vue/GctWordTemplateDesigner.vue.d.ts +3 -0
- package/dist/types/adapters/vue/QuickFillPanel.vue.d.ts +12 -0
- package/dist/types/adapters/vue/SignatureCardReader.vue.d.ts +1 -0
- package/dist/types/adapters/vue/SignatureFieldPanel.vue.d.ts +0 -1
- package/dist/types/adapters/vue/SignatureVisual.vue.d.ts +12 -0
- package/dist/types/adapters/vue/WordFeedback.vue.d.ts +11 -0
- package/dist/types/adapters/vue/WordLayoutNotices.vue.d.ts +8 -0
- package/dist/types/adapters/vue/WordOperationError.vue.d.ts +11 -0
- package/dist/types/adapters/vue/field-properties/dependency-strategies.d.ts +7 -0
- package/dist/types/adapters/vue/index.d.ts +2 -0
- package/dist/types/adapters/vue/layout-notices.d.ts +15 -0
- package/dist/types/adapters/vue/legacy-template-converter.d.ts +14 -0
- package/dist/types/adapters/vue/quick-fill-container.d.ts +2 -0
- package/dist/types/adapters/vue/quick-fill-data.d.ts +8 -0
- package/dist/types/adapters/vue/quick-fill-merge.d.ts +49 -0
- package/dist/types/adapters/vue/quick-fill-panel.d.ts +4 -0
- package/dist/types/adapters/vue/region-properties/WordBusinessRegion.vue.d.ts +3 -0
- package/dist/types/adapters/vue/region-properties/WordDataLockConfig.vue.d.ts +16 -0
- package/dist/types/adapters/vue/useWordWorkspace.d.ts +6 -3
- package/dist/types/adapters/vue/word-feedback.d.ts +21 -0
- package/dist/types/data/DataManager.d.ts +2 -2
- package/dist/types/data/rows/copy-row.d.ts +5 -0
- package/dist/types/data/services/DataDependencies.d.ts +2 -2
- package/dist/types/data/types/manager.d.ts +2 -0
- package/dist/types/data/types/rules.d.ts +8 -1
- package/dist/types/import/legacy/autofill.d.ts +3 -0
- package/dist/types/import/legacy/bindings.d.ts +9 -0
- package/dist/types/import/legacy/boundary.d.ts +10 -0
- package/dist/types/import/legacy/business-fields.d.ts +25 -0
- package/dist/types/import/legacy/context.d.ts +61 -0
- package/dist/types/import/legacy/data-sources.d.ts +29 -0
- package/dist/types/import/legacy/document-rules.d.ts +38 -0
- package/dist/types/import/legacy/document-signature.d.ts +16 -0
- package/dist/types/import/legacy/fields.d.ts +34 -0
- package/dist/types/import/legacy/index.d.ts +3 -0
- package/dist/types/import/legacy/initialization.d.ts +34 -0
- package/dist/types/import/legacy/json-data.d.ts +25 -0
- package/dist/types/import/legacy/materials.d.ts +40 -0
- package/dist/types/import/legacy/media.d.ts +18 -0
- package/dist/types/import/legacy/metadata.d.ts +23 -0
- package/dist/types/import/legacy/migrate.d.ts +9 -0
- package/dist/types/import/legacy/page-widgets.d.ts +30 -0
- package/dist/types/import/legacy/relations.d.ts +25 -0
- package/dist/types/import/legacy/scalar-fields.d.ts +7 -0
- package/dist/types/import/legacy/styles.d.ts +52 -0
- package/dist/types/import/legacy/table-variants.d.ts +18 -0
- package/dist/types/import/legacy/tables.d.ts +27 -0
- package/dist/types/import/legacy/trace-fields.d.ts +21 -0
- package/dist/types/import/legacy/types.d.ts +141 -0
- package/dist/types/import/legacy/widget-presentation.d.ts +10 -0
- package/dist/types/layout/engine/atoms/control-text.d.ts +16 -0
- package/dist/types/layout/engine/atoms/field-control.d.ts +2 -13
- package/dist/types/layout/engine/atoms/fit-atomic.d.ts +1 -1
- package/dist/types/layout/engine/atoms/signatures.d.ts +2 -2
- package/dist/types/layout/engine/blocks/placement-types.d.ts +7 -0
- package/dist/types/layout/engine/pagination/content-flow.d.ts +8 -0
- package/dist/types/layout/engine/tables/place-table-window.d.ts +3 -2
- package/dist/types/layout/engine/tables/row-flow.d.ts +3 -2
- package/dist/types/layout/engine/tables/table-flow.d.ts +3 -1
- package/dist/types/layout/geometry/control-brackets.d.ts +4 -0
- package/dist/types/layout/types/presentation/controls.d.ts +13 -0
- package/dist/types/layout/types/presentation/images.d.ts +8 -0
- package/dist/types/layout/types/presentation/signatures.d.ts +6 -0
- package/dist/types/model/business/business-types.d.ts +9 -1
- package/dist/types/model/business/data-lock-config.d.ts +27 -0
- package/dist/types/runtime/form/business/signatures/NativeSignatures.d.ts +3 -1
- package/dist/types/runtime/form/business/signatures/device-signature-lock.d.ts +2 -0
- package/dist/types/runtime/form/business/tables/row-fields.d.ts +1 -1
- package/dist/types/runtime/form/copy-field-paths.d.ts +3 -0
- package/dist/types/runtime/form/fields/core/declaration-changes.d.ts +2 -2
- package/dist/types/runtime/form/fields/core/rules/CommonFieldRules.d.ts +5 -1
- package/dist/types/runtime/form/validation/NativeFieldValidation.d.ts +16 -2
- package/dist/types/runtime/form/validation/description.d.ts +8 -4
- package/dist/types/runtime/form/validation/targets.d.ts +1 -1
- package/dist/types/runtime/form/validation/types.d.ts +2 -0
- package/dist/types/runtime/interaction/EditorController.d.ts +5 -1
- package/dist/types/runtime/interaction/browse/types.d.ts +1 -1
- package/dist/types/runtime/interaction/design/format/EditorFormat.d.ts +2 -2
- package/dist/types/runtime/interaction/design/format/summary.d.ts +1 -2
- package/dist/types/runtime/interaction/design/format/targets.d.ts +11 -0
- package/dist/types/runtime/interaction/design/format/types.d.ts +3 -3
- package/dist/types/runtime/interaction/design/tables/regions/EditorTableRegions.d.ts +3 -1
- package/dist/types/runtime/interaction/design/tables/regions/definitions.d.ts +7 -0
- package/dist/types/runtime/interaction/field-signature.d.ts +3 -0
- package/dist/types/runtime/interaction/field-text.d.ts +5 -5
- package/dist/types/runtime/interaction/validation/types.d.ts +2 -0
- package/dist/types/runtime/presentation/fields/signatures.d.ts +5 -2
- package/dist/types/shared/platform-gct/form-credentials.d.ts +0 -1
- package/dist/types/shared/platform-gct/templates.d.ts +2 -0
- package/dist/types/shared/signature-graphic.d.ts +27 -0
- package/dist/types/shared/text/shading.d.ts +12 -0
- package/dist/types/shared/text/word-navigation.d.ts +1 -0
- package/dist/types/shared/ui/select/src/select.types.d.ts +2 -0
- package/dist/types/shared/ui/tree-select/src/unified-tree-select.vue.d.ts +1 -1
- package/dist/types/shared/word-shortcuts.d.ts +28 -0
- package/dist/vue.js +2482 -4573
- package/dist/vue.js.map +1 -1
- package/package.json +10 -3
- package/dist/chunks/ModelEditor-CXoezurC.js.map +0 -1
- package/dist/chunks/NodeFactory-D9gVGSok.js.map +0 -1
- package/dist/chunks/browser-DY0wE3Uz.js.map +0 -1
- package/dist/chunks/sdk-Dz96Ca_-.js.map +0 -1
- package/dist/chunks/types-Bq4hbWKT.js.map +0 -1
- package/dist/types/adapters/browser/input/business/tables/fixed-quick-fill-grid.d.ts +0 -19
- package/dist/types/adapters/browser/input/validation/CanvasValidationMarks.d.ts +0 -15
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** @file 嵌套表格窗口借用的块放置能力;递归由调用方组合,窗口不反向装配块放置器。 */
|
|
2
|
+
import type { MeasuredBlock } from './measure-blocks';
|
|
3
|
+
import type { LayoutBlockFragment } from '../../types/fragments';
|
|
4
|
+
import type { FlowBuildContext } from '../context';
|
|
5
|
+
import type { PlacementOccurrence } from '../pagination/placement-occurrence';
|
|
6
|
+
import type { PlacementWindow } from '../pagination/placement-window';
|
|
7
|
+
export type MeasuredBlockPlacer = (blocks: readonly MeasuredBlock[], x: number, y: number, context: FlowBuildContext, occurrence?: PlacementOccurrence, window?: PlacementWindow) => LayoutBlockFragment[];
|
|
@@ -89,4 +89,12 @@ export interface ContentFlowSlice {
|
|
|
89
89
|
export declare function previewContentFlow(cursor: ContentFlowCursor, capacity: number, forceFirst?: boolean, frameHeight?: number): ContentFlowSlice;
|
|
90
90
|
/** 将同段连续视觉行或同控件内部行聚合为少量最终块,不按字符创建结果。 */
|
|
91
91
|
export declare function placeContentFlow(slice: ContentFlowSlice, x: number, y: number, pageId: string, context: FlowBuildContext): LayoutBlockFragment[];
|
|
92
|
+
/** 表格借用内容流操作,递归创建由本组合层提供,行流不反向导入实现。 */
|
|
93
|
+
export interface ContentFlowOperations {
|
|
94
|
+
create(source: MeasuredTableCell, context: FlowBuildContext): ContentFlowCursor;
|
|
95
|
+
readonly preview: typeof previewContentFlow;
|
|
96
|
+
readonly place: typeof placeContentFlow;
|
|
97
|
+
}
|
|
98
|
+
/** 仅包含无状态函数,游标、候选和上下文仍由本轮分页拥有。 */
|
|
99
|
+
export declare const contentFlowOperations: ContentFlowOperations;
|
|
92
100
|
export {};
|
|
@@ -3,6 +3,7 @@ import { type PlacementWindow } from '../pagination/placement-window';
|
|
|
3
3
|
import type { MeasuredTable, MeasuredTableCell } from './table-types';
|
|
4
4
|
import type { LayoutBlockFragment, LayoutTableFragment } from '../../types/fragments';
|
|
5
5
|
import type { LayoutRect } from '../../types/geometry';
|
|
6
|
+
import type { MeasuredBlockPlacer } from '../blocks/placement-types';
|
|
6
7
|
import type { FlowBuildContext } from '../context';
|
|
7
8
|
import type { PlacementOccurrence } from '../pagination/placement-occurrence';
|
|
8
9
|
/** 完整格内容与可见格片段的交集,不持有整份文档或回调。 */
|
|
@@ -13,6 +14,6 @@ export interface PlacedCellWindow {
|
|
|
13
14
|
readonly blocks: readonly LayoutBlockFragment[];
|
|
14
15
|
}
|
|
15
16
|
/** 保留完整格中的图片尺寸、垂直对齐和内边距,续页仅平移原坐标并裁剪。 */
|
|
16
|
-
export declare function placeCellWindow(cell: MeasuredTableCell, originX: number, originY: number, visible: LayoutRect, key: string, context: FlowBuildContext, occurrence?: PlacementOccurrence): PlacedCellWindow;
|
|
17
|
+
export declare function placeCellWindow(cell: MeasuredTableCell, originX: number, originY: number, visible: LayoutRect, key: string, context: FlowBuildContext, placeBlocks: MeasuredBlockPlacer, occurrence?: PlacementOccurrence): PlacedCellWindow;
|
|
17
18
|
/** 嵌套表沿原几何截取,可见跨度按当前窗口重算,合并主格仍使用原实例和来源。 */
|
|
18
|
-
export declare function placeTableWindow(table: MeasuredTable, originX: number, y: number, window: PlacementWindow, context: FlowBuildContext, occurrence?: PlacementOccurrence): LayoutTableFragment;
|
|
19
|
+
export declare function placeTableWindow(table: MeasuredTable, originX: number, y: number, window: PlacementWindow, context: FlowBuildContext, placeBlocks: MeasuredBlockPlacer, occurrence?: PlacementOccurrence): LayoutTableFragment;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/** @file 单行与跨行合并组的连续多页进度,源行/格与业务身份保持唯一。 */
|
|
2
|
-
import { ContentFlowCursor, type ContentFlowSlice } from '../pagination/content-flow';
|
|
3
2
|
import type { MeasuredTable, MeasuredTableCell, TableRowGroup } from './table-types';
|
|
4
3
|
import type { LayoutTableFragment } from '../../types/fragments';
|
|
5
4
|
import type { FlowBuildContext } from '../context';
|
|
5
|
+
import type { ContentFlowCursor, ContentFlowOperations, ContentFlowSlice } from '../pagination/content-flow';
|
|
6
6
|
/** 有效显式分页和超高行组使用连续流,固定祖先仍保持几何裁剪。 */
|
|
7
7
|
export declare function rowNeedsFlow(table: MeasuredTable, group: TableRowGroup, frameHeight: number, context: FlowBuildContext): boolean;
|
|
8
8
|
/** 合并格只有一个内容游标,显示行边界不重新创建字段或文字来源。 */
|
|
@@ -68,6 +68,7 @@ export declare class RowFlow {
|
|
|
68
68
|
private readonly table;
|
|
69
69
|
private readonly group;
|
|
70
70
|
private readonly context;
|
|
71
|
+
private readonly contentFlow;
|
|
71
72
|
/** 当前源显示行。 */
|
|
72
73
|
private index;
|
|
73
74
|
/** 物理页片段序号,不写入 model。 */
|
|
@@ -81,7 +82,7 @@ export declare class RowFlow {
|
|
|
81
82
|
/** 每个合并主格只注册一次进度。 */
|
|
82
83
|
private readonly cells;
|
|
83
84
|
/** 借用本轮测量结果,不创建新原生网格或业务值副本。 */
|
|
84
|
-
constructor(table: MeasuredTable, group: TableRowGroup, context: FlowBuildContext);
|
|
85
|
+
constructor(table: MeasuredTable, group: TableRowGroup, context: FlowBuildContext, contentFlow: ContentFlowOperations);
|
|
85
86
|
/** 所有源行完成后才进入下一行组。 */
|
|
86
87
|
get done(): boolean;
|
|
87
88
|
/** 后续页表头按当前真实显示行选择,不能始终沿用组首行。 */
|
|
@@ -3,6 +3,7 @@ import { RowFlow, type RowFlowSlice } from './row-flow';
|
|
|
3
3
|
import type { MeasuredTable, TableRowGroup } from './table-types';
|
|
4
4
|
import type { LayoutTableFragment } from '../../types/fragments';
|
|
5
5
|
import type { FlowBuildContext } from '../context';
|
|
6
|
+
import type { ContentFlowOperations } from '../pagination/content-flow';
|
|
6
7
|
/** 已测量完整行范围,候选期间不创建页面结果。 */
|
|
7
8
|
interface RangePart extends TableRowGroup {
|
|
8
9
|
/** 完整行放置类别。 */
|
|
@@ -47,6 +48,7 @@ export interface TableFlowCheckpoint {
|
|
|
47
48
|
export declare class TableFlow {
|
|
48
49
|
private readonly table;
|
|
49
50
|
private readonly context;
|
|
51
|
+
private readonly contentFlow;
|
|
50
52
|
/** 当前测量独占的表头与显式分页索引,完成后随游标释放。 */
|
|
51
53
|
private indexed?;
|
|
52
54
|
/** 当前尚未完成的行组下标。 */
|
|
@@ -56,7 +58,7 @@ export declare class TableFlow {
|
|
|
56
58
|
/** 只保留当前候选涉及的行组进度,完成即释放。 */
|
|
57
59
|
private readonly flows;
|
|
58
60
|
/** 借用同一次构建的测量及来源注册器,不创建全局状态。 */
|
|
59
|
-
constructor(table: MeasuredTable, context: FlowBuildContext);
|
|
61
|
+
constructor(table: MeasuredTable, context: FlowBuildContext, contentFlow: ContentFlowOperations);
|
|
60
62
|
/** 首次实际查询才建立规则,构造游标本身不创建中间索引。 */
|
|
61
63
|
private get rules();
|
|
62
64
|
/** 只有当前行组没有未完成内容流时,才允许保存恢复点。 */
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/** @file 字段括号共用的纯几何;宽度沿用已度量的槽,绘制和选中覆盖层不再分别猜位置。 */
|
|
2
|
+
import type { LayoutControl } from '../types/presentation/controls';
|
|
3
|
+
import type { LayoutTextStyle } from '../types/text';
|
|
4
|
+
export declare function controlBracketFrames(control: Pick<LayoutControl, 'bracketFrames' | 'bracketTexts'>, style: Pick<LayoutTextStyle, 'fontSizePx'>): NonNullable<LayoutControl['bracketFrames']>;
|
|
@@ -105,6 +105,14 @@ export interface LayoutControlPresentation {
|
|
|
105
105
|
}
|
|
106
106
|
/** 控件内已放置的一段文字,坐标相对原子片段左上角。 */
|
|
107
107
|
export interface LayoutControlText {
|
|
108
|
+
/** 跟随图片的附属文字,整页适配图片后仍保持原间距、字号和居中。 */
|
|
109
|
+
readonly imageDecoration?: {
|
|
110
|
+
readonly imageIndex: number;
|
|
111
|
+
readonly placement: 'right' | 'bottom';
|
|
112
|
+
readonly gapPx: number;
|
|
113
|
+
};
|
|
114
|
+
/** 图形附属文字可独立声明实际绘制样式,不继承字段状态色或下划线。 */
|
|
115
|
+
readonly style?: LayoutTextStyle;
|
|
108
116
|
/** 已解析的字体框,用于恢复旧版文字框装饰,不改变正文基线或行高。 */
|
|
109
117
|
readonly fontMetrics?: {
|
|
110
118
|
/** 字体框的上升高度。 */
|
|
@@ -168,6 +176,11 @@ export interface LayoutControl {
|
|
|
168
176
|
readonly decoration?: LayoutControlDecoration;
|
|
169
177
|
/** 已度量的字段首尾括号,保持细体正体,不进入实际填写值。 */
|
|
170
178
|
readonly bracketTexts?: readonly LayoutControlText[];
|
|
179
|
+
/** 签名等整组图形的细线括号,高度跟随当前页面片段,不放大文字字形。 */
|
|
180
|
+
readonly bracketFrames?: readonly {
|
|
181
|
+
readonly side: 'start' | 'end';
|
|
182
|
+
readonly frame: LayoutRect;
|
|
183
|
+
}[];
|
|
171
184
|
/** 多页字段只保存当前片段的展示坐标,编辑仍读取完整业务值。 */
|
|
172
185
|
readonly continuation?: {
|
|
173
186
|
/** 排版端实际度量的内部文字行高,活动文本框沿用同一值。 */
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/** @file 图片只读展示协议;解码对象和加载任务始终由外部资源所有者管理。 */
|
|
2
2
|
import type { DeepReadonly, ImageAsset } from '../../../model/index';
|
|
3
|
+
import type { SignatureGraphic } from '../../../shared/signature-graphic';
|
|
3
4
|
import type { LayoutRect } from '../geometry';
|
|
4
5
|
/** 模板资产和业务地址共用的窄来源,不携带整个资产表或业务记录。 */
|
|
5
6
|
export type LayoutImageSource = DeepReadonly<ImageAsset['source']>;
|
|
@@ -19,6 +20,13 @@ export interface LayoutImageGalleryPresentation {
|
|
|
19
20
|
}
|
|
20
21
|
/** 一张图片的最终绘制快照,frame 相对所属原子片段。 */
|
|
21
22
|
export interface LayoutImage extends LayoutImagePresentation {
|
|
23
|
+
/** 独立图形可指定与旧版一致的加载占位,缺省文字为空。 */
|
|
24
|
+
readonly placeholder?: {
|
|
25
|
+
readonly backgroundColor: string;
|
|
26
|
+
readonly text?: string;
|
|
27
|
+
};
|
|
28
|
+
/** 同步生成的签名矢量图;无需下载、解码或保存到文档资产。 */
|
|
29
|
+
readonly graphic?: SignatureGraphic;
|
|
22
30
|
/** 同步度量时的状态。 */
|
|
23
31
|
readonly state: 'pending' | 'ready' | 'error';
|
|
24
32
|
/** 与解码资源一一对应的版本,旧结果不能绘制替换后的图片。 */
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/** @file 签名绘制输入仅保存当前可见图片与文字,不包含认证记录或业务服务。 */
|
|
2
2
|
import type { LayoutImagePresentation } from './images';
|
|
3
|
+
import type { SignatureAppearance } from '../../../shared/signature-graphic';
|
|
3
4
|
/** 一位签署人的最终展示内容。 */
|
|
4
5
|
export interface LayoutSignaturePresentation {
|
|
5
6
|
/** 当前签名图片;无图片时显示文字。 */
|
|
@@ -10,9 +11,14 @@ export interface LayoutSignaturePresentation {
|
|
|
10
11
|
readonly timeText: string;
|
|
11
12
|
/** 图片是否采用竖向尺寸。 */
|
|
12
13
|
readonly vertical: boolean;
|
|
14
|
+
/** 无图签名的内部日期栏,不与外置日期互相替代。 */
|
|
15
|
+
readonly fallback?: 'name' | 'name-and-date';
|
|
16
|
+
readonly fallbackDate?: string;
|
|
13
17
|
}
|
|
14
18
|
/** 多位签署人的组合排版,签署次数不会变成字符节点。 */
|
|
15
19
|
export interface LayoutSignatureGalleryPresentation {
|
|
20
|
+
/** 每张签名的配置尺寸,整组排版宽度由实际内容决定。 */
|
|
21
|
+
readonly imageSize?: Pick<SignatureAppearance, 'width' | 'height'>;
|
|
16
22
|
/** 按已保存顺序展示。 */
|
|
17
23
|
readonly items: readonly LayoutSignaturePresentation[];
|
|
18
24
|
/** 日期在图片右侧或下方。 */
|
|
@@ -14,8 +14,10 @@ export interface FieldDependency {
|
|
|
14
14
|
expression?: string | null;
|
|
15
15
|
/** 表达式的人类可读文本。 */
|
|
16
16
|
expressionLabel?: string | null;
|
|
17
|
+
/** 赋值类型;缺省按公式计算,clear 将表达式作为清空条件。 */
|
|
18
|
+
assignmentType?: 'formula' | 'clear' | null;
|
|
17
19
|
/** 赋值覆盖策略,仅赋值联动使用。 */
|
|
18
|
-
strategy?: 'alwaysCover' | 'notCovered' | null;
|
|
20
|
+
strategy?: 'alwaysCover' | 'notCovered' | 'notCoveredForever' | null;
|
|
19
21
|
/** 固定布尔配置,显式 false 必须保留。 */
|
|
20
22
|
value?: boolean | null;
|
|
21
23
|
}
|
|
@@ -273,9 +275,15 @@ export interface BoundedConfig {
|
|
|
273
275
|
mainFieldBindings?: string[] | null;
|
|
274
276
|
/** 当前行触发数据锁定的签名字段键;仅保存声明,不保存签名值或已锁定状态。 */
|
|
275
277
|
dataLockControlField?: 'inspector_' | 'reviewer_' | null;
|
|
278
|
+
/** 行锁定后仍允许编辑的相对字段路径。 */
|
|
279
|
+
excludedFields?: string[] | null;
|
|
276
280
|
}
|
|
277
281
|
/** 动态表区域的通用行为。 */
|
|
278
282
|
export interface RepeatingConfig {
|
|
283
|
+
/** 普通动态表的单人签名控制字段,相对于当前数据行。 */
|
|
284
|
+
dataLockControlField?: string | null;
|
|
285
|
+
/** 行锁定后仍允许编辑的相对字段路径。 */
|
|
286
|
+
excludedFields?: string[] | null;
|
|
279
287
|
/** 是否允许快速填充。 */
|
|
280
288
|
quickFill?: boolean | null;
|
|
281
289
|
/** 删除前是否确认。 */
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { ModelQuery } from '../query/ModelQuery';
|
|
2
|
+
import type { JsonObject } from '../types';
|
|
3
|
+
export interface DataLockField {
|
|
4
|
+
readonly value: string;
|
|
5
|
+
readonly label: string;
|
|
6
|
+
readonly eligible: boolean;
|
|
7
|
+
readonly fieldType?: string;
|
|
8
|
+
readonly businessType?: string;
|
|
9
|
+
readonly widget?: string;
|
|
10
|
+
}
|
|
11
|
+
/** 纯文字、样式和业务值变化不触发锁配置扫描。 */
|
|
12
|
+
export declare function affectsDataLockConfig(operation: {
|
|
13
|
+
readonly kind: 'text' | 'splice' | 'business';
|
|
14
|
+
} | {
|
|
15
|
+
readonly kind: 'dictionary';
|
|
16
|
+
readonly dictionary: string;
|
|
17
|
+
} | {
|
|
18
|
+
readonly kind: 'set';
|
|
19
|
+
readonly key: string;
|
|
20
|
+
}): boolean;
|
|
21
|
+
/** 从所属区域实际放置的字段采集,包含条件附属字段和嵌套表。 */
|
|
22
|
+
export declare function collectDataLockFields(query: ModelQuery, regionId: string): readonly DataLockField[];
|
|
23
|
+
/** 只修正已显式声明的锁定属性,保留区域的其余配置。 */
|
|
24
|
+
export declare function normalizeDataLockConfigs(query: ModelQuery): readonly {
|
|
25
|
+
regionId: string;
|
|
26
|
+
config: JsonObject;
|
|
27
|
+
}[];
|
|
@@ -16,7 +16,7 @@ export interface NativeSignaturesOptions {
|
|
|
16
16
|
/** 业务签名前必须检查的同文档路径。 */
|
|
17
17
|
validationPaths?(path: string): readonly string[];
|
|
18
18
|
/** 使用正式字段规则校验签名依赖项。 */
|
|
19
|
-
validatePaths?(paths: readonly string[], signal: AbortSignal): Promise<void>;
|
|
19
|
+
validatePaths?(paths: readonly string[], signal: AbortSignal, sourcePath: string): Promise<void>;
|
|
20
20
|
}
|
|
21
21
|
/** 每个展示服务只拥有自己的认证请求和凭据,关闭后旧引用不能触达文档。 */
|
|
22
22
|
export declare class NativeSignatures {
|
|
@@ -32,6 +32,8 @@ export declare class NativeSignatures {
|
|
|
32
32
|
private readonly unsubscribeModel;
|
|
33
33
|
/** 仅建立失效订阅,打开表单不触发认证。 */
|
|
34
34
|
constructor(options: NativeSignaturesOptions);
|
|
35
|
+
/** 打开签名框前只校验字段;无校验路径时保持同步返回。 */
|
|
36
|
+
validateBeforeOpen(fieldId: string, instance: string, signal: AbortSignal): Promise<void> | undefined;
|
|
35
37
|
/** 手动认证得到当前会话的不透明预览凭据,确认之前不写任何业务值。 */
|
|
36
38
|
prepare(fieldId: string, instance: string, signal: AbortSignal, authorization?: NativeSignatureAuthorization): Promise<NativeSignatureDraft | undefined>;
|
|
37
39
|
/** 只接受本会话的有效认证,先完成互斥与回填检查,再复用 DataManager 用户写入链。 */
|
|
@@ -3,6 +3,8 @@ import type { DocumentHandle } from '../../../session';
|
|
|
3
3
|
import type { FieldEnvironment, FieldFlags } from '../../fields/contracts/state';
|
|
4
4
|
/** 按模型版本缓存声明;权限每次从当前行读取,签名确认和撤销立即可见。 */
|
|
5
5
|
export declare function createDeviceSignatureLocks(handle: DocumentHandle, data: DataManager, environment: () => FieldEnvironment): {
|
|
6
|
+
/** 例外字段不解除整行锁;菜单和执行入口共用同一判断。 */
|
|
7
|
+
rowLocked(axis: string, index: number): boolean;
|
|
6
8
|
/** 给公共字段状态提供强制只读和禁用标记。 */
|
|
7
9
|
flags(path: string): FieldFlags;
|
|
8
10
|
/** 第一次控制签名前检查参与校验的绑定主字段和同行路径。 */
|
|
@@ -14,4 +14,4 @@ export declare function clearCopiedAuthentication(options: NativeBusinessTablesO
|
|
|
14
14
|
/** 按真实槽位及附属条件筛选本行字段,新行只用空标记投影活动坐标。 */
|
|
15
15
|
export declare function tableRowTargets(options: NativeBusinessTablesOptions, axis: string, index: number, fields: readonly NativeFieldDeclaration[], prospective?: boolean, readAxis?: NativeTargetOptions['readAxis']): readonly NativeFieldDeclaration[];
|
|
16
16
|
/** 轴复制会连带复制该轴全部交叉格,认证检查包含隐藏、超容量及其他关联区。 */
|
|
17
|
-
export declare function authenticatedMatrixRow(options: NativeBusinessTablesOptions, axis: string, index: number): boolean;
|
|
17
|
+
export declare function authenticatedMatrixRow(options: NativeBusinessTablesOptions, axis: string, index: number, onlyKind?: 'signature' | 'seal'): boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/** @file 判断原生事务是否改变数据声明,普通文字和绘制样式不重建规则或重跑请求。 */
|
|
2
|
-
import type { ReadonlyChangeSet } from '../../../../model';
|
|
2
|
+
import type { ModelQuery, ReadonlyChangeSet } from '../../../../model';
|
|
3
3
|
/** 绑定、业务配置和表格结构需要刷新,文字及绘制属性沿用当前数据规则。 */
|
|
4
|
-
export declare function affectsNativeDataDeclarations(change: ReadonlyChangeSet): boolean;
|
|
4
|
+
export declare function affectsNativeDataDeclarations(change: ReadonlyChangeSet, query?: Pick<ModelQuery, 'getEntity'>): boolean;
|
|
@@ -13,8 +13,10 @@ export declare class CommonFieldRules {
|
|
|
13
13
|
private generation;
|
|
14
14
|
/** 系统默认值按字段及配置缓存,避免普通输入导致时钟变化。 */
|
|
15
15
|
private readonly systemDefaults;
|
|
16
|
-
/**
|
|
16
|
+
/** 以稳定业务行身份保存手填保护,插行或换序不会套用到其他行。 */
|
|
17
17
|
private readonly assignmentMarks;
|
|
18
|
+
/** 仅缓存实际公式输入,规则重建继续沿用;整份数据恢复时清除。 */
|
|
19
|
+
private readonly assignmentEvaluations;
|
|
18
20
|
/** 只保存注入能力。 */
|
|
19
21
|
constructor(options: FieldRulesOptions);
|
|
20
22
|
/** 是否仍可接受当前异步返回。 */
|
|
@@ -25,6 +27,8 @@ export declare class CommonFieldRules {
|
|
|
25
27
|
private releaseScope;
|
|
26
28
|
/** 当前普通输入不重建全部字段,根/行身份/控制值变化才失效目标集合。 */
|
|
27
29
|
dataChanged(path: string, source: DataSource): boolean;
|
|
30
|
+
/** 所有用户写入共用空值语义,0 和 false 不解除保护。 */
|
|
31
|
+
private markAssignmentEdit;
|
|
28
32
|
/** 主表按路径、行字段按稳定行键识别赋值所有权。 */
|
|
29
33
|
private assignmentIdentity;
|
|
30
34
|
/** 重建当前字段声明,按附属深度逐层准备默认值及公式。 */
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { NativeValidationIssue } from './types';
|
|
1
|
+
import type { NativeValidationIssue, NativeValidationResult } from './types';
|
|
2
|
+
import type { SessionVersions } from '../../session';
|
|
2
3
|
import type { NativeSubmissionPreparationResult } from '../submission/coordinator-types';
|
|
3
4
|
type FieldDiagnostic = NativeValidationIssue & {
|
|
4
5
|
readonly stage?: 'signatures';
|
|
@@ -18,15 +19,26 @@ export declare class NativeFieldValidation {
|
|
|
18
19
|
private failure?;
|
|
19
20
|
private versions?;
|
|
20
21
|
private readonly listeners;
|
|
22
|
+
private readonly scopedRequired;
|
|
23
|
+
private readonly requiredScopes;
|
|
21
24
|
private required;
|
|
22
25
|
constructor(options: NonNullable<NativeFieldValidation['options']>);
|
|
23
26
|
/** 诊断只刷新视图,不推进业务环境代次或打断正在进行的正式提交。 */
|
|
24
|
-
subscribe(listener: () => void): () => void;
|
|
27
|
+
subscribe(listener: (reason?: 'check') => void): () => void;
|
|
25
28
|
start(): void;
|
|
26
29
|
/** 明确完整检查后继续保留必填诊断,后续编辑自动清除已修正的问题。 */
|
|
27
30
|
revealRequired(): void;
|
|
28
31
|
/** 活动草稿沿用已经启动的完整检查必填策略。 */
|
|
29
32
|
get checksRequired(): boolean;
|
|
33
|
+
checksRequiredFor(path: string): boolean;
|
|
34
|
+
/** 主字段和同行字段共用触发签名所在行的生命周期。 */
|
|
35
|
+
private rememberScopedRequired;
|
|
36
|
+
/** 行换位、替换或软删后丢弃旧范围,普通字段修改继续保留提示。 */
|
|
37
|
+
private pruneScopedRequired;
|
|
38
|
+
private dropScopedReferences;
|
|
39
|
+
private clearScopedRequired;
|
|
40
|
+
/** 接收本轮完整字段结果,只保存路径和诊断,不保存填写值。 */
|
|
41
|
+
followScopedCheck(sourcePath: string, paths: readonly string[], result: NativeValidationResult, versions: SessionVersions): boolean;
|
|
30
42
|
/** 只接受同一代次真正执行过的完整字段检查;草稿、提前终止和取消不启用必填续查。 */
|
|
31
43
|
followCompleteCheck(result: NativeSubmissionPreparationResult): void;
|
|
32
44
|
/** 只交出当前模型和数据代次的轻量诊断。 */
|
|
@@ -39,6 +51,8 @@ export declare class NativeFieldValidation {
|
|
|
39
51
|
private publish;
|
|
40
52
|
/** 环境变化可重排,但模型或填写值换代后不能显示旧错误。 */
|
|
41
53
|
message(fieldId: string, valuePath: string): string | undefined;
|
|
54
|
+
/** 每条诊断保持独立,界面不从文案中的标点反推规则边界。 */
|
|
55
|
+
messages(fieldId: string, valuePath: string): readonly string[];
|
|
42
56
|
whenSettled(): Promise<void>;
|
|
43
57
|
dispose(): void;
|
|
44
58
|
}
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import type { CommonFieldDeclaration } from '../fields/contracts/behavior';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
/** 纸边批注和输入提示共用的标量展示信息。 */
|
|
3
|
+
export interface NativeFieldValidationDescription {
|
|
4
|
+
readonly label: string;
|
|
5
|
+
readonly context: string;
|
|
6
|
+
readonly modelName: string;
|
|
7
|
+
readonly modelKind: 'main' | 'sub' | 'linked';
|
|
8
|
+
}
|
|
9
|
+
export declare function fieldValidationDescription(declaration: CommonFieldDeclaration, path: string, modelName?: string): NativeFieldValidationDescription;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/** @file 校验目标直接从原生结构、条件和运行权限求得,不读取 pages 或构造 WidgetMeta。 */
|
|
2
2
|
import type { NativeValidationMode, NativeValidationTargets, NativeValidatorOptions } from './types';
|
|
3
3
|
/** 展示沿用异常保留覆盖;其他模式沿用只读/禁用不进入校验门禁的既有规则。 */
|
|
4
|
-
export declare function nativeValidationTargets(options: NativeValidatorOptions, mode: NativeValidationMode, paths?: ReadonlySet<string>, widgets?: ReadonlySet<string>, blockedOnly?: boolean, includeRequired?: boolean): NativeValidationTargets;
|
|
4
|
+
export declare function nativeValidationTargets(options: NativeValidatorOptions, mode: NativeValidationMode, paths?: ReadonlySet<string>, widgets?: ReadonlySet<string>, blockedOnly?: boolean, includeRequired?: boolean, requiredPaths?: ReadonlySet<string>): NativeValidationTargets;
|
|
@@ -58,6 +58,8 @@ export interface NativeValidationRequest {
|
|
|
58
58
|
readonly blockedOnly?: true;
|
|
59
59
|
/** 仅 change/blur 使用:完整检查后继续检查必填,不触发 all 的后台记录复核。 */
|
|
60
60
|
readonly includeRequired?: boolean;
|
|
61
|
+
/** 仅 change/blur 使用:只对指定路径继续检查必填,不过滤其他校验目标。 */
|
|
62
|
+
readonly requiredPaths?: Iterable<string>;
|
|
61
63
|
/** 仅 change/blur 使用的当前文本或数值草稿,不写仓库,不参与正式提交快照。 */
|
|
62
64
|
readonly draft?: {
|
|
63
65
|
readonly fieldId: string;
|
|
@@ -71,7 +71,7 @@ export declare class EditorController {
|
|
|
71
71
|
selectCells(selection: CellSelection): void;
|
|
72
72
|
/** 选择真实字段发生;路径、权限和值不复制进选区。 */
|
|
73
73
|
selectField(fieldId: string, instanceKey: string): void;
|
|
74
|
-
/**
|
|
74
|
+
/** 查询相邻可填写字段;规则准备期间由浏览器等待,文档边界返回 undefined。 */
|
|
75
75
|
getFieldTabStop(direction: -1 | 1): FieldSelection | 'pending' | undefined;
|
|
76
76
|
/** 使用同一提交准备生成校验反馈,返回值仅包含版本及可显示诊断。 */
|
|
77
77
|
checkSubmission(signal: AbortSignal): Promise<EditorValidationReport>;
|
|
@@ -173,6 +173,8 @@ export declare class EditorController {
|
|
|
173
173
|
requestFieldValidation(): void;
|
|
174
174
|
/** 数值输入中的短期校验复用正式字段规则,取消不影响已提交值或提交门禁。 */
|
|
175
175
|
validateFieldText(text: string, expected: FieldTextInputState, signal: AbortSignal): Promise<string | undefined>;
|
|
176
|
+
/** 列表展示复用同一草稿校验,保留每条规则的文案边界。 */
|
|
177
|
+
validateFieldTextMessages(text: string, expected: FieldTextInputState, signal: AbortSignal): Promise<readonly string[] | undefined>;
|
|
176
178
|
/** 当前输入草稿只参与本视图排版,原值、声明和发生必须仍与激活基值一致。 */
|
|
177
179
|
previewFieldText(text: string, expected: FieldTextInputState, validationError?: boolean): void;
|
|
178
180
|
/** 编辑结束只撤销短期展示,不回写半成品数值或输入法候选。 */
|
|
@@ -191,6 +193,8 @@ export declare class EditorController {
|
|
|
191
193
|
clearFieldOptions(expected: FieldOptionInputState): boolean;
|
|
192
194
|
/** 读取当前签名的最小摘要,不自动发起认证。 */
|
|
193
195
|
getFieldSignatureInput(): FieldSignatureInputState | undefined;
|
|
196
|
+
/** 弹框前预检查,不认证;无校验需求时保持同步。 */
|
|
197
|
+
validateFieldSignature(expected: FieldSignatureInputState, signal: AbortSignal): Promise<void> | undefined;
|
|
194
198
|
/** 用户明确认证后取得原业务服务的不透明预览;取消和过期结果不写入。 */
|
|
195
199
|
prepareFieldSignature(expected: FieldSignatureInputState, signal: AbortSignal, authorization?: FieldSignatureAuthorization): Promise<FieldSignatureDraft | undefined>;
|
|
196
200
|
/** 确认仅接受本控制器针对同一激活签发的凭据,互斥和属性回填由签署服务完成。 */
|
|
@@ -108,7 +108,7 @@ export interface ReadonlyActionHit {
|
|
|
108
108
|
}
|
|
109
109
|
/** 本地字段预览,只包含已有资源的短期展示地址,不提供编辑能力。 */
|
|
110
110
|
export interface ReadonlyMediaPreview {
|
|
111
|
-
readonly kind: 'file' | 'image'
|
|
111
|
+
readonly kind: 'file' | 'image';
|
|
112
112
|
readonly label: string;
|
|
113
113
|
readonly entries: readonly ReadonlyResourceEntry[];
|
|
114
114
|
}
|
|
@@ -7,9 +7,9 @@ export declare class EditorFormat {
|
|
|
7
7
|
private context?;
|
|
8
8
|
/** 构造不读取样式目录、创建段落或触发排版。 */
|
|
9
9
|
constructor(context: DesignFormattingContext);
|
|
10
|
-
/**
|
|
10
|
+
/** 按当前文字或格选区读取小份格式,填报值不作为模板文字处理。 */
|
|
11
11
|
read(): DesignFormatState | undefined;
|
|
12
|
-
/**
|
|
12
|
+
/** 折叠光标只发布输入意图;文字范围或格内内容通过原生 API 修改并保留选区。 */
|
|
13
13
|
applyText(expected: DesignFormatState, update: TextFormatUpdate): ReadonlyChangeSet | null;
|
|
14
14
|
/** 段落格式作用于真实触达段落;空集合只有明确设置时才物化一个段落。 */
|
|
15
15
|
applyParagraph(expected: DesignFormatState, update: ParagraphFormatUpdate): ReadonlyChangeSet | null;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type { DesignFormatProperties, DesignFormatState, DesignFormattingContext } from './types';
|
|
2
|
-
import type { TextSelection } from '../../types';
|
|
3
2
|
/** 对小份有效属性比较嵌套值,只输出共同值和存在差异的键。 */
|
|
4
3
|
export declare function common<T extends object>(styles: readonly T[]): DesignFormatProperties<T>;
|
|
5
4
|
/** 读取选择触达的真实文字/字段/页组件;下一段起点不串入当前格式摘要。 */
|
|
6
|
-
export declare function readFormat(context: DesignFormattingContext, selection:
|
|
5
|
+
export declare function readFormat(context: DesignFormattingContext, selection: DesignFormatState['selection']): DesignFormatState;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { DesignFormatState, DesignFormattingContext } from './types';
|
|
2
|
+
import type { ContentRange } from '../../../../model';
|
|
3
|
+
import type { BlockGap } from '../../text/TextFlow';
|
|
4
|
+
/** 格选择覆盖可见合并主格内的所有段落,空格仅在明确设置格式时由调用方物化。 */
|
|
5
|
+
export declare function formatTargets(context: DesignFormattingContext, selection: DesignFormatState['selection']): Generator<ContentRange | BlockGap>;
|
|
6
|
+
/** 文字范围沿用原生投影;格选择只返回选中主格内的模板文字和原子声明。 */
|
|
7
|
+
export declare function formatInlines(context: DesignFormattingContext, selection: DesignFormatState['selection']): {
|
|
8
|
+
id: string;
|
|
9
|
+
from: number;
|
|
10
|
+
to: number;
|
|
11
|
+
}[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/** @file 格式设计的独立小快照、混合值摘要和窄输入能力。 */
|
|
2
2
|
import type { DeepReadonly, PageSettings, ParagraphStyle, TextFormatUpdate, TextStyle } from '../../../../model';
|
|
3
3
|
import type { TextFlow } from '../../text/TextFlow';
|
|
4
|
-
import type { TextSelection } from '../../types';
|
|
4
|
+
import type { CellSelection, TextSelection } from '../../types';
|
|
5
5
|
import type { DesignCommandContext, DesignTargetIdentity } from '../types';
|
|
6
6
|
/** 选区共同格式与混合键;混合值不伪装为第一个节点的格式。 */
|
|
7
7
|
export interface DesignFormatProperties<T extends object> {
|
|
@@ -10,10 +10,10 @@ export interface DesignFormatProperties<T extends object> {
|
|
|
10
10
|
/** 目标存在差异的顶层属性,嵌套声明按整体比较。 */
|
|
11
11
|
readonly mixed: readonly (keyof T)[];
|
|
12
12
|
}
|
|
13
|
-
/**
|
|
13
|
+
/** 当前文字或单元格选区的隔离格式状态,不持有任何模型节点。 */
|
|
14
14
|
export interface DesignFormatState extends DesignTargetIdentity {
|
|
15
15
|
/** 当前带方向的逻辑选区,写入前必须复核没有改选目标。 */
|
|
16
|
-
readonly selection: TextSelection;
|
|
16
|
+
readonly selection: TextSelection | CellSelection;
|
|
17
17
|
/** 折叠光标的文字格式只改变后续输入意图。 */
|
|
18
18
|
readonly typing: boolean;
|
|
19
19
|
/** 当前触达的段落或空内容集合数量。 */
|
|
@@ -39,12 +39,14 @@ export declare class EditorTableRegions {
|
|
|
39
39
|
update(expected: DesignRegionState, update: RegionUpdate): ReadonlyChangeSet | null;
|
|
40
40
|
/** 用当前已确认表选区更新区域范围;两个来源必须属于同一模型版本和发生。 */
|
|
41
41
|
setRange(expected: DesignRegionState, table: DesignTableState): ReadonlyChangeSet | null;
|
|
42
|
-
/**
|
|
42
|
+
/** 删除业务/数据表或分组时联删其字段;独立删除表头只移除声明,普通格内容保留。 */
|
|
43
43
|
remove(expected: DesignRegionState, options?: RemoveRegionOptions): ReadonlyChangeSet | null;
|
|
44
44
|
/** 高亮当前区域的实际范围,不分配模型身份或历史。 */
|
|
45
45
|
select(expected: DesignRegionState): void;
|
|
46
46
|
/** 关闭使旧区域 API 和目录回调都无法继续访问文档。 */
|
|
47
47
|
dispose(): void;
|
|
48
|
+
/** 按物理格收集主体及级联分组/表头的字段根;附属子树随所属字段一次删除。 */
|
|
49
|
+
private removalFields;
|
|
48
50
|
/** 读取只检查打开及模型版本;不会为只读查看要求可写权限。 */
|
|
49
51
|
private readTarget;
|
|
50
52
|
/** 区域身份必须仍属于当前目标表,不能复用相同 ID 的另一个打开。 */
|
|
@@ -25,3 +25,10 @@ export interface DesignRegionVariantItem {
|
|
|
25
25
|
export declare const designRegionTypes: readonly DesignRegionTypeItem[];
|
|
26
26
|
/** 当前支持的业务来源配置目录,不以目录加载代替真实平台接入。 */
|
|
27
27
|
export declare const designRegionVariants: readonly DesignRegionVariantItem[];
|
|
28
|
+
/** 画布标签和属性面包屑共用具体类型名称,业务变体优先。 */
|
|
29
|
+
export declare function designRegionLabel(region: {
|
|
30
|
+
readonly type: RegionType;
|
|
31
|
+
readonly variant?: {
|
|
32
|
+
readonly name: ExtensionName;
|
|
33
|
+
};
|
|
34
|
+
}): string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { FieldValueGuard } from './field-value-guard';
|
|
2
2
|
import type { EditorControllerOptions, EditorSelection, FieldSelection } from './types';
|
|
3
|
+
import type { SignatureAppearance } from '../../shared/signature-graphic';
|
|
3
4
|
import type { NativeSignatureAuthorization, NativeSignatureDraft } from '../form/business/signatures/types';
|
|
4
5
|
import type { DocumentHandle } from '../session';
|
|
5
6
|
/** 浏览器只持有既有服务发放的不透明凭据,不能把姓名/时间对象作为有效签署记录提交。 */
|
|
@@ -17,6 +18,8 @@ export interface FieldSignatureRecord {
|
|
|
17
18
|
}
|
|
18
19
|
/** 单次签名激活的只读状态;原值仅供比较,不作为签署写入值。 */
|
|
19
20
|
export interface FieldSignatureInputState extends FieldValueGuard {
|
|
21
|
+
/** 签名图形的最终配置,不向面板传递整个字段或认证记录。 */
|
|
22
|
+
readonly appearance?: SignatureAppearance;
|
|
20
23
|
/** 明确使用专门签署通道。 */
|
|
21
24
|
readonly widget: 'signature';
|
|
22
25
|
readonly inlineAuthorization?: boolean;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/** @file 活动文本字段的最小同步协议和旧事件保护,不包含 DOM、布局几何或数据副本。 */
|
|
2
2
|
import type { FieldValueGuard } from './field-value-guard';
|
|
3
3
|
import type { EditorControllerOptions, EditorSelection, FieldSelection } from './types';
|
|
4
|
+
import type { NativeFieldValidationDescription } from '../form/validation/description';
|
|
4
5
|
import type { DocumentHandle } from '../session';
|
|
5
6
|
/** 一次读取的活动输入状态,值仅允许标量;浏览器用它复核当前焦点和提交基值。 */
|
|
6
7
|
export interface FieldTextInputState extends FieldValueGuard {
|
|
@@ -18,11 +19,10 @@ export interface FieldTextInputState extends FieldValueGuard {
|
|
|
18
19
|
readonly pending: boolean;
|
|
19
20
|
/** 当前已提交数值的轻量校验反馈,不包含草稿或业务数据副本。 */
|
|
20
21
|
readonly validationMessage?: string;
|
|
22
|
+
/** 按规则保留独立文案,列表展示不拆分消息里的分号或换行。 */
|
|
23
|
+
readonly validationMessages?: readonly string[];
|
|
21
24
|
readonly validationPath?: string;
|
|
22
|
-
readonly validationDescription?:
|
|
23
|
-
readonly label: string;
|
|
24
|
-
readonly context: string;
|
|
25
|
-
};
|
|
25
|
+
readonly validationDescription?: NativeFieldValidationDescription;
|
|
26
26
|
}
|
|
27
27
|
/** 借用旧实例身份解析当前数据,绝不将旧几何当成有效输入框坐标。 */
|
|
28
28
|
export declare function readFieldTextInput(handle: DocumentHandle, options: EditorControllerOptions, selection: FieldSelection): FieldTextInputState | undefined;
|
|
@@ -31,4 +31,4 @@ export declare function writeGuardedFieldText(handle: DocumentHandle, options: E
|
|
|
31
31
|
/** 展示与写入共用同一活动基值判定,不将整份数据版本当成当前字段身份。 */
|
|
32
32
|
export declare function sameFieldTextInput(current: FieldTextInputState | undefined, expected: FieldTextInputState): boolean;
|
|
33
33
|
/** 当前数字草稿仅用于短期校验;异步前后复核焦点、配置和原值,不把草稿写进仓库。 */
|
|
34
|
-
export declare function validateFieldTextDraft(handle: DocumentHandle, options: EditorControllerOptions, selection: () => EditorSelection | null, expected: FieldTextInputState, text: string, signal: AbortSignal): Promise<string | undefined>;
|
|
34
|
+
export declare function validateFieldTextDraft(handle: DocumentHandle, options: EditorControllerOptions, selection: () => EditorSelection | null, expected: FieldTextInputState, text: string, signal: AbortSignal): Promise<readonly string[] | undefined>;
|
|
@@ -7,6 +7,8 @@ export interface EditorValidationIssue extends NativeSubmissionCheckIssue {
|
|
|
7
7
|
/** 字段、表格或文档标题,按本次稳定模型解析。 */
|
|
8
8
|
readonly label: string;
|
|
9
9
|
readonly context?: string;
|
|
10
|
+
readonly modelName?: string;
|
|
11
|
+
readonly modelKind?: 'main' | 'sub' | 'linked';
|
|
10
12
|
}
|
|
11
13
|
/** 单轮检查的轻量结果,不保留提交数据或原业务检查对象。 */
|
|
12
14
|
export interface EditorValidationReport {
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
/** @file 读取签名的显示声明,不认证、不改值、不创建姓名位图缓存。 */
|
|
2
2
|
import type { LayoutSignatureGalleryPresentation } from '../../../layout/types/presentation/signatures';
|
|
3
3
|
import type { DeepReadonly, SignatureConfig } from '../../../model';
|
|
4
|
-
/**
|
|
5
|
-
export declare function signatureGallery(config: DeepReadonly<SignatureConfig> | undefined, value: unknown, url: (value: string) => string | undefined
|
|
4
|
+
/** 先解析姓名图形和跟随日期的声明,度量与绘制共用旧版显示规则。 */
|
|
5
|
+
export declare function signatureGallery(config: DeepReadonly<SignatureConfig> | undefined, value: unknown, url: (value: string) => string | undefined, imageSize?: {
|
|
6
|
+
readonly width: number;
|
|
7
|
+
readonly height: number;
|
|
8
|
+
}): LayoutSignatureGalleryPresentation | undefined;
|
|
@@ -20,6 +20,8 @@ interface GctTemplateVersion {
|
|
|
20
20
|
/** 平台保存的设计与运行正文。 */
|
|
21
21
|
readonly runtimeJson?: unknown;
|
|
22
22
|
readonly designerJson?: unknown;
|
|
23
|
+
/** 平台单独保存的 OCR / 设备通信配置;Word 设计器转换旧模板时自动导入,套件侧无需额外处理。 */
|
|
24
|
+
readonly communicationConfig?: unknown;
|
|
23
25
|
}
|
|
24
26
|
/** 模板 BOM 查询与保存共用的记录,业务字段由编辑器适配。 */
|
|
25
27
|
export interface GctTemplateBomRecord extends Record<string, unknown> {
|