From 9a3a48a1689afa19d6cf06cff2fec645703fd48f Mon Sep 17 00:00:00 2001 From: znaim Date: Tue, 22 Oct 2024 15:40:14 -0400 Subject: [PATCH] added upload input styling for text --- .../localization/en/protocol_generator.json | 1 + .../src/organisms/UpdateProtocol/index.tsx | 42 +++++++++++++++---- 2 files changed, 35 insertions(+), 8 deletions(-) diff --git a/opentrons-ai-client/src/assets/localization/en/protocol_generator.json b/opentrons-ai-client/src/assets/localization/en/protocol_generator.json index 3d43b45f5a4..ad07ea04413 100644 --- a/opentrons-ai-client/src/assets/localization/en/protocol_generator.json +++ b/opentrons-ai-client/src/assets/localization/en/protocol_generator.json @@ -5,6 +5,7 @@ "commands": "Commands: List the protocol's steps, specifying quantities in microliters (uL) and giving exact source and destination locations.", "copy_code": "Copy code", "disclaimer": "OpentronsAI can make mistakes. Review your protocol before running it on an Opentrons robot.", + "drag_and_drop": "Drag and drop or browse your files", "example": "For example prompts, click the buttons in the left panel.", "got_feedback": "Got feedback? We love to hear it.", "key_info": "Here are some key pieces of information to provide in your prompt:", diff --git a/opentrons-ai-client/src/organisms/UpdateProtocol/index.tsx b/opentrons-ai-client/src/organisms/UpdateProtocol/index.tsx index 97030b9dfbb..bad54168130 100644 --- a/opentrons-ai-client/src/organisms/UpdateProtocol/index.tsx +++ b/opentrons-ai-client/src/organisms/UpdateProtocol/index.tsx @@ -1,5 +1,6 @@ import styled from 'styled-components' import { + COLORS, DIRECTION_COLUMN, DIRECTION_ROW, DropdownField, @@ -9,12 +10,13 @@ import { JUSTIFY_END, LargeButton, StyledText, + Link as LinkComponent, } from '@opentrons/components' import { UploadInput } from '../../molecules/UploadInput' import { HeaderWithMeter } from '../../molecules/HeaderWithMeter' import { useState } from 'react' import type { ChangeEvent } from 'react' -import { useTranslation } from 'react-i18next' +import { Trans, useTranslation } from 'react-i18next' const updateOptions = [ { @@ -76,13 +78,37 @@ export function UpdateProtocol(): JSX.Element { {t('update_existing_protocol')} {t('protocol_file')} - + + + + ), + }} + /> + + } + onUpload={function (file: File): unknown { + throw new Error('Function not implemented.') + }} + > + + {t('type_of_update')}