elm-designer icon indicating copy to clipboard operation
elm-designer copied to clipboard

Implement proper workspace pan and zoom capability

Open passiomatic opened this issue 3 years ago • 0 comments

Currently Elm Designer uses the native page CSS overflow and scroll behavior to allow the workspace to be bigger than the browser viewport.

We can swap the current implementation with something more polished by leveraging the Zoom abstraction from the elm-visualization package or elm-pan-and-zoom .

A first proof of concept implementation seems promising: https://ellie-app.com/gS7tKm4BVPNa1

We aim to mimic Figma and Sketch here and map UI commands as follows:

  • Zoom in/out: Cmd/Ctrl down + mouse wheel
  • Combined X/Y panning: Spacebar down + dragging
  • Horizontal translation: horizontal scrolling/wheel
  • Vertical translation: horizontal scrolling/wheel

passiomatic avatar Mar 07 '22 15:03 passiomatic