https://github.com/sylvenas/leaflet.magicmarker
Magic marker animation.
https://github.com/sylvenas/leaflet.magicmarker
Last synced: about 2 months ago
JSON representation
Magic marker animation.
- Host: GitHub
- URL: https://github.com/sylvenas/leaflet.magicmarker
- Owner: Sylvenas
- License: mit
- Created: 2017-01-18T13:56:23.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-10-09T02:34:01.000Z (over 7 years ago)
- Last Synced: 2025-03-27T07:12:05.221Z (3 months ago)
- Language: CSS
- Size: 89.8 KB
- Stars: 25
- Watchers: 6
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# leaflet.magicMarker
Adding magical animation effect to a marker while loading.
![]()
## supported browsers
Internet Explorer 11
Google Chrome
Safari
Firefox## Demo online
A demo is available on the Github Pages webpage for leaflet.magicMarker [Check out demo!](https://sylvenas.github.io/leaflet.magicMarker/)## Usage
1.Include the JavaScript file and css files located in ```\dist``` directory.
```html```
2.Create a new magic marker
```js
var magicMarker = new L.marker.magic([51.55, -0.09], {
iconUrl: './img/magicIcon.png',
magic: 'vanishIn'
})
```
## Options| Option | Description | Default Value | Required |
| --------------- | ------------------------ | -------------- | ----------- |
| iconUrl | The URL to the icon image| null | no |
| magic | Animation type | null | yes |Other options inherited from leaflet [Icon](http://leafletjs.com/reference-1.0.2.html#icon)
## Leaflet Version
Requires Leaflet 1.0.2 or newer## Thanks
leaflet.magicMarker is base on [magic animations](https://github.com/miniMAC/magic).## License
MIT.