Closed jywarren closed 1 year ago
Hi @jywarren, this URL https://lite.mapknitter.org?k=empire-st-chinatown-providence
is quite simple and user-friendly too but it appears we could have this https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?k=empire-st-chinatown-providence
in the interim if lite.mapknitter.org
is a long term plan. What do you say?
You know I could work to realize this https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?k=empire-st-chinatown-providence
if you think it makes sense in the context of what the long term plan is.
That does make sense. If you can implement the k= parameter, then I can work on getting the subdomain set up! Thanks!
On Wed, Feb 22, 2023 at 11:11 AM Segun @.***> wrote:
Hi @jywarren https://github.com/jywarren, this URL https://lite.mapknitter.org?k=empire-st-chinatown-providence is quite simple and user-friendly too but it appears we could have this https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?k=empire-st-chinatown-providence in the interim if lite.mapknitter.org is a long term plan. What do you say?
You know I could work to realize this https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?k=empire-st-chinatown-providence if you think it makes sense in the context of what the long term plan is.
— Reply to this email directly, view it on GitHub https://github.com/publiclab/Leaflet.DistortableImage/issues/1355#issuecomment-1440327378, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAF6J6XHSJ5ACVFIHQPL6TWYY3CPANCNFSM6AAAAAAU33NLCI . You are receiving this because you were mentioned.Message ID: @.***>
Please clarify, do you mean I could implement k=parameter for https://lite.mapknitter.org?k=empire-st-chinatown-providence
? Many thanks!
I thought if it's implemented for GitHub pages, it will also work for the subdomain as well, right? Thanks!
On Wed, Feb 22, 2023, 8:52 PM Segun @.***> wrote:
Please clarify, do you mean I could implement k=parameter for https://lite.mapknitter.org?k=empire-st-chinatown-providence? Many thanks!
— Reply to this email directly, view it on GitHub https://github.com/publiclab/Leaflet.DistortableImage/issues/1355#issuecomment-1441122701, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAF6J4YKOXYCLDWXE7QZZDWY27FBANCNFSM6AAAAAAU33NLCI . You are receiving this because you were mentioned.Message ID: @.***>
Oh! yeah, sure it will. Okay, I will begin work on this.
Shorten URL-Type 1: https://publiclab.github.io/Leaflet.DistortableImage/examples/archive.html?k=empire-st-chinatown-providence (for legacy json files) Shorten URL-Type 2: https://publiclab.github.io/Leaflet.DistortableImage/examples/archive.html?k=mkl-2-2 (for mk-lite generated json files)
For shorten URL-Type 1 to work:
For shorten URL-Type 2 to work:
What do you think about this?
Hmm, I actually hadn't thought about the legacy MapKnitter files related to this, but that is an interesting idea!
I was just thinking of scenario 2, where k = the key of an Archive.org collection, like: https://archive.org/details/empire-st-chinatown-providence
Since we already can load those directly like:
all we have to do is to find the name of the JSON file, which I think we already do because of #1351. So for this PR, I believe we just need to read the k=KEYNAME
parameter, and begin using it the same way as if you'd pasted it in, then auto-detect the JSON file, which should already work. How does that sound?
Separately the idea of a short URL for legacy mapknitter maps is interesting, and we could open a second issue for that if you want! But I think maybe it's lower priority than some of the other things on our list, like code modularity and tests.
Okay, this approach sounds good.
Currently, and excitingly, we can now share maps like this:
https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?json=https://ia601609.us.archive.org/33/items/empire-st-chinatown-providence/mapknitter-1676395083251.json
What if we also allowed sharing maps using only an Archive.org key? The URL could be much shorter:
https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?k=empire-st-chinatown-providence
If we started serving this from a new repository or URL we could even do this maybe:
https://lite.mapknitter.org?k=empire-st-chinatown-providence
It would then act as if you'd entered the collection URL but would auto-load.
What do you all think?