fix glitch for relation picker search (#8040)
Fix for #7957 --------- Co-authored-by: Félix Malfait <felix@twenty.com>
This commit is contained in:
+1
-8
@@ -3,7 +3,6 @@ import styled from '@emotion/styled';
|
||||
import { ScrollWrapper } from '@/ui/utilities/scroll/components/ScrollWrapper';
|
||||
|
||||
const StyledDropdownMenuItemsExternalContainer = styled.div<{
|
||||
hasMinHeight?: boolean;
|
||||
hasMaxHeight?: boolean;
|
||||
}>`
|
||||
--padding: ${({ theme }) => theme.spacing(1)};
|
||||
@@ -13,7 +12,6 @@ const StyledDropdownMenuItemsExternalContainer = styled.div<{
|
||||
|
||||
flex-direction: column;
|
||||
gap: 2px;
|
||||
min-height: ${({ hasMinHeight }) => (hasMinHeight ? '150px' : '100%')};
|
||||
max-height: ${({ hasMaxHeight }) => (hasMaxHeight ? '188px' : 'none')};
|
||||
overflow-y: auto;
|
||||
|
||||
@@ -38,18 +36,13 @@ const StyledDropdownMenuItemsInternalContainer = styled.div`
|
||||
|
||||
export const DropdownMenuItemsContainer = ({
|
||||
children,
|
||||
hasMinHeight,
|
||||
hasMaxHeight,
|
||||
}: {
|
||||
children: React.ReactNode;
|
||||
hasMinHeight?: boolean;
|
||||
hasMaxHeight?: boolean;
|
||||
}) => {
|
||||
return (
|
||||
<StyledDropdownMenuItemsExternalContainer
|
||||
hasMaxHeight={hasMaxHeight}
|
||||
hasMinHeight={hasMinHeight}
|
||||
>
|
||||
<StyledDropdownMenuItemsExternalContainer hasMaxHeight={hasMaxHeight}>
|
||||
{hasMaxHeight ? (
|
||||
<StyledScrollWrapper contextProviderName="dropdownMenuItemsContainer">
|
||||
<StyledDropdownMenuItemsInternalContainer>
|
||||
|
||||
Reference in New Issue
Block a user