Fix PageHeaderToggleCommandMenuButton (#11496)
This PR fixes a bug introduced by https://github.com/twentyhq/twenty/pull/11470 Before: https://github.com/user-attachments/assets/8c1b8114-591f-4b58-a177-551c4f0dfb98 After: https://github.com/user-attachments/assets/b93aa498-2ae8-4001-b541-372866d24f54
This commit is contained in:
@ -118,31 +118,30 @@ export const PageHeaderToggleCommandMenuButton = () => {
|
|||||||
const theme = useTheme();
|
const theme = useTheme();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<StyledButtonWrapper>
|
||||||
<StyledButtonWrapper>
|
<div id="toggle-command-menu-button">
|
||||||
<div id="toggle-command-menu-button">
|
<AnimatedButton
|
||||||
<AnimatedButton
|
animatedSvg={
|
||||||
animatedSvg={
|
<AnimatedIcon isCommandMenuOpened={isCommandMenuOpened} />
|
||||||
<AnimatedIcon isCommandMenuOpened={isCommandMenuOpened} />
|
}
|
||||||
}
|
className="page-header-command-menu-button"
|
||||||
className="page-header-command-menu-button"
|
dataTestId="page-header-command-menu-button"
|
||||||
dataTestId="page-header-command-menu-button"
|
size={isMobile ? 'medium' : 'small'}
|
||||||
size={isMobile ? 'medium' : 'small'}
|
variant="secondary"
|
||||||
variant="secondary"
|
accent="default"
|
||||||
accent="default"
|
hotkeys={[getOsControlSymbol(), 'K']}
|
||||||
hotkeys={[getOsControlSymbol(), 'K']}
|
ariaLabel={ariaLabel}
|
||||||
ariaLabel={ariaLabel}
|
onClick={toggleCommandMenu}
|
||||||
onClick={toggleCommandMenu}
|
animate={{
|
||||||
animate={{
|
rotate: isCommandMenuOpened ? 90 : 0,
|
||||||
rotate: isCommandMenuOpened ? 90 : 0,
|
}}
|
||||||
}}
|
transition={{
|
||||||
transition={{
|
duration: theme.animation.duration.normal,
|
||||||
duration: theme.animation.duration.normal,
|
ease: 'easeInOut',
|
||||||
ease: 'easeInOut',
|
}}
|
||||||
}}
|
/>
|
||||||
/>
|
</div>
|
||||||
</div>
|
|
||||||
</StyledButtonWrapper>
|
|
||||||
<StyledTooltipWrapper>
|
<StyledTooltipWrapper>
|
||||||
<AppTooltip
|
<AppTooltip
|
||||||
anchorSelect="#toggle-command-menu-button"
|
anchorSelect="#toggle-command-menu-button"
|
||||||
@ -153,6 +152,6 @@ export const PageHeaderToggleCommandMenuButton = () => {
|
|||||||
noArrow
|
noArrow
|
||||||
/>
|
/>
|
||||||
</StyledTooltipWrapper>
|
</StyledTooltipWrapper>
|
||||||
</div>
|
</StyledButtonWrapper>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user