@agile-team/mach-report 2.10.0 → 2.11.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 +6 -2
- package/dist/ExcelBindingWizard-LWX6G1A2.js +1465 -0
- package/dist/ExcelBindingWizard-a4kslPHF.cjs +1 -0
- package/dist/ParamEditor-BLaE5q5W.js +522 -0
- package/dist/ParamEditor-MBBC7lUE.cjs +1 -0
- package/dist/ReportBatchPanel-B5ClP9tm.js +350 -0
- package/dist/ReportBatchPanel-Dc-SDkYA.cjs +1 -0
- package/dist/ReportPreview-DWXROHBP.cjs +6 -0
- package/dist/ReportPreview-DiNXhQI0.js +4138 -0
- package/dist/ReportTemplateLibrary-5fk5CQBO.cjs +1 -0
- package/dist/ReportTemplateLibrary-BZB-XWjj.js +311 -0
- package/dist/RuleEditor-C2QsOHOs.cjs +1 -0
- package/dist/RuleEditor-D9wQHrkf.js +2024 -0
- package/dist/TemplateReviewPanel-BKofGrV9.js +222 -0
- package/dist/TemplateReviewPanel-DwtOcLue.cjs +1 -0
- package/dist/analytics.cjs +1 -1
- package/dist/analytics.d.cts +2 -0
- package/dist/analytics.d.ts +2 -0
- package/dist/analytics.js +29 -29
- package/dist/batch-Bt3Fd27Z.cjs +1 -0
- package/dist/batch-mRqhhhjt.js +364 -0
- package/dist/computed-Bvk0W15F.js +521 -0
- package/dist/computed-CGV2a809.cjs +1 -0
- package/dist/config-B612mw0x.js +525 -0
- package/dist/config-BRoLo2oj.cjs +1 -0
- package/dist/designer.cjs +2 -2
- package/dist/designer.d.cts +730 -9
- package/dist/designer.d.ts +730 -9
- package/dist/designer.js +2093 -1785
- package/dist/index.cjs +8 -8
- package/dist/index.d.cts +161 -3
- package/dist/index.d.ts +161 -3
- package/dist/index.js +486 -431
- package/dist/injection-keys-Db_DyLkm.cjs +1 -0
- package/dist/injection-keys-e85udZCp.js +7 -0
- package/dist/list-cell-BuYn4tGF.cjs +1 -0
- package/dist/{list-cell-Dxyi7DOw.js → list-cell-ClFra1zS.js} +54 -40
- package/dist/matrix-DVyWiYsd.cjs +1 -0
- package/dist/matrix-yZsGnldA.js +227 -0
- package/dist/param-validation-BlHHXs6u.js +153 -0
- package/dist/param-validation-DCK039V1.cjs +1 -0
- package/dist/pdf.cjs +25 -25
- package/dist/pdf.d.cts +3 -0
- package/dist/pdf.d.ts +3 -0
- package/dist/pdf.js +677 -677
- package/dist/plugin-BDTU4D94.cjs +1 -0
- package/dist/plugin-Cd5G2QQn.js +22 -0
- package/dist/region-binding-workflow-CXDmt9Bs.js +977 -0
- package/dist/region-binding-workflow-DhQvu1co.cjs +3 -0
- package/dist/{report-params-B_VCihAh.js → report-params-B44imUd4.js} +1 -1
- package/dist/{report-params-CjWrjPl6.cjs → report-params-SJfhKgaX.cjs} +1 -1
- package/dist/server/node.d.cts +5 -2
- package/dist/server/node.d.ts +5 -2
- package/dist/server-node.cjs +1 -1
- package/dist/server-node.js +87 -87
- package/dist/server.cjs +1 -1
- package/dist/server.d.cts +201 -2
- package/dist/server.d.ts +201 -2
- package/dist/server.js +557 -658
- package/dist/style.css +1 -1
- package/dist/template-registry-WNXdkiET.js +506 -0
- package/dist/template-registry-ukBGlm8N.cjs +1 -0
- package/dist/template-review-BXp2oyqg.cjs +1 -0
- package/dist/template-review-BdcXSYbx.js +1616 -0
- package/dist/tree-BX380Rr7.cjs +1 -0
- package/dist/tree-CqcQ99NM.js +172 -0
- package/dist/{validate-UUy9yP4K.js → validate-7s0yn6ii.js} +44 -44
- package/dist/validate-DsRiNw8h.cjs +1 -0
- package/dist/vue/async.d.cts +93 -4
- package/dist/vue/async.d.ts +93 -4
- package/dist/vue/index.d.cts +145 -7
- package/dist/vue/index.d.ts +145 -7
- package/dist/vue-async.cjs +1 -1
- package/dist/vue-async.js +5 -5
- package/dist/vue.cjs +1 -1
- package/dist/vue.js +116 -113
- package/dist/{workbook-session-B-bW5_yR.js → workbook-session-BKOTwcoq.js} +1 -1
- package/dist/{workbook-session-D7RtdNo0.cjs → workbook-session-CLYLhZWu.cjs} +1 -1
- package/dist/worker.cjs +1 -1
- package/dist/worker.d.cts +5 -2
- package/dist/worker.d.ts +5 -2
- package/dist/worker.js +1 -1
- package/dist/xlsx.cjs +3 -3
- package/dist/xlsx.d.cts +129 -2
- package/dist/xlsx.d.ts +129 -2
- package/dist/xlsx.js +336 -242
- package/package.json +1 -1
- package/dist/ExcelBindingWizard-CF7RplWm.cjs +0 -1
- package/dist/ExcelBindingWizard-qhwEderR.js +0 -842
- package/dist/ReportPreview-BE1tCHqE.js +0 -4604
- package/dist/ReportPreview-QKRKQOe3.cjs +0 -6
- package/dist/RuleEditor-BA36yIV6.js +0 -1723
- package/dist/RuleEditor-CczJ6mJm.cjs +0 -1
- package/dist/TemplateReviewPanel-CHi4Alqa.cjs +0 -1
- package/dist/TemplateReviewPanel-Dz0G5o83.js +0 -217
- package/dist/binding-preview-BWsdf_z2.cjs +0 -2
- package/dist/binding-preview-DILq0-0f.js +0 -649
- package/dist/decimal-CI1OAczk.js +0 -87
- package/dist/decimal-CQA0xJex.cjs +0 -1
- package/dist/list-cell-CyM1ZlRN.cjs +0 -1
- package/dist/matrix-BbXarwyk.js +0 -661
- package/dist/matrix-Cm65WLLP.cjs +0 -1
- package/dist/param-validation-BWNjLcN0.js +0 -116
- package/dist/param-validation-CiTxFeZ8.cjs +0 -1
- package/dist/plugin-CThk42vJ.cjs +0 -1
- package/dist/plugin-tGn7-5oF.js +0 -25
- package/dist/template-registry-CGWTLtIA.cjs +0 -1
- package/dist/template-registry-DzlQs3OF.js +0 -434
- package/dist/template-review-D1RoNCPw.cjs +0 -1
- package/dist/template-review-fnteXRng.js +0 -1473
- package/dist/validate-Bf6ccFr2.cjs +0 -1
package/dist/vue/index.d.ts
CHANGED
|
@@ -387,6 +387,10 @@ declare type __VLS_Props_3 = {
|
|
|
387
387
|
/** 触发过查询后才开始必填提示(避免首屏一片红) */
|
|
388
388
|
attempted: boolean;
|
|
389
389
|
issues?: readonly ReportParamIssue[];
|
|
390
|
+
/** Embedded batch forms reuse the same typed inputs without per-row query buttons. */
|
|
391
|
+
showActions?: boolean;
|
|
392
|
+
showTitle?: boolean;
|
|
393
|
+
disabled?: boolean;
|
|
390
394
|
};
|
|
391
395
|
declare function __VLS_template(): {
|
|
392
396
|
slots: {
|
|
@@ -821,6 +825,8 @@ declare interface GridCell {
|
|
|
821
825
|
value?: string | number | boolean | null;
|
|
822
826
|
/** Excel 数字格式(例如 #,##0.00 / 0.00%),不改变 text。 */
|
|
823
827
|
numberFormat?: string;
|
|
828
|
+
/** Physical left inset for hierarchical labels; raw value stays unchanged. */
|
|
829
|
+
indentMm?: number;
|
|
824
830
|
/** 编辑输入类型;省略时只按原始值推断,数字字符串不会被转换为数值。 */
|
|
825
831
|
valueType?: "text" | "number" | "boolean";
|
|
826
832
|
/** 单元格级编辑控制;预览仍需显式开启 editing。 */
|
|
@@ -842,6 +848,8 @@ declare interface GridCell_2 {
|
|
|
842
848
|
value?: string | number | boolean | null;
|
|
843
849
|
/** Excel 数字格式(例如 #,##0.00 / 0.00%),不改变 text。 */
|
|
844
850
|
numberFormat?: string;
|
|
851
|
+
/** Physical left inset for hierarchical labels; raw value stays unchanged. */
|
|
852
|
+
indentMm?: number;
|
|
845
853
|
/** 编辑输入类型;省略时只按原始值推断,数字字符串不会被转换为数值。 */
|
|
846
854
|
valueType?: "text" | "number" | "boolean";
|
|
847
855
|
/** 单元格级编辑控制;预览仍需显式开启 editing。 */
|
|
@@ -863,6 +871,8 @@ declare interface GridCell_3 {
|
|
|
863
871
|
value?: string | number | boolean | null;
|
|
864
872
|
/** Excel 数字格式(例如 #,##0.00 / 0.00%),不改变 text。 */
|
|
865
873
|
numberFormat?: string;
|
|
874
|
+
/** Physical left inset for hierarchical labels; raw value stays unchanged. */
|
|
875
|
+
indentMm?: number;
|
|
866
876
|
/** 编辑输入类型;省略时只按原始值推断,数字字符串不会被转换为数值。 */
|
|
867
877
|
valueType?: "text" | "number" | "boolean";
|
|
868
878
|
/** 单元格级编辑控制;预览仍需显式开启 editing。 */
|
|
@@ -970,6 +980,8 @@ declare interface ListColumn_3 {
|
|
|
970
980
|
}
|
|
971
981
|
declare interface ListComponent {
|
|
972
982
|
kind: "list";
|
|
983
|
+
/** Opaque serializable layout annotations; interpreted only by explicit optional adapters. */
|
|
984
|
+
meta?: Record<string, unknown>;
|
|
973
985
|
id?: string;
|
|
974
986
|
/** 宽表标记用于连续 Excel;不改变低层列表的列宽和分页算法。 */
|
|
975
987
|
layout?: "page" | "wide";
|
|
@@ -979,6 +991,10 @@ declare interface ListComponent {
|
|
|
979
991
|
topMm: number;
|
|
980
992
|
widthMm: number;
|
|
981
993
|
dataset: string;
|
|
994
|
+
/** Headerless record/region bindings do not allocate a synthetic list header. */
|
|
995
|
+
header?: boolean;
|
|
996
|
+
/** A fixed record region rejects multiple rows instead of dropping source data. */
|
|
997
|
+
cardinality?: "record";
|
|
982
998
|
/** 数据集中稳定业务主键的字段名;省略时编辑仅有计划内坐标。 */
|
|
983
999
|
rowKey?: string;
|
|
984
1000
|
revisionField?: string;
|
|
@@ -1005,6 +1021,8 @@ declare interface ListComponent {
|
|
|
1005
1021
|
computed?: ComputedField[];
|
|
1006
1022
|
/** Dynamic pivot of the current source dataset, with read-only derived identities. */
|
|
1007
1023
|
matrix?: MatrixTableOptions;
|
|
1024
|
+
/** Full ordered hierarchy; source parent values and descendant-leaf rollups are explicit. */
|
|
1025
|
+
tree?: TreeTableOptions;
|
|
1008
1026
|
/** Explicit row visibility; hidden rows do not participate in summaries. */
|
|
1009
1027
|
rowVisibleWhen?: StyleRule["when"];
|
|
1010
1028
|
/** Master/detail relation is keyed by business identity, never by display row index. */
|
|
@@ -1014,6 +1032,8 @@ declare interface ListComponent {
|
|
|
1014
1032
|
}
|
|
1015
1033
|
declare interface ListComponent_2 {
|
|
1016
1034
|
kind: "list";
|
|
1035
|
+
/** Opaque serializable layout annotations; interpreted only by explicit optional adapters. */
|
|
1036
|
+
meta?: Record<string, unknown>;
|
|
1017
1037
|
id?: string;
|
|
1018
1038
|
/** 宽表标记用于连续 Excel;不改变低层列表的列宽和分页算法。 */
|
|
1019
1039
|
layout?: "page" | "wide";
|
|
@@ -1023,6 +1043,10 @@ declare interface ListComponent_2 {
|
|
|
1023
1043
|
topMm: number;
|
|
1024
1044
|
widthMm: number;
|
|
1025
1045
|
dataset: string;
|
|
1046
|
+
/** Headerless record/region bindings do not allocate a synthetic list header. */
|
|
1047
|
+
header?: boolean;
|
|
1048
|
+
/** A fixed record region rejects multiple rows instead of dropping source data. */
|
|
1049
|
+
cardinality?: "record";
|
|
1026
1050
|
/** 数据集中稳定业务主键的字段名;省略时编辑仅有计划内坐标。 */
|
|
1027
1051
|
rowKey?: string;
|
|
1028
1052
|
revisionField?: string;
|
|
@@ -1049,6 +1073,8 @@ declare interface ListComponent_2 {
|
|
|
1049
1073
|
computed?: ComputedField_2[];
|
|
1050
1074
|
/** Dynamic pivot of the current source dataset, with read-only derived identities. */
|
|
1051
1075
|
matrix?: MatrixTableOptions_2;
|
|
1076
|
+
/** Full ordered hierarchy; source parent values and descendant-leaf rollups are explicit. */
|
|
1077
|
+
tree?: TreeTableOptions_2;
|
|
1052
1078
|
/** Explicit row visibility; hidden rows do not participate in summaries. */
|
|
1053
1079
|
rowVisibleWhen?: StyleRule_2["when"];
|
|
1054
1080
|
/** Master/detail relation is keyed by business identity, never by display row index. */
|
|
@@ -1058,6 +1084,8 @@ declare interface ListComponent_2 {
|
|
|
1058
1084
|
}
|
|
1059
1085
|
declare interface ListComponent_3 {
|
|
1060
1086
|
kind: "list";
|
|
1087
|
+
/** Opaque serializable layout annotations; interpreted only by explicit optional adapters. */
|
|
1088
|
+
meta?: Record<string, unknown>;
|
|
1061
1089
|
id?: string;
|
|
1062
1090
|
/** 宽表标记用于连续 Excel;不改变低层列表的列宽和分页算法。 */
|
|
1063
1091
|
layout?: "page" | "wide";
|
|
@@ -1067,6 +1095,10 @@ declare interface ListComponent_3 {
|
|
|
1067
1095
|
topMm: number;
|
|
1068
1096
|
widthMm: number;
|
|
1069
1097
|
dataset: string;
|
|
1098
|
+
/** Headerless record/region bindings do not allocate a synthetic list header. */
|
|
1099
|
+
header?: boolean;
|
|
1100
|
+
/** A fixed record region rejects multiple rows instead of dropping source data. */
|
|
1101
|
+
cardinality?: "record";
|
|
1070
1102
|
/** 数据集中稳定业务主键的字段名;省略时编辑仅有计划内坐标。 */
|
|
1071
1103
|
rowKey?: string;
|
|
1072
1104
|
revisionField?: string;
|
|
@@ -1093,6 +1125,8 @@ declare interface ListComponent_3 {
|
|
|
1093
1125
|
computed?: ComputedField_3[];
|
|
1094
1126
|
/** Dynamic pivot of the current source dataset, with read-only derived identities. */
|
|
1095
1127
|
matrix?: MatrixTableOptions_3;
|
|
1128
|
+
/** Full ordered hierarchy; source parent values and descendant-leaf rollups are explicit. */
|
|
1129
|
+
tree?: TreeTableOptions_3;
|
|
1096
1130
|
/** Explicit row visibility; hidden rows do not participate in summaries. */
|
|
1097
1131
|
rowVisibleWhen?: StyleRule_3["when"];
|
|
1098
1132
|
/** Master/detail relation is keyed by business identity, never by display row index. */
|
|
@@ -1421,6 +1455,8 @@ export declare interface MachReportMessages extends Partial<ReportCalculationMes
|
|
|
1421
1455
|
paramPromptDescription?: string;
|
|
1422
1456
|
paramSelectPlaceholder?: string;
|
|
1423
1457
|
paramTextPlaceholder?: string;
|
|
1458
|
+
paramRangeStart?: string;
|
|
1459
|
+
paramRangeEnd?: string;
|
|
1424
1460
|
/** 可选搜索进度文案,旧完整 messages 对象无需新增字段。 */
|
|
1425
1461
|
searching?: string;
|
|
1426
1462
|
importExcel?: string;
|
|
@@ -1858,6 +1894,7 @@ export declare class PlanLoadError extends Error {
|
|
|
1858
1894
|
constructor(message: string);
|
|
1859
1895
|
}
|
|
1860
1896
|
declare interface PlanPage {
|
|
1897
|
+
meta?: Record<string, unknown>;
|
|
1861
1898
|
/** wide 表示完整自然列宽;页面仅为预览的垂直窗口分段。 */
|
|
1862
1899
|
layout?: "page" | "wide";
|
|
1863
1900
|
pageWidthMm: number;
|
|
@@ -2255,6 +2292,27 @@ export declare interface ReportFieldTarget {
|
|
|
2255
2292
|
rowKey?: string | number;
|
|
2256
2293
|
tableId?: string;
|
|
2257
2294
|
}
|
|
2295
|
+
declare interface ReportFlowBand {
|
|
2296
|
+
/** Exact stable component IDs. Static components use nid, lists use id. */
|
|
2297
|
+
componentIds: string[];
|
|
2298
|
+
/** Source-template coordinates; following bands keep their original gap. */
|
|
2299
|
+
topMm: number;
|
|
2300
|
+
heightMm: number;
|
|
2301
|
+
}
|
|
2302
|
+
declare interface ReportFlowBand_2 {
|
|
2303
|
+
/** Exact stable component IDs. Static components use nid, lists use id. */
|
|
2304
|
+
componentIds: string[];
|
|
2305
|
+
/** Source-template coordinates; following bands keep their original gap. */
|
|
2306
|
+
topMm: number;
|
|
2307
|
+
heightMm: number;
|
|
2308
|
+
}
|
|
2309
|
+
declare interface ReportFlowBand_3 {
|
|
2310
|
+
/** Exact stable component IDs. Static components use nid, lists use id. */
|
|
2311
|
+
componentIds: string[];
|
|
2312
|
+
/** Source-template coordinates; following bands keep their original gap. */
|
|
2313
|
+
topMm: number;
|
|
2314
|
+
heightMm: number;
|
|
2315
|
+
}
|
|
2258
2316
|
export declare type ReportIdInput = string | string[] | null | undefined;
|
|
2259
2317
|
export declare interface ReportInteractionOptions {
|
|
2260
2318
|
/** 只读选区计算,默认关闭;不写回业务值或执行导入的 Excel 公式。 */
|
|
@@ -2276,6 +2334,15 @@ export declare interface ReportOutputOptions {
|
|
|
2276
2334
|
/** warn preserves supported output and shows diagnostics; strict rejects known fidelity loss. */
|
|
2277
2335
|
fidelity?: "warn" | "strict";
|
|
2278
2336
|
}
|
|
2337
|
+
declare interface ReportPageFlow {
|
|
2338
|
+
bands: ReportFlowBand[];
|
|
2339
|
+
}
|
|
2340
|
+
declare interface ReportPageFlow_2 {
|
|
2341
|
+
bands: ReportFlowBand_2[];
|
|
2342
|
+
}
|
|
2343
|
+
declare interface ReportPageFlow_3 {
|
|
2344
|
+
bands: ReportFlowBand_3[];
|
|
2345
|
+
}
|
|
2279
2346
|
export declare const ReportPagination: DefineComponent<__VLS_Props_2, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
2280
2347
|
goto: (page: number) => any;
|
|
2281
2348
|
}, string, MachReportVuePublicProps, Readonly<__VLS_Props_2> & Readonly<{
|
|
@@ -2287,7 +2354,7 @@ declare interface ReportParamDef {
|
|
|
2287
2354
|
field: string;
|
|
2288
2355
|
/** 显示名(缺省用 field) */
|
|
2289
2356
|
label?: string;
|
|
2290
|
-
type?: "text" | "number" | "date" | "select";
|
|
2357
|
+
type?: "text" | "number" | "date" | "month" | "year" | "dateRange" | "select";
|
|
2291
2358
|
/** select 选项 */
|
|
2292
2359
|
options?: Array<{
|
|
2293
2360
|
label: string;
|
|
@@ -2296,7 +2363,7 @@ declare interface ReportParamDef {
|
|
|
2296
2363
|
defaultValue?: string;
|
|
2297
2364
|
required?: boolean;
|
|
2298
2365
|
placeholder?: string;
|
|
2299
|
-
/**
|
|
2366
|
+
/** 数字上下界;日期/月/年使用对应规范字符串;dateRange 对两端使用 YYYY-MM-DD 边界(含边界)。 */
|
|
2300
2367
|
min?: number | string;
|
|
2301
2368
|
max?: number | string;
|
|
2302
2369
|
minLength?: number;
|
|
@@ -2308,7 +2375,7 @@ declare interface ReportParamDef_2 {
|
|
|
2308
2375
|
field: string;
|
|
2309
2376
|
/** 显示名(缺省用 field) */
|
|
2310
2377
|
label?: string;
|
|
2311
|
-
type?: "text" | "number" | "date" | "select";
|
|
2378
|
+
type?: "text" | "number" | "date" | "month" | "year" | "dateRange" | "select";
|
|
2312
2379
|
/** select 选项 */
|
|
2313
2380
|
options?: Array<{
|
|
2314
2381
|
label: string;
|
|
@@ -2317,7 +2384,7 @@ declare interface ReportParamDef_2 {
|
|
|
2317
2384
|
defaultValue?: string;
|
|
2318
2385
|
required?: boolean;
|
|
2319
2386
|
placeholder?: string;
|
|
2320
|
-
/**
|
|
2387
|
+
/** 数字上下界;日期/月/年使用对应规范字符串;dateRange 对两端使用 YYYY-MM-DD 边界(含边界)。 */
|
|
2321
2388
|
min?: number | string;
|
|
2322
2389
|
max?: number | string;
|
|
2323
2390
|
minLength?: number;
|
|
@@ -2329,7 +2396,7 @@ declare interface ReportParamDef_3 {
|
|
|
2329
2396
|
field: string;
|
|
2330
2397
|
/** 显示名(缺省用 field) */
|
|
2331
2398
|
label?: string;
|
|
2332
|
-
type?: "text" | "number" | "date" | "select";
|
|
2399
|
+
type?: "text" | "number" | "date" | "month" | "year" | "dateRange" | "select";
|
|
2333
2400
|
/** select 选项 */
|
|
2334
2401
|
options?: Array<{
|
|
2335
2402
|
label: string;
|
|
@@ -2338,7 +2405,7 @@ declare interface ReportParamDef_3 {
|
|
|
2338
2405
|
defaultValue?: string;
|
|
2339
2406
|
required?: boolean;
|
|
2340
2407
|
placeholder?: string;
|
|
2341
|
-
/**
|
|
2408
|
+
/** 数字上下界;日期/月/年使用对应规范字符串;dateRange 对两端使用 YYYY-MM-DD 边界(含边界)。 */
|
|
2342
2409
|
min?: number | string;
|
|
2343
2410
|
max?: number | string;
|
|
2344
2411
|
minLength?: number;
|
|
@@ -2361,7 +2428,12 @@ export declare const ReportParamPanel: DefineComponent<__VLS_Props_3, {
|
|
|
2361
2428
|
onReset?: (() => any) | undefined;
|
|
2362
2429
|
onQuery?: (() => any) | undefined;
|
|
2363
2430
|
"onUpdate:modelValue"?: ((value: Record<string, string>) => any) | undefined;
|
|
2364
|
-
}>, {
|
|
2431
|
+
}>, {
|
|
2432
|
+
disabled: boolean;
|
|
2433
|
+
issues: readonly ReportParamIssue[];
|
|
2434
|
+
showActions: boolean;
|
|
2435
|
+
showTitle: boolean;
|
|
2436
|
+
}>;
|
|
2365
2437
|
export declare interface ReportPreferencesAdapter {
|
|
2366
2438
|
load(key: string): Partial<ReportPreviewPreferences> | null | Promise<Partial<ReportPreviewPreferences> | null>;
|
|
2367
2439
|
save(key: string, value: Readonly<Partial<ReportPreviewPreferences>>): void | Promise<void>;
|
|
@@ -2607,6 +2679,9 @@ declare interface TemplatePage {
|
|
|
2607
2679
|
marginLeftMm?: number;
|
|
2608
2680
|
marginRightMm?: number;
|
|
2609
2681
|
components: TemplateComponent[];
|
|
2682
|
+
/** Explicit vertical bands preserve source gaps as dynamic regions expand. */
|
|
2683
|
+
flow?: ReportPageFlow;
|
|
2684
|
+
meta?: Record<string, unknown>;
|
|
2610
2685
|
}
|
|
2611
2686
|
declare interface TemplatePage_2 {
|
|
2612
2687
|
widthMm: number;
|
|
@@ -2618,6 +2693,9 @@ declare interface TemplatePage_2 {
|
|
|
2618
2693
|
marginLeftMm?: number;
|
|
2619
2694
|
marginRightMm?: number;
|
|
2620
2695
|
components: TemplateComponent_2[];
|
|
2696
|
+
/** Explicit vertical bands preserve source gaps as dynamic regions expand. */
|
|
2697
|
+
flow?: ReportPageFlow_2;
|
|
2698
|
+
meta?: Record<string, unknown>;
|
|
2621
2699
|
}
|
|
2622
2700
|
declare interface TemplatePage_3 {
|
|
2623
2701
|
widthMm: number;
|
|
@@ -2629,6 +2707,9 @@ declare interface TemplatePage_3 {
|
|
|
2629
2707
|
marginLeftMm?: number;
|
|
2630
2708
|
marginRightMm?: number;
|
|
2631
2709
|
components: TemplateComponent_3[];
|
|
2710
|
+
/** Explicit vertical bands preserve source gaps as dynamic regions expand. */
|
|
2711
|
+
flow?: ReportPageFlow_3;
|
|
2712
|
+
meta?: Record<string, unknown>;
|
|
2632
2713
|
}
|
|
2633
2714
|
/**
|
|
2634
2715
|
* 文本测量与折行(分页/Canvas/PDF 共用的唯一折行真相源)。
|
|
@@ -2651,6 +2732,63 @@ declare interface TextMeasurer {
|
|
|
2651
2732
|
/** theme 对象 → CSS 自定义属性 style 对象(注入组件外壳) */
|
|
2652
2733
|
export declare function themeToCssVars(theme: Partial<MachReportTheme>): CSSProperties;
|
|
2653
2734
|
export declare function toErrorDetail(error: unknown): MachReportErrorDetail;
|
|
2735
|
+
/** A serialized tree contract. Sibling and root order follow input order. */
|
|
2736
|
+
declare interface TreeTableOptions {
|
|
2737
|
+
input: "flat" | "nested";
|
|
2738
|
+
idField: string;
|
|
2739
|
+
/** Flat roots have null/undefined parent values. */
|
|
2740
|
+
parentField?: string;
|
|
2741
|
+
/** Nested child arrays, defaults to children. Every node still needs an ID. */
|
|
2742
|
+
childrenField?: string;
|
|
2743
|
+
labelField: string;
|
|
2744
|
+
indentMm?: number;
|
|
2745
|
+
orphan?: "error" | "root";
|
|
2746
|
+
/** Source preserves parent values; leaf-aggregate derives only parents from descendant leaves. */
|
|
2747
|
+
parentValues?: "source" | "leaf-aggregate";
|
|
2748
|
+
aggregates?: AggregateDefinition[];
|
|
2749
|
+
maxRows?: number;
|
|
2750
|
+
maxDepth?: number;
|
|
2751
|
+
/** Bounded leaf-to-ancestor aggregate work; default one million. */
|
|
2752
|
+
maxAggregationVisits?: number;
|
|
2753
|
+
}
|
|
2754
|
+
/** A serialized tree contract. Sibling and root order follow input order. */
|
|
2755
|
+
declare interface TreeTableOptions_2 {
|
|
2756
|
+
input: "flat" | "nested";
|
|
2757
|
+
idField: string;
|
|
2758
|
+
/** Flat roots have null/undefined parent values. */
|
|
2759
|
+
parentField?: string;
|
|
2760
|
+
/** Nested child arrays, defaults to children. Every node still needs an ID. */
|
|
2761
|
+
childrenField?: string;
|
|
2762
|
+
labelField: string;
|
|
2763
|
+
indentMm?: number;
|
|
2764
|
+
orphan?: "error" | "root";
|
|
2765
|
+
/** Source preserves parent values; leaf-aggregate derives only parents from descendant leaves. */
|
|
2766
|
+
parentValues?: "source" | "leaf-aggregate";
|
|
2767
|
+
aggregates?: AggregateDefinition_2[];
|
|
2768
|
+
maxRows?: number;
|
|
2769
|
+
maxDepth?: number;
|
|
2770
|
+
/** Bounded leaf-to-ancestor aggregate work; default one million. */
|
|
2771
|
+
maxAggregationVisits?: number;
|
|
2772
|
+
}
|
|
2773
|
+
/** A serialized tree contract. Sibling and root order follow input order. */
|
|
2774
|
+
declare interface TreeTableOptions_3 {
|
|
2775
|
+
input: "flat" | "nested";
|
|
2776
|
+
idField: string;
|
|
2777
|
+
/** Flat roots have null/undefined parent values. */
|
|
2778
|
+
parentField?: string;
|
|
2779
|
+
/** Nested child arrays, defaults to children. Every node still needs an ID. */
|
|
2780
|
+
childrenField?: string;
|
|
2781
|
+
labelField: string;
|
|
2782
|
+
indentMm?: number;
|
|
2783
|
+
orphan?: "error" | "root";
|
|
2784
|
+
/** Source preserves parent values; leaf-aggregate derives only parents from descendant leaves. */
|
|
2785
|
+
parentValues?: "source" | "leaf-aggregate";
|
|
2786
|
+
aggregates?: AggregateDefinition_3[];
|
|
2787
|
+
maxRows?: number;
|
|
2788
|
+
maxDepth?: number;
|
|
2789
|
+
/** Bounded leaf-to-ancestor aggregate work; default one million. */
|
|
2790
|
+
maxAggregationVisits?: number;
|
|
2791
|
+
}
|
|
2654
2792
|
/**
|
|
2655
2793
|
* 父组件统一入口,无需手写组件实例类型或可选链:
|
|
2656
2794
|
* `const report = useMachReport()` → `<MachReportPreview :ref="report.ref" />`。
|
package/dist/vue-async.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("./plugin-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("./plugin-BDTU4D94.cjs");function i(){return Promise.resolve().then(()=>require("./ReportPreview-DWXROHBP.cjs")).then(e=>e.ReportPreview$1)}const t={install(e,o={}){r.machReportPlugin.install(e,o)}};exports.MachReportPreview=r.MachReportPreview;exports.default=t;exports.machReportAsyncPlugin=t;exports.preloadMachReport=i;
|
package/dist/vue-async.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { m as
|
|
2
|
-
import { M as l } from "./plugin-
|
|
1
|
+
import { m as r } from "./plugin-Cd5G2QQn.js";
|
|
2
|
+
import { M as l } from "./plugin-Cd5G2QQn.js";
|
|
3
3
|
function a() {
|
|
4
|
-
return import("./ReportPreview-
|
|
4
|
+
return import("./ReportPreview-DiNXhQI0.js").then((t) => t.o);
|
|
5
5
|
}
|
|
6
6
|
const n = {
|
|
7
|
-
install(t,
|
|
8
|
-
|
|
7
|
+
install(t, o = {}) {
|
|
8
|
+
r.install(t, o);
|
|
9
9
|
}
|
|
10
10
|
};
|
|
11
11
|
export {
|
package/dist/vue.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("@agile-team/mach-report"),i=require("./ReportPreview-DWXROHBP.cjs"),a=require("./config-BRoLo2oj.cjs"),f=require("./injection-keys-Db_DyLkm.cjs"),_=require("./plugin-BDTU4D94.cjs"),h=require("vue");function S(r){const e=E.createReportSource(r),n=async t=>{if(t.reportIds.length===0)throw new i.PlanLoadError("缺少报表 ID");for(const o of t.reportIds)if(!Object.prototype.hasOwnProperty.call(r,o)||!r[o])throw new i.PlanLoadError(`本地模板 ${o} 不存在`);return e(t)};return n.getParamDefs=e.getParamDefs,n}const v=Object.freeze({loading:!1,hasPlan:!1,pageCount:0,currentPage:1,exporting:null,printing:!1,canExport:!1,canPrint:!1,error:null,pdfFont:Object.freeze({status:"unchecked",fontUrl:""})});function A(){const r=h.shallowRef(null),e=()=>r.value?.state??v,n=Object.freeze({get loading(){return e().loading},get hasPlan(){return e().hasPlan},get pageCount(){return e().pageCount},get currentPage(){return e().currentPage},get exporting(){return e().exporting},get printing(){return e().printing},get canExport(){return e().canExport},get canPrint(){return e().canPrint},get error(){return e().error},get pdfFont(){return e().pdfFont},get editing(){return e().editing??!1},get saving(){return e().saving??!1},get importing(){return e().importing??!1},get dirty(){return e().dirty??!1},get pendingLocalChanges(){return e().pendingLocalChanges??!1},get task(){return e().task??null},get diagnostics(){return e().diagnostics??[]},get reportIds(){return e().reportIds??[]},get params(){return e().params??{}},get canUndo(){return e().canUndo??!1},get canRedo(){return e().canRedo??!1},get changeCount(){return e().changeCount??0},get selection(){return e().selection??null}});function t(){if(!r.value)throw new a.MachReportError("config","报表预览尚未挂载,请在 ready 后调用控制器");return r.value}return{ref(o){const s=o;r.value=s&&typeof s.reload=="function"&&typeof s.print=="function"&&typeof s.exportAs=="function"&&typeof s.openPdfWindow=="function"&&typeof s.gotoPage=="function"&&typeof s.setParams=="function"?s:null},ready:h.computed(()=>r.value!==null),state:n,async checkPdfFont(){const o=t();return o.checkPdfFont?o.checkPdfFont():{status:"unverified",fontUrl:"",message:"旧自定义控制器未提供字体检查,请由宿主确认字体配置"}},cancelTask(){t().cancelTask?.()},async confirmDiscard(o){return await t().confirmDiscard?.(o)??!0},getOutputDiagnostics(o){return t().getOutputDiagnostics?.(o)??[]},async reload(){await t().reload()},async print(){await t().print()},async exportAs(o){await t().exportAs(o)},openPdfWindow(){t().openPdfWindow()},gotoPage(o){t().gotoPage(o)},async setParams(o,s){await t().setParams(o,s)},async importExcel(o,s){const g=t();if(!g.importExcel)throw new a.MachReportError("config","旧自定义控制器未提供 Excel 导入");return g.importExcel(o,s)},getPlan(){return t().getPlan?.()??null},getChanges(){return t().getChanges?.()??[]},getDifferences:()=>t().getDifferences?.()??[],undo:async()=>await t().undo?.()??!1,redo:async()=>await t().redo?.()??!1,restoreChanges:async()=>await t().restoreChanges?.()??!1,getSelection:()=>t().getSelection?.()??null,focusCell:async(o,s)=>await t().focusCell?.(o,s)??!1,focusField:async o=>await t().focusField?.(o)??!1,copySelection:()=>t().copySelection?.()??"",pasteSelection:async o=>await t().pasteSelection?.(o)??!1}}function I(){return h.inject(f.MACH_REPORT_CONTROLLER_KEY,null)}function T(r){return!!r&&typeof r=="object"&&!Array.isArray(r)}function L(r){return Array.isArray(r)&&r.every(e=>T(e)&&typeof e.code=="string"&&typeof e.message=="string"&&["info","warning","error"].includes(e.severity)&&(e.path===void 0||typeof e.path=="string"))}function D(r,e){return Array.isArray(r)&&r.every(n=>T(n)&&Number.isSafeInteger(n.editIndex)&&n.editIndex>=0&&n.editIndex<e&&typeof n.code=="string"&&typeof n.message=="string")}function x(r,e){let n;if(!T(r)||typeof r.revision!="string"||!r.revision.trim()?n="非空 revision(请先在适配器解包业务响应)":r.sourceToken!==void 0&&typeof r.sourceToken!="string"?n="字符串 sourceToken":r.diagnostics!==void 0&&!L(r.diagnostics)?n="结构化 diagnostics":r.conflicts!==void 0&&!D(r.conflicts,e)&&(n="有效 editIndex/code/message conflicts"),n)throw new a.MachReportError("edit",`ReportProvider.save 必须返回${n};服务器可能已提交,请重新查询确认后再编辑`)}function w(r){return typeof r=="function"?r():r}function F(r,e){const n=new Set(r.flatMap(t=>t.source?.[e]===void 0?[]:[String(t.source[e])]));return n.size===1?[...n][0]:void 0}function O(r,e,n,t){return typeof r=="function"?r():F(e,n)??t??r}function b(r){return r.requestId??globalThis.crypto?.randomUUID?.()??`mr-${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}function q(r,e){if(!r.save)throw new a.MachReportError("config","ReportProvider.save 未配置,无法启用业务保存");let n="",t,o,s=0;function g(c,u,p){c.conflicts?.length||u!==n||p!==s||(t=c.revision,o=c.sourceToken)}async function m(c,u){if(u.signal.aborted)throw u.signal.reason??new DOMException("Aborted","AbortError");const p=w(e.reportId),y={...w(e.params??{})},R=JSON.stringify([p,y]),C=++s;if(R!==n&&(n=R,t=void 0,o=void 0),e.requireSource!==!1&&c.edits.some(d=>!d.source))throw new E.ReportCellEditError("missing");const l=await r.save({reportId:p,params:y,signal:u.signal,requestId:c.requestId,action:u.action,edits:i.cloneReportSnapshot(c.edits),expectedRevision:O(e.expectedRevision,c.edits,"revision",t),sourceToken:O(e.sourceToken,c.edits,"sourceToken",o)});if(u.signal.aborted)throw u.signal.reason??new DOMException("Aborted","AbortError");x(l,c.edits.length),l.diagnostics?.forEach(d=>e.onDiagnostic?.(d));const P=l.diagnostics?.filter(d=>d.severity==="error");if(P?.length)throw new a.MachReportError("edit",P.map(d=>d.message).join(";"),{diagnostics:P});const M=l.conflicts?.map(d=>({source:c.edits[d.editIndex]?.source,address:c.edits[d.editIndex]?.address,message:d.message}));return g(l,R,C),{revision:l.revision,sourceToken:l.sourceToken,conflicts:M}}return{requireSource:e.requireSource??!0,canEdit:e.canEdit,validate:e.validate,saveBatch:m,save:(c,u)=>m({requestId:b(u),edits:[i.cloneReportSnapshot(c)]},u)}}exports.PlanLoadError=i.PlanLoadError;exports.REPORT_EXPORT_FORMATS=i.REPORT_EXPORT_FORMATS;exports.REPORT_PREVIEW_TOOLS=i.REPORT_PREVIEW_TOOLS;exports.ReportPagination=i.ReportPagination;exports.ReportPreview=i.ReportPreview;exports.ReportToolbar=i.ReportToolbar;exports.buildPrintDocument=i.buildPrintDocument;exports.buildWordHtml=i.buildWordHtml;exports.createDefaultPdfExporter=i.createDefaultPdfExporter;exports.createFetchRequest=i.createFetchRequest;exports.createReportStoragePreferences=i.createReportStoragePreferences;exports.joinReportIds=i.joinReportIds;exports.normalizeReportIds=i.normalizeReportIds;exports.printPlans=i.printPlans;exports.usePageWindow=i.usePageWindow;exports.usePrintExport=i.usePrintExport;exports.useZoom=i.useZoom;exports.DEFAULT_CALCULATION_MESSAGES=a.DEFAULT_CALCULATION_MESSAGES;exports.DEFAULT_MESSAGES=a.DEFAULT_MESSAGES;exports.DEFAULT_THEME=a.DEFAULT_THEME;exports.MachReportError=a.MachReportError;exports.ReportParamPanel=a.ReportParamPanel;exports.SILENT_LOGGER=a.SILENT_LOGGER;exports.defineMachReportConfig=a.defineMachReportConfig;exports.defineMachReportPreset=a.defineMachReportPreset;exports.normalizeReportLoadError=a.normalizeReportLoadError;exports.provideMachReportConfig=a.provideMachReportConfig;exports.resolveCalculationMessages=a.resolveCalculationMessages;exports.resolveConfig=a.resolveConfig;exports.themeToCssVars=a.themeToCssVars;exports.toErrorDetail=a.toErrorDetail;exports.useMachReportConfig=a.useMachReportConfig;exports.MACH_REPORT_CONFIG_KEY=f.MACH_REPORT_CONFIG_KEY;exports.MACH_REPORT_CONTROLLER_KEY=f.MACH_REPORT_CONTROLLER_KEY;exports.MACH_REPORT_FETCHER_KEY=f.MACH_REPORT_FETCHER_KEY;exports.MACH_REPORT_PDF_EXPORTER_KEY=f.MACH_REPORT_PDF_EXPORTER_KEY;exports.MachReportPreview=_.MachReportPreview;exports.machReportPlugin=_.machReportPlugin;exports.createLocalFetcher=S;exports.createProviderEditing=q;exports.useMachReport=A;exports.useReportPreview=I;Object.keys(E).forEach(r=>{r!=="default"&&!Object.prototype.hasOwnProperty.call(exports,r)&&Object.defineProperty(exports,r,{enumerable:!0,get:()=>E[r]})});
|