heavyai / heavyai-charting

Dimensional charting built to work natively with crossfilter rendered using d3.js
https://heavyai.github.io/heavyai-charting/
Other
399 stars 73 forks source link

[FE-15602] Popup image support #650

Closed johallar closed 1 year ago

johallar commented 1 year ago

This adds support for showing images in the popup for raster layers. This includes:

Dataset is on Kali @ inaturalist_observations_colorado_fungi

Basic demo + slow connection mocked with chrome to show loader behavior:

https://github.com/heavyai/heavyai-charting/assets/1031659/24c1d8bc-8fbd-4e10-86f2-2d251eb07402

copying from the popup with a tooltip gives you the url of the image:

Screen Shot 2023-07-12 at 2 19 32 PM
species_guess: Xanthoparmelia
image_url: https://inaturalist-open-data.s3.amazonaws.com/photos/595549/medium.JPG
created_at: 12/2/2013, 4:42:49 PM
num_identification_agreements: 1.00
place_state_name: Colorado
user_id: 26K
url: http://www.inaturalist.org/observations/472419
johallar commented 1 year ago

I'm going to make one update here to handle query string parameters w image previews. Current check is a little too dumb endsWith, and sounds like some use cases will need to be able to parse image names with query string params after.

johallar commented 1 year ago

OK @cmatzenbach, made an update to parse URLs a little smarter so we can handle query string params and more. At your earliest convenience