@hailin-zheng/editor-core 2.2.10 → 2.2.11

Sign up to get free protection for your applications and to get access to all the features.
@@ -2,7 +2,7 @@ import { ContentMenuItem } from './framework/element-event-define';
2
2
  import { ElementReader } from './framework/element-reader';
3
3
  import { SelectionState } from './framework/selection/document-selection';
4
4
  import { BlockContainerElement, Element, ICancelTokenFn, LeafElement, MarginProps, OrientType, PageLayoutMode, Position, Rect, SerializeProps, ViewOptions } from './framework/element-define';
5
- import { DataElementInlineGroup, DataElementLeaf, DocumentElement, ParagraphElement, TableCellElement, TableElement, TableRowElement } from './framework/impl';
5
+ import { DataElementGroupElement, DataElementInlineGroup, DataElementLeaf, DocumentElement, ParagraphElement, TableCellElement, TableElement, TableRowElement } from './framework/impl';
6
6
  import { CellDiagonal, ParagraphNumberType, ParagraphProps, TextProps } from './framework/element-props';
7
7
  import { EditorContext } from './framework/document-context';
8
8
  import { ElementTrackManage } from './framework/history/element-trace-manage';
@@ -128,10 +128,15 @@ export declare class DocEditor {
128
128
  */
129
129
  private docDblClickHandle;
130
130
  /**
131
- * 获取当前光标所在的数据元或者数据组
131
+ * 获取当前光标所在的数据元
132
132
  * @returns
133
133
  */
134
134
  getCurrentDataElement(): DataElementInlineGroup | DataElementLeaf | null;
135
+ /**
136
+ * 回去当前光标所在数据组
137
+ * @returns
138
+ */
139
+ getCurrentDataGroupElement(): DataElementGroupElement | null;
135
140
  /**
136
141
  * 移动光标到下一个数据元素上
137
142
  */
@@ -61,6 +61,7 @@ export declare class DocumentContext {
61
61
  includeChildren: boolean;
62
62
  }): Array<DataElementInlineGroup | DataElementLeaf>;
63
63
  getControlById(id: string): DataElementInlineGroup | DataElementLeaf;
64
+ isDataEle(ele: Element): boolean;
64
65
  getControlByName(name: string): DataElementInlineGroup | DataElementLeaf;
65
66
  /**
66
67
  * 获取数据元值集合
@@ -2,7 +2,7 @@ import { DocumentPaginator } from "./document-paginator";
2
2
  import { SelectionState } from "./selection/document-selection";
3
3
  import { Element, LeafElement, Position, Rect, ViewOptions } from "./element-define";
4
4
  import { ElementEvent, EventStage, EventTypes, HitEventInfo, HitRegion, ITrackTips, MouseElementEvent } from "./element-event-define";
5
- import { DataElementInlineGroup, DataElementLeaf, DocumentRenderObject } from "./impl";
5
+ import { DataElementGroupElement, DataElementInlineGroup, DataElementLeaf, DocumentRenderObject } from "./impl";
6
6
  import { BorderType, CursorType, RenderObject } from "./render-define";
7
7
  import { EditorContext } from "./document-context";
8
8
  import { Subject, Subscription } from "./infrastructure/event-subject";
@@ -247,5 +247,10 @@ export declare class DocumentEvent {
247
247
  * @returns
248
248
  */
249
249
  getCurrentDataElement(mode?: 'strict' | 'free'): DataElementInlineGroup | DataElementLeaf | null;
250
+ /**
251
+ * 获取当前光标所在的数据组
252
+ * @returns
253
+ */
254
+ getCurrentDataGroupElement(mode?: 'strict' | 'free'): DataElementGroupElement | null;
250
255
  }
251
256
  export {};
@@ -258,12 +258,16 @@ export declare class ViewOptions {
258
258
  dataDecoratorNormalColor: string;
259
259
  dataDecoratorMouseEnterColor: string;
260
260
  dataDecoratorFocusedColor: string;
261
+ showDataEleDecorator: boolean;
261
262
  dataEleEmptyBgColor: string;
262
263
  dataEleMouseEnterBgColor: string;
263
264
  dataEleReadOnlyBgColor: string;
264
265
  dataEleFocusedBgColor: string;
265
266
  dataEleNormalBgColor: string;
266
267
  dataEleErrorBgColor: string;
268
+ dataGroupEleNormalBgColor: string;
269
+ dataGroupMouseEnterBgColor: string;
270
+ dataGroupFocusedBgColor: string;
267
271
  viewBackcolor: string;
268
272
  paraSymbolColor: string;
269
273
  dataGroupColor: string;
@@ -24,3 +24,4 @@ export declare class DataElementGroupFactory extends DataElementBaseFactory<Data
24
24
  * @param offset
25
25
  */
26
26
  export declare function IsInSideDataGroup(control: LeafElement, offset: number): boolean;
27
+ export declare function validateDataGroup(control: Element): boolean;
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "author": "hailin-zheng",
5
5
  "private": false,
6
6
  "license": "ISC",
7
- "version": "2.2.10",
7
+ "version": "2.2.11",
8
8
  "scripts": {},
9
9
  "dependencies": {
10
10
  "moment": "^2.29.3",