@leafer-ui/interface 1.12.2 → 1.12.4

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/interface",
3
- "version": "1.12.2",
3
+ "version": "1.12.4",
4
4
  "description": "@leafer-ui/interface",
5
5
  "author": "Chao (Leafer) Wan",
6
6
  "license": "MIT",
@@ -22,6 +22,6 @@
22
22
  "leaferjs"
23
23
  ],
24
24
  "dependencies": {
25
- "@leafer/interface": "1.12.2"
25
+ "@leafer/interface": "1.12.4"
26
26
  }
27
27
  }
package/src/IUI.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { ILeaf, ILeafComputedData, ILeafData, ILeafInputData, ILeaferCanvas, IRenderOptions, IExportOptions, IExportResult, IPathDrawer, IPointData, IPathCommandData, IBoundsData, IObject, IPathString, ILeaferImage, IPathCreator, IAnswer, IPickOptions, IPickResult, IValue, ICanvasContext2DSettings, IFourNumber, IFindCondition, IBoolean, ICanvasContext2D, IJSONOptions, IMatrixData, ISizeData, ITransition } from '@leafer/interface'
1
+ import { ILeaf, ILeafComputedData, ILeafData, ILeafInputData, ILeaferCanvas, IRenderOptions, IExportOptions, IExportResult, IPathDrawer, IPointData, IPathCommandData, IBoundsData, IObject, IPathString, ILeaferImage, IPathCreator, IAnswer, IPickOptions, IPickResult, IValue, ICanvasContext2DSettings, IFourNumber, IFindCondition, IBoolean, ICanvasContext2D, IJSONOptions, IMatrixData, ISizeData, ITransition, IAround } from '@leafer/interface'
2
2
 
3
3
  import {
4
4
  IFillAttrData, IFillInputData, IFillComputedData,
@@ -42,6 +42,25 @@ interface IArrowAttrData {
42
42
  export interface IArrowData extends IArrowAttrData, ILineData { }
43
43
  export interface IArrowInputData extends IArrowAttrData, ILineInputData { }
44
44
 
45
+
46
+ // Linker
47
+ export interface ILinker extends IArrow {
48
+ __: ILinkerData
49
+ }
50
+
51
+ export interface ILinkerPointData {
52
+ id: string | IUI,
53
+ point?: IAround,
54
+ }
55
+
56
+ interface ILinkerAttrData {
57
+ startPoint?: ILinkerPointData | IUI | string
58
+ endPoint?: ILinkerPointData | IUI | string
59
+ }
60
+ export interface ILinkerData extends ILinkerAttrData, IArrowData { }
61
+ export interface ILinkerInputData extends ILinkerAttrData, IArrowInputData { }
62
+
63
+
45
64
  // Flow
46
65
  export interface IFlow extends IBox {
47
66
  __: IFlowData
package/src/index.ts CHANGED
@@ -6,6 +6,7 @@ export { ILeafer } from './app/ILeafer'
6
6
  export {
7
7
  ILine, ILineInputData, ILineData,
8
8
  IArrow, IArrowInputData, IArrowData,
9
+ ILinker, ILinkerInputData, ILinkerData, ILinkerPointData,
9
10
  IRect, IRectInputData, IRectData,
10
11
  IEllipse, IEllipseInputData, IEllipseData,
11
12
  IPolygon, IPolygonInputData, IPolygonData,
package/src/type/IType.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { IPointData, IPathCommandData, IWindingRule, IBlendMode, IExportFileType, IFourNumber, IAlign, IUnitPointData, IAxis, IAxisReverse, IFilter, IOptionSizeData, ISizeData, IGap, IPointGap, IScaleFixed, IDirection } from '@leafer/interface'
1
+ import { IPointData, IPathCommandData, IWindingRule, IBlendMode, IExportFileType, IFourNumber, IAlign, IUnitPointData, IAxis, IAxisReverse, IFilter, IOptionSizeData, ISizeData, IGap, IPointGap, IScaleFixed, IDirection, IImageLOD } from '@leafer/interface'
2
2
  import { IColorString, IPaintString } from './IStringType'
3
3
  import { IStrokeStyle } from '../ICommonAttr'
4
4
 
@@ -73,6 +73,7 @@ export interface IImagePaint extends IPaintBase {
73
73
  type: "image"
74
74
 
75
75
  url: string
76
+ lod?: IImageLOD
76
77
 
77
78
  mode?: IImagePaintMode
78
79
  format?: IExportFileType
@@ -95,6 +96,7 @@ export interface IImagePaint extends IPaintBase {
95
96
 
96
97
  repeat?: IRepeat
97
98
  gap?: IGap | IPointGap
99
+ interlace?: number | IInterlace // 平铺图案交错排列
98
100
 
99
101
  changeful?: boolean // 会频繁变化,不生成图案(有特殊性能优化,一般用于游戏精灵、动图场景)
100
102
  sync?: boolean // 同步显示,不走任务列表生成图案
@@ -113,6 +115,10 @@ export interface IImageFilters {
113
115
  }
114
116
  export type IImagePaintMode = 'normal' | 'cover' | 'fit' | 'stretch' | 'clip' | 'repeat'
115
117
  export type IRepeat = boolean | 'x' | 'y' | IPointData
118
+ export interface IInterlace {
119
+ type: IAxis
120
+ offset: number
121
+ }
116
122
 
117
123
  // 描边
118
124
  export type IStrokeAlign = 'inside' | 'outside' | 'center'
package/types/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { IBlendMode, IScaleFixed, IAlign, IUnitPointData, IExportFileType, IFourNumber, IPointData, IOptionSizeData, ISizeData, IGap, IPointGap, IPathCommandData, IAxis, IAxisReverse, IDirection, IWindingRule, IFilter, IMatrixData, ILeaferImage, ITaskItem, INumber, IString, IBoolean, IUnitData, IAnimateOptions, IAnimateEasing, IEventer, IObject, IEventParamsMap, IAnimateEasingFunction, IAnimateEnding, ITransition, IPercentData, IBounds, ILeafInputData, ILeaf as ILeaf$1, ILeafComputedData, ILeafData, IBoundsData, IValue, IPathCreator, IJSONOptions, IFindCondition, IAnswer, IPathString, IPathDrawer, ILeaferCanvas, IRenderOptions, IExportOptions, IExportResult, IPickOptions, IPickResult, ICanvasContext2DSettings, ICanvasContext2D, ILeaferAttrData, IControl, ILeaferType, ILeaferConfig, ILeafRender, ILeafBounds, ILeafHit, ICachedLeaf, IScaleData as IScaleData$1, IBooleanMap, IFunction, IMatrixWithBoundsScaleData } from '@leafer/interface';
1
+ import { IBlendMode, IScaleFixed, IAlign, IUnitPointData, IImageLOD, IExportFileType, IFourNumber, IPointData, IOptionSizeData, ISizeData, IGap, IPointGap, IAxis, IPathCommandData, IAxisReverse, IDirection, IWindingRule, IFilter, IMatrixData, ILeaferImage, ITaskItem, INumber, IString, IBoolean, IUnitData, IAnimateOptions, IAnimateEasing, IEventer, IObject, IEventParamsMap, IAnimateEasingFunction, IAnimateEnding, ITransition, IPercentData, IBounds, ILeafInputData, ILeaf as ILeaf$1, ILeafComputedData, ILeafData, IBoundsData, IValue, IPathCreator, IJSONOptions, IFindCondition, IAnswer, IPathString, IPathDrawer, ILeaferCanvas, IRenderOptions, IExportOptions, IExportResult, IPickOptions, IPickResult, IAround, ICanvasContext2DSettings, ICanvasContext2D, ILeaferAttrData, IControl, ILeaferType, ILeaferConfig, ILeafRender, ILeafBounds, ILeafHit, ICachedLeaf, IScaleData as IScaleData$1, IBooleanMap, IFunction, IMatrixWithBoundsScaleData } from '@leafer/interface';
2
2
  export * from '@leafer/interface';
3
3
  import { IObject as IObject$1, IEditSize, IStroke as IStroke$1, IFourNumber as IFourNumber$1, IFill as IFill$1, IBoxInputData as IBoxInputData$1, IRectInputData as IRectInputData$1, IColorString as IColorString$1, IDirection4, ICursorType, IImageCursor, IAlign as IAlign$1, IUnitPointData as IUnitPointData$1, IUIInputData as IUIInputData$1, IShortcutKeysCheck, IShortcutKeys, IUI as IUI$1, IPointData as IPointData$1, IScaleData, ISkewData, IGroup as IGroup$1, ISelectorProxy, IBox as IBox$1, ILayoutBoundsData, IKeyEvent, IUIEvent, IDragEvent, IMoveEvent, IZoomEvent, IRotateEvent, ITransition as ITransition$1, ILeafList, ILeafer as ILeafer$1, ILeaf, IGroupInputData as IGroupInputData$1, IStateName as IStateName$1, IString as IString$1, IBoolean as IBoolean$1, IStateStyle as IStateStyle$1 } from '@leafer-ui/interface';
4
4
 
@@ -61,6 +61,7 @@ interface IColorStop {
61
61
  interface IImagePaint extends IPaintBase {
62
62
  type: "image";
63
63
  url: string;
64
+ lod?: IImageLOD;
64
65
  mode?: IImagePaintMode;
65
66
  format?: IExportFileType;
66
67
  filters?: IImageFilters;
@@ -75,6 +76,7 @@ interface IImagePaint extends IPaintBase {
75
76
  clipSize?: ISizeData;
76
77
  repeat?: IRepeat;
77
78
  gap?: IGap | IPointGap;
79
+ interlace?: number | IInterlace;
78
80
  changeful?: boolean;
79
81
  sync?: boolean;
80
82
  showProgress?: boolean | IColorString;
@@ -92,6 +94,10 @@ interface IImageFilters {
92
94
  }
93
95
  type IImagePaintMode = 'normal' | 'cover' | 'fit' | 'stretch' | 'clip' | 'repeat';
94
96
  type IRepeat = boolean | 'x' | 'y' | IPointData;
97
+ interface IInterlace {
98
+ type: IAxis;
99
+ offset: number;
100
+ }
95
101
  type IStrokeAlign = 'inside' | 'outside' | 'center';
96
102
  type IStrokeCap = 'none' | 'round' | 'square';
97
103
  type IStrokeJoin = 'bevel' | 'round' | 'miter';
@@ -713,6 +719,21 @@ interface IArrowData extends IArrowAttrData, ILineData {
713
719
  }
714
720
  interface IArrowInputData extends IArrowAttrData, ILineInputData {
715
721
  }
722
+ interface ILinker extends IArrow {
723
+ __: ILinkerData;
724
+ }
725
+ interface ILinkerPointData {
726
+ id: string | IUI;
727
+ point?: IAround;
728
+ }
729
+ interface ILinkerAttrData {
730
+ startPoint?: ILinkerPointData | IUI | string;
731
+ endPoint?: ILinkerPointData | IUI | string;
732
+ }
733
+ interface ILinkerData extends ILinkerAttrData, IArrowData {
734
+ }
735
+ interface ILinkerInputData extends ILinkerAttrData, IArrowInputData {
736
+ }
716
737
  interface IFlow extends IBox {
717
738
  __: IFlowData;
718
739
  }
@@ -1290,4 +1311,4 @@ interface IFilterFunction {
1290
1311
  (filter: IFilter, ui: IUI, bounds: IMatrixWithBoundsScaleData, currentCanvas: ILeaferCanvas, originCanvas: ILeaferCanvas, shape: ICachedShape): void;
1291
1312
  }
1292
1313
 
1293
- export type { IAnimate, IAnimateKeyframe, IAnimateList, IAnimateType, IAnimation, IApp, IAppConfig, IAppData, IAppForEachFunction, IAppInputData, IArrow, IArrowData, IArrowInputData, IArrowStyle, IArrowType, IArrowTypeData, IBackgroundBoxStyle, IBlurEffect, IBox, IBoxData, IBoxInputData, ICachedShape, ICanvas, ICanvasData, ICanvasInputData, IColor, IColorConvertModule, IColorStop, IColorString, IComputedKeyframe, ICornerRadiusString, IDashPatternString, IEditBoxBase, IEditPoint, IEditPointInputData, IEditPointType, IEditToolFunction, IEditorBase, IEditorBeforeEditInner, IEditorBeforeEditOuter, IEditorBeforeMove, IEditorBeforeRotate, IEditorBeforeScale, IEditorBeforeSelect, IEditorBeforeSkew, IEditorConfig, IEditorConfigFunction, IEditorDragStartData, IEditorEditInnerData, IEditorEditOuterData, IEditorMoveData, IEditorRotationData, IEditorScaleData, IEditorSelectData, IEditorSkewData, IEffect, IEffectAttrData, IEffectComputedData, IEffectInputData, IEffectModule, IEllipse, IEllipseData, IEllipseInputData, IExportModule, IFill, IFilterFunction, IFilterModule, IFilterProcessor, IFindUIMethod, IFlow, IFlowData, IFlowInputData, IFontWeight, IFontWeightNumer, IFontWeightString, IFrame, IFrameData, IFrameInputData, IFrameRenderModule, IGIF, IGIFData, IGIFInputData, IGradientPaint, IGradientType, IGrayscaleEffect, IGroup, IGroupData, IGroupInputData, IGroupRenderModule, IImage, IImageData, IImageFilters, IImageInputData, IImagePaint, IImagePaintMode, IImageRenderModule, IKeyframe, IKeyframeId, IKeyframesAnimation, ILeafFill, ILeafPaint, ILeafPaintColor, ILeafPaintPatternData, ILeafShadowEffect, ILeafStrokePaint, ILeafer, ILeaferData, ILeaferInputData, ILine, ILineData, ILineInputData, IOverflow, IPaint, IPaintAttr, IPaintBase, IPaintGradientModule, IPaintImageModule, IPaintModule, IPaintString, IPaintType, IPath, IPathArrowModule, IPathData, IPathDataArrow, IPathDataArrowMap, IPathDataArrowOffset, IPathInputData, IPen, IPenData, IPenInputData, IPercent, IPolygon, IPolygonData, IPolygonInputData, IRGB, IRGBA, IRect, IRectData, IRectInputData, IRectRenderModule, IRepeat, IRobot, IRobotActionName, IRobotActions, IRobotAnimation, IRobotComputedKeyframe, IRobotData, IRobotInputData, IRobotKeyframe, IScrollConfig, IScrollTheme, IScroller, IShadowEffect, IShadowString, ISolidPaint, IStar, IStarData, IStarInputData, IStateModule, IStateName, IStateStyle, IStates, IStroke, IStrokeAlign, IStrokeAttrData, IStrokeCap, IStrokeComputedData, IStrokeComputedStyle, IStrokeGradientPaint, IStrokeImagePaint, IStrokeInputData, IStrokeJoin, IStrokePaint, IStrokeSolidPaint, IStrokeStyle, IStrokeWidthString, IStyleAnimation, IText, ITextAlign, ITextCase, ITextCharData, ITextConvertModule, ITextData, ITextDecoration, ITextDecorationData, ITextDecorationType, ITextDrawData, ITextInputData, ITextOverflow, ITextRenderModule, ITextRowData, ITextStyleAttrData, ITextStyleComputedData, ITextStyleInputData, ITextWordData, ITextWrap, ITransformTool, ITransitionFunction, ITransitionMap, ITransitionModule, IUI, IUIBaseInputData, IUIBoundsModule, IUIData, IUIHitModule, IUIInputData, IUIJSONData, IUIRenderModule, IUITag, IVectorPath, IVerticalAlign, IVideo, IVideoData, IVideoInputData, IWritingMode };
1314
+ export type { IAnimate, IAnimateKeyframe, IAnimateList, IAnimateType, IAnimation, IApp, IAppConfig, IAppData, IAppForEachFunction, IAppInputData, IArrow, IArrowData, IArrowInputData, IArrowStyle, IArrowType, IArrowTypeData, IBackgroundBoxStyle, IBlurEffect, IBox, IBoxData, IBoxInputData, ICachedShape, ICanvas, ICanvasData, ICanvasInputData, IColor, IColorConvertModule, IColorStop, IColorString, IComputedKeyframe, ICornerRadiusString, IDashPatternString, IEditBoxBase, IEditPoint, IEditPointInputData, IEditPointType, IEditToolFunction, IEditorBase, IEditorBeforeEditInner, IEditorBeforeEditOuter, IEditorBeforeMove, IEditorBeforeRotate, IEditorBeforeScale, IEditorBeforeSelect, IEditorBeforeSkew, IEditorConfig, IEditorConfigFunction, IEditorDragStartData, IEditorEditInnerData, IEditorEditOuterData, IEditorMoveData, IEditorRotationData, IEditorScaleData, IEditorSelectData, IEditorSkewData, IEffect, IEffectAttrData, IEffectComputedData, IEffectInputData, IEffectModule, IEllipse, IEllipseData, IEllipseInputData, IExportModule, IFill, IFilterFunction, IFilterModule, IFilterProcessor, IFindUIMethod, IFlow, IFlowData, IFlowInputData, IFontWeight, IFontWeightNumer, IFontWeightString, IFrame, IFrameData, IFrameInputData, IFrameRenderModule, IGIF, IGIFData, IGIFInputData, IGradientPaint, IGradientType, IGrayscaleEffect, IGroup, IGroupData, IGroupInputData, IGroupRenderModule, IImage, IImageData, IImageFilters, IImageInputData, IImagePaint, IImagePaintMode, IImageRenderModule, IKeyframe, IKeyframeId, IKeyframesAnimation, ILeafFill, ILeafPaint, ILeafPaintColor, ILeafPaintPatternData, ILeafShadowEffect, ILeafStrokePaint, ILeafer, ILeaferData, ILeaferInputData, ILine, ILineData, ILineInputData, ILinker, ILinkerData, ILinkerInputData, ILinkerPointData, IOverflow, IPaint, IPaintAttr, IPaintBase, IPaintGradientModule, IPaintImageModule, IPaintModule, IPaintString, IPaintType, IPath, IPathArrowModule, IPathData, IPathDataArrow, IPathDataArrowMap, IPathDataArrowOffset, IPathInputData, IPen, IPenData, IPenInputData, IPercent, IPolygon, IPolygonData, IPolygonInputData, IRGB, IRGBA, IRect, IRectData, IRectInputData, IRectRenderModule, IRepeat, IRobot, IRobotActionName, IRobotActions, IRobotAnimation, IRobotComputedKeyframe, IRobotData, IRobotInputData, IRobotKeyframe, IScrollConfig, IScrollTheme, IScroller, IShadowEffect, IShadowString, ISolidPaint, IStar, IStarData, IStarInputData, IStateModule, IStateName, IStateStyle, IStates, IStroke, IStrokeAlign, IStrokeAttrData, IStrokeCap, IStrokeComputedData, IStrokeComputedStyle, IStrokeGradientPaint, IStrokeImagePaint, IStrokeInputData, IStrokeJoin, IStrokePaint, IStrokeSolidPaint, IStrokeStyle, IStrokeWidthString, IStyleAnimation, IText, ITextAlign, ITextCase, ITextCharData, ITextConvertModule, ITextData, ITextDecoration, ITextDecorationData, ITextDecorationType, ITextDrawData, ITextInputData, ITextOverflow, ITextRenderModule, ITextRowData, ITextStyleAttrData, ITextStyleComputedData, ITextStyleInputData, ITextWordData, ITextWrap, ITransformTool, ITransitionFunction, ITransitionMap, ITransitionModule, IUI, IUIBaseInputData, IUIBoundsModule, IUIData, IUIHitModule, IUIInputData, IUIJSONData, IUIRenderModule, IUITag, IVectorPath, IVerticalAlign, IVideo, IVideoData, IVideoInputData, IWritingMode };