Skip to content

Commit

Permalink
Rename dummy to placeholder
Browse files Browse the repository at this point in the history
  • Loading branch information
Eddasol committed Oct 31, 2023
1 parent b4e78cd commit 00bb821
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Button, Card, Dialog, Icon, Typography, DotProgress } from '@equinor/eds-core-react'
import { config } from 'config'
import { tokens } from '@equinor/eds-tokens'
import { Mission, dummyMission } from 'models/Mission'
import { Mission, placeholderMission } from 'models/Mission'
import styled from 'styled-components'
import { useNavigate } from 'react-router-dom'
import { useState } from 'react'
Expand Down Expand Up @@ -74,7 +74,7 @@ export function MissionQueueCard({ order, mission, onDeleteMission }: MissionQue
<Typography variant="body_short_bold">{order}</Typography>
</CircularCard>

{mission === dummyMission ? (
{mission === placeholderMission ? (
<PaddingLeft>
<DotProgress size={48} color="primary" />
</PaddingLeft>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import styled from 'styled-components'
import { MissionQueueCard } from './MissionQueueCard'
import { BackendAPICaller } from 'api/ApiCaller'
import { useEffect, useState } from 'react'
import { Mission, dummyMission } from 'models/Mission'
import { Mission, placeholderMission } from 'models/Mission'
import { EmptyMissionQueuePlaceholder } from './NoMissionPlaceholder'
import { ScheduleMissionDialog } from './ScheduleMissionDialog'
import { Robot } from 'models/Robot'
Expand Down Expand Up @@ -138,9 +138,9 @@ export function MissionQueueView({ refreshInterval }: RefreshProps) {

const loadingQueueDisplay = (
<MissionQueueCard
key={'test'}
key={'placeholder'}
order={missionQueue.length + 1}
mission={dummyMission}
mission={placeholderMission}
onDeleteMission={() => {}}
/>
)
Expand Down
10 changes: 5 additions & 5 deletions frontend/src/models/Mission.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { MapMetadata } from './MapMetadata'
import { Robot, dummyRobot } from './Robot'
import { Robot, placeholderRobot } from './Robot'
import { Task } from './Task'

export enum MissionStatus {
Expand Down Expand Up @@ -41,10 +41,10 @@ export interface Mission {
tasks: Task[]
map?: MapMetadata
}
export const dummyMission: Mission = {
id: 'dummyId',
name: 'dummyMission',
robot: dummyRobot,
export const placeholderMission: Mission = {
id: 'placeholderId',
name: 'placeholderMission',
robot: placeholderRobot,
status: MissionStatus.Pending,
isCompleted: false,
desiredStartTime: new Date(),
Expand Down
10 changes: 5 additions & 5 deletions frontend/src/models/Robot.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Area } from './Area'
import { BatteryStatus } from './Battery'
import { Pose } from './Pose'
import { RobotModel, dummyRobotModel } from './RobotModel'
import { RobotModel, placeholderRobotModel } from './RobotModel'
import { VideoStream } from './VideoStream'

export enum RobotStatus {
Expand Down Expand Up @@ -29,9 +29,9 @@ export interface Robot {
isarUri?: string
currentArea?: Area
}
export const dummyRobot: Robot = {
id: 'dummyRobotId',
model: dummyRobotModel,
currentInstallation: 'DummyInstallation',
export const placeholderRobot: Robot = {
id: 'placeholderRobotId',
model: placeholderRobotModel,
currentInstallation: 'PlaceholderInstallation',
status: RobotStatus.Available,
}
4 changes: 2 additions & 2 deletions frontend/src/models/RobotModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ export interface RobotModel {
upperPressureWarningThreshold: number
lowerPressureWarningThreshold: number
}
export const dummyRobotModel: RobotModel = {
id: 'dummyModelId',
export const placeholderRobotModel: RobotModel = {
id: 'placeholderModelId',
type: RobotType.Robot,
upperPressureWarningThreshold: 100,
lowerPressureWarningThreshold: 10,
Expand Down

0 comments on commit 00bb821

Please sign in to comment.