d3/d3-brush

multitouch

Fil opened this issue · 2 comments

Fil commented

It would be nice to manipulate the brush rectangle with two finger touches. Currently what happens is that one corner follows one finger.

Might need to wait for version 2 and d3/d3-selection#245

Fil commented

I have a [EDIT] half-working version at https://observablehq.com/d/16d21e1d05af5ee1 using d3.pointers

Fil commented

The implementation below seems to work. It's built on d3-selection@2-rc2:

https://observablehq.com/d/2553f0eff99e5957

Note that I changed my development approach and this time did everything on a dev notebook directly. Makes it so much easier (in particular) to continuously test on the tablet and the phone each iteration of the code. Previously each change needed a build-upload-refresh loop which was a waste of time.