@jbrowse/bandage-core 9.0.0 → 9.1.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.
Files changed (41) hide show
  1. package/dist/bubbles/bubbleHalos.js +9 -5
  2. package/dist/bubbles/bubbleLine.js +3 -1
  3. package/dist/bubbles/bubblesFromGraph.js +8 -4
  4. package/dist/bubbles/classifyBubble.js +2 -2
  5. package/dist/bubbles/superbubbles.js +21 -0
  6. package/dist/chunks/{chunk-ISEI2FH3.js → chunk-2AWUWGAD.js} +10 -4
  7. package/dist/chunks/{chunk-YOYLCLIG.js → chunk-2ZT7ZF7A.js} +6 -2
  8. package/dist/chunks/{chunk-TLQ7F2ZT.js → chunk-3TGUKQWQ.js} +4 -4
  9. package/dist/chunks/{chunk-LLP3FXPM.js → chunk-75HR3756.js} +24 -7
  10. package/dist/chunks/chunk-FUVI4WQP.js +273 -0
  11. package/dist/chunks/{chunk-MFKORG3F.js → chunk-FX4RDMDN.js} +5 -1
  12. package/dist/chunks/{chunk-4S47XRYA.js → chunk-GOZYKNQ2.js} +16 -11
  13. package/dist/chunks/{chunk-TL4B342F.js → chunk-MXDQGA7A.js} +1 -1
  14. package/dist/chunks/{chunk-SKKYLBRA.js → chunk-RRZMMYBG.js} +1 -1
  15. package/dist/chunks/{chunk-AMS3MAFP.js → chunk-UID3QBWH.js} +1 -1
  16. package/dist/chunks/{chunk-2WNBVB55.js → chunk-WBCOREDZ.js} +121 -74
  17. package/dist/chunks/{chunk-WOO7QYKB.js → chunk-XKWD2RY3.js} +8 -2
  18. package/dist/chunks/{chunk-6VBDMZBZ.js → chunk-XLCTQHBE.js} +1 -1
  19. package/dist/cli/figure.js +6 -6
  20. package/dist/figure.js +6 -6
  21. package/dist/figureSettings.js +3 -3
  22. package/dist/index.js +34 -24
  23. package/dist/layout/forceCache.js +3 -3
  24. package/dist/pipeline.js +2 -2
  25. package/dist/renderer/Canvas2DRenderer.js +1 -1
  26. package/dist/renderer/recordingCanvas.js +12 -1
  27. package/dist/tubeMap/connectors.js +3 -1
  28. package/dist/tubeMap/draw.js +3 -1
  29. package/dist/types/bubbles/bubbleHalos.d.ts +2 -0
  30. package/dist/types/bubbles/bubbleLine.d.ts +3 -0
  31. package/dist/types/bubbles/bubblesFromGraph.d.ts +12 -2
  32. package/dist/types/bubbles/superbubbles.d.ts +5 -0
  33. package/dist/types/index.d.ts +3 -2
  34. package/dist/types/renderer/Canvas2DRenderer.d.ts +6 -3
  35. package/dist/types/tubeMap/connectors.d.ts +1 -0
  36. package/dist/types/tubeMap/draw.d.ts +1 -0
  37. package/dist/types/version.d.ts +1 -1
  38. package/dist/version.js +1 -1
  39. package/dist/viewport.js +3 -3
  40. package/package.json +1 -1
  41. package/dist/chunks/{chunk-5OIVTEF7.js → chunk-OOXIMURX.js} +3 -3
@@ -12,6 +12,8 @@ export interface MinigraphBubble {
12
12
  longestAllele: string | undefined;
13
13
  partial?: boolean;
14
14
  routes?: BubbleRoute[];
15
+ key?: string;
16
+ offReference?: true;
15
17
  }
16
18
  export interface BubbleRoute {
17
19
  steps: string[];
@@ -20,6 +22,7 @@ export interface BubbleRoute {
20
22
  }
21
23
  export declare function parseBubbleLine(line: string): MinigraphBubble;
22
24
  export declare function sameBubble(a: MinigraphBubble, b: MinigraphBubble): boolean;
25
+ export declare function bubbleKey(b: MinigraphBubble): string;
23
26
  export declare function bubbleLabel(bubble: MinigraphBubble): string;
24
27
  export declare const SATURATED_PATH_COUNT = 2147483647;
25
28
  export declare function bubbleDescription(bubble: MinigraphBubble): string;
@@ -1,3 +1,13 @@
1
- import type { MinigraphBubble } from './bubbleLine.js';
2
- import type { Graph } from '../types.js';
1
+ import type { BubbleRoute, MinigraphBubble } from './bubbleLine.js';
2
+ import type { Graph, GraphNode } from '../types.js';
3
+ export interface Routes {
4
+ min: number;
5
+ max: number;
6
+ n: number;
7
+ }
3
8
  export declare function bubblesFromGraph(graph: Graph): MinigraphBubble[];
9
+ export declare function walkIndexOf(graph: Graph): Map<string, number>[] | undefined;
10
+ export declare function walkRoutes(graph: Graph, byId: Map<string, GraphNode>, walkIndex: Map<string, number>[], startId: string, endId: string): (Routes & {
11
+ left: number;
12
+ routes: BubbleRoute[];
13
+ }) | undefined;
@@ -0,0 +1,5 @@
1
+ import type { MinigraphBubble } from './bubbleLine.js';
2
+ import type { Graph } from '../types.js';
3
+ export declare const MAX_SUPERBUBBLES = 50;
4
+ export declare function superbubblesFromGraph(graph: Graph, span?: MinigraphBubble): MinigraphBubble[];
5
+ export declare function graphBubbles(graph: Graph, span?: MinigraphBubble): MinigraphBubble[];
@@ -31,7 +31,7 @@ export type { AxisScale } from './util/geometry.js';
31
31
  export { wheelZoomFactor } from './util/wheelZoom.js';
32
32
  export { REFERENCE_STRIP_ZONE_PX, drawReferenceStrip, referenceStripBlocks, stripBlockAt, } from './referenceStrip.js';
33
33
  export type { StripBlock } from './referenceStrip.js';
34
- export { drawTubeMap, tubeMapMismatchAt, tubeMapPicture, tubeMapTrackAt, } from './tubeMap/draw.js';
34
+ export { drawTubeMap, drawTubeMapHighlight, tubeMapMismatchAt, tubeMapPicture, tubeMapTrackAt, } from './tubeMap/draw.js';
35
35
  export type { TubeMapFrame, TubeMapPicture } from './tubeMap/draw.js';
36
36
  export { tubeMapNodeColors } from './tubeMap/nodeColors.js';
37
37
  export { referenceKnots, warpX } from './tubeMap/warp.js';
@@ -41,7 +41,7 @@ export { drawTubeMapRuler, referenceBoxes, rulerBoxes, tubeX, } from './tubeMap/
41
41
  export type { Box as TubeMapBox, ReferenceBox, ReferenceBoxes, } from './tubeMap/axis.js';
42
42
  export { drawTubeMapGenes, tubeMapGenes } from './tubeMap/genes.js';
43
43
  export type { TubeMapGene } from './tubeMap/genes.js';
44
- export { connectorAt, drawTubeMapConnectors, tubeMapConnectors, } from './tubeMap/connectors.js';
44
+ export { connectorAt, drawLitConnector, drawTubeMapConnectors, tubeMapConnectors, } from './tubeMap/connectors.js';
45
45
  export type { Connector } from './tubeMap/connectors.js';
46
46
  export type { TubeMapColumn, TubeMapDrawing } from './layout/tubeMapLayout.js';
47
47
  export { deletionDrawing, deletionEdges } from './deletionEdges.js';
@@ -62,6 +62,7 @@ export { WALK_FIELDS, WALK_SCHEMES, encodingStops, encodingSwatchCss, resolveEnc
62
62
  export type { WalkEncoding, WalkField, WalkLayer, WalkScheme, } from './walkEncoding.js';
63
63
  export { pathColorsLegible, pathLegend, walkLabelsOf } from './pathColors.js';
64
64
  export { bubblesFromGraph } from './bubbles/bubblesFromGraph.js';
65
+ export { graphBubbles, superbubblesFromGraph } from './bubbles/superbubbles.js';
65
66
  export { bubbleHalos } from './bubbles/bubbleHalos.js';
66
67
  export type { BubbleHalo } from './bubbles/bubbleHalos.js';
67
68
  export { BUBBLE_KIND_COLORS, BUBBLE_KIND_NAMES, bubbleSegmentIds, classifyBubble, } from './bubbles/classifyBubble.js';
@@ -16,9 +16,12 @@ export declare class Canvas2DRenderer implements Renderer {
16
16
  setEdgeHighlight(edgeIndex: number | null, factor: number): void;
17
17
  updateTransform(transform: TransformUniform): void;
18
18
  render(clearColor: [number, number, number, number]): void;
19
- private renderEdges;
20
- private renderNodes;
21
- private renderArrows;
19
+ renderHighlights(): void;
20
+ private edgeRun;
21
+ private liftedStrokes;
22
+ private strokeCurves;
23
+ private strokeNodes;
24
+ private fillArrows;
22
25
  dispose(): void;
23
26
  }
24
27
  export declare function arrowheadOutline(a: Arrowhead, t: TransformUniform): readonly [{
@@ -12,3 +12,4 @@ export declare function drawTubeMapConnectors(ctx: CanvasRenderingContext2D, con
12
12
  highlightNode?: string | null;
13
13
  darkMode?: boolean;
14
14
  }): void;
15
+ export declare function drawLitConnector(ctx: CanvasRenderingContext2D, connectors: readonly Connector[], bottom: number, node: string | null | undefined): void;
@@ -69,6 +69,7 @@ export interface TubeMapFrame extends TubeMapTransform {
69
69
  nodeColors?: ReadonlyMap<string, string>;
70
70
  }
71
71
  export declare function drawTubeMap(ctx: CanvasRenderingContext2D, picture: TubeMapPicture, frame: TubeMapFrame): void;
72
+ export declare function drawTubeMapHighlight(ctx: CanvasRenderingContext2D, picture: TubeMapPicture, frame: TubeMapFrame): void;
72
73
  export declare function mismatchesLegible(yScale: number): boolean;
73
74
  export declare function mismatchOnScreen(m: TubeMapMismatch, { x, width }: Pick<TubeMapFrame, 'x' | 'width'>): boolean;
74
75
  export declare function tubeMapTrackAt(picture: TubeMapPicture, { x, y }: TubeMapTransform, sx: number, sy: number): number | undefined;
@@ -1 +1 @@
1
- export declare const version = "9.0.0";
1
+ export declare const version = "9.1.0";
package/dist/version.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  version
3
- } from "./chunks/chunk-AMS3MAFP.js";
3
+ } from "./chunks/chunk-UID3QBWH.js";
4
4
  export {
5
5
  version
6
6
  };
package/dist/viewport.js CHANGED
@@ -5,14 +5,14 @@ import {
5
5
  screenToLayout,
6
6
  viewportOf,
7
7
  zoomAbout
8
- } from "./chunks/chunk-TL4B342F.js";
9
- import "./chunks/chunk-5OIVTEF7.js";
8
+ } from "./chunks/chunk-MXDQGA7A.js";
9
+ import "./chunks/chunk-OOXIMURX.js";
10
10
  import "./chunks/chunk-PUG7LXDF.js";
11
11
  import "./chunks/chunk-IGVV37VI.js";
12
+ import "./chunks/chunk-OA7RIMZ2.js";
12
13
  import "./chunks/chunk-OCMBULGN.js";
13
14
  import "./chunks/chunk-QYBZZI5H.js";
14
15
  import "./chunks/chunk-CDLPYR5O.js";
15
- import "./chunks/chunk-OA7RIMZ2.js";
16
16
  import "./chunks/chunk-ES2N6V56.js";
17
17
  import "./chunks/chunk-ST2IBUAN.js";
18
18
  import "./chunks/chunk-BPLIXMH7.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jbrowse/bandage-core",
3
- "version": "9.0.0",
3
+ "version": "9.1.0",
4
4
  "description": "Pangenome graph layout and drawing with no host: GFA in, the Bandage force-directed engine and reference-anchored layouts, a Canvas2D renderer, hit testing and labels out",
5
5
  "license": "GPL-3.0-or-later",
6
6
  "repository": {
@@ -4,15 +4,15 @@ import {
4
4
  import {
5
5
  seededNodes
6
6
  } from "./chunk-IGVV37VI.js";
7
+ import {
8
+ graphFromTables
9
+ } from "./chunk-OA7RIMZ2.js";
7
10
  import {
8
11
  convertGFAToGraph
9
12
  } from "./chunk-OCMBULGN.js";
10
13
  import {
11
14
  parseGFA
12
15
  } from "./chunk-CDLPYR5O.js";
13
- import {
14
- graphFromTables
15
- } from "./chunk-OA7RIMZ2.js";
16
16
  import {
17
17
  anchorGraph
18
18
  } from "./chunk-ST2IBUAN.js";