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

[SALESFORCE] PointerEvent is not a constructor error in LWC #6315

Closed
matsbryntse opened this issue Mar 6, 2023 · 1 comment
Closed

[SALESFORCE] PointerEvent is not a constructor error in LWC #6315

matsbryntse opened this issue Mar 6, 2023 · 1 comment
Assignees
Labels
bug Something isn't working forum Issues from forum large-account Reported by large customer OEM OEM customer premium resolved Fixed but not yet released (available in the nightly builds)
Milestone

Comments

@matsbryntse
Copy link
Member

Forum post

Hi folks,

We've had an issue raised that our released scheduler component is spewing errors when the page is scrolled. After doing a bit of digging it looks like Locker service doesn't support the PointerEvent created in
onScheduleScroll.

The documentation indicates that PointerEvent is not supported within LWC.
https://developer.salesforce.com/docs/component-library/tools/locker-service-viewer

We've seen this in bryntum gantt version 5.2.1, and want to be able to patch that release due to restrictions on changes in patches in Salesforce. So I would appreciate any support you can offer in working around this.

I've attached a screenshot of the exception we're seeing, can we avoid using PointerEvent in this scenario?

Thanks,
Gareth
Screenshot 2023-03-06 at 11.13.37.png

@matsbryntse matsbryntse added bug Something isn't working premium forum Issues from forum large-account Reported by large customer OEM OEM customer labels Mar 6, 2023
@matsbryntse matsbryntse self-assigned this Mar 6, 2023
@matsbryntse matsbryntse added the ready for review Issue is fixed, the pull request is being reviewed label Mar 6, 2023
@amurashincertinia
Copy link

A quick update

This issue is only reproducible if the Scheduler component is displayed on an App page in a Lightning app which uses Console navigation.

We have patched this in our custom bundle build and everything seems to be in order now.

The changes we made:

  1. Added a new supportsPointerEventConstructor feature flag to the BrowserHelper.
  2. Updated our existing override for onScheduleScrollNow with an early exit if PointerEvent constructor is not supported.
  3. Updated EventHelper.fixEvent override with the improved implementation from the latest version.

@matsbryntse matsbryntse added resolved Fixed but not yet released (available in the nightly builds) and removed ready for review Issue is fixed, the pull request is being reviewed labels Mar 9, 2023
@matsbryntse matsbryntse added this to the 5.3.1 milestone Mar 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working forum Issues from forum large-account Reported by large customer OEM OEM customer premium resolved Fixed but not yet released (available in the nightly builds)
Projects
None yet
Development

No branches or pull requests

2 participants