Skip to content

Commit

Permalink
Use tick labels that correspond to the overview's larger zoom level (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdcolin authored Oct 7, 2022
1 parent 9dea8dc commit 5eaa86a
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import { Typography, useTheme, alpha } from '@mui/material'
import { makeStyles } from 'tss-react/mui'
import { observer } from 'mobx-react'
import { Instance } from 'mobx-state-tree'

import Base1DView, { Base1DViewModel } from '@jbrowse/core/util/Base1DViewModel'
import { getSession, getTickDisplayStr } from '@jbrowse/core/util'
Expand Down Expand Up @@ -79,7 +78,7 @@ const Polygon = observer(
useOffset = true,
}: {
model: LGV
overview: Instance<Base1DViewModel>
overview: Base1DViewModel
useOffset?: boolean
}) => {
const theme = useTheme()
Expand Down Expand Up @@ -305,7 +304,7 @@ const OverviewBox = observer(
overview: Base1DViewModel
}) => {
const { classes, cx } = useStyles()
const { cytobandOffset, bpPerPx, showCytobands } = model
const { cytobandOffset, showCytobands } = model
const { start, end, reversed, refName, assemblyName } = block
const { majorPitch } = chooseGridPitch(scale, 120, 15)
const { assemblyManager } = getSession(model)
Expand Down Expand Up @@ -361,7 +360,7 @@ const OverviewBox = observer(
color: refNameColor,
}}
>
{getTickDisplayStr(tickLabel, bpPerPx)}
{getTickDisplayStr(tickLabel, overview.bpPerPx)}
</Typography>
))
: null}
Expand Down

0 comments on commit 5eaa86a

Please sign in to comment.