@plait/mind 0.12.1 → 0.13.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/esm2020/node.component.mjs +1 -2
- package/esm2020/plugins/with-abstract-resize.mjs +4 -4
- package/esm2020/plugins/with-mind-hotkey.mjs +101 -16
- package/esm2020/plugins/with-mind.mjs +3 -91
- package/esm2020/plugins/with-node-dnd.mjs +19 -24
- package/esm2020/utils/mind.mjs +1 -2
- package/esm2020/utils/node/common.mjs +2 -2
- package/esm2020/utils/position/topic.mjs +5 -2
- package/fesm2015/plait-mind.mjs +117 -129
- package/fesm2015/plait-mind.mjs.map +1 -1
- package/fesm2020/plait-mind.mjs +117 -129
- package/fesm2020/plait-mind.mjs.map +1 -1
- package/package.json +1 -1
- package/plugins/with-mind-hotkey.d.ts +4 -1
- package/styles/styles.scss +37 -33
package/package.json
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
import { PlaitBoard } from '@plait/core';
|
|
2
2
|
export declare const withMindHotkey: (board: PlaitBoard) => PlaitBoard;
|
|
3
|
-
export declare const isExpandHotkey: (
|
|
3
|
+
export declare const isExpandHotkey: (event: KeyboardEvent) => boolean;
|
|
4
|
+
export declare const isTabHotkey: (event: KeyboardEvent) => boolean;
|
|
5
|
+
export declare const isEnterHotkey: (event: KeyboardEvent) => boolean;
|
|
6
|
+
export declare const isSpaceHotkey: (event: KeyboardEvent) => boolean;
|
package/styles/styles.scss
CHANGED
|
@@ -2,44 +2,46 @@
|
|
|
2
2
|
|
|
3
3
|
$primary: #4e8afa;
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
.plait-board-container {
|
|
6
|
+
// The font family under SAFARI affects the measurement of the text size,
|
|
7
|
+
// so specify the default font family to avoid unexpected text breaks in different scene
|
|
8
|
+
font-family: PingFangSC-Regular, 'PingFang SC';
|
|
9
|
+
g[plait-mindmap='true'] {
|
|
10
|
+
.root {
|
|
11
|
+
.text {
|
|
12
|
+
font-family: PingFangSC-Medium, 'PingFang SC';
|
|
13
|
+
font-weight: 400;
|
|
14
|
+
}
|
|
10
15
|
}
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
16
|
+
.branch {
|
|
17
|
+
.text {
|
|
18
|
+
font-family: PingFangSC-Medium, 'PingFang SC';
|
|
19
|
+
}
|
|
15
20
|
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
.slate-editable-container {
|
|
22
|
+
cursor: default;
|
|
23
|
+
min-width: 5px;
|
|
24
|
+
&.editing {
|
|
25
|
+
cursor: text;
|
|
26
|
+
max-width: 34em;
|
|
27
|
+
}
|
|
23
28
|
}
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.extend {
|
|
27
|
-
opacity: 0;
|
|
28
|
-
cursor: default;
|
|
29
|
-
}
|
|
30
29
|
|
|
31
|
-
.collapsed {
|
|
32
30
|
.extend {
|
|
33
|
-
opacity:
|
|
31
|
+
opacity: 0;
|
|
32
|
+
cursor: default;
|
|
34
33
|
}
|
|
35
|
-
}
|
|
36
34
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
35
|
+
.collapsed {
|
|
36
|
+
.extend {
|
|
37
|
+
opacity: 1;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
41
40
|
|
|
42
|
-
.
|
|
41
|
+
.dragging-node {
|
|
42
|
+
opacity: 0.6;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
43
45
|
&.focused:not(.selection-moving):not(.element-moving):not(.abstract-resizing-horizontal):not(.abstract-resizing-vertical):not(.pointer-mind):not(.mind-node-dragging) {
|
|
44
46
|
.extend {
|
|
45
47
|
cursor: pointer;
|
|
@@ -110,9 +112,11 @@ g[plait-mindmap='true'] {
|
|
|
110
112
|
&.dragging {
|
|
111
113
|
cursor: pointer;
|
|
112
114
|
opacity: 0.6;
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
115
|
+
// Compact: Safari
|
|
116
|
+
// Opacity property will cause text position warning
|
|
117
|
+
// .plait-richtext-container {
|
|
118
|
+
// opacity: 0.6;
|
|
119
|
+
// }
|
|
116
120
|
}
|
|
117
121
|
}
|
|
118
122
|
|