react-msaview 4.0.2 → 4.1.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/bundle/index.js +282 -111
- package/dist/colorSchemes.js +1 -1
- package/dist/colorSchemes.js.map +1 -1
- package/dist/components/Checkbox2.js.map +1 -1
- package/dist/components/Loading.js +5 -6
- package/dist/components/Loading.js.map +1 -1
- package/dist/components/MSAView.js +3 -4
- package/dist/components/MSAView.js.map +1 -1
- package/dist/components/ResizeHandles.js.map +1 -1
- package/dist/components/SequenceTextArea.js +1 -2
- package/dist/components/SequenceTextArea.js.map +1 -1
- package/dist/components/TextTrack.d.ts +1 -1
- package/dist/components/TextTrack.js +1 -1
- package/dist/components/TextTrack.js.map +1 -1
- package/dist/components/Track.js +4 -5
- package/dist/components/Track.js.map +1 -1
- package/dist/components/VerticalScrollbar.js +1 -1
- package/dist/components/VerticalScrollbar.js.map +1 -1
- package/dist/components/dialogs/AboutDialog.js +4 -4
- package/dist/components/dialogs/AboutDialog.js.map +1 -1
- package/dist/components/dialogs/AddTrackDialog.js +1 -1
- package/dist/components/dialogs/AddTrackDialog.js.map +1 -1
- package/dist/components/dialogs/DomainDialog.js +1 -2
- package/dist/components/dialogs/DomainDialog.js.map +1 -1
- package/dist/components/dialogs/ExportSVGDialog.js +1 -1
- package/dist/components/dialogs/ExportSVGDialog.js.map +1 -1
- package/dist/components/dialogs/FeatureDialog.js +1 -1
- package/dist/components/dialogs/FeatureDialog.js.map +1 -1
- package/dist/components/dialogs/InterProScanDialog.js +3 -3
- package/dist/components/dialogs/InterProScanDialog.js.map +1 -1
- package/dist/components/dialogs/MetadataDialog.js +3 -2
- package/dist/components/dialogs/MetadataDialog.js.map +1 -1
- package/dist/components/dialogs/SettingsDialog.js +29 -29
- package/dist/components/dialogs/SettingsDialog.js.map +1 -1
- package/dist/components/dialogs/TrackInfoDialog.js +2 -2
- package/dist/components/dialogs/TrackInfoDialog.js.map +1 -1
- package/dist/components/dialogs/TracklistDialog.js +1 -1
- package/dist/components/dialogs/TracklistDialog.js.map +1 -1
- package/dist/components/dialogs/UserProvidedDomainsDialog.js +3 -3
- package/dist/components/dialogs/UserProvidedDomainsDialog.js.map +1 -1
- package/dist/components/header/Header.js +5 -7
- package/dist/components/header/Header.js.map +1 -1
- package/dist/components/header/HeaderInfoArea.js.map +1 -1
- package/dist/components/header/HeaderMenu.js +3 -4
- package/dist/components/header/HeaderMenu.js.map +1 -1
- package/dist/components/header/HeaderMenuExtra.js +8 -9
- package/dist/components/header/HeaderMenuExtra.js.map +1 -1
- package/dist/components/header/HeaderStatusArea.js +1 -1
- package/dist/components/header/HeaderStatusArea.js.map +1 -1
- package/dist/components/header/MultiAlignmentSelector.js +1 -1
- package/dist/components/header/MultiAlignmentSelector.js.map +1 -1
- package/dist/components/header/ZoomControls.js +11 -5
- package/dist/components/header/ZoomControls.js.map +1 -1
- package/dist/components/import/ImportForm.js +19 -15
- package/dist/components/import/ImportForm.js.map +1 -1
- package/dist/components/import/ImportFormExamples.js +2 -2
- package/dist/components/import/ImportFormExamples.js.map +1 -1
- package/dist/components/import/util.d.ts +1 -1
- package/dist/components/minimap/Minimap.js.map +1 -1
- package/dist/components/minimap/MinimapSVG.js.map +1 -1
- package/dist/components/msa/Loading.js +1 -1
- package/dist/components/msa/Loading.js.map +1 -1
- package/dist/components/msa/MSACanvas.js +2 -2
- package/dist/components/msa/MSACanvas.js.map +1 -1
- package/dist/components/msa/MSACanvasBlock.js +2 -3
- package/dist/components/msa/MSACanvasBlock.js.map +1 -1
- package/dist/components/msa/MSAMouseoverCanvas.js +1 -1
- package/dist/components/msa/MSAMouseoverCanvas.js.map +1 -1
- package/dist/components/msa/MSAPanel.js +0 -1
- package/dist/components/msa/MSAPanel.js.map +1 -1
- package/dist/components/msa/renderBoxFeatureCanvasBlock.js.map +1 -1
- package/dist/components/msa/renderMSABlock.d.ts +1 -1
- package/dist/components/msa/renderMSABlock.js +9 -3
- package/dist/components/msa/renderMSABlock.js.map +1 -1
- package/dist/components/tree/TreeBranchMenu.js.map +1 -1
- package/dist/components/tree/TreeCanvas.js +1 -2
- package/dist/components/tree/TreeCanvas.js.map +1 -1
- package/dist/components/tree/TreeCanvasBlock.js +4 -5
- package/dist/components/tree/TreeCanvasBlock.js.map +1 -1
- package/dist/components/tree/TreeNodeMenu.js +5 -1
- package/dist/components/tree/TreeNodeMenu.js.map +1 -1
- package/dist/components/tree/TreePanel.js.map +1 -1
- package/dist/components/tree/TreeRuler.js.map +1 -1
- package/dist/components/tree/dialogs/TreeNodeInfoDialog.js +2 -1
- package/dist/components/tree/dialogs/TreeNodeInfoDialog.js.map +1 -1
- package/dist/components/tree/renderTreeCanvas.d.ts +2 -2
- package/dist/components/tree/renderTreeCanvas.js +5 -5
- package/dist/components/tree/renderTreeCanvas.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js.map +1 -1
- package/dist/launchInterProScan.js.map +1 -1
- package/dist/model/DialogQueue.js.map +1 -1
- package/dist/model/treeModel.d.ts +1 -1
- package/dist/model/treeModel.js +1 -1
- package/dist/model/treeModel.js.map +1 -1
- package/dist/model.d.ts +30 -34
- package/dist/model.js +71 -40
- package/dist/model.js.map +1 -1
- package/dist/parsers/ClustalMSA.js.map +1 -1
- package/dist/parsers/EmfMSA.js.map +1 -1
- package/dist/parsers/StockholmMSA.js.map +1 -1
- package/dist/renderToSvg.d.ts +1 -1
- package/dist/renderToSvg.js +5 -6
- package/dist/renderToSvg.js.map +1 -1
- package/dist/rowCoordinateCalculations.test.js.map +1 -1
- package/dist/util.d.ts +1 -1
- package/dist/util.js +1 -1
- package/dist/util.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +4 -5
- package/src/colorSchemes.ts +2 -1
- package/src/components/Checkbox2.tsx +1 -0
- package/src/components/Loading.tsx +7 -6
- package/src/components/MSAView.tsx +6 -5
- package/src/components/ResizeHandles.tsx +1 -1
- package/src/components/SequenceTextArea.tsx +2 -2
- package/src/components/TextTrack.tsx +5 -3
- package/src/components/Track.tsx +5 -5
- package/src/components/VerticalScrollbar.tsx +5 -2
- package/src/components/dialogs/AboutDialog.tsx +6 -7
- package/src/components/dialogs/AddTrackDialog.tsx +7 -5
- package/src/components/dialogs/DomainDialog.tsx +3 -2
- package/src/components/dialogs/ExportSVGDialog.tsx +7 -5
- package/src/components/dialogs/FeatureDialog.tsx +4 -3
- package/src/components/dialogs/InterProScanDialog.tsx +6 -5
- package/src/components/dialogs/MetadataDialog.tsx +6 -7
- package/src/components/dialogs/SettingsDialog.tsx +24 -22
- package/src/components/dialogs/TrackInfoDialog.tsx +3 -2
- package/src/components/dialogs/TracklistDialog.tsx +4 -4
- package/src/components/dialogs/UserProvidedDomainsDialog.tsx +7 -6
- package/src/components/header/Header.tsx +8 -11
- package/src/components/header/HeaderInfoArea.tsx +1 -1
- package/src/components/header/HeaderMenu.tsx +4 -6
- package/src/components/header/HeaderMenuExtra.tsx +9 -11
- package/src/components/header/HeaderStatusArea.tsx +2 -2
- package/src/components/header/MultiAlignmentSelector.tsx +2 -2
- package/src/components/header/ZoomControls.tsx +13 -6
- package/src/components/import/ImportForm.tsx +31 -24
- package/src/components/import/ImportFormExamples.tsx +5 -4
- package/src/components/import/util.ts +1 -1
- package/src/components/minimap/Minimap.tsx +2 -0
- package/src/components/minimap/MinimapSVG.tsx +2 -0
- package/src/components/msa/Loading.tsx +2 -1
- package/src/components/msa/MSACanvas.tsx +5 -4
- package/src/components/msa/MSACanvasBlock.tsx +5 -4
- package/src/components/msa/MSAMouseoverCanvas.tsx +4 -3
- package/src/components/msa/MSAPanel.tsx +2 -1
- package/src/components/msa/renderBoxFeatureCanvasBlock.ts +1 -3
- package/src/components/msa/renderMSABlock.ts +11 -10
- package/src/components/tree/TreeBranchMenu.tsx +1 -1
- package/src/components/tree/TreeCanvas.tsx +4 -4
- package/src/components/tree/TreeCanvasBlock.tsx +7 -7
- package/src/components/tree/TreeNodeMenu.tsx +10 -1
- package/src/components/tree/TreePanel.tsx +3 -1
- package/src/components/tree/TreeRuler.tsx +1 -1
- package/src/components/tree/dialogs/TreeNodeInfoDialog.tsx +5 -6
- package/src/components/tree/renderTreeCanvas.ts +7 -9
- package/src/index.ts +1 -1
- package/src/launchInterProScan.ts +2 -0
- package/src/model/DialogQueue.ts +2 -1
- package/src/model/treeModel.ts +1 -1
- package/src/model.ts +89 -58
- package/src/parsers/ClustalMSA.ts +1 -0
- package/src/parsers/EmfMSA.ts +1 -0
- package/src/parsers/StockholmMSA.ts +1 -1
- package/src/renderToSvg.tsx +7 -9
- package/src/rowCoordinateCalculations.test.ts +1 -0
- package/src/util.ts +4 -3
- package/src/version.ts +1 -1
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import React, { useState } from 'react'
|
|
2
|
+
|
|
3
|
+
import { ErrorMessage, FileSelector } from '@jbrowse/core/ui'
|
|
4
|
+
import { Button, Container, Typography } from '@mui/material'
|
|
2
5
|
import { observer } from 'mobx-react'
|
|
3
|
-
import { Button, Container, Grid, Typography } from '@mui/material'
|
|
4
|
-
import { FileSelector } from '@jbrowse/core/ui'
|
|
5
|
-
import type { FileLocation } from '@jbrowse/core/util/types'
|
|
6
6
|
|
|
7
|
-
// locals
|
|
8
|
-
import type { MsaViewModel } from '../../model'
|
|
9
|
-
import { load } from './util'
|
|
10
7
|
import ImportFormExamples from './ImportFormExamples'
|
|
8
|
+
import { load } from './util'
|
|
9
|
+
|
|
10
|
+
import type { MsaViewModel } from '../../model'
|
|
11
|
+
import type { FileLocation } from '@jbrowse/core/util/types'
|
|
11
12
|
|
|
12
13
|
const ImportForm = observer(function ({ model }: { model: MsaViewModel }) {
|
|
13
14
|
const [msaFile, setMsaFile] = useState<FileLocation>()
|
|
@@ -17,11 +18,7 @@ const ImportForm = observer(function ({ model }: { model: MsaViewModel }) {
|
|
|
17
18
|
return (
|
|
18
19
|
<Container>
|
|
19
20
|
<div style={{ width: '50%' }}>
|
|
20
|
-
{error ?
|
|
21
|
-
<div style={{ padding: 20 }}>
|
|
22
|
-
<Typography color="error">Error: {`${error}`}</Typography>
|
|
23
|
-
</div>
|
|
24
|
-
) : null}
|
|
21
|
+
{error ? <ErrorMessage error={error} /> : null}
|
|
25
22
|
<Typography>
|
|
26
23
|
Open an MSA file (stockholm or clustal format) and/or a tree file
|
|
27
24
|
(newick format).
|
|
@@ -34,15 +31,25 @@ const ImportForm = observer(function ({ model }: { model: MsaViewModel }) {
|
|
|
34
31
|
</Typography>
|
|
35
32
|
</div>
|
|
36
33
|
|
|
37
|
-
<
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
<
|
|
34
|
+
<div
|
|
35
|
+
style={{
|
|
36
|
+
display: 'flex',
|
|
37
|
+
justifyContent: 'center',
|
|
38
|
+
alignItems: 'center',
|
|
39
|
+
gap: 40,
|
|
40
|
+
}}
|
|
41
|
+
>
|
|
42
|
+
<div>
|
|
43
|
+
<div>
|
|
44
|
+
<Typography>MSA file or URL</Typography>
|
|
45
|
+
<FileSelector location={msaFile} setLocation={setMsaFile} />
|
|
46
|
+
</div>
|
|
47
|
+
<div>
|
|
48
|
+
<Typography>Tree file or URL</Typography>
|
|
49
|
+
<FileSelector location={treeFile} setLocation={setTreeFile} />
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
<div>
|
|
46
53
|
<Button
|
|
47
54
|
onClick={() => {
|
|
48
55
|
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
|
@@ -61,13 +68,13 @@ const ImportForm = observer(function ({ model }: { model: MsaViewModel }) {
|
|
|
61
68
|
>
|
|
62
69
|
Open
|
|
63
70
|
</Button>
|
|
64
|
-
</
|
|
71
|
+
</div>
|
|
65
72
|
|
|
66
|
-
<
|
|
73
|
+
<div>
|
|
67
74
|
<Typography>Examples</Typography>
|
|
68
75
|
<ImportFormExamples model={model} />
|
|
69
|
-
</
|
|
70
|
-
</
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
71
78
|
</Container>
|
|
72
79
|
)
|
|
73
80
|
})
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
import { Link, Typography } from '@mui/material'
|
|
3
4
|
import { observer } from 'mobx-react'
|
|
4
5
|
|
|
5
|
-
|
|
6
|
-
import type { MsaViewModel } from '../../model'
|
|
7
|
-
import { smallTree, smallMSA, smallMSAOnly } from './data/seq2'
|
|
6
|
+
import { smallMSA, smallMSAOnly, smallTree } from './data/seq2'
|
|
8
7
|
import { load } from './util'
|
|
9
8
|
|
|
9
|
+
import type { MsaViewModel } from '../../model'
|
|
10
|
+
|
|
10
11
|
function ListItem({
|
|
11
12
|
onClick,
|
|
12
13
|
model,
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import React, { useEffect,
|
|
1
|
+
import React, { useEffect, useRef, useState } from 'react'
|
|
2
|
+
|
|
2
3
|
import { observer } from 'mobx-react'
|
|
3
4
|
|
|
4
|
-
// locals
|
|
5
|
-
import type { MsaViewModel } from '../../model'
|
|
6
|
-
import MSACanvasBlock from './MSACanvasBlock'
|
|
7
5
|
import Loading from './Loading'
|
|
6
|
+
import MSACanvasBlock from './MSACanvasBlock'
|
|
7
|
+
|
|
8
|
+
import type { MsaViewModel } from '../../model'
|
|
8
9
|
|
|
9
10
|
const MSACanvas = observer(function ({ model }: { model: MsaViewModel }) {
|
|
10
11
|
const {
|
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
import React, { useEffect,
|
|
1
|
+
import React, { useEffect, useMemo, useRef } from 'react'
|
|
2
|
+
|
|
2
3
|
import { useTheme } from '@mui/material'
|
|
3
4
|
import { autorun } from 'mobx'
|
|
4
5
|
import { observer } from 'mobx-react'
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
import { renderBoxFeatureCanvasBlock } from './renderBoxFeatureCanvasBlock'
|
|
7
8
|
import { renderMSABlock } from './renderMSABlock'
|
|
8
|
-
import type { MsaViewModel } from '../../model'
|
|
9
9
|
import { colorContrast } from '../../util'
|
|
10
|
-
|
|
10
|
+
|
|
11
|
+
import type { MsaViewModel } from '../../model'
|
|
11
12
|
|
|
12
13
|
const MSACanvasBlock = observer(function ({
|
|
13
14
|
model,
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import React, { useEffect, useRef } from 'react'
|
|
2
|
-
|
|
2
|
+
|
|
3
3
|
import { autorun } from 'mobx'
|
|
4
|
+
import { observer } from 'mobx-react'
|
|
4
5
|
|
|
5
|
-
// locals
|
|
6
|
-
import type { MsaViewModel } from '../../model'
|
|
7
6
|
import { renderMouseover } from './renderMSAMouseover'
|
|
8
7
|
|
|
8
|
+
import type { MsaViewModel } from '../../model'
|
|
9
|
+
|
|
9
10
|
const MSAMouseoverCanvas = observer(function ({
|
|
10
11
|
model,
|
|
11
12
|
}: {
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import type { HierarchyNode } from 'd3-hierarchy'
|
|
2
|
-
|
|
3
|
-
// locals
|
|
4
1
|
import type { MsaViewModel } from '../../model'
|
|
5
2
|
import type { NodeWithIdsAndLength } from '../../util'
|
|
3
|
+
import type { HierarchyNode } from 'd3-hierarchy'
|
|
6
4
|
|
|
7
5
|
export function renderBoxFeatureCanvasBlock({
|
|
8
6
|
model,
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import type { Theme } from '@mui/material'
|
|
1
|
+
import { getClustalXColor, getPercentIdentityColor } from '../../colorSchemes'
|
|
3
2
|
|
|
4
|
-
// locals
|
|
5
3
|
import type { MsaViewModel } from '../../model'
|
|
6
|
-
import { getClustalXColor, getPercentIdentityColor } from '../../colorSchemes'
|
|
7
4
|
import type { NodeWithIdsAndLength } from '../../util'
|
|
5
|
+
import type { Theme } from '@mui/material'
|
|
6
|
+
import type { HierarchyNode } from 'd3-hierarchy'
|
|
8
7
|
|
|
9
8
|
export function renderMSABlock({
|
|
10
9
|
model,
|
|
@@ -98,8 +97,6 @@ function drawTiles({
|
|
|
98
97
|
bgColor,
|
|
99
98
|
colorSchemeName,
|
|
100
99
|
colorScheme,
|
|
101
|
-
colStats,
|
|
102
|
-
colStatsSums,
|
|
103
100
|
columns,
|
|
104
101
|
colWidth,
|
|
105
102
|
rowHeight,
|
|
@@ -117,16 +114,20 @@ function drawTiles({
|
|
|
117
114
|
const color =
|
|
118
115
|
colorSchemeName === 'clustalx_protein_dynamic'
|
|
119
116
|
? getClustalXColor(
|
|
120
|
-
colStats
|
|
121
|
-
|
|
117
|
+
// use model.colStats dot notation here: delay use of colStats
|
|
118
|
+
// until absolutely needed
|
|
119
|
+
model.colStats[xStart + i]!,
|
|
120
|
+
model.colStatsSums[xStart + i]!,
|
|
122
121
|
model,
|
|
123
122
|
name,
|
|
124
123
|
xStart + i,
|
|
125
124
|
)
|
|
126
125
|
: colorSchemeName === 'percent_identity_dynamic'
|
|
127
126
|
? getPercentIdentityColor(
|
|
128
|
-
colStats
|
|
129
|
-
|
|
127
|
+
// use model.colStats dot notation here: delay use of
|
|
128
|
+
// colStats until absolutely needed
|
|
129
|
+
model.colStats[xStart + i]!,
|
|
130
|
+
model.colStatsSums[xStart + i]!,
|
|
130
131
|
model,
|
|
131
132
|
name,
|
|
132
133
|
xStart + i,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
|
|
1
|
+
import React, { useEffect, useRef, useState } from 'react'
|
|
2
|
+
|
|
3
3
|
import { observer } from 'mobx-react'
|
|
4
4
|
|
|
5
|
-
// locals
|
|
6
|
-
import type { MsaViewModel } from '../../model'
|
|
7
5
|
import TreeCanvasBlock from './TreeCanvasBlock'
|
|
8
6
|
import { padding } from './renderTreeCanvas'
|
|
9
7
|
|
|
8
|
+
import type { MsaViewModel } from '../../model'
|
|
9
|
+
|
|
10
10
|
const TreeCanvas = observer(function ({ model }: { model: MsaViewModel }) {
|
|
11
11
|
const ref = useRef<HTMLDivElement>(null)
|
|
12
12
|
const scheduled = useRef(false)
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
|
|
1
|
+
import React, { useCallback, useEffect, useRef, useState } from 'react'
|
|
2
|
+
|
|
3
|
+
import { useTheme } from '@mui/material'
|
|
3
4
|
import { autorun } from 'mobx'
|
|
4
5
|
import { observer } from 'mobx-react'
|
|
5
|
-
import { useTheme } from '@mui/material'
|
|
6
6
|
import RBush from 'rbush'
|
|
7
7
|
|
|
8
|
-
// locals
|
|
9
|
-
import type { MsaViewModel } from '../../model'
|
|
10
|
-
import TreeNodeMenu from './TreeNodeMenu'
|
|
11
8
|
import TreeBranchMenu from './TreeBranchMenu'
|
|
9
|
+
import TreeNodeMenu from './TreeNodeMenu'
|
|
12
10
|
import { padding, renderTreeCanvas } from './renderTreeCanvas'
|
|
13
11
|
|
|
12
|
+
import type { MsaViewModel } from '../../model'
|
|
13
|
+
|
|
14
14
|
interface TooltipData {
|
|
15
15
|
name: string
|
|
16
16
|
id: string
|
|
@@ -36,7 +36,7 @@ const TreeCanvasBlock = observer(function ({
|
|
|
36
36
|
offsetY: number
|
|
37
37
|
}) {
|
|
38
38
|
const theme = useTheme()
|
|
39
|
-
const ref = useRef<HTMLCanvasElement>()
|
|
39
|
+
const ref = useRef<HTMLCanvasElement>(null)
|
|
40
40
|
const clickMap = useRef(new RBush<ClickEntry>())
|
|
41
41
|
const mouseoverRef = useRef<HTMLCanvasElement>(null)
|
|
42
42
|
const [branchMenu, setBranchMenu] = useState<TooltipData>()
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { lazy } from 'react'
|
|
2
|
+
|
|
2
3
|
import { Menu, MenuItem } from '@mui/material'
|
|
3
4
|
import { observer } from 'mobx-react'
|
|
4
5
|
|
|
5
|
-
// locals
|
|
6
6
|
import type { MsaViewModel } from '../../model'
|
|
7
7
|
|
|
8
8
|
// lazies
|
|
@@ -76,6 +76,15 @@ const TreeMenu = observer(function ({
|
|
|
76
76
|
? 'Show node'
|
|
77
77
|
: 'Hide node'}
|
|
78
78
|
</MenuItem>
|
|
79
|
+
<MenuItem
|
|
80
|
+
dense
|
|
81
|
+
onClick={() => {
|
|
82
|
+
model.drawRelativeTo(node.id)
|
|
83
|
+
onClose()
|
|
84
|
+
}}
|
|
85
|
+
>
|
|
86
|
+
Indicate differences from this row
|
|
87
|
+
</MenuItem>
|
|
79
88
|
</Menu>
|
|
80
89
|
)
|
|
81
90
|
})
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
|
+
|
|
2
3
|
import { observer } from 'mobx-react'
|
|
3
4
|
|
|
4
|
-
import type { MsaViewModel } from '../../model'
|
|
5
5
|
import TreeCanvas from './TreeCanvas'
|
|
6
6
|
|
|
7
|
+
import type { MsaViewModel } from '../../model'
|
|
8
|
+
|
|
7
9
|
const TreePanel = observer(function ({ model }: { model: MsaViewModel }) {
|
|
8
10
|
const { treeAreaWidth } = model
|
|
9
11
|
return (
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
|
+
|
|
3
|
+
import Attributes from '@jbrowse/core/BaseFeatureWidget/BaseFeatureDetail/Attributes'
|
|
4
|
+
import BaseCard from '@jbrowse/core/BaseFeatureWidget/BaseFeatureDetail/BaseCard'
|
|
2
5
|
import { Dialog } from '@jbrowse/core/ui'
|
|
3
6
|
import { DialogContent } from '@mui/material'
|
|
4
7
|
import { observer } from 'mobx-react'
|
|
5
|
-
import {
|
|
6
|
-
Attributes,
|
|
7
|
-
BaseCard,
|
|
8
|
-
} from '@jbrowse/core/BaseFeatureWidget/BaseFeatureDetail'
|
|
9
8
|
|
|
10
|
-
// locals
|
|
11
|
-
import type { MsaViewModel } from '../../../model'
|
|
12
9
|
import SequenceTextArea from '../../SequenceTextArea'
|
|
13
10
|
|
|
11
|
+
import type { MsaViewModel } from '../../../model'
|
|
12
|
+
|
|
14
13
|
const TreeNodeInfoDialog = observer(function ({
|
|
15
14
|
info,
|
|
16
15
|
model,
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import type RBush from 'rbush'
|
|
2
|
-
import type { Theme } from '@mui/material'
|
|
3
|
-
|
|
4
|
-
// locals
|
|
5
1
|
import type { MsaViewModel } from '../../model'
|
|
2
|
+
import type { Theme } from '@mui/material'
|
|
3
|
+
import type RBush from 'rbush'
|
|
6
4
|
|
|
7
5
|
export const padding = 600
|
|
8
6
|
|
|
@@ -255,11 +253,11 @@ export function renderTreeCanvas({
|
|
|
255
253
|
|
|
256
254
|
ctx.resetTransform()
|
|
257
255
|
|
|
258
|
-
// this is a bogus use of nref, it is never less than 0. we just are using
|
|
259
|
-
// in this statement because otherwise it would be an unused variable,
|
|
260
|
-
// just need to use nref to indicate a redraw in an autorun when canvas
|
|
261
|
-
// is updated and in order to convince bundlers like not to delete
|
|
262
|
-
// usage with propertyReadSideEffects
|
|
256
|
+
// this is a bogus use of nref, it is never less than 0. we just are using
|
|
257
|
+
// it in this statement because otherwise it would be an unused variable,
|
|
258
|
+
// we just need to use nref to indicate a redraw in an autorun when canvas
|
|
259
|
+
// ref is updated and in order to convince bundlers like not to delete
|
|
260
|
+
// unused usage with propertyReadSideEffects
|
|
263
261
|
const k =
|
|
264
262
|
nref < 0
|
|
265
263
|
? Number.NEGATIVE_INFINITY
|
package/src/index.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { default as MSAView } from './components/Loading'
|
|
2
|
-
export { default as MSAModelF
|
|
2
|
+
export { type MsaViewModel, default as MSAModelF } from './model'
|
package/src/model/DialogQueue.ts
CHANGED