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

Splitter error : Cannot read property '0' of undefined at Splitter.onResize #10286

Closed
Blafy opened this issue Jun 1, 2021 · 1 comment
Closed
Assignees
Labels
LTS-FIXED-11.4.8 Fixed in PrimeNG LTS 11.4.8 Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@Blafy
Copy link

Blafy commented Jun 1, 2021

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

Plunkr Case (Bug Reports)
Please demonstrate your case at stackblitz by using the issue template below. Issues without a test case have much less possibility to be reviewd in detail and assisted.

https://stackblitz.com/edit/primeng-splitter-demo-xwz81m

Current behavior
Moving the splitter to the left repeatedly throws an error
"TypeError: Cannot read property '0' of undefined
at Splitter.onResize (splitter.ts:147)

Expected behavior
No error thrown

Minimal reproduction of the problem with instructions
Like I said in #10176, you need to drag the splitter from right to the very far left (further than the div) several times (a dozen) to make it happen.

What is the motivation / use case for changing the behavior?
I'm not sure here, but it seems that 'event.changedTouches' is undefined sometimes

Please tell us about your environment:
Windows 10

  • Angular version:
    11.0.9

  • PrimeNG version: 5.X
    11.4.2

  • Browser:
    Edge 91.0.864, Firefox 88.0.1

  • Language:
    TypeScript 4

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

@yigitfindikli yigitfindikli added the Status: Pending Review Issue or pull request is being reviewed by Core Team label Jun 1, 2021
@rsohi
Copy link

rsohi commented Jun 1, 2021

As pointed by @Blafy the issue still persist in the new version. One tip to replicate keep the dragging to outside the div and do not mouseup

@yigitfindikli yigitfindikli added Type: Bug Issue contains a bug related to a specific component. Something about the component is not working and removed Status: Pending Review Issue or pull request is being reviewed by Core Team labels Jun 4, 2021
@yigitfindikli yigitfindikli self-assigned this Jun 4, 2021
@yigitfindikli yigitfindikli added this to the 12.0.0-Final milestone Jun 4, 2021
@yigitfindikli yigitfindikli changed the title Splitter error : Cannot read property '0' of undefined at Splitter.onResize same as #10176 Splitter error : Cannot read property '0' of undefined at Splitter.onResize Jun 4, 2021
yigitfindikli added a commit that referenced this issue Jun 7, 2021
@yigitfindikli yigitfindikli added LTS-FIXED-11.4.8 Fixed in PrimeNG LTS 11.4.8 and removed LTS-PORTABLE labels Nov 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
LTS-FIXED-11.4.8 Fixed in PrimeNG LTS 11.4.8 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