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

double clicking the checkbox/radiobutton causes the label to highlight #6278

Closed
SteveMattar opened this issue Aug 9, 2018 · 3 comments
Closed
Assignees
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@SteveMattar
Copy link

I'm submitting a ... (check one with "x")

[x ] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primeng/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=35

Current behavior
in Chrome when clicking rapidly on the checkbox it highlights the checkbox label, or any other element outside of the component: label, span, input...
i tried to resolve the issue by disabling the user-select in the css but the issue remains and jumps to the next element

Expected behavior
no highlight (just like in IE)

Minimal reproduction of the problem with instructions

https://www.primefaces.org/primeng/#/checkbox

What is the motivation / use case for changing the behavior?
better ux

Please tell us about your environment:

  • Angular version: 6.0.6
  • PrimeNG version: 6.0.1
  • Browser: [Chrome Version 67.0.3396.99 ]
  • Language: [all]

  • Node (for AoT issues): node --version = 8.9

@JacobSiegle
Copy link
Contributor

Not sure what you mean about it jumping to the next element or even if this is a regression from previous PrimeNG versions, but setting 'user-select: none' on '.ui-chkbox-label' does prevent the checkbox label from being selected on double click.

@SteveMattar
Copy link
Author

try to set 'user-select: none' on '.ui-chkbox-label' in https://www.primefaces.org/primeng/#/checkbox using F12
Then click rapidly on "Los Angeles" or "Entertainment" check-boxes the label will not be highlighted but the next element which is the "Selected Cities: / Selected Catergories" will be highlighted instead

@JacobSiegle
Copy link
Contributor

Weird glitch, seems like it can be fixed by adding 'user-select: none' onto p-checkbox in chrome instead of the label.

@cagataycivici cagataycivici self-assigned this Aug 12, 2018
@cagataycivici cagataycivici added the Type: Bug Issue contains a bug related to a specific component. Something about the component is not working label Aug 12, 2018
@cagataycivici cagataycivici added this to the 6.1.1 milestone Aug 12, 2018
@cagataycivici cagataycivici changed the title double clicking the checkbox causes the label to highlight double clicking the checkbox/radiobutton causes the label to highlight Aug 14, 2018
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

No branches or pull requests

3 participants