@gct-paas/word 0.1.25 → 0.1.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/interaction/InteractionController.d.ts +2 -0
- package/dist/core/utils/expand.d.ts +18 -23
- package/dist/core/view/Doc.d.ts +5 -1
- package/dist/core/view/TableCell.d.ts +2 -0
- package/dist/core/widget/widget-state.d.ts +5 -0
- package/dist/index.es.js +546 -471
- package/dist/runtime/canvas/table/utils/index.d.ts +6 -17
- package/dist/runtime/interface/render.d.ts +0 -6
- package/dist/sdk/doc-runtime/factories/document-initializer.d.ts +1 -1
- package/dist/sdk/types/index.d.ts +10 -4
- package/dist/utils/func/form.d.ts +2 -0
- package/dist/word.css +17 -17
- package/package.json +1 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { CellRect, HLine, MergeRect, OutlineResult, OutlineType, VLine } from '../types/table';
|
|
2
|
+
export declare const OUTLINE_BORDER_INSET = 1;
|
|
2
3
|
export declare const borderConfig: {
|
|
3
4
|
outer: {
|
|
4
5
|
color: string;
|
|
@@ -83,25 +84,13 @@ export declare function mapCellsToOutlineCells(cells: any[]): {
|
|
|
83
84
|
}[];
|
|
84
85
|
export declare function groupBy<T>(list: T[], getKey: (item: T) => string): Record<string, T[]>;
|
|
85
86
|
export declare function buildPosMap<T>(layers: Record<string, T>, getRect: (layer: T) => any | null, toDom: (rect: any) => any): Record<string, any>;
|
|
86
|
-
export declare function
|
|
87
|
-
|
|
88
|
-
|
|
87
|
+
export declare function getDataIndexLayersMap({ type, cells, isEdit, convertExtraProps }: {
|
|
88
|
+
type: 'fixed-table' | 'check-table' | 'dynamic-table' | '2d-table';
|
|
89
|
+
cells: any[];
|
|
89
90
|
isEdit: boolean;
|
|
90
|
-
|
|
91
|
-
type: OutlineType;
|
|
92
|
-
placeholder: string;
|
|
93
|
-
valuePath: string;
|
|
94
|
-
}): {
|
|
95
|
-
[k: string]: {
|
|
96
|
-
showBorder: boolean;
|
|
97
|
-
placeholderBjRect: Omit<CellRect, "layoutX" | "layoutY"> | null;
|
|
98
|
-
lastCell: any;
|
|
91
|
+
convertExtraProps: (firstCell: any) => {
|
|
99
92
|
type: OutlineType;
|
|
100
93
|
placeholder: string;
|
|
101
94
|
valuePath: string;
|
|
102
|
-
backgroundRect: Omit<CellRect, "layoutX" | "layoutY"> | null;
|
|
103
|
-
hLines: HLine[];
|
|
104
|
-
vLines: VLine[];
|
|
105
|
-
labelPos?: VLine | undefined;
|
|
106
95
|
};
|
|
107
|
-
};
|
|
96
|
+
}): any;
|
|
@@ -1,11 +1,5 @@
|
|
|
1
|
-
import { FIELD_TYPE } from '../../domain/field/field-type';
|
|
2
1
|
import { DesignSuiteContext } from '../_register_/context/DesignSuiteContext';
|
|
3
2
|
import { FieldMeta } from '../../capabilities/model-field-runtime';
|
|
4
|
-
/** 渲染端公共类(目前只迁移了部分使用到的方法 ) */
|
|
5
|
-
export declare const renderUtils: {
|
|
6
|
-
getBoolValue: (value: any) => any;
|
|
7
|
-
formatValue: (fieldType: FIELD_TYPE, value: any) => any;
|
|
8
|
-
};
|
|
9
3
|
/**
|
|
10
4
|
* 根据字段类型获取默认的查询ID值
|
|
11
5
|
* 用于根据不同类型的ID请求实验室(Lab)相关数据
|
|
@@ -5,6 +5,6 @@ export interface InitializedDocument {
|
|
|
5
5
|
doc: Doc;
|
|
6
6
|
docInfo: DocInfo;
|
|
7
7
|
}
|
|
8
|
-
/** 从 Doc
|
|
8
|
+
/** 从 Doc 实例提取响应式页面快照(与 layout 同步,供 docInfo ref 驱动 Vue) */
|
|
9
9
|
export declare function snapshotDocInfo(docInst?: Doc): DocInfo;
|
|
10
10
|
export declare function initializeDocumentEngine(props: IDocProps, payload: IDocPayload, result: Execute): Promise<InitializedDocument>;
|
|
@@ -7,7 +7,7 @@ import { OnlineFormInstanceResponse, OnlineFormTmplResponse } from '@gct-paas/ap
|
|
|
7
7
|
import { FieldChangeItem } from '../../runtime/interface/change-diff';
|
|
8
8
|
import { FormTmplConfigController } from '../../suites/edhr/panel-schema/data-load/hooks/form-tmpl-config';
|
|
9
9
|
import { Execute } from '../doc-runtime/factories/useDocumentFactory';
|
|
10
|
-
export type { DocUnsavedChanges, DocGetUnsavedChangesOptions } from '../doc-runtime/composables/useDocOperations';
|
|
10
|
+
export type { DocUnsavedChanges, DocGetUnsavedChangesOptions, } from '../doc-runtime/composables/useDocOperations';
|
|
11
11
|
export type { FieldModelQuery } from './field-model-query';
|
|
12
12
|
/** 字段权限信息 */
|
|
13
13
|
export interface FieldPermissionInfo {
|
|
@@ -31,6 +31,12 @@ export interface DocInfo {
|
|
|
31
31
|
pages: Page[];
|
|
32
32
|
/** 布局刷新次数 */
|
|
33
33
|
updateTick: number;
|
|
34
|
+
/** 主渲染模式(文档未加载时为 null) */
|
|
35
|
+
mode: DocModeType | null;
|
|
36
|
+
/** 主渲染模式文案 */
|
|
37
|
+
modeLabel: string;
|
|
38
|
+
/** 按钮区渲染模式(文档未加载时为 null) */
|
|
39
|
+
btnRenderModeType: DocModeType | null;
|
|
34
40
|
}
|
|
35
41
|
/** 只读文档查询 API(对外稳定) */
|
|
36
42
|
export interface DocQueryAPI {
|
|
@@ -50,7 +56,7 @@ export interface DocControllerMethods extends DocOperations {
|
|
|
50
56
|
/** 重做上一步被撤销的操作 */
|
|
51
57
|
redo(): void;
|
|
52
58
|
/** 设置渲染模式 */
|
|
53
|
-
setMode(mode: DocModeType): void;
|
|
59
|
+
setMode(mode: DocModeType, updateBtn?: boolean): void;
|
|
54
60
|
/** 用新的文档模型替换当前文档 */
|
|
55
61
|
setModel(model: DocModel): void;
|
|
56
62
|
/** 获取当前文档原始填报数据快照 */
|
|
@@ -94,6 +100,8 @@ export interface DocControllerState {
|
|
|
94
100
|
mode: ComputedRef<DocModeType | null>;
|
|
95
101
|
/** 当前渲染模式中文文案(响应式) */
|
|
96
102
|
modeLabel: ComputedRef<string>;
|
|
103
|
+
/** 按钮区渲染模式(响应式) */
|
|
104
|
+
btnRenderModeType: ComputedRef<DocModeType | null>;
|
|
97
105
|
/** 布局刷新次数(响应式) */
|
|
98
106
|
updateTick: ComputedRef<number>;
|
|
99
107
|
/** 当前页面数组(响应式) */
|
|
@@ -118,8 +126,6 @@ export interface DocController extends DocControllerState, DocControllerMethods
|
|
|
118
126
|
}
|
|
119
127
|
/** docRuntimeMeta 中业务拼接的运行时处理信息 */
|
|
120
128
|
export interface DocRuntimeMetaHandleInfo {
|
|
121
|
-
/** 按钮区渲染模式 */
|
|
122
|
-
btnRenderModeType: DocModeType;
|
|
123
129
|
/** bpmn 流程类型 */
|
|
124
130
|
bpmnType?: string;
|
|
125
131
|
/** bpmn 字段权限映射 */
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { DecimalDisplayModeType } from '../../domain/constants/enum';
|
|
2
|
+
import { FIELD_TYPE } from '../../domain/field/field-type';
|
|
2
3
|
export declare function getValue(value: any, multiple: boolean): any;
|
|
3
4
|
export declare function setValue(value: any, valuePath: string, payload?: {
|
|
4
5
|
multiple?: boolean;
|
|
@@ -11,6 +12,7 @@ export declare function setValue(value: any, valuePath: string, payload?: {
|
|
|
11
12
|
[x: string]: any;
|
|
12
13
|
};
|
|
13
14
|
export declare function toBoolean(value: any): boolean | null;
|
|
15
|
+
export declare function toFormatValue(fieldType: FIELD_TYPE, value: any): any;
|
|
14
16
|
export declare function toDictValue(field: string, value: any, row: any): any;
|
|
15
17
|
export declare function getSelectOptions(payload: any): {
|
|
16
18
|
selectOptions: any;
|
package/dist/word.css
CHANGED
|
@@ -8474,25 +8474,25 @@ textarea[data-v-57fe54a3]::placeholder {
|
|
|
8474
8474
|
.container[data-v-9e3d6c1b] .form-item__label {
|
|
8475
8475
|
width: 90px;
|
|
8476
8476
|
}
|
|
8477
|
-
.container[data-v-
|
|
8477
|
+
.container[data-v-d5785019] {
|
|
8478
8478
|
padding: 0 20px;
|
|
8479
8479
|
}
|
|
8480
|
-
.container[data-v-
|
|
8480
|
+
.container[data-v-d5785019] .form-item__label {
|
|
8481
8481
|
width: 80px;
|
|
8482
8482
|
}
|
|
8483
|
-
.items-container[data-v-
|
|
8483
|
+
.items-container[data-v-880a7ed3] {
|
|
8484
8484
|
display: inline-flex;
|
|
8485
8485
|
height: 42px;
|
|
8486
8486
|
align-items: center;
|
|
8487
8487
|
overflow: hidden;
|
|
8488
8488
|
}
|
|
8489
|
-
.ribbon-tab-item[data-v-
|
|
8489
|
+
.ribbon-tab-item[data-v-880a7ed3] {
|
|
8490
8490
|
display: inline-flex;
|
|
8491
8491
|
align-items: center;
|
|
8492
8492
|
flex-shrink: 0;
|
|
8493
8493
|
gap: 6px;
|
|
8494
8494
|
}
|
|
8495
|
-
.split-divider[data-v-
|
|
8495
|
+
.split-divider[data-v-880a7ed3] {
|
|
8496
8496
|
display: inline-block;
|
|
8497
8497
|
width: 1px;
|
|
8498
8498
|
height: 16px;
|
|
@@ -8500,11 +8500,11 @@ textarea[data-v-57fe54a3]::placeholder {
|
|
|
8500
8500
|
flex-shrink: 0;
|
|
8501
8501
|
margin: 0 6px;
|
|
8502
8502
|
}
|
|
8503
|
-
.title-style-bottom-bar[data-v-
|
|
8503
|
+
.title-style-bottom-bar[data-v-880a7ed3] {
|
|
8504
8504
|
padding: 8px;
|
|
8505
8505
|
position: relative;
|
|
8506
8506
|
}
|
|
8507
|
-
.title-style-bottom-bar[data-v-
|
|
8507
|
+
.title-style-bottom-bar[data-v-880a7ed3]::before {
|
|
8508
8508
|
content: '';
|
|
8509
8509
|
height: 1px;
|
|
8510
8510
|
background: #f0f0f0;
|
|
@@ -8515,11 +8515,11 @@ textarea[data-v-57fe54a3]::placeholder {
|
|
|
8515
8515
|
margin-left: 8px;
|
|
8516
8516
|
margin-right: 8px;
|
|
8517
8517
|
}
|
|
8518
|
-
.title-style-bottom-bar .content[data-v-
|
|
8518
|
+
.title-style-bottom-bar .content[data-v-880a7ed3] {
|
|
8519
8519
|
padding: 6px 8px;
|
|
8520
8520
|
border-radius: 4px;
|
|
8521
8521
|
}
|
|
8522
|
-
.title-style-bottom-bar .content[data-v-
|
|
8522
|
+
.title-style-bottom-bar .content[data-v-880a7ed3]:hover {
|
|
8523
8523
|
background: rgba(13, 13, 13, 0.06);
|
|
8524
8524
|
}
|
|
8525
8525
|
.v-popper__popper.paragraph-title-select-dropdown .option-label {
|
|
@@ -8858,7 +8858,7 @@ ul li .widget-icon[data-v-1e28101c] {
|
|
|
8858
8858
|
line-height: 22px;
|
|
8859
8859
|
}
|
|
8860
8860
|
|
|
8861
|
-
[data-v-
|
|
8861
|
+
[data-v-8bfe3f32] .gct-input-number {
|
|
8862
8862
|
text-align: center;
|
|
8863
8863
|
width: 48px;
|
|
8864
8864
|
}
|
|
@@ -9688,13 +9688,13 @@ svg.portrait-icon[data-v-8bdb451e] {
|
|
|
9688
9688
|
justify-content: flex-start;
|
|
9689
9689
|
gap: 4px;
|
|
9690
9690
|
}
|
|
9691
|
-
.panel-data-group[data-v-
|
|
9691
|
+
.panel-data-group[data-v-4572267c] {
|
|
9692
9692
|
position: relative;
|
|
9693
9693
|
}
|
|
9694
|
-
.panel-data-group .container[data-v-
|
|
9694
|
+
.panel-data-group .container[data-v-4572267c] {
|
|
9695
9695
|
padding: 16px;
|
|
9696
9696
|
}
|
|
9697
|
-
.panel-data-group .content[data-v-
|
|
9697
|
+
.panel-data-group .content[data-v-4572267c] {
|
|
9698
9698
|
width: 100%;
|
|
9699
9699
|
display: flex;
|
|
9700
9700
|
line-height: 22px;
|
|
@@ -9702,18 +9702,18 @@ svg.portrait-icon[data-v-8bdb451e] {
|
|
|
9702
9702
|
align-items: center;
|
|
9703
9703
|
justify-content: flex-end;
|
|
9704
9704
|
}
|
|
9705
|
-
.panel-data-group .line-content[data-v-
|
|
9705
|
+
.panel-data-group .line-content[data-v-4572267c] {
|
|
9706
9706
|
position: relative;
|
|
9707
9707
|
display: flex;
|
|
9708
9708
|
margin-top: 12px;
|
|
9709
9709
|
margin-bottom: 12px;
|
|
9710
9710
|
gap: 16px;
|
|
9711
9711
|
}
|
|
9712
|
-
.panel-data-group .line-content .form-item[data-v-
|
|
9712
|
+
.panel-data-group .line-content .form-item[data-v-4572267c] {
|
|
9713
9713
|
margin-top: 0;
|
|
9714
9714
|
gap: 8px;
|
|
9715
9715
|
}
|
|
9716
|
-
.panel-data-group .line-content .delete-title[data-v-
|
|
9716
|
+
.panel-data-group .line-content .delete-title[data-v-4572267c] {
|
|
9717
9717
|
color: #f54547;
|
|
9718
9718
|
cursor: pointer;
|
|
9719
9719
|
transition: all 0.3s;
|
|
@@ -9723,7 +9723,7 @@ svg.portrait-icon[data-v-8bdb451e] {
|
|
|
9723
9723
|
right: 0;
|
|
9724
9724
|
line-height: 22px;
|
|
9725
9725
|
}
|
|
9726
|
-
.panel-data-group .line-content .delete-title[data-v-
|
|
9726
|
+
.panel-data-group .line-content .delete-title[data-v-4572267c]:hover {
|
|
9727
9727
|
opacity: 0.7;
|
|
9728
9728
|
}
|
|
9729
9729
|
.panel-data-group-2d[data-v-09b6985e] {
|