mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
fix: Cancel Button not maintaining min height
After the recent changes the Cancel button wasn't maintaining min height in floating mode. Also the new button group was not scaling in width correctly on the Canvas Beta UI. Fixed both.
This commit is contained in:
parent
2cd7bd4a8e
commit
8ae71303a5
@ -40,11 +40,15 @@ const cancelButtonSelector = createSelector(
|
||||
}
|
||||
);
|
||||
|
||||
interface CancelButtonProps {
|
||||
btnGroupWidth?: string | number;
|
||||
}
|
||||
|
||||
export default function CancelButton(
|
||||
props: Omit<IAIIconButtonProps, 'aria-label'>
|
||||
props: CancelButtonProps & Omit<IAIIconButtonProps, 'aria-label'>
|
||||
) {
|
||||
const dispatch = useAppDispatch();
|
||||
const { ...rest } = props;
|
||||
const { btnGroupWidth = 'auto', ...rest } = props;
|
||||
const {
|
||||
isProcessing,
|
||||
isConnected,
|
||||
@ -91,7 +95,12 @@ export default function CancelButton(
|
||||
];
|
||||
|
||||
return (
|
||||
<ButtonGroup isAttached variant="link">
|
||||
<ButtonGroup
|
||||
isAttached
|
||||
variant="link"
|
||||
minHeight="2.5rem"
|
||||
width={btnGroupWidth}
|
||||
>
|
||||
{cancelType === 'immediate' ? (
|
||||
<IAIIconButton
|
||||
icon={<MdCancel />}
|
||||
|
@ -38,7 +38,7 @@ export default function UnifiedCanvasProcessingButtons() {
|
||||
<InvokeButton iconButton />
|
||||
</Flex>
|
||||
<Flex>
|
||||
<CancelButton width="100%" height="40px" />
|
||||
<CancelButton width="100%" height="40px" btnGroupWidth="100%" />
|
||||
</Flex>
|
||||
</Flex>
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user