mirror of
https://github.com/tiennm99/ccs.git
synced 2026-10-14 08:18:04 +00:00
fix(ui): restore searchable-select dropdown scrolling
- replace the popover list scroll area with a native overflow container - keep keyboard navigation behavior while restoring wheel scroll in long dropdowns
This commit is contained in:
1 parent
87f00c524d
commit
a70eae558e
2 files changed
+16
-3
No files matched your search
@@ -122,6 +122,16 @@ describe('SearchableSelect', () => {
|
||||
});
|
||||
});
|
||||
|
||||
it('renders options inside a native overflow container so wheel scrolling works', async () => {
|
||||
render(<SearchableSelectHarness />);
|
||||
|
||||
await userEvent.click(screen.getByRole('button', { name: 'Select model' }));
|
||||
|
||||
const scrollContainer = await screen.findByTestId('searchable-select-scroll-container');
|
||||
expect(scrollContainer).toHaveClass('max-h-72');
|
||||
expect(scrollContainer).toHaveClass('overflow-y-auto');
|
||||
});
|
||||
|
||||
it('opens from the trigger with arrow keys', async () => {
|
||||
render(<SearchableSelectHarness />);
|
||||
|
||||
|
||||
Reference in new issue
Block a user