@mastergo/plugin-utils
Advanced tools
+67
-7
@@ -409,2 +409,3 @@ declare function hexToRGBA(hex: string): RGBA; | ||
| removed: boolean | ||
| reactions: Reaction[] | ||
| remove(): void | ||
@@ -583,4 +584,7 @@ getPluginData(key: string): string | ||
| gridStyleId: string | ||
| overflowDirection: OverflowDirection | ||
| } | ||
| type OverflowDirection = "NONE" | "HORIZONTAL" | "VERTICAL" | "BOTH" | ||
| interface RectangleCornerMixin { | ||
@@ -620,8 +624,4 @@ topLeftRadius: number | ||
| */ | ||
| readonly flows: Flow[] | ||
| readonly flowStartingPoints: FlowStartingPoint[] | ||
| /** | ||
| * 根据flow id获取原型 | ||
| */ | ||
| getLayerPrototypeById(): Flow | ||
| /** | ||
| * 标签,默认'NONE' | ||
@@ -637,2 +637,13 @@ */ | ||
| interface ComponentSetNode extends DefaultContainerMixin, GeometryMixin, FrameContainerMixin { | ||
| readonly type: 'COMPONENT_SET' | ||
| readonly componentPropertyDefinitions: Array<Record<string, Array<string> | string>> | ||
| clone(): ComponentSetNode | ||
| createVariantComponent(): void | ||
| createVariantProperties(properties: Array<string>): void | ||
| editVariantProperties(properties: Record<string, string>): void | ||
| editVariantPropertyValues(properties: Record<string, { oldValue: string, newValue: string }>): void | ||
| deleteVariantProperty(property: string): void | ||
| } | ||
| interface GroupNode extends DefaultContainerMixin, GeometryMixin, FrameContainerMixin { | ||
@@ -758,2 +769,5 @@ readonly type: 'GROUP' | ||
| readonly type: 'COMPONENT' | ||
| readonly variantProperties: Array<Record<string, string>> | ||
| description: string | ||
| setVariantPropertyValues(property: Record<string, string>): void | ||
| clone(): ComponentNode | ||
@@ -765,2 +779,4 @@ createInstance(): InstanceNode | ||
| readonly type: 'INSTANCE' | ||
| readonly variantProperties: Array<Record<string, string>> | ||
| setVariantPropertyValues(property: Record<string, string>): void | ||
| clone(): InstanceNode | ||
@@ -814,2 +830,3 @@ /** | ||
| | 'COMPONENT' | ||
| | 'COMPONENT_SET' | ||
| | 'INSTANCE' | ||
@@ -829,5 +846,4 @@ | 'BOOLEAN_OPERATION' | ||
| interface Flow { | ||
| interface FlowStartingPoint { | ||
| name: string | ||
| index: string | ||
| id: string | ||
@@ -837,3 +853,47 @@ flowId: string | ||
| } | ||
| interface Reaction { | ||
| readonly trigger: Trigger; | ||
| readonly action?: Action; | ||
| } | ||
| interface Action { | ||
| readonly type: ActionType; | ||
| readonly destinationId: string; | ||
| readonly navigation: Navigation; | ||
| readonly transition: Transition; | ||
| readonly url: string; | ||
| readonly scrollToXOffset?: number; | ||
| readonly scrollToYOffset?: number; | ||
| } | ||
| type ActionType = 'BACK' | 'NODE'| 'URL'| 'CLOSE'| 'NONE'; | ||
| type Navigation = 'NAVIGATE' | 'OVERLAY' | 'SWAP_OVERLAY' | 'SCROLL_TO'; | ||
| interface Transition { | ||
| readonly type: TransitionType; | ||
| readonly duration: number; | ||
| readonly direction: TransitionDirection; | ||
| readonly easing: Easing; | ||
| } | ||
| type TransitionType = 'TANS_NONE' | 'INSTANT' | 'DISSOLVE' | 'SMART_ANIMATE' | 'MOVE_IN' | 'MOVE_OUT' | 'PUSH' | 'SLIDE_IN' | 'SLIDE_OUT' | 'DISPLACE' | ||
| type TransitionDirection = 'LEFT' | 'RIGHT' | 'TOP' | 'BOTTOM' | ||
| interface Easing{ | ||
| readonly type: EasingType; | ||
| readonly easingFunctionCubicBezier: { | ||
| x1: number; | ||
| x2: number; | ||
| y1: number; | ||
| y2: number; | ||
| }; | ||
| } | ||
| type EasingType = 'LINEAR' | 'EASE_IN' | 'EASE_OUT' | 'EASE_IN_AND_OUT' | 'EASE_IN_BACK' | 'EASE_OUT_BACK' | 'EASE_IN_AND_OUT_BACK' | 'CUSTOM_CUBIC_BEZIER' | ||
| interface Trigger{ | ||
| readonly type: TriggerType; | ||
| readonly delay: number; | ||
| } | ||
| type TriggerType = 'ON_CLICK' | 'ON_DRAG' | 'ON_HOVER' | 'ON_PRESS' | 'MOUSE_ENTER' | 'MOUSE_LEAVE' | 'MOUSE_DOWN' | 'MOUSE_UP' | 'AFTER_DELAY' | ||
| interface ArcData { | ||
@@ -840,0 +900,0 @@ /** |
+1
-1
| { | ||
| "name": "@mastergo/plugin-utils", | ||
| "version": "0.4.0", | ||
| "version": "0.5.0", | ||
| "main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "types": "dist/index.d.ts", |
26740
9.59%823
6.74%