@plait/draw 0.57.0 → 0.58.0
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/constants/draw.d.ts +1 -0
- package/constants/geometry.d.ts +78 -2
- package/constants/index.d.ts +1 -0
- package/constants/pointer.d.ts +4 -2
- package/engines/index.d.ts +3 -3
- package/engines/table/table.d.ts +15 -1
- package/engines/uml/actor.d.ts +2 -0
- package/engines/uml/combined-fragment.d.ts +3 -0
- package/engines/uml/container.d.ts +2 -0
- package/engines/uml/package.d.ts +3 -0
- package/esm2022/constants/draw.mjs +2 -0
- package/esm2022/constants/geometry.mjs +69 -4
- package/esm2022/constants/index.mjs +2 -1
- package/esm2022/constants/pointer.mjs +9 -3
- package/esm2022/engines/basic-shapes/cloud.mjs +1 -1
- package/esm2022/engines/basic-shapes/comment.mjs +1 -1
- package/esm2022/engines/basic-shapes/diamond.mjs +2 -2
- package/esm2022/engines/basic-shapes/parallelogram.mjs +2 -2
- package/esm2022/engines/basic-shapes/pentagon.mjs +1 -1
- package/esm2022/engines/basic-shapes/round-comment.mjs +2 -2
- package/esm2022/engines/basic-shapes/star.mjs +1 -1
- package/esm2022/engines/basic-shapes/trapezoid.mjs +2 -2
- package/esm2022/engines/basic-shapes/triangle.mjs +2 -2
- package/esm2022/engines/flowchart/database.mjs +2 -2
- package/esm2022/engines/flowchart/display.mjs +1 -1
- package/esm2022/engines/flowchart/document.mjs +1 -1
- package/esm2022/engines/flowchart/hard-disk.mjs +2 -2
- package/esm2022/engines/flowchart/internal-storage.mjs +2 -2
- package/esm2022/engines/flowchart/manual-input.mjs +2 -2
- package/esm2022/engines/flowchart/manual-loop.mjs +2 -2
- package/esm2022/engines/flowchart/merge.mjs +1 -1
- package/esm2022/engines/flowchart/multi-document.mjs +1 -1
- package/esm2022/engines/flowchart/note-curly-left.mjs +2 -2
- package/esm2022/engines/flowchart/note-curly-right.mjs +2 -2
- package/esm2022/engines/flowchart/note-square.mjs +1 -1
- package/esm2022/engines/flowchart/off-page.mjs +2 -2
- package/esm2022/engines/flowchart/or.mjs +1 -8
- package/esm2022/engines/flowchart/predefined-process.mjs +1 -1
- package/esm2022/engines/flowchart/summing-junction.mjs +1 -8
- package/esm2022/engines/index.mjs +14 -5
- package/esm2022/engines/table/table.mjs +58 -10
- package/esm2022/engines/uml/actor.mjs +102 -0
- package/esm2022/engines/uml/combined-fragment.mjs +66 -0
- package/esm2022/engines/uml/container.mjs +44 -0
- package/esm2022/engines/uml/package.mjs +75 -0
- package/esm2022/generators/geometry-shape.generator.mjs +3 -3
- package/esm2022/generators/index.mjs +7 -0
- package/esm2022/generators/line-active.generator.mjs +3 -3
- package/esm2022/generators/line-auto-complete.generator.mjs +1 -1
- package/esm2022/generators/single-text.generator.mjs +16 -0
- package/esm2022/generators/table.generator.mjs +20 -0
- package/esm2022/generators/text.generator.mjs +134 -0
- package/esm2022/geometry.component.mjs +63 -76
- package/esm2022/image.component.mjs +8 -25
- package/esm2022/interfaces/element.mjs +2 -1
- package/esm2022/interfaces/engine.mjs +2 -0
- package/esm2022/interfaces/geometry.mjs +14 -1
- package/esm2022/interfaces/image.mjs +1 -1
- package/esm2022/interfaces/index.mjs +27 -4
- package/esm2022/interfaces/line.mjs +1 -1
- package/esm2022/interfaces/table.mjs +9 -2
- package/esm2022/line.component.mjs +8 -25
- package/esm2022/plugins/with-draw-fragment.mjs +3 -1
- package/esm2022/plugins/with-draw-hotkey.mjs +12 -3
- package/esm2022/plugins/with-draw-resize.mjs +1 -1
- package/esm2022/plugins/with-draw.mjs +6 -2
- package/esm2022/plugins/with-geometry-create.mjs +2 -1
- package/esm2022/plugins/with-geometry-resize.mjs +1 -1
- package/esm2022/plugins/with-line-auto-complete-reaction.mjs +2 -2
- package/esm2022/plugins/with-line-bound-reaction.mjs +3 -4
- package/esm2022/plugins/with-line-create.mjs +3 -3
- package/esm2022/plugins/with-line-resize.mjs +3 -3
- package/esm2022/plugins/with-swimlane-create.mjs +132 -0
- package/esm2022/plugins/with-swimlane.mjs +21 -0
- package/esm2022/plugins/with-table-resize.mjs +130 -0
- package/esm2022/plugins/with-table.mjs +53 -7
- package/esm2022/public-api.mjs +2 -1
- package/esm2022/table.component.mjs +115 -24
- package/esm2022/transforms/geometry-text.mjs +6 -3
- package/esm2022/transforms/geometry.mjs +3 -2
- package/esm2022/transforms/index.mjs +11 -2
- package/esm2022/transforms/multi-text-geometry-text.mjs +15 -0
- package/esm2022/transforms/swimlane.mjs +97 -0
- package/esm2022/transforms/table-text.mjs +44 -0
- package/esm2022/utils/clipboard.mjs +15 -2
- package/esm2022/utils/common.mjs +130 -0
- package/esm2022/utils/geometry.mjs +49 -63
- package/esm2022/utils/hit.mjs +47 -18
- package/esm2022/utils/index.mjs +4 -1
- package/esm2022/utils/line/elbow.mjs +2 -2
- package/esm2022/utils/line/line-arrow.mjs +2 -2
- package/esm2022/utils/line/line-basic.mjs +4 -4
- package/esm2022/utils/line/line-common.mjs +2 -2
- package/esm2022/utils/memorize.mjs +7 -1
- package/esm2022/utils/multi-text-geometry.mjs +61 -0
- package/esm2022/utils/position/geometry.mjs +2 -40
- package/esm2022/utils/selected.mjs +14 -1
- package/esm2022/utils/shape.mjs +5 -2
- package/esm2022/utils/snap-resizing.mjs +7 -7
- package/esm2022/utils/style/stroke.mjs +4 -10
- package/esm2022/utils/swimlane.mjs +120 -0
- package/esm2022/utils/table.mjs +124 -0
- package/fesm2022/plait-draw.mjs +6158 -4642
- package/fesm2022/plait-draw.mjs.map +1 -1
- package/generators/index.d.ts +6 -0
- package/generators/line-auto-complete.generator.d.ts +2 -2
- package/generators/single-text.generator.d.ts +11 -0
- package/generators/table.generator.d.ts +9 -0
- package/generators/text.generator.d.ts +43 -0
- package/geometry.component.d.ts +11 -17
- package/image.component.d.ts +5 -11
- package/interfaces/element.d.ts +2 -1
- package/interfaces/engine.d.ts +16 -0
- package/interfaces/geometry.d.ts +23 -18
- package/interfaces/image.d.ts +4 -2
- package/interfaces/index.d.ts +12 -3
- package/interfaces/line.d.ts +4 -5
- package/interfaces/table.d.ts +14 -1
- package/line.component.d.ts +4 -10
- package/package.json +1 -1
- package/plugins/with-swimlane-create.d.ts +8 -0
- package/plugins/with-swimlane.d.ts +2 -0
- package/plugins/with-table-resize.d.ts +2 -0
- package/plugins/with-table.d.ts +5 -1
- package/public-api.d.ts +1 -0
- package/table.component.d.ts +17 -11
- package/transforms/geometry.d.ts +2 -2
- package/transforms/index.d.ts +8 -2
- package/transforms/multi-text-geometry-text.d.ts +4 -0
- package/transforms/swimlane.d.ts +6 -0
- package/transforms/table-text.d.ts +4 -0
- package/utils/clipboard.d.ts +2 -0
- package/utils/common.d.ts +27 -0
- package/utils/geometry.d.ts +34 -15
- package/utils/hit.d.ts +4 -2
- package/utils/index.d.ts +3 -0
- package/utils/line/line-common.d.ts +3 -3
- package/utils/memorize.d.ts +3 -1
- package/utils/multi-text-geometry.d.ts +14 -0
- package/utils/position/geometry.d.ts +8 -21
- package/utils/selected.d.ts +4 -0
- package/utils/shape.d.ts +2 -2
- package/utils/style/stroke.d.ts +4 -5
- package/utils/swimlane.d.ts +52 -0
- package/utils/table.d.ts +26 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { PlaitBoard } from '@plait/core';
|
|
2
2
|
import { PlaitGeometry, PlaitShapeElement } from '../interfaces';
|
|
3
3
|
import { ActiveGeneratorExtraData, Generator } from '@plait/common';
|
|
4
|
-
export declare class LineAutoCompleteGenerator extends Generator<
|
|
4
|
+
export declare class LineAutoCompleteGenerator<T extends PlaitShapeElement = PlaitGeometry> extends Generator<T, ActiveGeneratorExtraData> {
|
|
5
5
|
board: PlaitBoard;
|
|
6
6
|
static key: string;
|
|
7
7
|
autoCompleteG: SVGGElement;
|
|
8
8
|
hoverElement: SVGGElement | null;
|
|
9
9
|
constructor(board: PlaitBoard);
|
|
10
10
|
canDraw(element: PlaitShapeElement, data: ActiveGeneratorExtraData): boolean;
|
|
11
|
-
draw(element:
|
|
11
|
+
draw(element: T, data: ActiveGeneratorExtraData): SVGGElement;
|
|
12
12
|
removeAutoCompleteG(index: number): void;
|
|
13
13
|
recoverAutoCompleteG(): void;
|
|
14
14
|
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { PlaitBoard, PlaitElement } from '@plait/core';
|
|
2
|
+
import { ParagraphElement } from '@plait/text';
|
|
3
|
+
import { PlaitGeometry } from '../interfaces';
|
|
4
|
+
import { ViewContainerRef } from '@angular/core';
|
|
5
|
+
import { PlaitDrawShapeText, TextGenerator, TextGeneratorOptions } from './text.generator';
|
|
6
|
+
export declare class SingleTextGenerator<T extends PlaitElement = PlaitGeometry> extends TextGenerator<T> {
|
|
7
|
+
get textManage(): import("@plait/text").TextManage;
|
|
8
|
+
constructor(board: PlaitBoard, element: T, text: ParagraphElement, viewContainerRef: ViewContainerRef, options: TextGeneratorOptions<T>);
|
|
9
|
+
update(element: T, previousDrawShapeTexts: PlaitDrawShapeText[], currentDrawShapeTexts: PlaitDrawShapeText[], elementG: SVGElement): void;
|
|
10
|
+
update(element: T, previousText: ParagraphElement, currentText: ParagraphElement, elementG: SVGElement): void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Generator } from '@plait/common';
|
|
2
|
+
import { PlaitElement } from '@plait/core';
|
|
3
|
+
import { PlaitTable } from '../interfaces/table';
|
|
4
|
+
export interface TableData {
|
|
5
|
+
}
|
|
6
|
+
export declare class TableGenerator<T extends PlaitElement = PlaitTable> extends Generator<T, TableData> {
|
|
7
|
+
canDraw(element: T, data: TableData): boolean;
|
|
8
|
+
draw(element: T, data: TableData): SVGGElement;
|
|
9
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { PlaitBoard, PlaitElement, RectangleClient } from '@plait/core';
|
|
2
|
+
import { TextManageRef, TextManage, ParagraphElement } from '@plait/text';
|
|
3
|
+
import { DrawShapes, EngineExtraData, PlaitGeometry } from '../interfaces';
|
|
4
|
+
import { ViewContainerRef } from '@angular/core';
|
|
5
|
+
export interface PlaitDrawShapeText extends EngineExtraData {
|
|
6
|
+
key: string;
|
|
7
|
+
text: ParagraphElement;
|
|
8
|
+
textHeight: number;
|
|
9
|
+
board?: PlaitBoard;
|
|
10
|
+
}
|
|
11
|
+
export interface TextGeneratorOptions<T> {
|
|
12
|
+
onValueChangeHandle: (element: T, textChangeRef: TextManageRef, text: PlaitDrawShapeText) => void;
|
|
13
|
+
getRenderRectangle?: (element: T, text: PlaitDrawShapeText) => RectangleClient;
|
|
14
|
+
getMaxWidth?: () => number;
|
|
15
|
+
}
|
|
16
|
+
export declare const KEY_TO_TEXT_MANAGE: Map<string, TextManage>;
|
|
17
|
+
export declare const setTextManage: (key: string, textManage: TextManage) => Map<string, TextManage>;
|
|
18
|
+
export declare const getTextManage: (key: string) => TextManage | undefined;
|
|
19
|
+
export declare const deleteTextManage: (key: string) => boolean;
|
|
20
|
+
export declare class TextGenerator<T extends PlaitElement = PlaitGeometry> {
|
|
21
|
+
protected board: PlaitBoard;
|
|
22
|
+
protected element: T;
|
|
23
|
+
protected texts: PlaitDrawShapeText[];
|
|
24
|
+
protected viewContainerRef: ViewContainerRef;
|
|
25
|
+
protected options: TextGeneratorOptions<T>;
|
|
26
|
+
textManages: TextManage[];
|
|
27
|
+
get shape(): DrawShapes;
|
|
28
|
+
constructor(board: PlaitBoard, element: T, texts: PlaitDrawShapeText[], viewContainerRef: ViewContainerRef, options: TextGeneratorOptions<T>);
|
|
29
|
+
initialize(): void;
|
|
30
|
+
getTextKey(text: PlaitDrawShapeText): string;
|
|
31
|
+
draw(elementG: SVGElement): void;
|
|
32
|
+
update(element: T, previousDrawShapeTexts: PlaitDrawShapeText[], currentDrawShapeTexts: PlaitDrawShapeText[], elementG: SVGElement): void;
|
|
33
|
+
private createTextManage;
|
|
34
|
+
getRectangle(text: PlaitDrawShapeText): {
|
|
35
|
+
height: any;
|
|
36
|
+
width: number;
|
|
37
|
+
x: any;
|
|
38
|
+
y: number;
|
|
39
|
+
};
|
|
40
|
+
onValueChangeHandle(textManageRef: TextManageRef, text: PlaitDrawShapeText): void;
|
|
41
|
+
getMaxWidth(text: PlaitDrawShapeText): number;
|
|
42
|
+
destroy(): void;
|
|
43
|
+
}
|
package/geometry.component.d.ts
CHANGED
|
@@ -1,26 +1,20 @@
|
|
|
1
|
-
import { OnDestroy, OnInit } from '@angular/core';
|
|
2
1
|
import { PlaitBoard, PlaitPluginElementContext, OnContextChanged } from '@plait/core';
|
|
3
|
-
import {
|
|
4
|
-
import { PlaitGeometry } from './interfaces/geometry';
|
|
2
|
+
import { PlaitCommonGeometry, PlaitMultipleTextGeometry } from './interfaces/geometry';
|
|
5
3
|
import { GeometryShapeGenerator } from './generators/geometry-shape.generator';
|
|
6
|
-
import {
|
|
7
|
-
import { ActiveGenerator, CommonPluginElement } from '@plait/common';
|
|
4
|
+
import { ActiveGenerator, CommonElementFlavour } from '@plait/common';
|
|
8
5
|
import { LineAutoCompleteGenerator } from './generators/line-auto-complete.generator';
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
activeGenerator: ActiveGenerator<
|
|
6
|
+
import { TextGenerator } from './generators/text.generator';
|
|
7
|
+
import { SingleTextGenerator } from './generators/single-text.generator';
|
|
8
|
+
export declare class GeometryComponent extends CommonElementFlavour<PlaitCommonGeometry, PlaitBoard> implements OnContextChanged<PlaitCommonGeometry, PlaitBoard> {
|
|
9
|
+
activeGenerator: ActiveGenerator<PlaitCommonGeometry>;
|
|
13
10
|
lineAutoCompleteGenerator: LineAutoCompleteGenerator;
|
|
14
11
|
shapeGenerator: GeometryShapeGenerator;
|
|
15
|
-
|
|
12
|
+
textGenerator: TextGenerator<PlaitMultipleTextGeometry> | SingleTextGenerator;
|
|
16
13
|
constructor();
|
|
17
14
|
initializeGenerator(): void;
|
|
18
|
-
|
|
19
|
-
onContextChanged(value: PlaitPluginElementContext<
|
|
20
|
-
|
|
21
|
-
updateText(): void;
|
|
15
|
+
initialize(): void;
|
|
16
|
+
onContextChanged(value: PlaitPluginElementContext<PlaitCommonGeometry, PlaitBoard>, previous: PlaitPluginElementContext<PlaitCommonGeometry, PlaitBoard>): void;
|
|
17
|
+
updateText(previousElement: PlaitCommonGeometry, currentElement: PlaitCommonGeometry): void;
|
|
22
18
|
initializeTextManage(): void;
|
|
23
|
-
|
|
24
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<GeometryComponent, never>;
|
|
25
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<GeometryComponent, "plait-draw-geometry", never, {}, {}, never, never, true, never>;
|
|
19
|
+
destroy(): void;
|
|
26
20
|
}
|
package/image.component.d.ts
CHANGED
|
@@ -1,20 +1,14 @@
|
|
|
1
|
-
import { OnDestroy, OnInit } from '@angular/core';
|
|
2
1
|
import { PlaitBoard, PlaitPluginElementContext, OnContextChanged } from '@plait/core';
|
|
3
|
-
import {
|
|
4
|
-
import { CommonPluginElement, ImageGenerator } from '@plait/common';
|
|
2
|
+
import { CommonElementFlavour, ImageGenerator } from '@plait/common';
|
|
5
3
|
import { PlaitImage } from './interfaces/image';
|
|
6
4
|
import { LineAutoCompleteGenerator } from './generators/line-auto-complete.generator';
|
|
7
|
-
|
|
8
|
-
export declare class ImageComponent extends CommonPluginElement<PlaitImage, PlaitBoard> implements OnInit, OnDestroy, OnContextChanged<PlaitImage, PlaitBoard> {
|
|
9
|
-
destroy$: Subject<void>;
|
|
5
|
+
export declare class ImageComponent extends CommonElementFlavour<PlaitImage, PlaitBoard> implements OnContextChanged<PlaitImage, PlaitBoard> {
|
|
10
6
|
get activeGenerator(): import("@plait/common").ActiveGenerator<import("@plait/core").PlaitElement>;
|
|
11
7
|
imageGenerator: ImageGenerator<PlaitImage>;
|
|
12
|
-
lineAutoCompleteGenerator: LineAutoCompleteGenerator
|
|
8
|
+
lineAutoCompleteGenerator: LineAutoCompleteGenerator<PlaitImage>;
|
|
13
9
|
constructor();
|
|
14
10
|
initializeGenerator(): void;
|
|
15
|
-
|
|
11
|
+
initialize(): void;
|
|
16
12
|
onContextChanged(value: PlaitPluginElementContext<PlaitImage, PlaitBoard>, previous: PlaitPluginElementContext<PlaitImage, PlaitBoard>): void;
|
|
17
|
-
|
|
18
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ImageComponent, never>;
|
|
19
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ImageComponent, "plait-draw-geometry", never, {}, {}, never, never, true, never>;
|
|
13
|
+
destroy(): void;
|
|
20
14
|
}
|
package/interfaces/element.d.ts
CHANGED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { RectangleClient, PointOfRectangle, Vector, PlaitBoard, Point, PlaitElement } from '@plait/core';
|
|
2
|
+
import { Options } from 'roughjs/bin/core';
|
|
3
|
+
import { PlaitGeometry } from './geometry';
|
|
4
|
+
export interface EngineExtraData {
|
|
5
|
+
}
|
|
6
|
+
export interface ShapeEngine<T extends PlaitElement = PlaitGeometry, P extends EngineExtraData = EngineExtraData, K extends EngineExtraData = EngineExtraData> {
|
|
7
|
+
isInsidePoint: (rectangle: RectangleClient, point: Point) => boolean;
|
|
8
|
+
getNearestPoint: (rectangle: RectangleClient, point: Point) => Point;
|
|
9
|
+
getNearestCrossingPoint?: (rectangle: RectangleClient, point: Point) => Point;
|
|
10
|
+
getConnectorPoints: (rectangle: RectangleClient) => Point[];
|
|
11
|
+
getCornerPoints: (rectangle: RectangleClient) => Point[];
|
|
12
|
+
getEdgeByConnectionPoint?: (rectangle: RectangleClient, point: PointOfRectangle) => [Point, Point] | null;
|
|
13
|
+
getTangentVectorByConnectionPoint?: (rectangle: RectangleClient, point: PointOfRectangle) => Vector | null;
|
|
14
|
+
draw: (board: PlaitBoard, rectangle: RectangleClient, roughOptions: Options, options?: P) => SVGGElement;
|
|
15
|
+
getTextRectangle?: (element: T, options?: K) => RectangleClient;
|
|
16
|
+
}
|
package/interfaces/geometry.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Options } from 'roughjs/bin/core';
|
|
1
|
+
import { PlaitElement, Point } from '@plait/core';
|
|
3
2
|
import { ParagraphElement } from '@plait/text';
|
|
4
3
|
import { StrokeStyle } from './element';
|
|
5
4
|
import { PlaitTable } from './table';
|
|
5
|
+
import { PlaitDrawShapeText } from '../generators/text.generator';
|
|
6
6
|
export declare enum BasicShapes {
|
|
7
7
|
rectangle = "rectangle",
|
|
8
8
|
ellipse = "ellipse",
|
|
@@ -59,13 +59,23 @@ export declare enum SwimlaneSymbols {
|
|
|
59
59
|
swimlaneVertical = "swimlaneVertical",
|
|
60
60
|
swimlaneHorizontal = "swimlaneHorizontal"
|
|
61
61
|
}
|
|
62
|
-
export
|
|
63
|
-
|
|
62
|
+
export declare enum UMLSymbols {
|
|
63
|
+
actor = "actor",
|
|
64
|
+
useCase = "useCase",
|
|
65
|
+
container = "container",
|
|
66
|
+
package = "package",
|
|
67
|
+
combinedFragment = "combinedFragment"
|
|
68
|
+
}
|
|
69
|
+
export declare enum MultipleTextGeometryCommonTextKeys {
|
|
70
|
+
name = "name",
|
|
71
|
+
content = "content"
|
|
72
|
+
}
|
|
73
|
+
export type GeometryShapes = BasicShapes | FlowchartSymbols | SwimlaneSymbols | UMLSymbols;
|
|
74
|
+
export type SwimlaneDirection = 'horizontal' | 'vertical';
|
|
75
|
+
export interface PlaitCommonGeometry extends PlaitElement {
|
|
64
76
|
points: [Point, Point];
|
|
65
77
|
type: 'geometry';
|
|
66
78
|
shape: GeometryShapes;
|
|
67
|
-
text: ParagraphElement;
|
|
68
|
-
textHeight: number;
|
|
69
79
|
fill?: string;
|
|
70
80
|
strokeColor?: string;
|
|
71
81
|
strokeWidth?: number;
|
|
@@ -73,6 +83,13 @@ export interface PlaitGeometry extends PlaitElement {
|
|
|
73
83
|
angle: number;
|
|
74
84
|
opacity: number;
|
|
75
85
|
}
|
|
86
|
+
export interface PlaitMultipleTextGeometry extends PlaitCommonGeometry {
|
|
87
|
+
texts: PlaitDrawShapeText[];
|
|
88
|
+
}
|
|
89
|
+
export interface PlaitGeometry extends PlaitCommonGeometry {
|
|
90
|
+
text?: ParagraphElement;
|
|
91
|
+
textHeight?: number;
|
|
92
|
+
}
|
|
76
93
|
export interface PlaitRectangle extends PlaitGeometry {
|
|
77
94
|
shape: BasicShapes.rectangle;
|
|
78
95
|
}
|
|
@@ -83,7 +100,6 @@ export interface PlaitDiamond extends PlaitGeometry {
|
|
|
83
100
|
shape: BasicShapes.diamond;
|
|
84
101
|
}
|
|
85
102
|
export interface PlaitSwimlane extends PlaitTable {
|
|
86
|
-
type: 'geometry';
|
|
87
103
|
shape: SwimlaneSymbols;
|
|
88
104
|
}
|
|
89
105
|
export interface PlaitSwimlaneVertical extends PlaitSwimlane {
|
|
@@ -93,14 +109,3 @@ export interface PlaitSwimlaneHorizontal extends PlaitSwimlane {
|
|
|
93
109
|
shape: SwimlaneSymbols.swimlaneHorizontal;
|
|
94
110
|
}
|
|
95
111
|
export declare const PlaitGeometry: {};
|
|
96
|
-
export interface ShapeEngine {
|
|
97
|
-
isInsidePoint: (rectangle: RectangleClient, point: Point) => boolean;
|
|
98
|
-
getNearestPoint: (rectangle: RectangleClient, point: Point) => Point;
|
|
99
|
-
getNearestCrossingPoint?: (rectangle: RectangleClient, point: Point) => Point;
|
|
100
|
-
getConnectorPoints: (rectangle: RectangleClient) => Point[];
|
|
101
|
-
getCornerPoints: (rectangle: RectangleClient) => Point[];
|
|
102
|
-
getEdgeByConnectionPoint?: (rectangle: RectangleClient, point: PointOfRectangle) => [Point, Point] | null;
|
|
103
|
-
getTangentVectorByConnectionPoint?: (rectangle: RectangleClient, point: PointOfRectangle) => Vector | null;
|
|
104
|
-
draw: (board: PlaitBoard, rectangle: RectangleClient, options: Options) => SVGGElement;
|
|
105
|
-
getTextRectangle?: (element: PlaitGeometry) => RectangleClient;
|
|
106
|
-
}
|
package/interfaces/image.d.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { PlaitElement, Point } from '@plait/core';
|
|
2
|
-
export interface
|
|
2
|
+
export interface PlaitCommonImage extends PlaitElement {
|
|
3
3
|
points: [Point, Point];
|
|
4
4
|
type: 'image';
|
|
5
|
-
url: string;
|
|
6
5
|
angle: number;
|
|
7
6
|
}
|
|
7
|
+
export interface PlaitImage extends PlaitCommonImage {
|
|
8
|
+
url: string;
|
|
9
|
+
}
|
package/interfaces/index.d.ts
CHANGED
|
@@ -1,20 +1,29 @@
|
|
|
1
|
-
import { PlaitGeometry } from './geometry';
|
|
1
|
+
import { GeometryShapes, PlaitGeometry, TableSymbols } from './geometry';
|
|
2
2
|
import { PlaitImage } from './image';
|
|
3
3
|
import { PlaitLine } from './line';
|
|
4
|
+
import { PlaitTable } from './table';
|
|
4
5
|
import { PlaitText } from './text';
|
|
5
6
|
export * from './line';
|
|
6
7
|
export * from './geometry';
|
|
7
8
|
export * from './text';
|
|
8
9
|
export * from './element';
|
|
9
|
-
export
|
|
10
|
-
export type
|
|
10
|
+
export * from './engine';
|
|
11
|
+
export type PlaitDrawElement = PlaitGeometry | PlaitLine | PlaitImage | PlaitTable;
|
|
12
|
+
export type PlaitShapeElement = PlaitGeometry | PlaitImage | PlaitTable;
|
|
13
|
+
export type DrawShapes = GeometryShapes | TableSymbols;
|
|
11
14
|
export declare const PlaitDrawElement: {
|
|
12
15
|
isGeometry: (value: any) => value is PlaitGeometry;
|
|
13
16
|
isLine: (value: any) => value is PlaitLine;
|
|
14
17
|
isText: (value: any) => value is PlaitText;
|
|
15
18
|
isImage: (value: any) => value is PlaitImage;
|
|
19
|
+
isTable: (value: any) => value is PlaitTable;
|
|
16
20
|
isDrawElement: (value: any) => value is PlaitDrawElement;
|
|
17
21
|
isShapeElement: (value: any) => value is PlaitShapeElement;
|
|
18
22
|
isBasicShape: (value: any) => boolean;
|
|
19
23
|
isFlowchart: (value: any) => boolean;
|
|
24
|
+
isUML: (value: any) => boolean;
|
|
25
|
+
isSwimlane: (value: any) => boolean;
|
|
26
|
+
isVerticalSwimlane: (value: any) => boolean;
|
|
27
|
+
isHorizontalSwimlane: (value: any) => boolean;
|
|
28
|
+
isUMLClassOrInterface: (value: any) => boolean;
|
|
20
29
|
};
|
package/interfaces/line.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Direction, PlaitBoard, PlaitElement, Point, PointOfRectangle, Vector } from '@plait/core';
|
|
2
2
|
import { Element } from 'slate';
|
|
3
|
-
import { PlaitGeometry } from './geometry';
|
|
4
3
|
import { StrokeStyle } from './element';
|
|
5
|
-
import {
|
|
4
|
+
import { PlaitShapeElement } from '.';
|
|
6
5
|
export declare enum LineMarkerType {
|
|
7
6
|
arrow = "arrow",
|
|
8
7
|
none = "none",
|
|
@@ -39,7 +38,7 @@ export interface LineHandleRef {
|
|
|
39
38
|
direction: Direction;
|
|
40
39
|
point: PointOfRectangle;
|
|
41
40
|
vector: Vector;
|
|
42
|
-
boundElement?:
|
|
41
|
+
boundElement?: PlaitShapeElement;
|
|
43
42
|
}
|
|
44
43
|
export interface LineHandleRefPair {
|
|
45
44
|
source: LineHandleRef;
|
|
@@ -70,7 +69,7 @@ export declare const PlaitLine: {
|
|
|
70
69
|
isSourceMarkOrTargetMark(line: PlaitLine, markType: LineMarkerType, handleKey: LineHandleKey): boolean;
|
|
71
70
|
isSourceMark(line: PlaitLine, markType: LineMarkerType): boolean;
|
|
72
71
|
isTargetMark(line: PlaitLine, markType: LineMarkerType): boolean;
|
|
73
|
-
isBoundElementOfSource(line: PlaitLine, element:
|
|
74
|
-
isBoundElementOfTarget(line: PlaitLine, element:
|
|
72
|
+
isBoundElementOfSource(line: PlaitLine, element: PlaitShapeElement): boolean;
|
|
73
|
+
isBoundElementOfTarget(line: PlaitLine, element: PlaitShapeElement): boolean;
|
|
75
74
|
getPoints(board: PlaitBoard, line: PlaitLine): Point[];
|
|
76
75
|
};
|
package/interfaces/table.d.ts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { PlaitElement, Point } from '@plait/core';
|
|
2
|
+
import { EngineExtraData } from './engine';
|
|
2
3
|
import { ParagraphElement } from '@plait/text';
|
|
3
4
|
export interface PlaitTable extends PlaitElement {
|
|
4
5
|
id: string;
|
|
5
6
|
points: Point[];
|
|
7
|
+
type: 'table';
|
|
6
8
|
rows: {
|
|
7
9
|
id: string;
|
|
8
10
|
height?: number;
|
|
@@ -21,7 +23,18 @@ export interface PlaitTableCell {
|
|
|
21
23
|
colspan?: number;
|
|
22
24
|
rowspan?: number;
|
|
23
25
|
text?: PlaitTableCellParagraph;
|
|
26
|
+
textHeight?: number;
|
|
27
|
+
}
|
|
28
|
+
export interface PlaitTableDrawOptions extends EngineExtraData {
|
|
29
|
+
element: PlaitTable;
|
|
30
|
+
}
|
|
31
|
+
export interface PlaitTableCellWithPoints extends PlaitTableCell {
|
|
32
|
+
points: [Point, Point];
|
|
24
33
|
}
|
|
25
34
|
export interface PlaitTableCellParagraph extends ParagraphElement {
|
|
26
|
-
|
|
35
|
+
direction?: 'vertical' | 'horizontal';
|
|
27
36
|
}
|
|
37
|
+
export declare const PlaitTableElement: {
|
|
38
|
+
isTable: (value: any) => value is PlaitTable;
|
|
39
|
+
isVerticalText: (value: PlaitTableCell) => value is PlaitTableCell;
|
|
40
|
+
};
|
package/line.component.d.ts
CHANGED
|
@@ -1,24 +1,20 @@
|
|
|
1
|
-
import { OnDestroy, OnInit } from '@angular/core';
|
|
2
1
|
import { PlaitBoard, PlaitPluginElementContext, OnContextChanged } from '@plait/core';
|
|
3
|
-
import { Subject } from 'rxjs';
|
|
4
2
|
import { LineText, PlaitGeometry, PlaitLine } from './interfaces';
|
|
5
3
|
import { TextManage } from '@plait/text';
|
|
6
4
|
import { LineShapeGenerator } from './generators/line.generator';
|
|
7
5
|
import { LineActiveGenerator } from './generators/line-active.generator';
|
|
8
|
-
import {
|
|
9
|
-
import * as i0 from "@angular/core";
|
|
6
|
+
import { CommonElementFlavour } from '@plait/common';
|
|
10
7
|
interface BoundedElements {
|
|
11
8
|
source?: PlaitGeometry;
|
|
12
9
|
target?: PlaitGeometry;
|
|
13
10
|
}
|
|
14
|
-
export declare class LineComponent extends
|
|
15
|
-
destroy$: Subject<void>;
|
|
11
|
+
export declare class LineComponent extends CommonElementFlavour<PlaitLine, PlaitBoard> implements OnContextChanged<PlaitLine, PlaitBoard> {
|
|
16
12
|
shapeGenerator: LineShapeGenerator;
|
|
17
13
|
activeGenerator: LineActiveGenerator;
|
|
18
14
|
boundedElements: BoundedElements;
|
|
19
15
|
constructor();
|
|
20
16
|
initializeGenerator(): void;
|
|
21
|
-
|
|
17
|
+
initialize(): void;
|
|
22
18
|
getBoundedElements(): BoundedElements;
|
|
23
19
|
onContextChanged(value: PlaitPluginElementContext<PlaitLine, PlaitBoard>, previous: PlaitPluginElementContext<PlaitLine, PlaitBoard>): void;
|
|
24
20
|
initializeTextManagesByElement(): void;
|
|
@@ -26,8 +22,6 @@ export declare class LineComponent extends CommonPluginElement<PlaitLine, PlaitB
|
|
|
26
22
|
createTextManage(text: LineText, index: number): TextManage;
|
|
27
23
|
updateText(previousTexts: LineText[], currentTexts: LineText[]): void;
|
|
28
24
|
updateTextRectangle(): void;
|
|
29
|
-
|
|
30
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<LineComponent, never>;
|
|
31
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<LineComponent, "plait-draw-line", never, {}, {}, never, never, true, never>;
|
|
25
|
+
destroy(): void;
|
|
32
26
|
}
|
|
33
27
|
export {};
|
package/package.json
CHANGED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PlaitBoard } from '@plait/core';
|
|
2
|
+
import { TextManage } from '@plait/text';
|
|
3
|
+
export interface FakeCreateTextRef {
|
|
4
|
+
g: SVGGElement;
|
|
5
|
+
textManage: TextManage;
|
|
6
|
+
}
|
|
7
|
+
export declare const withSwimlaneCreateByDrag: (board: PlaitBoard) => PlaitBoard;
|
|
8
|
+
export declare const withSwimlaneCreateByDrawing: (board: PlaitBoard) => PlaitBoard;
|
package/plugins/with-table.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
+
import { PlaitTable } from '../interfaces/table';
|
|
1
2
|
import { PlaitBoard } from '@plait/core';
|
|
2
|
-
export
|
|
3
|
+
export interface PlaitTableBoard extends PlaitBoard {
|
|
4
|
+
buildTable: (element: PlaitTable) => PlaitTable;
|
|
5
|
+
}
|
|
6
|
+
export declare const withTable: (board: PlaitBoard) => PlaitTableBoard;
|
package/public-api.d.ts
CHANGED
package/table.component.d.ts
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
|
-
import { OnDestroy, OnInit } from '@angular/core';
|
|
2
1
|
import { PlaitBoard, PlaitPluginElementContext, OnContextChanged } from '@plait/core';
|
|
3
|
-
import { ActiveGenerator,
|
|
4
|
-
import { PlaitTable } from './interfaces/table';
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
import { ActiveGenerator, CommonElementFlavour } from '@plait/common';
|
|
3
|
+
import { PlaitTable, PlaitTableCell } from './interfaces/table';
|
|
4
|
+
import { PlaitDrawShapeText, TextGenerator } from './generators/text.generator';
|
|
5
|
+
import { TableGenerator } from './generators/table.generator';
|
|
6
|
+
import { LineAutoCompleteGenerator } from './generators/line-auto-complete.generator';
|
|
7
|
+
export declare class TableComponent<T extends PlaitTable> extends CommonElementFlavour<T, PlaitBoard> implements OnContextChanged<T, PlaitBoard> {
|
|
8
|
+
activeGenerator: ActiveGenerator<T>;
|
|
9
|
+
tableGenerator: TableGenerator<T>;
|
|
10
|
+
textGenerator: TextGenerator<T>;
|
|
11
|
+
lineAutoCompleteGenerator: LineAutoCompleteGenerator<PlaitTable>;
|
|
8
12
|
constructor();
|
|
9
13
|
initializeGenerator(): void;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
14
|
+
initialize(): void;
|
|
15
|
+
draw(): void;
|
|
16
|
+
rotateVerticalText(): void;
|
|
17
|
+
getDrawShapeTexts(cells: PlaitTableCell[]): PlaitDrawShapeText[];
|
|
18
|
+
initializeTextManage(): void;
|
|
19
|
+
onContextChanged(value: PlaitPluginElementContext<T, PlaitBoard>, previous: PlaitPluginElementContext<T, PlaitBoard>): void;
|
|
20
|
+
destroy(): void;
|
|
15
21
|
}
|
package/transforms/geometry.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { PlaitBoard, Point, Path, Vector } from '@plait/core';
|
|
2
2
|
import { GeometryShapes } from '../interfaces';
|
|
3
3
|
import { Element } from 'slate';
|
|
4
|
-
export declare const insertGeometry: (board: PlaitBoard, points: [Point, Point], shape: GeometryShapes) => import("../interfaces").PlaitGeometry;
|
|
5
|
-
export declare const insertGeometryByVector: (board: PlaitBoard, point: Point, shape: GeometryShapes, vector: Vector) => import("../interfaces").PlaitGeometry | null;
|
|
4
|
+
export declare const insertGeometry: (board: PlaitBoard, points: [Point, Point], shape: GeometryShapes) => import("../interfaces").PlaitGeometry | import("../interfaces").PlaitMultipleTextGeometry;
|
|
5
|
+
export declare const insertGeometryByVector: (board: PlaitBoard, point: Point, shape: GeometryShapes, vector: Vector) => import("../interfaces").PlaitGeometry | import("../interfaces").PlaitMultipleTextGeometry | null;
|
|
6
6
|
export declare const insertText: (board: PlaitBoard, point: Point, text: string | Element) => void;
|
|
7
7
|
export declare const resizeGeometry: (board: PlaitBoard, points: [Point, Point], textHeight: number, path: Path) => void;
|
|
8
8
|
export declare const switchGeometryShape: (board: PlaitBoard, shape: GeometryShapes) => void;
|
package/transforms/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export declare const DrawTransforms: {
|
|
2
2
|
setText: (board: import("@plait/core").PlaitBoard, element: import("@plait/draw").PlaitGeometry, text: import("slate").BaseElement, width: number, textHeight: number) => void;
|
|
3
|
-
|
|
3
|
+
setDrawShapeText: (board: import("@plait/core").PlaitBoard, element: import("@plait/draw").PlaitMultipleTextGeometry, text: import("@plait/draw").PlaitDrawShapeText) => void;
|
|
4
|
+
insertGeometry: (board: import("@plait/core").PlaitBoard, points: [import("@plait/core").Point, import("@plait/core").Point], shape: import("@plait/draw").GeometryShapes) => import("@plait/draw").PlaitGeometry | import("@plait/draw").PlaitMultipleTextGeometry;
|
|
4
5
|
resizeGeometry: (board: import("@plait/core").PlaitBoard, points: [import("@plait/core").Point, import("@plait/core").Point], textHeight: number, path: import("@plait/core").Path) => void;
|
|
5
6
|
insertText: (board: import("@plait/core").PlaitBoard, point: import("@plait/core").Point, text: string | import("slate").BaseElement) => void;
|
|
6
7
|
setTextSize: (board: import("@plait/core").PlaitBoard, element: import("@plait/draw").PlaitGeometry, textWidth: number, textHeight: number) => void;
|
|
@@ -12,5 +13,10 @@ export declare const DrawTransforms: {
|
|
|
12
13
|
insertImage: (board: import("@plait/core").PlaitBoard, imageItem: import("@plait/common").CommonImageItem, startPoint?: import("@plait/core").Point | undefined) => void;
|
|
13
14
|
switchGeometryShape: (board: import("@plait/core").PlaitBoard, shape: import("@plait/draw").GeometryShapes) => void;
|
|
14
15
|
connectLineToGeometry: (board: import("@plait/core").PlaitBoard, lineElement: import("@plait/draw").PlaitLine, handle: import("@plait/draw").LineHandleKey, geometryElement: import("@plait/draw").PlaitGeometry) => void;
|
|
15
|
-
insertGeometryByVector: (board: import("@plait/core").PlaitBoard, point: import("@plait/core").Point, shape: import("@plait/draw").GeometryShapes, vector: import("@plait/core").Vector) => import("@plait/draw").PlaitGeometry | null;
|
|
16
|
+
insertGeometryByVector: (board: import("@plait/core").PlaitBoard, point: import("@plait/core").Point, shape: import("@plait/draw").GeometryShapes, vector: import("@plait/core").Vector) => import("@plait/draw").PlaitGeometry | import("@plait/draw").PlaitMultipleTextGeometry | null;
|
|
17
|
+
setTableText: (board: import("@plait/core").PlaitBoard, table: import("../interfaces/table").PlaitTable, cellId: string, text: import("slate").BaseElement, textWidth: number, textHeight: number) => void;
|
|
18
|
+
addSwimlaneRow: (board: import("@plait/core").PlaitBoard, swimlane: import("@plait/draw").PlaitSwimlane, index: number) => void;
|
|
19
|
+
addSwimlaneColumn: (board: import("@plait/core").PlaitBoard, swimlane: import("@plait/draw").PlaitSwimlane, index: number) => void;
|
|
20
|
+
removeSwimlaneRow: (board: import("@plait/core").PlaitBoard, swimlane: import("@plait/draw").PlaitSwimlane, index: number) => void;
|
|
21
|
+
removeSwimlaneColumn: (board: import("@plait/core").PlaitBoard, swimlane: import("@plait/draw").PlaitSwimlane, index: number) => void;
|
|
16
22
|
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { PlaitBoard } from '@plait/core';
|
|
2
|
+
import { PlaitMultipleTextGeometry } from '../interfaces';
|
|
3
|
+
import { PlaitDrawShapeText } from '../generators/text.generator';
|
|
4
|
+
export declare const setDrawShapeText: (board: PlaitBoard, element: PlaitMultipleTextGeometry, text: PlaitDrawShapeText) => void;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { PlaitBoard } from '@plait/core';
|
|
2
|
+
import { PlaitSwimlane } from '../interfaces';
|
|
3
|
+
export declare const addSwimlaneRow: (board: PlaitBoard, swimlane: PlaitSwimlane, index: number) => void;
|
|
4
|
+
export declare const addSwimlaneColumn: (board: PlaitBoard, swimlane: PlaitSwimlane, index: number) => void;
|
|
5
|
+
export declare const removeSwimlaneRow: (board: PlaitBoard, swimlane: PlaitSwimlane, index: number) => void;
|
|
6
|
+
export declare const removeSwimlaneColumn: (board: PlaitBoard, swimlane: PlaitSwimlane, index: number) => void;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { PlaitBoard } from '@plait/core';
|
|
2
|
+
import { Element } from 'slate';
|
|
3
|
+
import { PlaitTable } from '../interfaces/table';
|
|
4
|
+
export declare const setTableText: (board: PlaitBoard, table: PlaitTable, cellId: string, text: Element, textWidth: number, textHeight: number) => void;
|
package/utils/clipboard.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { PlaitBoard, Point } from '@plait/core';
|
|
2
2
|
import { PlaitDrawElement, PlaitGeometry, PlaitLine } from '../interfaces';
|
|
3
|
+
import { PlaitTable } from '../interfaces/table';
|
|
3
4
|
export declare const buildClipboardData: (board: PlaitBoard, elements: PlaitDrawElement[], startPoint: Point) => (PlaitGeometry | PlaitLine)[];
|
|
4
5
|
export declare const insertClipboardData: (board: PlaitBoard, elements: PlaitDrawElement[], startPoint: Point) => void;
|
|
6
|
+
export declare const insertClipboardTableData: (board: PlaitBoard, elements: PlaitTable[], startPoint: Point) => void;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { PlaitBoard, PlaitElement, Point, RectangleClient } from '@plait/core';
|
|
2
|
+
import { DrawShapes, EngineExtraData, PlaitCommonGeometry, PlaitDrawElement, PlaitGeometry, PlaitShapeElement } from '../interfaces';
|
|
3
|
+
import { Options } from 'roughjs/bin/core';
|
|
4
|
+
import { PlaitTable } from '../interfaces/table';
|
|
5
|
+
export declare const getTextRectangle: <T extends PlaitElement = PlaitGeometry>(element: T) => {
|
|
6
|
+
height: any;
|
|
7
|
+
width: number;
|
|
8
|
+
x: any;
|
|
9
|
+
y: number;
|
|
10
|
+
};
|
|
11
|
+
export declare const getStrokeWidthByElement: (element: PlaitElement) => any;
|
|
12
|
+
export declare const insertElement: (board: PlaitBoard, element: PlaitCommonGeometry | PlaitTable) => void;
|
|
13
|
+
export declare const isDrawElementsIncludeText: (elements: PlaitDrawElement[]) => boolean;
|
|
14
|
+
export declare const getSnappingShape: (board: PlaitBoard, point: Point) => PlaitShapeElement | null;
|
|
15
|
+
export declare const getSnappingRef: (board: PlaitBoard, hitElement: PlaitShapeElement, point: Point) => {
|
|
16
|
+
isHitEdge: boolean;
|
|
17
|
+
isHitConnector: boolean;
|
|
18
|
+
connectorPoint: Point | undefined;
|
|
19
|
+
edgePoint: Point;
|
|
20
|
+
};
|
|
21
|
+
export declare const getHitShape: (board: PlaitBoard, point: Point, offset?: number) => PlaitShapeElement | null;
|
|
22
|
+
export declare const traverseDrawShapes: (board: PlaitBoard, callback: (element: PlaitShapeElement) => void) => void;
|
|
23
|
+
export declare const drawShape: (board: PlaitBoard, outerRectangle: RectangleClient, shape: DrawShapes, roughOptions: Options, drawOptions: EngineExtraData) => SVGGElement;
|
|
24
|
+
export declare const drawBoundReaction: (board: PlaitBoard, element: PlaitShapeElement, roughOptions?: {
|
|
25
|
+
hasMask: boolean;
|
|
26
|
+
hasConnector: boolean;
|
|
27
|
+
}) => SVGGElement;
|