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

Pointer events should not be visibile outside of cdk-drag/cdk-drop area. #17415

Open
1 of 4 tasks
StefaniToto opened this issue Jan 16, 2025 · 0 comments
Open
1 of 4 tasks
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible

Comments

@StefaniToto
Copy link

Describe the bug

Scenario: Having a component that contain a drag/drop functionality, will affect other components that has on hover effect.

Issue:
Hovering at component-2 should apply some style.
When we drag from comp-1/comp-3 to some other part of the page, but especially at comp-2 that has an active class for hovering,
the pointer-events are making this component as active.

This styles of drag/drop element is better to remain only inside that box and not to affect other elements.

Hot fix: Remove the pointer event from other components, and add it only to drag area where is active.

Image

Pull Request Link

No response

Reason for not contributing a PR

  • Lack of time
  • Unsure how to implement the fix/feature
  • Difficulty understanding the codebase
  • Other

Other Reason

No response

Reproducer

https://stackblitz.com/github/StefaniToto/Primeng-Drag-Drop

Environment

Windows 11, WebStorm.

Angular version

18.0.1

PrimeNG version

v17 (LTS Only)

Node version

22.3.0

Browser(s)

Chrome,Firefox

Steps to reproduce the behavior

Drag the element from drag/drop area to other elements of the page that have a hover style.

Expected behavior

Pointer events should not be visible if we decide to drag an element out of that area.
As long as the drag/drop operation will not be valid this should not affect other components style.

@StefaniToto StefaniToto added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Jan 16, 2025
@StefaniToto StefaniToto changed the title Pointer events should not be visibile outside of cdk-drag/cdk-drop element. Pointer events should not be visibile outside of cdk-drag/cdk-drop area. Jan 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
Projects
None yet
Development

No branches or pull requests

1 participant