@agile-team/mach-report 2.15.0 → 2.17.0
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 +21 -12
- package/dist/{ExcelBindingWizard-Bs43BGNp.cjs → ExcelBindingWizard-Bq6FYME6.cjs} +1 -1
- package/dist/{ExcelBindingWizard-BKH1nGNS.js → ExcelBindingWizard-Co1svTsw.js} +3 -3
- package/dist/{ParamEditor-Da4akw6V.cjs → ParamEditor-B5UZRgxv.cjs} +1 -1
- package/dist/{ParamEditor-DoAhzJsm.js → ParamEditor-DNNARyeB.js} +1 -1
- package/dist/{ReportBatchPanel-wP9m9Pj1.cjs → ReportBatchPanel-Ctvs2t_9.cjs} +1 -1
- package/dist/{ReportBatchPanel-BMf6boMA.js → ReportBatchPanel-uQh06usx.js} +3 -3
- package/dist/ReportPreview-BdQawRh0.js +4879 -0
- package/dist/ReportPreview-CJC_-j2I.cjs +6 -0
- package/dist/{ReportTemplateLibrary-Sxr3eD0J.cjs → ReportTemplateLibrary-CnP7_1pH.cjs} +1 -1
- package/dist/{ReportTemplateLibrary-C9wutIiT.js → ReportTemplateLibrary-TIL_Oj2l.js} +1 -1
- package/dist/RuleEditor-DkRjOLlr.js +2141 -0
- package/dist/RuleEditor-h5anGsDB.cjs +1 -0
- package/dist/{TemplateOutlinePanel-JTSR53vJ.cjs → TemplateOutlinePanel-BlLxRrfu.cjs} +1 -1
- package/dist/{TemplateOutlinePanel-D6Bkny59.js → TemplateOutlinePanel-BouxsuqQ.js} +1 -1
- package/dist/{TemplateReusePanel-rVuK1kTz.js → TemplateReusePanel-BEACLPaN.js} +2 -2
- package/dist/{TemplateReusePanel-Kx35S0Ql.cjs → TemplateReusePanel-yxsHSO40.cjs} +1 -1
- package/dist/{TemplateReviewPanel-B0ar9_zf.js → TemplateReviewPanel-B1OGRY2i.js} +1 -1
- package/dist/{TemplateReviewPanel-Dn6X9UmY.cjs → TemplateReviewPanel-D9Cx0m2N.cjs} +1 -1
- package/dist/analytics.cjs +1 -1
- package/dist/analytics.d.cts +65 -1
- package/dist/analytics.d.ts +65 -1
- package/dist/analytics.js +4 -4
- package/dist/artifact-integrity.json +105 -101
- package/dist/assets-BIMVwjQe.js +231 -0
- package/dist/assets-Dfs2ElxI.cjs +1 -0
- package/dist/auto-BIOmtVhk.js +240 -0
- package/dist/auto-DDHflI9v.cjs +1 -0
- package/dist/{batch-BfZHN1do.js → batch-WzDIXJAt.js} +1 -1
- package/dist/{batch-CLpELXBl.cjs → batch-z6Aw5GEY.cjs} +1 -1
- package/dist/codes.d.cts +2 -0
- package/dist/codes.d.ts +2 -0
- package/dist/component-tree-Ca6YYfHq.js +61 -0
- package/dist/component-tree-DkGLEfZC.cjs +1 -0
- package/dist/computed-BW5a8QFk.js +612 -0
- package/dist/computed-C2GD3XcE.cjs +1 -0
- package/dist/config-Dg_o8e7m.cjs +1 -0
- package/dist/{config-BVsJXSqS.js → config-XQ4qrQ7Q.js} +66 -64
- package/dist/dataset-DL83majE.js +161 -0
- package/dist/dataset-IrlXbUvh.cjs +1 -0
- package/dist/designer-D9XAxqSc.js +5178 -0
- package/dist/designer-uCDo5XSK.cjs +2 -0
- package/dist/designer.cjs +1 -1
- package/dist/designer.d.cts +178 -3
- package/dist/designer.d.ts +178 -3
- package/dist/designer.js +1 -1
- package/dist/drill-ByN8COs_.cjs +1 -0
- package/dist/{drill-ByJviLXS.js → drill-CKW3Xtfa.js} +5 -5
- package/dist/encoding-BFMFIc4r.cjs +1 -0
- package/dist/encoding-DP_Eaf0A.js +21 -0
- package/dist/{font-loader-B_UkxpzC.cjs → font-loader-7FWVlykp.cjs} +1 -1
- package/dist/{font-loader-Q3bQjmrI.js → font-loader-CQZowp0I.js} +1 -1
- package/dist/index.cjs +8 -9
- package/dist/index.d.cts +175 -1
- package/dist/index.d.ts +175 -1
- package/dist/index.js +1343 -915
- package/dist/json-snapshot-D7PE1NsU.cjs +2 -0
- package/dist/json-snapshot-DYmEe3sO.js +1779 -0
- package/dist/matrix-JLAXlux-.js +302 -0
- package/dist/matrix-gTHpDTGm.cjs +1 -0
- package/dist/{pdf-CvvrjPQg.cjs → pdf-B8JouyYv.cjs} +48 -50
- package/dist/{pdf-BwNyeGpt.js → pdf-l3ea86di.js} +2734 -2748
- package/dist/pdf.cjs +1 -1
- package/dist/pdf.d.cts +14 -0
- package/dist/pdf.d.ts +14 -0
- package/dist/pdf.js +2 -2
- package/dist/{plugin-Ca_XZG3l.js → plugin-BBp74CQZ.js} +1 -1
- package/dist/{plugin-DHO7X8z2.cjs → plugin-CtFX9PFG.cjs} +1 -1
- package/dist/prepared-CARicKYh.js +87 -0
- package/dist/prepared-Ch1x_Gog.cjs +1 -0
- package/dist/progress-BXzlVbIp.js +29 -0
- package/dist/progress-DJBd9Rb9.cjs +1 -0
- package/dist/{progress-D-OTpEav.js → progress-Hc2vxoCs.js} +2 -2
- package/dist/protocol-B5A2uom4.cjs +1 -0
- package/dist/protocol-BaiWjq5w.js +90 -0
- package/dist/record-bindings-B86Sur_y.cjs +1 -0
- package/dist/{record-bindings-Do_b3h4V.js → record-bindings-D4TuMzHs.js} +10 -11
- package/dist/{region-binding-workflow-BMhK_TjP.js → region-binding-workflow-BNasF5kz.js} +2 -2
- package/dist/{region-binding-workflow-DIYJdCUr.cjs → region-binding-workflow-O2Cni3mF.cjs} +1 -1
- package/dist/report-encoding-worker.cjs +1 -0
- package/dist/report-encoding-worker.d.ts +1 -0
- package/dist/report-encoding-worker.js +2 -0
- package/dist/rich-text-layout-ALlMoYOG.cjs +3 -0
- package/dist/rich-text-layout-Ct5WrY1g.js +102 -0
- package/dist/runtime-DakRXui3.js +170 -0
- package/dist/runtime-dL5ygIfa.cjs +1 -0
- package/dist/sbom.cdx.json +2 -2
- package/dist/server/node.d.cts +132 -1
- package/dist/server/node.d.ts +132 -1
- package/dist/server-node.cjs +5 -1
- package/dist/server-node.js +5177 -463
- package/dist/server.cjs +1 -1
- package/dist/server.d.cts +182 -2
- package/dist/server.d.ts +182 -2
- package/dist/server.js +918 -833
- package/dist/sha256-BshdOkCC.cjs +1 -0
- package/dist/sha256-DTG-Gq8i.js +157 -0
- package/dist/style-67OqfNed.js +73 -0
- package/dist/style-C22Pbv3T.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/template-catalog-Dua8h9ZA.cjs +1 -0
- package/dist/{template-catalog-j2B1MJlL.js → template-catalog-wT1fNeAP.js} +10 -10
- package/dist/{template-fragments-DcKeiylI.cjs → template-fragments-BajTajb4.cjs} +1 -1
- package/dist/{template-fragments-BGbQLGlV.js → template-fragments-DmX5XK4N.js} +2 -2
- package/dist/template-registry-CpysHAxy.cjs +1 -0
- package/dist/{template-registry-BtaKPELV.js → template-registry-u11fPd8D.js} +389 -321
- package/dist/{textwrap-DE1kgcJB.js → textwrap-BEIg2w8y.js} +1 -1
- package/dist/textwrap-BI-yJ6Wt.cjs +4 -0
- package/dist/{tree-BX380Rr7.cjs → tree-CLpxYbKa.cjs} +1 -1
- package/dist/{tree-CjVZLRw7.js → tree-DNJorJUf.js} +1 -1
- package/dist/vue/async.d.cts +174 -2
- package/dist/vue/async.d.ts +174 -2
- package/dist/vue/index.d.cts +218 -3
- package/dist/vue/index.d.ts +218 -3
- package/dist/vue-async.cjs +1 -1
- package/dist/vue-async.js +3 -3
- package/dist/vue.cjs +1 -1
- package/dist/vue.js +7 -7
- package/dist/{workbook-session-BvToI-Fd.js → workbook-session-B8pNW24X.js} +153 -140
- package/dist/{workbook-session-Bjv1YCRK.cjs → workbook-session-DN5LSA5C.cjs} +12 -12
- package/dist/worker.cjs +1 -1
- package/dist/worker.d.cts +84 -1
- package/dist/worker.d.ts +84 -1
- package/dist/worker.js +12 -157
- package/dist/xlsx-node.cjs +33 -33
- package/dist/xlsx-node.js +1282 -1289
- package/dist/xlsx.cjs +4 -3
- package/dist/xlsx.d.cts +90 -2
- package/dist/xlsx.d.ts +90 -2
- package/dist/xlsx.js +279 -259
- package/package.json +6 -3
- package/dist/ReportPreview-ChV19HBp.js +0 -4619
- package/dist/ReportPreview-DbLvvOUT.cjs +0 -6
- package/dist/RuleEditor-C_Clasvd.js +0 -2037
- package/dist/RuleEditor-XhGHK8DE.cjs +0 -1
- package/dist/assets-B9ImAi6_.cjs +0 -1
- package/dist/assets-DEaz4qsp.js +0 -124
- package/dist/batch-BaP6pWDE.cjs +0 -1
- package/dist/batch-CGyt-b2W.js +0 -273
- package/dist/capabilities-CAh2Nrue.cjs +0 -1
- package/dist/capabilities-DskCHs3V.js +0 -69
- package/dist/computed-C-4C2S5h.js +0 -521
- package/dist/computed-CGV2a809.cjs +0 -1
- package/dist/config-D10us76d.cjs +0 -1
- package/dist/data-explanation-B8MZRYVS.js +0 -16
- package/dist/data-explanation-DE55G30w.cjs +0 -1
- package/dist/dataset-BkRmwgeJ.cjs +0 -1
- package/dist/dataset-H5pFuQGU.js +0 -121
- package/dist/defaults-DXhiM1ZD.js +0 -10
- package/dist/defaults-xhmcLLrf.cjs +0 -1
- package/dist/designer-2bDlcNXQ.js +0 -5136
- package/dist/designer-BT7XCdbW.cjs +0 -2
- package/dist/drill-DYTxuL3A.cjs +0 -1
- package/dist/grid-strokes-Cr7DwUux.cjs +0 -1
- package/dist/grid-strokes-DyyG1q_o.js +0 -53
- package/dist/json-snapshot-DFb2eWkf.js +0 -1416
- package/dist/json-snapshot-WWSGlaHG.cjs +0 -2
- package/dist/matrix-CGRGkn5s.js +0 -112
- package/dist/matrix-gEO7ZM_u.cjs +0 -1
- package/dist/prepared-CFy9B75C.cjs +0 -1
- package/dist/prepared-ajM-H-9B.js +0 -69
- package/dist/record-bindings-By_UKZ2g.cjs +0 -1
- package/dist/render-plan-7xpGrCEl.cjs +0 -1
- package/dist/render-plan-Ck6koX9L.js +0 -13
- package/dist/sha256-ArEYjaTI.cjs +0 -1
- package/dist/sha256-DPEuJ3nh.js +0 -155
- package/dist/style-CQ1PK8ZB.js +0 -67
- package/dist/style-UgIJSA1F.cjs +0 -1
- package/dist/template-catalog-FJE_c9Qe.cjs +0 -1
- package/dist/template-registry-Co1zPq5e.cjs +0 -1
- package/dist/textwrap-CWHyzkBH.cjs +0 -4
package/dist/server.d.ts
CHANGED
|
@@ -35,6 +35,8 @@ declare interface AssetRenderBudget {
|
|
|
35
35
|
|
|
36
36
|
declare interface AssetRenderOptions extends OutputDiagnosticOptions, ImageMediaOptions {
|
|
37
37
|
assetRenderers?: Partial<Record<ImageComponentKind, ComponentImageRenderer>>;
|
|
38
|
+
/** Explicit id/version registry; unbound components continue using assetRenderers by kind. */
|
|
39
|
+
assetRegistry?: ComponentAssetRegistry;
|
|
38
40
|
assetBudget?: AssetRenderBudget;
|
|
39
41
|
/** Default throw prevents an incomplete export; placeholder retains the component and emits diagnostics. */
|
|
40
42
|
assetFailure?: "throw" | "placeholder";
|
|
@@ -117,6 +119,11 @@ declare type ColumnFormat_2 = {
|
|
|
117
119
|
pattern?: string;
|
|
118
120
|
};
|
|
119
121
|
|
|
122
|
+
declare interface ComponentAssetRegistry {
|
|
123
|
+
rendererFor(component: Readonly<PlanComponent>): ComponentImageRenderer | undefined;
|
|
124
|
+
hasExtension(id: string, version: string, kind: string): boolean;
|
|
125
|
+
}
|
|
126
|
+
|
|
120
127
|
/** A literal own field of the current label record; expressions and paths are not evaluated. */
|
|
121
128
|
declare interface ComponentBinding {
|
|
122
129
|
field: string;
|
|
@@ -219,6 +226,9 @@ declare interface ComputedField_2 extends ExpressionOptions_2 {
|
|
|
219
226
|
|
|
220
227
|
export declare function createManagerTemplateCatalog(manager: ReportTemplateManager, metadata?: (document: ReportTemplateDocument) => Pick<LocalTemplateCatalogItem, "category" | "tags">): ReportTemplateCatalogProvider;
|
|
221
228
|
|
|
229
|
+
/** Bounded, single-process reference store. Scope is host-authorized identity, never a client permission. */
|
|
230
|
+
export declare function createMemoryReportDocumentStore(options?: ReportDocumentBudget): ReportDocumentStore;
|
|
231
|
+
|
|
222
232
|
/** Session-local intents; durable hosts should supply their own authorized stable IDs. */
|
|
223
233
|
export declare function createMemoryReportInstanceIds(maximum?: number): {
|
|
224
234
|
forCase(templateId: string, caseId: string): string;
|
|
@@ -270,6 +280,13 @@ export declare function createReportInstanceManager(store: ReportInstanceStore,
|
|
|
270
280
|
/** Durable at-least-once dispatch; export/artifact handlers must be idempotent by scope+taskId. */
|
|
271
281
|
export declare function createReportJobService(options: ReportJobServiceOptions): ReportJobService;
|
|
272
282
|
|
|
283
|
+
/** OpenAPI 3.1 for the minimal Java/Node wire contract. Host registers routes and authorizes IDs before describe(). */
|
|
284
|
+
export declare function createReportOpenApi(descriptions: readonly ReportDescription[], options?: {
|
|
285
|
+
title?: string;
|
|
286
|
+
version?: string;
|
|
287
|
+
basePath?: string;
|
|
288
|
+
}): Record<string, unknown>;
|
|
289
|
+
|
|
273
290
|
/** 无 Vue、无 HTTP 框架的可选服务端外观;PDF/Excel 仅在对应 export 调用时加载。 */
|
|
274
291
|
export declare function createReportRuntime(options: ReportRuntimeOptions): ReportRuntime;
|
|
275
292
|
|
|
@@ -342,6 +359,8 @@ declare interface FormulaAdapter {
|
|
|
342
359
|
}
|
|
343
360
|
|
|
344
361
|
declare interface GridCell {
|
|
362
|
+
/** Styled cell content; text remains a plain-text fallback. Imported rich cells are read-only. */
|
|
363
|
+
richParagraphs?: RichParagraph[];
|
|
345
364
|
text?: string;
|
|
346
365
|
rawText?: string;
|
|
347
366
|
/** 原始值,仅供 Excel raw 模式消费;不参与预览、分页与 PDF 绘制。 */
|
|
@@ -366,6 +385,8 @@ declare interface GridCell {
|
|
|
366
385
|
}
|
|
367
386
|
|
|
368
387
|
declare interface GridCell_2 {
|
|
388
|
+
/** Styled cell content; text remains a plain-text fallback. Imported rich cells are read-only. */
|
|
389
|
+
richParagraphs?: RichParagraph_2[];
|
|
369
390
|
text?: string;
|
|
370
391
|
rawText?: string;
|
|
371
392
|
/** 原始值,仅供 Excel raw 模式消费;不参与预览、分页与 PDF 绘制。 */
|
|
@@ -705,6 +726,46 @@ declare interface LocalTemplateCatalogItem {
|
|
|
705
726
|
tags?: string[];
|
|
706
727
|
}
|
|
707
728
|
|
|
729
|
+
declare interface MatrixAxisOptions {
|
|
730
|
+
/** Display names in the same outer-to-inner order as the dimension fields. */
|
|
731
|
+
labels?: readonly string[];
|
|
732
|
+
/** Per-level sibling order; omitted levels retain first-seen order. */
|
|
733
|
+
sort?: readonly MatrixDimensionOrder[];
|
|
734
|
+
/** One-based prefix depths. Leaf depths are not subtotals. */
|
|
735
|
+
subtotals?: readonly number[];
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
declare interface MatrixAxisOptions_2 {
|
|
739
|
+
/** Display names in the same outer-to-inner order as the dimension fields. */
|
|
740
|
+
labels?: readonly string[];
|
|
741
|
+
/** Per-level sibling order; omitted levels retain first-seen order. */
|
|
742
|
+
sort?: readonly MatrixDimensionOrder_2[];
|
|
743
|
+
/** One-based prefix depths. Leaf depths are not subtotals. */
|
|
744
|
+
subtotals?: readonly number[];
|
|
745
|
+
}
|
|
746
|
+
|
|
747
|
+
declare type MatrixDimensionOrder = "source" | "asc" | "desc";
|
|
748
|
+
|
|
749
|
+
declare type MatrixDimensionOrder_2 = "source" | "asc" | "desc";
|
|
750
|
+
|
|
751
|
+
declare interface MatrixHierarchyOptions {
|
|
752
|
+
row?: MatrixAxisOptions;
|
|
753
|
+
column?: MatrixAxisOptions;
|
|
754
|
+
/** Only null/missing values use this label; empty strings and zero stay distinct. */
|
|
755
|
+
emptyLabel?: string;
|
|
756
|
+
subtotalLabel?: string;
|
|
757
|
+
totalLabel?: string;
|
|
758
|
+
}
|
|
759
|
+
|
|
760
|
+
declare interface MatrixHierarchyOptions_2 {
|
|
761
|
+
row?: MatrixAxisOptions_2;
|
|
762
|
+
column?: MatrixAxisOptions_2;
|
|
763
|
+
/** Only null/missing values use this label; empty strings and zero stay distinct. */
|
|
764
|
+
emptyLabel?: string;
|
|
765
|
+
subtotalLabel?: string;
|
|
766
|
+
totalLabel?: string;
|
|
767
|
+
}
|
|
768
|
+
|
|
708
769
|
declare interface MatrixTableOptions {
|
|
709
770
|
rowFields: readonly string[];
|
|
710
771
|
columnFields: readonly string[];
|
|
@@ -719,6 +780,10 @@ declare interface MatrixTableOptions {
|
|
|
719
780
|
maxColumns?: number;
|
|
720
781
|
maxInputRows?: number;
|
|
721
782
|
maxCells?: number;
|
|
783
|
+
/** Opt-in hierarchical dimensions, physical merged headers and prefix subtotals. */
|
|
784
|
+
hierarchy?: MatrixHierarchyOptions;
|
|
785
|
+
/** Hierarchical aggregate work, checked before measure reads; default 10 million updates. */
|
|
786
|
+
maxAggregateUpdates?: number;
|
|
722
787
|
}
|
|
723
788
|
|
|
724
789
|
declare interface MatrixTableOptions_2 {
|
|
@@ -735,6 +800,10 @@ declare interface MatrixTableOptions_2 {
|
|
|
735
800
|
maxColumns?: number;
|
|
736
801
|
maxInputRows?: number;
|
|
737
802
|
maxCells?: number;
|
|
803
|
+
/** Opt-in hierarchical dimensions, physical merged headers and prefix subtotals. */
|
|
804
|
+
hierarchy?: MatrixHierarchyOptions_2;
|
|
805
|
+
/** Hierarchical aggregate work, checked before measure reads; default 10 million updates. */
|
|
806
|
+
maxAggregateUpdates?: number;
|
|
738
807
|
}
|
|
739
808
|
|
|
740
809
|
export declare interface MemoryReportInstanceStoreOptions {
|
|
@@ -754,6 +823,11 @@ declare interface OutputDiagnostic {
|
|
|
754
823
|
componentPath?: readonly number[];
|
|
755
824
|
kind: string;
|
|
756
825
|
nid?: string;
|
|
826
|
+
/** Declarative extension identity only; no property values or business binding data enter diagnostics. */
|
|
827
|
+
extension?: {
|
|
828
|
+
id: string;
|
|
829
|
+
version: string;
|
|
830
|
+
};
|
|
757
831
|
message: string;
|
|
758
832
|
}
|
|
759
833
|
|
|
@@ -936,6 +1010,21 @@ export declare interface PreparedReport {
|
|
|
936
1010
|
|
|
937
1011
|
declare type PublicationAssets = Omit<AssetRenderOptions, "signal">;
|
|
938
1012
|
|
|
1013
|
+
/** Progressive consumption ends at the currently committed boundary; caller may resume with nextPage. */
|
|
1014
|
+
export declare function readReportDocumentPages(store: ReportDocumentStore, input: {
|
|
1015
|
+
scope: string;
|
|
1016
|
+
id: string;
|
|
1017
|
+
version: string;
|
|
1018
|
+
fromPage?: number;
|
|
1019
|
+
limit?: number;
|
|
1020
|
+
maxBytes?: number;
|
|
1021
|
+
signal?: AbortSignal;
|
|
1022
|
+
}): Promise<{
|
|
1023
|
+
manifest: ReportDocumentManifest;
|
|
1024
|
+
pages: PlanPage[];
|
|
1025
|
+
nextPage: number;
|
|
1026
|
+
}>;
|
|
1027
|
+
|
|
939
1028
|
declare interface RenderPlan {
|
|
940
1029
|
schemaVersion: string;
|
|
941
1030
|
/** 编辑需要模板重算上下文;跨 Worker/JSON 保留要求,但不声明本地会话可用。 */
|
|
@@ -943,6 +1032,8 @@ declare interface RenderPlan {
|
|
|
943
1032
|
pages: PlanPage[];
|
|
944
1033
|
}
|
|
945
1034
|
|
|
1035
|
+
export declare const REPORT_HTTP_CONTRACT_VERSION = "1.0";
|
|
1036
|
+
|
|
946
1037
|
export declare interface ReportBatchCase {
|
|
947
1038
|
id: string;
|
|
948
1039
|
params: Record<string, string>;
|
|
@@ -1081,6 +1172,46 @@ declare interface ReportDiagnostic {
|
|
|
1081
1172
|
target?: ReportDataTarget;
|
|
1082
1173
|
}
|
|
1083
1174
|
|
|
1175
|
+
export declare interface ReportDocumentBudget {
|
|
1176
|
+
maxDocuments?: number;
|
|
1177
|
+
maxBytes?: number;
|
|
1178
|
+
maxPages?: number;
|
|
1179
|
+
maxPageBytes?: number;
|
|
1180
|
+
maxManifestBytes?: number;
|
|
1181
|
+
}
|
|
1182
|
+
|
|
1183
|
+
export declare class ReportDocumentError extends Error {
|
|
1184
|
+
readonly code: "input" | "capacity" | "conflict" | "missing" | "closed";
|
|
1185
|
+
constructor(code: "input" | "capacity" | "conflict" | "missing" | "closed", message: string);
|
|
1186
|
+
}
|
|
1187
|
+
|
|
1188
|
+
export declare interface ReportDocumentManifest {
|
|
1189
|
+
scope: string;
|
|
1190
|
+
id: string;
|
|
1191
|
+
version: string;
|
|
1192
|
+
/** CAS token increases after each append and completion. */
|
|
1193
|
+
revision: number;
|
|
1194
|
+
state: "building" | "complete" | "failed";
|
|
1195
|
+
failure?: {
|
|
1196
|
+
code: "cancelled" | "generation";
|
|
1197
|
+
message: string;
|
|
1198
|
+
};
|
|
1199
|
+
pageCount: number;
|
|
1200
|
+
bytes: number;
|
|
1201
|
+
plan: Omit<RenderPlan, "pages">;
|
|
1202
|
+
metadata?: Omit<PreparedReport, "plan">;
|
|
1203
|
+
}
|
|
1204
|
+
|
|
1205
|
+
export declare interface ReportDocumentStore {
|
|
1206
|
+
create(input: Pick<ReportDocumentManifest, "scope" | "id" | "version" | "plan">, signal?: AbortSignal): Promise<ReportDocumentManifest>;
|
|
1207
|
+
append(scope: string, id: string, version: string, expectedRevision: number, page: PlanPage, signal?: AbortSignal): Promise<ReportDocumentManifest>;
|
|
1208
|
+
complete(scope: string, id: string, version: string, expectedRevision: number, metadata?: Omit<PreparedReport, "plan">, signal?: AbortSignal): Promise<ReportDocumentManifest>;
|
|
1209
|
+
fail(scope: string, id: string, version: string, expectedRevision: number, failure: NonNullable<ReportDocumentManifest["failure"]>): Promise<ReportDocumentManifest>;
|
|
1210
|
+
read(scope: string, id: string, signal?: AbortSignal): Promise<ReportDocumentManifest | undefined>;
|
|
1211
|
+
readPage(scope: string, id: string, version: string, index: number, signal?: AbortSignal): Promise<PlanPage | undefined>;
|
|
1212
|
+
remove(scope: string, id: string, version: string, signal?: AbortSignal): Promise<boolean>;
|
|
1213
|
+
}
|
|
1214
|
+
|
|
1084
1215
|
declare type ReportExpression = {
|
|
1085
1216
|
field: string;
|
|
1086
1217
|
} | {
|
|
@@ -1107,7 +1238,15 @@ declare type ReportExpression_2 = {
|
|
|
1107
1238
|
args: readonly ReportExpression_2[];
|
|
1108
1239
|
};
|
|
1109
1240
|
|
|
1110
|
-
declare
|
|
1241
|
+
declare type ReportFieldAggregation = "sum" | "avg" | "min" | "max" | "count" | "none";
|
|
1242
|
+
|
|
1243
|
+
declare interface ReportFieldCalculation {
|
|
1244
|
+
/** Business-owned explanation, never executable JavaScript or an inferred business formula. */
|
|
1245
|
+
description: string;
|
|
1246
|
+
dependsOn: readonly string[];
|
|
1247
|
+
}
|
|
1248
|
+
|
|
1249
|
+
declare interface ReportFieldContract extends ReportFieldSemantics {
|
|
1111
1250
|
field: string;
|
|
1112
1251
|
label?: string;
|
|
1113
1252
|
type: "text" | "number" | "boolean" | "date" | "decimal";
|
|
@@ -1122,6 +1261,17 @@ declare interface ReportFieldContract {
|
|
|
1122
1261
|
unit?: string;
|
|
1123
1262
|
}
|
|
1124
1263
|
|
|
1264
|
+
declare interface ReportFieldSemantics {
|
|
1265
|
+
description?: string;
|
|
1266
|
+
/** Explicit meaning of null/missing; does not convert blanks into zero. */
|
|
1267
|
+
missingMeaning?: string;
|
|
1268
|
+
/** Recommended aggregation; none marks non-additive measures such as ratios. No aggregation runs implicitly. */
|
|
1269
|
+
aggregation?: ReportFieldAggregation;
|
|
1270
|
+
/** Shared presentation only; raw values and calculation precision remain unchanged. */
|
|
1271
|
+
format?: ColumnFormat;
|
|
1272
|
+
calculation?: ReportFieldCalculation;
|
|
1273
|
+
}
|
|
1274
|
+
|
|
1125
1275
|
declare interface ReportFlowBand {
|
|
1126
1276
|
/** Exact stable component IDs. Static components use nid, lists use id. */
|
|
1127
1277
|
componentIds: string[];
|
|
@@ -1148,6 +1298,22 @@ export declare interface ReportGenerationInput {
|
|
|
1148
1298
|
signal?: AbortSignal;
|
|
1149
1299
|
}
|
|
1150
1300
|
|
|
1301
|
+
/** Stable transport mapping; unexpected errors never expose exception details or stacks. */
|
|
1302
|
+
export declare function reportHttpError(error: unknown, correlationId: string): {
|
|
1303
|
+
status: number;
|
|
1304
|
+
body: ReportHttpErrorBody;
|
|
1305
|
+
};
|
|
1306
|
+
|
|
1307
|
+
export declare interface ReportHttpErrorBody {
|
|
1308
|
+
error: {
|
|
1309
|
+
code: string;
|
|
1310
|
+
message: string;
|
|
1311
|
+
correlationId: string;
|
|
1312
|
+
path?: string;
|
|
1313
|
+
issues?: Record<string, string>[];
|
|
1314
|
+
};
|
|
1315
|
+
}
|
|
1316
|
+
|
|
1151
1317
|
export declare interface ReportInstanceArtifact {
|
|
1152
1318
|
key: string;
|
|
1153
1319
|
format: "pdf" | "xlsx";
|
|
@@ -1560,10 +1726,11 @@ export declare interface ReportRuntimeExportInput extends ReportRuntimeInput {
|
|
|
1560
1726
|
format: "pdf" | "xlsx";
|
|
1561
1727
|
/** strict 在编码前拒绝已识别的输出降级;默认保留诊断并继续。 */
|
|
1562
1728
|
fidelity?: "warn" | "strict";
|
|
1563
|
-
xlsx?: {
|
|
1729
|
+
xlsx?: ImageMediaOptions & {
|
|
1564
1730
|
sheetMode?: "auto" | "pages" | "continuous";
|
|
1565
1731
|
valueMode?: "text" | "raw";
|
|
1566
1732
|
paperSize?: "auto" | "a3" | "a4" | "a5";
|
|
1733
|
+
sheetName?: (sheetIndex: number) => string;
|
|
1567
1734
|
};
|
|
1568
1735
|
}
|
|
1569
1736
|
|
|
@@ -1594,6 +1761,8 @@ export declare interface ReportRuntimeOptions {
|
|
|
1594
1761
|
/** Encode an existing plan without querying providers or repaginating. */
|
|
1595
1762
|
export declare interface ReportRuntimePreparedExportInput extends ReportTaskMonitoring {
|
|
1596
1763
|
prepared: PreparedReport;
|
|
1764
|
+
/** verify checks font metric identity; preserve explicitly keeps existing geometry, with a diagnostic. Encoding fidelity is unchanged. */
|
|
1765
|
+
layoutPolicy?: "verify" | "preserve";
|
|
1597
1766
|
format: ReportRuntimeExportInput["format"];
|
|
1598
1767
|
fidelity?: ReportRuntimeExportInput["fidelity"];
|
|
1599
1768
|
pdf?: ReportPdfFontOptions;
|
|
@@ -2179,4 +2348,15 @@ declare type ValueFormat = ColumnFormat;
|
|
|
2179
2348
|
/** The same declarative formatting used by list columns, before any output backend. */
|
|
2180
2349
|
declare type ValueFormat_2 = ColumnFormat_2;
|
|
2181
2350
|
|
|
2351
|
+
/** Accepts paginateTemplatePages/AsyncIterable without retaining all pages; partial documents stay inspectable on failure. */
|
|
2352
|
+
export declare function writeReportDocument(store: ReportDocumentStore, input: {
|
|
2353
|
+
scope: string;
|
|
2354
|
+
id: string;
|
|
2355
|
+
version: string;
|
|
2356
|
+
plan: Omit<RenderPlan, "pages">;
|
|
2357
|
+
pages: Iterable<PlanPage> | AsyncIterable<PlanPage>;
|
|
2358
|
+
metadata?: Omit<PreparedReport, "plan">;
|
|
2359
|
+
signal?: AbortSignal;
|
|
2360
|
+
}): Promise<ReportDocumentManifest>;
|
|
2361
|
+
|
|
2182
2362
|
export { }
|