stefanocudini / leaflet-gps Goto Github PK
View Code? Open in Web Editor NEWSimple leaflet control plugin for tracking gps position
Home Page: https://opengeo.tech/maps/leaflet-gps
License: MIT License
Simple leaflet control plugin for tracking gps position
Home Page: https://opengeo.tech/maps/leaflet-gps
License: MIT License
Making the .gps-alert
a live region is important as it conveys to screen readers that the content should be announced when added to the DOM, or otherwise has been updated. This is done by adding the status
role (a live region role) to the <div>
, and accompanying ARIA attributes:
<div class="gps-alert" style="display: block;"
+ role="status"
+ aria-live="polite"
+ aria-atomic="true">
Geolocation error: User denied Geolocation.
</div>
While role="status"
already implies aria-live="polite"
, it's best to be explicit with the value per MDN advice:
To maximize compatibility, add a redundant
aria-live="polite"
when using this role.
Hi,
I would like to use the js and css but instead on cloning the whole repo, I would like to just link in in my script section. How do I do that?
Thank you
Hi,
May I know that is the difference between these two solutions ?
Thanks.
The version that I got via npm was outdated, also please include a "main" entry in the package.json for browserify compatibility. (see pull request #14 )
Your locate plugin has the most accuracy and is the smoothest one for leaflet. Great Job!
Any idea how to implement a spinner icon to the locate-button (with font-awesome) which should appear only when "map.locate" is trying to find the current position of the user?
here's an example: https://www.domoritz.de/leaflet-locatecontrol/demo/
<a class="gps-button">
button is announced as a "link" using a screen reader (missing role="button"
, see Leaflet controls).
Another option is to use <button type="button">
, but requires additional styling to reset browser defaults.
Other potentially helpful resources:
Not really an issue and more of a question. Have you experimented with the ability to leave a GPS trace on the map. Maybe via plotted marker at interval or poly-line generated from intervals?
Have you tested it with leaflet 0.6.4??
Thought it might be a nice addition to have the option of setting a marker with a L.Circle showing the accuracy of the GPS location
getCurrentPosition() and watchPosition() are deprecated on insecure origins, and support will be removed in the future. You should consider switching your application to a secure origin, such as HTTPS. See https://goo.gl/rStTGz for more details.
Someone know a definitive solution for this!??!
Does leaflet-gps work with Leaflet 1.0 beta ?
Hi,
Is it possible to display the user coordinates inside a div or pass them to a variable?
Thanks and good work.
this issue affects iOS device on Safari:
http://stackoverflow.com/questions/1409141/location-manager-error-kclerrordomain-error-0
Be cool have option for autoupdating marker position by time (min, sec).
Example:
options: {
autoActive: false, //activate control at startup
autoCenter: false, //move map when gps location change
maxZoom: null, //max zoom for autoCenter
autoUpdate: 60 // autoupdate my position via GPS in sec
Now marker position updating if move map or if change map zoom.
But marker not move automaticaly if I go or if I ride.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.