Skip to content

Commit

Permalink
Typ file
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdcolin committed Jan 24, 2025
1 parent df71139 commit 83d1196
Show file tree
Hide file tree
Showing 17 changed files with 37 additions and 37 deletions.
2 changes: 1 addition & 1 deletion plugins/variants/src/MultiLinearVariantDisplay/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { isAlive, types } from 'mobx-state-tree'

import { randomColor } from '../util'

import type { Source } from '../util'
import type { Source } from '../types'
import type PluginManager from '@jbrowse/core/PluginManager'
import type { AnyConfigurationSchemaType } from '@jbrowse/core/configuration'
import type { AnyReactComponentType, Feature } from '@jbrowse/core/util'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { isAlive, types } from 'mobx-state-tree'

import { randomColor } from '../util'

import type { Source } from '../util'
import type { Source } from '../types'
import type { AnyConfigurationSchemaType } from '@jbrowse/core/configuration'
import type { Feature } from '@jbrowse/core/util'
import type { ExportSvgDisplayOptions } from '@jbrowse/plugin-linear-genome-view'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { SimpleFeature, renderToAbstractCanvas } from '@jbrowse/core/util'

import { getCol } from '../util'

import type { Source } from '../util'
import type { Source } from '../types'
import type { RenderArgsDeserialized as BoxRenderArgsDeserialized } from '@jbrowse/core/pluggableElementTypes/renderers/BoxRendererType'
import type { Feature } from '@jbrowse/core/util'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { featureSpanPx, renderToAbstractCanvas } from '@jbrowse/core/util'
// locals
import { getCol } from '../util'

import type { Source } from '../util'
import type { Source } from '../types'
import type { RenderArgsDeserialized as FeatureRenderArgsDeserialized } from '@jbrowse/core/pluggableElementTypes/renderers/FeatureRendererType'
import type { Feature } from '@jbrowse/core/util'
import type { ThemeOptions } from '@mui/material'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { useRef } from 'react'
import { PrerenderedCanvas } from '@jbrowse/core/ui'
import { observer } from 'mobx-react'

import type { Source } from '../util'
import type { Source } from '../types'
import type { Feature } from '@jbrowse/core/util'
import type { Region } from '@jbrowse/core/util/types'

Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/MultiVariantBaseRenderer.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import FeatureRendererType from '@jbrowse/core/pluggableElementTypes/renderers/FeatureRendererType'
import { renderToAbstractCanvas } from '@jbrowse/core/util'

import type { Source } from './util'
import type { Source } from './types'
import type { RenderArgsDeserialized as FeatureRenderArgsDeserialized } from '@jbrowse/core/pluggableElementTypes/renderers/FeatureRendererType'
import type { Feature } from '@jbrowse/core/util'
import type { ThemeOptions } from '@mui/material'
Expand Down
22 changes: 1 addition & 21 deletions plugins/variants/src/StructuralVariantChordRenderer/Chord.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,7 @@ import { observer } from 'mobx-react'

import type { AnyConfigurationModel } from '@jbrowse/core/configuration'
import type { Feature } from '@jbrowse/core/util'

export interface Region {
end: number
start: number
refName: string
elided?: false
}

export interface ElidedRegion {
elided: true
regions: Region[]
}

export type AnyRegion = Region | ElidedRegion

export interface Block {
flipped: boolean
bpPerRadian: number
startRadians: number
region: AnyRegion
}
import type { AnyRegion, Block } from './types'

function bpToRadians(block: Block, pos: number) {
const blockStart = block.region.elided ? 0 : block.region.start
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { observer } from 'mobx-react'

import Chord from './Chord'

import type { AnyRegion, Block } from './Chord'
import type { AnyRegion, Block } from './types'
import type { AnyConfigurationModel } from '@jbrowse/core/configuration'
import type { Feature } from '@jbrowse/core/util'

Expand Down
20 changes: 20 additions & 0 deletions plugins/variants/src/StructuralVariantChordRenderer/types.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
export interface Region {
end: number
start: number
refName: string
elided?: false
}

export interface ElidedRegion {
elided: true
regions: Region[]
}

export type AnyRegion = Region | ElidedRegion

export interface Block {
flipped: boolean
bpPerRadian: number
startRadians: number
region: AnyRegion
}
3 changes: 1 addition & 2 deletions plugins/variants/src/shared/BulkEditPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ import { useState } from 'react'
import { ErrorMessage } from '@jbrowse/core/ui'
import { Button, TextField, Typography } from '@mui/material'
import { makeStyles } from 'tss-react/mui'

import { type Source } from '../util'
import { Source } from '../types'

const useStyles = makeStyles()({
textAreaFont: {
Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/shared/ClusterDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { saveAs } from 'file-saver'
import { isAlive } from 'mobx-state-tree'
import { makeStyles } from 'tss-react/mui'

import type { Source } from '../util'
import type { Source } from '../types'
import type { AnyConfigurationModel } from '@jbrowse/core/configuration'
import type { LinearGenomeViewModel } from '@jbrowse/plugin-linear-genome-view'

Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/shared/ColorLegend.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { observer } from 'mobx-react'

import RectBg from './RectBg'

import type { Source } from '../util'
import type { Source } from '../types'

const ColorLegend = observer(function ({
model,
Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/shared/LegendBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { observer } from 'mobx-react'

import ColorLegend from './ColorLegend'

import type { Source } from '../util'
import type { Source } from '../types'

interface ReducedModel {
scrollTop: number
Expand Down
3 changes: 2 additions & 1 deletion plugins/variants/src/shared/RowPalettizer.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { set1 } from '@jbrowse/core/ui/colors'
import { Button } from '@mui/material'

import { type Source, randomColor } from '../util'
import { randomColor } from '../util'
import { Source } from '../types'

export default function RowPalettizer({
setCurrLayout,
Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/shared/SetColorDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ import { Button, DialogActions, DialogContent } from '@mui/material'
import { makeStyles } from 'tss-react/mui'

import SourcesGrid from './SourcesGrid'
import { type Source } from '../util'
import BulkEditPanel from './BulkEditPanel'
import RowPalettizer from './RowPalettizer'
import { Source } from '../types'

const useStyles = makeStyles()({
content: {
Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/shared/SourcesGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import { makeStyles } from 'tss-react/mui'
// locals
import { moveDown, moveUp } from './util'

import type { Source } from '../util'
import type { Source } from '../types'
import type { GridColDef } from '@mui/x-data-grid'

// icons
Expand Down
2 changes: 1 addition & 1 deletion plugins/variants/src/shared/Tooltip.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { observer } from 'mobx-react'
import Tooltip from '../Tooltip'

import type { TooltipContentsComponent } from '../Tooltip'
import type { Source } from '../util'
import type { Source } from '../types'
import type { Feature } from '@jbrowse/core/util'

const en = (n: number) => n.toLocaleString('en-US')
Expand Down

0 comments on commit 83d1196

Please sign in to comment.