Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dropdown: Additional case where dropdown causes panel to scroll #14078

Closed
rosenthalj opened this issue Nov 9, 2023 · 0 comments · Fixed by #14079
Closed

Dropdown: Additional case where dropdown causes panel to scroll #14078

rosenthalj opened this issue Nov 9, 2023 · 0 comments · Fixed by #14079
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@rosenthalj
Copy link
Contributor

rosenthalj commented Nov 9, 2023

Describe the bug

Similar to issue #14039 which was fixed in v16.7.2 by pull request #14040

This is just another special dropdown component case.

If a horizontal scroll bar is present, when a user clicks on the dropdown component or uses the mouse key to navigate the dropdown menu options, the panel containing the dropdown will scroll to the "CENTER" of the visible region.

The video demonstrates the problem

DropdownScrollIssue.mov

Environment

mac os and windows

Reproducer

https://stackblitz.com/edit/nkd8th-jtv6xj

Angular version

16.x

PrimeNG version

16.7.2

Build / Runtime

Angular CLI App

Language

TypeScript

Node version (for AoT issues node --version)

18.18.1

Browser(s)

safari, chrome, firefox

Steps to reproduce the behavior

  1. Run the reproducer: https://stackblitz.com/edit/nkd8th-jtv6xj
  2. Use the scroll bar to scroll the red rectangle out of view
    --> Only the yellow rectangles and the dropdown are visible
  3. Click on dropdown
    --> The panel will automatically scroll and center the dropdown

Expected behavior

The panel should not scroll

@rosenthalj rosenthalj added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Nov 9, 2023
@cetincakiroglu cetincakiroglu added Type: Bug Issue contains a bug related to a specific component. Something about the component is not working and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Nov 15, 2023
@cetincakiroglu cetincakiroglu added this to the 16.8.0 milestone Nov 15, 2023
cetincakiroglu added a commit that referenced this issue Nov 15, 2023
Fix additional case where dropdown causes panel (#14078)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants