@jbrowse/plugin-variants 2.10.3 → 2.11.1

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.
Files changed (45) hide show
  1. package/dist/ChordVariantDisplay/index.d.ts +1 -2
  2. package/dist/ChordVariantDisplay/index.js +3 -2
  3. package/dist/LinearVariantDisplay/index.d.ts +1 -2
  4. package/dist/LinearVariantDisplay/index.js +3 -2
  5. package/dist/StructuralVariantChordRenderer/Chord.js +1 -1
  6. package/dist/StructuralVariantChordRenderer/index.d.ts +1 -2
  7. package/dist/StructuralVariantChordRenderer/index.js +3 -2
  8. package/dist/VariantFeatureWidget/index.d.ts +1 -2
  9. package/dist/VariantFeatureWidget/index.js +3 -2
  10. package/dist/VariantFeatureWidget/stateModelFactory.d.ts +23 -0
  11. package/dist/VariantTrack/index.d.ts +1 -2
  12. package/dist/VariantTrack/index.js +3 -2
  13. package/dist/VcfAdapter/index.d.ts +1 -2
  14. package/dist/VcfAdapter/index.js +3 -2
  15. package/dist/VcfFeature/util.d.ts +1 -1
  16. package/dist/VcfFeature/util.js +3 -3
  17. package/dist/VcfTabixAdapter/VcfTabixAdapter.d.ts +1 -1
  18. package/dist/VcfTabixAdapter/VcfTabixAdapter.js +2 -2
  19. package/dist/VcfTabixAdapter/index.d.ts +1 -2
  20. package/dist/VcfTabixAdapter/index.js +3 -2
  21. package/dist/extensionPoints.d.ts +1 -2
  22. package/dist/extensionPoints.js +3 -2
  23. package/esm/ChordVariantDisplay/index.d.ts +1 -2
  24. package/esm/ChordVariantDisplay/index.js +2 -2
  25. package/esm/LinearVariantDisplay/index.d.ts +1 -2
  26. package/esm/LinearVariantDisplay/index.js +2 -2
  27. package/esm/StructuralVariantChordRenderer/Chord.js +2 -2
  28. package/esm/StructuralVariantChordRenderer/index.d.ts +1 -2
  29. package/esm/StructuralVariantChordRenderer/index.js +2 -2
  30. package/esm/VariantFeatureWidget/index.d.ts +1 -2
  31. package/esm/VariantFeatureWidget/index.js +2 -2
  32. package/esm/VariantFeatureWidget/stateModelFactory.d.ts +23 -0
  33. package/esm/VariantTrack/index.d.ts +1 -2
  34. package/esm/VariantTrack/index.js +2 -2
  35. package/esm/VcfAdapter/index.d.ts +1 -2
  36. package/esm/VcfAdapter/index.js +2 -2
  37. package/esm/VcfFeature/util.d.ts +1 -1
  38. package/esm/VcfFeature/util.js +3 -3
  39. package/esm/VcfTabixAdapter/VcfTabixAdapter.d.ts +1 -1
  40. package/esm/VcfTabixAdapter/VcfTabixAdapter.js +1 -1
  41. package/esm/VcfTabixAdapter/index.d.ts +1 -2
  42. package/esm/VcfTabixAdapter/index.js +2 -2
  43. package/esm/extensionPoints.d.ts +1 -2
  44. package/esm/extensionPoints.js +2 -2
  45. package/package.json +3 -3
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function ChordVariantDisplayF(pluginManager: PluginManager): void;
@@ -8,7 +8,7 @@ const DisplayType_1 = __importDefault(require("@jbrowse/core/pluggableElementTyp
8
8
  // locals
9
9
  const configSchema_1 = __importDefault(require("./models/configSchema"));
10
10
  const stateModelFactory_1 = __importDefault(require("./models/stateModelFactory"));
11
- exports.default = (pluginManager) => {
11
+ function ChordVariantDisplayF(pluginManager) {
12
12
  pluginManager.addDisplayType(() => {
13
13
  const configSchema = (0, configSchema_1.default)(pluginManager);
14
14
  const stateModel = (0, stateModelFactory_1.default)(configSchema);
@@ -22,4 +22,5 @@ exports.default = (pluginManager) => {
22
22
  ReactComponent: plugin_circular_view_1.BaseChordDisplayComponent,
23
23
  });
24
24
  });
25
- };
25
+ }
26
+ exports.default = ChordVariantDisplayF;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function LinearVariantDisplayF(pluginManager: PluginManager): void;
@@ -7,7 +7,7 @@ const plugin_linear_genome_view_1 = require("@jbrowse/plugin-linear-genome-view"
7
7
  const DisplayType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/DisplayType"));
8
8
  const model_1 = __importDefault(require("./model"));
9
9
  const configSchema_1 = __importDefault(require("./configSchema"));
10
- exports.default = (pluginManager) => {
10
+ function LinearVariantDisplayF(pluginManager) {
11
11
  pluginManager.addDisplayType(() => {
12
12
  const configSchema = (0, configSchema_1.default)(pluginManager);
13
13
  return new DisplayType_1.default({
@@ -20,4 +20,5 @@ exports.default = (pluginManager) => {
20
20
  ReactComponent: plugin_linear_genome_view_1.BaseLinearDisplayComponent,
21
21
  });
22
22
  });
23
- };
23
+ }
24
+ exports.default = LinearVariantDisplayF;
@@ -87,7 +87,7 @@ const Chord = (0, mobx_react_1.observer)(function Chord({ feature, blocksForRefs
87
87
  const hoverStrokeColor = (0, configuration_1.readConfObject)(config, 'strokeColorHover', {
88
88
  feature,
89
89
  });
90
- return (react_1.default.createElement("path", { "data-testid": `chord-${feature.id()}`, cursor: "crosshair", fill: "none", d: ['M', ...startXY, 'Q', ...controlXY, ...endXY].join(' '), stroke: hovered ? hoverStrokeColor : strokeColor, strokeWidth: hovered ? 3 : 1, onClick: evt => {
90
+ return (react_1.default.createElement("path", { "data-testid": `chord-${feature.id()}`, cursor: "crosshair", fill: "none", d: ['M', ...startXY, 'Q', ...controlXY, ...endXY].join(' '), ...(0, util_1.getStrokeProps)(hovered ? hoverStrokeColor : strokeColor), strokeWidth: hovered ? 3 : 1, onClick: evt => {
91
91
  if (endBlock && startBlock) {
92
92
  onClick(feature, startBlock.region, endBlock.region, evt);
93
93
  }
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function StructuralVariantChordRendererF(pluginManager: PluginManager): void;
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const CircularChordRendererType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/renderers/CircularChordRendererType"));
7
7
  const configSchema_1 = __importDefault(require("./configSchema"));
8
8
  const ReactComponent_1 = __importDefault(require("./ReactComponent"));
9
- exports.default = (pluginManager) => {
9
+ function StructuralVariantChordRendererF(pluginManager) {
10
10
  pluginManager.addRendererType(() => new CircularChordRendererType_1.default({
11
11
  name: 'StructuralVariantChordRenderer',
12
12
  displayName: 'SV chord renderer',
@@ -14,4 +14,5 @@ exports.default = (pluginManager) => {
14
14
  configSchema: configSchema_1.default,
15
15
  pluginManager,
16
16
  }));
17
- };
17
+ }
18
+ exports.default = StructuralVariantChordRendererF;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function VariantFeatureWidgetF(pluginManager: PluginManager): void;
@@ -30,7 +30,7 @@ const react_1 = require("react");
30
30
  const WidgetType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/WidgetType"));
31
31
  const stateModelFactory_1 = require("./stateModelFactory");
32
32
  const configSchema_1 = require("./configSchema");
33
- exports.default = (pluginManager) => {
33
+ function VariantFeatureWidgetF(pluginManager) {
34
34
  pluginManager.addWidgetType(() => new WidgetType_1.default({
35
35
  name: 'VariantFeatureWidget',
36
36
  heading: 'Feature details',
@@ -38,4 +38,5 @@ exports.default = (pluginManager) => {
38
38
  stateModel: (0, stateModelFactory_1.stateModelFactory)(pluginManager),
39
39
  ReactComponent: (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('./VariantFeatureWidget')))),
40
40
  }));
41
- };
41
+ }
42
+ exports.default = VariantFeatureWidgetF;
@@ -11,6 +11,17 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
11
11
  trackId: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
12
12
  trackType: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
13
13
  maxDepth: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<number>>;
14
+ sequenceFeatureDetails: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IModelType<{}, {
15
+ intronBp: number;
16
+ upDownBp: number;
17
+ upperCaseCDS: boolean;
18
+ } & {
19
+ setUpDownBp(f: number): void;
20
+ setIntronBp(f: number): void;
21
+ setUpperCaseCDS(f: boolean): void;
22
+ } & {
23
+ afterAttach(): void;
24
+ }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>, [undefined]>;
14
25
  } & {
15
26
  type: import("mobx-state-tree").ISimpleType<"VariantFeatureWidget">;
16
27
  descriptions: import("mobx-state-tree").IType<any, any, any>;
@@ -37,6 +48,17 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
37
48
  trackId: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
38
49
  trackType: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
39
50
  maxDepth: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<number>>;
51
+ sequenceFeatureDetails: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IModelType<{}, {
52
+ intronBp: number;
53
+ upDownBp: number;
54
+ upperCaseCDS: boolean;
55
+ } & {
56
+ setUpDownBp(f: number): void;
57
+ setIntronBp(f: number): void;
58
+ setUpperCaseCDS(f: boolean): void;
59
+ } & {
60
+ afterAttach(): void;
61
+ }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>, [undefined]>;
40
62
  }>> & import("mobx-state-tree/dist/internal").NonEmptyObject & import("mobx-state-tree")._NotCustomized, {
41
63
  id: string;
42
64
  type: "BaseFeatureWidget";
@@ -46,6 +68,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
46
68
  trackType: string | undefined;
47
69
  maxDepth: number | undefined;
48
70
  formattedFields: any;
71
+ sequenceFeatureDetails: import("mobx-state-tree").ModelSnapshotType<{}>;
49
72
  finalizedFeatureData: any;
50
73
  } & import("mobx-state-tree")._NotCustomized>;
51
74
  export type VariantFeatureWidgetStateModel = ReturnType<typeof stateModelFactory>;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pm: PluginManager) => void;
3
- export default _default;
2
+ export default function VariantTrackF(pm: PluginManager): void;
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const TrackType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/TrackType"));
7
7
  const models_1 = require("@jbrowse/core/pluggableElementTypes/models");
8
8
  const configSchema_1 = __importDefault(require("./configSchema"));
9
- exports.default = (pm) => {
9
+ function VariantTrackF(pm) {
10
10
  pm.addTrackType(() => {
11
11
  const configSchema = (0, configSchema_1.default)(pm);
12
12
  return new TrackType_1.default({
@@ -16,4 +16,5 @@ exports.default = (pm) => {
16
16
  stateModel: (0, models_1.createBaseTrackModel)(pm, 'VariantTrack', configSchema),
17
17
  });
18
18
  });
19
- };
19
+ }
20
+ exports.default = VariantTrackF;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function VcfAdapterF(pluginManager: PluginManager): void;
@@ -28,11 +28,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
29
  const AdapterType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/AdapterType"));
30
30
  const configSchema_1 = __importDefault(require("./configSchema"));
31
- exports.default = (pluginManager) => {
31
+ function VcfAdapterF(pluginManager) {
32
32
  pluginManager.addAdapterType(() => new AdapterType_1.default({
33
33
  name: 'VcfAdapter',
34
34
  displayName: 'VCF adapter',
35
35
  configSchema: configSchema_1.default,
36
36
  getAdapterClass: () => Promise.resolve().then(() => __importStar(require('./VcfAdapter'))).then(r => r.default),
37
37
  }));
38
- };
38
+ }
39
+ exports.default = VcfAdapterF;
@@ -3,5 +3,5 @@ import VCF from '@gmod/vcf';
3
3
  * Get a sequence ontology (SO) term that describes the variant type
4
4
  */
5
5
  export declare function getSOTermAndDescription(ref: string, alt: string[], parser: VCF): string[];
6
- export declare function getSOAndDescFromAltDefs(ref: string, alt: string, parser: VCF): string[];
6
+ export declare function getSOAndDescFromAltDefs(alt: string, parser: VCF): string[];
7
7
  export declare function getSOAndDescByExamination(ref: string, alt: string): string[];
@@ -25,7 +25,7 @@ function getSOTermAndDescription(ref, alt, parser) {
25
25
  const soTerms = new Set();
26
26
  let descriptions = new Set();
27
27
  alt.forEach(a => {
28
- let [soTerm, description] = getSOAndDescFromAltDefs(ref, a, parser);
28
+ let [soTerm, description] = getSOAndDescFromAltDefs(a, parser);
29
29
  if (!soTerm) {
30
30
  ;
31
31
  [soTerm, description] = getSOAndDescByExamination(ref, a);
@@ -58,7 +58,7 @@ function getSOTermAndDescription(ref, alt, parser) {
58
58
  return [];
59
59
  }
60
60
  exports.getSOTermAndDescription = getSOTermAndDescription;
61
- function getSOAndDescFromAltDefs(ref, alt, parser) {
61
+ function getSOAndDescFromAltDefs(alt, parser) {
62
62
  if (typeof alt === 'string' && !alt.startsWith('<')) {
63
63
  return [];
64
64
  }
@@ -74,7 +74,7 @@ function getSOAndDescFromAltDefs(ref, alt, parser) {
74
74
  // try to look for a definition for a parent term if we can
75
75
  const modAlt = alt.split(':');
76
76
  if (modAlt.length > 1) {
77
- return getSOAndDescFromAltDefs(ref, `<${modAlt.slice(0, -1).join(':')}>`, parser);
77
+ return getSOAndDescFromAltDefs(`<${modAlt.slice(0, -1).join(':')}>`, parser);
78
78
  }
79
79
  // no parent
80
80
  return [];
@@ -3,7 +3,7 @@ import { NoAssemblyRegion } from '@jbrowse/core/util/types';
3
3
  import { Feature } from '@jbrowse/core/util';
4
4
  import { TabixIndexedFile } from '@gmod/tabix';
5
5
  import VcfParser from '@gmod/vcf';
6
- export default class extends BaseFeatureDataAdapter {
6
+ export default class VcfTabixAdapter extends BaseFeatureDataAdapter {
7
7
  private configured?;
8
8
  private configurePre;
9
9
  protected configure(): Promise<{
@@ -10,7 +10,7 @@ const tabix_1 = require("@gmod/tabix");
10
10
  const vcf_1 = __importDefault(require("@gmod/vcf"));
11
11
  // local
12
12
  const VcfFeature_1 = __importDefault(require("../VcfFeature"));
13
- class default_1 extends BaseAdapter_1.BaseFeatureDataAdapter {
13
+ class VcfTabixAdapter extends BaseAdapter_1.BaseFeatureDataAdapter {
14
14
  async configurePre() {
15
15
  const pm = this.pluginManager;
16
16
  const vcfGzLocation = this.getConf('vcfGzLocation');
@@ -71,4 +71,4 @@ class default_1 extends BaseAdapter_1.BaseFeatureDataAdapter {
71
71
  }
72
72
  freeResources( /* { region } */) { }
73
73
  }
74
- exports.default = default_1;
74
+ exports.default = VcfTabixAdapter;
@@ -1,4 +1,3 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
2
  export { default as configSchema } from './configSchema';
3
- declare const _default: (pluginManager: PluginManager) => void;
4
- export default _default;
3
+ export default function VcfTabixAdapterF(pluginManager: PluginManager): void;
@@ -31,11 +31,12 @@ const AdapterType_1 = __importDefault(require("@jbrowse/core/pluggableElementTyp
31
31
  const configSchema_1 = __importDefault(require("./configSchema"));
32
32
  var configSchema_2 = require("./configSchema");
33
33
  Object.defineProperty(exports, "configSchema", { enumerable: true, get: function () { return __importDefault(configSchema_2).default; } });
34
- exports.default = (pluginManager) => {
34
+ function VcfTabixAdapterF(pluginManager) {
35
35
  pluginManager.addAdapterType(() => new AdapterType_1.default({
36
36
  name: 'VcfTabixAdapter',
37
37
  displayName: 'VCF tabix adapter',
38
38
  configSchema: configSchema_1.default,
39
39
  getAdapterClass: () => Promise.resolve().then(() => __importStar(require('./VcfTabixAdapter'))).then(r => r.default),
40
40
  }));
41
- };
41
+ }
42
+ exports.default = VcfTabixAdapterF;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function ExtensionPointsF(pluginManager: PluginManager): void;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tracks_1 = require("@jbrowse/core/util/tracks");
4
- exports.default = (pluginManager) => {
4
+ function ExtensionPointsF(pluginManager) {
5
5
  pluginManager.addToExtensionPoint('Core-guessAdapterForLocation', (adapterGuesser) => {
6
6
  return (file, index, adapterHint) => {
7
7
  const regexGuess = /\.vcf\.b?gz$/i;
@@ -47,4 +47,5 @@ exports.default = (pluginManager) => {
47
47
  return adapterGuesser(file, index, adapterHint);
48
48
  };
49
49
  });
50
- };
50
+ }
51
+ exports.default = ExtensionPointsF;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function ChordVariantDisplayF(pluginManager: PluginManager): void;
@@ -3,7 +3,7 @@ import DisplayType from '@jbrowse/core/pluggableElementTypes/DisplayType';
3
3
  // locals
4
4
  import configSchemaF from './models/configSchema';
5
5
  import stateModelF from './models/stateModelFactory';
6
- export default (pluginManager) => {
6
+ export default function ChordVariantDisplayF(pluginManager) {
7
7
  pluginManager.addDisplayType(() => {
8
8
  const configSchema = configSchemaF(pluginManager);
9
9
  const stateModel = stateModelF(configSchema);
@@ -17,4 +17,4 @@ export default (pluginManager) => {
17
17
  ReactComponent: BaseChordDisplayComponent,
18
18
  });
19
19
  });
20
- };
20
+ }
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function LinearVariantDisplayF(pluginManager: PluginManager): void;
@@ -2,7 +2,7 @@ import { BaseLinearDisplayComponent } from '@jbrowse/plugin-linear-genome-view';
2
2
  import DisplayType from '@jbrowse/core/pluggableElementTypes/DisplayType';
3
3
  import stateModelFactory from './model';
4
4
  import configSchemaF from './configSchema';
5
- export default (pluginManager) => {
5
+ export default function LinearVariantDisplayF(pluginManager) {
6
6
  pluginManager.addDisplayType(() => {
7
7
  const configSchema = configSchemaF(pluginManager);
8
8
  return new DisplayType({
@@ -15,4 +15,4 @@ export default (pluginManager) => {
15
15
  ReactComponent: BaseLinearDisplayComponent,
16
16
  });
17
17
  });
18
- };
18
+ }
@@ -1,6 +1,6 @@
1
1
  import React, { useState } from 'react';
2
2
  import { observer } from 'mobx-react';
3
- import { polarToCartesian } from '@jbrowse/core/util';
3
+ import { polarToCartesian, getStrokeProps } from '@jbrowse/core/util';
4
4
  import { readConfObject, } from '@jbrowse/core/configuration';
5
5
  import { parseBreakend } from '@gmod/vcf';
6
6
  function bpToRadians(block, pos) {
@@ -62,7 +62,7 @@ const Chord = observer(function Chord({ feature, blocksForRefs, radius, config,
62
62
  const hoverStrokeColor = readConfObject(config, 'strokeColorHover', {
63
63
  feature,
64
64
  });
65
- return (React.createElement("path", { "data-testid": `chord-${feature.id()}`, cursor: "crosshair", fill: "none", d: ['M', ...startXY, 'Q', ...controlXY, ...endXY].join(' '), stroke: hovered ? hoverStrokeColor : strokeColor, strokeWidth: hovered ? 3 : 1, onClick: evt => {
65
+ return (React.createElement("path", { "data-testid": `chord-${feature.id()}`, cursor: "crosshair", fill: "none", d: ['M', ...startXY, 'Q', ...controlXY, ...endXY].join(' '), ...getStrokeProps(hovered ? hoverStrokeColor : strokeColor), strokeWidth: hovered ? 3 : 1, onClick: evt => {
66
66
  if (endBlock && startBlock) {
67
67
  onClick(feature, startBlock.region, endBlock.region, evt);
68
68
  }
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function StructuralVariantChordRendererF(pluginManager: PluginManager): void;
@@ -1,7 +1,7 @@
1
1
  import ChordRendererType from '@jbrowse/core/pluggableElementTypes/renderers/CircularChordRendererType';
2
2
  import configSchema from './configSchema';
3
3
  import ReactComponent from './ReactComponent';
4
- export default (pluginManager) => {
4
+ export default function StructuralVariantChordRendererF(pluginManager) {
5
5
  pluginManager.addRendererType(() => new ChordRendererType({
6
6
  name: 'StructuralVariantChordRenderer',
7
7
  displayName: 'SV chord renderer',
@@ -9,4 +9,4 @@ export default (pluginManager) => {
9
9
  configSchema,
10
10
  pluginManager,
11
11
  }));
12
- };
12
+ }
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function VariantFeatureWidgetF(pluginManager: PluginManager): void;
@@ -2,7 +2,7 @@ import { lazy } from 'react';
2
2
  import WidgetType from '@jbrowse/core/pluggableElementTypes/WidgetType';
3
3
  import { stateModelFactory } from './stateModelFactory';
4
4
  import { configSchema } from './configSchema';
5
- export default (pluginManager) => {
5
+ export default function VariantFeatureWidgetF(pluginManager) {
6
6
  pluginManager.addWidgetType(() => new WidgetType({
7
7
  name: 'VariantFeatureWidget',
8
8
  heading: 'Feature details',
@@ -10,4 +10,4 @@ export default (pluginManager) => {
10
10
  stateModel: stateModelFactory(pluginManager),
11
11
  ReactComponent: lazy(() => import('./VariantFeatureWidget')),
12
12
  }));
13
- };
13
+ }
@@ -11,6 +11,17 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
11
11
  trackId: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
12
12
  trackType: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
13
13
  maxDepth: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<number>>;
14
+ sequenceFeatureDetails: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IModelType<{}, {
15
+ intronBp: number;
16
+ upDownBp: number;
17
+ upperCaseCDS: boolean;
18
+ } & {
19
+ setUpDownBp(f: number): void;
20
+ setIntronBp(f: number): void;
21
+ setUpperCaseCDS(f: boolean): void;
22
+ } & {
23
+ afterAttach(): void;
24
+ }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>, [undefined]>;
14
25
  } & {
15
26
  type: import("mobx-state-tree").ISimpleType<"VariantFeatureWidget">;
16
27
  descriptions: import("mobx-state-tree").IType<any, any, any>;
@@ -37,6 +48,17 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
37
48
  trackId: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
38
49
  trackType: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
39
50
  maxDepth: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<number>>;
51
+ sequenceFeatureDetails: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IModelType<{}, {
52
+ intronBp: number;
53
+ upDownBp: number;
54
+ upperCaseCDS: boolean;
55
+ } & {
56
+ setUpDownBp(f: number): void;
57
+ setIntronBp(f: number): void;
58
+ setUpperCaseCDS(f: boolean): void;
59
+ } & {
60
+ afterAttach(): void;
61
+ }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>, [undefined]>;
40
62
  }>> & import("mobx-state-tree/dist/internal").NonEmptyObject & import("mobx-state-tree")._NotCustomized, {
41
63
  id: string;
42
64
  type: "BaseFeatureWidget";
@@ -46,6 +68,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
46
68
  trackType: string | undefined;
47
69
  maxDepth: number | undefined;
48
70
  formattedFields: any;
71
+ sequenceFeatureDetails: import("mobx-state-tree").ModelSnapshotType<{}>;
49
72
  finalizedFeatureData: any;
50
73
  } & import("mobx-state-tree")._NotCustomized>;
51
74
  export type VariantFeatureWidgetStateModel = ReturnType<typeof stateModelFactory>;
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pm: PluginManager) => void;
3
- export default _default;
2
+ export default function VariantTrackF(pm: PluginManager): void;
@@ -1,7 +1,7 @@
1
1
  import TrackType from '@jbrowse/core/pluggableElementTypes/TrackType';
2
2
  import { createBaseTrackModel } from '@jbrowse/core/pluggableElementTypes/models';
3
3
  import configSchemaF from './configSchema';
4
- export default (pm) => {
4
+ export default function VariantTrackF(pm) {
5
5
  pm.addTrackType(() => {
6
6
  const configSchema = configSchemaF(pm);
7
7
  return new TrackType({
@@ -11,4 +11,4 @@ export default (pm) => {
11
11
  stateModel: createBaseTrackModel(pm, 'VariantTrack', configSchema),
12
12
  });
13
13
  });
14
- };
14
+ }
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function VcfAdapterF(pluginManager: PluginManager): void;
@@ -1,10 +1,10 @@
1
1
  import AdapterType from '@jbrowse/core/pluggableElementTypes/AdapterType';
2
2
  import configSchema from './configSchema';
3
- export default (pluginManager) => {
3
+ export default function VcfAdapterF(pluginManager) {
4
4
  pluginManager.addAdapterType(() => new AdapterType({
5
5
  name: 'VcfAdapter',
6
6
  displayName: 'VCF adapter',
7
7
  configSchema,
8
8
  getAdapterClass: () => import('./VcfAdapter').then(r => r.default),
9
9
  }));
10
- };
10
+ }
@@ -3,5 +3,5 @@ import VCF from '@gmod/vcf';
3
3
  * Get a sequence ontology (SO) term that describes the variant type
4
4
  */
5
5
  export declare function getSOTermAndDescription(ref: string, alt: string[], parser: VCF): string[];
6
- export declare function getSOAndDescFromAltDefs(ref: string, alt: string, parser: VCF): string[];
6
+ export declare function getSOAndDescFromAltDefs(alt: string, parser: VCF): string[];
7
7
  export declare function getSOAndDescByExamination(ref: string, alt: string): string[];
@@ -22,7 +22,7 @@ export function getSOTermAndDescription(ref, alt, parser) {
22
22
  const soTerms = new Set();
23
23
  let descriptions = new Set();
24
24
  alt.forEach(a => {
25
- let [soTerm, description] = getSOAndDescFromAltDefs(ref, a, parser);
25
+ let [soTerm, description] = getSOAndDescFromAltDefs(a, parser);
26
26
  if (!soTerm) {
27
27
  ;
28
28
  [soTerm, description] = getSOAndDescByExamination(ref, a);
@@ -54,7 +54,7 @@ export function getSOTermAndDescription(ref, alt, parser) {
54
54
  }
55
55
  return [];
56
56
  }
57
- export function getSOAndDescFromAltDefs(ref, alt, parser) {
57
+ export function getSOAndDescFromAltDefs(alt, parser) {
58
58
  if (typeof alt === 'string' && !alt.startsWith('<')) {
59
59
  return [];
60
60
  }
@@ -70,7 +70,7 @@ export function getSOAndDescFromAltDefs(ref, alt, parser) {
70
70
  // try to look for a definition for a parent term if we can
71
71
  const modAlt = alt.split(':');
72
72
  if (modAlt.length > 1) {
73
- return getSOAndDescFromAltDefs(ref, `<${modAlt.slice(0, -1).join(':')}>`, parser);
73
+ return getSOAndDescFromAltDefs(`<${modAlt.slice(0, -1).join(':')}>`, parser);
74
74
  }
75
75
  // no parent
76
76
  return [];
@@ -3,7 +3,7 @@ import { NoAssemblyRegion } from '@jbrowse/core/util/types';
3
3
  import { Feature } from '@jbrowse/core/util';
4
4
  import { TabixIndexedFile } from '@gmod/tabix';
5
5
  import VcfParser from '@gmod/vcf';
6
- export default class extends BaseFeatureDataAdapter {
6
+ export default class VcfTabixAdapter extends BaseFeatureDataAdapter {
7
7
  private configured?;
8
8
  private configurePre;
9
9
  protected configure(): Promise<{
@@ -5,7 +5,7 @@ import { TabixIndexedFile } from '@gmod/tabix';
5
5
  import VcfParser from '@gmod/vcf';
6
6
  // local
7
7
  import VcfFeature from '../VcfFeature';
8
- export default class extends BaseFeatureDataAdapter {
8
+ export default class VcfTabixAdapter extends BaseFeatureDataAdapter {
9
9
  async configurePre() {
10
10
  const pm = this.pluginManager;
11
11
  const vcfGzLocation = this.getConf('vcfGzLocation');
@@ -1,4 +1,3 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
2
  export { default as configSchema } from './configSchema';
3
- declare const _default: (pluginManager: PluginManager) => void;
4
- export default _default;
3
+ export default function VcfTabixAdapterF(pluginManager: PluginManager): void;
@@ -1,11 +1,11 @@
1
1
  import AdapterType from '@jbrowse/core/pluggableElementTypes/AdapterType';
2
2
  import configSchema from './configSchema';
3
3
  export { default as configSchema } from './configSchema';
4
- export default (pluginManager) => {
4
+ export default function VcfTabixAdapterF(pluginManager) {
5
5
  pluginManager.addAdapterType(() => new AdapterType({
6
6
  name: 'VcfTabixAdapter',
7
7
  displayName: 'VCF tabix adapter',
8
8
  configSchema,
9
9
  getAdapterClass: () => import('./VcfTabixAdapter').then(r => r.default),
10
10
  }));
11
- };
11
+ }
@@ -1,3 +1,2 @@
1
1
  import PluginManager from '@jbrowse/core/PluginManager';
2
- declare const _default: (pluginManager: PluginManager) => void;
3
- export default _default;
2
+ export default function ExtensionPointsF(pluginManager: PluginManager): void;
@@ -1,5 +1,5 @@
1
1
  import { makeIndex, makeIndexType, getFileName, } from '@jbrowse/core/util/tracks';
2
- export default (pluginManager) => {
2
+ export default function ExtensionPointsF(pluginManager) {
3
3
  pluginManager.addToExtensionPoint('Core-guessAdapterForLocation', (adapterGuesser) => {
4
4
  return (file, index, adapterHint) => {
5
5
  const regexGuess = /\.vcf\.b?gz$/i;
@@ -45,4 +45,4 @@ export default (pluginManager) => {
45
45
  return adapterGuesser(file, index, adapterHint);
46
46
  };
47
47
  });
48
- };
48
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jbrowse/plugin-variants",
3
- "version": "2.10.3",
3
+ "version": "2.11.1",
4
4
  "description": "JBrowse 2 variant adapters, tracks, etc.",
5
5
  "keywords": [
6
6
  "jbrowse",
@@ -41,7 +41,7 @@
41
41
  "@gmod/tabix": "^1.5.6",
42
42
  "@gmod/vcf": "^5.0.9",
43
43
  "@mui/icons-material": "^5.0.2",
44
- "@mui/x-data-grid": "^6.0.1",
44
+ "@mui/x-data-grid": "^7.0.0",
45
45
  "generic-filehandle": "^3.0.0"
46
46
  },
47
47
  "peerDependencies": {
@@ -63,5 +63,5 @@
63
63
  "distModule": "esm/index.js",
64
64
  "srcModule": "src/index.ts",
65
65
  "module": "esm/index.js",
66
- "gitHead": "c8fc800cd17decd72b2e971c7a6add3b95214e72"
66
+ "gitHead": "11b28d66d782eb06f92ccb993108bb6c3c82819e"
67
67
  }