@logicflow/core 2.2.0-alpha.1 → 2.2.0-alpha.3

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.
Files changed (119) hide show
  1. package/.turbo/turbo-build$colon$dev.log +2 -57
  2. package/.turbo/turbo-build.log +6 -6
  3. package/CHANGELOG.md +12 -0
  4. package/dist/index.css +3 -2
  5. package/dist/index.min.js +1 -1
  6. package/dist/index.min.js.map +1 -1
  7. package/es/LogicFlow.d.ts +9 -0
  8. package/es/constant/index.d.ts +1 -1
  9. package/es/constant/index.js +1 -1
  10. package/es/constant/theme.d.ts +136 -0
  11. package/es/constant/theme.js +680 -0
  12. package/es/index.css +3 -2
  13. package/es/model/GraphModel.d.ts +9 -2
  14. package/es/model/GraphModel.js +17 -6
  15. package/es/model/TransformModel.js +9 -9
  16. package/es/model/edge/BaseEdgeModel.js +7 -2
  17. package/es/model/edge/PolylineEdgeModel.d.ts +6 -0
  18. package/es/model/edge/PolylineEdgeModel.js +23 -1
  19. package/es/model/node/BaseNodeModel.d.ts +12 -1
  20. package/es/model/node/BaseNodeModel.js +6 -1
  21. package/es/model/node/HtmlNodeModel.d.ts +12 -0
  22. package/es/model/node/HtmlNodeModel.js +19 -0
  23. package/es/model/node/PolygonNodeModel.js +3 -3
  24. package/es/options.d.ts +1 -1
  25. package/es/style/index.css +3 -2
  26. package/es/style/index.less +3 -2
  27. package/es/style/raw.d.ts +1 -1
  28. package/es/style/raw.js +1 -1
  29. package/es/tool/MultipleSelectTool.js +6 -5
  30. package/es/util/edge.d.ts +1 -1
  31. package/es/util/edge.js +2 -2
  32. package/es/util/geometry.d.ts +8 -0
  33. package/es/util/geometry.js +79 -0
  34. package/es/util/theme.d.ts +2 -65
  35. package/es/util/theme.js +4 -281
  36. package/es/view/Control.d.ts +5 -0
  37. package/es/view/Control.js +44 -57
  38. package/es/view/edge/PolylineEdge.js +13 -2
  39. package/es/view/node/BaseNode.d.ts +1 -0
  40. package/es/view/node/BaseNode.js +14 -10
  41. package/es/view/node/HtmlNode.js +2 -4
  42. package/es/view/overlay/Grid.d.ts +12 -1
  43. package/es/view/overlay/Grid.js +85 -23
  44. package/es/view/overlay/OutlineOverlay.d.ts +1 -0
  45. package/es/view/overlay/OutlineOverlay.js +17 -16
  46. package/es/view/overlay/gridConfig.d.ts +46 -0
  47. package/es/view/overlay/gridConfig.js +99 -0
  48. package/es/view/shape/Polygon.d.ts +0 -7
  49. package/es/view/shape/Polygon.js +12 -43
  50. package/lib/LogicFlow.d.ts +9 -0
  51. package/lib/constant/index.d.ts +1 -1
  52. package/lib/constant/index.js +16 -2
  53. package/lib/constant/theme.d.ts +136 -0
  54. package/lib/constant/theme.js +683 -0
  55. package/lib/index.css +3 -2
  56. package/lib/model/GraphModel.d.ts +9 -2
  57. package/lib/model/GraphModel.js +18 -7
  58. package/lib/model/TransformModel.js +9 -9
  59. package/lib/model/edge/BaseEdgeModel.js +7 -2
  60. package/lib/model/edge/PolylineEdgeModel.d.ts +6 -0
  61. package/lib/model/edge/PolylineEdgeModel.js +23 -1
  62. package/lib/model/node/BaseNodeModel.d.ts +12 -1
  63. package/lib/model/node/BaseNodeModel.js +6 -1
  64. package/lib/model/node/HtmlNodeModel.d.ts +12 -0
  65. package/lib/model/node/HtmlNodeModel.js +19 -0
  66. package/lib/model/node/PolygonNodeModel.js +3 -3
  67. package/lib/options.d.ts +1 -1
  68. package/lib/style/index.css +3 -2
  69. package/lib/style/index.less +3 -2
  70. package/lib/style/raw.d.ts +1 -1
  71. package/lib/style/raw.js +1 -1
  72. package/lib/tool/MultipleSelectTool.js +6 -5
  73. package/lib/util/edge.d.ts +1 -1
  74. package/lib/util/edge.js +2 -2
  75. package/lib/util/geometry.d.ts +8 -0
  76. package/lib/util/geometry.js +81 -1
  77. package/lib/util/theme.d.ts +2 -65
  78. package/lib/util/theme.js +15 -292
  79. package/lib/view/Control.d.ts +5 -0
  80. package/lib/view/Control.js +44 -57
  81. package/lib/view/edge/PolylineEdge.js +13 -2
  82. package/lib/view/node/BaseNode.d.ts +1 -0
  83. package/lib/view/node/BaseNode.js +14 -10
  84. package/lib/view/node/HtmlNode.js +1 -3
  85. package/lib/view/overlay/Grid.d.ts +12 -1
  86. package/lib/view/overlay/Grid.js +83 -21
  87. package/lib/view/overlay/OutlineOverlay.d.ts +1 -0
  88. package/lib/view/overlay/OutlineOverlay.js +17 -16
  89. package/lib/view/overlay/gridConfig.d.ts +46 -0
  90. package/lib/view/overlay/gridConfig.js +104 -0
  91. package/lib/view/shape/Polygon.d.ts +0 -7
  92. package/lib/view/shape/Polygon.js +13 -45
  93. package/package.json +1 -1
  94. package/src/LogicFlow.tsx +10 -0
  95. package/src/constant/index.ts +2 -2
  96. package/src/constant/theme.ts +708 -0
  97. package/src/model/GraphModel.ts +19 -7
  98. package/src/model/TransformModel.ts +9 -9
  99. package/src/model/edge/BaseEdgeModel.ts +10 -2
  100. package/src/model/edge/PolylineEdgeModel.ts +26 -1
  101. package/src/model/node/BaseNodeModel.ts +9 -1
  102. package/src/model/node/HtmlNodeModel.ts +14 -0
  103. package/src/model/node/PolygonNodeModel.ts +2 -0
  104. package/src/options.ts +1 -1
  105. package/src/style/index.less +3 -2
  106. package/src/style/raw.ts +3 -2
  107. package/src/tool/MultipleSelectTool.tsx +6 -5
  108. package/src/util/edge.ts +2 -1
  109. package/src/util/geometry.ts +99 -0
  110. package/src/util/theme.ts +12 -303
  111. package/src/view/Control.tsx +61 -63
  112. package/src/view/edge/PolylineEdge.tsx +14 -2
  113. package/src/view/node/BaseNode.tsx +8 -3
  114. package/src/view/node/HtmlNode.tsx +27 -10
  115. package/src/view/overlay/Grid.tsx +187 -30
  116. package/src/view/overlay/OutlineOverlay.tsx +35 -47
  117. package/src/view/overlay/gridConfig.ts +103 -0
  118. package/src/view/shape/Polygon.tsx +12 -49
  119. package/stats.html +1 -1
@@ -0,0 +1,683 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.gridModeMap = exports.retroGrid = exports.defaultGrid = exports.colorfulGrid = exports.darkGrid = exports.backgroundModeMap = exports.retroBackground = exports.defaultBackground = exports.colorfulBackground = exports.darkBackground = exports.themeModeMap = exports.colorfulTheme = exports.darkTheme = exports.retroTheme = exports.defaultTheme = exports.DEFAULT_GRID_SIZE = void 0;
4
+ exports.DEFAULT_GRID_SIZE = 10;
5
+ exports.defaultTheme = {
6
+ baseNode: {
7
+ fill: '#fff',
8
+ stroke: '#474747',
9
+ strokeWidth: 2,
10
+ radius: 12,
11
+ },
12
+ baseEdge: {
13
+ stroke: '#474747',
14
+ strokeWidth: 2,
15
+ radius: 12,
16
+ },
17
+ rect: {
18
+ shadow: {
19
+ dx: 0,
20
+ dy: 0,
21
+ stdDeviation: 4,
22
+ floodColor: '#9CA1AA55',
23
+ },
24
+ },
25
+ circle: {},
26
+ diamond: {},
27
+ ellipse: {},
28
+ polygon: {},
29
+ html: {
30
+ fill: 'transparent',
31
+ stroke: 'transparent',
32
+ shadow: {
33
+ dx: 0,
34
+ dy: 0,
35
+ stdDeviation: 4,
36
+ floodColor: '#9CA1AA55',
37
+ },
38
+ },
39
+ text: {
40
+ color: '#474747',
41
+ stroke: 'none',
42
+ fontSize: 12,
43
+ background: {
44
+ fill: 'transparent',
45
+ },
46
+ },
47
+ nodeText: {
48
+ color: '#474747',
49
+ overflowMode: 'default',
50
+ fontSize: 12,
51
+ lineHeight: 1.2,
52
+ },
53
+ anchor: {
54
+ stroke: '#474747',
55
+ fill: '#fff',
56
+ r: 4,
57
+ hover: {
58
+ r: 8,
59
+ fill: '#707070',
60
+ fillOpacity: 0.15,
61
+ stroke: 'transparent',
62
+ },
63
+ },
64
+ anchorLine: {
65
+ stroke: '#474747',
66
+ strokeWidth: 2,
67
+ strokeDasharray: '3,2',
68
+ },
69
+ line: {},
70
+ polyline: {},
71
+ bezier: {
72
+ fill: 'none',
73
+ adjustLine: {
74
+ stroke: '#949494',
75
+ },
76
+ adjustAnchor: {
77
+ r: 4,
78
+ fill: '#949494',
79
+ fillOpacity: 1,
80
+ stroke: '#949494',
81
+ },
82
+ },
83
+ edgeText: {
84
+ textWidth: 100,
85
+ overflowMode: 'default',
86
+ fontSize: 12,
87
+ background: {
88
+ fill: '#fff',
89
+ },
90
+ },
91
+ arrow: {
92
+ strokeLinecap: 'round',
93
+ strokeLinejoin: 'round',
94
+ offset: 10,
95
+ verticalLength: 5, // 箭头垂直于边的距离
96
+ },
97
+ snapline: {
98
+ strokeLinecap: 'round',
99
+ strokeLinejoin: 'round',
100
+ stroke: '#AAAAAA',
101
+ strokeWidth: 1,
102
+ strokeDasharray: '3,3',
103
+ },
104
+ edgeAdjust: {
105
+ r: 4,
106
+ fill: '#fff',
107
+ stroke: '#474747',
108
+ strokeWidth: 1,
109
+ },
110
+ outline: {
111
+ fill: 'none',
112
+ stroke: 'transparent', // 矩形默认不显示调整边框
113
+ strokeWidth: 0,
114
+ },
115
+ edgeOutline: {
116
+ fill: 'transparent',
117
+ stroke: '#757575',
118
+ strokeWidth: 1.5,
119
+ strokeDasharray: '4,4',
120
+ radius: 8,
121
+ hover: {
122
+ stroke: '#4271DF',
123
+ },
124
+ },
125
+ edgeAnimation: {
126
+ stroke: '#4271DF',
127
+ strokeDasharray: '12,4,6,4',
128
+ strokeDashoffset: '100%',
129
+ animationName: 'lf_animate_dash',
130
+ animationDuration: '20s',
131
+ animationIterationCount: 'infinite',
132
+ animationTimingFunction: 'linear',
133
+ animationDirection: 'normal',
134
+ },
135
+ rotateControl: {
136
+ stroke: '#474747',
137
+ fill: '#fff',
138
+ strokeWidth: 1,
139
+ hover: {
140
+ fill: '#707070',
141
+ fillOpacity: 0.15,
142
+ stroke: 'transparent',
143
+ },
144
+ },
145
+ resizeControl: {
146
+ width: 8,
147
+ height: 8,
148
+ radius: 2,
149
+ fill: '#fff',
150
+ stroke: '#474747',
151
+ hover: {
152
+ width: 12,
153
+ height: 12,
154
+ fill: '#707070',
155
+ fillOpacity: 0.15,
156
+ stroke: 'transparent',
157
+ },
158
+ },
159
+ resizeOutline: {
160
+ fill: 'transparent',
161
+ stroke: '#757575',
162
+ strokeWidth: 1.5,
163
+ strokeDasharray: '4,4',
164
+ radius: 8,
165
+ hover: {
166
+ stroke: '#4271DF',
167
+ },
168
+ },
169
+ };
170
+ exports.retroTheme = {
171
+ baseNode: {
172
+ fill: '#fff',
173
+ stroke: '#000',
174
+ strokeWidth: 2,
175
+ },
176
+ baseEdge: {
177
+ stroke: '#000',
178
+ strokeWidth: 2,
179
+ },
180
+ rect: {},
181
+ circle: {},
182
+ diamond: {},
183
+ ellipse: {},
184
+ polygon: {},
185
+ html: {
186
+ fill: 'transparent',
187
+ stroke: 'transparent',
188
+ },
189
+ text: {
190
+ color: '#000',
191
+ stroke: 'none',
192
+ fontSize: 12,
193
+ background: {
194
+ fill: 'transparent',
195
+ },
196
+ },
197
+ anchor: {
198
+ stroke: '#000',
199
+ fill: '#fff',
200
+ r: 4,
201
+ hover: {
202
+ r: 10,
203
+ fill: '#949494',
204
+ fillOpacity: 0.5,
205
+ stroke: '#949494',
206
+ },
207
+ },
208
+ anchorLine: {
209
+ stroke: '#000',
210
+ strokeWidth: 2,
211
+ strokeDasharray: '3,2',
212
+ },
213
+ nodeText: {
214
+ color: '#000',
215
+ overflowMode: 'default',
216
+ fontSize: 12,
217
+ lineHeight: 1.2,
218
+ },
219
+ edgeText: {
220
+ textWidth: 100,
221
+ overflowMode: 'default',
222
+ fontSize: 12,
223
+ background: {
224
+ fill: '#fff',
225
+ },
226
+ },
227
+ line: {},
228
+ polyline: {},
229
+ bezier: {
230
+ fill: 'none',
231
+ adjustLine: {
232
+ stroke: '#949494',
233
+ },
234
+ adjustAnchor: {
235
+ r: 4,
236
+ fill: '#949494',
237
+ fillOpacity: 1,
238
+ stroke: '#949494',
239
+ },
240
+ },
241
+ arrow: {
242
+ offset: 10,
243
+ verticalLength: 5, // 箭头垂直于边的距离
244
+ },
245
+ snapline: {
246
+ stroke: '#949494',
247
+ strokeWidth: 1,
248
+ },
249
+ edgeAdjust: {
250
+ r: 4,
251
+ fill: '#fff',
252
+ stroke: '#949494',
253
+ strokeWidth: 2,
254
+ },
255
+ outline: {
256
+ fill: 'transparent',
257
+ stroke: '#949494',
258
+ strokeDasharray: '3,3',
259
+ hover: {
260
+ stroke: '#949494',
261
+ },
262
+ },
263
+ edgeOutline: {
264
+ fill: 'transparent',
265
+ stroke: '#949494',
266
+ strokeDasharray: '3,3',
267
+ hover: {
268
+ stroke: '#949494',
269
+ },
270
+ },
271
+ edgeAnimation: {
272
+ stroke: 'red',
273
+ strokeDasharray: '10,10',
274
+ strokeDashoffset: '100%',
275
+ animationName: 'lf_animate_dash',
276
+ animationDuration: '20s',
277
+ animationIterationCount: 'infinite',
278
+ animationTimingFunction: 'linear',
279
+ animationDirection: 'normal',
280
+ },
281
+ rotateControl: {
282
+ stroke: '#000',
283
+ fill: '#fff',
284
+ strokeWidth: 1.5,
285
+ },
286
+ resizeControl: {
287
+ width: 7,
288
+ height: 7,
289
+ fill: '#fff',
290
+ stroke: '#000',
291
+ },
292
+ resizeOutline: {
293
+ fill: 'none',
294
+ stroke: 'transparent', // 矩形默认不显示调整边框
295
+ strokeWidth: 1,
296
+ strokeDasharray: '3,3',
297
+ },
298
+ };
299
+ exports.darkTheme = {
300
+ baseNode: {
301
+ fill: '#33353A',
302
+ stroke: '#EAEAEA',
303
+ strokeWidth: 2,
304
+ radius: 12,
305
+ },
306
+ baseEdge: {
307
+ stroke: '#EAEAEA',
308
+ strokeWidth: 2,
309
+ radius: 12,
310
+ },
311
+ rect: {},
312
+ circle: {},
313
+ diamond: {},
314
+ ellipse: {},
315
+ polygon: {},
316
+ html: {
317
+ fill: '#33353A',
318
+ stroke: 'transparent',
319
+ shadow: {
320
+ dx: 0,
321
+ dy: 0,
322
+ stdDeviation: 4,
323
+ floodColor: '#9CA1AA55',
324
+ },
325
+ },
326
+ text: {
327
+ color: '#EAEAEA',
328
+ stroke: 'none',
329
+ fontSize: 12,
330
+ background: {
331
+ fill: 'transparent',
332
+ },
333
+ },
334
+ nodeText: {
335
+ color: '#EAEAEA',
336
+ overflowMode: 'default',
337
+ fontSize: 12,
338
+ lineHeight: 1.2,
339
+ },
340
+ anchor: {
341
+ stroke: '#EAEAEA',
342
+ fill: '#33353A',
343
+ r: 4,
344
+ hover: {
345
+ r: 8,
346
+ fill: '#707070',
347
+ fillOpacity: 0.15,
348
+ stroke: 'transparent',
349
+ },
350
+ },
351
+ anchorLine: {
352
+ stroke: '#EAEAEA',
353
+ strokeWidth: 2,
354
+ strokeDasharray: '3,2',
355
+ },
356
+ line: {},
357
+ polyline: {},
358
+ bezier: {
359
+ fill: 'none',
360
+ adjustLine: {
361
+ stroke: '#EAEAEA',
362
+ },
363
+ adjustAnchor: {
364
+ r: 4,
365
+ fill: '#33353A',
366
+ fillOpacity: 1,
367
+ stroke: '#EAEAEA',
368
+ },
369
+ },
370
+ edgeText: {
371
+ textWidth: 100,
372
+ overflowMode: 'default',
373
+ fontSize: 12,
374
+ background: {
375
+ fill: '#EAEAEA',
376
+ },
377
+ },
378
+ arrow: {
379
+ strokeLinecap: 'round',
380
+ strokeLinejoin: 'round',
381
+ offset: 10,
382
+ verticalLength: 5, // 箭头垂直于边的距离
383
+ },
384
+ snapline: {
385
+ strokeLinecap: 'round',
386
+ strokeLinejoin: 'round',
387
+ stroke: '#949494',
388
+ strokeWidth: 1,
389
+ },
390
+ edgeAdjust: {
391
+ r: 4,
392
+ fill: '#33353A',
393
+ stroke: '#EAEAEA',
394
+ strokeWidth: 1,
395
+ },
396
+ outline: {
397
+ fill: 'none',
398
+ stroke: 'transparent', // 矩形默认不显示调整边框
399
+ strokeWidth: 0,
400
+ },
401
+ edgeOutline: {
402
+ fill: 'transparent',
403
+ stroke: '#EAEAEA',
404
+ strokeWidth: 1.5,
405
+ strokeDasharray: '4,4',
406
+ radius: 8,
407
+ hover: {
408
+ stroke: '#4271DF',
409
+ },
410
+ },
411
+ edgeAnimation: {
412
+ stroke: '#4271DF',
413
+ strokeDasharray: '12,4,6,4',
414
+ strokeDashoffset: '100%',
415
+ animationName: 'lf_animate_dash',
416
+ animationDuration: '20s',
417
+ animationIterationCount: 'infinite',
418
+ animationTimingFunction: 'linear',
419
+ animationDirection: 'normal',
420
+ },
421
+ rotateControl: {
422
+ stroke: '#EAEAEA',
423
+ fill: '#33353A',
424
+ strokeWidth: 1,
425
+ hover: {
426
+ fill: '#707070',
427
+ fillOpacity: 0.15,
428
+ stroke: 'transparent',
429
+ },
430
+ },
431
+ resizeControl: {
432
+ width: 8,
433
+ height: 8,
434
+ radius: 2,
435
+ fill: '#33353A',
436
+ stroke: '#EAEAEA',
437
+ hover: {
438
+ width: 12,
439
+ height: 12,
440
+ fill: '#707070',
441
+ fillOpacity: 0.15,
442
+ stroke: 'transparent',
443
+ },
444
+ },
445
+ resizeOutline: {
446
+ fill: 'transparent',
447
+ stroke: '#EAEAEA',
448
+ strokeWidth: 1.5,
449
+ strokeDasharray: '4,4',
450
+ radius: 8,
451
+ hover: {
452
+ stroke: '#4271DF',
453
+ },
454
+ },
455
+ };
456
+ exports.colorfulTheme = {
457
+ baseNode: {
458
+ fill: '#fff',
459
+ stroke: '#474747',
460
+ strokeWidth: 2,
461
+ radius: 12,
462
+ },
463
+ baseEdge: {
464
+ stroke: '#474747',
465
+ strokeWidth: 2,
466
+ radius: 12,
467
+ },
468
+ rect: { fill: '#72CBFF', stroke: '#3ABDF9', radius: 8 },
469
+ circle: { fill: '#FFE075', stroke: '#F9CE3A', radius: 8 },
470
+ ellipse: { fill: '#FFA8A8', stroke: '#FF6B66', radius: 8 },
471
+ text: { fill: '#72CBFF', radius: 8, fontSize: 12 },
472
+ diamond: { fill: '#96F7AF', stroke: '#40EF7E', radius: 8 },
473
+ polygon: { fill: '#E0A8FF', stroke: '#C271FF', radius: 8 },
474
+ nodeText: {
475
+ color: '#474747',
476
+ overflowMode: 'default',
477
+ fontSize: 12,
478
+ lineHeight: 1.2,
479
+ },
480
+ edgeText: {
481
+ textWidth: 100,
482
+ overflowMode: 'default',
483
+ fontSize: 12,
484
+ background: {
485
+ fill: '#fff',
486
+ },
487
+ },
488
+ html: {
489
+ fill: '#fff',
490
+ stroke: 'transparent',
491
+ strokeWidth: 0,
492
+ },
493
+ anchor: {
494
+ stroke: '#474747',
495
+ fill: '#fff',
496
+ r: 4,
497
+ hover: {
498
+ r: 8,
499
+ fill: '#707070',
500
+ fillOpacity: 0.15,
501
+ stroke: 'transparent',
502
+ },
503
+ },
504
+ anchorLine: {
505
+ stroke: '#474747',
506
+ strokeWidth: 2,
507
+ strokeDasharray: '3,2',
508
+ },
509
+ line: {},
510
+ polyline: { radius: 8 },
511
+ bezier: {
512
+ fill: 'none',
513
+ adjustLine: {
514
+ stroke: '#3ABDF9',
515
+ },
516
+ adjustAnchor: {
517
+ r: 4,
518
+ fill: '#3ABDF9',
519
+ fillOpacity: 1,
520
+ stroke: '#3ABDF9',
521
+ },
522
+ },
523
+ edgeAdjust: {
524
+ r: 4,
525
+ fill: '#fff',
526
+ stroke: '#474747',
527
+ strokeWidth: 1,
528
+ },
529
+ arrow: {
530
+ strokeLinecap: 'round',
531
+ strokeLinejoin: 'round',
532
+ offset: 10,
533
+ verticalLength: 5, // 箭头垂直于边的距离
534
+ },
535
+ snapline: {
536
+ strokeLinecap: 'round',
537
+ strokeLinejoin: 'round',
538
+ stroke: '#949494',
539
+ strokeWidth: 1,
540
+ },
541
+ outline: {
542
+ radius: 8,
543
+ fill: 'transparent',
544
+ stroke: '#949494',
545
+ strokeDasharray: '3,3',
546
+ hover: {
547
+ stroke: '#949494',
548
+ },
549
+ },
550
+ edgeOutline: {
551
+ fill: 'transparent',
552
+ stroke: '#757575',
553
+ strokeWidth: 1.5,
554
+ strokeDasharray: '4,4',
555
+ radius: 8,
556
+ hover: {
557
+ stroke: '#4271DF',
558
+ },
559
+ },
560
+ edgeAnimation: {
561
+ stroke: '#4271DF',
562
+ strokeDasharray: '12,4,6,4',
563
+ strokeDashoffset: '100%',
564
+ animationName: 'lf_animate_dash',
565
+ animationDuration: '20s',
566
+ animationIterationCount: 'infinite',
567
+ animationTimingFunction: 'linear',
568
+ animationDirection: 'normal',
569
+ },
570
+ rotateControl: {
571
+ stroke: '#474747',
572
+ fill: '#fff',
573
+ strokeWidth: 1,
574
+ hover: {
575
+ fill: '#707070',
576
+ fillOpacity: 0.15,
577
+ stroke: 'transparent',
578
+ },
579
+ },
580
+ resizeControl: {
581
+ width: 8,
582
+ height: 8,
583
+ radius: 2,
584
+ fill: '#fff',
585
+ stroke: '#474747',
586
+ hover: {
587
+ width: 12,
588
+ height: 12,
589
+ fill: '#707070',
590
+ fillOpacity: 0.15,
591
+ stroke: 'transparent',
592
+ },
593
+ },
594
+ resizeOutline: {
595
+ fill: 'transparent',
596
+ stroke: '#757575',
597
+ strokeWidth: 1.5,
598
+ strokeDasharray: '4,4',
599
+ radius: 8,
600
+ hover: {
601
+ stroke: '#4271DF',
602
+ },
603
+ },
604
+ };
605
+ exports.themeModeMap = {
606
+ default: exports.defaultTheme,
607
+ colorful: exports.colorfulTheme,
608
+ dark: exports.darkTheme,
609
+ retro: exports.retroTheme,
610
+ };
611
+ // 不同主题的背景色
612
+ exports.darkBackground = {
613
+ background: '#33353A',
614
+ };
615
+ exports.colorfulBackground = {
616
+ background: '#fefeff',
617
+ };
618
+ exports.defaultBackground = {
619
+ background: '#FBFCFE',
620
+ };
621
+ exports.retroBackground = {
622
+ background: '#ffffff',
623
+ };
624
+ exports.backgroundModeMap = {
625
+ colorful: exports.colorfulBackground,
626
+ dark: exports.darkBackground,
627
+ default: exports.defaultBackground,
628
+ retro: exports.retroBackground,
629
+ };
630
+ // 不同主题的网格样式
631
+ exports.darkGrid = {
632
+ size: exports.DEFAULT_GRID_SIZE,
633
+ visible: true,
634
+ type: 'mesh',
635
+ config: {
636
+ color: '#83838377',
637
+ thickness: 2,
638
+ },
639
+ majorBold: true,
640
+ };
641
+ exports.colorfulGrid = {
642
+ size: exports.DEFAULT_GRID_SIZE,
643
+ visible: true,
644
+ type: 'dot',
645
+ config: {
646
+ color: '#b7c2d9',
647
+ thickness: 2,
648
+ },
649
+ majorBold: false,
650
+ };
651
+ exports.defaultGrid = {
652
+ size: exports.DEFAULT_GRID_SIZE,
653
+ visible: true,
654
+ type: 'mesh',
655
+ config: {
656
+ color: '#D7DEEB',
657
+ thickness: 1,
658
+ },
659
+ // majorBold: true,
660
+ majorBold: {
661
+ opacity: 0.6,
662
+ boldIndices: [5],
663
+ dashArrayConfig: { pattern: [] },
664
+ customBoldWidth: 2,
665
+ },
666
+ };
667
+ exports.retroGrid = {
668
+ size: exports.DEFAULT_GRID_SIZE,
669
+ visible: true,
670
+ type: 'dot',
671
+ config: {
672
+ color: '#ababab',
673
+ thickness: 1,
674
+ },
675
+ majorBold: false,
676
+ };
677
+ exports.gridModeMap = {
678
+ colorful: exports.colorfulGrid,
679
+ dark: exports.darkGrid,
680
+ retro: exports.retroGrid,
681
+ default: exports.defaultGrid,
682
+ };
683
+ exports.default = null;
package/lib/index.css CHANGED
@@ -177,8 +177,9 @@
177
177
  }
178
178
  .lf-multiple-select {
179
179
  position: absolute;
180
- border: 2px dashed #187dffcc;
181
- box-shadow: 0 0 3px 0 #187dff80;
180
+ border: 2px dashed #4271dfcc;
181
+ border-radius: 12px;
182
+ box-shadow: 0 0 3px 0 #4271df80;
182
183
  cursor: move;
183
184
  }
184
185
  .lf-edge-adjust-point {