From a000ad75f64dcd5a089c79df1d86c4ecb1716af8 Mon Sep 17 00:00:00 2001 From: psychedelicious <4822129+psychedelicious@users.noreply.github.com> Date: Fri, 23 Aug 2024 17:11:47 +1000 Subject: [PATCH] tidy(ui): regional guidance buttons --- .../RegionalGuidanceAddPromptsIPAdapterButtons.tsx} | 2 +- .../RegionalGuidance/RegionalGuidanceSettings.tsx | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) rename invokeai/frontend/web/src/features/controlLayers/components/{AddPromptButtons.tsx => RegionalGuidance/RegionalGuidanceAddPromptsIPAdapterButtons.tsx} (96%) diff --git a/invokeai/frontend/web/src/features/controlLayers/components/AddPromptButtons.tsx b/invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceAddPromptsIPAdapterButtons.tsx similarity index 96% rename from invokeai/frontend/web/src/features/controlLayers/components/AddPromptButtons.tsx rename to invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceAddPromptsIPAdapterButtons.tsx index aa05176e38..07104989c0 100644 --- a/invokeai/frontend/web/src/features/controlLayers/components/AddPromptButtons.tsx +++ b/invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceAddPromptsIPAdapterButtons.tsx @@ -17,7 +17,7 @@ type AddPromptButtonProps = { id: string; }; -export const AddPromptButtons = ({ id }: AddPromptButtonProps) => { +export const RegionalGuidanceAddPromptsIPAdapterButtons = ({ id }: AddPromptButtonProps) => { const { t } = useTranslation(); const dispatch = useAppDispatch(); const defaultIPAdapter = useDefaultIPAdapter(); diff --git a/invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceSettings.tsx b/invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceSettings.tsx index fb359e06c5..54165cfbeb 100644 --- a/invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceSettings.tsx +++ b/invokeai/frontend/web/src/features/controlLayers/components/RegionalGuidance/RegionalGuidanceSettings.tsx @@ -1,7 +1,7 @@ import { Divider } from '@invoke-ai/ui-library'; import { useAppSelector } from 'app/store/storeHooks'; -import { AddPromptButtons } from 'features/controlLayers/components/AddPromptButtons'; import { CanvasEntitySettingsWrapper } from 'features/controlLayers/components/common/CanvasEntitySettingsWrapper'; +import { RegionalGuidanceAddPromptsIPAdapterButtons } from 'features/controlLayers/components/RegionalGuidance/RegionalGuidanceAddPromptsIPAdapterButtons'; import { useEntityIdentifierContext } from 'features/controlLayers/contexts/EntityIdentifierContext'; import { selectRegionalGuidanceEntityOrThrow } from 'features/controlLayers/store/regionsReducers'; import { memo } from 'react'; @@ -24,7 +24,9 @@ export const RegionalGuidanceSettings = memo(() => { return ( - {!hasPositivePrompt && !hasNegativePrompt && !hasIPAdapters && } + {!hasPositivePrompt && !hasNegativePrompt && !hasIPAdapters && ( + + )} {hasPositivePrompt && ( <>