Skip to content

Commit 90ff9a4

Browse files
fix(ui): only show weight for IP adapters
1 parent adc69ea commit 90ff9a4

File tree

1 file changed

+16
-14
lines changed
  • invokeai/frontend/web/src/features/controlLayers/components/RefImage

1 file changed

+16
-14
lines changed

invokeai/frontend/web/src/features/controlLayers/components/RefImage/RefImage.tsx

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -197,20 +197,22 @@ const Thumbnail = memo(({ disclosure }: { disclosure: UseDisclosure }) => {
197197
maxH="full"
198198
borderRadius="base"
199199
/>
200-
<Flex
201-
position="absolute"
202-
inset={0}
203-
fontWeight="semibold"
204-
alignItems="center"
205-
justifyContent="center"
206-
zIndex={1}
207-
data-visible={showWeightDisplay}
208-
sx={weightDisplaySx}
209-
>
210-
<Text filter="drop-shadow(0px 0px 4px rgb(0, 0, 0)) drop-shadow(0px 0px 2px rgba(0, 0, 0, 1))">
211-
{`${round(entity.config.weight * 100, 2)}%`}
212-
</Text>
213-
</Flex>
200+
{isIPAdapterConfig(entity.config) && (
201+
<Flex
202+
position="absolute"
203+
inset={0}
204+
fontWeight="semibold"
205+
alignItems="center"
206+
justifyContent="center"
207+
zIndex={1}
208+
data-visible={showWeightDisplay}
209+
sx={weightDisplaySx}
210+
>
211+
<Text filter="drop-shadow(0px 0px 4px rgb(0, 0, 0)) drop-shadow(0px 0px 2px rgba(0, 0, 0, 1))">
212+
{`${round(entity.config.weight * 100, 2)}%`}
213+
</Text>
214+
</Flex>
215+
)}
214216
</Flex>
215217
</PopoverAnchor>
216218
);

0 commit comments

Comments
 (0)