From 02bb99f739e407c0daf743fe9fd5aae4a5e3908c Mon Sep 17 00:00:00 2001 From: 1F616EMO~nya Date: Fri, 5 Jul 2024 19:52:39 +0800 Subject: [PATCH] Prevent POI image from vertically overflowing too much (#395) --- public/css/custom.css | 6 ++++++ public/js/map/overlays/PoiOverlay.js | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/public/css/custom.css b/public/css/custom.css index d2da078..be4e61c 100644 --- a/public/css/custom.css +++ b/public/css/custom.css @@ -49,6 +49,12 @@ body { grid-area: info; } +.poi_image_container { + width: 100%; + max-height: 75vh; + overflow-y: auto; +} + .poi_image { width: 100%; height: auto; diff --git a/public/js/map/overlays/PoiOverlay.js b/public/js/map/overlays/PoiOverlay.js index d218fbb..89cbbe9 100644 --- a/public/js/map/overlays/PoiOverlay.js +++ b/public/js/map/overlays/PoiOverlay.js @@ -30,8 +30,9 @@ export default AbstractIconOverlay.extend({ } if (poi.attributes.image) { - innerHTML += ""; + innerHTML += "
" + + "
"; } innerHTML += "
Owner: " + HtmlSanitizer.SanitizeHtml(poi.attributes.owner) + "
";