diff --git a/css/app.css b/css/app.css
index b982113..bf91ca5 100644
--- a/css/app.css
+++ b/css/app.css
@@ -121,23 +121,6 @@ a:visited {
padding-right: 33px;
}
/* Leaflef map container */
-@media (max-width: 840px) {
- .map-sm {
- height: 450px;
- }
-}
-@media (min-width: 840px) and (max-width: 960px) {
- .map-sm {
- height: 600px;
- }
-}
-@media (min-width: 960px) and (max-width: 1280px) {
- .map-lg {
- height: 700px;
- }
-}
-@media (min-width: 1280px) {
- .map-lg {
- height: 800px;
- }
+#map {
+ height: calc(100vh - 107px);
}
\ No newline at end of file
diff --git a/index.html b/index.html
index 5f35856..b52641e 100644
--- a/index.html
+++ b/index.html
@@ -14,9 +14,15 @@
Carta archeologica di Capri
+
+
+
+
+
+
-
diff --git a/js/index.js b/js/index.js
index 0fd6f5f..7792401 100644
--- a/js/index.js
+++ b/js/index.js
@@ -7,5 +7,6 @@ document.addEventListener('DOMContentLoaded', async () => {
UI.addCenterMapControl(map, GIS.CENTER_COORDS, GIS.INIT_ZOOM);
UI.toggleMenu('siti');
+ UI.toggleBurger('navbar-burger');
UI.sitesMenu('.menu-list', map, sites);
});
diff --git a/js/ui.js b/js/ui.js
index ca1a9ee..ad25e49 100644
--- a/js/ui.js
+++ b/js/ui.js
@@ -40,6 +40,14 @@ UI.addCenterMapControl = function (map, centerCoords, zoom) {
let centerCtr = new L.Control.CenterControl();
map.addControl(centerCtr);
}
+UI.toggleBurger = function(burgerClass) {
+ const burger = document.querySelector(`.${burgerClass}`);
+ burger.addEventListener('click', () => {
+ burger.classList.toggle('is-active');
+ const menuId = burger.getAttribute('data-target');
+ document.querySelector(`#${menuId}`).classList.toggle('is-active');
+ });
+}
/**
*
* @param {string} triggerId The ID of the trigger element