Skip to content

Commit

Permalink
Fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
machado2 committed Jun 28, 2024
1 parent 5a743b7 commit 5d2458f
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 38 deletions.
11 changes: 0 additions & 11 deletions ui/src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,6 @@
text-align: center;
}

.App-logo {
height: 40vmin;
pointer-events: none;
}

@media (prefers-reduced-motion: no-preference) {
.App-logo {
animation: App-logo-spin infinite 20s linear;
}
}

.App-header {
background-color: #282c34;
min-height: 100vh;
Expand Down
1 change: 0 additions & 1 deletion ui/src/components/ImageComparison.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import {
Heading,
Select,
VStack,
Text
} from '@chakra-ui/react';
import ImageById from "./ImageById";
import StylePromptTable from "./StylePromptTable";
Expand Down
5 changes: 0 additions & 5 deletions ui/src/components/LargeImage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,9 @@ import {
ModalOverlay,
ModalContent,
ModalHeader,
ModalFooter,
ModalBody,
ModalCloseButton,
Image,
Button
} from '@chakra-ui/react';

interface Props {
Expand All @@ -26,9 +24,6 @@ const LargeImage: React.FC<Props> = ({
onClose,
prompt_id,
style_id,
handleMouseLeave,
handleMouseEnter,
handleClick
}) => {
const imageUrl = `/image?prompt_id=${prompt_id}&style_id=${style_id}`;

Expand Down
42 changes: 21 additions & 21 deletions ui/src/components/StylePromptTable.tsx
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
import React, {useEffect, useState} from 'react';
import React, {useState} from 'react';
import {
Box,
Table,
Thead,
Tbody,
Tr,
Th,
Td,
useBreakpointValue,
Button,
Center,
Modal,
ModalOverlay,
ModalContent,
ModalHeader,
ModalCloseButton,
ModalBody,
ModalCloseButton,
ModalContent,
ModalFooter,
Button,
ModalHeader,
ModalOverlay,
Spinner,
Table,
Tbody,
Td,
Textarea,
Th,
Thead,
Tr,
useBreakpointValue,
useDisclosure,
Spinner,
Center,
} from '@chakra-ui/react';
import axios from 'axios';
import ImageById from './ImageById';
import { Prompt, Style } from './SimpleTypes';
import {Prompt, Style} from './SimpleTypes';

interface CheckpointPromptTableProps {
prompts: Prompt[];
Expand All @@ -36,8 +36,8 @@ const StylePromptTable: React.FC<CheckpointPromptTableProps> = ({
styles,
handleClick,
}) => {
const boxSize = useBreakpointValue({ base: '90vw', md: 'auto' });
const { isOpen, onOpen, onClose } = useDisclosure();
const boxSize = useBreakpointValue({base: '90vw', md: 'auto'});
const {isOpen, onOpen, onClose} = useDisclosure();
const [modalContent, setModalContent] = useState<string | null>(null);
const [loading, setLoading] = useState<boolean>(false);

Expand Down Expand Up @@ -104,14 +104,14 @@ const StylePromptTable: React.FC<CheckpointPromptTableProps> = ({
</Box>

<Modal isOpen={isOpen} onClose={onClose} size="xl">
<ModalOverlay />
<ModalOverlay/>
<ModalContent>
<ModalHeader>Style Details</ModalHeader>
<ModalCloseButton />
<ModalCloseButton/>
<ModalBody>
{loading ? (
<Center>
<Spinner size="xl" />
<Spinner size="xl"/>
</Center>
) : (
<Textarea
Expand Down

0 comments on commit 5d2458f

Please sign in to comment.