linting and some type fixes

This commit is contained in:
caranicas 2022-09-20 09:50:50 -04:00
parent e8544be30a
commit 63b658ac50
9 changed files with 33 additions and 36 deletions

View File

@ -61,14 +61,14 @@ export type ImageOutput = {
data: string;
path_abs: string | null;
seed: number;
}
};
export type ImageReturnType = {
output: ImageOutput[];
request: {};
status: string,
session_id: string,
}
status: string;
session_id: string;
};
export const MakeImageKey = "MakeImage";
export const doMakeImage = async (reqBody: ImageRequest) => {

View File

@ -35,7 +35,6 @@ export default function BasicCreation() {
<SeedImage></SeedImage>
<ActiveTags></ActiveTags>
</div>
);
}

View File

@ -24,7 +24,6 @@ export default function MakeButton() {
const setRequestOption = useImageCreate((state) => state.setRequestOptions);
const makeImages = () => {
// potentially update the seed
if (isRandomSeed) {
// update the seed for the next time we click the button
@ -78,7 +77,6 @@ export default function MakeButton() {
seed,
});
});
};
return (

View File

@ -1,6 +1,5 @@
import React, { useState } from "react";
// @ts-expect-error
import { PanelBox } from "../../../../styles/shared.css.ts";

View File

@ -1,6 +1,5 @@
import { style } from "@vanilla-extract/css";
export const displayPanel = style({
height: "100%",
display: "flex",
@ -15,5 +14,4 @@ export const displayContainer = style({
alignItems: "center",
});
export const previousImages = style({
});
export const previousImages = style({});

View File

@ -5,7 +5,12 @@ import { ImageRequest, useImageCreate } from "../../../stores/imageCreateStore";
import { useQuery, useQueryClient } from "@tanstack/react-query";
import { doMakeImage, MakeImageKey, ImageReturnType, ImageOutput } from "../../../api";
import {
doMakeImage,
MakeImageKey,
ImageReturnType,
ImageOutput,
} from "../../../api";
import AudioDing from "./audioDing";
@ -93,7 +98,6 @@ export default function DisplayPanel() {
// this is where we generate the list of completed images
useEffect(() => {
const completedQueries = completedIds.map((id) => {
const imageData = queryClient.getQueryData([MakeImageKey, id]);
return imageData;

View File

@ -14,7 +14,6 @@ interface ImageQueueState {
clearCachedIds: () => void;
}
export const useImageQueue = create<ImageQueueState>((set, get) => ({
images: [],
completedImageIds: [],

File diff suppressed because one or more lines are too long