Skip to content

Commit

Permalink
Update read-only annotation modal
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt Stone committed Nov 7, 2022
1 parent 5e49114 commit 2a025f2
Showing 1 changed file with 17 additions and 11 deletions.
28 changes: 17 additions & 11 deletions src/app/src/components/DrawTools/AnnotationModals.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ function ReadOnlyAnnotationModal({ annotation, onClose }) {
headerText='View comment'
isOpen={!!annotation}
onClose={onClose}
body={<Textarea value={annotation?.comment} disabled />}
body={<Text color='gray.900'>{annotation?.comment}</Text>}
/>
);
}
Expand Down Expand Up @@ -180,19 +180,25 @@ function AnnotationModalBase({
variant='secondary'
onClick={onClose}
disabled={isLoading}
width={onSubmit ? undefined : '100%'}
>
Back
</Button>
<Spacer />
<Button
variant='cta'
onClick={() => {
onSubmit();
}}
isLoading={isLoading}
>
{ctaLabel}
</Button>

{onSubmit && (
<>
<Spacer />
<Button
variant='cta'
onClick={() => {
onSubmit();
}}
isLoading={isLoading}
>
{ctaLabel}
</Button>
</>
)}
</Flex>
</ModalFooter>
</ModalContent>
Expand Down

0 comments on commit 2a025f2

Please sign in to comment.