@leafer-ui/display 1.0.0-rc.21 → 1.0.0-rc.23

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leafer-ui/display",
3
- "version": "1.0.0-rc.21",
3
+ "version": "1.0.0-rc.23",
4
4
  "description": "@leafer-ui/display",
5
5
  "author": "Chao (Leafer) Wan",
6
6
  "license": "MIT",
@@ -22,14 +22,14 @@
22
22
  "leaferjs"
23
23
  ],
24
24
  "dependencies": {
25
- "@leafer/core": "1.0.0-rc.21",
26
- "@leafer-ui/data": "1.0.0-rc.21",
27
- "@leafer-ui/display-module": "1.0.0-rc.21",
28
- "@leafer-ui/decorator": "1.0.0-rc.21",
29
- "@leafer-ui/external": "1.0.0-rc.21"
25
+ "@leafer/core": "1.0.0-rc.23",
26
+ "@leafer-ui/data": "1.0.0-rc.23",
27
+ "@leafer-ui/display-module": "1.0.0-rc.23",
28
+ "@leafer-ui/decorator": "1.0.0-rc.23",
29
+ "@leafer-ui/external": "1.0.0-rc.23"
30
30
  },
31
31
  "devDependencies": {
32
- "@leafer/interface": "1.0.0-rc.21",
33
- "@leafer-ui/interface": "1.0.0-rc.21"
32
+ "@leafer/interface": "1.0.0-rc.23",
33
+ "@leafer-ui/interface": "1.0.0-rc.23"
34
34
  }
35
35
  }
package/src/Box.ts CHANGED
@@ -49,6 +49,7 @@ export class Box extends Group implements IBox {
49
49
 
50
50
  public __updateBoxBounds(): void {
51
51
  const data = this.__
52
+
52
53
  if (data.__autoSide && this.children.length) {
53
54
  if (this.leafer) this.leafer.layouter.addExtra(this)
54
55
  super.__updateBoxBounds()
@@ -60,6 +61,8 @@ export class Box extends Group implements IBox {
60
61
  } else {
61
62
  this.__updateRectBoxBounds()
62
63
  }
64
+
65
+ if (data.flow) this.__updateContentBounds()
63
66
  }
64
67
 
65
68
  @rewrite(rect.__updateStrokeBounds)
package/src/Leafer.ts CHANGED
@@ -11,9 +11,6 @@ const debug = Debug.get('Leafer')
11
11
  @registerUI()
12
12
  export class Leafer extends Group implements ILeafer {
13
13
 
14
-
15
- static get version() { return '1.0.0-rc.21' }
16
-
17
14
  static list = new LeafList() // 所有leafer实例
18
15
 
19
16
 
@@ -123,7 +120,6 @@ export class Leafer extends Group implements ILeafer {
123
120
 
124
121
  if (this.isApp) this.__setApp()
125
122
  this.__checkAutoLayout(config)
126
- this.updateLazyBounds()
127
123
  this.view = canvas.view
128
124
 
129
125
  // interaction / manager
@@ -199,10 +195,6 @@ export class Leafer extends Group implements ILeafer {
199
195
  Object.keys(data).forEach(key => (this as any)[key] = data[key])
200
196
  }
201
197
 
202
- public forceFullRender(): void {
203
- this.forceRender()
204
- }
205
-
206
198
  public forceRender(bounds?: IBoundsData): void {
207
199
  this.renderer.addBlock(bounds ? new Bounds(bounds) : this.canvas.bounds)
208
200
  if (this.viewReady) this.renderer.update()
@@ -284,7 +276,7 @@ export class Leafer extends Group implements ILeafer {
284
276
  if (this.canvas.allowBackgroundColor) {
285
277
  this.canvas.backgroundColor = newValue as string
286
278
  } else {
287
- this.forceFullRender()
279
+ this.forceRender()
288
280
  }
289
281
  }
290
282
 
@@ -390,6 +382,7 @@ export class Leafer extends Group implements ILeafer {
390
382
  protected __listenEvents(): void {
391
383
  const runId = Run.start('FirstCreate ' + this.innerName)
392
384
  this.once(LeaferEvent.START, () => Run.end(runId))
385
+ this.once(LayoutEvent.START, () => this.updateLazyBounds())
393
386
  this.once(LayoutEvent.END, () => this.__onReady())
394
387
  this.once(RenderEvent.START, () => this.__onCreated())
395
388
  this.once(RenderEvent.END, () => this.__onViewReady())
package/src/Text.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { ILeaferCanvas, IPathDrawer, IPathCommandData, IBoolean, INumber, IString, IBoundsData } from '@leafer/interface'
1
+ import { ILeaferCanvas, IPathDrawer, IPathCommandData, IBoolean, INumber, IString, IBoundsData, IUnitData } from '@leafer/interface'
2
2
  import { BoundsHelper, boundsType, surfaceType, dataProcessor, registerUI, affectStrokeBoundsType, hitType, MathHelper } from '@leafer/core'
3
3
 
4
- import { IFill, IText, IFontWeight, ITextCase, ITextDecoration, ITextData, ITextInputData, ITextAlign, IVerticalAlign, ITextDrawData, IOverflow, IUnitData, IStrokeAlign, IHitType, ITextWrap } from '@leafer-ui/interface'
4
+ import { IFill, IText, IFontWeight, ITextCase, ITextDecoration, ITextData, ITextInputData, ITextAlign, IVerticalAlign, ITextDrawData, IOverflow, IStrokeAlign, IHitType, ITextWrap } from '@leafer-ui/interface'
5
5
  import { TextData, UnitConvert } from '@leafer-ui/data'
6
6
 
7
7
  import { TextConvert } from '@leafer-ui/external'
@@ -9,7 +9,7 @@ import { TextConvert } from '@leafer-ui/external'
9
9
  import { UI } from './UI'
10
10
 
11
11
 
12
- const { copyAndSpread, includes, spread, setList } = BoundsHelper
12
+ const { copyAndSpread, includes, isSame, spread, setList } = BoundsHelper
13
13
 
14
14
  @registerUI()
15
15
  export class Text extends UI implements IText {
@@ -26,9 +26,6 @@ export class Text extends UI implements IText {
26
26
  @boundsType(0)
27
27
  declare public height: INumber
28
28
 
29
- @boundsType(0)
30
- public padding: number | number[]
31
-
32
29
  @surfaceType('#000000')
33
30
  declare public fill: IFill
34
31
 
@@ -83,11 +80,14 @@ export class Text extends UI implements IText {
83
80
  @boundsType('show')
84
81
  public textOverflow: IOverflow | string
85
82
 
83
+ public get editInner(): string { return 'TextEditor' }
84
+
86
85
  public get textDrawData(): ITextDrawData {
87
86
  this.__layout.update()
88
87
  return this.__.__textDrawData
89
88
  }
90
89
 
90
+
91
91
  constructor(data?: ITextInputData) {
92
92
  super(data)
93
93
  }
@@ -169,7 +169,7 @@ export class Text extends UI implements IText {
169
169
  if (italic) b.width += fontSize * 0.16
170
170
 
171
171
  const contentBounds = includes(b, bounds) ? b : bounds
172
- if (contentBounds !== layout.contentBounds) {
172
+ if (!isSame(contentBounds, layout.contentBounds)) {
173
173
  layout.contentBounds = contentBounds
174
174
  layout.renderChanged = true
175
175
  setList(data.__textBoxBounds = {} as IBoundsData, [b, bounds])
package/src/UI.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { ILeaferCanvas, IPathDrawer, IPathCommandData, IHitType, INumber, IBoolean, IString, IPathString, IExportFileType, IPointData, ICursorType, IMaskType, IAround, IValue, IWindingRule, IPathCreator } from '@leafer/interface'
1
+ import { ILeaferCanvas, IPathDrawer, IPathCommandData, IHitType, INumber, IBoolean, IString, IPathString, IExportFileType, IPointData, ICursorType, IMaskType, IEraserType, IValue, IWindingRule, IPathCreator, IFourNumber, IBoundsData, IFlowType, IGap, IWrap, IAxis, IConstraint, IAutoBoxData, IFlowBoxType, IPointGap, IFlowAlign, IFlowAxisAlign, IFindCondition, IAutoSize, IRangeSize, IAlign, IUnitPointData } from '@leafer/interface'
2
2
  import { Leaf, PathDrawer, surfaceType, dataType, positionType, boundsType, pathType, scaleType, rotationType, opacityType, sortType, maskType, dataProcessor, registerUI, useModule, rewrite, rewriteAble, UICreator, PathCorner, hitType, strokeType, PathConvert, eraserType, cursorType, autoLayoutType, pen, naturalBoundsType, pathInputType } from '@leafer/core'
3
3
 
4
- import { IUI, IShadowEffect, IBlurEffect, IStrokeAlign, IStrokeJoin, IStrokeCap, IBlendMode, IDashPatternString, IShadowString, IGrayscaleEffect, IUIData, IGroup, IStrokeWidthString, ICornerRadiusString, IUIInputData, IExportOptions, IExportResult, IFill, IStroke, IArrowType, IFindUIMethod, IEditSize, ILeafer, IEditorConfig } from '@leafer-ui/interface'
4
+ import { IUI, IShadowEffect, IBlurEffect, IStrokeAlign, IStrokeJoin, IStrokeCap, IBlendMode, IDashPatternString, IShadowString, IGrayscaleEffect, IUIData, IGroup, IStrokeWidthString, ICornerRadiusString, IUIInputData, IExportOptions, IExportResult, IFill, IStroke, IArrowType, IFindUIMethod, ILeafer, IEditorConfig, IEditorConfigFunction, IEditToolFunction } from '@leafer-ui/interface'
5
5
  import { arrowType, effectType, stateType, zoomLayerType } from '@leafer-ui/decorator'
6
6
 
7
7
  import { UIData } from '@leafer-ui/data'
@@ -72,13 +72,13 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
72
72
 
73
73
 
74
74
  @maskType(false)
75
- public mask: IBoolean
75
+ public mask: IMaskType
76
76
 
77
- @surfaceType('pixel')
77
+ @surfaceType('pixel') // will remove
78
78
  public maskType: IMaskType
79
79
 
80
80
  @eraserType(false)
81
- public eraser: IBoolean
81
+ public eraser: IEraserType
82
82
 
83
83
 
84
84
  // position
@@ -114,22 +114,98 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
114
114
  public skewY: INumber
115
115
 
116
116
 
117
+ // offset
118
+ @positionType(0, true)
119
+ public offsetX: INumber
120
+
121
+ @positionType(0, true)
122
+ public offsetY: INumber
123
+
124
+ // scroll
125
+ @positionType(0, true)
126
+ public scrollX: INumber
127
+
128
+ @positionType(0, true)
129
+ public scrollY: INumber
130
+
131
+
132
+ // center
133
+ @autoLayoutType()
134
+ public origin: IAlign | IUnitPointData
135
+
117
136
  @autoLayoutType()
118
- public around: IAround
137
+ public around: IAlign | IUnitPointData
119
138
 
120
139
 
140
+ // image
121
141
  @dataType(false)
122
- public draggable: IBoolean
142
+ public lazy: IBoolean // load image / compute paint
123
143
 
144
+ @naturalBoundsType(1)
145
+ public pixelRatio: INumber
124
146
 
125
- @dataType(false)
126
- public editable: IBoolean
127
147
 
128
- @dataType('size')
129
- public editSize?: IEditSize
148
+ // path
149
+ @pathInputType()
150
+ public path: IPathCommandData | IPathString
151
+
152
+ @pathType()
153
+ public windingRule: IWindingRule
154
+
155
+ @pathType(true)
156
+ public closed: boolean
157
+
158
+
159
+ // auto layout
160
+ @autoLayoutType(false)
161
+ public flow: IFlowType
162
+
163
+ @boundsType(0)
164
+ public padding: IFourNumber
165
+
166
+ @boundsType(0)
167
+ public gap: IGap | IPointGap
168
+
169
+ @boundsType('top-left')
170
+ public align: IFlowAlign | IFlowAxisAlign
171
+
172
+ @boundsType(false)
173
+ public wrap: IWrap
174
+
175
+ @boundsType('box')
176
+ public itemBox: IFlowBoxType
177
+
178
+
179
+ @boundsType(true)
180
+ public inFlow: IBoolean
181
+
182
+ @boundsType() // rewrite in flow
183
+ public autoWidth: IAutoSize
184
+
185
+ @boundsType() // rewrite in flow
186
+ public autoHeight: IAutoSize
187
+
188
+ @boundsType()
189
+ public autoBox: IAutoBoxData | IConstraint
190
+
191
+
192
+ @boundsType()
193
+ public widthRange: IRangeSize
194
+
195
+ @boundsType()
196
+ public heightRange: IRangeSize
197
+
198
+
199
+ // drag
200
+ @dataType(false)
201
+ public draggable: IBoolean | IAxis
130
202
 
131
203
  @dataType()
132
- public editorStyle: IEditorConfig
204
+ public dragBounds?: IBoundsData | 'parent'
205
+
206
+
207
+ @dataType(false)
208
+ public editable: IBoolean
133
209
 
134
210
 
135
211
  // hit
@@ -174,7 +250,7 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
174
250
  public strokeAlign: IStrokeAlign
175
251
 
176
252
  @strokeType(1)
177
- public strokeWidth: INumber | INumber[] | IStrokeWidthString
253
+ public strokeWidth: IFourNumber | IStrokeWidthString
178
254
 
179
255
  @strokeType(false)
180
256
  public strokeWidthFixed: IBoolean
@@ -194,25 +270,6 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
194
270
  @strokeType(10)
195
271
  public miterLimit: INumber
196
272
 
197
- // image
198
-
199
- @dataType(false)
200
- public lazy: IBoolean // load image / compute paint
201
-
202
- @naturalBoundsType(1)
203
- public pixelRatio: INumber
204
-
205
- // path
206
-
207
- @pathInputType()
208
- public path: IPathCommandData | IPathString
209
-
210
- @pathType()
211
- public windingRule: IWindingRule
212
-
213
- @pathType(true)
214
- public closed: boolean
215
-
216
273
 
217
274
  // arrow
218
275
 
@@ -225,7 +282,7 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
225
282
  // corner
226
283
 
227
284
  @pathType(0)
228
- public cornerRadius: number | number[] | ICornerRadiusString
285
+ public cornerRadius: IFourNumber | ICornerRadiusString
229
286
 
230
287
  @pathType()
231
288
  public cornerSmoothing: INumber
@@ -283,13 +340,21 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
283
340
  return scaleX !== scaleY ? { x: scaleX, y: scaleY } : scaleX
284
341
  }
285
342
 
286
-
287
343
  public get pen(): IPathCreator {
288
344
  pen.set(this.path = this.__.path || [])
289
345
  return pen
290
346
  }
291
347
 
292
348
 
349
+ // editor
350
+
351
+ public get editConfig(): IEditorConfig { return undefined }
352
+
353
+ public get editOuter(): string { return 'EditTool' }
354
+
355
+ public get editInner(): string { return 'PathEditor' }
356
+
357
+
293
358
  constructor(data?: IUIInputData) {
294
359
  super(data)
295
360
  }
@@ -314,9 +379,13 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
314
379
 
315
380
  // hit rewrite
316
381
 
317
- public find(_condition: number | string | IFindUIMethod, _options?: any): IUI[] { return undefined }
382
+ public find(_condition: number | string | IFindCondition | IFindUIMethod, _options?: any): IUI[] { return undefined }
383
+
384
+ public findTag(tag: string | string[]): IUI[] { return this.find({ tag }) }
318
385
 
319
- public findOne(_condition: number | string | IFindUIMethod, _options?: any): IUI { return undefined }
386
+ public findOne(_condition: number | string | IFindCondition | IFindUIMethod, _options?: any): IUI { return undefined }
387
+
388
+ public findId(id: number | string): IUI { return this.findOne({ id }) }
320
389
 
321
390
 
322
391
  // path
@@ -375,7 +444,8 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
375
444
  public __drawPathByBox(drawer: IPathDrawer): void {
376
445
  const { x, y, width, height } = this.__layout.boxBounds
377
446
  if (this.__.cornerRadius) {
378
- drawer.roundRect(x, y, width, height, this.__.cornerRadius)
447
+ const { cornerRadius } = this.__
448
+ drawer.roundRect(x, y, width, height, typeof cornerRadius === 'number' ? [cornerRadius] : cornerRadius) // 修复微信浏览器bug, 后续需进一步优化
379
449
  } else {
380
450
  drawer.rect(x, y, width, height)
381
451
  }
@@ -404,6 +474,16 @@ export class UI extends Leaf implements IUI { // tip: rewrited Box
404
474
  dataProcessor(data)(this.prototype)
405
475
  }
406
476
 
477
+
478
+ // @leafer-in/editor rewrite
479
+
480
+ static setEditConfig(_config: IEditorConfig | IEditorConfigFunction): void { }
481
+
482
+ static setEditOuter(_toolName: string | IEditToolFunction): void { }
483
+
484
+ static setEditInner(_editorName: string | IEditToolFunction): void { }
485
+
486
+
407
487
  public destroy(): void {
408
488
  this.fill = this.stroke = null
409
489
  super.destroy()
package/types/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- import { IString, INumber, IBoolean, IMaskType, IAround, IHitType, ICursorType, IPathCommandData, IPathString, IWindingRule, IPointData, IPathCreator, IValue, ILeaferCanvas, IPathDrawer, IExportFileType, IPickOptions, IPickResult, IRenderer, IWatcher, ILayouter, ISelector, IInteraction, ICanvasManager, IHitCanvasManager, ILeaferConfig, IAutoBounds, IBounds, IEventListenerId, ITimer, IControl, ILeaferType, IScreenSizeData, IBoundsData, IResizeEvent, IObject, IZoomType, IFourNumber, IRenderOptions, ILeaferImage, ICanvasContext2DSettings, ICanvasContext2D } from '@leafer/interface';
1
+ import { IString, INumber, IBoolean, IMaskType, IEraserType, IAlign, IUnitPointData, IPathCommandData, IPathString, IWindingRule, IFlowType, IFourNumber, IGap, IPointGap, IFlowAlign, IFlowAxisAlign, IWrap, IFlowBoxType, IAutoSize, IAutoBoxData, IConstraint, IRangeSize, IAxis, IBoundsData, IHitType, ICursorType, IPointData, IPathCreator, IValue, IFindCondition, ILeaferCanvas, IPathDrawer, IExportFileType, IPickOptions, IPickResult, IRenderer, IWatcher, ILayouter, ISelector, IInteraction, ICanvasManager, IHitCanvasManager, ILeaferConfig, IAutoBounds, IBounds, IEventListenerId, ITimer, IControl, ILeaferType, IScreenSizeData, IResizeEvent, IObject, IZoomType, IRenderOptions, ILeaferImage, ICanvasContext2DSettings, ICanvasContext2D, IUnitData } from '@leafer/interface';
2
2
  import { Leaf, LeafList } from '@leafer/core';
3
- import { IUI, IUIData, IUIInputData, ILeafer, IGroup, IBlendMode, IEditSize, IEditorConfig, IFill, IStroke, IStrokeAlign, IStrokeWidthString, IStrokeCap, IStrokeJoin, IDashPatternString, IArrowType, ICornerRadiusString, IShadowEffect, IShadowString, IBlurEffect, IGrayscaleEffect, IFindUIMethod, IExportOptions, IExportResult, IGroupData, IGroupInputData, ILeaferData, IApp, IEditorBase, IFunction, ILeaferInputData, IBox, IBoxData, IOverflow, IBoxInputData, IFrame, IFrameData, IFrameInputData, IRect, IRectData, IRectInputData, IEllipse, IEllipseData, IEllipseInputData, IPolygon, IPolygonData, IPolygonInputData, IStar, IStarData, IStarInputData, ILine, ILineData, ILineInputData, IImage, IImageData, IImageInputData, ICanvas, ICanvasData, ICanvasInputData, IText, ITextData, IHitType as IHitType$1, IFontWeight, ITextCase, ITextDecoration, IUnitData, ITextAlign, IVerticalAlign, ITextWrap, ITextDrawData, ITextInputData, IPath, IPathData, IPathInputData, IPen, IPenData, IPathCommandData as IPathCommandData$1, IPenInputData } from '@leafer-ui/interface';
3
+ import { IUI, IUIData, IUIInputData, ILeafer, IGroup, IBlendMode, IFill, IStroke, IStrokeAlign, IStrokeWidthString, IStrokeCap, IStrokeJoin, IDashPatternString, IArrowType, ICornerRadiusString, IShadowEffect, IShadowString, IBlurEffect, IGrayscaleEffect, IEditorConfig, IFindUIMethod, IExportOptions, IExportResult, IEditorConfigFunction, IEditToolFunction, IGroupData, IGroupInputData, ILeaferData, IApp, IEditorBase, IFunction, ILeaferInputData, IBox, IBoxData, IOverflow, IBoxInputData, IFrame, IFrameData, IFrameInputData, IRect, IRectData, IRectInputData, IEllipse, IEllipseData, IEllipseInputData, IPolygon, IPolygonData, IPolygonInputData, IStar, IStarData, IStarInputData, ILine, ILineData, ILineInputData, IImage, IImageData, IImageInputData, ICanvas, ICanvasData, ICanvasInputData, IText, ITextData, IHitType as IHitType$1, IFontWeight, ITextCase, ITextDecoration, ITextAlign, IVerticalAlign, ITextWrap, ITextDrawData, ITextInputData, IPath, IPathData, IPathInputData, IPen, IPenData, IPathCommandData as IPathCommandData$1, IPenInputData } from '@leafer-ui/interface';
4
4
 
5
5
  declare class UI extends Leaf implements IUI {
6
6
  __: IUIData;
@@ -22,9 +22,9 @@ declare class UI extends Leaf implements IUI {
22
22
  disabled: IBoolean;
23
23
  locked: IBoolean;
24
24
  zIndex: INumber;
25
- mask: IBoolean;
25
+ mask: IMaskType;
26
26
  maskType: IMaskType;
27
- eraser: IBoolean;
27
+ eraser: IEraserType;
28
28
  x: INumber;
29
29
  y: INumber;
30
30
  width: INumber;
@@ -34,11 +34,32 @@ declare class UI extends Leaf implements IUI {
34
34
  rotation: INumber;
35
35
  skewX: INumber;
36
36
  skewY: INumber;
37
- around: IAround;
38
- draggable: IBoolean;
37
+ offsetX: INumber;
38
+ offsetY: INumber;
39
+ scrollX: INumber;
40
+ scrollY: INumber;
41
+ origin: IAlign | IUnitPointData;
42
+ around: IAlign | IUnitPointData;
43
+ lazy: IBoolean;
44
+ pixelRatio: INumber;
45
+ path: IPathCommandData | IPathString;
46
+ windingRule: IWindingRule;
47
+ closed: boolean;
48
+ flow: IFlowType;
49
+ padding: IFourNumber;
50
+ gap: IGap | IPointGap;
51
+ align: IFlowAlign | IFlowAxisAlign;
52
+ wrap: IWrap;
53
+ itemBox: IFlowBoxType;
54
+ inFlow: IBoolean;
55
+ autoWidth: IAutoSize;
56
+ autoHeight: IAutoSize;
57
+ autoBox: IAutoBoxData | IConstraint;
58
+ widthRange: IRangeSize;
59
+ heightRange: IRangeSize;
60
+ draggable: IBoolean | IAxis;
61
+ dragBounds?: IBoundsData | 'parent';
39
62
  editable: IBoolean;
40
- editSize?: IEditSize;
41
- editorStyle: IEditorConfig;
42
63
  hittable: IBoolean;
43
64
  hitFill: IHitType;
44
65
  hitStroke: IHitType;
@@ -50,21 +71,16 @@ declare class UI extends Leaf implements IUI {
50
71
  fill: IFill;
51
72
  stroke: IStroke;
52
73
  strokeAlign: IStrokeAlign;
53
- strokeWidth: INumber | INumber[] | IStrokeWidthString;
74
+ strokeWidth: IFourNumber | IStrokeWidthString;
54
75
  strokeWidthFixed: IBoolean;
55
76
  strokeCap: IStrokeCap;
56
77
  strokeJoin: IStrokeJoin;
57
78
  dashPattern: INumber[] | IDashPatternString;
58
79
  dashOffset: INumber;
59
80
  miterLimit: INumber;
60
- lazy: IBoolean;
61
- pixelRatio: INumber;
62
- path: IPathCommandData | IPathString;
63
- windingRule: IWindingRule;
64
- closed: boolean;
65
81
  startArrow: IArrowType;
66
82
  endArrow: IArrowType;
67
- cornerRadius: number | number[] | ICornerRadiusString;
83
+ cornerRadius: IFourNumber | ICornerRadiusString;
68
84
  cornerSmoothing: INumber;
69
85
  shadow: IShadowEffect | IShadowEffect[] | IShadowString;
70
86
  innerShadow: IShadowEffect | IShadowEffect[] | IShadowString;
@@ -80,13 +96,18 @@ declare class UI extends Leaf implements IUI {
80
96
  set scale(value: INumber | IPointData);
81
97
  get scale(): INumber | IPointData;
82
98
  get pen(): IPathCreator;
99
+ get editConfig(): IEditorConfig;
100
+ get editOuter(): string;
101
+ get editInner(): string;
83
102
  constructor(data?: IUIInputData);
84
103
  reset(_data?: IUIInputData): void;
85
104
  set(data: IUIInputData): void;
86
105
  get(name?: string | string[] | IUIInputData): IUIInputData | IValue;
87
106
  createProxyData(): IUIInputData;
88
- find(_condition: number | string | IFindUIMethod, _options?: any): IUI[];
89
- findOne(_condition: number | string | IFindUIMethod, _options?: any): IUI;
107
+ find(_condition: number | string | IFindCondition | IFindUIMethod, _options?: any): IUI[];
108
+ findTag(tag: string | string[]): IUI[];
109
+ findOne(_condition: number | string | IFindCondition | IFindUIMethod, _options?: any): IUI;
110
+ findId(id: number | string): IUI;
90
111
  getPath(curve?: boolean, pathForRender?: boolean): IPathCommandData;
91
112
  getPathString(curve?: boolean, pathForRender?: boolean): IPathString;
92
113
  __onUpdateSize(): void;
@@ -100,6 +121,9 @@ declare class UI extends Leaf implements IUI {
100
121
  static one(data: IUIInputData, x?: number, y?: number, width?: number, height?: number): IUI;
101
122
  static registerUI(): void;
102
123
  static registerData(data: IUIData): void;
124
+ static setEditConfig(_config: IEditorConfig | IEditorConfigFunction): void;
125
+ static setEditOuter(_toolName: string | IEditToolFunction): void;
126
+ static setEditInner(_editorName: string | IEditToolFunction): void;
103
127
  destroy(): void;
104
128
  }
105
129
 
@@ -125,7 +149,6 @@ declare class Group extends UI implements IGroup {
125
149
  }
126
150
 
127
151
  declare class Leafer extends Group implements ILeafer {
128
- static get version(): string;
129
152
  static list: LeafList;
130
153
  get __tag(): string;
131
154
  __: ILeaferData;
@@ -177,7 +200,6 @@ declare class Leafer extends Group implements ILeafer {
177
200
  unlockLayout(): void;
178
201
  lockLayout(): void;
179
202
  resize(size: IScreenSizeData): void;
180
- forceFullRender(): void;
181
203
  forceRender(bounds?: IBoundsData): void;
182
204
  updateCursor(cursor?: ICursorType): void;
183
205
  updateLazyBounds(): void;
@@ -330,7 +352,6 @@ declare class Text extends UI implements IText {
330
352
  __: ITextData;
331
353
  width: INumber;
332
354
  height: INumber;
333
- padding: number | number[];
334
355
  fill: IFill;
335
356
  strokeAlign: IStrokeAlign;
336
357
  hitFill: IHitType$1;
@@ -349,6 +370,7 @@ declare class Text extends UI implements IText {
349
370
  verticalAlign: IVerticalAlign;
350
371
  textWrap: ITextWrap;
351
372
  textOverflow: IOverflow | string;
373
+ get editInner(): string;
352
374
  get textDrawData(): ITextDrawData;
353
375
  constructor(data?: ITextInputData);
354
376
  __drawHitPath(canvas: ILeaferCanvas): void;