-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
47 additions
and
33 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/** | ||
* jQuery ddYMap Plugin | ||
* @version 1.1 (2014-03-16) | ||
* | ||
* @desc A jQuery library that allows Yandex.Maps to be rendered on a page in a simple way. | ||
* | ||
* @uses jQuery 1.10.2. | ||
* @uses Yandex.Maps 2.0-stable. | ||
* | ||
* Parameters of the “$.fn.ddYMap” method (transferred as plain object). | ||
* @param latLng {array} - Comma separated longitude and latitude. @required | ||
* @param zoom {integer} - Default map zoom. Default: 15. | ||
* @param defaultType {'map'; 'satellite'; 'hybrid'; 'publicMap'; 'publicMapHybrid'} - Default map type: 'map' — schematic map, 'satellite' — satellite map, 'hybrid' — hybrid map, 'publicMap' — public map, 'publicMapHybrid' - hybrid public map. Default: 'map'; | ||
* @param scrollZoom {boolean} - Allow zoom while scrolling. Default: false. | ||
* @param placemarkOptions {plain object} - Placemark options. Default: {}. | ||
* | ||
* @link http://code.divandesign.biz/jquery/ddymap/1.1 | ||
* | ||
* @copyright 2014, DivanDesign | ||
* http://www.DivanDesign.biz | ||
*/ | ||
|
||
(function(b){b.extend(!0,{ddYMap:{defaults:{latLng:[],element:"map",zoom:15,defaultType:"map",scrollZoom:!1,placemarkOptions:{}},init:function(a){a=b.extend({},this.defaults,a);b.isArray(a.latLng)&&2==a.latLng.length&&ymaps.ready(function(){var b=new ymaps.Map(a.element,{center:a.latLng,zoom:a.zoom,type:"yandex#"+a.defaultType});b.controls.add("zoomControl").add("typeSelector").add("scaleLine").add("mapTools");a.scrollZoom&&b.behaviors.enable("scrollZoom");b.geoObjects.add(new ymaps.Placemark(a.latLng, | ||
{},a.placemarkOptions))})}}});b.fn.ddYMap=function(a){var c=b.ddYMap;return b(this).each(function(){c.init(b.extend(a,{element:b(this).get(0)}))})}})(jQuery); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters