Skip to content

Commit 7f3376c

Browse files
authored
fix(protocol-designer): fix small DQA bugs (#17228)
Fixes 3 small style bugs for 1) copy for importing a protocol on PD landing page, 2) background color of selected off deck location, and 3) height of divider in liquid overflow menu Closes RQA-3646, Closes RQA-3672, Closes RQA-3683
1 parent 784c622 commit 7f3376c

File tree

6 files changed

+8
-7
lines changed

6 files changed

+8
-7
lines changed

protocol-designer/cypress/support/commands.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export const locators = {
5555
import: 'Import',
5656
createNew: 'Create new',
5757
createProtocol: 'Create a protocol',
58-
editProtocol: 'Edit existing protocol',
58+
importProtocol: 'Import existing protocol',
5959
settingsDataTestid: 'SettingsIconButton',
6060
settings: 'Settings',
6161
privacyPolicy: 'a[href="https://opentrons.com/privacy-policy"]',
@@ -103,7 +103,7 @@ Cypress.Commands.add('verifyCreateNewHeader', () => {
103103
Cypress.Commands.add('verifyHomePage', () => {
104104
cy.contains(content.welcome)
105105
cy.contains('button', locators.createProtocol).should('be.visible')
106-
cy.contains('label', locators.editProtocol).should('be.visible')
106+
cy.contains('label', locators.importProtocol).should('be.visible')
107107
cy.getByTestId(locators.settingsDataTestid).should('be.visible')
108108
cy.get(locators.privacyPolicy).should('exist').and('be.visible')
109109
cy.get(locators.eula).should('exist').and('be.visible')

protocol-designer/src/assets/localization/en/shared.json

+1
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
"heatershakermoduletype": "Heater-shaker Module",
3838
"hints": "Hints",
3939
"import": "Import",
40+
"import_existing_protocol": "Import existing protocol",
4041
"incorrect_file_header": "Invalid file type",
4142
"incorrect_file_type_body": "Protocol Designer only accepts JSON protocol files created with Protocol Designer. Upload a valid file to continue.",
4243
"invalid_json_file_body": "This JSON file is either missing required information or contains sections that Protocol Designer cannot read. At this time we do not support JSON files created outside of Protocol Designer.",

protocol-designer/src/pages/Designer/LiquidsOverflowMenu.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ import { useLocation } from 'react-router-dom'
55
import {
66
ALIGN_CENTER,
77
BORDERS,
8-
Box,
98
COLORS,
109
CURSOR_POINTER,
1110
DIRECTION_COLUMN,
11+
Divider,
1212
Flex,
1313
Icon,
1414
LiquidIcon,
@@ -92,7 +92,7 @@ export function LiquidsOverflowMenu(
9292
)
9393
})}
9494
{liquids.length > 0 ? (
95-
<Box width="100%" border={`1px solid ${COLORS.grey20}`} />
95+
<Divider color={COLORS.grey20} marginY="0" />
9696
) : null}
9797
<MenuItem
9898
data-testid="defineLiquid"

protocol-designer/src/pages/Designer/Offdeck/Offdeck.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ export function OffDeck(props: DeckSetupTabType): JSX.Element {
126126
justifyContent={JUSTIFY_CENTER}
127127
alignItems={ALIGN_CENTER}
128128
borderRadius={BORDERS.borderRadius8}
129-
backgroundColor={COLORS.grey20}
129+
backgroundColor={COLORS.white}
130130
>
131131
<Flex
132132
padding={SPACING.spacing60}

protocol-designer/src/pages/Landing/__tests__/Landing.test.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ describe('Landing', () => {
5858
)
5959
fireEvent.click(screen.getByRole('button', { name: 'Create a protocol' }))
6060
expect(vi.mocked(toggleNewProtocolModal)).toHaveBeenCalled()
61-
screen.getByText('Edit existing protocol')
61+
screen.getByText('Import existing protocol')
6262
screen.getByRole('img', { name: 'welcome image' })
6363
})
6464

protocol-designer/src/pages/Landing/index.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ export function Landing(): JSX.Element {
149149
<StyledLabel>
150150
<Flex css={LINK_BUTTON_STYLE}>
151151
<StyledText desktopStyle="bodyLargeRegular">
152-
{t('edit_existing')}
152+
{t('import_existing_protocol')}
153153
</StyledText>
154154
</Flex>
155155
<input type="file" onChange={loadFile} />

0 commit comments

Comments
 (0)