A client-side GIF generator for producing Bay Bridge Light GIFS. Runs on @jnordberg's client-side GIF generator.
Make sure you have Node.js and the Heroku Toolbelt installed.
$ npm install
$ npm start
Code for the generation can be found in here.
Your app should now be running on localhost:5000.
The GIF Generator is to be used as an embed on share-donation component of SIF.
/giffy The /giffy path accepts three query params:
- nodeX position of a light
- nodeY position of a light
- light number
Utilizing a 1:4 scale mapping based on the coordinates in use for [lights.py] on bay-lights-api and @jnordberg's client-side GIF-generator, the client generates a 20-frame gif using canvas frames and web-workers. Canvas draws expanding circles along with a title constructed using websafe font. The result is uploaded to filestack, and the Blob URL is extracted for a SendGrid template e-mail. To preserve browser security, all download links have been removed to opt for server-side e-mailing. Users on non-Safari/mobile browers can right-click to save.
/imagify The /imagify path accepts four post items:
- image URL
- Recepient Name
- Donator' E-mail
- Light #
Utilizing a SendGrid template e-mail, Donator is shipped off an HTML-rich e-mail with image src embedded.