jbrowse-plugin-msaview 5.3.0 → 5.5.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/dist/MsaViewPanel/afterCreateAutoruns.d.ts +1 -0
- package/dist/MsaViewPanel/afterCreateAutoruns.js +8 -0
- package/dist/MsaViewPanel/connectedDomains.d.ts +40 -0
- package/dist/MsaViewPanel/connectedDomains.js +74 -0
- package/dist/MsaViewPanel/connectedDomains.test.d.ts +1 -0
- package/dist/MsaViewPanel/connectedDomains.test.js +108 -0
- package/dist/MsaViewPanel/domainTrack.d.ts +85 -0
- package/dist/MsaViewPanel/domainTrack.js +64 -0
- package/dist/MsaViewPanel/domainTrack.test.d.ts +1 -0
- package/dist/MsaViewPanel/domainTrack.test.js +67 -0
- package/dist/MsaViewPanel/model.d.ts +44 -22
- package/dist/MsaViewPanel/model.js +78 -2
- package/dist/MsaViewPanel/model.test.js +85 -0
- package/dist/MsaViewPanel/msaCoordToGenomeCoord.d.ts +11 -3
- package/dist/MsaViewPanel/msaCoordToGenomeCoord.js +21 -14
- package/dist/chunks/{AboutDialog-447TIFAW.js → AboutDialog-HCCCEJ6V.js} +2 -2
- package/dist/chunks/{AboutDialog-447TIFAW.js.map → AboutDialog-HCCCEJ6V.js.map} +1 -1
- package/dist/chunks/AnnotationFileDialog-CPJ4X7XW.js +2 -0
- package/dist/chunks/{AnnotationFileDialog-S3N5EHHE.js.map → AnnotationFileDialog-CPJ4X7XW.js.map} +2 -2
- package/dist/chunks/{ExportSVGDialog-7ZHKKQ7W.js → ExportSVGDialog-YUFLYBYW.js} +2 -2
- package/dist/chunks/{ExportSVGDialog-7ZHKKQ7W.js.map → ExportSVGDialog-YUFLYBYW.js.map} +1 -1
- package/dist/chunks/{FeatureDialog-EEOGSLOG.js → FeatureDialog-NBDB5SWU.js} +1 -1
- package/dist/chunks/{FeatureDialog-EEOGSLOG.js.map → FeatureDialog-NBDB5SWU.js.map} +1 -1
- package/dist/chunks/{HelpDialog-TCWNBZOV.js → HelpDialog-UCUYPCOI.js} +2 -2
- package/dist/chunks/{HelpDialog-TCWNBZOV.js.map → HelpDialog-UCUYPCOI.js.map} +1 -1
- package/dist/chunks/{LaunchMsaViewDialog-R6CNRASN.js → LaunchMsaViewDialog-BG4MX2BW.js} +2 -2
- package/dist/chunks/{LaunchMsaViewDialog-R6CNRASN.js.map → LaunchMsaViewDialog-BG4MX2BW.js.map} +2 -2
- package/dist/chunks/MetadataDialog-DSA3545E.js +2 -0
- package/dist/chunks/{MetadataDialog-MNSI6NEW.js.map → MetadataDialog-DSA3545E.js.map} +2 -2
- package/dist/chunks/MsaViewPanel-XSXFJWWY.js +2 -0
- package/dist/chunks/{MsaViewPanel-R2WAER5O.js.map → MsaViewPanel-XSXFJWWY.js.map} +1 -1
- package/dist/chunks/{TrackInfoDialog-W2F77IPG.js → TrackInfoDialog-YXCIGFYM.js} +2 -2
- package/dist/chunks/{TrackInfoDialog-W2F77IPG.js.map → TrackInfoDialog-YXCIGFYM.js.map} +1 -1
- package/dist/chunks/TreeNodeInfoDialog-QCWDJTM4.js +2 -0
- package/dist/chunks/{TreeNodeInfoDialog-T5XMPG3R.js.map → TreeNodeInfoDialog-QCWDJTM4.js.map} +2 -2
- package/dist/chunks/{chunk-JF6CW6MO.js → chunk-35FWLG3N.js} +1 -1
- package/dist/chunks/{chunk-JF6CW6MO.js.map → chunk-35FWLG3N.js.map} +1 -1
- package/dist/chunks/{chunk-BAM67QHH.js → chunk-4TEPHD3L.js} +3 -3
- package/dist/chunks/{chunk-BAM67QHH.js.map → chunk-4TEPHD3L.js.map} +2 -2
- package/dist/chunks/{chunk-NWHZOZMG.js → chunk-5OSSOQH4.js} +1 -1
- package/dist/chunks/{chunk-NWHZOZMG.js.map → chunk-5OSSOQH4.js.map} +1 -1
- package/dist/chunks/{chunk-FEUZKN5V.js → chunk-666BV764.js} +2 -2
- package/dist/chunks/{chunk-FEUZKN5V.js.map → chunk-666BV764.js.map} +1 -1
- package/dist/chunks/{chunk-YUKJI2AH.js → chunk-AQ2THRTR.js} +2 -2
- package/dist/chunks/{chunk-YUKJI2AH.js.map → chunk-AQ2THRTR.js.map} +1 -1
- package/dist/chunks/{chunk-L6CBIH6H.js → chunk-ASUKJX5J.js} +2 -2
- package/dist/chunks/{chunk-L6CBIH6H.js.map → chunk-ASUKJX5J.js.map} +1 -1
- package/dist/chunks/chunk-F726IWCW.js +2 -0
- package/dist/chunks/chunk-F726IWCW.js.map +7 -0
- package/dist/chunks/{chunk-CSCUNTGJ.js → chunk-FFHB7WP7.js} +4 -4
- package/dist/chunks/chunk-FFHB7WP7.js.map +7 -0
- package/dist/chunks/{chunk-ERCMNTEQ.js → chunk-GAY2PLS6.js} +1 -1
- package/dist/chunks/{chunk-ERCMNTEQ.js.map → chunk-GAY2PLS6.js.map} +1 -1
- package/dist/chunks/{chunk-TSHN6J7U.js → chunk-JDQUBCHM.js} +1 -1
- package/dist/chunks/{chunk-TSHN6J7U.js.map → chunk-JDQUBCHM.js.map} +1 -1
- package/dist/chunks/{chunk-IBBQUV2I.js → chunk-KSCGTF4R.js} +1 -1
- package/dist/chunks/{chunk-IBBQUV2I.js.map → chunk-KSCGTF4R.js.map} +1 -1
- package/dist/chunks/{chunk-6YFCSBEE.js → chunk-NLAW2OYS.js} +2 -2
- package/dist/chunks/{chunk-6YFCSBEE.js.map → chunk-NLAW2OYS.js.map} +1 -1
- package/dist/chunks/chunk-QQKPT6EL.js +2 -0
- package/dist/chunks/{chunk-XVNCZQMR.js.map → chunk-QQKPT6EL.js.map} +1 -1
- package/dist/chunks/{chunk-WAPIOD25.js → chunk-WMDOEOAH.js} +5 -5
- package/dist/chunks/{chunk-WAPIOD25.js.map → chunk-WMDOEOAH.js.map} +1 -1
- package/dist/chunks/chunk-XTQQNBQ5.js +2 -0
- package/dist/chunks/{chunk-6EOYBBT4.js.map → chunk-XTQQNBQ5.js.map} +1 -1
- package/dist/chunks/chunk-XXCNVFGP.js +11 -0
- package/dist/chunks/chunk-XXCNVFGP.js.map +7 -0
- package/dist/chunks/{chunk-OVAXNTPN.js → chunk-ZQSWX57C.js} +1 -1
- package/dist/chunks/{chunk-OVAXNTPN.js.map → chunk-ZQSWX57C.js.map} +1 -1
- package/dist/chunks/dist-GZKCGB2N.js +2 -0
- package/dist/chunks/model-7RBDANXP.js +12 -0
- package/dist/chunks/model-7RBDANXP.js.map +7 -0
- package/dist/chunks/{renderToSvg-53FEV6IJ.js → renderToSvg-5DMIQ72S.js} +2 -2
- package/dist/jbrowse-plugin-msaview.esm.js +2 -2
- package/dist/jbrowse-plugin-msaview.esm.js.map +3 -3
- package/dist/utils/domainCache.js +16 -2
- package/dist/utils/ncbiDomains.js +15 -25
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +17 -17
- package/src/LaunchMsaViewExtensionPoint/index.ts +5 -0
- package/src/MsaViewPanel/afterCreateAutoruns.ts +11 -0
- package/src/MsaViewPanel/connectedDomains.test.ts +153 -0
- package/src/MsaViewPanel/connectedDomains.ts +107 -0
- package/src/MsaViewPanel/domainTrack.test.ts +73 -0
- package/src/MsaViewPanel/domainTrack.ts +79 -0
- package/src/MsaViewPanel/model.test.ts +92 -0
- package/src/MsaViewPanel/model.ts +90 -1
- package/src/MsaViewPanel/msaCoordToGenomeCoord.ts +37 -25
- package/src/utils/domainCache.ts +19 -2
- package/src/utils/ncbiDomains.ts +15 -26
- package/src/version.ts +1 -1
- package/dist/chunks/AnnotationFileDialog-S3N5EHHE.js +0 -2
- package/dist/chunks/MetadataDialog-MNSI6NEW.js +0 -2
- package/dist/chunks/MsaViewPanel-R2WAER5O.js +0 -2
- package/dist/chunks/TreeNodeInfoDialog-T5XMPG3R.js +0 -2
- package/dist/chunks/chunk-6EOYBBT4.js +0 -2
- package/dist/chunks/chunk-A63PUWQZ.js +0 -6
- package/dist/chunks/chunk-A63PUWQZ.js.map +0 -7
- package/dist/chunks/chunk-CSCUNTGJ.js.map +0 -7
- package/dist/chunks/chunk-DEFUNIWW.js +0 -8
- package/dist/chunks/chunk-DEFUNIWW.js.map +0 -7
- package/dist/chunks/chunk-K55ZVN73.js +0 -5
- package/dist/chunks/chunk-K55ZVN73.js.map +0 -7
- package/dist/chunks/chunk-XVNCZQMR.js +0 -2
- package/dist/chunks/dist-N4ZJK63Q.js +0 -2
- package/dist/chunks/model-TCPB6WNJ.js +0 -12
- package/dist/chunks/model-TCPB6WNJ.js.map +0 -7
- /package/dist/chunks/{dist-N4ZJK63Q.js.map → dist-GZKCGB2N.js.map} +0 -0
- /package/dist/chunks/{renderToSvg-53FEV6IJ.js.map → renderToSvg-5DMIQ72S.js.map} +0 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export type { MSAFormat } from 'msa-parsers';
|
|
2
2
|
import type { BlastDatabase, MsaAlgorithm, PhmmerDatabase } from '../LaunchMsaView/components/BlastQuery/consts';
|
|
3
3
|
import type { UnirefIdentity } from '../utils/unirefHomologs';
|
|
4
|
+
import type { ConnectedDomain } from './connectedDomains';
|
|
4
5
|
import type { MsaDataPayload } from './msaDataStore';
|
|
5
6
|
import type { MafRegion, MsaViewInitState } from './types';
|
|
6
7
|
import type { TranscriptRef } from './util';
|
|
@@ -128,7 +129,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
128
129
|
colorSchemeName: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
129
130
|
customColorScheme: import("@jbrowse/mobx-state-tree").IType<Record<string, string> | undefined, Record<string, string> | undefined, Record<string, string> | undefined>;
|
|
130
131
|
showColumnStats: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
131
|
-
msaFormat: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<import("
|
|
132
|
+
msaFormat: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<import("msa-parsers").MSAFormat>>;
|
|
132
133
|
}, "id" | "type" | "allowedGappyness" | "clades" | "colWidth" | "collapsed" | "columnTracks" | "currentAlignment" | "data" | "drawMsaLetters" | "encodings" | "features" | "gffFilehandle" | "height" | "hideGaps" | "highlightColumns" | "highlights" | "msaFilehandle" | "region" | "relativeTo" | "residueMappings" | "rotated" | "rowHeight" | "rowPanels" | "scrollX" | "scrollY" | "scrollZoom" | "scrollZoomAxis" | "selection" | "showDomainLegend" | "showDomains" | "showOnly" | "subFeatureRows" | "trackHeights" | "treeFilehandle" | "treeMetadataFilehandle" | "treeRoot" | "turnedOffFeatures" | "turnedOffTracks"> & {
|
|
133
134
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
134
135
|
showDomains: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
@@ -497,7 +498,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
497
498
|
clades: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<import("react-msaview").Clade, import("react-msaview").Clade, import("react-msaview").Clade>>, [undefined]>;
|
|
498
499
|
encodings: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<import("react-msaview").Encoding, import("react-msaview").Encoding, import("react-msaview").Encoding>>, [undefined]>;
|
|
499
500
|
rowPanels: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<import("react-msaview").RowPanelSpec, import("react-msaview").RowPanelSpec, import("react-msaview").RowPanelSpec>>, [undefined]>;
|
|
500
|
-
}, "init" | "querySeqName" | "launchCompleted" | "connectedViewId" | "connectedFeature" | "connectedTranscript" | "blastParams" | "orthologParams" | "querySeqOffset" | "uniprotId" | "zoomToBaseLevel" | "dataStoreId" | "mafRegion"> & {
|
|
501
|
+
}, "init" | "querySeqName" | "launchCompleted" | "embeddedMode" | "connectedViewId" | "connectedFeature" | "connectedTranscript" | "blastParams" | "orthologParams" | "querySeqOffset" | "uniprotId" | "zoomToBaseLevel" | "dataStoreId" | "mafRegion" | "domainsOnGenome"> & {
|
|
501
502
|
connectedViewId: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
502
503
|
connectedFeature: import("@jbrowse/mobx-state-tree").IType<any, any, any>;
|
|
503
504
|
connectedTranscript: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
@@ -511,6 +512,8 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
511
512
|
dataStoreId: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
512
513
|
launchCompleted: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
513
514
|
mafRegion: import("@jbrowse/mobx-state-tree").IType<MafRegion | undefined, MafRegion | undefined, MafRegion | undefined>;
|
|
515
|
+
embeddedMode: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
516
|
+
domainsOnGenome: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
514
517
|
}, {
|
|
515
518
|
width: number;
|
|
516
519
|
bodyMounted: boolean;
|
|
@@ -549,7 +552,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
549
552
|
setCustomColorScheme(map?: Record<string, string>): void;
|
|
550
553
|
setBgColor(arg: boolean): void;
|
|
551
554
|
setShowColumnStats(arg: boolean): void;
|
|
552
|
-
setMSAFormat(arg?: import("
|
|
555
|
+
setMSAFormat(arg?: import("msa-parsers").MSAFormat): void;
|
|
553
556
|
} & {
|
|
554
557
|
headerHeight: number;
|
|
555
558
|
hideHeader: boolean;
|
|
@@ -581,7 +584,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
581
584
|
dismissedWarnings: string[];
|
|
582
585
|
resetCount: number;
|
|
583
586
|
hostCarriesData: boolean;
|
|
584
|
-
annotations: import("
|
|
587
|
+
annotations: import("msa-parsers").Annotation[];
|
|
585
588
|
} & {
|
|
586
589
|
drawRelativeTo(id: string | undefined): void;
|
|
587
590
|
setHideGaps(arg: boolean): void;
|
|
@@ -632,7 +635,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
632
635
|
setGFF(result?: string): void;
|
|
633
636
|
} & {
|
|
634
637
|
readonly hideGapsEffective: boolean;
|
|
635
|
-
readonly allAnnotations: import("
|
|
638
|
+
readonly allAnnotations: import("msa-parsers").Annotation[];
|
|
636
639
|
readonly actuallyShowDomains: boolean;
|
|
637
640
|
readonly hostRestoresData: boolean;
|
|
638
641
|
readonly viewInitialized: boolean;
|
|
@@ -660,7 +663,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
660
663
|
readonly rowData: Record<string, Record<string, string> | undefined>;
|
|
661
664
|
rowDataOf(name: string): Record<string, string> | undefined;
|
|
662
665
|
readonly rowFields: string[];
|
|
663
|
-
readonly MSA: import("
|
|
666
|
+
readonly MSA: import("msa-parsers").MSAParserType | null;
|
|
664
667
|
readonly numColumns: number;
|
|
665
668
|
readonly inputTree: import("react-msaview").NodeWithIds;
|
|
666
669
|
readonly tree: import("react-msaview").NodeWithIds;
|
|
@@ -791,9 +794,9 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
791
794
|
readonly topBandHeight: number;
|
|
792
795
|
readonly msaAreaHeight: number;
|
|
793
796
|
readonly totalTrackAreaHeight: number;
|
|
794
|
-
readonly annotationTypes: Map<string, import("
|
|
795
|
-
readonly filteredAnnotations: import("
|
|
796
|
-
readonly annotationsByRow: Record<string, import("
|
|
797
|
+
readonly annotationTypes: Map<string, import("msa-parsers").Annotation>;
|
|
798
|
+
readonly filteredAnnotations: import("msa-parsers").Annotation[];
|
|
799
|
+
readonly annotationsByRow: Record<string, import("msa-parsers").Annotation[]>;
|
|
797
800
|
} & {
|
|
798
801
|
readonly showVerticalScrollbar: boolean;
|
|
799
802
|
} & {
|
|
@@ -826,7 +829,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
826
829
|
zoomToPos(scaleFactor: number, offsetX: number, offsetY: number, axis?: "both" | "horizontal" | "vertical"): void;
|
|
827
830
|
doScrollY(deltaY: number): void;
|
|
828
831
|
setScrollY(n: number): void;
|
|
829
|
-
setAnnotations(annotations: import("
|
|
832
|
+
setAnnotations(annotations: import("msa-parsers").Annotation[]): void;
|
|
830
833
|
applyGFFText(gffText: string): void;
|
|
831
834
|
doScrollX(deltaX: number): void;
|
|
832
835
|
setScrollX(n: number): void;
|
|
@@ -845,24 +848,24 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
845
848
|
readonly hoveredCell: import("react-msaview").Cell | undefined;
|
|
846
849
|
readonly clickedCell: import("react-msaview").Cell | undefined;
|
|
847
850
|
readonly viewport: import("react-msaview").Viewport | undefined;
|
|
848
|
-
readonly segmentDomainTypes: import("
|
|
849
|
-
readonly categoricalDomainTypes: import("
|
|
851
|
+
readonly segmentDomainTypes: import("msa-parsers").Annotation[];
|
|
852
|
+
readonly categoricalDomainTypes: import("msa-parsers").Annotation[];
|
|
850
853
|
readonly fillPalette: {
|
|
851
854
|
[x: string]: string;
|
|
852
855
|
};
|
|
853
856
|
readonly featureFillEncoding: import("react-msaview").ResolvedEncoding | undefined;
|
|
854
|
-
readonly featureColors: Map<import("
|
|
857
|
+
readonly featureColors: Map<import("msa-parsers").Annotation, {
|
|
855
858
|
fill: string;
|
|
856
859
|
stroke: string;
|
|
857
860
|
}>;
|
|
858
|
-
readonly featureLabels: Map<import("
|
|
861
|
+
readonly featureLabels: Map<import("msa-parsers").Annotation, string> | undefined;
|
|
859
862
|
readonly segmentLabels: Map<string, string>;
|
|
860
|
-
readonly visibleDomainTypes: import("
|
|
863
|
+
readonly visibleDomainTypes: import("msa-parsers").Annotation[];
|
|
861
864
|
readonly legends: import("react-msaview").Legend[];
|
|
862
865
|
readonly domainUnderline: boolean;
|
|
863
866
|
readonly domainBands: Map<string, import("react-msaview").DomainBand[]>;
|
|
864
867
|
readonly domainBandsByStart: Map<string, import("react-msaview").DomainBand[]>;
|
|
865
|
-
readonly mouseOverDomains: import("
|
|
868
|
+
readonly mouseOverDomains: import("msa-parsers").Annotation[];
|
|
866
869
|
readonly referenceRowIndex: number | undefined;
|
|
867
870
|
readonly hoveredRowIndices: number[];
|
|
868
871
|
readonly highlightedColumnRuns: {
|
|
@@ -903,13 +906,13 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
903
906
|
x: "column" | "position";
|
|
904
907
|
kind: "features";
|
|
905
908
|
field?: string | undefined;
|
|
906
|
-
colors: Map<import("
|
|
909
|
+
colors: Map<import("msa-parsers").Annotation, {
|
|
907
910
|
fill: string;
|
|
908
911
|
stroke: string;
|
|
909
912
|
}>;
|
|
910
913
|
legend: import("react-msaview").LegendEntry[];
|
|
911
914
|
legendTitle?: string | undefined;
|
|
912
|
-
labels?: Map<import("
|
|
915
|
+
labels?: Map<import("msa-parsers").Annotation, string> | undefined;
|
|
913
916
|
})[];
|
|
914
917
|
readonly resolvedRowPanels: import("react-msaview").ResolvedRowPanel[];
|
|
915
918
|
readonly featureAlignShifts: Map<string, Map<string, number>>;
|
|
@@ -978,6 +981,13 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
978
981
|
* to draw the same highlights in its own display
|
|
979
982
|
*/
|
|
980
983
|
readonly connectedHighlights: IRegion[];
|
|
984
|
+
/**
|
|
985
|
+
* #getter
|
|
986
|
+
* cross-plugin contract: jbrowse-plugin-protein3d reads this to paint the
|
|
987
|
+
* domains the alignment shows on the query row onto the structure, in
|
|
988
|
+
* the alignment's colors
|
|
989
|
+
*/
|
|
990
|
+
readonly connectedDomains: ConnectedDomain[];
|
|
981
991
|
} & {
|
|
982
992
|
/**
|
|
983
993
|
* #getter
|
|
@@ -1088,6 +1098,16 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
1088
1098
|
* #action
|
|
1089
1099
|
*/
|
|
1090
1100
|
setDomainsRequested(arg: boolean): void;
|
|
1101
|
+
/**
|
|
1102
|
+
* #action
|
|
1103
|
+
*/
|
|
1104
|
+
setDomainsOnGenome(arg: boolean): void;
|
|
1105
|
+
/**
|
|
1106
|
+
* #action
|
|
1107
|
+
* Add the query row's domains to the connected genome view as a session
|
|
1108
|
+
* track, replacing the one an earlier call added.
|
|
1109
|
+
*/
|
|
1110
|
+
showDomainsOnGenome(): void;
|
|
1091
1111
|
/**
|
|
1092
1112
|
* #action
|
|
1093
1113
|
*/
|
|
@@ -1140,7 +1160,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
1140
1160
|
colorSchemeName: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
1141
1161
|
customColorScheme: import("@jbrowse/mobx-state-tree").IType<Record<string, string> | undefined, Record<string, string> | undefined, Record<string, string> | undefined>;
|
|
1142
1162
|
showColumnStats: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1143
|
-
msaFormat: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<import("
|
|
1163
|
+
msaFormat: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<import("msa-parsers").MSAFormat>>;
|
|
1144
1164
|
}, "id" | "type" | "allowedGappyness" | "clades" | "colWidth" | "collapsed" | "columnTracks" | "currentAlignment" | "data" | "drawMsaLetters" | "encodings" | "features" | "gffFilehandle" | "height" | "hideGaps" | "highlightColumns" | "highlights" | "msaFilehandle" | "region" | "relativeTo" | "residueMappings" | "rotated" | "rowHeight" | "rowPanels" | "scrollX" | "scrollY" | "scrollZoom" | "scrollZoomAxis" | "selection" | "showDomainLegend" | "showDomains" | "showOnly" | "subFeatureRows" | "trackHeights" | "treeFilehandle" | "treeMetadataFilehandle" | "treeRoot" | "turnedOffFeatures" | "turnedOffTracks"> & {
|
|
1145
1165
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
1146
1166
|
showDomains: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
@@ -1509,7 +1529,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
1509
1529
|
clades: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<import("react-msaview").Clade, import("react-msaview").Clade, import("react-msaview").Clade>>, [undefined]>;
|
|
1510
1530
|
encodings: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<import("react-msaview").Encoding, import("react-msaview").Encoding, import("react-msaview").Encoding>>, [undefined]>;
|
|
1511
1531
|
rowPanels: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<import("react-msaview").RowPanelSpec, import("react-msaview").RowPanelSpec, import("react-msaview").RowPanelSpec>>, [undefined]>;
|
|
1512
|
-
}, "init" | "querySeqName" | "launchCompleted" | "connectedViewId" | "connectedFeature" | "connectedTranscript" | "blastParams" | "orthologParams" | "querySeqOffset" | "uniprotId" | "zoomToBaseLevel" | "dataStoreId" | "mafRegion"> & {
|
|
1532
|
+
}, "init" | "querySeqName" | "launchCompleted" | "embeddedMode" | "connectedViewId" | "connectedFeature" | "connectedTranscript" | "blastParams" | "orthologParams" | "querySeqOffset" | "uniprotId" | "zoomToBaseLevel" | "dataStoreId" | "mafRegion" | "domainsOnGenome"> & {
|
|
1513
1533
|
connectedViewId: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
1514
1534
|
connectedFeature: import("@jbrowse/mobx-state-tree").IType<any, any, any>;
|
|
1515
1535
|
connectedTranscript: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
@@ -1523,12 +1543,14 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
1523
1543
|
dataStoreId: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
1524
1544
|
launchCompleted: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
1525
1545
|
mafRegion: import("@jbrowse/mobx-state-tree").IType<MafRegion | undefined, MafRegion | undefined, MafRegion | undefined>;
|
|
1546
|
+
embeddedMode: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
1547
|
+
domainsOnGenome: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1526
1548
|
}>, "id" | "type" | "drawLabels" | "drawNodeBubbles" | "drawNodeLabels" | "drawTree" | "labelsAlignRight" | "overviewHeight" | "showBranchLen" | "showTreeOverview" | "treeAreaWidth" | "treeOrder" | "treeWidth" | "bgColor" | "colorSchemeName" | "customColorScheme" | "msaFormat" | "showColumnStats" | "allowedGappyness" | "clades" | "colWidth" | "collapsed" | "columnTracks" | "currentAlignment" | "data" | "drawMsaLetters" | "encodings" | "features" | "gffFilehandle" | "height" | "hideGaps" | "highlightColumns" | "highlights" | "msaFilehandle" | "region" | "relativeTo" | "residueMappings" | "rotated" | "rowHeight" | "rowPanels" | "scrollX" | "scrollY" | "scrollZoom" | "scrollZoomAxis" | "selection" | "showDomainLegend" | "showDomains" | "showOnly" | "subFeatureRows" | "trackHeights" | "treeFilehandle" | "treeMetadataFilehandle" | "treeRoot" | "turnedOffFeatures" | "turnedOffTracks"> & ({
|
|
1527
1549
|
bgColor: boolean;
|
|
1528
1550
|
colorSchemeName: string;
|
|
1529
1551
|
customColorScheme: Record<string, string> | undefined;
|
|
1530
1552
|
showColumnStats: boolean;
|
|
1531
|
-
msaFormat: import("
|
|
1553
|
+
msaFormat: import("msa-parsers").MSAFormat | undefined;
|
|
1532
1554
|
drawLabels: boolean;
|
|
1533
1555
|
labelsAlignRight: boolean;
|
|
1534
1556
|
treeAreaWidth: number | undefined;
|
|
@@ -1665,7 +1687,7 @@ export default function stateModelFactory(): import("@jbrowse/mobx-state-tree").
|
|
|
1665
1687
|
colorSchemeName: string;
|
|
1666
1688
|
customColorScheme: Record<string, string> | undefined;
|
|
1667
1689
|
showColumnStats: boolean;
|
|
1668
|
-
msaFormat: import("
|
|
1690
|
+
msaFormat: import("msa-parsers").MSAFormat | undefined;
|
|
1669
1691
|
drawLabels: boolean;
|
|
1670
1692
|
labelsAlignRight: boolean;
|
|
1671
1693
|
treeAreaWidth: number | undefined;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { BaseViewModel } from '@jbrowse/core/pluggableElementTypes';
|
|
2
|
-
import { getSession } from '@jbrowse/core/util';
|
|
2
|
+
import { getSession, isSessionWithAddSessionTrack, isSessionWithDeleteTrackConf, isSessionWithSessionTracks, } from '@jbrowse/core/util';
|
|
3
3
|
import { addDisposer, getSnapshot, types } from '@jbrowse/mobx-state-tree';
|
|
4
4
|
import { autorun } from 'mobx';
|
|
5
5
|
import { MSAModelF } from 'react-msaview';
|
|
6
|
-
import { autoLoadProteinDomains, launchBlastIfNeeded, launchOrthologsIfNeeded, loadStoredData, observeProteinHighlights, processInit, runCleanup, storeDataToIndexedDB, syncGenomeHoverToMsaColumn, } from './afterCreateAutoruns';
|
|
6
|
+
import { autoLoadProteinDomains, launchBlastIfNeeded, launchOrthologsIfNeeded, loadStoredData, observeProteinHighlights, processInit, runCleanup, storeDataToIndexedDB, showDomainsOnGenomeIfAsked, syncGenomeHoverToMsaColumn, } from './afterCreateAutoruns';
|
|
7
|
+
import { connectedDomains } from './connectedDomains';
|
|
8
|
+
import { domainTrackConf } from './domainTrack';
|
|
7
9
|
import { msaCoordToGenomeCoord, msaCoordToGenomeRegions, } from './msaCoordToGenomeCoord';
|
|
8
10
|
import { resolveConnectedTranscriptIfNeeded } from './resolveConnectedTranscript';
|
|
9
11
|
import { transcriptMap } from './transcriptMap';
|
|
@@ -99,6 +101,20 @@ export default function stateModelFactory() {
|
|
|
99
101
|
* #property
|
|
100
102
|
*/
|
|
101
103
|
mafRegion: types.frozen(),
|
|
104
|
+
/**
|
|
105
|
+
* #property
|
|
106
|
+
* react-msaview draws the toolbar's menus and Settings as icons, since
|
|
107
|
+
* a JBrowse view shares its row with other panels. A session spec sets
|
|
108
|
+
* it false for the labeled toolbar.
|
|
109
|
+
*/
|
|
110
|
+
embeddedMode: true,
|
|
111
|
+
/**
|
|
112
|
+
* #property
|
|
113
|
+
* a launch asking for the domains on the genome: once the connected
|
|
114
|
+
* view and the query row's domains are both there, the view adds the
|
|
115
|
+
* domain track and clears this
|
|
116
|
+
*/
|
|
117
|
+
domainsOnGenome: types.stripDefault(types.boolean, false),
|
|
102
118
|
}))
|
|
103
119
|
.volatile(() => ({
|
|
104
120
|
/**
|
|
@@ -198,6 +214,15 @@ export default function stateModelFactory() {
|
|
|
198
214
|
...this.connectedClickHighlights,
|
|
199
215
|
];
|
|
200
216
|
},
|
|
217
|
+
/**
|
|
218
|
+
* #getter
|
|
219
|
+
* cross-plugin contract: jbrowse-plugin-protein3d reads this to paint the
|
|
220
|
+
* domains the alignment shows on the query row onto the structure, in
|
|
221
|
+
* the alignment's colors
|
|
222
|
+
*/
|
|
223
|
+
get connectedDomains() {
|
|
224
|
+
return connectedDomains(self);
|
|
225
|
+
},
|
|
201
226
|
}))
|
|
202
227
|
.views(self => ({
|
|
203
228
|
/**
|
|
@@ -389,6 +414,46 @@ export default function stateModelFactory() {
|
|
|
389
414
|
setDomainsRequested(arg) {
|
|
390
415
|
self.domainsRequested = arg;
|
|
391
416
|
},
|
|
417
|
+
/**
|
|
418
|
+
* #action
|
|
419
|
+
*/
|
|
420
|
+
setDomainsOnGenome(arg) {
|
|
421
|
+
self.domainsOnGenome = arg;
|
|
422
|
+
},
|
|
423
|
+
/**
|
|
424
|
+
* #action
|
|
425
|
+
* Add the query row's domains to the connected genome view as a session
|
|
426
|
+
* track, replacing the one an earlier call added.
|
|
427
|
+
*/
|
|
428
|
+
showDomainsOnGenome() {
|
|
429
|
+
const session = getSession(self);
|
|
430
|
+
const { connectedView, connectedDomains, connectedFeature } = self;
|
|
431
|
+
const assemblyName = connectedView?.assemblyNames[0];
|
|
432
|
+
if (!connectedView ||
|
|
433
|
+
!assemblyName ||
|
|
434
|
+
connectedDomains.length === 0 ||
|
|
435
|
+
!isSessionWithAddSessionTrack(session)) {
|
|
436
|
+
return;
|
|
437
|
+
}
|
|
438
|
+
const feature = connectedFeature;
|
|
439
|
+
const label = [feature?.gene_name, feature?.gene, feature?.name].find((v) => typeof v === 'string' && v !== '');
|
|
440
|
+
const conf = domainTrackConf({
|
|
441
|
+
viewId: self.id,
|
|
442
|
+
assemblyName,
|
|
443
|
+
name: `${label ?? self.querySeqName} domains (from the alignment)`,
|
|
444
|
+
strand: self.mafRegion ? undefined : self.transcriptToMsaMap?.strand,
|
|
445
|
+
domains: connectedDomains,
|
|
446
|
+
});
|
|
447
|
+
const existing = isSessionWithSessionTracks(session)
|
|
448
|
+
? session.sessionTracks.find(t => t.trackId === conf.trackId)
|
|
449
|
+
: undefined;
|
|
450
|
+
if (existing && isSessionWithDeleteTrackConf(session)) {
|
|
451
|
+
session.deleteTrackConf(existing);
|
|
452
|
+
}
|
|
453
|
+
if (session.addSessionTrackConf(conf)) {
|
|
454
|
+
void connectedView.launchTrack(conf.trackId);
|
|
455
|
+
}
|
|
456
|
+
},
|
|
392
457
|
/**
|
|
393
458
|
* #action
|
|
394
459
|
*/
|
|
@@ -470,6 +535,16 @@ export default function stateModelFactory() {
|
|
|
470
535
|
self.setZoomToBaseLevel(!self.zoomToBaseLevel);
|
|
471
536
|
},
|
|
472
537
|
},
|
|
538
|
+
...(self.connectedView && self.connectedDomains.length > 0
|
|
539
|
+
? [
|
|
540
|
+
{
|
|
541
|
+
label: 'Show domains on the genome',
|
|
542
|
+
onClick: () => {
|
|
543
|
+
self.showDomainsOnGenome();
|
|
544
|
+
},
|
|
545
|
+
},
|
|
546
|
+
]
|
|
547
|
+
: []),
|
|
473
548
|
];
|
|
474
549
|
},
|
|
475
550
|
};
|
|
@@ -491,6 +566,7 @@ export default function stateModelFactory() {
|
|
|
491
566
|
launchOrthologsIfNeeded,
|
|
492
567
|
processInit,
|
|
493
568
|
autoLoadProteinDomains,
|
|
569
|
+
showDomainsOnGenomeIfAsked,
|
|
494
570
|
]) {
|
|
495
571
|
addDisposer(self, autorun(() => {
|
|
496
572
|
fn(self);
|
|
@@ -163,3 +163,88 @@ describe('returning to the import form', () => {
|
|
|
163
163
|
expect(model.dataStoreId).toBeUndefined();
|
|
164
164
|
});
|
|
165
165
|
});
|
|
166
|
+
test('the view asks react-msaview for its icon toolbar', () => {
|
|
167
|
+
expect(view().embeddedMode).toBe(true);
|
|
168
|
+
});
|
|
169
|
+
// two CDS on the reverse strand, so residue 3's codon straddles the intron
|
|
170
|
+
const reverseTranscript = {
|
|
171
|
+
refName: 'chr1',
|
|
172
|
+
strand: -1,
|
|
173
|
+
start: 100,
|
|
174
|
+
end: 208,
|
|
175
|
+
subfeatures: [
|
|
176
|
+
{ type: 'CDS', start: 100, end: 107, phase: 0 },
|
|
177
|
+
{ type: 'CDS', start: 200, end: 208, phase: 0 },
|
|
178
|
+
],
|
|
179
|
+
};
|
|
180
|
+
describe('connectedDomains', () => {
|
|
181
|
+
function domainView() {
|
|
182
|
+
const model = stateModelFactory().create({
|
|
183
|
+
type: 'MsaView',
|
|
184
|
+
id: 'msaview1',
|
|
185
|
+
data: { msa: '>QUERY\nMKV-LA\n>Mouse\nMKVQLA' },
|
|
186
|
+
connectedFeature: reverseTranscript,
|
|
187
|
+
});
|
|
188
|
+
model.setAnnotations([
|
|
189
|
+
{
|
|
190
|
+
id: 'QUERY',
|
|
191
|
+
accession: 'cd1',
|
|
192
|
+
name: 'Hb beta-like',
|
|
193
|
+
description: '',
|
|
194
|
+
start: 1,
|
|
195
|
+
end: 5,
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
id: 'QUERY',
|
|
199
|
+
accession: 'cd2',
|
|
200
|
+
name: 'heme binding site',
|
|
201
|
+
description: '',
|
|
202
|
+
start: 2,
|
|
203
|
+
end: 4,
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
id: 'Mouse',
|
|
207
|
+
accession: 'cd1',
|
|
208
|
+
name: 'Hb beta-like',
|
|
209
|
+
description: '',
|
|
210
|
+
start: 1,
|
|
211
|
+
end: 6,
|
|
212
|
+
},
|
|
213
|
+
]);
|
|
214
|
+
return model;
|
|
215
|
+
}
|
|
216
|
+
test('carries the query row domains in the colors the alignment draws', () => {
|
|
217
|
+
const model = domainView();
|
|
218
|
+
const fills = new Map([...model.featureColors].map(([a, c]) => [
|
|
219
|
+
`${a.id}:${a.accession}`,
|
|
220
|
+
c.fill,
|
|
221
|
+
]));
|
|
222
|
+
expect(model.connectedDomains).toEqual([
|
|
223
|
+
{
|
|
224
|
+
name: 'Hb beta-like',
|
|
225
|
+
accession: 'cd1',
|
|
226
|
+
color: fills.get('QUERY:cd1'),
|
|
227
|
+
regions: [
|
|
228
|
+
{ refName: 'chr1', start: 100, end: 107 },
|
|
229
|
+
{ refName: 'chr1', start: 200, end: 208 },
|
|
230
|
+
],
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
name: 'heme binding site',
|
|
234
|
+
accession: 'cd2',
|
|
235
|
+
color: fills.get('QUERY:cd2'),
|
|
236
|
+
regions: [
|
|
237
|
+
{ refName: 'chr1', start: 103, end: 107 },
|
|
238
|
+
{ refName: 'chr1', start: 200, end: 205 },
|
|
239
|
+
],
|
|
240
|
+
},
|
|
241
|
+
]);
|
|
242
|
+
});
|
|
243
|
+
test('follows the overlay and the legend filter', () => {
|
|
244
|
+
const model = domainView();
|
|
245
|
+
model.setFilter('cd2', false);
|
|
246
|
+
expect(model.connectedDomains.map(d => d.accession)).toEqual(['cd1']);
|
|
247
|
+
model.setShowDomains(false);
|
|
248
|
+
expect(model.connectedDomains).toEqual([]);
|
|
249
|
+
});
|
|
250
|
+
});
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import type { MafRegion } from './types';
|
|
2
|
-
interface GenomeRegion {
|
|
2
|
+
export interface GenomeRegion {
|
|
3
3
|
refName: string;
|
|
4
4
|
start: number;
|
|
5
5
|
end: number;
|
|
6
6
|
}
|
|
7
|
-
interface
|
|
8
|
-
querySeqName: string;
|
|
7
|
+
export interface SeqPosModel {
|
|
9
8
|
transcriptToMsaMap: {
|
|
10
9
|
refName: string;
|
|
11
10
|
p2gCodon: Record<number, number[]>;
|
|
@@ -13,6 +12,9 @@ interface CoordModel {
|
|
|
13
12
|
mafRegion?: MafRegion;
|
|
14
13
|
/** transcript residues before the query row's first residue */
|
|
15
14
|
querySeqOffset?: number;
|
|
15
|
+
}
|
|
16
|
+
interface CoordModel extends SeqPosModel {
|
|
17
|
+
querySeqName: string;
|
|
16
18
|
/**
|
|
17
19
|
* react-msaview's converter, which is the only thing that knows which columns
|
|
18
20
|
* are on screen. `rows` carries the whole gapped alignment, so counting
|
|
@@ -22,6 +24,12 @@ interface CoordModel {
|
|
|
22
24
|
*/
|
|
23
25
|
visibleColToSeqPos: (rowName: string, visibleCol: number) => number | undefined;
|
|
24
26
|
}
|
|
27
|
+
/**
|
|
28
|
+
* The genome regions under residue `ungappedPos` (0-based) of the query row,
|
|
29
|
+
* 0-based half-open: the codon, one region per contiguous piece, or one base
|
|
30
|
+
* in a MAF alignment.
|
|
31
|
+
*/
|
|
32
|
+
export declare function seqPosToGenomeRegions(model: SeqPosModel, ungappedPos: number): GenomeRegion[];
|
|
25
33
|
/**
|
|
26
34
|
* The genome regions covered by MSA column `coord` of the query row, in 0-based
|
|
27
35
|
* half-open coordinates (what bpToPx and navTo take).
|
|
@@ -1,20 +1,11 @@
|
|
|
1
1
|
import { getCodonRanges } from 'g2p_mapper';
|
|
2
2
|
/**
|
|
3
|
-
* The genome regions
|
|
4
|
-
* half-open
|
|
5
|
-
*
|
|
6
|
-
* `coord` is a VISIBLE column -- what mouseCol and mouseClickCol carry.
|
|
7
|
-
*
|
|
8
|
-
* Usually one region -- one codon, or one base in a MAF alignment -- but a
|
|
9
|
-
* codon split across an exon boundary yields one region per contiguous piece,
|
|
10
|
-
* which is why this returns a list.
|
|
3
|
+
* The genome regions under residue `ungappedPos` (0-based) of the query row,
|
|
4
|
+
* 0-based half-open: the codon, one region per contiguous piece, or one base
|
|
5
|
+
* in a MAF alignment.
|
|
11
6
|
*/
|
|
12
|
-
export function
|
|
13
|
-
const {
|
|
14
|
-
const ungappedPos = model.visibleColToSeqPos(querySeqName, mouseCol);
|
|
15
|
-
if (ungappedPos === undefined) {
|
|
16
|
-
return [];
|
|
17
|
-
}
|
|
7
|
+
export function seqPosToGenomeRegions(model, ungappedPos) {
|
|
8
|
+
const { transcriptToMsaMap, mafRegion } = model;
|
|
18
9
|
if (mafRegion) {
|
|
19
10
|
const genomePos = mafRegion.start + ungappedPos;
|
|
20
11
|
return genomePos < mafRegion.end
|
|
@@ -40,6 +31,22 @@ export function msaCoordToGenomeRegions({ model, coord: mouseCol, }) {
|
|
|
40
31
|
}
|
|
41
32
|
return [];
|
|
42
33
|
}
|
|
34
|
+
/**
|
|
35
|
+
* The genome regions covered by MSA column `coord` of the query row, in 0-based
|
|
36
|
+
* half-open coordinates (what bpToPx and navTo take).
|
|
37
|
+
*
|
|
38
|
+
* `coord` is a VISIBLE column -- what mouseCol and mouseClickCol carry.
|
|
39
|
+
*
|
|
40
|
+
* Usually one region -- one codon, or one base in a MAF alignment -- but a
|
|
41
|
+
* codon split across an exon boundary yields one region per contiguous piece,
|
|
42
|
+
* which is why this returns a list.
|
|
43
|
+
*/
|
|
44
|
+
export function msaCoordToGenomeRegions({ model, coord: mouseCol, }) {
|
|
45
|
+
const ungappedPos = model.visibleColToSeqPos(model.querySeqName, mouseCol);
|
|
46
|
+
return ungappedPos === undefined
|
|
47
|
+
? []
|
|
48
|
+
: seqPosToGenomeRegions(model, ungappedPos);
|
|
49
|
+
}
|
|
43
50
|
/**
|
|
44
51
|
* A single region spanning the codon at MSA column `coord`, for navigation. For
|
|
45
52
|
* a codon split across an exon boundary this spans the intervening intron.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as l}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=AboutDialog-
|
|
1
|
+
import{a as l}from"./chunk-XTQQNBQ5.js";import{a as i}from"./chunk-DNFD5II2.js";import{a as m}from"./chunk-BX4Z274Q.js";import{a}from"./chunk-J6KYLXRD.js";import{b as r}from"./chunk-FY3BTKY4.js";var e=r(a(),1),o=r(i(),1),t=r(m(),1);function c({onClose:n}){return e.default.createElement(o.Dialog,{open:!0,title:"About",onClose:()=>{n()}},e.default.createElement(t.DialogContent,null,e.default.createElement(t.Typography,null,"MSAView ",l," (",e.default.createElement(t.Link,{target:"_blank",rel:"noopener",href:"https://github.com/gmod/react-msaview"},"Github"),")"),e.default.createElement("ul",null,e.default.createElement("li",null,e.default.createElement(t.Typography,null,"We use some color schemes from the"," ",e.default.createElement(t.Link,{target:"_blank",rel:"noopener",href:"https://github.com/biotite-dev/biotite"},"biotite")," ","project, and their license is reproduced"," ",e.default.createElement(t.Link,{target:"_blank",rel:"noopener",href:"https://github.com/biotite-dev/biotite/blob/master/LICENSE.rst"},"here"))),e.default.createElement("li",null,e.default.createElement(t.Typography,null,"See this page for some information on jalview colorings"," ",e.default.createElement(t.Link,{target:"_blank",rel:"noopener",href:"https://www.jalview.org/help/html/colourSchemes/"},"here"))),e.default.createElement("li",null,e.default.createElement(t.Typography,null,"See this page for some info on the clustal, cinema, maeditor, and lesk color schemes"," ",e.default.createElement(t.Link,{target:"_blank",rel:"noopener",href:"http://www.bioinformatics.nl/~berndb/aacolour.html"},"here"))),e.default.createElement("li",null,e.default.createElement(t.Typography,null,"See this paper about the flower color scheme"," ",e.default.createElement(t.Link,{target:"_blank",rel:"noopener",href:"https://www.ncbi.nlm.nih.gov/pmc/articles/PMC7245768/"},"here"))))))}export{c as default};
|
|
2
|
+
//# sourceMappingURL=AboutDialog-HCCCEJ6V.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../../node_modules/.pnpm/react-msaview@9.1.
|
|
3
|
+
"sources": ["../../node_modules/.pnpm/react-msaview@9.1.0_a4121c98828e538e8b3708814bbfe622/node_modules/react-msaview/src/components/dialogs/AboutDialog.tsx"],
|
|
4
4
|
"sourcesContent": ["import React from 'react'\n\nimport { Dialog } from '@jbrowse/core/ui'\nimport { DialogContent, Link, Typography } from '@mui/material'\n\nimport { version } from '../../version.ts'\n\nexport default function AboutDialog({ onClose }: { onClose: () => void }) {\n return (\n <Dialog\n open\n title=\"About\"\n onClose={() => {\n onClose()\n }}\n >\n <DialogContent>\n <Typography>\n MSAView {version} (\n <Link\n target=\"_blank\"\n rel=\"noopener\"\n href=\"https://github.com/gmod/react-msaview\"\n >\n Github\n </Link>\n )\n </Typography>\n\n <ul>\n <li>\n <Typography>\n We use some color schemes from the{' '}\n <Link\n target=\"_blank\"\n rel=\"noopener\"\n href=\"https://github.com/biotite-dev/biotite\"\n >\n biotite\n </Link>{' '}\n project, and their license is reproduced{' '}\n <Link\n target=\"_blank\"\n rel=\"noopener\"\n href=\"https://github.com/biotite-dev/biotite/blob/master/LICENSE.rst\"\n >\n here\n </Link>\n </Typography>\n </li>\n <li>\n <Typography>\n See this page for some information on jalview colorings{' '}\n <Link\n target=\"_blank\"\n rel=\"noopener\"\n href=\"https://www.jalview.org/help/html/colourSchemes/\"\n >\n here\n </Link>\n </Typography>\n </li>\n <li>\n <Typography>\n See this page for some info on the clustal, cinema, maeditor, and\n lesk color schemes{' '}\n <Link\n target=\"_blank\"\n rel=\"noopener\"\n href=\"http://www.bioinformatics.nl/~berndb/aacolour.html\"\n >\n here\n </Link>\n </Typography>\n </li>\n <li>\n <Typography>\n See this paper about the flower color scheme{' '}\n <Link\n target=\"_blank\"\n rel=\"noopener\"\n href=\"https://www.ncbi.nlm.nih.gov/pmc/articles/PMC7245768/\"\n >\n here\n </Link>\n </Typography>\n </li>\n </ul>\n </DialogContent>\n </Dialog>\n )\n}\n"],
|
|
5
5
|
"mappings": "mMAAA,IAAAA,EAAkB,SAElBC,EAAuB,SACvBC,EAAgD,SAIlC,SAAPC,EAA6B,CAAE,QAAAC,CAAO,EAA2B,CACtE,OACE,EAAAC,QAAA,cAAC,SAAM,CACL,KAAI,GACJ,MAAM,QACN,QAAS,IAAK,CACZD,EAAO,CACT,CAAC,EAED,EAAAC,QAAA,cAAC,gBAAa,KACZ,EAAAA,QAAA,cAAC,aAAU,gBACAC,OACT,EAAAD,QAAA,cAAC,OAAI,CACH,OAAO,SACP,IAAI,WACJ,KAAK,uCAAuC,EAAA,QAAA,OAOhD,EAAAA,QAAA,cAAA,KAAA,KACE,EAAAA,QAAA,cAAA,KAAA,KACE,EAAAA,QAAA,cAAC,aAAU,0CAC0B,IACnC,EAAAA,QAAA,cAAC,OAAI,CACH,OAAO,SACP,IAAI,WACJ,KAAK,wCAAwC,EAAA,SAAA,EAGvC,+CACiC,IACzC,EAAAA,QAAA,cAAC,OAAI,CACH,OAAO,SACP,IAAI,WACJ,KAAK,gEAAgE,EAAA,MAAA,CAGhE,CACI,EAEf,EAAAA,QAAA,cAAA,KAAA,KACE,EAAAA,QAAA,cAAC,aAAU,+DAC+C,IACxD,EAAAA,QAAA,cAAC,OAAI,CACH,OAAO,SACP,IAAI,WACJ,KAAK,kDAAkD,EAAA,MAAA,CAGlD,CACI,EAEf,EAAAA,QAAA,cAAA,KAAA,KACE,EAAAA,QAAA,cAAC,aAAU,4FAEU,IACnB,EAAAA,QAAA,cAAC,OAAI,CACH,OAAO,SACP,IAAI,WACJ,KAAK,oDAAoD,EAAA,MAAA,CAGpD,CACI,EAEf,EAAAA,QAAA,cAAA,KAAA,KACE,EAAAA,QAAA,cAAC,aAAU,oDACoC,IAC7C,EAAAA,QAAA,cAAC,OAAI,CACH,OAAO,SACP,IAAI,WACJ,KAAK,uDAAuD,EAAA,MAAA,CAGvD,CACI,CACV,CACF,CACS,CAGtB",
|
|
6
6
|
"names": ["import_react", "import_ui", "import_material", "AboutDialog", "onClose", "React", "version"]
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{i as E}from"./chunk-XXCNVFGP.js";import"./chunk-73KAPCJ2.js";import{a as x}from"./chunk-CVLB4VFP.js";import{a as C}from"./chunk-DNFD5II2.js";import{a as w}from"./chunk-BX4Z274Q.js";import{a as y}from"./chunk-J6KYLXRD.js";import{b as i}from"./chunk-FY3BTKY4.js";var e=i(y(),1),c=i(C(),1),t=i(w(),1),d=i(x(),1);async function T(o){let l=await fetch(o);if(!l.ok)throw new Error(`HTTP ${l.status} fetching ${o} ${await l.text()}`);return l.text()}var b=(0,d.observer)(function({handleClose:o,model:l}){let[a,h]=(0,e.useState)(),[r,g]=(0,e.useState)("file"),[s,F]=(0,e.useState)(""),[m,u]=(0,e.useState)(),[v,f]=(0,e.useState)(!1);return e.default.createElement(c.Dialog,{maxWidth:"xl",title:"Open annotation file",onClose:()=>{o()},open:!0},e.default.createElement(t.DialogContent,null,m?e.default.createElement(c.ErrorMessage,{error:m}):null,e.default.createElement(t.Typography,null,"Open a GFF3 file of annotations, such as the one `react-msaview-cli interpro` writes, or the JSON an InterProScan run returns."),e.default.createElement("div",{style:{display:"flex",margin:30}},e.default.createElement(t.FormControl,{component:"fieldset"},e.default.createElement(t.RadioGroup,{value:r,onChange:n=>{g(n.target.value)}},e.default.createElement(t.FormControlLabel,{value:"url",control:e.default.createElement(t.Radio,null),label:"URL"}),e.default.createElement(t.FormControlLabel,{value:"file",control:e.default.createElement(t.Radio,null),label:"File"}))),r==="url"?e.default.createElement("div",null,e.default.createElement(t.Typography,null,"Open an annotation file from a URL"),e.default.createElement(t.TextField,{label:"URL",value:s,onChange:n=>{F(n.target.value)}})):e.default.createElement("div",{style:{paddingTop:20}},e.default.createElement(t.Typography,null,"Open an annotation file from your local drive"),e.default.createElement(t.Button,{variant:"outlined",component:"label"},"Choose File",e.default.createElement("input",{type:"file",hidden:!0,onChange:({target:n})=>{let p=n.files?.[0];p&&h(p)}})),a?e.default.createElement(t.Typography,null,a.name):null))),e.default.createElement(t.DialogActions,null,e.default.createElement(t.Button,{variant:"contained",color:"primary",disabled:v||(r==="file"?!a:!s.trim()),onClick:()=>{(async()=>{f(!0),u(void 0);try{let n=await(r==="file"&&a?a.text():T(s));l.setGFFFilehandle(void 0),l.setGFF(E(n)),l.setShowDomains(!0),o()}catch(n){console.error(n),u(n)}finally{f(!1)}})()}},"Open annotations"),e.default.createElement(t.Button,{variant:"contained",color:"secondary",onClick:()=>{o()}},"Cancel")))}),R=b;export{R as default};
|
|
2
|
+
//# sourceMappingURL=AnnotationFileDialog-CPJ4X7XW.js.map
|
package/dist/chunks/{AnnotationFileDialog-S3N5EHHE.js.map → AnnotationFileDialog-CPJ4X7XW.js.map}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../../node_modules/.pnpm/react-msaview@9.1.
|
|
3
|
+
"sources": ["../../node_modules/.pnpm/react-msaview@9.1.0_a4121c98828e538e8b3708814bbfe622/node_modules/react-msaview/src/components/dialogs/AnnotationFileDialog.tsx"],
|
|
4
4
|
"sourcesContent": ["import React, { useState } from 'react'\n\nimport { Dialog, ErrorMessage } from '@jbrowse/core/ui'\nimport {\n Button,\n DialogActions,\n DialogContent,\n FormControl,\n FormControlLabel,\n Radio,\n RadioGroup,\n TextField,\n Typography,\n} from '@mui/material'\nimport { observer } from 'mobx-react'\nimport { annotationTextToGFF } from 'msa-parsers'\n\nimport type { MsaViewModel } from '../../model.ts'\n\nasync function fetchText(url: string) {\n const response = await fetch(url)\n if (!response.ok) {\n throw new Error(\n `HTTP ${response.status} fetching ${url} ${await response.text()}`,\n )\n }\n return response.text()\n}\n\nconst AnnotationFileDialog = observer(function ({\n handleClose,\n model,\n}: {\n handleClose: () => void\n model: MsaViewModel\n}) {\n const [file, setFile] = useState<File>()\n const [choice, setChoice] = useState('file')\n const [url, setUrl] = useState('')\n const [error, setError] = useState<unknown>()\n const [loading, setLoading] = useState(false)\n\n // the error is shown here rather than notified: the standalone app and the\n // MSAViewer component have no jbrowse session to notify, and asking one for\n // its notify() threw out of the success path into the catch, which threw\n // again on the same missing session\n return (\n <Dialog\n maxWidth=\"xl\"\n title=\"Open annotation file\"\n onClose={() => {\n handleClose()\n }}\n open\n >\n <DialogContent>\n {error ? <ErrorMessage error={error} /> : null}\n <Typography>\n Open a GFF3 file of annotations, such as the one `react-msaview-cli\n interpro` writes, or the JSON an InterProScan run returns.\n </Typography>\n\n <div style={{ display: 'flex', margin: 30 }}>\n <FormControl component=\"fieldset\">\n <RadioGroup\n value={choice}\n onChange={event => {\n setChoice(event.target.value)\n }}\n >\n <FormControlLabel value=\"url\" control={<Radio />} label=\"URL\" />\n <FormControlLabel value=\"file\" control={<Radio />} label=\"File\" />\n </RadioGroup>\n </FormControl>\n {choice === 'url' ? (\n <div>\n <Typography>Open an annotation file from a URL</Typography>\n <TextField\n label=\"URL\"\n value={url}\n onChange={event => {\n setUrl(event.target.value)\n }}\n />\n </div>\n ) : (\n <div style={{ paddingTop: 20 }}>\n <Typography>\n Open an annotation file from your local drive\n </Typography>\n <Button variant=\"outlined\" component=\"label\">\n Choose File\n <input\n type=\"file\"\n hidden\n onChange={({ target }) => {\n const chosen = target.files?.[0]\n if (chosen) {\n setFile(chosen)\n }\n }}\n />\n </Button>\n {file ? <Typography>{file.name}</Typography> : null}\n </div>\n )}\n </div>\n </DialogContent>\n <DialogActions>\n <Button\n variant=\"contained\"\n color=\"primary\"\n disabled={loading || (choice === 'file' ? !file : !url.trim())}\n onClick={() => {\n // eslint-disable-next-line @typescript-eslint/no-floating-promises\n ;(async () => {\n setLoading(true)\n setError(undefined)\n try {\n const text = await (choice === 'file' && file\n ? file.text()\n : fetchText(url))\n // through the model's own GFF text, so the annotations travel\n // in the snapshot and the shared URL like every other layer. A\n // filehandle left set would make the snapshot drop that text\n model.setGFFFilehandle(undefined)\n model.setGFF(annotationTextToGFF(text))\n model.setShowDomains(true)\n handleClose()\n } catch (e) {\n console.error(e)\n setError(e)\n } finally {\n setLoading(false)\n }\n })()\n }}\n >\n Open annotations\n </Button>\n <Button\n variant=\"contained\"\n color=\"secondary\"\n onClick={() => {\n handleClose()\n }}\n >\n Cancel\n </Button>\n </DialogActions>\n </Dialog>\n )\n})\n\nexport default AnnotationFileDialog\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "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",
|
|
6
6
|
"names": ["import_react", "import_ui", "import_material", "import_mobx_react", "fetchText", "url", "response", "AnnotationFileDialog", "handleClose", "model", "file", "setFile", "choice", "setChoice", "setUrl", "error", "setError", "loading", "setLoading", "React", "event", "target", "chosen", "text", "annotationTextToGFF", "e", "AnnotationFileDialog_default"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as p}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=ExportSVGDialog-
|
|
1
|
+
import{a as p}from"./chunk-GAY2PLS6.js";import{X as v,Y as y}from"./chunk-ZQSWX57C.js";import{a as L}from"./chunk-CVLB4VFP.js";import{a as D}from"./chunk-DNFD5II2.js";import{a as V}from"./chunk-BX4Z274Q.js";import{a as I}from"./chunk-J6KYLXRD.js";import{b as l}from"./chunk-FY3BTKY4.js";var t=l(I(),1),i=l(D(),1),e=l(V(),1),k=l(L(),1);function z(r){requestAnimationFrame(()=>{requestAnimationFrame(r)})}var P=(0,k.observer)(function({model:r,onClose:c}){let[s,C]=(0,t.useState)(!0),[n,T]=(0,t.useState)(!0),[o,b]=(0,t.useState)("viewport"),[E,w]=(0,t.useState)(),[m,h]=(0,t.useState)(!1),d=(0,e.useTheme)(),{turnedOnTracks:M,numColumns:S,leaves:A,showMsaLetters:F}=r,g=M.length>0,x=y(r,v(r,{theme:d,exportType:"entire",includeTracks:n})),f=F&&o==="entire"?S*A.length:0,G=f>1e5;return t.default.createElement(i.Dialog,{onClose:()=>{c()},open:!0,title:"Export SVG"},t.default.createElement(e.DialogContent,null,E?t.default.createElement(i.ErrorMessage,{error:E}):null,t.default.createElement(e.Typography,null,"Settings:"),t.default.createElement(p,{label:"Include minimap?",disabled:o==="entire",checked:s,onChange:()=>{C(!s)}}),g?t.default.createElement(p,{label:"Include tracks?",checked:n,onChange:()=>{T(!n)}}):null,t.default.createElement("div",null,t.default.createElement(e.FormControl,null,t.default.createElement(e.FormLabel,null,"Export type"),t.default.createElement(e.RadioGroup,{value:o,onChange:a=>{let{value:u}=a.target;(u==="entire"||u==="viewport")&&b(u)}},t.default.createElement(e.FormControlLabel,{value:"entire",control:t.default.createElement(e.Radio,null),label:"Entire MSA"}),t.default.createElement(e.FormControlLabel,{value:"viewport",control:t.default.createElement(e.Radio,null),label:"Current viewport only"})))),G?t.default.createElement(e.Alert,{severity:"warning",style:{marginTop:8}},"The entire MSA is ",Math.round(x.width),"x",Math.round(x.height)," pixels and draws"," ",Math.round(f/1e3),"k residue letters, each its own SVG element. Export may be slow or fail \u2014 zooming out far enough to hide the letters exports the same alignment as an image instead."):null),t.default.createElement(e.DialogActions,null,t.default.createElement(e.Button,{variant:"contained",color:"primary",disabled:m,startIcon:m?t.default.createElement(e.CircularProgress,{size:16,color:"inherit"}):null,onClick:()=>{h(!0),z(()=>{r.exportSVG({theme:d,includeMinimap:s,includeTracks:g&&n,exportType:o}).then(()=>{c()}).catch(a=>{console.error(a),w(a)}).finally(()=>{h(!1)})})}},m?"Exporting\u2026":"Export"),t.default.createElement(e.Button,{variant:"contained",color:"secondary",onClick:()=>{c()}},"Cancel")))}),B=P;export{B as default};
|
|
2
|
+
//# sourceMappingURL=ExportSVGDialog-YUFLYBYW.js.map
|