Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

188
Visualizações
Leaflet Fullscreen

I use the framework codeigniter3
bootrsap 5 called in header.php
Leaflet map cdn (in view)
leaflet.fullscreen cdn (in view)
jquery cdn (in view)

1st step in mode fullscreen off (worked fine)

<script>
 $("#map").css('z-index', 0);
 $(".sidebar").css('position', 'absolute')
 $(".sidebar").css('z-index', 1);
 $(".sidebar").draggable();
 $(".card-header-sidebar").css('cursor', 'grab');
</script>

when i change fullscreen ok ( my problem )

i want to keep the sidebar visible

Full screen off
full screen on

about 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

There are no solution for fullscreen leaflet with extern html content
Other adapted solution:
Add class hidden to sidebar ( Html element )

Create Legend on map

const legend = L.control({
  position: "topleft"
});

Get html content

const legend_html = $('#sidebar').html()

Add this to map

legend.onAdd = function() {
  let div = L.DomUtil.create("div", "leaflet-legend");
  L.DomEvent.disableClickPropagation(div);
  div.insertAdjacentHTML("beforeend", legend_html);
  return div;
};
legend.addTo(map);

Fullscreen result

about 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda