Skip to content

Commit

Permalink
Merge pull request #267 from zer0-dev/custom_bbox_show
Browse files Browse the repository at this point in the history
Show custom bbox on map-container
  • Loading branch information
louis-e authored Jan 11, 2025
2 parents 7b7ff6b + 408e182 commit a92c5bb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions gui-src/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,11 @@ function handleBboxInput() {
const bboxText = `${lat1} ${lng1} ${lat2} ${lng2}`;
window.dispatchEvent(new MessageEvent('message', { data: { bboxText } }));

// Show custom bbox on the map
let map_container = document.querySelector('.map-container');
map_container.setAttribute('src', `maps.html#${lat1},${lng1},${lat2},${lng2}`);
map_container.contentWindow.location.reload();

// Update the info text
bboxInfo.textContent = window.localization.custom_selection_confirmed;
bboxInfo.style.color = "#7bd864";
Expand Down

0 comments on commit a92c5bb

Please sign in to comment.