taye / interact.js

JavaScript drag and drop, resizing and multi-touch gestures with inertia and snapping for modern browsers (and also IE9+)
http://interactjs.io/
MIT License
12.32k stars 783 forks source link

Deprecation warning for vendor-prefixed attribute mozPressure #978

Closed Sardtok closed 1 year ago

Sardtok commented 2 years ago

Expected behavior

Page using interact.js should not generate warnings.

Actual behavior

Firefox warns that the vendor specific attribute MouseEvent.mozPressure is deprecated and should not be used. PointerEvent.pressure, should be used instead.

The source file in question is pointerExtend.ts.

System configuration

interact.js version: 1.10.17 Browser name and version: Firefox 103.0.2 Operating System: Windows 11 64-bit

Sardtok commented 1 year ago

I believe this is was re-introduced in 1.10.15, which was when utils/pointerExtend.ts had its logic changed. It was previously fixed in #751, where PressureEvents were added to the deprecation list for vendor-prefixed props. The new logic doesn't use a deprecation list, so it seems there's something a bit faulty with the lookup logic for existing non-prefixed props.