publiclab / leaflet-environmental-layers

Collection of different environmental map layers in an easy to use Leaflet library, similar to https://github.com/leaflet-extras/leaflet-providers#leaflet-providers
https://publiclab.github.io/leaflet-environmental-layers/example/
GNU General Public License v3.0
99 stars 77 forks source link

add thumbnail images to some layers #112

Open jywarren opened 5 years ago

jywarren commented 5 years ago

Like the mapknitter layer! This would be great. See http://mapknitter.org for the source of this layer.

The image would be added to this line, in the Popup HTML:

https://github.com/publiclab/leaflet-environmental-layers/blob/e36f294a2d4d8e588bf1a2647e6d039b98353a5a/src/mapKnitterLayer.js#L87

It could be build once this corresponding issue in MapKnitter is completed, which would add the image url to the JSON response: https://github.com/publiclab/mapknitter/issues/346

Thanks!

avsingh999 commented 5 years ago

@jywarren which images we have to show in popup HTML please clear me. thanks : )

jywarren commented 5 years ago

Hi! I think the maps Json feed should now show images, but it's not yet published, so maybe we have to wait a bit first? Could you try another issue maybe for now? Thanks!!!

sagarpreet-chadha commented 5 years ago

On It 😄 !

jywarren commented 5 years ago

thank you so much!!!

On Fri, Jun 28, 2019 at 10:54 AM Sagarpreet Chadha notifications@github.com wrote:

On It 😄 !

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/leaflet-environmental-layers/issues/112?email_source=notifications&email_token=AAAF6J47DVY64DELZZUZ6VLP4YQYVA5CNFSM4GPOIZM2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODY2JSJY#issuecomment-506763559, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6JYB76UH2YBJF7NWMO3P4YQYVANCNFSM4GPOIZMQ .

sagarpreet-chadha commented 5 years ago

Opening for other layers .

Swayamsvk commented 4 years ago

Can I work on this?

jywarren commented 4 years ago

Hi @crisner @nstjean i think this is now possible using a formatting function? Not sure though? Just wondering next steps for future contributors. Thanks!

crisner commented 4 years ago

@jywarren, I haven't come across a formatting function as such. Images are being included in popups through methods as the one below: https://github.com/publiclab/leaflet-environmental-layers/blob/67419ed0f9982fbb70cbff6aaceda96eee5af6de/src/layercode.js#L331 Or directly within the getMarker function as linked in the issue comment.