button css

This commit is contained in:
scossa 2024-08-18 23:55:27 +02:00
parent 802748863f
commit c0d783db52
4 changed files with 15 additions and 13 deletions

View file

@ -2,6 +2,7 @@ body {
margin: 0px !important;
}
#container {
display: flexbox;
}
@ -10,35 +11,34 @@ body {
#map {
height: 100vh;
width: 100vw;
/*cursor: url('https://unpkg.com/leaflet@1.9.4/dist/images/marker-icon.png'), auto; *//* custom cursore */
/*cursor: url("/img/marker-icon13.png"), auto;*/
}
.button-image {
width: 5px; /* Set the desired width */
height: auto; /* Maintain aspect ratio */
width: 5px;
height: auto;
}
.leaflet-popup-content>img {
width: 100%;
height: 100%;
}
#addMarkerBtn {
/* border-radius: 50%; */
z-index: 1000;
background: white;
width: 30px;
height: 30px;
background: rgb(255, 255, 255);
width: 40px;
height: 38px;
position: absolute;
top: 0;
/* Place the button 20px from the bottom */
right: 0;
/* Place the button 20px from the right */
margin-top: 10px;
margin-right: 10px;
}
#markerFormContainer {
display: none;
z-index: 999;
@ -52,6 +52,7 @@ body {
background-color: white;
}
#markerForm {
display: flex;
flex-direction: column;
@ -61,10 +62,12 @@ body {
margin: 20px 10px;
}
#markerForm > button {
margin-left: auto;
}
#remainingForm {
display: none;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

View file

@ -45,8 +45,7 @@
</div>
<div id="map">
<script>
document.getElementById("addMarkerBtn").innerHTML = '<img src="../img/marker-icon13.png" alt="Button Image" />';
//<button id="addMarkerBtn">📌</button> <!--// bottone vecchio!-->
document.getElementById("addMarkerBtn").innerHTML = '<img src="../img/marker-icon18.png" alt="Button Image" />';
</script>
</div>
</body>

View file

@ -21,7 +21,7 @@ export function initEvents(map){
// switch modalità inserimento/visualizzazione
if (isRedIcon) {
// imposta un marker come icona pulsante, icona cursore normale e esce dalla modalità inserimento.
document.getElementById("addMarkerBtn").innerHTML = '<img src="../img/marker-icon13.png" alt="Button Image" />';
document.getElementById("addMarkerBtn").innerHTML = '<img src="../img/marker-icon18.png" alt="Button Image" />';
document.getElementById('map').style = 'cursor: auto;';
editMode = false;
tmpMarkerSet = true;