diff --git a/invokeai/frontend/web/src/common/components/IAICollapse.tsx b/invokeai/frontend/web/src/common/components/IAICollapse.tsx index 0ce767ed9d..a5e08e6ddc 100644 --- a/invokeai/frontend/web/src/common/components/IAICollapse.tsx +++ b/invokeai/frontend/web/src/common/components/IAICollapse.tsx @@ -34,14 +34,10 @@ const IAICollapse = (props: IAIToggleCollapseProps) => { gap: 2, borderTopRadius: 'base', borderBottomRadius: isOpen ? 0 : 'base', - bg: isOpen - ? mode('base.200', 'base.750')(colorMode) - : mode('base.150', 'base.800')(colorMode), + bg: mode('base.250', 'base.750')(colorMode), color: mode('base.900', 'base.100')(colorMode), _hover: { - bg: isOpen - ? mode('base.250', 'base.700')(colorMode) - : mode('base.200', 'base.750')(colorMode), + bg: mode('base.300', 'base.700')(colorMode), }, fontSize: 'sm', fontWeight: 600, @@ -90,9 +86,10 @@ const IAICollapse = (props: IAIToggleCollapseProps) => { { ? {} : { cursor: 'pointer', - bg: mode('base.200', 'base.800')(colorMode), + bg: mode('base.200', 'base.700')(colorMode), _hover: { bg: mode('base.300', 'base.650')(colorMode), color: mode('base.500', 'base.300')(colorMode), diff --git a/invokeai/frontend/web/src/features/controlNet/components/ControlNet.tsx b/invokeai/frontend/web/src/features/controlNet/components/ControlNet.tsx index 367c0c559a..de9995c577 100644 --- a/invokeai/frontend/web/src/features/controlNet/components/ControlNet.tsx +++ b/invokeai/frontend/web/src/features/controlNet/components/ControlNet.tsx @@ -80,9 +80,13 @@ const ControlNet = (props: ControlNetProps) => { sx={{ flexDir: 'column', gap: 3, - p: 3, + p: 2, borderRadius: 'base', position: 'relative', + bg: 'base.250', + _dark: { + bg: 'base.750', + }, }} > @@ -190,7 +194,7 @@ const ControlNet = (props: ControlNetProps) => { aspectRatio: '1/1', }} > - + )} @@ -203,7 +207,7 @@ const ControlNet = (props: ControlNetProps) => { {isExpanded && ( <> - + diff --git a/invokeai/frontend/web/src/features/controlNet/components/ControlNetImagePreview.tsx b/invokeai/frontend/web/src/features/controlNet/components/ControlNetImagePreview.tsx index 0683282811..3b92d9d0c6 100644 --- a/invokeai/frontend/web/src/features/controlNet/components/ControlNetImagePreview.tsx +++ b/invokeai/frontend/web/src/features/controlNet/components/ControlNetImagePreview.tsx @@ -1,14 +1,14 @@ -import { Box, Flex, Spinner, SystemStyleObject } from '@chakra-ui/react'; +import { Box, Flex, Spinner } from '@chakra-ui/react'; import { createSelector } from '@reduxjs/toolkit'; import { skipToken } from '@reduxjs/toolkit/dist/query'; -import { - TypesafeDraggableData, - TypesafeDroppableData, -} from 'features/dnd/types'; import { stateSelector } from 'app/store/store'; import { useAppDispatch, useAppSelector } from 'app/store/storeHooks'; import { defaultSelectorOptions } from 'app/store/util/defaultMemoizeOptions'; import IAIDndImage from 'common/components/IAIDndImage'; +import { + TypesafeDraggableData, + TypesafeDroppableData, +} from 'features/dnd/types'; import { memo, useCallback, useMemo, useState } from 'react'; import { FaUndo } from 'react-icons/fa'; import { useGetImageDTOQuery } from 'services/api/endpoints/images'; @@ -21,7 +21,7 @@ import { type Props = { controlNet: ControlNetConfig; - height: SystemStyleObject['h']; + isSmall?: boolean; }; const selector = createSelector( @@ -36,15 +36,14 @@ const selector = createSelector( defaultSelectorOptions ); -const ControlNetImagePreview = (props: Props) => { - const { height } = props; +const ControlNetImagePreview = ({ isSmall, controlNet }: Props) => { const { controlImage: controlImageName, processedControlImage: processedControlImageName, processorType, isEnabled, controlNetId, - } = props.controlNet; + } = controlNet; const dispatch = useAppDispatch(); @@ -109,7 +108,7 @@ const ControlNetImagePreview = (props: Props) => { sx={{ position: 'relative', w: 'full', - h: height, + h: isSmall ? 28 : 366, // magic no touch alignItems: 'center', justifyContent: 'center', pointerEvents: isEnabled ? 'auto' : 'none', diff --git a/invokeai/frontend/web/src/features/parameters/components/Parameters/ControlNet/ParamControlNetCollapse.tsx b/invokeai/frontend/web/src/features/parameters/components/Parameters/ControlNet/ParamControlNetCollapse.tsx index c4d2d35f8f..9732e34c84 100644 --- a/invokeai/frontend/web/src/features/parameters/components/Parameters/ControlNet/ParamControlNetCollapse.tsx +++ b/invokeai/frontend/web/src/features/parameters/components/Parameters/ControlNet/ParamControlNetCollapse.tsx @@ -69,31 +69,29 @@ const ParamControlNetCollapse = () => { return ( - - - - - + + + } isDisabled={!firstModel} flexGrow={1} - size="md" + size="sm" onClick={handleClickedAddControlNet} />