@hailin-zheng/editor-core 2.2.14 → 2.2.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index-cjs.js +340 -103
- package/index-cjs.js.map +1 -1
- package/index.js +338 -103
- package/index.js.map +1 -1
- package/med_editor/doc-editor.d.ts +1 -0
- package/med_editor/editor-core.d.ts +4 -7
- package/med_editor/framework/doc-layout/document-arrange.d.ts +2 -0
- package/med_editor/framework/document-context.d.ts +12 -1
- package/med_editor/framework/element-define.d.ts +9 -6
- package/med_editor/framework/element-event-define.d.ts +0 -2
- package/med_editor/framework/impl/data-element/data-decorate-impl.d.ts +1 -0
- package/med_editor/framework/impl/data-element/data-element-base-impl.d.ts +2 -1
- package/med_editor/framework/impl/data-element/data-element-group-impl.d.ts +2 -1
- package/med_editor/framework/impl/document/doc-impl.d.ts +3 -1
- package/package.json +2 -2
package/index.js
CHANGED
@@ -24,8 +24,6 @@ class ElementEvent {
|
|
24
24
|
* 当前所在的对象
|
25
25
|
*/
|
26
26
|
currentElement;
|
27
|
-
currentRenderObjectX;
|
28
|
-
currentRenderObjectY;
|
29
27
|
//是否取消向上冒泡
|
30
28
|
isCancel;
|
31
29
|
globalX;
|
@@ -741,8 +739,11 @@ class CommonUtil {
|
|
741
739
|
const shouldCallNow = elapsed >= wait;
|
742
740
|
clearTimeout(timeout);
|
743
741
|
if (shouldCallNow) {
|
744
|
-
|
745
|
-
|
742
|
+
//延迟执行,微任务
|
743
|
+
Promise.resolve().then(() => {
|
744
|
+
fn.apply(context, args);
|
745
|
+
lastExecTime = Date.now();
|
746
|
+
});
|
746
747
|
}
|
747
748
|
else {
|
748
749
|
timeout = setTimeout(() => {
|
@@ -971,6 +972,8 @@ function generatePatch(doc, clear = true) {
|
|
971
972
|
}
|
972
973
|
if ('insert' in op.ops) {
|
973
974
|
insertOpsMap.set(ele, op);
|
975
|
+
//对象复制出来,避免paintRenders等内存占用
|
976
|
+
op.ops.insert = op.ops.insert.clone(true);
|
974
977
|
}
|
975
978
|
//当前为新插入的元素
|
976
979
|
if ('insText' in op.ops) {
|
@@ -1225,7 +1228,7 @@ class Element {
|
|
1225
1228
|
modifyFlag = ModifyFlag.Modify;
|
1226
1229
|
isMouseenter;
|
1227
1230
|
_eventMap;
|
1228
|
-
_refreshEvent = new Subject();
|
1231
|
+
//private _refreshEvent: Subject<void> = new Subject();
|
1229
1232
|
_onChangeEvent = new Subject();
|
1230
1233
|
observers = new WeakMap();
|
1231
1234
|
paintRenders = [];
|
@@ -1330,14 +1333,15 @@ class Element {
|
|
1330
1333
|
return 0;
|
1331
1334
|
}
|
1332
1335
|
}
|
1333
|
-
get refreshSubject() {
|
1334
|
-
|
1335
|
-
}
|
1336
|
+
// get refreshSubject(): Subject<void> {
|
1337
|
+
// return this._refreshEvent;
|
1338
|
+
// }
|
1336
1339
|
get onChangeSubject() {
|
1337
1340
|
return this._onChangeEvent;
|
1338
1341
|
}
|
1339
1342
|
refreshView() {
|
1340
|
-
this._refreshEvent.next();
|
1343
|
+
//this._refreshEvent.next();
|
1344
|
+
//refreshEditor(this);
|
1341
1345
|
}
|
1342
1346
|
unsubscribe(element) {
|
1343
1347
|
const subs = this.observers.get(element);
|
@@ -1419,13 +1423,13 @@ class BranchElement extends Element {
|
|
1419
1423
|
child.parent = this;
|
1420
1424
|
this.chilren.splice(index, 0, child);
|
1421
1425
|
insertEle(child);
|
1422
|
-
const refSub = child.refreshSubject.subscribe((data) => {
|
1423
|
-
|
1424
|
-
});
|
1426
|
+
//const refSub = child.refreshSubject.subscribe((data) => {
|
1427
|
+
//this.refreshSubject.next(data);
|
1428
|
+
// });
|
1425
1429
|
const onChangeSub = child.onChangeSubject.subscribe((data) => {
|
1426
1430
|
this.pubOnChange('tracker');
|
1427
1431
|
});
|
1428
|
-
this.addsubscribe(child,
|
1432
|
+
this.addsubscribe(child, onChangeSub);
|
1429
1433
|
this.pubOnChange('self');
|
1430
1434
|
}
|
1431
1435
|
removeChild(child) {
|
@@ -1705,9 +1709,9 @@ class ViewOptions {
|
|
1705
1709
|
currentFontName = '宋体';
|
1706
1710
|
//选区颜色
|
1707
1711
|
selectionColor = 'rgb(131,175,155,0.5)';
|
1708
|
-
|
1709
|
-
|
1710
|
-
|
1712
|
+
dataEleDecoratorNormalColor = '#0050b3';
|
1713
|
+
dataEleDecoratorMouseEnterColor = '#0050b3';
|
1714
|
+
dataEleDecoratorFocusedColor = '#0050b3';
|
1711
1715
|
//数据元修饰符宽度
|
1712
1716
|
dataDecoratorWidth = 1;
|
1713
1717
|
//是否显示数据元修饰符
|
@@ -1724,12 +1728,18 @@ class ViewOptions {
|
|
1724
1728
|
dataEleNormalBgColor = '#fafafa';
|
1725
1729
|
//数据元错误背景颜色
|
1726
1730
|
dataEleErrorBgColor = '#ff4d4f';
|
1727
|
-
|
1728
|
-
|
1731
|
+
//数据组修饰符号颜色
|
1732
|
+
dataGroupDecoratorNormalColor = '#0050b3';
|
1733
|
+
dataGroupDecoratorMouseEnterColor = '#0050b3';
|
1734
|
+
dataGroupDecoratorFocusedColor = '#0050b3';
|
1735
|
+
//数据组正常背景颜色
|
1736
|
+
dataGroupNormalBgColor = '#fafafa';
|
1737
|
+
//数据元没有输入值时背景颜色
|
1738
|
+
dataGroupEmptyBgColor = '';
|
1729
1739
|
//数据元鼠标悬浮颜色
|
1730
|
-
dataGroupMouseEnterBgColor = '';
|
1731
|
-
|
1732
|
-
dataGroupFocusedBgColor = '';
|
1740
|
+
dataGroupMouseEnterBgColor = '#f5f5f5';
|
1741
|
+
//数据元焦点背景颜色
|
1742
|
+
dataGroupFocusedBgColor = '#f0f0f0';
|
1733
1743
|
viewBackcolor = 'rgb(230,230,230)';
|
1734
1744
|
paraSymbolColor = 'rgb(128,128,128)';
|
1735
1745
|
dataGroupColor = 'rgb(0,80,179)';
|
@@ -1774,6 +1784,8 @@ class ViewOptions {
|
|
1774
1784
|
showEnterSymbol = false;
|
1775
1785
|
enableVisibleExpression = false;
|
1776
1786
|
shapeRendering = 'auto';
|
1787
|
+
//是否开启快速测量
|
1788
|
+
enableFastMeasure = false;
|
1777
1789
|
get fullPageView() {
|
1778
1790
|
return this._fullPageView;
|
1779
1791
|
}
|
@@ -2941,16 +2953,22 @@ class DataDecorateRenderObject extends LeafRenderObject {
|
|
2941
2953
|
if (event.mode === 'print') {
|
2942
2954
|
return null;
|
2943
2955
|
}
|
2956
|
+
if (this.element.dataEle.type === 'data-group') {
|
2957
|
+
return this.exportDataGroupSVG(event);
|
2958
|
+
}
|
2944
2959
|
// if(this.element.parent.parent.type==='data-group'){
|
2945
2960
|
// return null;
|
2946
2961
|
// }
|
2947
2962
|
const options = event.options;
|
2948
|
-
let color = options.
|
2949
|
-
if (this.element.dataEle.isMouseenter && options.
|
2950
|
-
color = options.
|
2963
|
+
let color = options.dataEleDecoratorNormalColor;
|
2964
|
+
if (this.element.dataEle.isMouseenter && options.dataEleDecoratorMouseEnterColor) {
|
2965
|
+
color = options.dataEleDecoratorMouseEnterColor;
|
2966
|
+
}
|
2967
|
+
if (this.element.dataEle.isFocused && options.dataEleDecoratorFocusedColor) {
|
2968
|
+
color = options.dataEleDecoratorFocusedColor;
|
2951
2969
|
}
|
2952
|
-
if (
|
2953
|
-
|
2970
|
+
if (!color) {
|
2971
|
+
return null;
|
2954
2972
|
}
|
2955
2973
|
const element = this.element;
|
2956
2974
|
const lineWidth = 3;
|
@@ -2971,6 +2989,37 @@ class DataDecorateRenderObject extends LeafRenderObject {
|
|
2971
2989
|
d: path
|
2972
2990
|
});
|
2973
2991
|
}
|
2992
|
+
exportDataGroupSVG(event) {
|
2993
|
+
const options = event.options;
|
2994
|
+
let color = options.dataGroupDecoratorNormalColor;
|
2995
|
+
if (this.element.dataEle.isMouseenter && options.dataGroupDecoratorMouseEnterColor) {
|
2996
|
+
color = options.dataGroupDecoratorMouseEnterColor;
|
2997
|
+
}
|
2998
|
+
if (this.element.dataEle.isFocused && options.dataGroupDecoratorFocusedColor) {
|
2999
|
+
color = options.dataGroupDecoratorFocusedColor;
|
3000
|
+
}
|
3001
|
+
if (!color) {
|
3002
|
+
return null;
|
3003
|
+
}
|
3004
|
+
const element = this.element;
|
3005
|
+
const lineWidth = 4;
|
3006
|
+
let path = '';
|
3007
|
+
const height = this.parent.rect.height - 4;
|
3008
|
+
if (element.isPrefix) {
|
3009
|
+
const x = this.rect.x + this.rect.width / 2;
|
3010
|
+
path = `M ${x + lineWidth} 2 L ${x} 2 L ${x} ${height} L ${x + lineWidth} ${height}`;
|
3011
|
+
}
|
3012
|
+
else {
|
3013
|
+
const x = this.rect.x + this.rect.width / 2;
|
3014
|
+
path = `M ${x - lineWidth} 2 L ${x} 2 L ${x} ${height} L ${x - lineWidth} ${height}`;
|
3015
|
+
}
|
3016
|
+
return ElementUtil.createSvgPath({
|
3017
|
+
stroke: color,
|
3018
|
+
fill: "none",
|
3019
|
+
'stroke-width': 2,
|
3020
|
+
d: path
|
3021
|
+
});
|
3022
|
+
}
|
2974
3023
|
}
|
2975
3024
|
|
2976
3025
|
function parser(code, objects) {
|
@@ -3452,6 +3501,7 @@ class DocumentElement extends BlockContainerElement {
|
|
3452
3501
|
footerElement;
|
3453
3502
|
//commentsContainerElement!: CommsContainerElement;
|
3454
3503
|
headerEditState = false;
|
3504
|
+
editorContext = null;
|
3455
3505
|
constructor() {
|
3456
3506
|
super('doc');
|
3457
3507
|
this.props = new DocumentProps();
|
@@ -3485,11 +3535,11 @@ class DocumentElement extends BlockContainerElement {
|
|
3485
3535
|
}
|
3486
3536
|
};
|
3487
3537
|
}
|
3488
|
-
clone() {
|
3538
|
+
clone(data) {
|
3489
3539
|
const clone = new DocumentElement();
|
3490
3540
|
this.props.clone(clone.props);
|
3491
3541
|
cloneElementBase(this, clone);
|
3492
|
-
cloneChildren(this, clone,
|
3542
|
+
cloneChildren(this, clone, data);
|
3493
3543
|
return clone;
|
3494
3544
|
}
|
3495
3545
|
/**
|
@@ -3525,7 +3575,7 @@ class DocumentElement extends BlockContainerElement {
|
|
3525
3575
|
this.headerEditState = false;
|
3526
3576
|
}
|
3527
3577
|
ss.clear();
|
3528
|
-
this.refreshView();
|
3578
|
+
//this.refreshView();
|
3529
3579
|
}
|
3530
3580
|
markPairs = [];
|
3531
3581
|
/**
|
@@ -3800,7 +3850,7 @@ class InlineGroupInputElement extends InlineGroupElement {
|
|
3800
3850
|
this.addEvent('ElementKeyDown', (evt) => {
|
3801
3851
|
const { selectionState, sourceEvent, source } = evt;
|
3802
3852
|
const { startControl, startOffset } = selectionState;
|
3803
|
-
if (
|
3853
|
+
if (IsInSideInlineGroupInputElement(startControl, startOffset)) {
|
3804
3854
|
if (sourceEvent.shiftKey && sourceEvent.keyCode === 13) ;
|
3805
3855
|
else if (!sourceEvent.shiftKey && sourceEvent.keyCode === 13) {
|
3806
3856
|
evt.isCancel = true;
|
@@ -3809,7 +3859,7 @@ class InlineGroupInputElement extends InlineGroupElement {
|
|
3809
3859
|
}, true);
|
3810
3860
|
this.addEvent('GotCursor', (evt) => {
|
3811
3861
|
const { startControl, startOffset } = evt.selectionState;
|
3812
|
-
if (
|
3862
|
+
if (IsInSideInlineGroupInputElement(startControl, startOffset)) {
|
3813
3863
|
this.isFocused = true;
|
3814
3864
|
}
|
3815
3865
|
});
|
@@ -3906,11 +3956,13 @@ class DataElementInlineGroup extends InlineGroupInputElement {
|
|
3906
3956
|
});
|
3907
3957
|
this.addEvent('ElementMousemove', (evt) => {
|
3908
3958
|
this.isMouseenter = true;
|
3909
|
-
|
3959
|
+
evt.ctx.refreshView();
|
3960
|
+
//this.refreshView();
|
3910
3961
|
});
|
3911
3962
|
this.addEvent('ElementMouseLeave', (evt) => {
|
3912
3963
|
this.isMouseenter = false;
|
3913
|
-
|
3964
|
+
evt.ctx.refreshView();
|
3965
|
+
//this.refreshView()
|
3914
3966
|
});
|
3915
3967
|
this.addEvent('GotCursor', (evt) => {
|
3916
3968
|
this.onGotCursorEvent(evt);
|
@@ -4050,21 +4102,10 @@ function getCurrOptions(ele) {
|
|
4050
4102
|
class DataElementRenderObject extends InlineGroupRenderObject {
|
4051
4103
|
exportSVG(event) {
|
4052
4104
|
const node = super.exportSVG(event);
|
4053
|
-
|
4105
|
+
exportDataEleDecoratorSVG$1(event, this);
|
4106
|
+
//绘制下划线
|
4054
4107
|
if (this.element.props.underline) {
|
4055
|
-
|
4056
|
-
event.highlights.push({
|
4057
|
-
sel: 'path',
|
4058
|
-
data: {
|
4059
|
-
ns: 'http://www.w3.org/2000/svg',
|
4060
|
-
attrs: {
|
4061
|
-
d: `M${x} ${y + this.rect.height} L${x + this.rect.width} ${y + this.rect.height}`,
|
4062
|
-
stroke: '#000',
|
4063
|
-
fill: 'none',
|
4064
|
-
'stroke-width': 1
|
4065
|
-
}
|
4066
|
-
}
|
4067
|
-
});
|
4108
|
+
renderUnderline(event, this);
|
4068
4109
|
}
|
4069
4110
|
renderErrorTip(event, this);
|
4070
4111
|
return node;
|
@@ -4127,7 +4168,7 @@ class DataElementBaseFactory extends ElementFactory {
|
|
4127
4168
|
* @param event
|
4128
4169
|
* @param r
|
4129
4170
|
*/
|
4130
|
-
function
|
4171
|
+
function exportDataEleDecoratorSVG$1(event, r) {
|
4131
4172
|
if (event.mode === 'print') {
|
4132
4173
|
return;
|
4133
4174
|
}
|
@@ -4143,6 +4184,9 @@ function exportDecoratorHTML(event, r) {
|
|
4143
4184
|
if (r.element.isFocused && options.dataEleFocusedBgColor) {
|
4144
4185
|
color = options.dataEleFocusedBgColor;
|
4145
4186
|
}
|
4187
|
+
if (!color) {
|
4188
|
+
return;
|
4189
|
+
}
|
4146
4190
|
//绘制背景
|
4147
4191
|
const bgX = event.relativePagePos.x;
|
4148
4192
|
const bgY = event.relativePagePos.y;
|
@@ -4311,6 +4355,21 @@ function renderUnderWavyLine(event, r, color) {
|
|
4311
4355
|
d += Array(Math.ceil(width / 3)).fill("3,0").join(' t ');
|
4312
4356
|
const path = ElementUtil.createSvgPath({ d, fill: 'none', stroke: color });
|
4313
4357
|
event.highlights.push(path);
|
4358
|
+
}
|
4359
|
+
function renderUnderline(event, render) {
|
4360
|
+
const { x, y } = event.relativePagePos;
|
4361
|
+
event.highlights.push({
|
4362
|
+
sel: 'path',
|
4363
|
+
data: {
|
4364
|
+
ns: 'http://www.w3.org/2000/svg',
|
4365
|
+
attrs: {
|
4366
|
+
d: `M${x} ${y + render.rect.height} L${x + render.rect.width} ${y + render.rect.height}`,
|
4367
|
+
stroke: '#000',
|
4368
|
+
fill: 'none',
|
4369
|
+
'stroke-width': 1
|
4370
|
+
}
|
4371
|
+
}
|
4372
|
+
});
|
4314
4373
|
}
|
4315
4374
|
|
4316
4375
|
class DocumentBodyElement extends BlockContainerElement {
|
@@ -5588,7 +5647,7 @@ class TableUtil {
|
|
5588
5647
|
if (startCell) {
|
5589
5648
|
this.restoreCellMerge(startCell);
|
5590
5649
|
ss.resetRange(startCell, 0);
|
5591
|
-
startCell.refreshView();
|
5650
|
+
//startCell.refreshView();
|
5592
5651
|
}
|
5593
5652
|
}
|
5594
5653
|
static restoreCellMerge(cell) {
|
@@ -5686,7 +5745,7 @@ class TableUtil {
|
|
5686
5745
|
tb.setCellWidth(insertColIndex === colsCount ? insertColIndex - 1 : insertColIndex, insertColWidth - newColWidth);
|
5687
5746
|
tb.insertCol(insertColIndex, newColWidth);
|
5688
5747
|
tb.pubOnChange('self');
|
5689
|
-
tb.refreshView();
|
5748
|
+
//tb.refreshView();
|
5690
5749
|
}
|
5691
5750
|
/**
|
5692
5751
|
* 在指定位置插入行
|
@@ -5715,7 +5774,7 @@ class TableUtil {
|
|
5715
5774
|
//新行插在第一行或者最后一行
|
5716
5775
|
if (insertRowIndex === 0 || insertRowIndex === tb.length) {
|
5717
5776
|
tb.addChild(newRow, insertRowIndex);
|
5718
|
-
tb.refreshView();
|
5777
|
+
//tb.refreshView();
|
5719
5778
|
return newRow;
|
5720
5779
|
}
|
5721
5780
|
const destRow = tb.getChild(insertRowIndex);
|
@@ -5734,7 +5793,7 @@ class TableUtil {
|
|
5734
5793
|
newCell.props.hMerge = destCell.props.hMerge;
|
5735
5794
|
}
|
5736
5795
|
tb.addChild(newRow, insertRowIndex);
|
5737
|
-
tb.refreshView();
|
5796
|
+
//tb.refreshView();
|
5738
5797
|
return newRow;
|
5739
5798
|
}
|
5740
5799
|
/**
|
@@ -5796,14 +5855,14 @@ class TableUtil {
|
|
5796
5855
|
const nextCell = this.getNextCell(ss);
|
5797
5856
|
if (nextCell) {
|
5798
5857
|
ss.resetRange(nextCell, 0);
|
5799
|
-
nextCell.refreshView();
|
5858
|
+
//nextCell.refreshView();
|
5800
5859
|
return;
|
5801
5860
|
}
|
5802
5861
|
//新增行,并定位
|
5803
5862
|
const tb = ElementUtil.getParentByType(startCell, TableElement);
|
5804
5863
|
const newRow = this.insertNewRow(tb, rowIndex + 1);
|
5805
5864
|
ss.resetRange(newRow, 0);
|
5806
|
-
newRow.refreshView();
|
5865
|
+
//newRow.refreshView();
|
5807
5866
|
}
|
5808
5867
|
/**
|
5809
5868
|
* 获取下一个可定位的单元格
|
@@ -5845,7 +5904,7 @@ class TableUtil {
|
|
5845
5904
|
console.warn('当前位置不存在表格');
|
5846
5905
|
return;
|
5847
5906
|
}
|
5848
|
-
tb.parent.refreshView();
|
5907
|
+
//tb.parent.refreshView();
|
5849
5908
|
tb.remove();
|
5850
5909
|
}
|
5851
5910
|
/**
|
@@ -5866,7 +5925,7 @@ class TableUtil {
|
|
5866
5925
|
else if (tc.props.diagonal === diagonal) {
|
5867
5926
|
tc.props.diagonal = null;
|
5868
5927
|
}
|
5869
|
-
tc.refreshView();
|
5928
|
+
//tc.refreshView();
|
5870
5929
|
}
|
5871
5930
|
/**
|
5872
5931
|
* 将当前表格截断成两个相邻的表格
|
@@ -6476,11 +6535,11 @@ class CommContentBaseElement extends BlockContainerElement {
|
|
6476
6535
|
super(type);
|
6477
6536
|
this.addEvent('GotCursor', () => {
|
6478
6537
|
this.focus = true;
|
6479
|
-
this.refreshView()
|
6538
|
+
//this.refreshView()
|
6480
6539
|
});
|
6481
6540
|
this.addEvent('LostCursor', () => {
|
6482
6541
|
this.focus = false;
|
6483
|
-
this.refreshView()
|
6542
|
+
//this.refreshView()
|
6484
6543
|
});
|
6485
6544
|
}
|
6486
6545
|
}
|
@@ -8689,11 +8748,13 @@ class DataElementGroupElement extends InlineGroupInputElement {
|
|
8689
8748
|
this.props = new DataElementGroupProps();
|
8690
8749
|
this.addEvent('ElementMousemove', (evt) => {
|
8691
8750
|
this.isMouseenter = true;
|
8692
|
-
this.refreshView();
|
8751
|
+
//this.refreshView();
|
8752
|
+
evt.ctx.refreshView();
|
8693
8753
|
});
|
8694
8754
|
this.addEvent('ElementMouseLeave', (evt) => {
|
8695
8755
|
this.isMouseenter = false;
|
8696
|
-
|
8756
|
+
evt.ctx.refreshView();
|
8757
|
+
//this.refreshView();
|
8697
8758
|
});
|
8698
8759
|
}
|
8699
8760
|
setValue(val) {
|
@@ -8709,13 +8770,15 @@ class DataElementGroupElement extends InlineGroupInputElement {
|
|
8709
8770
|
val += '';
|
8710
8771
|
}
|
8711
8772
|
if (val) {
|
8712
|
-
const items = val.split('
|
8773
|
+
const items = val.split('\n');
|
8713
8774
|
if (items.length) {
|
8714
8775
|
items.forEach((item, index) => {
|
8715
|
-
|
8716
|
-
|
8717
|
-
|
8718
|
-
|
8776
|
+
if (item) {
|
8777
|
+
const valueText = new TextGroupElement();
|
8778
|
+
this.props.valueTextProps.clone(valueText.props);
|
8779
|
+
valueText.text = item + '';
|
8780
|
+
this.addChild(valueText, this.length - 1);
|
8781
|
+
}
|
8719
8782
|
if (index < items.length - 1) {
|
8720
8783
|
const brElement = new BreakElement();
|
8721
8784
|
this.addChild(brElement, this.length - 1);
|
@@ -8754,6 +8817,15 @@ class DataElementGroupRenderObject extends InlineGroupRenderObject {
|
|
8754
8817
|
}
|
8755
8818
|
return cloneRender;
|
8756
8819
|
}
|
8820
|
+
exportSVG(event) {
|
8821
|
+
const node = super.exportSVG(event);
|
8822
|
+
exportDataEleDecoratorSVG(event, this);
|
8823
|
+
//绘制下划线
|
8824
|
+
if (this.element.props.underline) {
|
8825
|
+
renderUnderline(event, this);
|
8826
|
+
}
|
8827
|
+
return node;
|
8828
|
+
}
|
8757
8829
|
}
|
8758
8830
|
class DataElementGroupFactory extends DataElementBaseFactory {
|
8759
8831
|
match(type) {
|
@@ -8792,6 +8864,35 @@ function IsInSideDataGroup(control, offset) {
|
|
8792
8864
|
}
|
8793
8865
|
function validateDataGroup(control) {
|
8794
8866
|
return control instanceof DataElementGroupElement;
|
8867
|
+
}
|
8868
|
+
/**
|
8869
|
+
* 渲染数据元背景修饰
|
8870
|
+
* @param event
|
8871
|
+
* @param r
|
8872
|
+
*/
|
8873
|
+
function exportDataEleDecoratorSVG(event, r) {
|
8874
|
+
if (event.mode === 'print') {
|
8875
|
+
return;
|
8876
|
+
}
|
8877
|
+
const options = event.options;
|
8878
|
+
let color = options.dataGroupNormalBgColor;
|
8879
|
+
//空数据元填充颜色
|
8880
|
+
if (r.element.length === 2 && options.dataGroupEmptyBgColor) {
|
8881
|
+
color = options.dataGroupEmptyBgColor;
|
8882
|
+
}
|
8883
|
+
if (r.element.isMouseenter && options.dataGroupMouseEnterBgColor) {
|
8884
|
+
color = options.dataGroupMouseEnterBgColor;
|
8885
|
+
}
|
8886
|
+
if (r.element.isFocused && options.dataGroupFocusedBgColor) {
|
8887
|
+
color = options.dataGroupFocusedBgColor;
|
8888
|
+
}
|
8889
|
+
if (!color) {
|
8890
|
+
return;
|
8891
|
+
}
|
8892
|
+
//绘制背景
|
8893
|
+
const bgX = event.relativePagePos.x;
|
8894
|
+
const bgY = event.relativePagePos.y;
|
8895
|
+
event.highlights.push(ElementUtil.getFillSvgRect(bgX, bgY, r.rect.width, r.rect.height, color));
|
8795
8896
|
}
|
8796
8897
|
|
8797
8898
|
class DataElementImage extends DataElementLeaf {
|
@@ -9073,13 +9174,15 @@ class DataElementText extends DataElementInlineGroup {
|
|
9073
9174
|
val += '';
|
9074
9175
|
}
|
9075
9176
|
if (val) {
|
9076
|
-
const items = val.split('
|
9177
|
+
const items = val.split('\n');
|
9077
9178
|
if (items.length) {
|
9078
9179
|
items.forEach((item, index) => {
|
9079
|
-
|
9080
|
-
|
9081
|
-
|
9082
|
-
|
9180
|
+
if (item) {
|
9181
|
+
const valueText = new TextGroupElement();
|
9182
|
+
this.props.valueTextProps.clone(valueText.props);
|
9183
|
+
valueText.text = item + '';
|
9184
|
+
this.addChild(valueText, this.length - 1);
|
9185
|
+
}
|
9083
9186
|
if (index < items.length - 1) {
|
9084
9187
|
const brElement = new BreakElement();
|
9085
9188
|
this.addChild(brElement, this.length - 1);
|
@@ -9147,11 +9250,13 @@ class DataContainerElement extends BlockContainerElement {
|
|
9147
9250
|
this.props = new DataContainerProps();
|
9148
9251
|
this.addEvent('GotCursor', (evt) => {
|
9149
9252
|
this.isFocused = true;
|
9150
|
-
|
9253
|
+
evt.ctx.refreshView();
|
9254
|
+
//this.refreshView();
|
9151
9255
|
});
|
9152
9256
|
this.addEvent('LostCursor', (evt) => {
|
9153
9257
|
this.isFocused = false;
|
9154
|
-
|
9258
|
+
evt.ctx.refreshView();
|
9259
|
+
//this.refreshView();
|
9155
9260
|
});
|
9156
9261
|
}
|
9157
9262
|
createRenderObject() {
|
@@ -9266,19 +9371,23 @@ class DocumentBodyPartElement extends BlockContainerElement {
|
|
9266
9371
|
super('body-part');
|
9267
9372
|
this.addEvent('ElementMousemove', (evt) => {
|
9268
9373
|
this.isMouseenter = true;
|
9269
|
-
|
9374
|
+
evt.ctx.refreshView();
|
9375
|
+
//this.refreshView();
|
9270
9376
|
});
|
9271
9377
|
this.addEvent('ElementMouseLeave', (evt) => {
|
9272
9378
|
this.isMouseenter = false;
|
9273
|
-
|
9379
|
+
evt.ctx.refreshView();
|
9380
|
+
//this.refreshView();
|
9274
9381
|
});
|
9275
9382
|
this.addEvent('GotCursor', (evt) => {
|
9276
9383
|
this.isFocused = true;
|
9277
|
-
|
9384
|
+
evt.ctx.refreshView();
|
9385
|
+
//this.refreshView();
|
9278
9386
|
});
|
9279
9387
|
this.addEvent('LostCursor', (evt) => {
|
9280
9388
|
this.isFocused = false;
|
9281
|
-
|
9389
|
+
evt.ctx.refreshView();
|
9390
|
+
//this.refreshView();
|
9282
9391
|
});
|
9283
9392
|
this.props = new BodyPartProps();
|
9284
9393
|
}
|
@@ -10192,7 +10301,7 @@ class TableSplitCell {
|
|
10192
10301
|
}
|
10193
10302
|
}
|
10194
10303
|
tb.pubOnChange('self');
|
10195
|
-
tb.refreshView();
|
10304
|
+
//tb.refreshView();
|
10196
10305
|
}
|
10197
10306
|
/**
|
10198
10307
|
* 拆分合并的单元格
|
@@ -10299,7 +10408,7 @@ class TableSplitCell {
|
|
10299
10408
|
}
|
10300
10409
|
}
|
10301
10410
|
tb.pubOnChange('to-child');
|
10302
|
-
tb.refreshView();
|
10411
|
+
//tb.refreshView();
|
10303
10412
|
return {
|
10304
10413
|
startColIndex: focusCellIndex,
|
10305
10414
|
endColIndex: focusCellIndex + cols - 1
|
@@ -10329,7 +10438,7 @@ class TableSplitCell {
|
|
10329
10438
|
TableUtil.restoreCell(ss);
|
10330
10439
|
this.applyHorSplitColumnCurrPatchPacks(tb, focusRowIndex, focusCellIndex, rows, currPacks);
|
10331
10440
|
tb.pubOnChange('to-child');
|
10332
|
-
tb.refreshView();
|
10441
|
+
//tb.refreshView();
|
10333
10442
|
return {
|
10334
10443
|
startColIndex: focusCellIndex,
|
10335
10444
|
endColIndex: this.getPrepareNewColCounts(otherPacks, hMergeCols)
|
@@ -10697,6 +10806,9 @@ class ElementSerialize {
|
|
10697
10806
|
if (element instanceof PSymbolElement) {
|
10698
10807
|
return '\n';
|
10699
10808
|
}
|
10809
|
+
if (element instanceof BreakElement) {
|
10810
|
+
return '\n';
|
10811
|
+
}
|
10700
10812
|
if (element instanceof BranchElement) {
|
10701
10813
|
const items = [];
|
10702
10814
|
for (let i = 0; i < element.length; i++) {
|
@@ -13245,6 +13357,7 @@ class EditorContext {
|
|
13245
13357
|
//suggestionsList: Array<ISuggestionData> = [];
|
13246
13358
|
//currentSuggestionsList: Array<ISuggestionData> = [];
|
13247
13359
|
suggestions = new DocInputSuggestions();
|
13360
|
+
//editor->this->others
|
13248
13361
|
onKeyDownEvent = new Subject();
|
13249
13362
|
constructor(selectionState, viewOptions) {
|
13250
13363
|
this.selectionState = selectionState;
|
@@ -13254,6 +13367,16 @@ class EditorContext {
|
|
13254
13367
|
this.syncRefresh?.();
|
13255
13368
|
});
|
13256
13369
|
}
|
13370
|
+
/**
|
13371
|
+
* 刷新视图
|
13372
|
+
*/
|
13373
|
+
refreshView() {
|
13374
|
+
this.syncRefresh?.();
|
13375
|
+
}
|
13376
|
+
/**
|
13377
|
+
* 编辑器文档刷新后回调(DOM渲染完成后回调)
|
13378
|
+
* @param cb
|
13379
|
+
*/
|
13257
13380
|
onNextView(cb) {
|
13258
13381
|
if (!cb) {
|
13259
13382
|
this.nextViewFns.length = 0;
|
@@ -13268,25 +13391,27 @@ class EditorContext {
|
|
13268
13391
|
set document(value) {
|
13269
13392
|
this.clearPrevDocCb?.();
|
13270
13393
|
this._document = value;
|
13394
|
+
this._document['editorContext'] = this;
|
13271
13395
|
// this.refSub = this._document.refreshSubject.subscribe((data) => {
|
13272
13396
|
// data = data ?? 'content';
|
13273
13397
|
// this.isDirty = this.isDirty || data === 'content';
|
13274
13398
|
// this.syncRefresh?.(data);
|
13275
13399
|
// });
|
13276
|
-
const docRefreshSub = this._document.refreshSubject.subscribe(() => {
|
13277
|
-
|
13278
|
-
});
|
13400
|
+
// const docRefreshSub = this._document.refreshSubject.subscribe(() => {
|
13401
|
+
// this.syncRefresh?.();
|
13402
|
+
// });
|
13279
13403
|
const docChangedSub = this._document.onChangeSubject.subscribe(() => {
|
13280
13404
|
this.syncRefresh?.();
|
13281
13405
|
});
|
13282
13406
|
this.syncRefresh();
|
13283
13407
|
this.clearPrevDocCb = () => {
|
13284
|
-
docRefreshSub.unsubscribe();
|
13408
|
+
//docRefreshSub.unsubscribe();
|
13285
13409
|
docChangedSub.unsubscribe();
|
13286
13410
|
if (this._document) {
|
13287
13411
|
this.selectionState?.renderContainer?.destroy();
|
13288
13412
|
this.clear();
|
13289
13413
|
this._document.destroy();
|
13414
|
+
this._document.editorContext = null;
|
13290
13415
|
clearTraces(this._document);
|
13291
13416
|
}
|
13292
13417
|
this.clearPrevDocCb = null;
|
@@ -13297,6 +13422,7 @@ class EditorContext {
|
|
13297
13422
|
this.selectionState.clear();
|
13298
13423
|
this.isDirty = false;
|
13299
13424
|
this.suggestions.clear();
|
13425
|
+
this.currentOpsLog.length = 0;
|
13300
13426
|
//this.clearEleDepMaps();
|
13301
13427
|
}
|
13302
13428
|
get defaultCtx() {
|
@@ -13339,6 +13465,7 @@ class EditorContext {
|
|
13339
13465
|
//this.ele_types_handlers.length = 0;
|
13340
13466
|
//this.imageLoader.clear();
|
13341
13467
|
this._document = null;
|
13468
|
+
this.currentOpsLog.length = 0;
|
13342
13469
|
this.suggestions.destroy();
|
13343
13470
|
}
|
13344
13471
|
/**
|
@@ -13361,11 +13488,13 @@ class EditorContext {
|
|
13361
13488
|
oldDataElement.remove();
|
13362
13489
|
}
|
13363
13490
|
currentRefreshType = null;
|
13491
|
+
//当前操作日志
|
13492
|
+
currentOpsLog = [];
|
13364
13493
|
get refreshType() {
|
13365
|
-
if (!this._document) {
|
13494
|
+
if (!this._document || this._document.modifyFlag === ModifyFlag.None) {
|
13366
13495
|
return null;
|
13367
13496
|
}
|
13368
|
-
return this._document.modifyFlag === ModifyFlag.
|
13497
|
+
return this._document.modifyFlag === ModifyFlag.Track ? 'appearance' : 'content';
|
13369
13498
|
}
|
13370
13499
|
adaptiveScale() {
|
13371
13500
|
if (this.viewOptions.pageLayoutMode !== 'fit-page') {
|
@@ -13641,6 +13770,18 @@ class DocumentContext {
|
|
13641
13770
|
}
|
13642
13771
|
return arr;
|
13643
13772
|
}
|
13773
|
+
}
|
13774
|
+
function refreshEditor(ele) {
|
13775
|
+
const doc = ElementUtil.getParent(ele, e => e.type === 'doc');
|
13776
|
+
if (doc) {
|
13777
|
+
const editorCtx = doc['editorContext'];
|
13778
|
+
if (editorCtx) {
|
13779
|
+
editorCtx.refreshView();
|
13780
|
+
}
|
13781
|
+
else {
|
13782
|
+
console.warn("doc.editorContext is null,不能刷新!");
|
13783
|
+
}
|
13784
|
+
}
|
13644
13785
|
}
|
13645
13786
|
|
13646
13787
|
class DynamicExecute {
|
@@ -15171,6 +15312,83 @@ class DocumentArrange {
|
|
15171
15312
|
tmp.props.lineHeight = this.options.defaultLineHeight;
|
15172
15313
|
return tmp;
|
15173
15314
|
}
|
15315
|
+
patchParagraph() {
|
15316
|
+
if (!this.options.enableFastMeasure) {
|
15317
|
+
return false;
|
15318
|
+
}
|
15319
|
+
this.pMeasure = new ParagraphMeasure(this.options, this.renderCtx, this.execute);
|
15320
|
+
const ops = this.docCtx.currentOpsLog;
|
15321
|
+
if (!ops.length) {
|
15322
|
+
return false;
|
15323
|
+
}
|
15324
|
+
if (ops.every(op => 'delText' in op.ops || 'insText' in op.ops || ('insert' in op.ops && op.ops.insert.type === 'text'))) {
|
15325
|
+
const parentIndex = ops[0].parentIndex;
|
15326
|
+
//查找父容器
|
15327
|
+
const parentEle = ElementUtil.getControlByIndex(this.docCtx.document, { currIndex: -1, index: parentIndex }, true);
|
15328
|
+
const paraEle = ElementUtil.getParent(parentEle, item => item instanceof ParagraphElement);
|
15329
|
+
if (!paraEle) {
|
15330
|
+
return false;
|
15331
|
+
}
|
15332
|
+
const cacheRender = paraEle.cacheRender;
|
15333
|
+
if (!cacheRender) {
|
15334
|
+
return false;
|
15335
|
+
}
|
15336
|
+
//已经绘制的渲染对象
|
15337
|
+
const paintRenders = paraEle.paintRenders;
|
15338
|
+
const measureParaRenders = this.pMeasure.measureParagraph(paraEle, cacheRender.rect.width);
|
15339
|
+
if (measureParaRenders.length !== 1) {
|
15340
|
+
return false;
|
15341
|
+
}
|
15342
|
+
const measureParaRender = measureParaRenders[0];
|
15343
|
+
if (cacheRender.rect.width !== measureParaRender.rect.width || cacheRender.rect.height !== measureParaRender.rect.height) {
|
15344
|
+
return false;
|
15345
|
+
}
|
15346
|
+
//第一种情况,出现在页面或者页尾上
|
15347
|
+
const measureParaRenderLines = measureParaRender.length;
|
15348
|
+
const paintRendersLines = paintRenders.reduce((prev, curr) => {
|
15349
|
+
prev.push(...curr.getItems());
|
15350
|
+
return prev;
|
15351
|
+
}, []);
|
15352
|
+
if (paintRendersLines.length % measureParaRenderLines !== 0) {
|
15353
|
+
return false;
|
15354
|
+
}
|
15355
|
+
//完全一致,逐个替换
|
15356
|
+
if (paintRendersLines.length === measureParaRenderLines) {
|
15357
|
+
for (let i = 0; i < paintRendersLines.length; i++) {
|
15358
|
+
const line = paintRendersLines[i];
|
15359
|
+
const index = line.getIndex();
|
15360
|
+
const tempLine = measureParaRender.getChild(i).clone();
|
15361
|
+
tempLine.rect.width = line.rect.width;
|
15362
|
+
tempLine.rect.height = line.rect.height;
|
15363
|
+
tempLine.rect.x = line.rect.x;
|
15364
|
+
tempLine.rect.y = line.rect.y;
|
15365
|
+
line.parent.insertChild(tempLine, index);
|
15366
|
+
line.parent.removeChild(line);
|
15367
|
+
}
|
15368
|
+
return true;
|
15369
|
+
}
|
15370
|
+
}
|
15371
|
+
return false;
|
15372
|
+
}
|
15373
|
+
fastPatchReset(docRenders) {
|
15374
|
+
//测量阶段,对于空段落会插入段落符号,新表格会插入空段落,此时不需要记录节点的更改,以最大的节点进行记录
|
15375
|
+
return suppressTracking(() => {
|
15376
|
+
const doc = this.docCtx.document;
|
15377
|
+
this.execute = new DynamicExecute(doc, this.docCtx.selectionState);
|
15378
|
+
this.pMeasure = new ParagraphMeasure(this.options, this.renderCtx, this.execute);
|
15379
|
+
const data = {
|
15380
|
+
doc,
|
15381
|
+
options: this.options,
|
15382
|
+
execute: this.execute,
|
15383
|
+
renderCtx: this.renderCtx,
|
15384
|
+
createParaFn: () => this.createDefaultPara()
|
15385
|
+
};
|
15386
|
+
this.reset(data);
|
15387
|
+
this.setMeasureCompletedModifyFlag(doc);
|
15388
|
+
this.cacheDocRenders(docRenders);
|
15389
|
+
this.generateCommRange();
|
15390
|
+
});
|
15391
|
+
}
|
15174
15392
|
}
|
15175
15393
|
|
15176
15394
|
/**
|
@@ -15198,7 +15416,12 @@ class DocumentPaginator {
|
|
15198
15416
|
this.docCtx.selectionState.renderContainer = this.docContainer;
|
15199
15417
|
this.docContainer.rect.width = this.viewOptions.docPageSettings.width;
|
15200
15418
|
const newMeasure = new DocumentArrange(this.docCtx, this.renderContext, this.seo);
|
15201
|
-
|
15419
|
+
if (newMeasure.patchParagraph()) {
|
15420
|
+
newMeasure.fastPatchReset(this.docPages);
|
15421
|
+
}
|
15422
|
+
else {
|
15423
|
+
this.docPages = newMeasure.measureDoc();
|
15424
|
+
}
|
15202
15425
|
this.adjustTipLayoutWidth();
|
15203
15426
|
this.layoutPages();
|
15204
15427
|
}
|
@@ -20668,7 +20891,7 @@ class DocEditor {
|
|
20668
20891
|
},
|
20669
20892
|
on: {
|
20670
20893
|
resize: () => {
|
20671
|
-
console.log('resize')
|
20894
|
+
//console.log('resize')
|
20672
20895
|
}
|
20673
20896
|
}
|
20674
20897
|
},
|
@@ -20686,10 +20909,13 @@ class DocEditor {
|
|
20686
20909
|
const target = evt.target;
|
20687
20910
|
this.viewOptions.pageOffset.x = target.scrollLeft;
|
20688
20911
|
this.viewOptions.pageOffset.y = target.scrollTop;
|
20689
|
-
this.onChange();
|
20912
|
+
//this.onChange();
|
20913
|
+
//滚动的时候,不需要重新计算元素
|
20914
|
+
//只需要重新渲染vnode即可
|
20915
|
+
this.onPatchVNodeSubject.next();
|
20690
20916
|
},
|
20691
20917
|
resize: () => {
|
20692
|
-
console.log('resize')
|
20918
|
+
//console.log('resize')
|
20693
20919
|
}
|
20694
20920
|
},
|
20695
20921
|
hook: {
|
@@ -20752,12 +20978,12 @@ class DocEditor {
|
|
20752
20978
|
this.refreshDocument();
|
20753
20979
|
this.flushTask = null;
|
20754
20980
|
//回调
|
20755
|
-
let cbs = [...this.docCtx.nextViewFns];
|
20756
|
-
if (cbs.length) {
|
20757
|
-
|
20758
|
-
|
20759
|
-
|
20760
|
-
}
|
20981
|
+
// let cbs = [...this.docCtx.nextViewFns];
|
20982
|
+
// if (cbs.length) {
|
20983
|
+
// this.docCtx.onNextView(null);
|
20984
|
+
// cbs.forEach(cb => cb());
|
20985
|
+
// return;
|
20986
|
+
// }
|
20761
20987
|
this.historyMange.generateTrack();
|
20762
20988
|
this.historyMange.generateSelectionLog();
|
20763
20989
|
};
|
@@ -20807,9 +21033,9 @@ class DocEditor {
|
|
20807
21033
|
* @returns
|
20808
21034
|
*/
|
20809
21035
|
refreshDocument() {
|
20810
|
-
if (this.docCtx.refreshType === null) {
|
20811
|
-
|
20812
|
-
}
|
21036
|
+
// if (this.docCtx.refreshType === null) {
|
21037
|
+
// return;
|
21038
|
+
// }
|
20813
21039
|
this.docCtx.currentRefreshType = this.docCtx.refreshType;
|
20814
21040
|
if (this.docCtx.currentRefreshType) {
|
20815
21041
|
this.onBeforeRefreshDocument.next();
|
@@ -21690,6 +21916,7 @@ class DocEditor {
|
|
21690
21916
|
this.vNodeDocContent = this.nodePatch(this.svgContainer, vNode);
|
21691
21917
|
}
|
21692
21918
|
this.afterNodePatch.next();
|
21919
|
+
this.onNextView();
|
21693
21920
|
//console.timeEnd('patch');
|
21694
21921
|
};
|
21695
21922
|
render();
|
@@ -21700,6 +21927,13 @@ class DocEditor {
|
|
21700
21927
|
render();
|
21701
21928
|
}, 32));
|
21702
21929
|
}
|
21930
|
+
onNextView() {
|
21931
|
+
let cbs = [...this.docCtx.nextViewFns];
|
21932
|
+
if (cbs.length) {
|
21933
|
+
this.docCtx.onNextView();
|
21934
|
+
cbs.forEach(cb => cb());
|
21935
|
+
}
|
21936
|
+
}
|
21703
21937
|
/**
|
21704
21938
|
* 留痕提示的容器框,用于渲染后重新计算纵向位置
|
21705
21939
|
* @private
|
@@ -22055,7 +22289,7 @@ class DocEditor {
|
|
22055
22289
|
rule.setRuleOptions({ width: this.viewOptions.docPageSettings.width, pagePL, pagePR, docLeft });
|
22056
22290
|
}
|
22057
22291
|
version() {
|
22058
|
-
return "2.2.
|
22292
|
+
return "2.2.16";
|
22059
22293
|
}
|
22060
22294
|
switchPageHeaderEditor() {
|
22061
22295
|
this.docCtx.document.switchPageHeaderEditor(this.selectionState, null);
|
@@ -22138,6 +22372,7 @@ class DocEditor {
|
|
22138
22372
|
readDocChangeLog() {
|
22139
22373
|
//获取文档的变更日志
|
22140
22374
|
const ops = generatePatch(this.docCtx.document, false);
|
22375
|
+
this.docCtx.currentOpsLog = [...ops];
|
22141
22376
|
//1.处理批注删除不对称的问题
|
22142
22377
|
for (let i = 0; i < ops.length; i++) {
|
22143
22378
|
const op = ops[i];
|
@@ -22393,7 +22628,7 @@ class DocumentCombine {
|
|
22393
22628
|
* 用于合并文档计算
|
22394
22629
|
*/
|
22395
22630
|
load() {
|
22396
|
-
const template = this.mainTemplate.clone();
|
22631
|
+
const template = this.mainTemplate.clone(true);
|
22397
22632
|
const body = template.find((item) => item instanceof DocumentBodyElement);
|
22398
22633
|
body.clearItems();
|
22399
22634
|
for (let i = 0; i < this.docParts.length; i++) {
|
@@ -27755,13 +27990,13 @@ const onTableContextmenu = (evt) => {
|
|
27755
27990
|
evt.menus.push({
|
27756
27991
|
caption: '上方插入段落', click: () => {
|
27757
27992
|
currentElement.parent.addChild(ParagraphElement.createElement(), currentElement.getIndex());
|
27758
|
-
currentElement.refreshView()
|
27993
|
+
//currentElement.refreshView()
|
27759
27994
|
}
|
27760
27995
|
});
|
27761
27996
|
evt.menus.push({
|
27762
27997
|
caption: '下方插入段落', click: () => {
|
27763
27998
|
currentElement.parent.addChild(ParagraphElement.createElement(), currentElement.getIndex() + 1);
|
27764
|
-
currentElement.refreshView()
|
27999
|
+
//currentElement.refreshView()
|
27765
28000
|
}
|
27766
28001
|
});
|
27767
28002
|
evt.menus = removeDuplicatesEvent(evt.menus);
|
@@ -27777,5 +28012,5 @@ function removeDuplicatesEvent(events) {
|
|
27777
28012
|
return arr;
|
27778
28013
|
}
|
27779
28014
|
|
27780
|
-
export { BlockContainerElement, BlockContainerRenderObject, BlockContentElement, BlockContentRenderObject, BlockLineRectRenderObject, BodyPartProps, BooleanEnum, BorderProps, BranchElement, BranchRenderObject, BreakElement, BreakFactory, BreakRenderObject, CheckBoxElement, CheckBoxFactory, CheckBoxProps, CheckBoxRenderObject, ColumnPatchUtil, CommContentBaseElement, CommContentBaseRenderObject, CommContentElement, CommContentProps, CommContentRenderObject, CommProps, CommentContentFactory, CommentElement, CommentFactory, CommentRenderObject, CommentsFactory, CommonUtil, CommsContainerElement, CommsContainerRenderObject, ContentMenuItem, ContextMenuElementEvent, CopyElementEvent, DOMEventSource, DOMSubscription, DataContainerElement, DataContainerFactory, DataContainerProps, DataContainerRenderObject, DataDecorateElement, DataDecorateProps, DataDecorateRenderObject, DataEleBaseProps, DataEleBaseTextProps, DataEleCheckProps, DataEleDateProps, DataEleImageProps, DataEleListProps, DataEleMHProps, DataElementBarcode, DataElementBarcodeFactory, DataElementBarcodeProps, DataElementBarcodeRenderObject, DataElementBaseFactory, DataElementCheck, DataElementCheckFactory, DataElementCheckRenderObject, DataElementDate, DataElementDateFactory, DataElementDateRenderObject, DataElementGroupElement, DataElementGroupFactory, DataElementGroupProps, DataElementGroupRenderObject, DataElementImage, DataElementImgFactory, DataElementInlineGroup, DataElementLeaf, DataElementList, DataElementListFactory, DataElementListRenderObject, DataElementMH, DataElementMHFactory, DataElementRenderObject, DataElementText, DataElementTextFactory, DataElementTextRenderObject, DataImageRenderObject, DataRenderMH, DocEditor, DocInputSuggestions, DocMode, DocumentBodyElement, DocumentBodyFactory, DocumentBodyPartElement, DocumentBodyPartFactory, DocumentBodyPartRenderObject, DocumentBodyRenderObject, DocumentChange, DocumentCombine, DocumentComment, DocumentContainerRender, DocumentContext, DocumentCursor, DocumentElement, DocumentEvalFunc, DocumentEvent, DocumentFactory, DocumentFooterElement, DocumentFooterFactory, DocumentFooterRenderObject, DocumentHeaderElement, DocumentHeaderFactory, DocumentHeaderRenderObject, DocumentInput, DocumentPaginator, DocumentPrintOffscreen, DocumentPrintOffscreenBase, DocumentProps, DocumentRenderObject, DocumentSelection, DocumentTemplate, DropElementEvent, EditMode, EditorContext, Element, ElementEvent, ElementFactory, ElementReader, ElementSerialize, ElementUtil, EventBus, EventMap, EventSourceCore, FillNullSpaceElement, FillNullSpaceRenderObject, GetTrackTipsEvent, GotCursorEvent, IDispose, INotifyPropertyChanged, InlineBlockContainer, InlineGroupElement, InlineGroupInputElement, InlineGroupRenderObject, InlineMuiltBlockLineRenderObject, InputElementEvent, IsInSideDataElement, IsInSideDataGroup, IsInSideInlineGroupInputElement, KeyboradElementEvent, LeafElement, LeafRenderObject, LostCursorEvent, MarginProps, ModifyFlag, MouseElementEvent, MousedownElementEvent, MultiBlockLineRenderObject, OnceSubject, PSymbolElement, PSymbolRenderObject, PaddingProps, PageBreakElement, PageBreakFactory, PageBreakRenderObject, PageOptions, PaintContent, ParagraphElement, ParagraphFactory, ParagraphLineRectRenderObject, ParagraphNumberType, ParagraphProps, ParagraphRenderObject, PasteElementEvent, PermanentTeethElement, PermanentTeethFactory, PermanentTeethProps, PermanentTeethRenderObject, PictureElement, PictureFactory, PictureProps, PictureRenderObject, RadioBoxElement, RadioBoxFactory, RadioBoxProps, RadioBoxRenderObject, RangeUtil, Rect, RenderContext, RenderObject, RenderObjectType, ResizeLeafRenderObject, RowMinHeight, RunElementFactory, SVGElement, SVGFactory, SVGProps, SVGRenderObject, SelectionOverlays, SelectionRange, SelectionState, Subject, SubjectSubscription, Subscription, TEXT_HEIGHT_FACTOR, TabElement, TabFactory, TabRenderObject, TableCellElement, TableCellFactory, TableCellProps, TableCellRenderObject, TableElement, TableFactory, TableProps, TableRenderObject, TableRowElement, TableRowFactory, TableRowProps, TableRowRenderObject, TableSplitCell, TableUtil, TextGroupElement, TextGroupFactory, TextGroupRenderObject, TextProps, TextUnitsHolder, TrackRunElement, TrackRunProps, TrackRunRenderObject, TrackRunTypeEnum, ValidateCondition, ValidateElement, ValidateProps, ValidateRenderObject, ViewOptions, addReturn, clearChildrenRenderCache, clearTraces, cloneChildren, cloneElementBase, defaultParaHanging, deleteCurrentParagraph, docOpsMap, elementTypeEventHandler,
|
28015
|
+
export { BlockContainerElement, BlockContainerRenderObject, BlockContentElement, BlockContentRenderObject, BlockLineRectRenderObject, BodyPartProps, BooleanEnum, BorderProps, BranchElement, BranchRenderObject, BreakElement, BreakFactory, BreakRenderObject, CheckBoxElement, CheckBoxFactory, CheckBoxProps, CheckBoxRenderObject, ColumnPatchUtil, CommContentBaseElement, CommContentBaseRenderObject, CommContentElement, CommContentProps, CommContentRenderObject, CommProps, CommentContentFactory, CommentElement, CommentFactory, CommentRenderObject, CommentsFactory, CommonUtil, CommsContainerElement, CommsContainerRenderObject, ContentMenuItem, ContextMenuElementEvent, CopyElementEvent, DOMEventSource, DOMSubscription, DataContainerElement, DataContainerFactory, DataContainerProps, DataContainerRenderObject, DataDecorateElement, DataDecorateProps, DataDecorateRenderObject, DataEleBaseProps, DataEleBaseTextProps, DataEleCheckProps, DataEleDateProps, DataEleImageProps, DataEleListProps, DataEleMHProps, DataElementBarcode, DataElementBarcodeFactory, DataElementBarcodeProps, DataElementBarcodeRenderObject, DataElementBaseFactory, DataElementCheck, DataElementCheckFactory, DataElementCheckRenderObject, DataElementDate, DataElementDateFactory, DataElementDateRenderObject, DataElementGroupElement, DataElementGroupFactory, DataElementGroupProps, DataElementGroupRenderObject, DataElementImage, DataElementImgFactory, DataElementInlineGroup, DataElementLeaf, DataElementList, DataElementListFactory, DataElementListRenderObject, DataElementMH, DataElementMHFactory, DataElementRenderObject, DataElementText, DataElementTextFactory, DataElementTextRenderObject, DataImageRenderObject, DataRenderMH, DocEditor, DocInputSuggestions, DocMode, DocumentBodyElement, DocumentBodyFactory, DocumentBodyPartElement, DocumentBodyPartFactory, DocumentBodyPartRenderObject, DocumentBodyRenderObject, DocumentChange, DocumentCombine, DocumentComment, DocumentContainerRender, DocumentContext, DocumentCursor, DocumentElement, DocumentEvalFunc, DocumentEvent, DocumentFactory, DocumentFooterElement, DocumentFooterFactory, DocumentFooterRenderObject, DocumentHeaderElement, DocumentHeaderFactory, DocumentHeaderRenderObject, DocumentInput, DocumentPaginator, DocumentPrintOffscreen, DocumentPrintOffscreenBase, DocumentProps, DocumentRenderObject, DocumentSelection, DocumentTemplate, DropElementEvent, EditMode, EditorContext, Element, ElementEvent, ElementFactory, ElementReader, ElementSerialize, ElementUtil, EventBus, EventMap, EventSourceCore, FillNullSpaceElement, FillNullSpaceRenderObject, GetTrackTipsEvent, GotCursorEvent, IDispose, INotifyPropertyChanged, InlineBlockContainer, InlineGroupElement, InlineGroupInputElement, InlineGroupRenderObject, InlineMuiltBlockLineRenderObject, InputElementEvent, IsInSideDataElement, IsInSideDataGroup, IsInSideInlineGroupInputElement, KeyboradElementEvent, LeafElement, LeafRenderObject, LostCursorEvent, MarginProps, ModifyFlag, MouseElementEvent, MousedownElementEvent, MultiBlockLineRenderObject, OnceSubject, PSymbolElement, PSymbolRenderObject, PaddingProps, PageBreakElement, PageBreakFactory, PageBreakRenderObject, PageOptions, PaintContent, ParagraphElement, ParagraphFactory, ParagraphLineRectRenderObject, ParagraphNumberType, ParagraphProps, ParagraphRenderObject, PasteElementEvent, PermanentTeethElement, PermanentTeethFactory, PermanentTeethProps, PermanentTeethRenderObject, PictureElement, PictureFactory, PictureProps, PictureRenderObject, RadioBoxElement, RadioBoxFactory, RadioBoxProps, RadioBoxRenderObject, RangeUtil, Rect, RenderContext, RenderObject, RenderObjectType, ResizeLeafRenderObject, RowMinHeight, RunElementFactory, SVGElement, SVGFactory, SVGProps, SVGRenderObject, SelectionOverlays, SelectionRange, SelectionState, Subject, SubjectSubscription, Subscription, TEXT_HEIGHT_FACTOR, TabElement, TabFactory, TabRenderObject, TableCellElement, TableCellFactory, TableCellProps, TableCellRenderObject, TableElement, TableFactory, TableProps, TableRenderObject, TableRowElement, TableRowFactory, TableRowProps, TableRowRenderObject, TableSplitCell, TableUtil, TextGroupElement, TextGroupFactory, TextGroupRenderObject, TextProps, TextUnitsHolder, TrackRunElement, TrackRunProps, TrackRunRenderObject, TrackRunTypeEnum, ValidateCondition, ValidateElement, ValidateProps, ValidateRenderObject, ViewOptions, addReturn, clearChildrenRenderCache, clearTraces, cloneChildren, cloneElementBase, defaultParaHanging, deleteCurrentParagraph, docOpsMap, elementTypeEventHandler, exportDataEleDecoratorSVG$1 as exportDataEleDecoratorSVG, falseChar, fontMapFunc, formatEle, fromEvent, generatePatch, getCalleeName, getFocusTextSegment, inputText, insertEle, invokeTypeHandler, isDate, logUpdateEleProps, objectToString$4 as objectToString, onTableContextmenu, onceTask, parser, reactiveMap, refreshEditor, removeEle, removeText, renderErrorTip, renderUnderWavyLine, renderUnderline, runTextLineRender, setChildrenModifyFlag, setNotifyChangedCallback, setTraceTrackingFlag, suppressTracking, targetMaps, textLineRenderMode, toRawType, toTypeString, trueChar, validateDataEle, validateDataEleRenderObj, validateDataGroup, validateInlineInputRenderObj, watchChanged };
|
27781
28016
|
//# sourceMappingURL=index.js.map
|