b0576f37250da535ab6e1bad787a11e60671e29c
Drag: mousedown on a vertex circle calls event.preventDefault() (the documented way to opt a gesture out of MapLibre's own drag-to-pan), then a map-wide mousemove/mouseup follows the cursor and updates that point's coordinates live. Delete: clicking a vertex selects it (shown larger/yellow); Delete or Backspace removes it, guarded against eating a keystroke meant for an actual text input on the page. A vertex's own mousedown sets a one-shot flag so the same click doesn't also fall through to the generic map-click handler and add a brand new point on top of it.
MapTool
Table of Contents
A mapping application written in Ruby with Sinatra.
The project’s shape is still open — this is the initial scaffold.
Status
Early scaffold. The web application serves a vector map (MapLibre GL JS), with an online style and an optional offline style backed by a local PMTiles file, an animated RainViewer radar overlay, GPX upload/display (points and tracks, organized in folders), and a live position marker from a local GNSS receiver via gpsd.
Requirements
-
Ruby (see
.ruby-version) and Bundler
Getting started
bundle install
bundle exec puma -C config/puma.rb
Then open http://127.0.0.1:4567 in a browser.
Languages
JavaScript
48.7%
Ruby
43.6%
CSS
6%
HTML
1.2%
Dockerfile
0.5%