Leaflet.DistortableImage
Leaflet.DistortableImage copied to clipboard
multiple image collection actions (like export)
Part 1: -- this part is done. This is becoming higher priority now, and would at most basic, include the ability to select and display as selected, multiple images.
Part 2: -- -- this part is done. We should be able to return an array of selected images, and to perform actions using their collected image URLs or other properties.
Part 3: -- this part is done. Eventually we should consider a menu for the manipulation of image collections, for example initiating an export. This relates to https://github.com/publiclab/mapknitter/issues/326, the new MapKnitter Exporter UI, but could also be used for simple things like dragging a group of images together.
Part 4: -- Open to claim Get all actions available in the single image interface working in the collection interface:
- [x] Export
- [x] Delete
- [ ] ToggleTransparency
- [ ] Restore
- [ ] ToggleOutline
- [ ] ToggleRotateScale
- [ ] ToggleScale
- [ ] ToggleRotate
- [ ] EnableEXIF
- [x] ToggleLock
claiming this!
@jywarren hey just wanted to provide a status update here! Working on this and hoping to open a pull request tonight. Thank you
Amazing!!!!
@jywarren I updated this issue a little please feel free to revert it if you think it shouldn't be updated that way
OK! We've ironed out the input format for both the Ruby and JS based exporters, documented here:
https://github.com/publiclab/mapknitter-exporter-sinatra/pull/1#issuecomment-478173823
And we'll also need some glue function to convert that into the JS-specific format here (although we can do that as a follow-up step!):
https://github.com/publiclab/image-sequencer-app/issues/6#issuecomment-478205417
This is all coming together!
We could aim for a function that outputs the basic JSON format in https://github.com/publiclab/mapknitter-exporter-sinatra/pull/1#issuecomment-478173823, called collection.getExportJson()
?
This would eventually be replaced/superceded by a fuller Export UI in React that @sashadev-sky has explored!
This is great. The new class -- was it FeatureCollection
? -- is there an accessor function like featureCollection.getFeatures
that would return an array we could iterate over?
Class is called L.DistortableCollection
. The Leaflet way of doing this is this.eachLayer(function(layer) { .... });
. Not entirely convenient so I can save create quick PR for accessor function. Going to start the project first, though. Does that work?
Yeah, perfect!!!
@jywarren made some updates here!