working on the js
set up saving image and download