|
|
|
|
|
by sovok
3502 days ago
|
|
Thanks. It's just plain JavaScript and some jQuery. It uses SVG so the browser takes on some of the work you'd have to do yourself with canvas, like having the shapes as their own element and detecting mouse events. This also makes it easy to export as SVG (just append .svg to the URL). Server stuff and a small backend runs on minimal PHP and MySQL, no frameworks. The data is stored in a JSON-based format. PNGs are generated from the SVG with ImageMagick. Keyboard shortcuts with jQuery.hotkeys. Could be more modularized to allow touch input, multiplayer editing, use as a library etc., thus the needed rewrite :> The endgame for this could be something like https://www.figma.com. They have collaborative editing, use canvas to completely do their own thing for graphics and React+Redux for the interface. Quite amazing. |
|