@jbrowse/plugin-wiggle 4.1.3 → 4.1.4

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 (122) hide show
  1. package/esm/BigWigAdapter/BigWigAdapter.d.ts +14 -0
  2. package/esm/BigWigAdapter/BigWigAdapter.js +6 -0
  3. package/esm/BigWigAdapter/configSchema.d.ts +2 -2
  4. package/esm/DensityRenderer/configSchema.d.ts +2 -2
  5. package/esm/LinePlotRenderer/configSchema.d.ts +3 -3
  6. package/esm/LinearWiggleDisplay/configSchema.d.ts +6 -6
  7. package/esm/LinearWiggleDisplay/model.d.ts +24 -8
  8. package/esm/MultiDensityRenderer/configSchema.d.ts +2 -2
  9. package/esm/MultiLineRenderer/configSchema.d.ts +3 -3
  10. package/esm/MultiLinearWiggleDisplay/components/IndividualScaleBars.js +3 -2
  11. package/esm/MultiLinearWiggleDisplay/components/MultiWiggleColorLegend.d.ts +10 -0
  12. package/esm/MultiLinearWiggleDisplay/components/MultiWiggleColorLegend.js +29 -0
  13. package/esm/MultiLinearWiggleDisplay/components/MultiWiggleLegendBar.d.ts +7 -0
  14. package/esm/MultiLinearWiggleDisplay/components/MultiWiggleLegendBar.js +28 -0
  15. package/esm/MultiLinearWiggleDisplay/components/MultiWiggleLegendBarWrapper.d.ts +7 -0
  16. package/esm/MultiLinearWiggleDisplay/components/MultiWiggleLegendBarWrapper.js +18 -0
  17. package/esm/MultiLinearWiggleDisplay/components/RectBg.js +3 -1
  18. package/esm/MultiLinearWiggleDisplay/components/SvgTree.d.ts +5 -0
  19. package/esm/MultiLinearWiggleDisplay/components/SvgTree.js +19 -0
  20. package/esm/MultiLinearWiggleDisplay/components/TreeSidebar.d.ts +5 -0
  21. package/esm/MultiLinearWiggleDisplay/components/TreeSidebar.js +165 -0
  22. package/esm/MultiLinearWiggleDisplay/components/WiggleClusterDialog/WiggleClusterDialogAuto.js +2 -1
  23. package/esm/MultiLinearWiggleDisplay/components/WiggleClusterDialog/types.d.ts +2 -1
  24. package/esm/MultiLinearWiggleDisplay/components/WiggleDisplayComponent.js +5 -2
  25. package/esm/MultiLinearWiggleDisplay/components/constants.d.ts +1 -0
  26. package/esm/MultiLinearWiggleDisplay/components/constants.js +1 -0
  27. package/esm/MultiLinearWiggleDisplay/components/treeTypes.d.ts +39 -0
  28. package/esm/MultiLinearWiggleDisplay/components/treeTypes.js +1 -0
  29. package/esm/MultiLinearWiggleDisplay/configSchema.d.ts +6 -6
  30. package/esm/MultiLinearWiggleDisplay/makeSidebarSvg.d.ts +9 -0
  31. package/esm/MultiLinearWiggleDisplay/makeSidebarSvg.js +13 -0
  32. package/esm/MultiLinearWiggleDisplay/model.d.ts +146 -25
  33. package/esm/MultiLinearWiggleDisplay/model.js +137 -5
  34. package/esm/MultiLinearWiggleDisplay/renderSvg.js +3 -1
  35. package/esm/MultiLinearWiggleDisplay/treeDrawingAutorun.d.ts +17 -0
  36. package/esm/MultiLinearWiggleDisplay/treeDrawingAutorun.js +77 -0
  37. package/esm/MultiQuantitativeTrack/configSchema.d.ts +8 -8
  38. package/esm/MultiRowLineRenderer/configSchema.d.ts +3 -3
  39. package/esm/MultiRowXYPlotRenderer/configSchema.d.ts +3 -3
  40. package/esm/MultiWiggleAdapter/MultiWiggleAdapter.d.ts +3 -0
  41. package/esm/MultiWiggleAdapter/MultiWiggleAdapter.js +5 -1
  42. package/esm/MultiWiggleAdapter/configSchema.d.ts +2 -2
  43. package/esm/MultiXYPlotRenderer/configSchema.d.ts +3 -3
  44. package/esm/QuantitativeTrack/configSchema.d.ts +8 -8
  45. package/esm/WiggleRPC/MultiWiggleClusterScoreMatrix.d.ts +4 -1
  46. package/esm/WiggleRPC/executeClusterScoreMatrix.d.ts +4 -1
  47. package/esm/WiggleRPC/executeClusterScoreMatrix.js +8 -2
  48. package/esm/XYPlotRenderer/configSchema.d.ts +3 -3
  49. package/esm/configSchema.d.ts +2 -2
  50. package/esm/d3-hierarchy2/accessors.d.ts +2 -0
  51. package/esm/d3-hierarchy2/accessors.js +8 -0
  52. package/esm/d3-hierarchy2/array.d.ts +2 -0
  53. package/esm/d3-hierarchy2/array.js +15 -0
  54. package/esm/d3-hierarchy2/cluster.d.ts +8 -0
  55. package/esm/d3-hierarchy2/cluster.js +63 -0
  56. package/esm/d3-hierarchy2/constant.d.ts +2 -0
  57. package/esm/d3-hierarchy2/constant.js +8 -0
  58. package/esm/d3-hierarchy2/hierarchy/ancestors.d.ts +1 -0
  59. package/esm/d3-hierarchy2/hierarchy/ancestors.js +7 -0
  60. package/esm/d3-hierarchy2/hierarchy/count.d.ts +1 -0
  61. package/esm/d3-hierarchy2/hierarchy/count.js +12 -0
  62. package/esm/d3-hierarchy2/hierarchy/descendants.d.ts +1 -0
  63. package/esm/d3-hierarchy2/hierarchy/descendants.js +3 -0
  64. package/esm/d3-hierarchy2/hierarchy/each.d.ts +1 -0
  65. package/esm/d3-hierarchy2/hierarchy/each.js +7 -0
  66. package/esm/d3-hierarchy2/hierarchy/eachAfter.d.ts +1 -0
  67. package/esm/d3-hierarchy2/hierarchy/eachAfter.js +15 -0
  68. package/esm/d3-hierarchy2/hierarchy/eachBefore.d.ts +1 -0
  69. package/esm/d3-hierarchy2/hierarchy/eachBefore.js +12 -0
  70. package/esm/d3-hierarchy2/hierarchy/find.d.ts +1 -0
  71. package/esm/d3-hierarchy2/hierarchy/find.js +8 -0
  72. package/esm/d3-hierarchy2/hierarchy/index.d.ts +3 -0
  73. package/esm/d3-hierarchy2/hierarchy/index.js +78 -0
  74. package/esm/d3-hierarchy2/hierarchy/iterator.d.ts +1 -0
  75. package/esm/d3-hierarchy2/hierarchy/iterator.js +14 -0
  76. package/esm/d3-hierarchy2/hierarchy/leaves.d.ts +1 -0
  77. package/esm/d3-hierarchy2/hierarchy/leaves.js +9 -0
  78. package/esm/d3-hierarchy2/hierarchy/links.d.ts +1 -0
  79. package/esm/d3-hierarchy2/hierarchy/links.js +9 -0
  80. package/esm/d3-hierarchy2/hierarchy/path.d.ts +1 -0
  81. package/esm/d3-hierarchy2/hierarchy/path.js +26 -0
  82. package/esm/d3-hierarchy2/hierarchy/sort.d.ts +1 -0
  83. package/esm/d3-hierarchy2/hierarchy/sort.js +7 -0
  84. package/esm/d3-hierarchy2/hierarchy/sum.d.ts +1 -0
  85. package/esm/d3-hierarchy2/hierarchy/sum.js +8 -0
  86. package/esm/d3-hierarchy2/index.d.ts +15 -0
  87. package/esm/d3-hierarchy2/index.js +15 -0
  88. package/esm/d3-hierarchy2/lcg.d.ts +1 -0
  89. package/esm/d3-hierarchy2/lcg.js +7 -0
  90. package/esm/d3-hierarchy2/pack/enclose.d.ts +10 -0
  91. package/esm/d3-hierarchy2/pack/enclose.js +84 -0
  92. package/esm/d3-hierarchy2/pack/index.d.ts +7 -0
  93. package/esm/d3-hierarchy2/pack/index.js +68 -0
  94. package/esm/d3-hierarchy2/pack/siblings.d.ts +2 -0
  95. package/esm/d3-hierarchy2/pack/siblings.js +94 -0
  96. package/esm/d3-hierarchy2/partition.d.ts +6 -0
  97. package/esm/d3-hierarchy2/partition.js +42 -0
  98. package/esm/d3-hierarchy2/stratify.d.ts +9 -0
  99. package/esm/d3-hierarchy2/stratify.js +115 -0
  100. package/esm/d3-hierarchy2/tree.d.ts +8 -0
  101. package/esm/d3-hierarchy2/tree.js +153 -0
  102. package/esm/d3-hierarchy2/treemap/binary.d.ts +1 -0
  103. package/esm/d3-hierarchy2/treemap/binary.js +36 -0
  104. package/esm/d3-hierarchy2/treemap/dice.d.ts +1 -0
  105. package/esm/d3-hierarchy2/treemap/dice.js +7 -0
  106. package/esm/d3-hierarchy2/treemap/index.d.ts +17 -0
  107. package/esm/d3-hierarchy2/treemap/index.js +72 -0
  108. package/esm/d3-hierarchy2/treemap/resquarify.d.ts +5 -0
  109. package/esm/d3-hierarchy2/treemap/resquarify.js +28 -0
  110. package/esm/d3-hierarchy2/treemap/round.d.ts +1 -0
  111. package/esm/d3-hierarchy2/treemap/round.js +6 -0
  112. package/esm/d3-hierarchy2/treemap/slice.d.ts +1 -0
  113. package/esm/d3-hierarchy2/treemap/slice.js +7 -0
  114. package/esm/d3-hierarchy2/treemap/sliceDice.d.ts +1 -0
  115. package/esm/d3-hierarchy2/treemap/sliceDice.js +5 -0
  116. package/esm/d3-hierarchy2/treemap/squarify.d.ts +11 -0
  117. package/esm/d3-hierarchy2/treemap/squarify.js +46 -0
  118. package/esm/index.d.ts +3 -3
  119. package/esm/shared/SharedWiggleConfigSchema.d.ts +3 -3
  120. package/esm/shared/SharedWiggleMixin.d.ts +28 -10
  121. package/esm/shared/SharedWiggleMixin.js +13 -3
  122. package/package.json +7 -7
@@ -29,6 +29,20 @@ export default class BigWigAdapter extends BaseFeatureDataAdapter {
29
29
  featureCount: number;
30
30
  basesCovered: number;
31
31
  featureDensity: number;
32
+ scoreMeanMin?: undefined;
33
+ scoreMeanMax?: undefined;
34
+ } | {
35
+ scoreMin: number;
36
+ scoreMax: number;
37
+ scoreMeanMin: number;
38
+ scoreMeanMax: number;
39
+ scoreSum: number;
40
+ scoreSumSquares: number;
41
+ scoreMean: number;
42
+ scoreStdDev: number;
43
+ featureCount: number;
44
+ basesCovered: number;
45
+ featureDensity: number;
32
46
  }>;
33
47
  getMultiRegionFeatureDensityStats(_regions: Region[]): Promise<{
34
48
  featureDensity: number;
@@ -22,6 +22,8 @@ function computeStatsFromView(view, targetStart, targetEnd) {
22
22
  }
23
23
  let scoreMin = Number.MAX_VALUE;
24
24
  let scoreMax = Number.MIN_VALUE;
25
+ let scoreMeanMin = Number.MAX_VALUE;
26
+ let scoreMeanMax = Number.MIN_VALUE;
25
27
  let scoreSum = 0;
26
28
  let scoreSumSquares = 0;
27
29
  let featureCount = 0;
@@ -36,6 +38,8 @@ function computeStatsFromView(view, targetStart, targetEnd) {
36
38
  const max = view.maxScore(i) ?? score;
37
39
  scoreMin = Math.min(scoreMin, min);
38
40
  scoreMax = Math.max(scoreMax, max);
41
+ scoreMeanMin = Math.min(scoreMeanMin, score);
42
+ scoreMeanMax = Math.max(scoreMeanMax, score);
39
43
  scoreSum += score;
40
44
  scoreSumSquares += score * score;
41
45
  featureCount++;
@@ -58,6 +62,8 @@ function computeStatsFromView(view, targetStart, targetEnd) {
58
62
  return {
59
63
  scoreMin,
60
64
  scoreMax,
65
+ scoreMeanMin,
66
+ scoreMeanMax,
61
67
  scoreSum,
62
68
  scoreSumSquares,
63
69
  scoreMean,
@@ -1,4 +1,4 @@
1
- declare const BigWigAdapter: import("node_modules/@jbrowse/core/src/configuration/configurationSchema").ConfigurationSchemaType<{
1
+ declare const BigWigAdapter: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
2
2
  bigWigLocation: {
3
3
  type: string;
4
4
  defaultValue: {
@@ -16,5 +16,5 @@ declare const BigWigAdapter: import("node_modules/@jbrowse/core/src/configuratio
16
16
  defaultValue: number;
17
17
  description: string;
18
18
  };
19
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>;
19
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>;
20
20
  export default BigWigAdapter;
@@ -1,4 +1,4 @@
1
- declare const configSchema: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{}, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
1
+ declare const configSchema: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{}, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
2
2
  color: {
3
3
  type: string;
4
4
  description: string;
@@ -33,5 +33,5 @@ declare const configSchema: import("node_modules/@jbrowse/core/src/configuration
33
33
  defaultValue: number;
34
34
  description: string;
35
35
  };
36
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
36
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
37
37
  export default configSchema;
@@ -1,10 +1,10 @@
1
- declare const configSchema: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
1
+ declare const configSchema: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
2
2
  displayCrossHatches: {
3
3
  type: string;
4
4
  description: string;
5
5
  defaultValue: boolean;
6
6
  };
7
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
7
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
8
8
  color: {
9
9
  type: string;
10
10
  description: string;
@@ -39,5 +39,5 @@ declare const configSchema: import("node_modules/@jbrowse/core/src/configuration
39
39
  defaultValue: number;
40
40
  description: string;
41
41
  };
42
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
42
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
43
43
  export default configSchema;
@@ -1,16 +1,16 @@
1
1
  import type PluginManager from '@jbrowse/core/PluginManager';
2
- export default function WiggleConfigFactory(pluginManager: PluginManager): import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
2
+ export default function WiggleConfigFactory(pluginManager: PluginManager): import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
3
3
  defaultRendering: {
4
4
  type: string;
5
5
  model: import("@jbrowse/mobx-state-tree").ISimpleType<string>;
6
6
  defaultValue: string;
7
7
  };
8
- renderers: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
8
+ renderers: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
9
9
  DensityRenderer: import("@jbrowse/core/configuration").AnyConfigurationSchemaType;
10
10
  XYPlotRenderer: import("@jbrowse/core/configuration").AnyConfigurationSchemaType;
11
11
  LinePlotRenderer: import("@jbrowse/core/configuration").AnyConfigurationSchemaType;
12
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, undefined>>;
13
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
12
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>;
13
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
14
14
  autoscale: {
15
15
  type: string;
16
16
  defaultValue: string;
@@ -48,7 +48,7 @@ export default function WiggleConfigFactory(pluginManager: PluginManager): impor
48
48
  description: string;
49
49
  defaultValue: boolean;
50
50
  };
51
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
51
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
52
52
  maxFeatureScreenDensity: {
53
53
  type: string;
54
54
  description: string;
@@ -75,4 +75,4 @@ export default function WiggleConfigFactory(pluginManager: PluginManager): impor
75
75
  description: string;
76
76
  defaultValue: never[];
77
77
  };
78
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, "displayId">>, undefined>>, undefined>>;
78
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, "displayId">>, undefined>>, undefined>>;
@@ -37,6 +37,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
37
37
  statusMessage?: string;
38
38
  reactElement?: React.ReactElement;
39
39
  isRenderingPending?: boolean;
40
+ displayHeight?: number;
40
41
  };
41
42
  }) => import("react/jsx-runtime").JSX.Element;
42
43
  renderProps: any;
@@ -55,10 +56,11 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
55
56
  beforeDestroy(): void;
56
57
  } & {
57
58
  readonly statusMessage: any;
59
+ readonly displayHeight: number | undefined;
58
60
  } & {
59
61
  afterAttach(): void;
60
62
  }, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>;
61
- configuration: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
63
+ configuration: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
62
64
  maxFeatureScreenDensity: {
63
65
  type: string;
64
66
  description: string;
@@ -85,7 +87,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
85
87
  description: string;
86
88
  defaultValue: never[];
87
89
  };
88
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, "displayId">>;
90
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, "displayId">>;
89
91
  showLegend: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>>;
90
92
  showTooltips: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>>;
91
93
  } & {
@@ -397,6 +399,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
397
399
  statusMessage?: string;
398
400
  reactElement?: React.ReactElement;
399
401
  isRenderingPending?: boolean;
402
+ displayHeight?: number;
400
403
  };
401
404
  }) => import("react/jsx-runtime").JSX.Element;
402
405
  renderProps: any;
@@ -415,6 +418,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
415
418
  beforeDestroy(): void;
416
419
  } & {
417
420
  readonly statusMessage: any;
421
+ readonly displayHeight: number | undefined;
418
422
  } & {
419
423
  afterAttach(): void;
420
424
  }, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>> & import("@jbrowse/mobx-state-tree").IStateTreeNode<import("@jbrowse/mobx-state-tree").IMapType<import("@jbrowse/mobx-state-tree").IModelType<{
@@ -441,6 +445,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
441
445
  statusMessage?: string;
442
446
  reactElement?: React.ReactElement;
443
447
  isRenderingPending?: boolean;
448
+ displayHeight?: number;
444
449
  };
445
450
  }) => import("react/jsx-runtime").JSX.Element;
446
451
  renderProps: any;
@@ -459,6 +464,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
459
464
  beforeDestroy(): void;
460
465
  } & {
461
466
  readonly statusMessage: any;
467
+ readonly displayHeight: number | undefined;
462
468
  } & {
463
469
  afterAttach(): void;
464
470
  }, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>>;
@@ -472,7 +478,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
472
478
  [x: string]: any;
473
479
  } & import("@jbrowse/mobx-state-tree/dist/internal").NonEmptyObject & any & import("@jbrowse/mobx-state-tree").IStateTreeNode<AnyConfigurationSchemaType>);
474
480
  } & import("@jbrowse/mobx-state-tree").IStateTreeNode<AnyConfigurationSchemaType>);
475
- } & import("@jbrowse/mobx-state-tree").IStateTreeNode<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
481
+ } & import("@jbrowse/mobx-state-tree").IStateTreeNode<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
476
482
  maxFeatureScreenDensity: {
477
483
  type: string;
478
484
  description: string;
@@ -499,7 +505,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
499
505
  description: string;
500
506
  defaultValue: never[];
501
507
  };
502
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, "displayId">>>;
508
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, "displayId">>>;
503
509
  showLegend: boolean | undefined;
504
510
  showTooltips: boolean | undefined;
505
511
  } & import("@jbrowse/mobx-state-tree/dist/internal").NonEmptyObject & {
@@ -789,6 +795,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
789
795
  statusMessage?: string;
790
796
  reactElement?: React.ReactElement;
791
797
  isRenderingPending?: boolean;
798
+ displayHeight?: number;
792
799
  };
793
800
  }) => import("react/jsx-runtime").JSX.Element;
794
801
  renderProps: any;
@@ -807,10 +814,11 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
807
814
  beforeDestroy(): void;
808
815
  } & {
809
816
  readonly statusMessage: any;
817
+ readonly displayHeight: number | undefined;
810
818
  } & {
811
819
  afterAttach(): void;
812
820
  }, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>;
813
- configuration: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
821
+ configuration: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
814
822
  maxFeatureScreenDensity: {
815
823
  type: string;
816
824
  description: string;
@@ -837,7 +845,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
837
845
  description: string;
838
846
  defaultValue: never[];
839
847
  };
840
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, "displayId">>;
848
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, "displayId">>;
841
849
  showLegend: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>>;
842
850
  showTooltips: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>>;
843
851
  }, {
@@ -1108,6 +1116,8 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
1108
1116
  currStatsBpPerPx: number;
1109
1117
  scoreMin: number;
1110
1118
  scoreMax: number;
1119
+ scoreMeanMin?: number;
1120
+ scoreMeanMax?: number;
1111
1121
  statsRegion?: string;
1112
1122
  } | undefined;
1113
1123
  statsFetchInProgress: undefined | import("@jbrowse/core/util").StopToken;
@@ -1116,6 +1126,8 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
1116
1126
  currStatsBpPerPx: number;
1117
1127
  scoreMin: number;
1118
1128
  scoreMax: number;
1129
+ scoreMeanMin?: number;
1130
+ scoreMeanMax?: number;
1119
1131
  }, statsRegion?: string): void;
1120
1132
  setColor(color?: string): void;
1121
1133
  setPosColor(color?: string): void;
@@ -1164,6 +1176,8 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
1164
1176
  currStatsBpPerPx: number;
1165
1177
  scoreMin: number;
1166
1178
  scoreMax: number;
1179
+ scoreMeanMin?: number;
1180
+ scoreMeanMax?: number;
1167
1181
  statsRegion?: string;
1168
1182
  } | undefined;
1169
1183
  autoscaleType: string;
@@ -1357,6 +1371,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
1357
1371
  statusMessage?: string;
1358
1372
  reactElement?: React.ReactElement;
1359
1373
  isRenderingPending?: boolean;
1374
+ displayHeight?: number;
1360
1375
  };
1361
1376
  }) => import("react/jsx-runtime").JSX.Element;
1362
1377
  renderProps: any;
@@ -1375,10 +1390,11 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
1375
1390
  beforeDestroy(): void;
1376
1391
  } & {
1377
1392
  readonly statusMessage: any;
1393
+ readonly displayHeight: number | undefined;
1378
1394
  } & {
1379
1395
  afterAttach(): void;
1380
1396
  }, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>;
1381
- configuration: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
1397
+ configuration: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
1382
1398
  maxFeatureScreenDensity: {
1383
1399
  type: string;
1384
1400
  description: string;
@@ -1405,7 +1421,7 @@ declare function stateModelFactory(pluginManager: PluginManager, configSchema: A
1405
1421
  description: string;
1406
1422
  defaultValue: never[];
1407
1423
  };
1408
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, "displayId">>;
1424
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, "displayId">>;
1409
1425
  showLegend: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>>;
1410
1426
  showTooltips: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>>;
1411
1427
  } & {
@@ -1,4 +1,4 @@
1
- declare const configSchema: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{}, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
1
+ declare const configSchema: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{}, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
2
2
  color: {
3
3
  type: string;
4
4
  description: string;
@@ -33,5 +33,5 @@ declare const configSchema: import("node_modules/@jbrowse/core/src/configuration
33
33
  defaultValue: number;
34
34
  description: string;
35
35
  };
36
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
36
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
37
37
  export default configSchema;
@@ -1,4 +1,4 @@
1
- declare const configSchema: import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
1
+ declare const configSchema: import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
2
2
  displayCrossHatches: {
3
3
  type: string;
4
4
  description: string;
@@ -10,7 +10,7 @@ declare const configSchema: import("node_modules/@jbrowse/core/src/configuration
10
10
  description: string;
11
11
  defaultValue: string;
12
12
  };
13
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaType<{
13
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaType<{
14
14
  color: {
15
15
  type: string;
16
16
  description: string;
@@ -45,5 +45,5 @@ declare const configSchema: import("node_modules/@jbrowse/core/src/configuration
45
45
  defaultValue: number;
46
46
  description: string;
47
47
  };
48
- }, import("node_modules/@jbrowse/core/src/configuration/configurationSchema.ts").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
48
+ }, import("@jbrowse/core/configuration/configurationSchema").ConfigurationSchemaOptions<undefined, undefined>>, undefined>>;
49
49
  export default configSchema;
@@ -4,7 +4,8 @@ import ColorLegend from "./ColorLegend.js";
4
4
  import ScoreLegend from "./ScoreLegend.js";
5
5
  import YScaleBar from "../../shared/YScaleBar.js";
6
6
  const IndividualScaleBars = observer(function IndividualScaleBars({ model, orientation, exportSVG, }) {
7
- const { sources, rowHeight, rowHeightTooSmallForScalebar, needsCustomLegend, ticks, } = model;
8
- return sources?.length ? (_jsxs(_Fragment, { children: [_jsx(ColorLegend, { exportSVG: exportSVG, model: model, rowHeight: model.rowHeight }), rowHeightTooSmallForScalebar || needsCustomLegend ? (_jsx(ScoreLegend, { model: model })) : (sources.map((_source, idx) => (_jsx("g", { transform: `translate(0 ${rowHeight * idx})`, children: _jsx(YScaleBar, { model: model, orientation: orientation }) }, `${JSON.stringify(ticks)}-${idx}`))))] })) : null;
7
+ const { sources, rowHeight, rowHeightTooSmallForScalebar, needsCustomLegend, ticks, hierarchy, showTree, } = model;
8
+ const treeIsShowing = hierarchy && showTree;
9
+ return sources?.length ? (_jsxs(_Fragment, { children: [treeIsShowing ? null : (_jsx(ColorLegend, { exportSVG: exportSVG, model: model, rowHeight: model.rowHeight })), rowHeightTooSmallForScalebar || needsCustomLegend ? (_jsx(ScoreLegend, { model: model })) : (sources.map((_source, idx) => (_jsx("g", { transform: `translate(0 ${rowHeight * idx})`, children: _jsx(YScaleBar, { model: model, orientation: orientation }) }, `${JSON.stringify(ticks)}-${idx}`))))] })) : null;
9
10
  });
10
11
  export default IndividualScaleBars;
@@ -0,0 +1,10 @@
1
+ import type { Source } from '../../util.ts';
2
+ declare const MultiWiggleColorLegend: ({ model, labelWidth, }: {
3
+ model: {
4
+ canDisplayLegendLabels: boolean;
5
+ rowHeight: number;
6
+ sources?: Source[];
7
+ };
8
+ labelWidth: number;
9
+ }) => import("react/jsx-runtime").JSX.Element | null;
10
+ export default MultiWiggleColorLegend;
@@ -0,0 +1,29 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useMemo } from 'react';
3
+ import { getFillProps } from '@jbrowse/core/util';
4
+ import { useTheme } from '@mui/material';
5
+ import { observer } from 'mobx-react';
6
+ import RectBg from "./RectBg.js";
7
+ const LegendItem = function ({ source, idx, rowHeight, }) {
8
+ const { color } = source;
9
+ const colorBoxWidth = 15;
10
+ return color ? (_jsx(RectBg, { y: idx * rowHeight, x: 0, width: colorBoxWidth + 0.5, height: rowHeight + 0.5, color: color })) : null;
11
+ };
12
+ const LegendItemText = function ({ source, idx, rowHeight, textFillProps, }) {
13
+ const { color, name } = source;
14
+ const svgFontSize = Math.min(rowHeight, 12);
15
+ const colorBoxWidth = 15;
16
+ return (_jsx("text", { y: (idx + 0.5) * rowHeight, x: color ? colorBoxWidth + 2 : 0, fontSize: svgFontSize, dominantBaseline: "central", ...textFillProps, children: name }));
17
+ };
18
+ const MultiWiggleColorLegend = observer(function MultiWiggleColorLegend({ model, labelWidth, }) {
19
+ const { canDisplayLegendLabels, rowHeight, sources } = model;
20
+ const colorBoxWidth = 15;
21
+ const theme = useTheme();
22
+ const hasColors = useMemo(() => sources?.some(s => s.color) ?? false, [sources]);
23
+ const legendWidth = labelWidth + (hasColors ? colorBoxWidth + 5 : 0);
24
+ const textFillProps = useMemo(() => getFillProps(theme.palette.text.primary), [theme.palette.text.primary]);
25
+ return sources ? (_jsxs(_Fragment, { children: [canDisplayLegendLabels ? (_jsx(RectBg, { y: 0, x: 0, width: legendWidth, height: (sources.length + 0.25) * rowHeight })) : null, sources.map((source, idx) => (_jsx(LegendItem, { source: source, idx: idx, rowHeight: rowHeight }, `${source.name}-${idx}`))), canDisplayLegendLabels
26
+ ? sources.map((source, idx) => (_jsx(LegendItemText, { source: source, idx: idx, rowHeight: rowHeight, textFillProps: textFillProps }, `${source.name}-text-${idx}`)))
27
+ : null] })) : null;
28
+ });
29
+ export default MultiWiggleColorLegend;
@@ -0,0 +1,7 @@
1
+ import type { LegendBarModel } from './treeTypes.ts';
2
+ declare const MultiWiggleLegendBar: (props: {
3
+ model: LegendBarModel;
4
+ orientation?: string;
5
+ exportSVG?: boolean;
6
+ }) => import("react/jsx-runtime").JSX.Element | null;
7
+ export default MultiWiggleLegendBar;
@@ -0,0 +1,28 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { useMemo } from 'react';
3
+ import { measureText } from '@jbrowse/core/util';
4
+ import { observer } from 'mobx-react';
5
+ import MultiWiggleColorLegend from "./MultiWiggleColorLegend.js";
6
+ import MultiWiggleLegendBarWrapper from "./MultiWiggleLegendBarWrapper.js";
7
+ const MultiWiggleLegendBar = observer(function MultiWiggleLegendBar(props) {
8
+ const { model } = props;
9
+ const { canDisplayLegendLabels, rowHeight, sources } = model;
10
+ const svgFontSize = Math.min(rowHeight, 12);
11
+ const labelWidth = useMemo(() => {
12
+ if (!sources) {
13
+ return 0;
14
+ }
15
+ let maxWidth = 0;
16
+ for (const s of sources) {
17
+ const width = canDisplayLegendLabels
18
+ ? measureText(s.name, svgFontSize) + 10
19
+ : 20;
20
+ if (width > maxWidth) {
21
+ maxWidth = width;
22
+ }
23
+ }
24
+ return maxWidth;
25
+ }, [sources, svgFontSize, canDisplayLegendLabels]);
26
+ return sources ? (_jsx(MultiWiggleLegendBarWrapper, { ...props, children: _jsx(MultiWiggleColorLegend, { model: model, labelWidth: labelWidth }) })) : null;
27
+ });
28
+ export default MultiWiggleLegendBar;
@@ -0,0 +1,7 @@
1
+ import type { LegendBarModel } from './treeTypes.ts';
2
+ declare const MultiWiggleLegendBarWrapper: ({ children, model, exportSVG, }: {
3
+ model: LegendBarModel;
4
+ children: React.ReactNode;
5
+ exportSVG?: boolean;
6
+ }) => import("react/jsx-runtime").JSX.Element;
7
+ export default MultiWiggleLegendBarWrapper;
@@ -0,0 +1,18 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { getContainingView } from '@jbrowse/core/util';
3
+ import { observer } from 'mobx-react';
4
+ const MultiWiggleLegendBarWrapper = observer(function MultiWiggleLegendBarWrapper({ children, model, exportSVG, }) {
5
+ const { id, scrollTop, height, hierarchy, treeAreaWidth, showTree } = model;
6
+ const clipid = `legend-${typeof jest === 'undefined' ? id : 'test'}`;
7
+ const leftOffset = hierarchy && showTree ? treeAreaWidth : 0;
8
+ return exportSVG ? (_jsxs(_Fragment, { children: [_jsx("defs", { children: _jsx("clipPath", { id: clipid, children: _jsx("rect", { x: 0, y: 0, width: 1000, height: height }) }) }), _jsx("g", { clipPath: `url(#${clipid})`, children: _jsx("g", { transform: `translate(0,${-scrollTop})`, children: children }) })] })) : (_jsx("svg", { style: {
9
+ position: 'absolute',
10
+ top: 0,
11
+ left: leftOffset,
12
+ zIndex: 100,
13
+ pointerEvents: 'none',
14
+ height: model.totalHeight,
15
+ width: getContainingView(model).width,
16
+ }, children: children }));
17
+ });
18
+ export default MultiWiggleLegendBarWrapper;
@@ -1,8 +1,10 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { getFillProps } from '@jbrowse/core/util';
3
3
  import { alpha, useTheme } from '@mui/material';
4
+ import { SIDEBAR_BACKGROUND_OPACITY } from "./constants.js";
4
5
  const RectBg = ({ x, y, width, height, color, }) => {
5
6
  const theme = useTheme();
6
- return (_jsx("rect", { pointerEvents: "auto", x: x, y: y, width: width, height: height, ...getFillProps(color || alpha(theme.palette.background.paper, 0.3)) }));
7
+ return (_jsx("rect", { pointerEvents: "auto", x: x, y: y, width: width, height: height, ...getFillProps(color ||
8
+ alpha(theme.palette.background.paper, SIDEBAR_BACKGROUND_OPACITY)) }));
7
9
  };
8
10
  export default RectBg;
@@ -0,0 +1,5 @@
1
+ import type { LegendBarModel } from './treeTypes.ts';
2
+ declare const SvgTree: ({ model, }: {
3
+ model: LegendBarModel;
4
+ }) => import("react/jsx-runtime").JSX.Element[];
5
+ export default SvgTree;
@@ -0,0 +1,19 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { observer } from 'mobx-react';
3
+ const SvgTree = observer(function SvgTree({ model, }) {
4
+ const { treeAreaWidth: _treeAreaWidth, hierarchy } = model;
5
+ const svg = [];
6
+ let idx = 0;
7
+ if (hierarchy) {
8
+ for (const link of hierarchy.links()) {
9
+ const { source, target } = link;
10
+ const sy = source.x;
11
+ const ty = target.x;
12
+ const tx = target.y;
13
+ const sx = source.y;
14
+ svg.push(_jsx("line", { x1: sx, y1: sy, x2: sx, y2: ty, stroke: "black", opacity: "0.4" }, `${sx}-${sy}-${tx}-${ty}-${idx++}`), _jsx("line", { x1: sx, y1: ty, x2: tx, y2: ty, stroke: "black", opacity: "0.4" }, `${sx}-${sy}-${tx}-${ty}-${idx++}`));
15
+ }
16
+ }
17
+ return svg;
18
+ });
19
+ export default SvgTree;
@@ -0,0 +1,5 @@
1
+ import type { TreeSidebarModel } from './treeTypes.ts';
2
+ declare const TreeSidebar: ({ model, }: {
3
+ model: TreeSidebarModel;
4
+ }) => import("react/jsx-runtime").JSX.Element | null;
5
+ export default TreeSidebar;