Skip to content

Commit

Permalink
Update button colours
Browse files Browse the repository at this point in the history
Update images for readme
  • Loading branch information
ppettitau committed Oct 25, 2024
1 parent eeb426f commit 3b5b2f8
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 14 deletions.
10 changes: 10 additions & 0 deletions frontend/components/dataTable.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import {
ButtonProps,
chakra,
Flex,
IconButton,
Expand Down Expand Up @@ -100,6 +101,11 @@ export const DataTable = (props: DataTableProps) => {
debugTable: false,
});

const paginateButtonsProps: ButtonProps = {
colorScheme: "blue",
variant: "outline",
};

return (
<>
<Table {...tableProps}>
Expand Down Expand Up @@ -183,6 +189,7 @@ export const DataTable = (props: DataTableProps) => {
isDisabled={!table.getCanPreviousPage()}
icon={<ArrowLeftIcon h={3} w={3} />}
mr={2}
{...paginateButtonsProps}
/>
</Tooltip>
<Tooltip label="Previous Page">
Expand All @@ -192,6 +199,7 @@ export const DataTable = (props: DataTableProps) => {
onClick={() => table.previousPage()}
isDisabled={!table.getCanPreviousPage()}
icon={<ChevronLeftIcon h={6} w={6} />}
{...paginateButtonsProps}
/>
</Tooltip>
</Flex>
Expand Down Expand Up @@ -251,6 +259,7 @@ export const DataTable = (props: DataTableProps) => {
onClick={() => table.nextPage()}
disabled={!table.getCanNextPage()}
icon={<ChevronRightIcon h={6} w={6} />}
{...paginateButtonsProps}
/>
</Tooltip>
<Tooltip label="Last Page">
Expand All @@ -261,6 +270,7 @@ export const DataTable = (props: DataTableProps) => {
disabled={!table.getCanNextPage()}
icon={<ArrowRightIcon h={3} w={3} />}
ml={2}
{...paginateButtonsProps}
/>
</Tooltip>
</Flex>
Expand Down
38 changes: 24 additions & 14 deletions frontend/components/download/download.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ import {
HStack,
Menu,
MenuButton,
MenuGroup,
MenuItem,
MenuList,
MenuOptionGroup,
Portal,
} from "@chakra-ui/react";
import { ChevronDownIcon } from "@chakra-ui/icons";
Expand Down Expand Up @@ -67,24 +69,31 @@ export const Download: FunctionComponent<DownloadOptionsProps> = ({
return (
<HStack>
<Menu>
<MenuButton as={Button} rightIcon={<ChevronDownIcon />}>
<MenuButton
variant={"outline"}
colorScheme={"blue"}
as={Button}
rightIcon={<ChevronDownIcon />}
>
Download
</MenuButton>
<Portal>
<MenuList>
<MenuItem
icon={<MdMovie />}
onClick={() =>
downloadFile({
objectKey: mediaKey(transcription),
filename: transcription.metadata.filename,
})
}
>
Media
</MenuItem>
<MenuGroup>
<MenuItem
icon={<MdMovie />}
onClick={() =>
downloadFile({
objectKey: mediaKey(transcription),
filename: transcription.metadata.filename,
})
}
>
Media file
</MenuItem>
</MenuGroup>
{transcription.downloadKey && (
<>
<MenuGroup title={"Transcription formats"}>
<MenuItem
icon={<VscJson />}
onClick={() =>
Expand Down Expand Up @@ -126,7 +135,7 @@ export const Download: FunctionComponent<DownloadOptionsProps> = ({
>
DOCX
</MenuItem>
</>
</MenuGroup>
)}
</MenuList>
</Portal>
Expand All @@ -136,6 +145,7 @@ export const Download: FunctionComponent<DownloadOptionsProps> = ({
onClick={() => loadPlayer()}
variant={"solid"}
leftIcon={<AiOutlinePlaySquare />}
colorScheme={"blue"}
>
Play
</Button>
Expand Down
Binary file removed images/homepage.png
Binary file not shown.
Binary file modified images/player.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed images/transcription.png
Binary file not shown.
Binary file modified images/transcriptions.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 3b5b2f8

Please sign in to comment.