Skip to content

Commit

Permalink
Improve code quality
Browse files Browse the repository at this point in the history
  • Loading branch information
mrica-equinor committed Nov 13, 2023
1 parent cc1ac3a commit f485298
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { useNavigate } from 'react-router-dom'
import { useState } from 'react'
import { useLanguageContext } from 'components/Contexts/LanguageContext'
import { Icons } from 'utils/icons'
import { StyledDialog } from 'components/StyledComponents'
import { StyledDialog } from 'components/Styles/StyledComponents'
import { tokens } from '@equinor/eds-tokens'

interface MissionQueueCardProps {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { useInstallationContext } from 'components/Contexts/InstallationContext'
import { CreateMissionButton } from './CreateMissionButton'
import { Robot } from 'models/Robot'
import { EchoMissionDefinition } from 'models/MissionDefinition'
import { StyledAutoComplete, StyledDialog } from 'components/StyledComponents'
import { StyledAutoComplete, StyledDialog } from 'components/Styles/StyledComponents'

interface IProps {
robotOptions: Array<Robot>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { CondensedMissionDefinition } from 'models/MissionDefinition'
import { BackendAPICaller } from 'api/ApiCaller'
import { Icons } from 'utils/icons'
import { useRobotContext } from 'components/Contexts/RobotContext'
import { StyledAutoComplete, StyledDialog } from 'components/StyledComponents'
import { StyledAutoComplete, StyledDialog } from 'components/Styles/StyledComponents'

interface IProps {
missions: CondensedMissionDefinition[]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,12 +238,10 @@ function MissionDefinitionEditDialog({
{getFormItem()}
<StyledDict.ButtonSection>
<Button onClick={() => closeEditDialog()} variant="outlined" color="primary">
{' '}
{TranslateText('Cancel')}{' '}
{TranslateText('Cancel')}
</Button>
<Button onClick={handleSubmit} variant="contained" color="primary">
{' '}
{TranslateText('Update')}{' '}
{TranslateText('Update')}
</Button>
</StyledDict.ButtonSection>
</StyledDict.FormCard>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ export const StyledDict = {
ButtonSection: styled.div`
display: flex;
margin-left: auto;
margin-right: 0;
gap: 10px;
`,

Expand Down Expand Up @@ -58,21 +57,17 @@ export const StyledDict = {
`,

InspectionFrequencyDiv: styled.div`
> * {
padding: 10px;
}
padding: 10px;
`,

TitleComponent: styled.div`
display: flex;
align-items: center;
height: 37px;
height: 36px;
`,

EditButton: styled(Button)`
padding-left: 5px;
padding-top: 0px;
margin-top: 0px;
`,

Card: styled(Card)`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import { useState, useEffect, useRef } from 'react'
import { BackendAPICaller } from 'api/ApiCaller'
import { Robot } from 'models/Robot'
import { useLanguageContext } from 'components/Contexts/LanguageContext'
import styled from 'styled-components'
import { tokens } from '@equinor/eds-tokens'
import styled from 'styled-components'

interface RobotProps {
robot: Robot
Expand Down

0 comments on commit f485298

Please sign in to comment.