Comments (6)
what do you mean by "doesn't work"? what browser/OS are you using and why do you think that it doesn't work?
from leaflet-sidebar.
I have tried FireFox and Chrome.
My understanding was that clicking X in upper right corner will close sidepanel.
Try your own example.
http://turbo87.github.io/leaflet-sidebar/examples/two-sidebars.html.
from leaflet-sidebar.
ah, I see what you mean. it seems that it is not working properly in this particular example. if you check the main example at http://turbo87.github.io/leaflet-sidebar/examples/ however it works well for me.
from leaflet-sidebar.
https://github.com/Turbo87/leaflet-sidebar/blob/master/examples/index.html
Look at the end of file. There is click handler for whole map.
You can click anywhere on the map and close sidepanel.
(somehow it works for the X button too)
map.on('click', function () {
sidebar.hide();
}
from leaflet-sidebar.
right, thanks for analyzing that. I guess the solution is preventing the event from bubbling up to the map and fixing the event handler to hide the sidebar.
from leaflet-sidebar.
@UmpPCPL should be fixed by 6687349
from leaflet-sidebar.
Related Issues (20)
- show(), hide(), toggle() not working HOT 3
- Leaflet >=1.1.0 L.DomEvent.fakestop() HOT 2
- Sidebar appear from the side when zoom level changed on the browser HOT 2
- Changing sidebar position on-the-fly HOT 2
- Cannot read property 'prototype' of undefined HOT 4
- Fancybox not working in sidebar HOT 6
- Conflict with plugin twentytwenty HOT 3
- Using plugin in R Leaflet HOT 3
- Close button hidden due low z-index HOT 2
- Sidebar out map div HOT 2
- .
- Version 0.2.1 is not in NPM? HOT 4
- Deprecated include of L.Mixin.Events HOT 2
- Improve readme
- Examples not working HOT 2
- When get bounds center object to map look like is not center HOT 1
- Two sidebars are not working HOT 1
- [accessibility] Keyboard and screen reader support for the close button HOT 1
- How can i use this in react.js ?
- L.Mixin.Events is deprecated HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from leaflet-sidebar.