@voplus/morpho-document 1.4.44 → 1.4.45
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.
|
@@ -1,111 +1,111 @@
|
|
|
1
|
-
@import "~@voplus/antd/es/style/themes/default.less";
|
|
2
|
-
.reference-view {
|
|
3
|
-
display: flex;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
height: 100%;
|
|
6
|
-
:global {
|
|
7
|
-
.reference-header {
|
|
8
|
-
display: flex;
|
|
9
|
-
margin: 5px 20px 0 20px;
|
|
10
|
-
.multiple-remove {
|
|
11
|
-
font-weight: 600;
|
|
12
|
-
color: #000;
|
|
13
|
-
cursor: pointer;
|
|
14
|
-
.ant-btn {
|
|
15
|
-
padding: 0 10px 0 0;
|
|
16
|
-
font-size: 16px;
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
.multiple-remove-btn {
|
|
20
|
-
.ant-btn {
|
|
21
|
-
padding: 0 10px;
|
|
22
|
-
font-style: italic;
|
|
23
|
-
}
|
|
24
|
-
.del-btn {
|
|
25
|
-
color: #ff4d4f;
|
|
26
|
-
&:hover {
|
|
27
|
-
color: #ff7875;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
.cancel-btn {
|
|
31
|
-
color: #666;
|
|
32
|
-
&:hover {
|
|
33
|
-
color: @primary-color;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
.plus-icon {
|
|
38
|
-
display: inline-block;
|
|
39
|
-
padding: 4px;
|
|
40
|
-
margin-left: 10px;
|
|
41
|
-
font-size: 13px;
|
|
42
|
-
line-height: 1px;
|
|
43
|
-
background: #1abc9c;
|
|
44
|
-
cursor: pointer;
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
.reference-view-page {
|
|
48
|
-
display: block;
|
|
49
|
-
}
|
|
50
|
-
.reference-item {
|
|
51
|
-
display: flex;
|
|
52
|
-
position: relative;
|
|
53
|
-
justify-content: space-between;
|
|
54
|
-
align-items: center;
|
|
55
|
-
padding: 5px 20px;
|
|
56
|
-
&:hover {
|
|
57
|
-
cursor: pointer;
|
|
58
|
-
.reference-item-content {
|
|
59
|
-
opacity: 0.4;
|
|
60
|
-
}
|
|
61
|
-
.reference-status-none {
|
|
62
|
-
display: none;
|
|
63
|
-
}
|
|
64
|
-
.hover-operate-icon {
|
|
65
|
-
display: block;
|
|
66
|
-
opacity: 1;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
.reference-item-content {
|
|
70
|
-
flex: 1;
|
|
71
|
-
color: #000;
|
|
72
|
-
font-weight: 500;
|
|
73
|
-
.reference-content {
|
|
74
|
-
display: flex;
|
|
75
|
-
flex: 1;
|
|
76
|
-
.type-icon {
|
|
77
|
-
font-size: 15px;
|
|
78
|
-
padding-right: 10px;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
.task-item-name.task-item-name_done {
|
|
82
|
-
color: #a8a8a8;
|
|
83
|
-
}
|
|
84
|
-
.task-control {
|
|
85
|
-
display: flex;
|
|
86
|
-
align-items: center;
|
|
87
|
-
padding: 5px 0;
|
|
88
|
-
font-size: 13px;
|
|
89
|
-
color: #444;
|
|
90
|
-
font-weight: normal;
|
|
91
|
-
> span + span {
|
|
92
|
-
margin-left: 15px;
|
|
93
|
-
}
|
|
94
|
-
.svg-inline--fa {
|
|
95
|
-
margin-right: 5px;
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.hover-operate-icon {
|
|
101
|
-
display: none;
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
.ant-empty {
|
|
105
|
-
font-size: 12px;
|
|
106
|
-
.ant-empty-image {
|
|
107
|
-
height: 35px;
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
}
|
|
1
|
+
@import "~@voplus/antd/es/style/themes/default.less";
|
|
2
|
+
.reference-view {
|
|
3
|
+
display: flex;
|
|
4
|
+
flex-direction: column;
|
|
5
|
+
height: 100%;
|
|
6
|
+
:global {
|
|
7
|
+
.reference-header {
|
|
8
|
+
display: flex;
|
|
9
|
+
margin: 5px 20px 0 20px;
|
|
10
|
+
.multiple-remove {
|
|
11
|
+
font-weight: 600;
|
|
12
|
+
color: #000;
|
|
13
|
+
cursor: pointer;
|
|
14
|
+
.ant-btn {
|
|
15
|
+
padding: 0 10px 0 0;
|
|
16
|
+
font-size: 16px;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
.multiple-remove-btn {
|
|
20
|
+
.ant-btn {
|
|
21
|
+
padding: 0 10px;
|
|
22
|
+
font-style: italic;
|
|
23
|
+
}
|
|
24
|
+
.del-btn {
|
|
25
|
+
color: #ff4d4f;
|
|
26
|
+
&:hover {
|
|
27
|
+
color: #ff7875;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
.cancel-btn {
|
|
31
|
+
color: #666;
|
|
32
|
+
&:hover {
|
|
33
|
+
color: @primary-color;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
.plus-icon {
|
|
38
|
+
display: inline-block;
|
|
39
|
+
padding: 4px;
|
|
40
|
+
margin-left: 10px;
|
|
41
|
+
font-size: 13px;
|
|
42
|
+
line-height: 1px;
|
|
43
|
+
background: #1abc9c;
|
|
44
|
+
cursor: pointer;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
.reference-view-page {
|
|
48
|
+
display: block;
|
|
49
|
+
}
|
|
50
|
+
.reference-item {
|
|
51
|
+
display: flex;
|
|
52
|
+
position: relative;
|
|
53
|
+
justify-content: space-between;
|
|
54
|
+
align-items: center;
|
|
55
|
+
padding: 5px 20px;
|
|
56
|
+
&:hover {
|
|
57
|
+
cursor: pointer;
|
|
58
|
+
.reference-item-content {
|
|
59
|
+
opacity: 0.4;
|
|
60
|
+
}
|
|
61
|
+
.reference-status-none {
|
|
62
|
+
display: none;
|
|
63
|
+
}
|
|
64
|
+
.hover-operate-icon {
|
|
65
|
+
display: block;
|
|
66
|
+
opacity: 1;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
.reference-item-content {
|
|
70
|
+
flex: 1;
|
|
71
|
+
color: #000;
|
|
72
|
+
font-weight: 500;
|
|
73
|
+
.reference-content {
|
|
74
|
+
display: flex;
|
|
75
|
+
flex: 1;
|
|
76
|
+
.type-icon {
|
|
77
|
+
font-size: 15px;
|
|
78
|
+
padding-right: 10px;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
.task-item-name.task-item-name_done {
|
|
82
|
+
color: #a8a8a8;
|
|
83
|
+
}
|
|
84
|
+
.task-control {
|
|
85
|
+
display: flex;
|
|
86
|
+
align-items: center;
|
|
87
|
+
padding: 5px 0;
|
|
88
|
+
font-size: 13px;
|
|
89
|
+
color: #444;
|
|
90
|
+
font-weight: normal;
|
|
91
|
+
> span + span {
|
|
92
|
+
margin-left: 15px;
|
|
93
|
+
}
|
|
94
|
+
.svg-inline--fa {
|
|
95
|
+
margin-right: 5px;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.hover-operate-icon {
|
|
101
|
+
display: none;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
.ant-empty {
|
|
105
|
+
font-size: 12px;
|
|
106
|
+
.ant-empty-image {
|
|
107
|
+
height: 35px;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
@@ -9,10 +9,12 @@ import { runInAction } from "mobx";
|
|
|
9
9
|
import styles from "./index.less";
|
|
10
10
|
import { useAsideContentContext } from "@voplus/morpho-ui/es/components/layout/AsideContent";
|
|
11
11
|
import { useDocumentStore } from "@voplus/morpho-document-core";
|
|
12
|
+
import { useLayout } from "@voplus/morpho-data";
|
|
12
13
|
/** new document from */
|
|
13
14
|
const NewDocumentForm = (props) => {
|
|
14
15
|
const { Option } = Select;
|
|
15
16
|
const { placeholder } = props;
|
|
17
|
+
const layout = useLayout();
|
|
16
18
|
const documents = useDocumentStore();
|
|
17
19
|
const asideContext = useAsideContentContext();
|
|
18
20
|
const [state] = useState(new State({ parentId: props.parentId }));
|
|
@@ -28,8 +30,11 @@ const NewDocumentForm = (props) => {
|
|
|
28
30
|
React.createElement(Input, { autoFocus: true, value: state.params.name, placeholder: placeholder
|
|
29
31
|
? placeholder
|
|
30
32
|
: `Add a ${state.params.type === "document" ? "folder" : state.params.type} for this document`, onChange: (e) => runInAction(() => (state.params.name = e.target.value)), onPressEnter: () => state.onSubmit(documents), onKeyDown: (e) => onKeyDown(e) }),
|
|
31
|
-
|
|
32
|
-
React.createElement(
|
|
33
|
+
layout.ui.mobile ?
|
|
34
|
+
React.createElement(Button, { type: "primary", className: "margin-left-10", onClick: () => state.onSubmit(documents) }, "Submit")
|
|
35
|
+
:
|
|
36
|
+
React.createElement("span", { className: "detailed" },
|
|
37
|
+
React.createElement(FAIcon, { icon: faListAlt, size: "lg" })))))),
|
|
33
38
|
props.showView && (React.createElement(React.Fragment, null,
|
|
34
39
|
React.createElement(Form.Item, null,
|
|
35
40
|
React.createElement("div", { className: "form-item-layout" },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/NewDocumentForm/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEnD,OAAO,EAAE,eAAe,IAAI,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAC3E,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,UAAU,MAAM,YAAY,CAAC;AAEpC,OAAO,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAC7D,OAAO,E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