fix(ui): layers default to expanded

This commit is contained in:
psychedelicious 2024-04-30 19:47:22 +10:00 committed by Kent Keirsey
parent d74cd12aa6
commit 21cf1004db
3 changed files with 3 additions and 3 deletions
invokeai/frontend/web/src/features/controlLayers/components

@ -38,7 +38,7 @@ export const CALayerListItem = memo(({ layerId }: Props) => {
// Must be capture so that the layer is selected before deleting/resetting/etc
dispatch(layerSelected(layerId));
}, [dispatch, layerId]);
const { isOpen, onToggle } = useDisclosure();
const { isOpen, onToggle } = useDisclosure({ defaultIsOpen: true });
return (
<Flex

@ -24,7 +24,7 @@ export const IPLayerListItem = memo(({ layerId }: Props) => {
[layerId]
);
const ipAdapterId = useAppSelector(selector);
const { isOpen, onToggle } = useDisclosure();
const { isOpen, onToggle } = useDisclosure({ defaultIsOpen: true });
return (
<Flex gap={2} bg="base.800" borderRadius="base" p="1px" px={2}>
<Flex flexDir="column" w="full" bg="base.850" borderRadius="base">

@ -47,7 +47,7 @@ export const RGLayerListItem = memo(({ layerId }: Props) => {
);
const { autoNegative, color, hasPositivePrompt, hasNegativePrompt, hasIPAdapters, isSelected } =
useAppSelector(selector);
const { isOpen, onToggle } = useDisclosure();
const { isOpen, onToggle } = useDisclosure({ defaultIsOpen: true });
const onClick = useCallback(() => {
dispatch(layerSelected(layerId));
}, [dispatch, layerId]);