You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: sites/docs/docs/api/type/Theme.en.md
+12-7Lines changed: 12 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,8 +4,9 @@ title: Theme
4
4
toc: content
5
5
order: 0
6
6
---
7
-
This article mainly introduces the type definitions of LogicFlow theme styles. Let's start with the `style` parameter used to control the overall style of the canvas when creating a LogicFlow instance, which is of type `Theme`:
7
+
This article mainly introduces the type definitions of LogicFlow theme styles.
8
8
9
+
## Theme
9
10
The `Theme` type defines the theme styles for various elements in LogicFlow. It includes the style configurations for nodes, edges, text, anchors, arrows, and other elements.
10
11
11
12
| Property Name | Type | Description |
@@ -166,12 +167,16 @@ The `OutlineTheme` type defines the theme for the outline of nodes when selected
166
167
### ArrowTheme
167
168
The `ArrowTheme` type defines the theme for arrows on edges. It inherits from [CommonTheme](#commontheme) and adds some properties specific to arrows:
| offset | number | The length of the arrow. For example, for the symbol "->", offset represents the width of the greater-than sign. |
172
-
| refX | number (optional) | The distance of the arrow perpendicular to the edge. For example, for the symbol "->", refX represents the height of the greater-than sign. |
173
-
| refY | number (optional) | The distance of the arrow perpendicular to the edge. For example, for the symbol "->", refY represents the height of the greater-than sign. |
174
-
| verticalLength | number | The distance of the arrow perpendicular to the edge. For example, for the symbol "->", verticalLength represents the height of the greater-than sign. |
| offset | number | The length of the arrow. For example, for the symbol "->", offset represents the width of the greater-than sign. |
173
+
| refX | number (optional) | The distance of the arrow perpendicular to the edge. For example, for the symbol "->", refX represents the height of the greater-than sign. |
174
+
| refY | number (optional) | The distance of the arrow perpendicular to the edge. For example, for the symbol "->", refY represents the height of the greater-than sign. |
175
+
| verticalLength | number | The distance of the arrow perpendicular to the edge. For example, for the symbol "->", verticalLength represents the height of the greater-than sign. |
176
+
| endArrowType | string (optional) | The end arrow type. LogicFlow internally supports the following 4 types of arrows: <br/>`solid`: Solid arrow (default)<br/>`hollow`: Line arrow<br/>`diamond`: Diamond arrow<br/>`circle`: Circle arrow |
177
+
| startArrowType | string (optional) | The start arrow type. LogicFlow internally supports the following 4 types of arrows: <br/>`solid`: Solid arrow (default)<br/>`hollow`: Line arrow<br/>`diamond`: Diamond arrow<br/>`circle`: Circle arrow |
178
+
| strokeLinecap | string (optional) | The end style of the line, same as SVG strokeLinecap, supports three values: 'butt', 'round', 'square' |
179
+
| strokeLinejoin | string (optional) | The join style of the line, same as SVG strokeLinejoin, supports three values: 'miter', 'round', 'bevel' |
175
180
176
181
### AnchorLineTheme
177
182
The `AnchorLineTheme` type represents the theme for lines drawn from anchors. It inherits from [EdgeTheme](#edgetheme) and `EdgeAnimation`.
0 commit comments