mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
27 lines
738 B
TypeScript
27 lines
738 B
TypeScript
import { IoMdOptions } from 'react-icons/io';
|
|
import { useAppDispatch } from '../../app/store';
|
|
import IAIIconButton from '../../common/components/IAIIconButton';
|
|
import { setShouldShowOptionsPanel } from '../options/optionsSlice';
|
|
|
|
const ShowHideOptionsPanelButton = () => {
|
|
const dispatch = useAppDispatch();
|
|
|
|
const handleShowOptionsPanel = () => {
|
|
dispatch(setShouldShowOptionsPanel(true));
|
|
};
|
|
|
|
return (
|
|
<IAIIconButton
|
|
tooltip="Show Options Panel (G)"
|
|
tooltipPlacement="top"
|
|
aria-label="Show Options Panel"
|
|
styleClass="floating-show-hide-button left"
|
|
onMouseOver={handleShowOptionsPanel}
|
|
>
|
|
<IoMdOptions />
|
|
</IAIIconButton>
|
|
);
|
|
};
|
|
|
|
export default ShowHideOptionsPanelButton;
|