@jbrowse/plugin-linear-genome-view 5.0.0-beta.13 → 5.0.0-beta.15
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/esm/FeatureTrack/configSchema.d.ts +2 -1
- package/esm/FeatureTrack/configSchema.js +2 -1
- package/esm/LinearGenomeView/afterAttach.js +1 -23
- package/esm/LinearGenomeView/components/ExportSvgDialog.d.ts +6 -2
- package/esm/LinearGenomeView/components/ExportSvgDialog.js +31 -7
- package/esm/LinearGenomeView/components/HeaderPanControls.d.ts +3 -3
- package/esm/LinearGenomeView/components/HeaderPanControls.js +4 -2
- package/esm/LinearGenomeView/components/HighlightBand.d.ts +3 -2
- package/esm/LinearGenomeView/components/HighlightBand.js +4 -2
- package/esm/LinearGenomeView/components/HighlightChip.d.ts +3 -2
- package/esm/LinearGenomeView/components/HighlightChip.js +4 -2
- package/esm/LinearGenomeView/components/LinearGenomeView.js +5 -12
- package/esm/LinearGenomeView/components/LinearGenomeViewContainer.js +4 -5
- package/esm/LinearGenomeView/components/OverviewHighlightBand.d.ts +3 -2
- package/esm/LinearGenomeView/components/OverviewHighlightBand.js +4 -2
- package/esm/LinearGenomeView/components/RegionWidthEditorDialog.d.ts +3 -2
- package/esm/LinearGenomeView/components/RegionWidthEditorDialog.js +4 -4
- package/esm/LinearGenomeView/components/ScalebarRefNameLabels.js +4 -4
- package/esm/LinearGenomeView/components/SearchPanelForm.d.ts +3 -2
- package/esm/LinearGenomeView/components/SearchPanelForm.js +4 -2
- package/esm/LinearGenomeView/components/SearchResultsDialog.d.ts +4 -9
- package/esm/LinearGenomeView/components/SearchResultsDialog.js +7 -4
- package/esm/LinearGenomeView/components/SearchResultsTable.d.ts +3 -8
- package/esm/LinearGenomeView/components/SearchResultsTable.js +4 -32
- package/esm/LinearGenomeView/components/StrandCheckboxes.d.ts +3 -2
- package/esm/LinearGenomeView/components/StrandCheckboxes.js +4 -2
- package/esm/LinearGenomeView/components/TrackContainer.js +1 -1
- package/esm/LinearGenomeView/components/TrackLabelMenu.js +8 -12
- package/esm/LinearGenomeView/components/useRangeSelect.js +3 -2
- package/esm/LinearGenomeView/components/useSearchBoxPrefs.d.ts +3 -1
- package/esm/LinearGenomeView/components/useSearchBoxPrefs.js +4 -2
- package/esm/LinearGenomeView/components/useSideScroll.js +11 -12
- package/esm/LinearGenomeView/lazyDialogs.d.ts +17 -2
- package/esm/LinearGenomeView/menuItems.js +32 -24
- package/esm/LinearGenomeView/model.d.ts +121 -65
- package/esm/LinearGenomeView/model.js +143 -135
- package/esm/LinearGenomeView/rExport/exportLinearView.d.ts +13 -0
- package/esm/LinearGenomeView/rExport/exportLinearView.js +98 -0
- package/esm/LinearGenomeView/rExport/rScript.d.ts +75 -0
- package/esm/LinearGenomeView/rExport/rScript.js +464 -0
- package/esm/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js +3 -6
- package/esm/LinearGenomeView/svgcomponents/SVGStackedRow.d.ts +1 -2
- package/esm/LinearGenomeView/svgcomponents/SVGStackedRow.js +2 -2
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.d.ts +1 -2
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.js +4 -4
- package/esm/LinearGenomeView/svgcomponents/SVGView.d.ts +1 -2
- package/esm/LinearGenomeView/svgcomponents/SVGView.js +3 -3
- package/esm/LinearGenomeView/svgcomponents/renderViewTracks.d.ts +22 -20
- package/esm/LinearGenomeView/svgcomponents/renderViewTracks.js +42 -29
- package/esm/LinearGenomeView/svgcomponents/useViewSvgFigure.js +6 -11
- package/esm/LinearGenomeView/svgcomponents/util.d.ts +2 -1
- package/esm/LinearGenomeView/util.d.ts +42 -0
- package/esm/LinearGenomeView/util.js +81 -0
- package/esm/MultiLevelRubberband/MultiLevelRubberband.js +2 -2
- package/esm/displayKitTests/perRegionTestEnv.d.ts +45 -12
- package/esm/index.d.ts +4 -2
- package/esm/index.js +3 -1
- package/esm/searchUtils.js +1 -0
- package/esm/shared/RubberbandSpan.d.ts +3 -2
- package/esm/shared/RubberbandSpan.js +4 -2
- package/esm/shared/coordLabels.d.ts +6 -6
- package/esm/shared/coordLabels.js +7 -6
- package/package.json +9 -9
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
export declare const LABEL_WIDTH = 100;
|
|
2
2
|
/** A red vertical line at `coordX` with `children` labelled above it. */
|
|
3
|
-
export declare
|
|
3
|
+
export declare const VerticalGuideLine: ({ coordX, viewWidth, stickyTop, children, }: {
|
|
4
4
|
coordX: number;
|
|
5
5
|
viewWidth: number;
|
|
6
6
|
stickyTop: string | undefined;
|
|
7
7
|
children: React.ReactNode;
|
|
8
|
-
})
|
|
8
|
+
}) => import("react").JSX.Element;
|
|
9
9
|
/**
|
|
10
10
|
* The bp coordinate under a vertical guide, drawn just above the top of the
|
|
11
11
|
* guide line so it covers neither the line nor the cursor hovering the scalebar
|
|
@@ -26,22 +26,22 @@ export declare function VerticalGuideLine({ coordX, viewWidth, stickyTop, childr
|
|
|
26
26
|
* measured once per hover, not per mousemove — only `coordX` changes as the
|
|
27
27
|
* mouse moves, and that needs no measurement.
|
|
28
28
|
*/
|
|
29
|
-
export declare
|
|
29
|
+
export declare const GuideLabel: ({ coordX, viewWidth, stickyTop, children, }: {
|
|
30
30
|
coordX: number;
|
|
31
31
|
viewWidth: number;
|
|
32
32
|
stickyTop: string | undefined;
|
|
33
33
|
children: React.ReactNode;
|
|
34
|
-
})
|
|
34
|
+
}) => import("react").JSX.Element;
|
|
35
35
|
/**
|
|
36
36
|
* The bp coordinates of a rubberband selection, one label just outside each edge
|
|
37
37
|
* of the span. Renders inside the span, so the edges are its own box. A label
|
|
38
38
|
* with no room outside its edge flips inside instead, which is why the span it
|
|
39
39
|
* has to fit in is a prop.
|
|
40
40
|
*/
|
|
41
|
-
export declare
|
|
41
|
+
export declare const SpanEdgeLabels: ({ stickyTop, left, right, insideLeft, insideRight, }: {
|
|
42
42
|
stickyTop: string | undefined;
|
|
43
43
|
left: React.ReactNode;
|
|
44
44
|
right: React.ReactNode;
|
|
45
45
|
insideLeft: boolean;
|
|
46
46
|
insideRight: boolean;
|
|
47
|
-
})
|
|
47
|
+
}) => import("react").JSX.Element;
|
|
@@ -3,6 +3,7 @@ import { useEffect, useRef, useState } from 'react';
|
|
|
3
3
|
import { alpha } from '@jbrowse/core/ui/palette';
|
|
4
4
|
import { MUI_TOOLTIP_Z_INDEX } from '@jbrowse/core/ui/zIndexes';
|
|
5
5
|
import { makeStyles } from '@jbrowse/core/util/tss-react';
|
|
6
|
+
import { observer } from 'mobx-react';
|
|
6
7
|
import { createPortal } from 'react-dom';
|
|
7
8
|
// roughly how wide a coordinate label is. the guide clamps itself half of this
|
|
8
9
|
// from either border, and a rubberband label that would hang off a border goes
|
|
@@ -62,10 +63,10 @@ const useStyles = makeStyles()(theme => ({
|
|
|
62
63
|
},
|
|
63
64
|
}));
|
|
64
65
|
/** A red vertical line at `coordX` with `children` labelled above it. */
|
|
65
|
-
export function VerticalGuideLine({ coordX, viewWidth, stickyTop, children, }) {
|
|
66
|
+
export const VerticalGuideLine = observer(function VerticalGuideLine({ coordX, viewWidth, stickyTop, children, }) {
|
|
66
67
|
const { classes } = useStyles();
|
|
67
68
|
return (_jsxs(_Fragment, { children: [_jsx(GuideLabel, { coordX: coordX, viewWidth: viewWidth, stickyTop: stickyTop, children: children }), _jsx("div", { className: classes.guideLine, style: { transform: `translateX(${coordX}px)` } })] }));
|
|
68
|
-
}
|
|
69
|
+
});
|
|
69
70
|
function anchorStyle(stickyTop) {
|
|
70
71
|
return stickyTop === undefined
|
|
71
72
|
? { position: 'relative' }
|
|
@@ -91,7 +92,7 @@ function anchorStyle(stickyTop) {
|
|
|
91
92
|
* measured once per hover, not per mousemove — only `coordX` changes as the
|
|
92
93
|
* mouse moves, and that needs no measurement.
|
|
93
94
|
*/
|
|
94
|
-
export function GuideLabel({ coordX, viewWidth, stickyTop, children, }) {
|
|
95
|
+
export const GuideLabel = observer(function GuideLabel({ coordX, viewWidth, stickyTop, children, }) {
|
|
95
96
|
const { classes, cx } = useStyles();
|
|
96
97
|
const anchorRef = useRef(null);
|
|
97
98
|
const [anchorPos, setAnchorPos] = useState();
|
|
@@ -120,14 +121,14 @@ export function GuideLabel({ coordX, viewWidth, stickyTop, children, }) {
|
|
|
120
121
|
bottom: anchorPos.viewportHeight - anchorPos.top + LABEL_GAP,
|
|
121
122
|
}, children: children }), document.body)
|
|
122
123
|
: null] }));
|
|
123
|
-
}
|
|
124
|
+
});
|
|
124
125
|
/**
|
|
125
126
|
* The bp coordinates of a rubberband selection, one label just outside each edge
|
|
126
127
|
* of the span. Renders inside the span, so the edges are its own box. A label
|
|
127
128
|
* with no room outside its edge flips inside instead, which is why the span it
|
|
128
129
|
* has to fit in is a prop.
|
|
129
130
|
*/
|
|
130
|
-
export function SpanEdgeLabels({ stickyTop, left, right, insideLeft, insideRight, }) {
|
|
131
|
+
export const SpanEdgeLabels = observer(function SpanEdgeLabels({ stickyTop, left, right, insideLeft, insideRight, }) {
|
|
131
132
|
const { classes, cx } = useStyles();
|
|
132
133
|
return (_jsxs("div", { className: classes.anchor, style: anchorStyle(stickyTop), children: [_jsx("div", { className: cx(classes.label, classes.spanLabel, insideLeft ? classes.insideLeftEdge : classes.leftOfEdge), children: left }), _jsx("div", { className: cx(classes.label, classes.spanLabel, insideRight ? classes.insideRightEdge : classes.rightOfEdge), children: right })] }));
|
|
133
|
-
}
|
|
134
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jbrowse/plugin-linear-genome-view",
|
|
3
|
-
"version": "5.0.0-beta.
|
|
3
|
+
"version": "5.0.0-beta.15",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "JBrowse 2 linear genome view",
|
|
6
6
|
"keywords": [
|
|
@@ -21,15 +21,15 @@
|
|
|
21
21
|
"esm"
|
|
22
22
|
],
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@jbrowse/mobx-state-tree": "^6.
|
|
25
|
-
"@mui/icons-material": "^9.
|
|
26
|
-
"@mui/material": "^9.
|
|
24
|
+
"@jbrowse/mobx-state-tree": "^6.9.0",
|
|
25
|
+
"@mui/icons-material": "^9.5.0",
|
|
26
|
+
"@mui/material": "^9.5.0",
|
|
27
27
|
"mobx": "^7.0.6",
|
|
28
28
|
"mobx-react": "^10.0.2",
|
|
29
|
-
"@jbrowse/
|
|
30
|
-
"@jbrowse/
|
|
31
|
-
"@jbrowse/
|
|
32
|
-
"@jbrowse/
|
|
29
|
+
"@jbrowse/display-kit": "^5.0.0-beta.15",
|
|
30
|
+
"@jbrowse/display-ui": "^5.0.0-beta.15",
|
|
31
|
+
"@jbrowse/core": "^5.0.0-beta.15",
|
|
32
|
+
"@jbrowse/render-core": "^5.0.0-beta.15"
|
|
33
33
|
},
|
|
34
34
|
"peerDependencies": {
|
|
35
35
|
"react": ">=19.0.0",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
},
|
|
41
41
|
"sideEffects": false,
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@jbrowse/display-test-utils": "^5.0.0-beta.
|
|
43
|
+
"@jbrowse/display-test-utils": "^5.0.0-beta.15"
|
|
44
44
|
},
|
|
45
45
|
"scripts": {
|
|
46
46
|
"prebuild": "pnpm clean",
|