@jbrowse/plugin-linear-comparative-view 2.6.1 → 2.6.3
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/dist/LGVSyntenyDisplay/configSchemaF.d.ts +1 -3
- package/dist/LGVSyntenyDisplay/configSchemaF.js +0 -1
- package/dist/LGVSyntenyDisplay/index.js +0 -1
- package/dist/LGVSyntenyDisplay/model.d.ts +17 -76
- package/dist/LGVSyntenyDisplay/model.js +22 -4
- package/dist/LaunchLinearSyntenyView.js +0 -1
- package/dist/LinearComparativeDisplay/configSchemaF.js +0 -1
- package/dist/LinearComparativeDisplay/index.js +0 -1
- package/dist/LinearComparativeDisplay/stateModelFactory.js +0 -1
- package/dist/LinearComparativeView/components/Header.js +11 -2
- package/dist/LinearComparativeView/components/LinearComparativeView.js +0 -1
- package/dist/LinearComparativeView/components/Rubberband.js +11 -33
- package/dist/LinearComparativeView/components/VerticalGuide.d.ts +8 -0
- package/dist/LinearComparativeView/components/VerticalGuide.js +33 -0
- package/dist/LinearComparativeView/index.js +0 -1
- package/dist/LinearComparativeView/model.d.ts +9 -15
- package/dist/LinearComparativeView/model.js +0 -1
- package/dist/LinearReadVsRef/LinearReadVsRef.js +0 -1
- package/dist/LinearReadVsRef/index.js +0 -1
- package/dist/LinearSyntenyDisplay/afterAttach.js +0 -1
- package/dist/LinearSyntenyDisplay/components/Component.js +0 -1
- package/dist/LinearSyntenyDisplay/components/LinearSyntenyRendering.js +0 -1
- package/dist/LinearSyntenyDisplay/components/SyntenyTooltip.js +0 -1
- package/dist/LinearSyntenyDisplay/components/util.js +0 -1
- package/dist/LinearSyntenyDisplay/configSchemaF.js +0 -1
- package/dist/LinearSyntenyDisplay/drawSynteny.js +0 -1
- package/dist/LinearSyntenyDisplay/index.js +0 -1
- package/dist/LinearSyntenyDisplay/model.js +0 -1
- package/dist/LinearSyntenyView/components/ExportSvgDialog.js +0 -1
- package/dist/LinearSyntenyView/components/Icons.js +0 -1
- package/dist/LinearSyntenyView/components/ImportCustomTrack.js +0 -1
- package/dist/LinearSyntenyView/components/ImportForm.js +0 -1
- package/dist/LinearSyntenyView/components/ImportSyntenyTrackSelector.js +0 -1
- package/dist/LinearSyntenyView/components/LinearSyntenyView.js +0 -1
- package/dist/LinearSyntenyView/index.js +0 -1
- package/dist/LinearSyntenyView/model.d.ts +9 -9
- package/dist/LinearSyntenyView/model.js +0 -1
- package/dist/LinearSyntenyView/svgcomponents/SVGBackground.js +2 -2
- package/dist/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js +0 -1
- package/dist/SyntenyFeatureDetail/SyntenyFeatureDetail.js +0 -1
- package/dist/SyntenyFeatureDetail/index.js +0 -1
- package/dist/SyntenyTrack/configSchema.js +0 -1
- package/dist/SyntenyTrack/index.js +0 -1
- package/dist/index.js +0 -1
- package/dist/util.js +0 -1
- package/esm/LGVSyntenyDisplay/configSchemaF.d.ts +1 -3
- package/esm/LGVSyntenyDisplay/configSchemaF.js +0 -1
- package/esm/LGVSyntenyDisplay/index.js +0 -1
- package/esm/LGVSyntenyDisplay/model.d.ts +17 -76
- package/esm/LGVSyntenyDisplay/model.js +23 -5
- package/esm/LaunchLinearSyntenyView.js +0 -1
- package/esm/LinearComparativeDisplay/configSchemaF.js +0 -1
- package/esm/LinearComparativeDisplay/index.js +0 -1
- package/esm/LinearComparativeDisplay/stateModelFactory.js +0 -1
- package/esm/LinearComparativeView/components/Header.js +11 -2
- package/esm/LinearComparativeView/components/LinearComparativeView.js +0 -1
- package/esm/LinearComparativeView/components/Rubberband.js +8 -33
- package/esm/LinearComparativeView/components/VerticalGuide.d.ts +8 -0
- package/esm/LinearComparativeView/components/VerticalGuide.js +28 -0
- package/esm/LinearComparativeView/index.js +0 -1
- package/esm/LinearComparativeView/model.d.ts +9 -15
- package/esm/LinearComparativeView/model.js +0 -1
- package/esm/LinearReadVsRef/LinearReadVsRef.js +0 -1
- package/esm/LinearReadVsRef/index.js +0 -1
- package/esm/LinearSyntenyDisplay/afterAttach.js +0 -1
- package/esm/LinearSyntenyDisplay/components/Component.js +0 -1
- package/esm/LinearSyntenyDisplay/components/LinearSyntenyRendering.js +0 -1
- package/esm/LinearSyntenyDisplay/components/SyntenyTooltip.js +0 -1
- package/esm/LinearSyntenyDisplay/components/util.js +0 -1
- package/esm/LinearSyntenyDisplay/configSchemaF.js +0 -1
- package/esm/LinearSyntenyDisplay/drawSynteny.js +0 -1
- package/esm/LinearSyntenyDisplay/index.js +0 -1
- package/esm/LinearSyntenyDisplay/model.js +0 -1
- package/esm/LinearSyntenyView/components/ExportSvgDialog.js +0 -1
- package/esm/LinearSyntenyView/components/Icons.js +0 -1
- package/esm/LinearSyntenyView/components/ImportCustomTrack.js +0 -1
- package/esm/LinearSyntenyView/components/ImportForm.js +0 -1
- package/esm/LinearSyntenyView/components/ImportSyntenyTrackSelector.js +0 -1
- package/esm/LinearSyntenyView/components/LinearSyntenyView.js +0 -1
- package/esm/LinearSyntenyView/index.js +0 -1
- package/esm/LinearSyntenyView/model.d.ts +9 -9
- package/esm/LinearSyntenyView/model.js +0 -1
- package/esm/LinearSyntenyView/svgcomponents/SVGBackground.js +2 -2
- package/esm/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js +0 -1
- package/esm/SyntenyFeatureDetail/SyntenyFeatureDetail.js +0 -1
- package/esm/SyntenyFeatureDetail/index.js +0 -1
- package/esm/SyntenyTrack/configSchema.js +0 -1
- package/esm/SyntenyTrack/index.js +0 -1
- package/esm/index.js +0 -1
- package/esm/util.js +0 -1
- package/package.json +4 -4
- package/dist/LGVSyntenyDisplay/configSchemaF.js.map +0 -1
- package/dist/LGVSyntenyDisplay/index.js.map +0 -1
- package/dist/LGVSyntenyDisplay/model.js.map +0 -1
- package/dist/LaunchLinearSyntenyView.js.map +0 -1
- package/dist/LinearComparativeDisplay/configSchemaF.js.map +0 -1
- package/dist/LinearComparativeDisplay/index.js.map +0 -1
- package/dist/LinearComparativeDisplay/stateModelFactory.js.map +0 -1
- package/dist/LinearComparativeView/components/Header.js.map +0 -1
- package/dist/LinearComparativeView/components/LinearComparativeView.js.map +0 -1
- package/dist/LinearComparativeView/components/Rubberband.js.map +0 -1
- package/dist/LinearComparativeView/index.js.map +0 -1
- package/dist/LinearComparativeView/model.js.map +0 -1
- package/dist/LinearReadVsRef/LinearReadVsRef.js.map +0 -1
- package/dist/LinearReadVsRef/index.js.map +0 -1
- package/dist/LinearSyntenyDisplay/afterAttach.js.map +0 -1
- package/dist/LinearSyntenyDisplay/components/Component.js.map +0 -1
- package/dist/LinearSyntenyDisplay/components/LinearSyntenyRendering.js.map +0 -1
- package/dist/LinearSyntenyDisplay/components/SyntenyTooltip.js.map +0 -1
- package/dist/LinearSyntenyDisplay/components/util.js.map +0 -1
- package/dist/LinearSyntenyDisplay/configSchemaF.js.map +0 -1
- package/dist/LinearSyntenyDisplay/drawSynteny.js.map +0 -1
- package/dist/LinearSyntenyDisplay/index.js.map +0 -1
- package/dist/LinearSyntenyDisplay/model.js.map +0 -1
- package/dist/LinearSyntenyView/components/ExportSvgDialog.js.map +0 -1
- package/dist/LinearSyntenyView/components/Icons.js.map +0 -1
- package/dist/LinearSyntenyView/components/ImportCustomTrack.js.map +0 -1
- package/dist/LinearSyntenyView/components/ImportForm.js.map +0 -1
- package/dist/LinearSyntenyView/components/ImportSyntenyTrackSelector.js.map +0 -1
- package/dist/LinearSyntenyView/components/LinearSyntenyView.js.map +0 -1
- package/dist/LinearSyntenyView/index.js.map +0 -1
- package/dist/LinearSyntenyView/model.js.map +0 -1
- package/dist/LinearSyntenyView/svgcomponents/SVGBackground.js.map +0 -1
- package/dist/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js.map +0 -1
- package/dist/SyntenyFeatureDetail/SyntenyFeatureDetail.js.map +0 -1
- package/dist/SyntenyFeatureDetail/index.js.map +0 -1
- package/dist/SyntenyTrack/configSchema.js.map +0 -1
- package/dist/SyntenyTrack/index.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/util.js.map +0 -1
- package/esm/LGVSyntenyDisplay/configSchemaF.js.map +0 -1
- package/esm/LGVSyntenyDisplay/index.js.map +0 -1
- package/esm/LGVSyntenyDisplay/model.js.map +0 -1
- package/esm/LaunchLinearSyntenyView.js.map +0 -1
- package/esm/LinearComparativeDisplay/configSchemaF.js.map +0 -1
- package/esm/LinearComparativeDisplay/index.js.map +0 -1
- package/esm/LinearComparativeDisplay/stateModelFactory.js.map +0 -1
- package/esm/LinearComparativeView/components/Header.js.map +0 -1
- package/esm/LinearComparativeView/components/LinearComparativeView.js.map +0 -1
- package/esm/LinearComparativeView/components/Rubberband.js.map +0 -1
- package/esm/LinearComparativeView/index.js.map +0 -1
- package/esm/LinearComparativeView/model.js.map +0 -1
- package/esm/LinearReadVsRef/LinearReadVsRef.js.map +0 -1
- package/esm/LinearReadVsRef/index.js.map +0 -1
- package/esm/LinearSyntenyDisplay/afterAttach.js.map +0 -1
- package/esm/LinearSyntenyDisplay/components/Component.js.map +0 -1
- package/esm/LinearSyntenyDisplay/components/LinearSyntenyRendering.js.map +0 -1
- package/esm/LinearSyntenyDisplay/components/SyntenyTooltip.js.map +0 -1
- package/esm/LinearSyntenyDisplay/components/util.js.map +0 -1
- package/esm/LinearSyntenyDisplay/configSchemaF.js.map +0 -1
- package/esm/LinearSyntenyDisplay/drawSynteny.js.map +0 -1
- package/esm/LinearSyntenyDisplay/index.js.map +0 -1
- package/esm/LinearSyntenyDisplay/model.js.map +0 -1
- package/esm/LinearSyntenyView/components/ExportSvgDialog.js.map +0 -1
- package/esm/LinearSyntenyView/components/Icons.js.map +0 -1
- package/esm/LinearSyntenyView/components/ImportCustomTrack.js.map +0 -1
- package/esm/LinearSyntenyView/components/ImportForm.js.map +0 -1
- package/esm/LinearSyntenyView/components/ImportSyntenyTrackSelector.js.map +0 -1
- package/esm/LinearSyntenyView/components/LinearSyntenyView.js.map +0 -1
- package/esm/LinearSyntenyView/index.js.map +0 -1
- package/esm/LinearSyntenyView/model.js.map +0 -1
- package/esm/LinearSyntenyView/svgcomponents/SVGBackground.js.map +0 -1
- package/esm/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js.map +0 -1
- package/esm/SyntenyFeatureDetail/SyntenyFeatureDetail.js.map +0 -1
- package/esm/SyntenyFeatureDetail/index.js.map +0 -1
- package/esm/SyntenyTrack/configSchema.js.map +0 -1
- package/esm/SyntenyTrack/index.js.map +0 -1
- package/esm/index.js.map +0 -1
- package/esm/util.js.map +0 -1
- package/src/LGVSyntenyDisplay/configSchemaF.ts +0 -22
- package/src/LGVSyntenyDisplay/index.ts +0 -20
- package/src/LGVSyntenyDisplay/model.ts +0 -177
- package/src/LaunchLinearSyntenyView.ts +0 -86
- package/src/LinearComparativeDisplay/configSchemaF.ts +0 -22
- package/src/LinearComparativeDisplay/index.ts +0 -21
- package/src/LinearComparativeDisplay/stateModelFactory.ts +0 -212
- package/src/LinearComparativeView/components/Header.tsx +0 -103
- package/src/LinearComparativeView/components/LinearComparativeView.tsx +0 -152
- package/src/LinearComparativeView/components/Rubberband.tsx +0 -329
- package/src/LinearComparativeView/index.ts +0 -15
- package/src/LinearComparativeView/model.ts +0 -395
- package/src/LinearReadVsRef/LinearReadVsRef.tsx +0 -360
- package/src/LinearReadVsRef/index.ts +0 -58
- package/src/LinearSyntenyDisplay/afterAttach.ts +0 -149
- package/src/LinearSyntenyDisplay/components/Component.tsx +0 -75
- package/src/LinearSyntenyDisplay/components/LinearSyntenyRendering.tsx +0 -200
- package/src/LinearSyntenyDisplay/components/SyntenyTooltip.tsx +0 -82
- package/src/LinearSyntenyDisplay/components/util.ts +0 -142
- package/src/LinearSyntenyDisplay/configSchemaF.ts +0 -38
- package/src/LinearSyntenyDisplay/drawSynteny.ts +0 -266
- package/src/LinearSyntenyDisplay/index.ts +0 -21
- package/src/LinearSyntenyDisplay/model.ts +0 -187
- package/src/LinearSyntenyView/components/ExportSvgDialog.tsx +0 -148
- package/src/LinearSyntenyView/components/Icons.tsx +0 -24
- package/src/LinearSyntenyView/components/ImportCustomTrack.tsx +0 -262
- package/src/LinearSyntenyView/components/ImportForm.tsx +0 -221
- package/src/LinearSyntenyView/components/ImportSyntenyTrackSelector.tsx +0 -82
- package/src/LinearSyntenyView/components/LinearSyntenyView.tsx +0 -20
- package/src/LinearSyntenyView/index.ts +0 -15
- package/src/LinearSyntenyView/model.test.ts +0 -1605
- package/src/LinearSyntenyView/model.ts +0 -169
- package/src/LinearSyntenyView/svgcomponents/SVGBackground.tsx +0 -21
- package/src/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.tsx +0 -176
- package/src/SyntenyFeatureDetail/SyntenyFeatureDetail.tsx +0 -64
- package/src/SyntenyFeatureDetail/index.ts +0 -36
- package/src/SyntenyTrack/configSchema.ts +0 -23
- package/src/SyntenyTrack/index.tsx +0 -15
- package/src/index.tsx +0 -42
- package/src/util.ts +0 -124
|
@@ -125,12 +125,12 @@ export default function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
125
125
|
toggleNoTracksActive(): void;
|
|
126
126
|
toggleShowGridlines(): void;
|
|
127
127
|
scrollTo(offsetPx: number): number;
|
|
128
|
-
zoomTo(bpPerPx: number, offset?: number
|
|
128
|
+
zoomTo(bpPerPx: number, offset?: number, centerAtOffset?: boolean): number;
|
|
129
129
|
setOffsets(left?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").BpOffset | undefined, right?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").BpOffset | undefined): void;
|
|
130
130
|
setSearchResults(searchResults: import("@jbrowse/core/TextSearch/BaseResults").default[], searchQuery: string, assemblyName?: string | undefined): void;
|
|
131
131
|
setNewView(bpPerPx: number, offsetPx: number): void;
|
|
132
132
|
horizontallyFlip(): void;
|
|
133
|
-
showTrack(trackId: string, initialSnapshot?: {}
|
|
133
|
+
showTrack(trackId: string, initialSnapshot?: {}, displayInitialSnapshot?: {}): any;
|
|
134
134
|
hideTrack(trackId: string): number;
|
|
135
135
|
} & {
|
|
136
136
|
moveTrack(movingId: string, targetId: string): void;
|
|
@@ -161,7 +161,7 @@ export default function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
161
161
|
setDraggingTrackId(idx?: string | undefined): void;
|
|
162
162
|
setScaleFactor(factor: number): void;
|
|
163
163
|
clearView(): void;
|
|
164
|
-
exportSvg(opts?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").ExportSvgOptions
|
|
164
|
+
exportSvg(opts?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").ExportSvgOptions): Promise<void>;
|
|
165
165
|
} & {
|
|
166
166
|
slide: (viewWidths: number) => void;
|
|
167
167
|
} & {
|
|
@@ -375,12 +375,12 @@ export default function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
375
375
|
toggleNoTracksActive(): void;
|
|
376
376
|
toggleShowGridlines(): void;
|
|
377
377
|
scrollTo(offsetPx: number): number;
|
|
378
|
-
zoomTo(bpPerPx: number, offset?: number
|
|
378
|
+
zoomTo(bpPerPx: number, offset?: number, centerAtOffset?: boolean): number;
|
|
379
379
|
setOffsets(left?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").BpOffset | undefined, right?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").BpOffset | undefined): void;
|
|
380
380
|
setSearchResults(searchResults: import("@jbrowse/core/TextSearch/BaseResults").default[], searchQuery: string, assemblyName?: string | undefined): void;
|
|
381
381
|
setNewView(bpPerPx: number, offsetPx: number): void;
|
|
382
382
|
horizontallyFlip(): void;
|
|
383
|
-
showTrack(trackId: string, initialSnapshot?: {}
|
|
383
|
+
showTrack(trackId: string, initialSnapshot?: {}, displayInitialSnapshot?: {}): any;
|
|
384
384
|
hideTrack(trackId: string): number;
|
|
385
385
|
} & {
|
|
386
386
|
moveTrack(movingId: string, targetId: string): void;
|
|
@@ -411,7 +411,7 @@ export default function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
411
411
|
setDraggingTrackId(idx?: string | undefined): void;
|
|
412
412
|
setScaleFactor(factor: number): void;
|
|
413
413
|
clearView(): void;
|
|
414
|
-
exportSvg(opts?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").ExportSvgOptions
|
|
414
|
+
exportSvg(opts?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").ExportSvgOptions): Promise<void>;
|
|
415
415
|
} & {
|
|
416
416
|
slide: (viewWidths: number) => void;
|
|
417
417
|
} & {
|
|
@@ -563,12 +563,12 @@ export default function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
563
563
|
toggleNoTracksActive(): void;
|
|
564
564
|
toggleShowGridlines(): void;
|
|
565
565
|
scrollTo(offsetPx: number): number;
|
|
566
|
-
zoomTo(bpPerPx: number, offset?: number
|
|
566
|
+
zoomTo(bpPerPx: number, offset?: number, centerAtOffset?: boolean): number;
|
|
567
567
|
setOffsets(left?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").BpOffset | undefined, right?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").BpOffset | undefined): void;
|
|
568
568
|
setSearchResults(searchResults: import("@jbrowse/core/TextSearch/BaseResults").default[], searchQuery: string, assemblyName?: string | undefined): void;
|
|
569
569
|
setNewView(bpPerPx: number, offsetPx: number): void;
|
|
570
570
|
horizontallyFlip(): void;
|
|
571
|
-
showTrack(trackId: string, initialSnapshot?: {}
|
|
571
|
+
showTrack(trackId: string, initialSnapshot?: {}, displayInitialSnapshot?: {}): any;
|
|
572
572
|
hideTrack(trackId: string): number;
|
|
573
573
|
} & {
|
|
574
574
|
moveTrack(movingId: string, targetId: string): void;
|
|
@@ -599,7 +599,7 @@ export default function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
599
599
|
setDraggingTrackId(idx?: string | undefined): void;
|
|
600
600
|
setScaleFactor(factor: number): void;
|
|
601
601
|
clearView(): void;
|
|
602
|
-
exportSvg(opts?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").ExportSvgOptions
|
|
602
|
+
exportSvg(opts?: import("@jbrowse/plugin-linear-genome-view/src/LinearGenomeView").ExportSvgOptions): Promise<void>;
|
|
603
603
|
} & {
|
|
604
604
|
slide: (viewWidths: number) => void;
|
|
605
605
|
} & {
|
|
@@ -5,9 +5,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const react_1 = __importDefault(require("react"));
|
|
7
7
|
const material_1 = require("@mui/material");
|
|
8
|
+
const color_1 = __importDefault(require("color"));
|
|
8
9
|
function SVGBackground({ width, height, shift, }) {
|
|
9
10
|
const theme = (0, material_1.useTheme)();
|
|
10
|
-
return (react_1.default.createElement("rect", { width: width + shift * 2, height: height, fill: theme.palette.background.default }));
|
|
11
|
+
return (react_1.default.createElement("rect", { width: width + shift * 2, height: height, fill: (0, color_1.default)(theme.palette.background.default).hex() }));
|
|
11
12
|
}
|
|
12
13
|
exports.default = SVGBackground;
|
|
13
|
-
//# sourceMappingURL=SVGBackground.js.map
|
|
@@ -82,4 +82,3 @@ async function renderToSvg(model, opts) {
|
|
|
82
82
|
react_1.default.createElement(plugin_linear_genome_view_1.SVGTracks, { textHeight: textHeight, trackLabels: trackLabels, fontSize: fontSize, model: displayResults[1].view, displayResults: displayResults[1].data, offset: offset, trackLabelOffset: trackLabelOffset }))))));
|
|
83
83
|
}
|
|
84
84
|
exports.renderToSvg = renderToSvg;
|
|
85
|
-
//# sourceMappingURL=SVGLinearSyntenyView.js.map
|
package/dist/index.js
CHANGED
package/dist/util.js
CHANGED
|
@@ -6,9 +6,7 @@ declare function configSchemaF(pluginManager: PluginManager): import("@jbrowse/c
|
|
|
6
6
|
defaultRendering: {
|
|
7
7
|
type: string;
|
|
8
8
|
model: import("mobx-state-tree").ISimpleType<string>;
|
|
9
|
-
defaultValue: string;
|
|
10
|
-
* #baseConfiguration
|
|
11
|
-
*/
|
|
9
|
+
defaultValue: string;
|
|
12
10
|
};
|
|
13
11
|
renderers: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
|
|
14
12
|
PileupRenderer: import("@jbrowse/core/configuration").AnyConfigurationSchemaType;
|
|
@@ -86,21 +86,11 @@ declare function stateModelFactory(schema: AnyConfigurationSchemaType): import("
|
|
|
86
86
|
};
|
|
87
87
|
}, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, "displayId">>;
|
|
88
88
|
} & {
|
|
89
|
-
type: import("mobx-state-tree").ISimpleType<"LinearPileupDisplay">;
|
|
90
89
|
configuration: AnyConfigurationSchemaType;
|
|
91
|
-
showSoftClipping: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
92
90
|
featureHeight: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<number>>;
|
|
93
91
|
noSpacing: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<boolean>>;
|
|
94
92
|
fadeLikelihood: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<boolean>>;
|
|
95
93
|
trackMaxHeight: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<number>>;
|
|
96
|
-
mismatchAlpha: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<boolean>>;
|
|
97
|
-
sortedBy: import("mobx-state-tree").IMaybe<import("mobx-state-tree").IModelType<{
|
|
98
|
-
type: import("mobx-state-tree").ISimpleType<string>;
|
|
99
|
-
pos: import("mobx-state-tree").ISimpleType<number>;
|
|
100
|
-
tag: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
|
|
101
|
-
refName: import("mobx-state-tree").ISimpleType<string>;
|
|
102
|
-
assemblyName: import("mobx-state-tree").ISimpleType<string>;
|
|
103
|
-
}, {}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
|
|
104
94
|
colorBy: import("mobx-state-tree").IMaybe<import("mobx-state-tree").IModelType<{
|
|
105
95
|
type: import("mobx-state-tree").ISimpleType<string>;
|
|
106
96
|
tag: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
|
|
@@ -219,7 +209,7 @@ declare function stateModelFactory(schema: AnyConfigurationSchemaType): import("
|
|
|
219
209
|
featureIdUnderMouse: string | undefined;
|
|
220
210
|
contextMenuFeature: Feature | undefined;
|
|
221
211
|
} & {
|
|
222
|
-
readonly blockType: "
|
|
212
|
+
readonly blockType: "dynamicBlocks" | "staticBlocks";
|
|
223
213
|
readonly blockDefinitions: import("@jbrowse/core/util/blockTypes").BlockSet;
|
|
224
214
|
} & {
|
|
225
215
|
readonly renderDelay: number;
|
|
@@ -250,43 +240,30 @@ declare function stateModelFactory(schema: AnyConfigurationSchemaType): import("
|
|
|
250
240
|
afterAttach(): void;
|
|
251
241
|
} & {
|
|
252
242
|
colorTagMap: import("mobx").ObservableMap<string, string>;
|
|
253
|
-
modificationTagMap: import("mobx").ObservableMap<string, string>;
|
|
254
243
|
featureUnderMouseVolatile: Feature | undefined;
|
|
255
|
-
currSortBpPerPx: number;
|
|
256
|
-
modificationsReady: boolean;
|
|
257
|
-
sortReady: boolean;
|
|
258
244
|
tagsReady: boolean;
|
|
259
245
|
} & {
|
|
260
246
|
readonly autorunReady: boolean;
|
|
261
247
|
} & {
|
|
262
|
-
setModificationsReady(flag: boolean): void;
|
|
263
248
|
setTagsReady(flag: boolean): void;
|
|
264
|
-
setSortReady(flag: boolean): void;
|
|
265
|
-
setCurrSortBpPerPx(n: number): void;
|
|
266
249
|
setMaxHeight(n: number): void;
|
|
267
250
|
setFeatureHeight(n?: number | undefined): void;
|
|
268
251
|
setNoSpacing(flag?: boolean | undefined): void;
|
|
269
252
|
setColorScheme(colorScheme: {
|
|
270
253
|
type: string;
|
|
271
254
|
tag?: string | undefined;
|
|
255
|
+
extra?: import("@jbrowse/plugin-alignments/src/shared/color").ExtraColorBy | undefined;
|
|
272
256
|
}): void;
|
|
273
|
-
updateModificationColorMap(uniqueModifications: string[]): void;
|
|
274
257
|
updateColorTagMap(uniqueTag: string[]): void;
|
|
275
258
|
setFeatureUnderMouse(feat?: Feature | undefined): void;
|
|
276
259
|
selectFeature(feature: Feature): void;
|
|
277
|
-
clearSelected(): void;
|
|
278
260
|
copyFeatureToClipboard(feature: Feature): void;
|
|
279
|
-
toggleSoftClipping(): void;
|
|
280
|
-
toggleMismatchAlpha(): void;
|
|
281
261
|
setConfig(conf: {
|
|
282
262
|
[x: string]: any;
|
|
283
263
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
284
264
|
setSubschema(slotName: string, data: unknown): any;
|
|
285
265
|
} & import("mobx-state-tree").IStateTreeNode<AnyConfigurationSchemaType>): void;
|
|
286
|
-
|
|
287
|
-
setFilterBy(filter: import("@jbrowse/plugin-alignments/src/LinearPileupDisplay/model").Filter): void;
|
|
288
|
-
} & {
|
|
289
|
-
reload(): void;
|
|
266
|
+
setFilterBy(filter: import("@jbrowse/plugin-alignments/src/LinearPileupDisplay/SharedLinearPileupDisplayMixin").Filter): void;
|
|
290
267
|
} & {
|
|
291
268
|
readonly rendererConfig: {
|
|
292
269
|
[x: string]: any;
|
|
@@ -296,9 +273,8 @@ declare function stateModelFactory(schema: AnyConfigurationSchemaType): import("
|
|
|
296
273
|
} & {
|
|
297
274
|
readonly maxHeight: any;
|
|
298
275
|
readonly featureHeightSetting: any;
|
|
299
|
-
readonly mismatchAlphaSetting: any;
|
|
300
276
|
readonly featureUnderMouse: Feature | undefined;
|
|
301
|
-
|
|
277
|
+
renderReady(): boolean;
|
|
302
278
|
} & {
|
|
303
279
|
readonly rendererTypeName: string;
|
|
304
280
|
contextMenuItems(): ({
|
|
@@ -314,66 +290,31 @@ declare function stateModelFactory(schema: AnyConfigurationSchemaType): import("
|
|
|
314
290
|
})[];
|
|
315
291
|
readonly DisplayBlurb: (props: import("@jbrowse/plugin-alignments/src/LinearPileupDisplay/components/LinearPileupDisplayBlurb").LinearPileupDisplayBlurbProps) => import("react").JSX.Element | null;
|
|
316
292
|
renderPropsPre(): any;
|
|
317
|
-
|
|
318
|
-
trackMenuItems(): (import("@jbrowse/core/ui").MenuDivider | import("@jbrowse/core/ui").MenuSubHeader | import("@jbrowse/core/ui").NormalMenuItem | import("@jbrowse/core/ui").CheckboxMenuItem | import("@jbrowse/core/ui").RadioMenuItem | import("@jbrowse/core/ui").SubMenuItem | {
|
|
293
|
+
colorSchemeSubMenuItems(): {
|
|
319
294
|
label: string;
|
|
320
|
-
icon: import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").SvgIconTypeMap<{}, "svg">> & {
|
|
321
|
-
muiName: string;
|
|
322
|
-
};
|
|
323
|
-
type: string;
|
|
324
|
-
checked: boolean;
|
|
325
295
|
onClick: () => void;
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
} | {
|
|
329
|
-
label: string;
|
|
330
|
-
icon: import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").SvgIconTypeMap<{}, "svg">> & {
|
|
331
|
-
muiName: string;
|
|
332
|
-
};
|
|
333
|
-
disabled: boolean;
|
|
334
|
-
subMenu: {
|
|
335
|
-
label: string;
|
|
336
|
-
onClick: () => void;
|
|
337
|
-
}[];
|
|
338
|
-
type?: undefined;
|
|
339
|
-
checked?: undefined;
|
|
340
|
-
onClick?: undefined;
|
|
341
|
-
} | {
|
|
342
|
-
label: string;
|
|
343
|
-
icon: import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").SvgIconTypeMap<{}, "svg">> & {
|
|
344
|
-
muiName: string;
|
|
345
|
-
};
|
|
346
|
-
subMenu: {
|
|
347
|
-
label: string;
|
|
348
|
-
onClick: () => void;
|
|
349
|
-
}[];
|
|
350
|
-
type?: undefined;
|
|
351
|
-
checked?: undefined;
|
|
352
|
-
onClick?: undefined;
|
|
353
|
-
disabled?: undefined;
|
|
354
|
-
} | {
|
|
296
|
+
}[];
|
|
297
|
+
trackMenuItems(): (import("@jbrowse/core/ui").MenuDivider | import("@jbrowse/core/ui").MenuSubHeader | import("@jbrowse/core/ui").NormalMenuItem | import("@jbrowse/core/ui").CheckboxMenuItem | import("@jbrowse/core/ui").RadioMenuItem | import("@jbrowse/core/ui").SubMenuItem | {
|
|
355
298
|
label: string;
|
|
356
299
|
icon: import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").SvgIconTypeMap<{}, "svg">> & {
|
|
357
300
|
muiName: string;
|
|
358
301
|
};
|
|
359
302
|
onClick: () => void;
|
|
360
|
-
type?: undefined;
|
|
361
|
-
checked?: undefined;
|
|
362
|
-
disabled?: undefined;
|
|
363
|
-
subMenu?: undefined;
|
|
364
|
-
} | {
|
|
365
|
-
label: string;
|
|
366
|
-
type: string;
|
|
367
|
-
checked: any;
|
|
368
|
-
onClick: () => void;
|
|
369
|
-
icon?: undefined;
|
|
370
|
-
disabled?: undefined;
|
|
371
|
-
subMenu?: undefined;
|
|
372
303
|
})[];
|
|
304
|
+
} & {
|
|
305
|
+
renderProps(): any;
|
|
373
306
|
} & {
|
|
374
307
|
afterAttach(): void;
|
|
375
308
|
} & {
|
|
376
309
|
contextMenuItems(): import("@jbrowse/core/ui").MenuItem[];
|
|
310
|
+
} & {
|
|
311
|
+
trackMenuItems(): (import("@jbrowse/core/ui").MenuDivider | import("@jbrowse/core/ui").MenuSubHeader | import("@jbrowse/core/ui").NormalMenuItem | import("@jbrowse/core/ui").CheckboxMenuItem | import("@jbrowse/core/ui").RadioMenuItem | import("@jbrowse/core/ui").SubMenuItem | {
|
|
312
|
+
label: string;
|
|
313
|
+
subMenu: {
|
|
314
|
+
label: string;
|
|
315
|
+
onClick: () => void;
|
|
316
|
+
}[];
|
|
317
|
+
})[];
|
|
377
318
|
} & {
|
|
378
319
|
afterCreate(): void;
|
|
379
320
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ConfigurationReference, } from '@jbrowse/core/configuration';
|
|
2
2
|
import { getSession, getContainingTrack, getContainingView, } from '@jbrowse/core/util';
|
|
3
|
-
import { MismatchParser,
|
|
3
|
+
import { MismatchParser, SharedLinearPileupDisplayMixin, } from '@jbrowse/plugin-alignments';
|
|
4
4
|
import { types } from 'mobx-state-tree';
|
|
5
5
|
import { when } from 'mobx';
|
|
6
6
|
const { parseCigar } = MismatchParser;
|
|
@@ -112,7 +112,7 @@ async function navToSynteny(feature, self) {
|
|
|
112
112
|
*/
|
|
113
113
|
function stateModelFactory(schema) {
|
|
114
114
|
return types
|
|
115
|
-
.compose('LGVSyntenyDisplay',
|
|
115
|
+
.compose('LGVSyntenyDisplay', SharedLinearPileupDisplayMixin(schema), types.model({
|
|
116
116
|
/**
|
|
117
117
|
* #property
|
|
118
118
|
*/
|
|
@@ -140,13 +140,31 @@ function stateModelFactory(schema) {
|
|
|
140
140
|
];
|
|
141
141
|
},
|
|
142
142
|
};
|
|
143
|
+
})
|
|
144
|
+
.views(self => {
|
|
145
|
+
const { trackMenuItems: superTrackMenuItems, colorSchemeSubMenuItems: superColorSchemeSubMenuItems, } = self;
|
|
146
|
+
return {
|
|
147
|
+
trackMenuItems() {
|
|
148
|
+
return [
|
|
149
|
+
...superTrackMenuItems(),
|
|
150
|
+
{
|
|
151
|
+
label: 'Color scheme',
|
|
152
|
+
subMenu: [...superColorSchemeSubMenuItems()],
|
|
153
|
+
},
|
|
154
|
+
];
|
|
155
|
+
},
|
|
156
|
+
};
|
|
143
157
|
})
|
|
144
158
|
.actions(self => ({
|
|
145
159
|
afterCreate() {
|
|
146
|
-
// use color by
|
|
147
|
-
self.
|
|
160
|
+
// use color by stand to help indicate inversions better on first load, otherwise use selected orientation
|
|
161
|
+
if (self.colorBy) {
|
|
162
|
+
self.setColorScheme({ ...self.colorBy });
|
|
163
|
+
}
|
|
164
|
+
else {
|
|
165
|
+
self.setColorScheme({ type: 'strand' });
|
|
166
|
+
}
|
|
148
167
|
},
|
|
149
168
|
}));
|
|
150
169
|
}
|
|
151
170
|
export default stateModelFactory;
|
|
152
|
-
//# sourceMappingURL=model.js.map
|
|
@@ -7,6 +7,7 @@ import { Menu } from '@jbrowse/core/ui';
|
|
|
7
7
|
// icons
|
|
8
8
|
import MoreVertIcon from '@mui/icons-material/MoreVert';
|
|
9
9
|
import { TrackSelector as TrackSelectorIcon } from '@jbrowse/core/ui/Icons';
|
|
10
|
+
import CascadingMenuButton from '@jbrowse/core/ui/CascadingMenuButton';
|
|
10
11
|
const useStyles = makeStyles()(() => ({
|
|
11
12
|
headerBar: {
|
|
12
13
|
gridArea: '1/1/auto/span 2',
|
|
@@ -31,7 +32,16 @@ const useStyles = makeStyles()(() => ({
|
|
|
31
32
|
},
|
|
32
33
|
}));
|
|
33
34
|
const TrackSelector = observer(({ model }) => {
|
|
34
|
-
return (React.createElement(
|
|
35
|
+
return (React.createElement(CascadingMenuButton, { menuItems: [
|
|
36
|
+
{
|
|
37
|
+
label: 'Synteny track selector',
|
|
38
|
+
onClick: () => model.activateTrackSelector(),
|
|
39
|
+
},
|
|
40
|
+
...model.views.map((view, idx) => ({
|
|
41
|
+
label: `View ${idx + 1} track selector`,
|
|
42
|
+
onClick: () => view.activateTrackSelector(),
|
|
43
|
+
})),
|
|
44
|
+
] },
|
|
35
45
|
React.createElement(TrackSelectorIcon, null)));
|
|
36
46
|
});
|
|
37
47
|
const Header = observer(function ({ model }) {
|
|
@@ -58,4 +68,3 @@ const Header = observer(function ({ model }) {
|
|
|
58
68
|
}, menuItems: model.headerMenuItems(), onClose: () => setMenuAnchorEl(undefined) })) : null));
|
|
59
69
|
});
|
|
60
70
|
export default Header;
|
|
61
|
-
//# sourceMappingURL=Header.js.map
|
|
@@ -91,4 +91,3 @@ export default observer(function (props) {
|
|
|
91
91
|
const middle = model.tracks.some(({ displays }) => displays.some((d) => getConf(d, 'middle')));
|
|
92
92
|
return middle ? (React.createElement(MiddleComparativeView, { ...props })) : (React.createElement(OverlayComparativeView, { ...props }));
|
|
93
93
|
});
|
|
94
|
-
//# sourceMappingURL=LinearComparativeView.js.map
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import React, { useRef, useEffect, useState } from 'react';
|
|
2
2
|
import { observer } from 'mobx-react';
|
|
3
|
-
import { Popover,
|
|
3
|
+
import { Popover, Typography, alpha } from '@mui/material';
|
|
4
4
|
import { makeStyles } from 'tss-react/mui';
|
|
5
5
|
import { stringify } from '@jbrowse/core/util';
|
|
6
6
|
import { Menu } from '@jbrowse/core/ui';
|
|
7
|
+
import VerticalGuide from './VerticalGuide';
|
|
7
8
|
const useStyles = makeStyles()(theme => {
|
|
8
9
|
const { tertiary, primary } = theme.palette;
|
|
9
10
|
const background = tertiary
|
|
@@ -34,28 +35,8 @@ const useStyles = makeStyles()(theme => {
|
|
|
34
35
|
paddingLeft: theme.spacing(1),
|
|
35
36
|
paddingRight: theme.spacing(1),
|
|
36
37
|
},
|
|
37
|
-
guide: {
|
|
38
|
-
pointerEvents: 'none',
|
|
39
|
-
height: '100%',
|
|
40
|
-
width: 1,
|
|
41
|
-
position: 'absolute',
|
|
42
|
-
zIndex: 10,
|
|
43
|
-
},
|
|
44
|
-
sm: {
|
|
45
|
-
fontSize: 10,
|
|
46
|
-
},
|
|
47
38
|
};
|
|
48
39
|
});
|
|
49
|
-
const VerticalGuide = observer(({ model, coordX }) => {
|
|
50
|
-
const { classes } = useStyles();
|
|
51
|
-
return (React.createElement(Tooltip, { open: true, placement: "top", title: model.views
|
|
52
|
-
.map(view => view.pxToBp(coordX))
|
|
53
|
-
.map(elt => (React.createElement(Typography, { className: classes.sm, key: JSON.stringify(elt) }, stringify(elt)))), arrow: true },
|
|
54
|
-
React.createElement("div", { className: classes.guide, style: {
|
|
55
|
-
left: coordX,
|
|
56
|
-
background: 'red',
|
|
57
|
-
} })));
|
|
58
|
-
});
|
|
59
40
|
function Rubberband({ model, ControlComponent = React.createElement("div", null), }) {
|
|
60
41
|
const [startX, setStartX] = useState();
|
|
61
42
|
const [currentX, setCurrentX] = useState();
|
|
@@ -158,9 +139,8 @@ function Rubberband({ model, ControlComponent = React.createElement("div", null)
|
|
|
158
139
|
if (startX === undefined) {
|
|
159
140
|
return (React.createElement(React.Fragment, null,
|
|
160
141
|
guideX !== undefined ? (React.createElement(VerticalGuide, { model: model, coordX: guideX })) : null,
|
|
161
|
-
React.createElement("div", {
|
|
142
|
+
React.createElement("div", { ref: controlsRef, className: classes.rubberbandControl, onMouseDown: mouseDown, onMouseOut: mouseOut, onMouseMove: mouseMove }, ControlComponent)));
|
|
162
143
|
}
|
|
163
|
-
/* Calculating Pixels for Mouse Dragging */
|
|
164
144
|
const right = anchorPosition ? anchorPosition.offsetX : currentX || 0;
|
|
165
145
|
const left = right < startX ? right : startX;
|
|
166
146
|
const width = Math.abs(right - startX);
|
|
@@ -170,31 +150,26 @@ function Rubberband({ model, ControlComponent = React.createElement("div", null)
|
|
|
170
150
|
const numOfBpSelected = views.map(view => Math.ceil(width * view.bpPerPx));
|
|
171
151
|
return (React.createElement(React.Fragment, null,
|
|
172
152
|
rubberbandRef.current ? (React.createElement(React.Fragment, null,
|
|
173
|
-
React.createElement(Popover, { className: classes.popover, classes: {
|
|
174
|
-
paper: classes.paper,
|
|
175
|
-
}, open: true, anchorEl: rubberbandRef.current, anchorOrigin: {
|
|
153
|
+
React.createElement(Popover, { className: classes.popover, classes: { paper: classes.paper }, open: true, anchorEl: rubberbandRef.current, anchorOrigin: {
|
|
176
154
|
vertical: 'top',
|
|
177
155
|
horizontal: 'left',
|
|
178
156
|
}, transformOrigin: {
|
|
179
157
|
vertical: 'bottom',
|
|
180
158
|
horizontal: 'right',
|
|
181
|
-
}, keepMounted: true, disableRestoreFocus: true }, leftBpOffset.map(l => (React.createElement(Typography, { key: JSON.stringify(l) }, stringify(l))))),
|
|
182
|
-
React.createElement(Popover, { className: classes.popover, classes: {
|
|
183
|
-
paper: classes.paper,
|
|
184
|
-
}, open: true, anchorEl: rubberbandRef.current, anchorOrigin: {
|
|
159
|
+
}, keepMounted: true, disableRestoreFocus: true }, leftBpOffset.map((l, idx) => (React.createElement(Typography, { key: [JSON.stringify(l), idx, 'left'].join('-') }, stringify(l, true))))),
|
|
160
|
+
React.createElement(Popover, { className: classes.popover, classes: { paper: classes.paper }, open: true, anchorEl: rubberbandRef.current, anchorOrigin: {
|
|
185
161
|
vertical: 'top',
|
|
186
162
|
horizontal: 'right',
|
|
187
163
|
}, transformOrigin: {
|
|
188
164
|
vertical: 'bottom',
|
|
189
165
|
horizontal: 'left',
|
|
190
|
-
}, keepMounted: true, disableRestoreFocus: true }, rightBpOffset.map(l => (React.createElement(Typography, { key: JSON.stringify(l) }, stringify(l))))))) : null,
|
|
166
|
+
}, keepMounted: true, disableRestoreFocus: true }, rightBpOffset.map((l, idx) => (React.createElement(Typography, { key: [JSON.stringify(l), idx, 'right'].join('-') }, stringify(l, true))))))) : null,
|
|
191
167
|
React.createElement("div", { ref: rubberbandRef, className: classes.rubberband, style: { left, width } },
|
|
192
168
|
React.createElement(Typography, { variant: "h6", className: classes.rubberbandText }, numOfBpSelected.map((n, i) => (React.createElement(Typography, { key: `${n}_${i}` }, `${n.toLocaleString('en-US')}bp`))))),
|
|
193
|
-
React.createElement("div", {
|
|
169
|
+
React.createElement("div", { className: classes.rubberbandControl, ref: controlsRef, onMouseDown: mouseDown, onMouseOut: mouseOut, onMouseMove: mouseMove }, ControlComponent),
|
|
194
170
|
anchorPosition ? (React.createElement(Menu, { anchorReference: "anchorPosition", anchorPosition: {
|
|
195
171
|
left: anchorPosition.clientX,
|
|
196
172
|
top: anchorPosition.clientY,
|
|
197
173
|
}, onMenuItemClick: handleMenuItemClick, open: open, onClose: handleClose, menuItems: model.rubberBandMenuItems() })) : null));
|
|
198
174
|
}
|
|
199
175
|
export default observer(Rubberband);
|
|
200
|
-
//# sourceMappingURL=Rubberband.js.map
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { LinearComparativeViewModel } from '../model';
|
|
3
|
+
type LCV = LinearComparativeViewModel;
|
|
4
|
+
declare const VerticalGuide: ({ model, coordX, }: {
|
|
5
|
+
model: LCV;
|
|
6
|
+
coordX: number;
|
|
7
|
+
}) => React.JSX.Element;
|
|
8
|
+
export default VerticalGuide;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Tooltip, Typography } from '@mui/material';
|
|
3
|
+
import { observer } from 'mobx-react';
|
|
4
|
+
import { stringify } from '@jbrowse/core/util';
|
|
5
|
+
import { makeStyles } from 'tss-react/mui';
|
|
6
|
+
const useStyles = makeStyles()({
|
|
7
|
+
guide: {
|
|
8
|
+
pointerEvents: 'none',
|
|
9
|
+
height: '100%',
|
|
10
|
+
width: 1,
|
|
11
|
+
position: 'absolute',
|
|
12
|
+
zIndex: 10,
|
|
13
|
+
},
|
|
14
|
+
sm: {
|
|
15
|
+
fontSize: 10,
|
|
16
|
+
},
|
|
17
|
+
});
|
|
18
|
+
const VerticalGuide = observer(function ({ model, coordX, }) {
|
|
19
|
+
const { classes } = useStyles();
|
|
20
|
+
return (React.createElement(Tooltip, { open: true, placement: "top", title: model.views
|
|
21
|
+
.map(view => view.pxToBp(coordX))
|
|
22
|
+
.map((elt, idx) => (React.createElement(Typography, { className: classes.sm, key: [JSON.stringify(elt), idx].join('-') }, stringify(elt, true)))), arrow: true },
|
|
23
|
+
React.createElement("div", { className: classes.guide, style: {
|
|
24
|
+
left: coordX,
|
|
25
|
+
background: 'red',
|
|
26
|
+
} })));
|
|
27
|
+
});
|
|
28
|
+
export default VerticalGuide;
|