Skip to content

Commit

Permalink
Handle case insensitive UTR
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdcolin committed Feb 20, 2025
1 parent b362a9f commit 93ea45a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { SimpleFeature } from '@jbrowse/core/util'
import { observer } from 'mobx-react'

import Segments from './Segments'
import { layOutFeature, layOutSubfeatures } from './util'
import { isUTR, layOutFeature, layOutSubfeatures } from './util'

import type { ExtraGlyphValidator } from './util'
import type { AnyConfigurationModel } from '@jbrowse/core/configuration'
Expand All @@ -29,12 +29,6 @@ function filterSubpart(feature: Feature, config: AnyConfigurationModel) {
return makeSubpartsFilter('subParts', config)(feature)
}

function isUTR(feature: Feature) {
return /(\bUTR|_UTR|untranslated[_\s]region)\b/.test(
feature.get('type') || '',
)
}

function makeUTRs(parent: Feature, subs: Feature[]) {
// based on Lincoln's UTR-making code in
// Bio::Graphics::Glyph::processed_transcript
Expand Down
2 changes: 1 addition & 1 deletion plugins/svg/src/SvgFeatureRenderer/components/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export function layOutSubfeatures(args: SubfeatureLayOutArgs) {
}

export function isUTR(feature: Feature) {
return /(\bUTR|_UTR|untranslated[_\s]region)\b/.test(
return /(\bUTR|_UTR|untranslated[_\s]region)\b/i.test(
feature.get('type') || '',
)
}

0 comments on commit 93ea45a

Please sign in to comment.