Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
b-cooper committed Apr 30, 2024
1 parent 9bd6042 commit 0643974
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 10 deletions.
8 changes: 4 additions & 4 deletions app/src/App/hooks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,11 @@ export function useCurrentRunRoute(): string | null {
const currentRunLink = allRuns?.links?.current ?? null
const currentRun =
currentRunLink != null &&
typeof currentRunLink !== 'string' &&
'href' in currentRunLink
typeof currentRunLink !== 'string' &&
'href' in currentRunLink
? allRuns?.data.find(
run => run.id === currentRunLink.href.replace('/runs/', '')
) // trim link path down to only runId
run => run.id === currentRunLink.href.replace('/runs/', '')
) // trim link path down to only runId
: null
const currentRunId = currentRun?.id ?? null
const { data: runRecord } = useNotifyRunQuery(currentRunId, {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,13 @@ interface NoUnconfiguredModulesProps {
robotName: string
}
function NoUnconfiguredModules(props: NoUnconfiguredModulesProps): JSX.Element {
const { moduleDisplayName, displaySlotName, isOnDevice, robotName } = props
const configuredModuleMatches = ['feer']
const {
moduleDisplayName,
configuredModuleMatches,
displaySlotName,
isOnDevice,
robotName,
} = props
const { t } = useTranslation('protocol_setup')
const history = useHistory()
const { closeCurrentRun } = useCloseCurrentRun()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import {
MAGNETIC_BLOCK_FIXTURES,
SINGLE_SLOT_FIXTURES,
THERMOCYCLER_MODULE_TYPE,
FLEX_USB_MODULE_FIXTURES,
} from '@opentrons/shared-data'

import { InstrumentContainer } from '../../atoms/InstrumentContainer'
Expand Down Expand Up @@ -97,10 +98,11 @@ export const RobotConfigurationDetails = (
emptyText
)

// filter out single slot fixtures
// filter out single slot fixtures as they're implicit
// also filter out usb module fixtures as they're handled by required modules
const nonStandardRequiredFixtureDetails = requiredFixtureDetails.filter(
fixture =>
!SINGLE_SLOT_FIXTURES.includes(
![...SINGLE_SLOT_FIXTURES, ...FLEX_USB_MODULE_FIXTURES].includes(
fixture.cutoutFixtureId as SingleSlotCutoutFixtureId
)
)
Expand Down
2 changes: 0 additions & 2 deletions app/src/pages/ProtocolDetails/Hardware.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ import {
getModuleDisplayName,
getModuleType,
getFixtureDisplayName,
STAGING_AREA_SLOT_WITH_MAGNETIC_BLOCK_V1_FIXTURE,
STAGING_AREA_RIGHT_SLOT_FIXTURE,
GRIPPER_V1_2,
} from '@opentrons/shared-data'

Expand Down
8 changes: 8 additions & 0 deletions shared-data/js/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,14 @@ export const MODULE_FIXTURES_BY_MODEL: {
THERMOCYCLER_V2_FRONT_FIXTURE,
],
}

export const FLEX_USB_MODULE_FIXTURES: CutoutFixtureId[] = [
HEATERSHAKER_MODULE_V1_FIXTURE,
TEMPERATURE_MODULE_V2_FIXTURE,
THERMOCYCLER_V2_REAR_FIXTURE,
THERMOCYCLER_V2_FRONT_FIXTURE,
]

export const MAGNETIC_BLOCK_FIXTURES: CutoutFixtureId[] = [
MAGNETIC_BLOCK_V1_FIXTURE,
STAGING_AREA_SLOT_WITH_MAGNETIC_BLOCK_V1_FIXTURE,
Expand Down

0 comments on commit 0643974

Please sign in to comment.