From 010f63a50d3a57f31179fb8b20855540b7c3a978 Mon Sep 17 00:00:00 2001 From: psychedelicious <4822129+psychedelicious@users.noreply.github.com> Date: Thu, 25 May 2023 00:07:17 +1000 Subject: [PATCH] feat(ui): misc tidy --- .../web/src/features/gallery/hooks/useGetImageByName.ts | 2 -- .../features/nodes/util/graphBuilders/buildImageToImageGraph.ts | 1 - .../features/nodes/util/graphBuilders/buildTextToImageGraph.ts | 2 +- invokeai/frontend/web/src/features/nodes/util/parseSchema.ts | 2 +- 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/invokeai/frontend/web/src/features/gallery/hooks/useGetImageByName.ts b/invokeai/frontend/web/src/features/gallery/hooks/useGetImageByName.ts index d15c3fb51f..ad0870e7a4 100644 --- a/invokeai/frontend/web/src/features/gallery/hooks/useGetImageByName.ts +++ b/invokeai/frontend/web/src/features/gallery/hooks/useGetImageByName.ts @@ -13,11 +13,9 @@ const useGetImageByNameSelector = createSelector( const useGetImageByNameAndType = () => { const { allResults, allUploads } = useAppSelector(useGetImageByNameSelector); - return (name: string, type: ImageType) => { if (type === 'results') { const resultImagesResult = allResults[name]; - if (resultImagesResult) { return resultImagesResult; } diff --git a/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildImageToImageGraph.ts b/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildImageToImageGraph.ts index 003069ea89..d9eb80d654 100644 --- a/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildImageToImageGraph.ts +++ b/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildImageToImageGraph.ts @@ -1,4 +1,3 @@ -import { v4 as uuidv4 } from 'uuid'; import { RootState } from 'app/store/store'; import { CompelInvocation, diff --git a/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildTextToImageGraph.ts b/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildTextToImageGraph.ts index 2fc3ea3975..cbe16abe28 100644 --- a/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildTextToImageGraph.ts +++ b/invokeai/frontend/web/src/features/nodes/util/graphBuilders/buildTextToImageGraph.ts @@ -94,6 +94,6 @@ export const buildTextToImageGraph = (state: RootState): Graph => { // Create and add the noise nodes graph = addNoiseNodes(graph, TEXT_TO_LATENTS, state); - console.log(graph); + return graph; }; diff --git a/invokeai/frontend/web/src/features/nodes/util/parseSchema.ts b/invokeai/frontend/web/src/features/nodes/util/parseSchema.ts index 85b187dca4..ddd19b8749 100644 --- a/invokeai/frontend/web/src/features/nodes/util/parseSchema.ts +++ b/invokeai/frontend/web/src/features/nodes/util/parseSchema.ts @@ -13,7 +13,7 @@ import { buildOutputFieldTemplates, } from './fieldTemplateBuilders'; -const invocationDenylist = ['Graph', 'LoadImage']; +const invocationDenylist = ['Graph']; export const parseSchema = (openAPI: OpenAPIV3.Document) => { // filter out non-invocation schemas, plus some tricky invocations for now