Skip to content

Commit

Permalink
clean up unused const
Browse files Browse the repository at this point in the history
  • Loading branch information
jerader committed Nov 21, 2024
1 parent 75416f1 commit a38726e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 31 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
StyledText,
Tag,
} from '@opentrons/components'
import { compactPreIngreds, formatVolume } from './utils'
import { formatVolume } from './utils'
import type { AdditionalEquipmentName } from '@opentrons/step-generation'

import type { SubstepIdentifier, SubstepWellData } from '../../../../steplist'
Expand Down Expand Up @@ -44,14 +44,9 @@ function SubstepComponent(props: SubstepProps): JSX.Element {
'protocol_steps',
'shared',
])
const compactedSourcePreIngreds = source
? compactPreIngreds(source.preIngreds)
: {}

const selectSubstep = propSelectSubstep ?? noop

const ingredIds: string[] = Object.keys(compactedSourcePreIngreds)

const volumeTag = (
<Tag
text={`${formatVolume(volume)} ${t('units.microliter')}`}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,31 +29,6 @@ export const formatPercentage = (part: number, total: number): string => {
return `${round((part / total) * 100, PERCENTAGE_DECIMALS_ALLOWED)}%`
}

export const compactPreIngreds = (
preIngreds: WellIngredientVolumeData
): Partial<
| {
[ingredId: string]:
| {
volume: number
}
| undefined
}
| {
[well: string]:
| {
[ingredId: string]: {
volume: number
}
}
| undefined
}
> => {
return omitBy(preIngreds, ingred => {
return typeof ingred?.volume === 'number' && ingred.volume <= 0
})
}

export const getMetaSelectedSteps = (
multiSelectItemIds: StepIdType[] | null,
stepId: StepIdType,
Expand Down

0 comments on commit a38726e

Please sign in to comment.