fix: relation picker should not move once openened (#8026)

Fixes: #7959 

### Problem
- When searching in the dropdown, the results list would shrink based on
matching items
- This dynamic height change caused the dropdown to flip its position on
each keystroke

### Solution
- Added ```hasMinHeight``` as optional props to the
```DropdownMenuItemsContainer``` to maintain consistent height
- This prevents unwanted position recalculations and flipping while user
types
- The dropdown now stays in its initial position throughout the search
interaction

[Screencast from 2024-10-24
15-43-03.webm](https://github.com/user-attachments/assets/741317b7-fc5e-4874-8221-aa626a1a1747)
This commit is contained in:
Harsh Singh
2024-10-24 20:03:50 +05:30
committed by GitHub
parent 4ceee4ab8f
commit 4e8d8ce744
2 changed files with 9 additions and 3 deletions

View File

@ -113,7 +113,7 @@ export const MultiRecordSelect = ({
autoFocus
/>
<DropdownMenuSeparator />
<DropdownMenuItemsContainer hasMaxHeight>
<DropdownMenuItemsContainer hasMaxHeight hasMinHeight>
{recordMultiSelectIsLoading ? (
<MenuItem text="Loading..." />
) : (