<static-openstreetmap>
<static-openstreetmap>
is a Polymer Element that displays a static map (using OpenStreetMap) of
a provided address or a set of geographic coordinates.
Maintained by Marcin Warpechowski, Tomek Wytrębowicz.
Usage Policy
Please note that by default we use OpenStreetMap API at donated servers. So you should consider API usage policy, and Nominatim usage policy.
Demo
Usage
-
Import Web Components' polyfill:
<script src="//cdnjs.cloudflare.com/ajax/libs/polymer/0.2.0/platform.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/polymer/0.2.0/polymer.js"></script>
-
Import Custom Element:
<link rel="import" href="src/static-openstreetmap.html">
-
Start using it!
<static-openstreetmap></static-openstreetmap>
Options
query
or lat
,lng
set is required.
Attribute | Options | Default | Description |
---|---|---|---|
query |
string | Address to search for. | |
width |
int | 500 |
Image width in px |
height |
int | 355 |
Image height in px |
zoom |
int | 1 |
Zoom |
lat |
int | 0 |
Latitude |
lng |
int | 0 |
Longitude |
Contributing
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -m 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D
History
For detailed changelog, check Releases.
License
Cusom Element is distributed under MIT style LICENSE. Maps are provideded under Open Database License