diff --git a/plugins/alignments/src/LinearPileupDisplay/components/GroupByDialog.tsx b/plugins/alignments/src/LinearPileupDisplay/components/GroupByDialog.tsx index 9dab5b1515..f3164853c4 100644 --- a/plugins/alignments/src/LinearPileupDisplay/components/GroupByDialog.tsx +++ b/plugins/alignments/src/LinearPileupDisplay/components/GroupByDialog.tsx @@ -142,7 +142,7 @@ const GroupByTagDialog = observer(function (props: { session.addTrackConf({ ...trackConf, trackId: t1, - name: `${trackConf.name} (-)`, + name: `${trackConf.name} (${tag}:${tagValue})`, displays: [ { displayId: `${t1}-LinearAlignmentsDisplay`, diff --git a/plugins/alignments/src/PileupRenderer/renderMismatches.ts b/plugins/alignments/src/PileupRenderer/renderMismatches.ts index cf50165dec..2192575cbb 100644 --- a/plugins/alignments/src/PileupRenderer/renderMismatches.ts +++ b/plugins/alignments/src/PileupRenderer/renderMismatches.ts @@ -118,11 +118,11 @@ export function renderMismatches({ } else if (mismatch.type === 'insertion' && drawIndels) { const pos = leftPx + extraHorizontallyFlippedOffset const len = +mismatch.base || mismatch.length - const insW = Math.max(0, Math.min(1.2, 1 / bpPerPx)) + const insW = Math.max(minSubfeatureWidth, Math.min(1.2, 1 / bpPerPx)) if (len < 10) { fillRect(ctx, pos, topPx, insW, heightPx, canvasWidth, 'purple') if (1 / bpPerPx >= charWidth && heightPx >= heightLim) { - const l = pos - insW + const l = Math.round(pos - insW) fillRect(ctx, l, topPx, insW * 3, 1, canvasWidth) fillRect(ctx, l, topPx + heightPx - 1, insW * 3, 1, canvasWidth) ctx.fillText(`(${mismatch.base})`, pos + 3, topPx + heightPx) diff --git a/products/jbrowse-web/src/tests/__image_snapshots__/breakpoint_split_view_snapshot.svg b/products/jbrowse-web/src/tests/__image_snapshots__/breakpoint_split_view_snapshot.svg index 1251122a05..e5aa980029 100644 --- a/products/jbrowse-web/src/tests/__image_snapshots__/breakpoint_split_view_snapshot.svg +++ b/products/jbrowse-web/src/tests/__image_snapshots__/breakpoint_split_view_snapshot.svg @@ -1 +1 @@ -hg19chr3186,698,000186,700,000chr3186,702,000186,704,0000077HG002.hs37d5.11kbpbsv.BND.3:186700648-6:56758392T[6:56758392[pbsv.BND.3:186700648-6:56758392T[6:56758392[HG002.hs37d5.bndshg19chr656,754,00056,756,00056,758,000chr656,758,00056,760,00056,762,0000088HG002.hs37d5.11kbpbsv.BND.6:56758392-3:186700648]3:186700648]Tpbsv.BND.6:56758392-3:186700648]3:186700648]THG002.hs37d5.bnds \ No newline at end of file +hg19chr3186,698,000186,700,000chr3186,702,000186,704,0000077HG002.hs37d5.11kbpbsv.BND.3:186700648-6:56758392T[6:56758392[pbsv.BND.3:186700648-6:56758392T[6:56758392[HG002.hs37d5.bndshg19chr656,754,00056,756,00056,758,000chr656,758,00056,760,00056,762,0000088HG002.hs37d5.11kbpbsv.BND.6:56758392-3:186700648]3:186700648]Tpbsv.BND.6:56758392-3:186700648]3:186700648]THG002.hs37d5.bnds \ No newline at end of file diff --git a/products/jbrowse-web/src/tests/__snapshots__/ExportSvgBreakpointSplitView.test.tsx.snap b/products/jbrowse-web/src/tests/__snapshots__/ExportSvgBreakpointSplitView.test.tsx.snap index 009242c013..7b02ffb109 100644 --- a/products/jbrowse-web/src/tests/__snapshots__/ExportSvgBreakpointSplitView.test.tsx.snap +++ b/products/jbrowse-web/src/tests/__snapshots__/ExportSvgBreakpointSplitView.test.tsx.snap @@ -1,3 +1,3 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`export svg of breakpoint split view 1`] = `"hg19chr3186,698,000186,700,000chr3186,702,000186,704,0000077HG002.hs37d5.11kbpbsv.BND.3:186700648-6:56758392T[6:56758392[pbsv.BND.3:186700648-6:56758392T[6:56758392[HG002.hs37d5.bndshg19chr656,754,00056,756,00056,758,000chr656,758,00056,760,00056,762,0000088HG002.hs37d5.11kbpbsv.BND.6:56758392-3:186700648]3:186700648]Tpbsv.BND.6:56758392-3:186700648]3:186700648]THG002.hs37d5.bnds"`; +exports[`export svg of breakpoint split view 1`] = `"hg19chr3186,698,000186,700,000chr3186,702,000186,704,0000077HG002.hs37d5.11kbpbsv.BND.3:186700648-6:56758392T[6:56758392[pbsv.BND.3:186700648-6:56758392T[6:56758392[HG002.hs37d5.bndshg19chr656,754,00056,756,00056,758,000chr656,758,00056,760,00056,762,0000088HG002.hs37d5.11kbpbsv.BND.6:56758392-3:186700648]3:186700648]Tpbsv.BND.6:56758392-3:186700648]3:186700648]THG002.hs37d5.bnds"`;