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; margin: 0px !important;
} }
#container { #container {
display: flexbox; display: flexbox;
} }
@ -10,35 +11,34 @@ body {
#map { #map {
height: 100vh; height: 100vh;
width: 100vw; 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 { .button-image {
width: 5px; /* Set the desired width */ width: 5px;
height: auto; /* Maintain aspect ratio */ height: auto;
} }
.leaflet-popup-content>img { .leaflet-popup-content>img {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
#addMarkerBtn { #addMarkerBtn {
/* border-radius: 50%; */
z-index: 1000; z-index: 1000;
background: white; background: rgb(255, 255, 255);
width: 30px; width: 40px;
height: 30px; height: 38px;
position: absolute; position: absolute;
top: 0; top: 0;
/* Place the button 20px from the bottom */
right: 0; right: 0;
/* Place the button 20px from the right */
margin-top: 10px; margin-top: 10px;
margin-right: 10px; margin-right: 10px;
} }
#markerFormContainer { #markerFormContainer {
display: none; display: none;
z-index: 999; z-index: 999;
@ -52,6 +52,7 @@ body {
background-color: white; background-color: white;
} }
#markerForm { #markerForm {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
@ -61,10 +62,12 @@ body {
margin: 20px 10px; margin: 20px 10px;
} }
#markerForm > button { #markerForm > button {
margin-left: auto; margin-left: auto;
} }
#remainingForm { #remainingForm {
display: none; 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>
<div id="map"> <div id="map">
<script> <script>
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" />';
//<button id="addMarkerBtn">📌</button> <!--// bottone vecchio!-->
</script> </script>
</div> </div>
</body> </body>

View file

@ -21,7 +21,7 @@ export function initEvents(map){
// switch modalità inserimento/visualizzazione // switch modalità inserimento/visualizzazione
if (isRedIcon) { if (isRedIcon) {
// imposta un marker come icona pulsante, icona cursore normale e esce dalla modalità inserimento. // 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;'; document.getElementById('map').style = 'cursor: auto;';
editMode = false; editMode = false;
tmpMarkerSet = true; tmpMarkerSet = true;