@teselagen/ove 0.7.15 → 0.7.16
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/Menlo.ttf +0 -0
- package/Monaco.ttf +0 -0
- package/StatusBar/index.d.ts +8 -0
- package/html2canvas.esm--JN4fLQL.mjs +7891 -0
- package/html2canvas.esm-B7d7VJmQ.js +7891 -0
- package/html2canvas.esm-GLpiTZLt.cjs +7891 -0
- package/html2canvas.esm-GLpiTZLt.js +7891 -0
- package/html2canvas.esm-nFNn58sx.js +7891 -0
- package/html2canvas.esm-nFNn58sx.mjs +7891 -0
- package/index.cjs.js +310 -462
- package/index.es.js +311 -463
- package/index.umd.js +312 -464
- package/package.json +3 -2
- package/src/FindBar/index.js +3 -4
- package/src/StatusBar/index.js +14 -10
- package/src/helperComponents/PropertiesDialog/GeneralProperties.js +20 -40
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teselagen/ove",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.16",
|
|
4
4
|
"main": "./src/index.js",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"@teselagen/sequence-utils": "0.3.27",
|
|
14
14
|
"@teselagen/range-utils": "0.3.7",
|
|
15
|
-
"@teselagen/ui": "0.7.
|
|
15
|
+
"@teselagen/ui": "0.7.18",
|
|
16
16
|
"@teselagen/file-utils": "0.3.18",
|
|
17
17
|
"@teselagen/bounce-loader": "0.3.11",
|
|
18
18
|
"@teselagen/bio-parsers": "0.4.22",
|
|
@@ -60,6 +60,7 @@
|
|
|
60
60
|
"mock-fs": "5.2.0",
|
|
61
61
|
"nanoid": "^4.0.0",
|
|
62
62
|
"node-interval-tree": "^1.3.3",
|
|
63
|
+
"papaparse": "5.3.2",
|
|
63
64
|
"paths-js": "^0.4.11",
|
|
64
65
|
"pluralize": "^7.0.0",
|
|
65
66
|
"popper.js": "^1.16.1",
|
package/src/FindBar/index.js
CHANGED
|
@@ -5,14 +5,13 @@ import {
|
|
|
5
5
|
Switch,
|
|
6
6
|
Popover,
|
|
7
7
|
Position,
|
|
8
|
-
HTMLSelect,
|
|
9
8
|
TextArea,
|
|
10
9
|
Tooltip
|
|
11
10
|
} from "@blueprintjs/core";
|
|
12
11
|
import withEditorProps from "../withEditorProps";
|
|
13
12
|
import { MAX_MATCHES_DISPLAYED } from "../constants/findToolConstants";
|
|
14
13
|
import "./style.css";
|
|
15
|
-
import { InfoHelper } from "@teselagen/ui";
|
|
14
|
+
import { InfoHelper, TgHTMLSelect } from "@teselagen/ui";
|
|
16
15
|
import { searchableTypes } from "../selectors/annotationSearchSelector";
|
|
17
16
|
import { getSingular } from "../utils/annotationTypes";
|
|
18
17
|
import { getFeatureToColorMap } from "@teselagen/sequence-utils";
|
|
@@ -83,7 +82,7 @@ export class FindBar extends React.Component {
|
|
|
83
82
|
}
|
|
84
83
|
};
|
|
85
84
|
const findOptionsEls = [
|
|
86
|
-
<
|
|
85
|
+
<TgHTMLSelect
|
|
87
86
|
key="dnaoraa"
|
|
88
87
|
options={opts}
|
|
89
88
|
name="dnaOrAA"
|
|
@@ -93,7 +92,7 @@ export class FindBar extends React.Component {
|
|
|
93
92
|
}}
|
|
94
93
|
/>,
|
|
95
94
|
<div style={{ display: "flex" }} key="ambiguousorliteral">
|
|
96
|
-
<
|
|
95
|
+
<TgHTMLSelect
|
|
97
96
|
name="ambiguousOrLiteral"
|
|
98
97
|
options={[
|
|
99
98
|
{ label: "Literal", value: "LITERAL" },
|
package/src/StatusBar/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import { Button, Classes
|
|
2
|
+
import { Button, Classes } from "@blueprintjs/core";
|
|
3
3
|
|
|
4
4
|
import {
|
|
5
5
|
connectToEditor,
|
|
@@ -15,8 +15,9 @@ import useMeltingTemp from "../utils/useMeltingTemp";
|
|
|
15
15
|
import MeltingTemp from "./MeltingTemp";
|
|
16
16
|
import { getSequenceWithinRange } from "@teselagen/range-utils";
|
|
17
17
|
import { handleReadOnlyChange } from "../ToolBar/editTool";
|
|
18
|
+
import { TgHTMLSelect } from "@teselagen/ui";
|
|
18
19
|
|
|
19
|
-
const EditReadOnlyItem = connectToEditor(({ readOnly }) => ({
|
|
20
|
+
export const EditReadOnlyItem = connectToEditor(({ readOnly }) => ({
|
|
20
21
|
readOnly
|
|
21
22
|
}))(props => {
|
|
22
23
|
const {
|
|
@@ -26,12 +27,15 @@ const EditReadOnlyItem = connectToEditor(({ readOnly }) => ({
|
|
|
26
27
|
disableSetReadOnly,
|
|
27
28
|
disableBpEditing
|
|
28
29
|
} = props;
|
|
30
|
+
const disabled = disableSetReadOnly || !onSave; //the !onSave here is redundant
|
|
29
31
|
return showReadOnly ? (
|
|
30
32
|
<StatusBarItem dataTest="veStatusBar-readOnly">
|
|
31
33
|
{onSave ? (
|
|
32
|
-
<
|
|
34
|
+
<TgHTMLSelect
|
|
33
35
|
data-tip={
|
|
34
|
-
!readOnly &&
|
|
36
|
+
!readOnly && typeof disableBpEditing === "string"
|
|
37
|
+
? disableBpEditing
|
|
38
|
+
: undefined
|
|
35
39
|
}
|
|
36
40
|
options={[
|
|
37
41
|
{
|
|
@@ -43,8 +47,8 @@ const EditReadOnlyItem = connectToEditor(({ readOnly }) => ({
|
|
|
43
47
|
value: "editable"
|
|
44
48
|
}
|
|
45
49
|
]}
|
|
46
|
-
disabled={
|
|
47
|
-
className={Classes.MINIMAL}
|
|
50
|
+
disabled={disabled}
|
|
51
|
+
className={Classes.MINIMAL + " veReadOnlySelect"}
|
|
48
52
|
value={readOnly ? "readOnly" : "editable"}
|
|
49
53
|
onChange={({ target: { value } }) =>
|
|
50
54
|
handleReadOnlyChange(value === "readOnly", props)
|
|
@@ -153,7 +157,7 @@ const ShowTypeItem = connectToEditor(({ sequenceData }) => ({
|
|
|
153
157
|
return <StatusBarItem dataTest="veStatusBar-type">{type}</StatusBarItem>;
|
|
154
158
|
});
|
|
155
159
|
|
|
156
|
-
const EditCircularityItem = compose(
|
|
160
|
+
export const EditCircularityItem = compose(
|
|
157
161
|
connectToEditor(
|
|
158
162
|
({
|
|
159
163
|
readOnly,
|
|
@@ -176,7 +180,7 @@ const EditCircularityItem = compose(
|
|
|
176
180
|
"Linear"
|
|
177
181
|
)
|
|
178
182
|
) : (
|
|
179
|
-
<
|
|
183
|
+
<TgHTMLSelect
|
|
180
184
|
onChange={({ target: { value } }) => {
|
|
181
185
|
updateCircular(value === "circular");
|
|
182
186
|
}}
|
|
@@ -191,7 +195,7 @@ const EditCircularityItem = compose(
|
|
|
191
195
|
</StatusBarItem>
|
|
192
196
|
) : null;
|
|
193
197
|
});
|
|
194
|
-
const EditAvailabilityItem = connectToEditor(
|
|
198
|
+
export const EditAvailabilityItem = connectToEditor(
|
|
195
199
|
({ readOnly, sequenceData: { materiallyAvailable } = {} }) => ({
|
|
196
200
|
readOnly,
|
|
197
201
|
materiallyAvailable
|
|
@@ -206,7 +210,7 @@ const EditAvailabilityItem = connectToEditor(
|
|
|
206
210
|
"Unavailable"
|
|
207
211
|
)
|
|
208
212
|
) : (
|
|
209
|
-
<
|
|
213
|
+
<TgHTMLSelect
|
|
210
214
|
onChange={({ target: { value } }) => {
|
|
211
215
|
updateAvailability(value === "available");
|
|
212
216
|
}}
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import { InputField,
|
|
2
|
+
import { InputField, TextareaField } from "@teselagen/ui";
|
|
3
3
|
import { reduxForm } from "redux-form";
|
|
4
4
|
import withEditorProps from "../../withEditorProps";
|
|
5
5
|
import { compose } from "recompose";
|
|
6
|
-
import {
|
|
6
|
+
import {
|
|
7
|
+
EditAvailabilityItem,
|
|
8
|
+
EditCircularityItem,
|
|
9
|
+
EditReadOnlyItem
|
|
10
|
+
} from "../../StatusBar";
|
|
7
11
|
|
|
8
12
|
class GeneralProperties extends React.Component {
|
|
9
13
|
updateSeqDesc = val => {
|
|
@@ -13,13 +17,14 @@ class GeneralProperties extends React.Component {
|
|
|
13
17
|
const {
|
|
14
18
|
readOnly,
|
|
15
19
|
showReadOnly = true,
|
|
16
|
-
updateCircular,
|
|
17
20
|
isProtein,
|
|
18
21
|
disableSetReadOnly,
|
|
19
|
-
updateAvailability,
|
|
20
22
|
sequenceData,
|
|
21
23
|
onSave,
|
|
22
24
|
showAvailability,
|
|
25
|
+
beforeReadOnlyChange,
|
|
26
|
+
editorName,
|
|
27
|
+
disableBpEditing,
|
|
23
28
|
sequenceNameUpdate
|
|
24
29
|
} = this.props;
|
|
25
30
|
const {
|
|
@@ -28,9 +33,7 @@ class GeneralProperties extends React.Component {
|
|
|
28
33
|
isOligo,
|
|
29
34
|
isRna,
|
|
30
35
|
sequence = "",
|
|
31
|
-
proteinSequence = ""
|
|
32
|
-
circular,
|
|
33
|
-
materiallyAvailable
|
|
36
|
+
proteinSequence = ""
|
|
34
37
|
} = sequenceData || {};
|
|
35
38
|
return (
|
|
36
39
|
<React.Fragment>
|
|
@@ -48,22 +51,13 @@ class GeneralProperties extends React.Component {
|
|
|
48
51
|
/>{" "}
|
|
49
52
|
</div>
|
|
50
53
|
</div>
|
|
54
|
+
|
|
51
55
|
{!isProtein && !isOligo && !isRna && (
|
|
52
56
|
<div className="ve-flex-row circularLinearSelect">
|
|
53
57
|
<div className="ve-column-left bp3-label">Circular/Linear</div>{" "}
|
|
54
58
|
<div className="ve-column-right">
|
|
55
59
|
{" "}
|
|
56
|
-
<
|
|
57
|
-
disabled={readOnly}
|
|
58
|
-
onChange={val => {
|
|
59
|
-
updateCircular(val === "circular");
|
|
60
|
-
}}
|
|
61
|
-
value={circular ? "circular" : "linear"}
|
|
62
|
-
options={[
|
|
63
|
-
{ label: "Circular", value: "circular" },
|
|
64
|
-
{ label: "Linear", value: "linear" }
|
|
65
|
-
]}
|
|
66
|
-
/>
|
|
60
|
+
<EditCircularityItem editorName={editorName} showCircularity />
|
|
67
61
|
</div>
|
|
68
62
|
</div>
|
|
69
63
|
)}
|
|
@@ -75,17 +69,7 @@ class GeneralProperties extends React.Component {
|
|
|
75
69
|
</div>{" "}
|
|
76
70
|
<div className="ve-column-right">
|
|
77
71
|
{" "}
|
|
78
|
-
<
|
|
79
|
-
disabled={readOnly}
|
|
80
|
-
onChange={val => {
|
|
81
|
-
updateAvailability(val === "available");
|
|
82
|
-
}}
|
|
83
|
-
value={materiallyAvailable ? "available" : "unavailable"}
|
|
84
|
-
options={[
|
|
85
|
-
{ label: "Available", value: "available" },
|
|
86
|
-
{ label: "Unavailable", value: "unavailable" }
|
|
87
|
-
]}
|
|
88
|
-
/>
|
|
72
|
+
<EditAvailabilityItem editorName={editorName} showAvailability />
|
|
89
73
|
</div>
|
|
90
74
|
</div>
|
|
91
75
|
)}
|
|
@@ -101,17 +85,13 @@ class GeneralProperties extends React.Component {
|
|
|
101
85
|
<div className="ve-column-left bp3-label">Is Editable</div>{" "}
|
|
102
86
|
<div className="ve-column-right">
|
|
103
87
|
{" "}
|
|
104
|
-
<
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
options={[
|
|
112
|
-
{ label: "Read Only", value: "readOnly" },
|
|
113
|
-
{ label: "Editable", value: "editable" }
|
|
114
|
-
]}
|
|
88
|
+
<EditReadOnlyItem
|
|
89
|
+
beforeReadOnlyChange={beforeReadOnlyChange}
|
|
90
|
+
editorName={editorName}
|
|
91
|
+
onSave={onSave}
|
|
92
|
+
disableBpEditing={disableBpEditing}
|
|
93
|
+
disableSetReadOnly={disableSetReadOnly}
|
|
94
|
+
showReadOnly={showReadOnly}
|
|
115
95
|
/>
|
|
116
96
|
</div>
|
|
117
97
|
</div>
|