{"version":3,"sources":["kendo.dataviz.map.js"],"names":["f","define","$","normalizeText","text","String","replace","REPLACE_REGEX","SPACE","objectKey","object","key","parts","push","sort","join","hashKey","str","i","hash","length","charCodeAt","zeroSize","width","height","baseline","measureText","style","measureBox","TextMetrics","current","measure","LRUCache","DEFAULT_OPTIONS","defaultMeasureBox","window","kendo","util","Class","extend","init","size","this","_size","_length","_map","put","value","map","entry","_head","_tail","newer","older","get","baselineMarkerSize","document","createElement","cssText","options","_cache","styleKey","cacheKey","cachedResult","baselineMarker","textStr","box","_baselineMarker","cloneNode","textContent","appendChild","body","offsetWidth","offsetHeight","offsetTop","parentNode","removeChild","marker","deepExtend","jQuery","amd","a1","a2","a3","sqr","renderSize","renderPos","pos","result","toHyphens","split","arabicToRoman","n","literals","1","10","100","2","20","200","3","30","300","4","40","400","5","50","500","6","60","600","7","70","700","8","80","800","9","90","900","1000","values","roman","shift","romanToArabic","r","digits","prev","v","toLowerCase","x","l","c","d","m","charAt","memoize","cache","Object","create","id","arguments","apply","isUnicodeLetter","ch","RX_UNICODE_LETTER","test","withExit","obj","Return","call","ex","now","Date","getTime","RegExp","undefined","Extent","math","Math","abs","atan","atan2","cos","max","min","sin","tan","dataviz","drawing","defined","deg","rad","round","valueOrDefault","Location","lat","lng","DISTANCE_ITERATIONS","DISTANCE_CONVERGENCE","DISTANCE_PRECISION","FORMAT","toArray","equals","loc","clone","precision","wrap","distanceTo","dest","datum","greatCircleTo","distance","destination","bearing","fromLat","fromLng","dToR","datums","WGS84","a","asin","b","L","U1","sinU1","cosU1","U2","sinU2","cosU2","lambda","prevLambda","converged","sinLambda","cosLambda","sino","cosA2","coso","cos2om","sigma","sinA","C","u2","A","B","deltao","azimuthFrom","azimuthTo","sqrt","fn","toString","format","fromLngLat","ll","fromLatLng","nw","se","contains","center","containsAny","locs","include","includeAll","edges","ne","sw","overlaps","extent","World","Widget","ui","template","Attribution","element","_initOptions","items","addClass","name","separator","itemTemplate","filter","zoom","_extent","_zoom","_render","add","item","remove","clear","empty","_itemText","append","show","hide","inZoomLevel","_inZoomLevel","minZoom","maxZoom","inArea","_inArea","Number","MAX_VALUE","area","plugin","button","dir","keys","proxy","NS","BUTTONS","Navigator","on","parentElement","parent","closest","attr","_keyroot","_tabindex","_keydown","panStep","events","dispose","off","_pan","y","trigger","_click","e","currentTarget","is","preventDefault","which","UP","DOWN","RIGHT","LEFT","iconClass","PLUS","MINUS","FF_PLUS","FF_MINUS","ZoomControl","zoomStep","_change","delta","NUMPAD_PLUS","NUMPAD_MINUS","exp","pow","log","g","geometry","Point","limit","limitValue","PI","PI_DIV_2","PI_DIV_4","DEG_TO_RAD","Mercator","MAX_LNG","MAX_LAT","INVERSE_ITERATIONS","INVERSE_CONVERGENCE","centralMeridian","forward","clamp","proj","lng0","_projectLat","ecc","ts","con","p","inverse","point","_inverseY","dphi","ecch","phi","SphericalMercator","Equirectangular","EPSG3857","crs","_proj","_tm","transform","translate","scale","_itm","toPoint","toLocation","EPSG3395","EPSG4326","projections","Layer","css","zIndex","opacity","appendTo","scrollElement","_beforeReset","_reset","_resize","_panEnd","_activate","_updateAttribution","destroy","_deactivate","reset","_applyExtent","_setVisibility","noop","matchMinZoom","matchMaxZoom","inside","visible","bind","unbind","attribution","layers","DataSource","data","Group","last","ShapeLayer","surface","Surface","_initRoot","movable","Movable","_markers","_handler","_mouseenter","_mouseleave","_initDataSource","autoBind","dataSource","_dataChange","setDataSource","fetch","_translateSurface","_data","_load","_root","draw","dsOptions","sender","view","container","shape","_clearMarkers","_loader","GeoJSONLoader","parse","shapeCreated","args","cancelled","Circle","_createMarker","layer","featureCreated","markers","location","dataItem","_panning","suspendTracking","resumeTracking","locationToView","moveTo","event","originalEvent","locator","defaultStyle","observer","root","unwrap","type","_loadGeometryTo","_featureCreated","children","_shapeCreated","group","properties","path","coords","coordinates","_loadPolygon","_setLineFill","_loadPoint","segments","anchor","fill","_loadShape","rings","_buildPolygon","j","MultiPath","Path","lineTo","circle","schemas","geojson","features","geometries","transports","read","dataType","getter","BubbleLayer","locationField","valueField","minSize","maxSize","symbol","opt","getValue","scaleType","slice","_scaleType","_createSymbol","_drawSymbol","isFunction","scales","symbols","SqrtScale","domain","range","domainRange","outputRange","_domain","_range","_ratio","rel","Symbols","geo","square","halfSize","close","bubble","roundPoint","drawingUtil","TileLayer","subdomains","viewType","_viewType","_view","origin","locationToLayer","viewOrigin","_updateView","TileView","support","mobileOS","throttle","extentToPoint","render","pool","TilePool","tileSize","urlTemplate","_center","_viewOrigin","pointToTileIndex","floor","tileCount","firstTileIndex","indexToPoint","ceil","diff","index","subdomainText","subdomainIndex","tile","createTile","currentIndex","tileOptions","wrapIndex","offset","subdomain","errorUrlTemplate","boundary","wrapValue","remainder","ImageTile","errorUrl","target","setAttribute","removeAttribute","url","top","left","visibility","urlResult","urlOptions","z","s","quadkey","q","culture","_items","_remove","_create","dist","maxDist","splice","BingLayer","baseUrl","_scheme","_onMetadata","_fetchMetadata","imagerySet","Error","ajax","output","uriScheme","jsonp","success","proto","protocol","resource","resourceSets","resources","imageUrl","imageUrlSubdomains","zoomMin","zoomMax","_addAttribution","BingView","imageryProviders","coverageAreas","bbox","tileQuadKey","digit","mask","quadKey","bing","doc","indexOf","inArray","Tooltip","MarkerLayer","_markerClick","titleField","arg","isArray","_addOne","update","showAt","Marker","addTo","getLocation","getTitle","title","tooltip","popup","_position","attributes","renderTooltip","contentTemplate","content","contentUrl","defaults","CSS_PREFIX","FRICTION","FRICTION_MOBILE","MOUSEWHEEL","VELOCITY_MULTIPLIER","DEFAULT_ZOOM_RATE","Map","_getOrigin","_initScroller","_initMarkers","_initControls","_initLayers","_mousewheel","controls","navigator","layerDefaults","color","stroke","position","markerDefaults","wraparound","scroller","zoomControl","level","_setExtent","_getExtent","setOptions","_layerSize","layerToLocation","translateWith","viewToLocation","eventOffset","field","pageX","clientX","pageY","clientY","eventToView","cursor","eventToLayer","eventToLocation","viewSize","exportVisual","_setOrigin","topLeft","_origin","invalidate","bottomRight","layerWidth","layerHeight","raw","_zoomAround","pivot","_createAttribution","_createNavigator","_createZoomControl","_createControlElement","defaultPos","posSelector","_navigatorPan","_navigatorCenter","scrollLeft","scrollTop","bounds","_virtualSize","one","_scrollEnd","scrollTo","_zoomControlChange","friction","zoomable","mobile","Scroller","velocityMultiplier","mousewheelScrolling","supportDoubleTap","_scroll","userEvents","_scaleStart","_scale","_doubleTap","_tap","impl","defs","_scrollOffset","_panComplete","_panEndTS","touch","touches","cancel","_scaleToZoom","gestureCenter","centerLocation","centerPoint","originPoint","scaleDelta","tiles","_resetScroller","xBounds","yBounds","dimensions","forcedMinScale","maxScale","pannable","makeVirtual","virtualSize","_renderLayers","scrollWrap","toZoom","postZoom","fromZoom","mwDelta"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;CAwBC,SAAUA,EAAGC,QACVA,OAAO,qBAAsB,cAAeD,IAC9C,YACG,SAAUE,GAqDP,QAASC,GAAcC,GACnB,OAAcA,EAAPC,IAAaC,QAAQC,EAAeC,GAE/C,QAASC,GAAUC,GAAnB,GAEaC,GADLC,IACJ,KAASD,IAAOD,GACZE,EAAMC,KAAKF,EAAMD,EAAOC,GAE5B,OAAOC,GAAME,OAAOC,KAAK,IAE7B,QAASC,GAAQC,GAAjB,GAEaC,GADLC,EAAO,UACX,KAASD,EAAI,EAAGA,EAAID,EAAIG,SAAUF,EAC9BC,IAASA,GAAQ,IAAMA,GAAQ,IAAMA,GAAQ,IAAMA,GAAQ,IAAMA,GAAQ,IACzEA,GAAQF,EAAII,WAAWH,EAE3B,OAAOC,KAAS,EAEpB,QAASG,KACL,OACIC,MAAO,EACPC,OAAQ,EACRC,SAAU,GA0DlB,QAASC,GAAYtB,EAAMuB,EAAOC,GAC9B,MAAOC,GAAYC,QAAQC,QAAQ3B,EAAMuB,EAAOC,GAtIvD,GAEOI,GAiDAzB,EACAC,EA0BAyB,EACAC,EAKAL,CAnFJM,QAAOC,MAAMC,KAAOF,OAAOC,MAAMC,SAC7BL,EAAWI,MAAME,MAAM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O+E,IAAM/E,OAAS,SAAUgF,EAAIC,EAAIC,IACrEA,GAAMD,OAEV,SAAUlF,EAAGC,QACVA,OAAO,qBACH,aACA,mBACA,gBACA,wBACA,oBACA,qBACA,uBACA,0BACA,wBACA,mBACA,kBACA,0BACA,2BACA,4BACA,0BACA,0BACA,4BACA,oBACDD,IACL,WAeE,MAAOmC,QAAOC,OACE,kBAAVnC,SAAwBA,OAAO+E,IAAM/E,OAAS,SAAUgF,EAAIC,EAAIC,IACrEA,GAAMD","file":"kendo.dataviz.map.min.js","sourcesContent":["/*!\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n*/\n(function (f, define) {\n define('util/text-metrics', ['kendo.core'], f);\n}(function () {\n (function ($) {\n window.kendo.util = window.kendo.util || {};\n var LRUCache = kendo.Class.extend({\n init: function (size) {\n this._size = size;\n this._length = 0;\n this._map = {};\n },\n put: function (key, value) {\n var map = this._map;\n var entry = {\n key: key,\n value: value\n };\n map[key] = entry;\n if (!this._head) {\n this._head = this._tail = entry;\n } else {\n this._tail.newer = entry;\n entry.older = this._tail;\n this._tail = entry;\n }\n if (this._length >= this._size) {\n map[this._head.key] = null;\n this._head = this._head.newer;\n this._head.older = null;\n } else {\n this._length++;\n }\n },\n get: function (key) {\n var entry = this._map[key];\n if (entry) {\n if (entry === this._head && entry !== this._tail) {\n this._head = entry.newer;\n this._head.older = null;\n }\n if (entry !== this._tail) {\n if (entry.older) {\n entry.older.newer = entry.newer;\n entry.newer.older = entry.older;\n }\n entry.older = this._tail;\n entry.newer = null;\n this._tail.newer = entry;\n this._tail = entry;\n }\n return entry.value;\n }\n }\n });\n var REPLACE_REGEX = /\\r?\\n|\\r|\\t/g;\n var SPACE = ' ';\n function normalizeText(text) {\n return String(text).replace(REPLACE_REGEX, SPACE);\n }\n function objectKey(object) {\n var parts = [];\n for (var key in object) {\n parts.push(key + object[key]);\n }\n return parts.sort().join('');\n }\n function hashKey(str) {\n var hash = 2166136261;\n for (var i = 0; i < str.length; ++i) {\n hash += (hash << 1) + (hash << 4) + (hash << 7) + (hash << 8) + (hash << 24);\n hash ^= str.charCodeAt(i);\n }\n return hash >>> 0;\n }\n function zeroSize() {\n return {\n width: 0,\n height: 0,\n baseline: 0\n };\n }\n var DEFAULT_OPTIONS = { baselineMarkerSize: 1 };\n var defaultMeasureBox;\n if (typeof document !== 'undefined') {\n defaultMeasureBox = document.createElement('div');\n defaultMeasureBox.style.cssText = 'position: absolute !important; top: -4000px !important; width: auto !important; height: auto !important;' + 'padding: 0 !important; margin: 0 !important; border: 0 !important;' + 'line-height: normal !important; visibility: hidden !important; white-space: pre!important;';\n }\n var TextMetrics = kendo.Class.extend({\n init: function (options) {\n this._cache = new LRUCache(1000);\n this.options = $.extend({}, DEFAULT_OPTIONS, options);\n },\n measure: function (text, style, options) {\n if (options === void 0) {\n options = {};\n }\n if (!text) {\n return zeroSize();\n }\n var styleKey = objectKey(style);\n var cacheKey = hashKey(text + styleKey);\n var cachedResult = this._cache.get(cacheKey);\n if (cachedResult) {\n return cachedResult;\n }\n var size = zeroSize();\n var measureBox = options.box || defaultMeasureBox;\n var baselineMarker = this._baselineMarker().cloneNode(false);\n for (var key in style) {\n var value = style[key];\n if (typeof value !== 'undefined') {\n measureBox.style[key] = value;\n }\n }\n var textStr = options.normalizeText !== false ? normalizeText(text) : String(text);\n measureBox.textContent = textStr;\n measureBox.appendChild(baselineMarker);\n document.body.appendChild(measureBox);\n if (textStr.length) {\n size.width = measureBox.offsetWidth - this.options.baselineMarkerSize;\n size.height = measureBox.offsetHeight;\n size.baseline = baselineMarker.offsetTop + this.options.baselineMarkerSize;\n }\n if (size.width > 0 && size.height > 0) {\n this._cache.put(cacheKey, size);\n }\n measureBox.parentNode.removeChild(measureBox);\n return size;\n },\n _baselineMarker: function () {\n var marker = document.createElement('div');\n marker.style.cssText = 'display: inline-block; vertical-align: baseline;width: ' + this.options.baselineMarkerSize + 'px; height: ' + this.options.baselineMarkerSize + 'px;overflow: hidden;';\n return marker;\n }\n });\n TextMetrics.current = new TextMetrics();\n function measureText(text, style, measureBox) {\n return TextMetrics.current.measure(text, style, measureBox);\n }\n kendo.deepExtend(kendo.util, {\n LRUCache: LRUCache,\n TextMetrics: TextMetrics,\n measureText: measureText,\n objectKey: objectKey,\n hashKey: hashKey,\n normalizeText: normalizeText\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('util/main', ['kendo.core'], f);\n}(function () {\n (function () {\n var kendo = window.kendo, deepExtend = kendo.deepExtend;\n function sqr(value) {\n return value * value;\n }\n var now = Date.now;\n if (!now) {\n now = function () {\n return new Date().getTime();\n };\n }\n function renderSize(size) {\n if (typeof size !== 'string') {\n size += 'px';\n }\n return size;\n }\n function renderPos(pos) {\n var result = [];\n if (pos) {\n var parts = kendo.toHyphens(pos).split('-');\n for (var i = 0; i < parts.length; i++) {\n result.push('k-pos-' + parts[i]);\n }\n }\n return result.join(' ');\n }\n function arabicToRoman(n) {\n var literals = {\n 1: 'i',\n 10: 'x',\n 100: 'c',\n 2: 'ii',\n 20: 'xx',\n 200: 'cc',\n 3: 'iii',\n 30: 'xxx',\n 300: 'ccc',\n 4: 'iv',\n 40: 'xl',\n 400: 'cd',\n 5: 'v',\n 50: 'l',\n 500: 'd',\n 6: 'vi',\n 60: 'lx',\n 600: 'dc',\n 7: 'vii',\n 70: 'lxx',\n 700: 'dcc',\n 8: 'viii',\n 80: 'lxxx',\n 800: 'dccc',\n 9: 'ix',\n 90: 'xc',\n 900: 'cm',\n 1000: 'm'\n };\n var values = [\n 1000,\n 900,\n 800,\n 700,\n 600,\n 500,\n 400,\n 300,\n 200,\n 100,\n 90,\n 80,\n 70,\n 60,\n 50,\n 40,\n 30,\n 20,\n 10,\n 9,\n 8,\n 7,\n 6,\n 5,\n 4,\n 3,\n 2,\n 1\n ];\n var roman = '';\n while (n > 0) {\n if (n < values[0]) {\n values.shift();\n } else {\n roman += literals[values[0]];\n n -= values[0];\n }\n }\n return roman;\n }\n function romanToArabic(r) {\n r = r.toLowerCase();\n var digits = {\n i: 1,\n v: 5,\n x: 10,\n l: 50,\n c: 100,\n d: 500,\n m: 1000\n };\n var value = 0, prev = 0;\n for (var i = 0; i < r.length; ++i) {\n var v = digits[r.charAt(i)];\n if (!v) {\n return null;\n }\n value += v;\n if (v > prev) {\n value -= 2 * prev;\n }\n prev = v;\n }\n return value;\n }\n function memoize(f) {\n var cache = Object.create(null);\n return function () {\n var id = '';\n for (var i = arguments.length; --i >= 0;) {\n id += ':' + arguments[i];\n }\n return id in cache ? cache[id] : cache[id] = f.apply(this, arguments);\n };\n }\n function isUnicodeLetter(ch) {\n return RX_UNICODE_LETTER.test(ch);\n }\n function withExit(f, obj) {\n try {\n return f.call(obj, function (value) {\n throw new Return(value);\n });\n } catch (ex) {\n if (ex instanceof Return) {\n return ex.value;\n }\n throw ex;\n }\n function Return(value) {\n this.value = value;\n }\n }\n deepExtend(kendo, {\n util: {\n now: now,\n renderPos: renderPos,\n renderSize: renderSize,\n sqr: sqr,\n romanToArabic: romanToArabic,\n arabicToRoman: arabicToRoman,\n memoize: memoize,\n isUnicodeLetter: isUnicodeLetter,\n withExit: withExit\n }\n });\n var RX_UNICODE_LETTER = new RegExp('[\\\\u0041-\\\\u005A\\\\u0061-\\\\u007A\\\\u00AA\\\\u00B5\\\\u00BA\\\\u00C0-\\\\u00D6\\\\u00D8-\\\\u00F6\\\\u00F8-\\\\u02C1\\\\u02C6-\\\\u02D1\\\\u02E0-\\\\u02E4\\\\u02EC\\\\u02EE\\\\u0370-\\\\u0374\\\\u0376\\\\u0377\\\\u037A-\\\\u037D\\\\u037F\\\\u0386\\\\u0388-\\\\u038A\\\\u038C\\\\u038E-\\\\u03A1\\\\u03A3-\\\\u03F5\\\\u03F7-\\\\u0481\\\\u048A-\\\\u052F\\\\u0531-\\\\u0556\\\\u0559\\\\u0561-\\\\u0587\\\\u05D0-\\\\u05EA\\\\u05F0-\\\\u05F2\\\\u0620-\\\\u064A\\\\u066E\\\\u066F\\\\u0671-\\\\u06D3\\\\u06D5\\\\u06E5\\\\u06E6\\\\u06EE\\\\u06EF\\\\u06FA-\\\\u06FC\\\\u06FF\\\\u0710\\\\u0712-\\\\u072F\\\\u074D-\\\\u07A5\\\\u07B1\\\\u07CA-\\\\u07EA\\\\u07F4\\\\u07F5\\\\u07FA\\\\u0800-\\\\u0815\\\\u081A\\\\u0824\\\\u0828\\\\u0840-\\\\u0858\\\\u08A0-\\\\u08B2\\\\u0904-\\\\u0939\\\\u093D\\\\u0950\\\\u0958-\\\\u0961\\\\u0971-\\\\u0980\\\\u0985-\\\\u098C\\\\u098F\\\\u0990\\\\u0993-\\\\u09A8\\\\u09AA-\\\\u09B0\\\\u09B2\\\\u09B6-\\\\u09B9\\\\u09BD\\\\u09CE\\\\u09DC\\\\u09DD\\\\u09DF-\\\\u09E1\\\\u09F0\\\\u09F1\\\\u0A05-\\\\u0A0A\\\\u0A0F\\\\u0A10\\\\u0A13-\\\\u0A28\\\\u0A2A-\\\\u0A30\\\\u0A32\\\\u0A33\\\\u0A35\\\\u0A36\\\\u0A38\\\\u0A39\\\\u0A59-\\\\u0A5C\\\\u0A5E\\\\u0A72-\\\\u0A74\\\\u0A85-\\\\u0A8D\\\\u0A8F-\\\\u0A91\\\\u0A93-\\\\u0AA8\\\\u0AAA-\\\\u0AB0\\\\u0AB2\\\\u0AB3\\\\u0AB5-\\\\u0AB9\\\\u0ABD\\\\u0AD0\\\\u0AE0\\\\u0AE1\\\\u0B05-\\\\u0B0C\\\\u0B0F\\\\u0B10\\\\u0B13-\\\\u0B28\\\\u0B2A-\\\\u0B30\\\\u0B32\\\\u0B33\\\\u0B35-\\\\u0B39\\\\u0B3D\\\\u0B5C\\\\u0B5D\\\\u0B5F-\\\\u0B61\\\\u0B71\\\\u0B83\\\\u0B85-\\\\u0B8A\\\\u0B8E-\\\\u0B90\\\\u0B92-\\\\u0B95\\\\u0B99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u10C5\\\\u10C7\\\\u10CD\\\\u10D0-\\\\u10FA\\\\u10FC-\\\\u1248\\\\u124A-\\\\u124D\\\\u1250-\\\\u1256\\\\u1258\\\\u125A-\\\\u125D\\\\u1260-\\\\u1288\\\\u128A-\\\\u128D\\\\u1290-\\\\u12B0\\\\u12B2-\\\\u12B5\\\\u12B8-\\\\u12BE\\\\u12C0\\\\u12C2-\\\\u12C5\\\\u12C8-\\\\u12D6\\\\u12D8-\\\\u1310\\\\u1312-\\\\u1315\\\\u1318-\\\\u135A\\\\u1380-\\\\u138F\\\\u13A0-\\\\u13F4\\\\u1401-\\\\u166C\\\\u166F-\\\\u167F\\\\u1681-\\\\u169A\\\\u16A0-\\\\u16EA\\\\u16EE-\\\\u16F8\\\\u1700-\\\\u170C\\\\u170E-\\\\u1711\\\\u1720-\\\\u1731\\\\u1740-\\\\u1751\\\\u1760-\\\\u176C\\\\u176E-\\\\u1770\\\\u1780-\\\\u17B3\\\\u17D7\\\\u17DC\\\\u1820-\\\\u1877\\\\u1880-\\\\u18A8\\\\u18AA\\\\u18B0-\\\\u18F5\\\\u1900-\\\\u191E\\\\u1950-\\\\u196D\\\\u1970-\\\\u1974\\\\u1980-\\\\u19AB\\\\u19C1-\\\\u19C7\\\\u1A00-\\\\u1A16\\\\u1A20-\\\\u1A54\\\\u1AA7\\\\u1B05-\\\\u1B33\\\\u1B45-\\\\u1B4B\\\\u1B83-\\\\u1BA0\\\\u1BAE\\\\u1BAF\\\\u1BBA-\\\\u1BE5\\\\u1C00-\\\\u1C23\\\\u1C4D-\\\\u1C4F\\\\u1C5A-\\\\u1C7D\\\\u1CE9-\\\\u1CEC\\\\u1CEE-\\\\u1CF1\\\\u1CF5\\\\u1CF6\\\\u1D00-\\\\u1DBF\\\\u1E00-\\\\u1F15\\\\u1F18-\\\\u1F1D\\\\u1F20-\\\\u1F45\\\\u1F48-\\\\u1F4D\\\\u1F50-\\\\u1F57\\\\u1F59\\\\u1F5B\\\\u1F5D\\\\u1F5F-\\\\u1F7D\\\\u1F80-\\\\u1FB4\\\\u1FB6-\\\\u1FBC\\\\u1FBE\\\\u1FC2-\\\\u1FC4\\\\u1FC6-\\\\u1FCC\\\\u1FD0-\\\\u1FD3\\\\u1FD6-\\\\u1FDB\\\\u1FE0-\\\\u1FEC\\\\u1FF2-\\\\u1FF4\\\\u1FF6-\\\\u1FFC\\\\u2071\\\\u207F\\\\u2090-\\\\u209C\\\\u2102\\\\u2107\\\\u210A-\\\\u2113\\\\u2115\\\\u2119-\\\\u211D\\\\u2124\\\\u2126\\\\u2128\\\\u212A-\\\\u212D\\\\u212F-\\\\u2139\\\\u213C-\\\\u213F\\\\u2145-\\\\u2149\\\\u214E\\\\u2160-\\\\u2188\\\\u2C00-\\\\u2C2E\\\\u2C30-\\\\u2C5E\\\\u2C60-\\\\u2CE4\\\\u2CEB-\\\\u2CEE\\\\u2CF2\\\\u2CF3\\\\u2D00-\\\\u2D25\\\\u2D27\\\\u2D2D\\\\u2D30-\\\\u2D67\\\\u2D6F\\\\u2D80-\\\\u2D96\\\\u2DA0-\\\\u2DA6\\\\u2DA8-\\\\u2DAE\\\\u2DB0-\\\\u2DB6\\\\u2DB8-\\\\u2DBE\\\\u2DC0-\\\\u2DC6\\\\u2DC8-\\\\u2DCE\\\\u2DD0-\\\\u2DD6\\\\u2DD8-\\\\u2DDE\\\\u2E2F\\\\u3005-\\\\u3007\\\\u3021-\\\\u3029\\\\u3031-\\\\u3035\\\\u3038-\\\\u303C\\\\u3041-\\\\u3096\\\\u309D-\\\\u309F\\\\u30A1-\\\\u30FA\\\\u30FC-\\\\u30FF\\\\u3105-\\\\u312D\\\\u3131-\\\\u318E\\\\u31A0-\\\\u31BA\\\\u31F0-\\\\u31FF\\\\u3400-\\\\u4DB5\\\\u4E00-\\\\u9FCC\\\\uA000-\\\\uA48C\\\\uA4D0-\\\\uA4FD\\\\uA500-\\\\uA60C\\\\uA610-\\\\uA61F\\\\uA62A\\\\uA62B\\\\uA640-\\\\uA66E\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FD8F\\\\uFD92-\\\\uFDC7\\\\uFDF0-\\\\uFDFB\\\\uFE70-\\\\uFE74\\\\uFE76-\\\\uFEFC\\\\uFF21-\\\\uFF3A\\\\uFF41-\\\\uFF5A\\\\uFF66-\\\\uFFBE\\\\uFFC2-\\\\uFFC7\\\\uFFCA-\\\\uFFCF\\\\uFFD2-\\\\uFFD7\\\\uFFDA-\\\\uFFDC]');\n }());\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/location', [\n 'kendo.drawing',\n 'util/main'\n ], f);\n}(function () {\n (function ($, undefined) {\n var math = Math, abs = math.abs, atan = math.atan, atan2 = math.atan2, cos = math.cos, max = math.max, min = math.min, sin = math.sin, tan = math.tan, kendo = window.kendo, Class = kendo.Class, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, util = kendo.drawing.util, defined = util.defined, deg = util.deg, rad = util.rad, round = util.round, valueOrDefault = util.valueOrDefault, sqr = kendo.util.sqr;\n var Location = Class.extend({\n init: function (lat, lng) {\n if (arguments.length === 1) {\n this.lat = lat[0];\n this.lng = lat[1];\n } else {\n this.lat = lat;\n this.lng = lng;\n }\n },\n DISTANCE_ITERATIONS: 100,\n DISTANCE_CONVERGENCE: 1e-12,\n DISTANCE_PRECISION: 2,\n FORMAT: '{0:N6},{1:N6}',\n toArray: function () {\n return [\n this.lat,\n this.lng\n ];\n },\n equals: function (loc) {\n return loc && loc.lat === this.lat && loc.lng === this.lng;\n },\n clone: function () {\n return new Location(this.lat, this.lng);\n },\n round: function (precision) {\n this.lng = round(this.lng, precision);\n this.lat = round(this.lat, precision);\n return this;\n },\n wrap: function () {\n this.lng = this.lng % 180;\n this.lat = this.lat % 90;\n return this;\n },\n distanceTo: function (dest, datum) {\n return this.greatCircleTo(dest, datum).distance;\n },\n destination: function (distance, bearing, datum) {\n bearing = rad(bearing);\n datum = datum || dataviz.map.datums.WGS84;\n var fromLat = rad(this.lat);\n var fromLng = rad(this.lng);\n var dToR = distance / kendo.dataviz.map.datums.WGS84.a;\n var lat = math.asin(sin(fromLat) * cos(dToR) + cos(fromLat) * sin(dToR) * cos(bearing));\n var lng = fromLng + atan2(sin(bearing) * sin(dToR) * cos(fromLat), cos(dToR) - sin(fromLat) * sin(lat));\n return new Location(deg(lat), deg(lng));\n },\n greatCircleTo: function (dest, datum) {\n dest = Location.create(dest);\n datum = datum || dataviz.map.datums.WGS84;\n if (!dest || this.clone().round(8).equals(dest.clone().round(8))) {\n return {\n distance: 0,\n azimuthFrom: 0,\n azimuthTo: 0\n };\n }\n var a = datum.a;\n var b = datum.b;\n var f = datum.f;\n var L = rad(dest.lng - this.lng);\n var U1 = atan((1 - f) * tan(rad(this.lat)));\n var sinU1 = sin(U1);\n var cosU1 = cos(U1);\n var U2 = atan((1 - f) * tan(rad(dest.lat)));\n var sinU2 = sin(U2);\n var cosU2 = cos(U2);\n var lambda = L;\n var prevLambda;\n var i = this.DISTANCE_ITERATIONS;\n var converged = false;\n var sinLambda;\n var cosLambda;\n var sino;\n var cosA2;\n var coso;\n var cos2om;\n var sigma;\n while (!converged && i-- > 0) {\n sinLambda = sin(lambda);\n cosLambda = cos(lambda);\n sino = math.sqrt(sqr(cosU2 * sinLambda) + sqr(cosU1 * sinU2 - sinU1 * cosU2 * cosLambda));\n coso = sinU1 * sinU2 + cosU1 * cosU2 * cosLambda;\n sigma = atan2(sino, coso);\n var sinA = cosU1 * cosU2 * sinLambda / sino;\n cosA2 = 1 - sqr(sinA);\n cos2om = 0;\n if (cosA2 !== 0) {\n cos2om = coso - 2 * sinU1 * sinU2 / cosA2;\n }\n prevLambda = lambda;\n var C = f / 16 * cosA2 * (4 + f * (4 - 3 * cosA2));\n lambda = L + (1 - C) * f * sinA * (sigma + C * sino * (cos2om + C * coso * (-1 + 2 * sqr(cos2om))));\n converged = abs(lambda - prevLambda) <= this.DISTANCE_CONVERGENCE;\n }\n var u2 = cosA2 * (sqr(a) - sqr(b)) / sqr(b);\n var A = 1 + u2 / 16384 * (4096 + u2 * (-768 + u2 * (320 - 175 * u2)));\n var B = u2 / 1024 * (256 + u2 * (-128 + u2 * (74 - 47 * u2)));\n var deltao = B * sino * (cos2om + B / 4 * (coso * (-1 + 2 * sqr(cos2om)) - B / 6 * cos2om * (-3 + 4 * sqr(sino)) * (-3 + 4 * sqr(cos2om))));\n var azimuthFrom = atan2(cosU2 * sinLambda, cosU1 * sinU2 - sinU1 * cosU2 * cosLambda);\n var azimuthTo = atan2(cosU1 * sinLambda, -sinU1 * cosU2 + cosU1 * sinU2 * cosLambda);\n return {\n distance: round(b * A * (sigma - deltao), this.DISTANCE_PRECISION),\n azimuthFrom: deg(azimuthFrom),\n azimuthTo: deg(azimuthTo)\n };\n }\n });\n Location.fn.toString = function () {\n return kendo.format(this.FORMAT, this.lat, this.lng);\n };\n Location.fromLngLat = function (ll) {\n return new Location(ll[1], ll[0]);\n };\n Location.fromLatLng = function (ll) {\n return new Location(ll[0], ll[1]);\n };\n Location.create = function (a, b) {\n if (defined(a)) {\n if (a instanceof Location) {\n return a.clone();\n } else if (arguments.length === 1 && a.length === 2) {\n return Location.fromLatLng(a);\n } else {\n return new Location(a, b);\n }\n }\n };\n var Extent = Class.extend({\n init: function (nw, se) {\n nw = Location.create(nw);\n se = Location.create(se);\n if (nw.lng + 180 > se.lng + 180 && nw.lat + 90 < se.lat + 90) {\n this.se = nw;\n this.nw = se;\n } else {\n this.se = se;\n this.nw = nw;\n }\n },\n contains: function (loc) {\n var nw = this.nw, se = this.se, lng = valueOrDefault(loc.lng, loc[1]), lat = valueOrDefault(loc.lat, loc[0]);\n return loc && lng + 180 >= nw.lng + 180 && lng + 180 <= se.lng + 180 && lat + 90 >= se.lat + 90 && lat + 90 <= nw.lat + 90;\n },\n center: function () {\n var nw = this.nw;\n var se = this.se;\n var lng = nw.lng + (se.lng - nw.lng) / 2;\n var lat = nw.lat + (se.lat - nw.lat) / 2;\n return new Location(lat, lng);\n },\n containsAny: function (locs) {\n var result = false;\n for (var i = 0; i < locs.length; i++) {\n result = result || this.contains(locs[i]);\n }\n return result;\n },\n include: function (loc) {\n var nw = this.nw, se = this.se, lng = valueOrDefault(loc.lng, loc[1]), lat = valueOrDefault(loc.lat, loc[0]);\n nw.lng = min(nw.lng, lng);\n nw.lat = max(nw.lat, lat);\n se.lng = max(se.lng, lng);\n se.lat = min(se.lat, lat);\n },\n includeAll: function (locs) {\n for (var i = 0; i < locs.length; i++) {\n this.include(locs[i]);\n }\n },\n edges: function () {\n var nw = this.nw, se = this.se;\n return {\n nw: this.nw,\n ne: new Location(nw.lat, se.lng),\n se: this.se,\n sw: new Location(se.lat, nw.lng)\n };\n },\n toArray: function () {\n var nw = this.nw, se = this.se;\n return [\n nw,\n new Location(nw.lat, se.lng),\n se,\n new Location(se.lat, nw.lng)\n ];\n },\n overlaps: function (extent) {\n return this.containsAny(extent.toArray()) || extent.containsAny(this.toArray());\n }\n });\n Extent.World = new Extent([\n 90,\n -180\n ], [\n -90,\n 180\n ]);\n Extent.create = function (a, b) {\n if (a instanceof Extent) {\n return a;\n } else if (a && b) {\n return new Extent(a, b);\n } else if (a && a.length === 4 && !b) {\n return new Extent([\n a[0],\n a[1]\n ], [\n a[2],\n a[3]\n ]);\n }\n };\n deepExtend(dataviz, {\n map: {\n Extent: Extent,\n Location: Location\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/attribution', ['kendo.drawing'], f);\n}(function () {\n (function () {\n var kendo = window.kendo, Widget = kendo.ui.Widget, template = kendo.template, util = kendo.drawing.util, valueOrDefault = util.valueOrDefault, defined = util.defined;\n var Attribution = Widget.extend({\n init: function (element, options) {\n Widget.fn.init.call(this, element, options);\n this._initOptions(options);\n this.items = [];\n this.element.addClass('k-widget k-attribution');\n },\n options: {\n name: 'Attribution',\n separator: ' | ',\n itemTemplate: '#= text #'\n },\n filter: function (extent, zoom) {\n this._extent = extent;\n this._zoom = zoom;\n this._render();\n },\n add: function (item) {\n if (defined(item)) {\n if (typeof item === 'string') {\n item = { text: item };\n }\n this.items.push(item);\n this._render();\n }\n },\n remove: function (text) {\n var result = [];\n for (var i = 0; i < this.items.length; i++) {\n var item = this.items[i];\n if (item.text !== text) {\n result.push(item);\n }\n }\n this.items = result;\n this._render();\n },\n clear: function () {\n this.items = [];\n this.element.empty();\n },\n _render: function () {\n var result = [];\n var itemTemplate = template(this.options.itemTemplate);\n for (var i = 0; i < this.items.length; i++) {\n var item = this.items[i];\n var text = this._itemText(item);\n if (text !== '') {\n result.push(itemTemplate({ text: text }));\n }\n }\n if (result.length > 0) {\n this.element.empty().append(result.join(this.options.separator)).show();\n } else {\n this.element.hide();\n }\n },\n _itemText: function (item) {\n var text = '';\n var inZoomLevel = this._inZoomLevel(item.minZoom, item.maxZoom);\n var inArea = this._inArea(item.extent);\n if (inZoomLevel && inArea) {\n text += item.text;\n }\n return text;\n },\n _inZoomLevel: function (min, max) {\n var result = true;\n min = valueOrDefault(min, -Number.MAX_VALUE);\n max = valueOrDefault(max, Number.MAX_VALUE);\n result = this._zoom > min && this._zoom < max;\n return result;\n },\n _inArea: function (area) {\n var result = true;\n if (area) {\n result = area.contains(this._extent);\n }\n return result;\n }\n });\n kendo.dataviz.ui.plugin(Attribution);\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/navigator', ['kendo.core'], f);\n}(function () {\n (function ($) {\n var kendo = window.kendo;\n var Widget = kendo.ui.Widget;\n var keys = kendo.keys;\n var proxy = $.proxy;\n var NS = '.kendoNavigator';\n function button(dir) {\n return kendo.format('', dir);\n }\n var BUTTONS = button('up') + button('right') + button('down') + button('left');\n var Navigator = Widget.extend({\n init: function (element, options) {\n Widget.fn.init.call(this, element, options);\n this._initOptions(options);\n this.element.addClass('k-widget k-navigator').append(BUTTONS).on('click' + NS, '.k-button', proxy(this, '_click'));\n var parentElement = this.element.parent().closest('[' + kendo.attr('role') + ']');\n this._keyroot = parentElement.length > 0 ? parentElement : this.element;\n this._tabindex(this._keyroot);\n this._keydown = proxy(this._keydown, this);\n this._keyroot.on('keydown', this._keydown);\n },\n options: {\n name: 'Navigator',\n panStep: 1\n },\n events: ['pan'],\n dispose: function () {\n this._keyroot.off('keydown', this._keydown);\n },\n _pan: function (x, y) {\n var panStep = this.options.panStep;\n this.trigger('pan', {\n x: x * panStep,\n y: y * panStep\n });\n },\n _click: function (e) {\n var x = 0;\n var y = 0;\n var button = $(e.currentTarget);\n if (button.is('.k-navigator-up')) {\n y = 1;\n } else if (button.is('.k-navigator-down')) {\n y = -1;\n } else if (button.is('.k-navigator-right')) {\n x = 1;\n } else if (button.is('.k-navigator-left')) {\n x = -1;\n }\n this._pan(x, y);\n e.preventDefault();\n },\n _keydown: function (e) {\n switch (e.which) {\n case keys.UP:\n this._pan(0, 1);\n e.preventDefault();\n break;\n case keys.DOWN:\n this._pan(0, -1);\n e.preventDefault();\n break;\n case keys.RIGHT:\n this._pan(1, 0);\n e.preventDefault();\n break;\n case keys.LEFT:\n this._pan(-1, 0);\n e.preventDefault();\n break;\n }\n }\n });\n kendo.dataviz.ui.plugin(Navigator);\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/zoom', ['kendo.core'], f);\n}(function () {\n (function ($) {\n var kendo = window.kendo;\n var Widget = kendo.ui.Widget;\n var keys = kendo.keys;\n var proxy = $.proxy;\n function button(dir, iconClass) {\n return kendo.format('', dir, iconClass);\n }\n var NS = '.kendoZoomControl';\n var BUTTONS = button('in', 'k-i-plus') + button('out', 'k-i-minus');\n var PLUS = 187;\n var MINUS = 189;\n var FF_PLUS = 61;\n var FF_MINUS = 173;\n var ZoomControl = Widget.extend({\n init: function (element, options) {\n Widget.fn.init.call(this, element, options);\n this._initOptions(options);\n this.element.addClass('k-widget k-zoom-control k-button-group k-group-horizontal').append(BUTTONS).on('click' + NS, '.k-button', proxy(this, '_click'));\n var parentElement = this.element.parent().closest('[' + kendo.attr('role') + ']');\n this._keyroot = parentElement.length > 0 ? parentElement : this.element;\n this._tabindex(this._keyroot);\n this._keydown = proxy(this._keydown, this);\n this._keyroot.on('keydown', this._keydown);\n },\n options: {\n name: 'ZoomControl',\n zoomStep: 1\n },\n events: ['change'],\n _change: function (dir) {\n var zoomStep = this.options.zoomStep;\n this.trigger('change', { delta: dir * zoomStep });\n },\n _click: function (e) {\n var button = $(e.currentTarget);\n var dir = 1;\n if (button.is('.k-zoom-out')) {\n dir = -1;\n }\n this._change(dir);\n e.preventDefault();\n },\n _keydown: function (e) {\n switch (e.which) {\n case keys.NUMPAD_PLUS:\n case PLUS:\n case FF_PLUS:\n this._change(1);\n break;\n case keys.NUMPAD_MINUS:\n case MINUS:\n case FF_MINUS:\n this._change(-1);\n break;\n }\n }\n });\n kendo.dataviz.ui.plugin(ZoomControl);\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/crs', [\n 'dataviz/map/location',\n 'kendo.drawing'\n ], f);\n}(function () {\n (function ($, undefined) {\n var math = Math, atan = math.atan, exp = math.exp, pow = math.pow, sin = math.sin, log = math.log, tan = math.tan, kendo = window.kendo, Class = kendo.Class, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, g = kendo.geometry, Point = g.Point, map = dataviz.map, Location = map.Location, util = kendo.drawing.util, rad = util.rad, deg = util.deg, limit = util.limitValue;\n var PI = math.PI, PI_DIV_2 = PI / 2, PI_DIV_4 = PI / 4, DEG_TO_RAD = PI / 180;\n var WGS84 = {\n a: 6378137,\n b: 6356752.314245179,\n f: 0.0033528106647474805,\n e: 0.08181919084262149\n };\n var Mercator = Class.extend({\n init: function (options) {\n this._initOptions(options);\n },\n MAX_LNG: 180,\n MAX_LAT: 85.0840590501,\n INVERSE_ITERATIONS: 15,\n INVERSE_CONVERGENCE: 1e-12,\n options: {\n centralMeridian: 0,\n datum: WGS84\n },\n forward: function (loc, clamp) {\n var proj = this, options = proj.options, datum = options.datum, r = datum.a, lng0 = options.centralMeridian, lat = limit(loc.lat, -proj.MAX_LAT, proj.MAX_LAT), lng = clamp ? limit(loc.lng, -proj.MAX_LNG, proj.MAX_LNG) : loc.lng, x = rad(lng - lng0) * r, y = proj._projectLat(lat);\n return new Point(x, y);\n },\n _projectLat: function (lat) {\n var datum = this.options.datum, ecc = datum.e, r = datum.a, y = rad(lat), ts = tan(PI_DIV_4 + y / 2), con = ecc * sin(y), p = pow((1 - con) / (1 + con), ecc / 2);\n return r * log(ts * p);\n },\n inverse: function (point, clamp) {\n var proj = this, options = proj.options, datum = options.datum, r = datum.a, lng0 = options.centralMeridian, lng = point.x / (DEG_TO_RAD * r) + lng0, lat = limit(proj._inverseY(point.y), -proj.MAX_LAT, proj.MAX_LAT);\n if (clamp) {\n lng = limit(lng, -proj.MAX_LNG, proj.MAX_LNG);\n }\n return new Location(lat, lng);\n },\n _inverseY: function (y) {\n var proj = this, datum = proj.options.datum, r = datum.a, ecc = datum.e, ecch = ecc / 2, ts = exp(-y / r), phi = PI_DIV_2 - 2 * atan(ts), i;\n for (i = 0; i <= proj.INVERSE_ITERATIONS; i++) {\n var con = ecc * sin(phi), p = pow((1 - con) / (1 + con), ecch), dphi = PI_DIV_2 - 2 * atan(ts * p) - phi;\n phi += dphi;\n if (math.abs(dphi) <= proj.INVERSE_CONVERGENCE) {\n break;\n }\n }\n return deg(phi);\n }\n });\n var SphericalMercator = Mercator.extend({\n MAX_LAT: 85.0511287798,\n _projectLat: function (lat) {\n var r = this.options.datum.a, y = rad(lat), ts = tan(PI_DIV_4 + y / 2);\n return r * log(ts);\n },\n _inverseY: function (y) {\n var r = this.options.datum.a, ts = exp(-y / r);\n return deg(PI_DIV_2 - 2 * atan(ts));\n }\n });\n var Equirectangular = Class.extend({\n forward: function (loc) {\n return new Point(loc.lng, loc.lat);\n },\n inverse: function (point) {\n return new Location(point.y, point.x);\n }\n });\n var EPSG3857 = Class.extend({\n init: function () {\n var crs = this, proj = crs._proj = new SphericalMercator();\n var c = this.c = 2 * PI * proj.options.datum.a;\n this._tm = g.transform().translate(0.5, 0.5).scale(1 / c, -1 / c);\n this._itm = g.transform().scale(c, -c).translate(-0.5, -0.5);\n },\n toPoint: function (loc, scale, clamp) {\n var point = this._proj.forward(loc, clamp);\n return point.transform(this._tm).scale(scale || 1);\n },\n toLocation: function (point, scale, clamp) {\n point = point.clone().scale(1 / (scale || 1)).transform(this._itm);\n return this._proj.inverse(point, clamp);\n }\n });\n var EPSG3395 = Class.extend({\n init: function () {\n this._proj = new Mercator();\n },\n toPoint: function (loc) {\n return this._proj.forward(loc);\n },\n toLocation: function (point) {\n return this._proj.inverse(point);\n }\n });\n var EPSG4326 = Class.extend({\n init: function () {\n this._proj = new Equirectangular();\n },\n toPoint: function (loc) {\n return this._proj.forward(loc);\n },\n toLocation: function (point) {\n return this._proj.inverse(point);\n }\n });\n deepExtend(dataviz, {\n map: {\n crs: {\n EPSG3395: EPSG3395,\n EPSG3857: EPSG3857,\n EPSG4326: EPSG4326\n },\n datums: { WGS84: WGS84 },\n projections: {\n Equirectangular: Equirectangular,\n Mercator: Mercator,\n SphericalMercator: SphericalMercator\n }\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/layers/base', [\n 'kendo.core',\n 'dataviz/map/location'\n ], f);\n}(function () {\n (function ($, undefined) {\n var proxy = $.proxy, kendo = window.kendo, Class = kendo.Class, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, Extent = dataviz.map.Extent, util = kendo.drawing.util, defined = util.defined;\n var Layer = Class.extend({\n init: function (map, options) {\n this._initOptions(options);\n this.map = map;\n this.element = $('
').css({\n 'zIndex': this.options.zIndex,\n 'opacity': this.options.opacity\n }).appendTo(map.scrollElement);\n this._beforeReset = proxy(this._beforeReset, this);\n this._reset = proxy(this._reset, this);\n this._resize = proxy(this._resize, this);\n this._panEnd = proxy(this._panEnd, this);\n this._activate();\n this._updateAttribution();\n },\n destroy: function () {\n this._deactivate();\n },\n show: function () {\n this.reset();\n this._activate();\n this._applyExtent(true);\n },\n hide: function () {\n this._deactivate();\n this._setVisibility(false);\n },\n reset: function () {\n this._beforeReset();\n this._reset();\n },\n _reset: function () {\n this._applyExtent();\n },\n _beforeReset: $.noop,\n _resize: $.noop,\n _panEnd: function () {\n this._applyExtent();\n },\n _applyExtent: function () {\n var options = this.options;\n var zoom = this.map.zoom();\n var matchMinZoom = !defined(options.minZoom) || zoom >= options.minZoom;\n var matchMaxZoom = !defined(options.maxZoom) || zoom <= options.maxZoom;\n var extent = Extent.create(options.extent);\n var inside = !extent || extent.overlaps(this.map.extent());\n this._setVisibility(matchMinZoom && matchMaxZoom && inside);\n },\n _setVisibility: function (visible) {\n this.element.css('display', visible ? '' : 'none');\n },\n _activate: function () {\n var map = this.map;\n this._deactivate();\n map.bind('beforeReset', this._beforeReset);\n map.bind('reset', this._reset);\n map.bind('resize', this._resize);\n map.bind('panEnd', this._panEnd);\n },\n _deactivate: function () {\n var map = this.map;\n map.unbind('beforeReset', this._beforeReset);\n map.unbind('reset', this._reset);\n map.unbind('resize', this._resize);\n map.unbind('panEnd', this._panEnd);\n },\n _updateAttribution: function () {\n var attr = this.map.attribution;\n if (attr) {\n attr.add(this.options.attribution);\n }\n }\n });\n deepExtend(dataviz, { map: { layers: { Layer: Layer } } });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/layers/shape', [\n 'dataviz/map/layers/base',\n 'dataviz/map/location'\n ], f);\n}(function () {\n (function ($, undefined) {\n var proxy = $.proxy, kendo = window.kendo, Class = kendo.Class, DataSource = kendo.data.DataSource, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, g = kendo.geometry, d = kendo.drawing, Group = d.Group, last = d.util.last, defined = d.util.defined, map = dataviz.map, Location = map.Location, Layer = map.layers.Layer;\n var ShapeLayer = Layer.extend({\n init: function (map, options) {\n this._pan = proxy(this._pan, this);\n Layer.fn.init.call(this, map, options);\n this.surface = d.Surface.create(this.element, {\n width: map.scrollElement.width(),\n height: map.scrollElement.height()\n });\n this._initRoot();\n this.movable = new kendo.ui.Movable(this.surface.element);\n this._markers = [];\n this._click = this._handler('shapeClick');\n this.surface.bind('click', this._click);\n this._mouseenter = this._handler('shapeMouseEnter');\n this.surface.bind('mouseenter', this._mouseenter);\n this._mouseleave = this._handler('shapeMouseLeave');\n this.surface.bind('mouseleave', this._mouseleave);\n this._initDataSource();\n },\n options: { autoBind: true },\n destroy: function () {\n Layer.fn.destroy.call(this);\n this.surface.destroy();\n this.dataSource.unbind('change', this._dataChange);\n },\n setDataSource: function (dataSource) {\n if (this.dataSource) {\n this.dataSource.unbind('change', this._dataChange);\n }\n this.dataSource = kendo.data.DataSource.create(dataSource);\n this.dataSource.bind('change', this._dataChange);\n if (this.options.autoBind) {\n this.dataSource.fetch();\n }\n },\n _reset: function () {\n Layer.fn._reset.call(this);\n this._translateSurface();\n if (this._data) {\n this._load(this._data);\n }\n },\n _initRoot: function () {\n this._root = new Group();\n this.surface.draw(this._root);\n },\n _beforeReset: function () {\n this.surface.clear();\n this._initRoot();\n },\n _resize: function () {\n this.surface.size(this.map.size());\n },\n _initDataSource: function () {\n var dsOptions = this.options.dataSource;\n this._dataChange = proxy(this._dataChange, this);\n this.dataSource = DataSource.create(dsOptions).bind('change', this._dataChange);\n if (dsOptions && this.options.autoBind) {\n this.dataSource.fetch();\n }\n },\n _dataChange: function (e) {\n this._data = e.sender.view();\n this._load(this._data);\n },\n _load: function (data) {\n this._clearMarkers();\n if (!this._loader) {\n this._loader = new GeoJSONLoader(this.map, this.options.style, this);\n }\n var container = new Group();\n for (var i = 0; i < data.length; i++) {\n var shape = this._loader.parse(data[i]);\n if (shape) {\n container.append(shape);\n }\n }\n this._root.clear();\n this._root.append(container);\n },\n shapeCreated: function (shape) {\n var cancelled = false;\n if (shape instanceof d.Circle) {\n cancelled = defined(this._createMarker(shape));\n }\n if (!cancelled) {\n var args = {\n layer: this,\n shape: shape\n };\n cancelled = this.map.trigger('shapeCreated', args);\n }\n return cancelled;\n },\n featureCreated: function (e) {\n e.layer = this;\n this.map.trigger('shapeFeatureCreated', e);\n },\n _createMarker: function (shape) {\n var marker = this.map.markers.bind({ location: shape.location }, shape.dataItem);\n if (marker) {\n this._markers.push(marker);\n }\n return marker;\n },\n _clearMarkers: function () {\n for (var i = 0; i < this._markers.length; i++) {\n this.map.markers.remove(this._markers[i]);\n }\n this._markers = [];\n },\n _pan: function () {\n if (!this._panning) {\n this._panning = true;\n this.surface.suspendTracking();\n }\n },\n _panEnd: function (e) {\n Layer.fn._panEnd.call(this, e);\n this._translateSurface();\n this.surface.resumeTracking();\n this._panning = false;\n },\n _translateSurface: function () {\n var map = this.map;\n var nw = map.locationToView(map.extent().nw);\n if (this.surface.translate) {\n this.surface.translate(nw);\n this.movable.moveTo({\n x: nw.x,\n y: nw.y\n });\n }\n },\n _handler: function (event) {\n var layer = this;\n return function (e) {\n if (e.element) {\n var args = {\n layer: layer,\n shape: e.element,\n originalEvent: e.originalEvent\n };\n layer.map.trigger(event, args);\n }\n };\n },\n _activate: function () {\n Layer.fn._activate.call(this);\n this.map.bind('pan', this._pan);\n },\n _deactivate: function () {\n Layer.fn._deactivate.call(this);\n this.map.unbind('pan', this._pan);\n }\n });\n var GeoJSONLoader = Class.extend({\n init: function (locator, defaultStyle, observer) {\n this.observer = observer;\n this.locator = locator;\n this.style = defaultStyle;\n },\n parse: function (item) {\n var root = new Group();\n var unwrap = true;\n if (item.type === 'Feature') {\n unwrap = false;\n this._loadGeometryTo(root, item.geometry, item);\n this._featureCreated(root, item);\n } else {\n this._loadGeometryTo(root, item, item);\n }\n if (unwrap && root.children.length < 2) {\n root = root.children[0];\n }\n return root;\n },\n _shapeCreated: function (shape) {\n var cancelled = false;\n if (this.observer && this.observer.shapeCreated) {\n cancelled = this.observer.shapeCreated(shape);\n }\n return cancelled;\n },\n _featureCreated: function (group, dataItem) {\n if (this.observer && this.observer.featureCreated) {\n this.observer.featureCreated({\n group: group,\n dataItem: dataItem,\n properties: dataItem.properties\n });\n }\n },\n _loadGeometryTo: function (container, geometry, dataItem) {\n var coords = geometry.coordinates;\n var i;\n var path;\n switch (geometry.type) {\n case 'LineString':\n path = this._loadPolygon(container, [coords], dataItem);\n this._setLineFill(path);\n break;\n case 'MultiLineString':\n for (i = 0; i < coords.length; i++) {\n path = this._loadPolygon(container, [coords[i]], dataItem);\n this._setLineFill(path);\n }\n break;\n case 'Polygon':\n this._loadPolygon(container, coords, dataItem);\n break;\n case 'MultiPolygon':\n for (i = 0; i < coords.length; i++) {\n this._loadPolygon(container, coords[i], dataItem);\n }\n break;\n case 'Point':\n this._loadPoint(container, coords, dataItem);\n break;\n case 'MultiPoint':\n for (i = 0; i < coords.length; i++) {\n this._loadPoint(container, coords[i], dataItem);\n }\n break;\n }\n },\n _setLineFill: function (path) {\n var segments = path.segments;\n if (segments.length < 4 || !segments[0].anchor().equals(last(segments).anchor())) {\n path.options.fill = null;\n }\n },\n _loadShape: function (container, shape) {\n if (!this._shapeCreated(shape)) {\n container.append(shape);\n }\n return shape;\n },\n _loadPolygon: function (container, rings, dataItem) {\n var shape = this._buildPolygon(rings);\n shape.dataItem = dataItem;\n return this._loadShape(container, shape);\n },\n _buildPolygon: function (rings) {\n var type = rings.length > 1 ? d.MultiPath : d.Path;\n var path = new type(this.style);\n for (var i = 0; i < rings.length; i++) {\n for (var j = 0; j < rings[i].length; j++) {\n var point = this.locator.locationToView(Location.fromLngLat(rings[i][j]));\n if (j === 0) {\n path.moveTo(point.x, point.y);\n } else {\n path.lineTo(point.x, point.y);\n }\n }\n }\n return path;\n },\n _loadPoint: function (container, coords, dataItem) {\n var location = Location.fromLngLat(coords);\n var point = this.locator.locationToView(location);\n var circle = new g.Circle(point, 10);\n var shape = new d.Circle(circle, this.style);\n shape.dataItem = dataItem;\n shape.location = location;\n return this._loadShape(container, shape);\n }\n });\n deepExtend(kendo.data, {\n schemas: {\n geojson: {\n type: 'json',\n data: function (data) {\n if (data.type === 'FeatureCollection') {\n return data.features;\n }\n if (data.type === 'GeometryCollection') {\n return data.geometries;\n }\n return data;\n }\n }\n },\n transports: { geojson: { read: { dataType: 'json' } } }\n });\n deepExtend(dataviz, {\n map: {\n layers: {\n shape: ShapeLayer,\n ShapeLayer: ShapeLayer\n },\n GeoJSONLoader: GeoJSONLoader\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/layers/bubble', ['dataviz/map/layers/shape'], f);\n}(function () {\n (function ($, undefined) {\n var kendo = window.kendo, getter = kendo.getter, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, g = kendo.geometry, d = kendo.drawing, util = d.util, defined = util.defined, map = dataviz.map, Location = map.Location, ShapeLayer = map.layers.ShapeLayer;\n var BubbleLayer = ShapeLayer.extend({\n options: {\n autoBind: true,\n locationField: 'location',\n valueField: 'value',\n minSize: 0,\n maxSize: 100,\n scale: 'sqrt',\n symbol: 'circle'\n },\n _load: function (data) {\n this.surface.clear();\n if (data.length === 0) {\n return;\n }\n var opt = this.options;\n var getValue = getter(opt.valueField);\n data = data.slice(0);\n data.sort(function (a, b) {\n return getValue(b) - getValue(a);\n });\n var scaleType = this._scaleType();\n var scale;\n for (var i = 0; i < data.length; i++) {\n var dataItem = data[i];\n var location = getter(opt.locationField)(dataItem);\n var value = getter(opt.valueField)(dataItem);\n if (defined(location) && defined(value)) {\n if (!scale) {\n scale = new scaleType([\n 0,\n value\n ], [\n opt.minSize,\n opt.maxSize\n ]);\n }\n location = Location.create(location);\n var center = this.map.locationToView(location);\n var size = scale.map(value);\n var symbol = this._createSymbol({\n center: center,\n size: size,\n style: opt.style,\n dataItem: dataItem,\n location: location\n });\n symbol.dataItem = dataItem;\n symbol.location = location;\n symbol.value = value;\n this._drawSymbol(symbol);\n }\n }\n },\n _scaleType: function () {\n var scale = this.options.scale;\n if (kendo.isFunction(scale)) {\n return scale;\n }\n return dataviz.map.scales[scale];\n },\n _createSymbol: function (args) {\n var symbol = this.options.symbol;\n if (!kendo.isFunction(symbol)) {\n symbol = dataviz.map.symbols[symbol];\n }\n return symbol(args);\n },\n _drawSymbol: function (shape) {\n var args = {\n layer: this,\n shape: shape\n };\n var cancelled = this.map.trigger('shapeCreated', args);\n if (!cancelled) {\n this.surface.draw(shape);\n }\n }\n });\n var SqrtScale = kendo.Class.extend({\n init: function (domain, range) {\n this._domain = domain;\n this._range = range;\n var domainRange = Math.sqrt(domain[1]) - Math.sqrt(domain[0]);\n var outputRange = range[1] - range[0];\n this._ratio = outputRange / domainRange;\n },\n map: function (value) {\n var rel = (Math.sqrt(value) - Math.sqrt(this._domain[0])) * this._ratio;\n return this._range[0] + rel;\n }\n });\n var Symbols = {\n circle: function (args) {\n var geo = new g.Circle(args.center, args.size / 2);\n return new d.Circle(geo, args.style);\n },\n square: function (args) {\n var path = new d.Path(args.style);\n var halfSize = args.size / 2;\n var center = args.center;\n path.moveTo(center.x - halfSize, center.y - halfSize).lineTo(center.x + halfSize, center.y - halfSize).lineTo(center.x + halfSize, center.y + halfSize).lineTo(center.x - halfSize, center.y + halfSize).close();\n return path;\n }\n };\n deepExtend(dataviz, {\n map: {\n layers: {\n bubble: BubbleLayer,\n BubbleLayer: BubbleLayer\n },\n scales: { sqrt: SqrtScale },\n symbols: Symbols\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/layers/tile', [\n 'dataviz/map/layers/base',\n 'dataviz/map/location'\n ], f);\n}(function () {\n (function ($, undefined) {\n var math = Math, proxy = $.proxy, kendo = window.kendo, Class = kendo.Class, template = kendo.template, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, g = kendo.geometry, Point = g.Point, Layer = dataviz.map.layers.Layer, util = kendo.util, renderSize = util.renderSize, drawingUtil = kendo.drawing.util, round = drawingUtil.round, limit = drawingUtil.limitValue;\n var TileLayer = Layer.extend({\n init: function (map, options) {\n Layer.fn.init.call(this, map, options);\n if (typeof this.options.subdomains === 'string') {\n this.options.subdomains = this.options.subdomains.split('');\n }\n var viewType = this._viewType();\n this._view = new viewType(this.element, this.options);\n },\n destroy: function () {\n Layer.fn.destroy.call(this);\n this._view.destroy();\n this._view = null;\n },\n _beforeReset: function () {\n var map = this.map;\n var origin = map.locationToLayer(map.extent().nw).round();\n this._view.viewOrigin(origin);\n },\n _reset: function () {\n Layer.fn._reset.call(this);\n this._updateView();\n this._view.reset();\n },\n _viewType: function () {\n return TileView;\n },\n _activate: function () {\n Layer.fn._activate.call(this);\n if (!kendo.support.mobileOS) {\n if (!this._pan) {\n this._pan = kendo.throttle(proxy(this._render, this), 100);\n }\n this.map.bind('pan', this._pan);\n }\n },\n _deactivate: function () {\n Layer.fn._deactivate.call(this);\n if (this._pan) {\n this.map.unbind('pan', this._pan);\n }\n },\n _updateView: function () {\n var view = this._view, map = this.map, extent = map.extent(), extentToPoint = {\n nw: map.locationToLayer(extent.nw).round(),\n se: map.locationToLayer(extent.se).round()\n };\n view.center(map.locationToLayer(map.center()));\n view.extent(extentToPoint);\n view.zoom(map.zoom());\n },\n _resize: function () {\n this._render();\n },\n _panEnd: function (e) {\n Layer.fn._panEnd.call(this, e);\n this._render();\n },\n _render: function () {\n this._updateView();\n this._view.render();\n }\n });\n var TileView = Class.extend({\n init: function (element, options) {\n this.element = element;\n this._initOptions(options);\n this.pool = new TilePool();\n },\n options: {\n tileSize: 256,\n subdomains: [\n 'a',\n 'b',\n 'c'\n ],\n urlTemplate: ''\n },\n center: function (center) {\n this._center = center;\n },\n extent: function (extent) {\n this._extent = extent;\n },\n viewOrigin: function (origin) {\n this._viewOrigin = origin;\n },\n zoom: function (zoom) {\n this._zoom = zoom;\n },\n pointToTileIndex: function (point) {\n return new Point(math.floor(point.x / this.options.tileSize), math.floor(point.y / this.options.tileSize));\n },\n tileCount: function () {\n var size = this.size(), firstTileIndex = this.pointToTileIndex(this._extent.nw), nw = this._extent.nw, point = this.indexToPoint(firstTileIndex).translate(-nw.x, -nw.y);\n return {\n x: math.ceil((math.abs(point.x) + size.width) / this.options.tileSize),\n y: math.ceil((math.abs(point.y) + size.height) / this.options.tileSize)\n };\n },\n size: function () {\n var nw = this._extent.nw, se = this._extent.se, diff = se.clone().translate(-nw.x, -nw.y);\n return {\n width: diff.x,\n height: diff.y\n };\n },\n indexToPoint: function (index) {\n var x = index.x, y = index.y;\n return new Point(x * this.options.tileSize, y * this.options.tileSize);\n },\n subdomainText: function () {\n var subdomains = this.options.subdomains;\n return subdomains[this.subdomainIndex++ % subdomains.length];\n },\n destroy: function () {\n this.element.empty();\n this.pool.empty();\n },\n reset: function () {\n this.pool.reset();\n this.subdomainIndex = 0;\n this.render();\n },\n render: function () {\n var size = this.tileCount(), firstTileIndex = this.pointToTileIndex(this._extent.nw), tile, x, y;\n for (x = 0; x < size.x; x++) {\n for (y = 0; y < size.y; y++) {\n tile = this.createTile({\n x: firstTileIndex.x + x,\n y: firstTileIndex.y + y\n });\n if (!tile.visible) {\n tile.show();\n }\n }\n }\n },\n createTile: function (currentIndex) {\n var options = this.tileOptions(currentIndex);\n var tile = this.pool.get(this._center, options);\n if (tile.element.parent().length === 0) {\n this.element.append(tile.element);\n }\n return tile;\n },\n tileOptions: function (currentIndex) {\n var index = this.wrapIndex(currentIndex), point = this.indexToPoint(currentIndex), origin = this._viewOrigin, offset = point.clone().translate(-origin.x, -origin.y);\n return {\n index: index,\n currentIndex: currentIndex,\n point: point,\n offset: roundPoint(offset),\n zoom: this._zoom,\n size: this.options.tileSize,\n subdomain: this.subdomainText(),\n urlTemplate: this.options.urlTemplate,\n errorUrlTemplate: this.options.errorUrlTemplate\n };\n },\n wrapIndex: function (index) {\n var boundary = math.pow(2, this._zoom);\n return {\n x: this.wrapValue(index.x, boundary),\n y: limit(index.y, 0, boundary - 1)\n };\n },\n wrapValue: function (value, boundary) {\n var remainder = math.abs(value) % boundary;\n if (value >= 0) {\n value = remainder;\n } else {\n value = boundary - (remainder === 0 ? boundary : remainder);\n }\n return value;\n }\n });\n var ImageTile = Class.extend({\n init: function (id, options) {\n this.id = id;\n this.visible = true;\n this._initOptions(options);\n this.createElement();\n this.show();\n },\n options: {\n urlTemplate: '',\n errorUrlTemplate: ''\n },\n createElement: function () {\n this.element = $('\\'\\'').css({\n width: this.options.size,\n height: this.options.size\n }).on('error', proxy(function (e) {\n if (this.errorUrl()) {\n e.target.setAttribute('src', this.errorUrl());\n } else {\n e.target.removeAttribute('src');\n }\n }, this));\n },\n show: function () {\n var element = this.element[0];\n element.style.top = renderSize(this.options.offset.y);\n element.style.left = renderSize(this.options.offset.x);\n var url = this.url();\n if (url) {\n element.setAttribute('src', url);\n }\n element.style.visibility = 'visible';\n this.visible = true;\n },\n hide: function () {\n this.element[0].style.visibility = 'hidden';\n this.visible = false;\n },\n url: function () {\n var urlResult = template(this.options.urlTemplate);\n return urlResult(this.urlOptions());\n },\n errorUrl: function () {\n var urlResult = template(this.options.errorUrlTemplate);\n return urlResult(this.urlOptions());\n },\n urlOptions: function () {\n var options = this.options;\n return {\n zoom: options.zoom,\n subdomain: options.subdomain,\n z: options.zoom,\n x: options.index.x,\n y: options.index.y,\n s: options.subdomain,\n quadkey: options.quadkey,\n q: options.quadkey,\n culture: options.culture,\n c: options.culture\n };\n },\n destroy: function () {\n if (this.element) {\n this.element.remove();\n this.element = null;\n }\n }\n });\n var TilePool = Class.extend({\n init: function () {\n this._items = [];\n },\n options: { maxSize: 100 },\n get: function (center, options) {\n if (this._items.length >= this.options.maxSize) {\n this._remove(center);\n }\n return this._create(options);\n },\n empty: function () {\n var items = this._items;\n for (var i = 0; i < items.length; i++) {\n items[i].destroy();\n }\n this._items = [];\n },\n reset: function () {\n var items = this._items;\n for (var i = 0; i < items.length; i++) {\n items[i].hide();\n }\n },\n _create: function (options) {\n var items = this._items;\n var tile;\n var id = util.hashKey(options.point.toString() + options.offset.toString() + options.zoom + options.urlTemplate);\n for (var i = 0; i < items.length; i++) {\n if (items[i].id === id) {\n tile = items[i];\n break;\n }\n }\n if (tile) {\n tile.show();\n } else {\n tile = new ImageTile(id, options);\n this._items.push(tile);\n }\n return tile;\n },\n _remove: function (center) {\n var items = this._items;\n var maxDist = -1;\n var index = -1;\n for (var i = 0; i < items.length; i++) {\n var dist = items[i].options.point.distanceTo(center);\n if (dist > maxDist && !items[i].visible) {\n index = i;\n maxDist = dist;\n }\n }\n if (index !== -1) {\n items[index].destroy();\n items.splice(index, 1);\n }\n }\n });\n function roundPoint(point) {\n return new Point(round(point.x), round(point.y));\n }\n deepExtend(dataviz, {\n map: {\n layers: {\n tile: TileLayer,\n TileLayer: TileLayer,\n ImageTile: ImageTile,\n TilePool: TilePool,\n TileView: TileView\n }\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/layers/bing', ['dataviz/map/layers/tile'], f);\n}(function () {\n (function ($, undefined) {\n var kendo = window.kendo, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, defined = kendo.drawing.util.defined, Extent = dataviz.map.Extent, Location = dataviz.map.Location, TileLayer = dataviz.map.layers.TileLayer, TileView = dataviz.map.layers.TileView;\n var BingLayer = TileLayer.extend({\n init: function (map, options) {\n this.options.baseUrl = this._scheme() + '://dev.virtualearth.net/REST/v1/Imagery/Metadata/';\n TileLayer.fn.init.call(this, map, options);\n this._onMetadata = $.proxy(this._onMetadata, this);\n this._fetchMetadata();\n },\n options: { imagerySet: 'road' },\n _fetchMetadata: function () {\n var options = this.options;\n if (!options.key) {\n throw new Error('Bing tile layer: API key is required');\n }\n $.ajax({\n url: options.baseUrl + options.imagerySet,\n data: {\n output: 'json',\n include: 'ImageryProviders',\n key: options.key,\n uriScheme: this._scheme()\n },\n type: 'get',\n dataType: 'jsonp',\n jsonp: 'jsonp',\n success: this._onMetadata\n });\n },\n _scheme: function (proto) {\n proto = proto || window.location.protocol;\n return proto.replace(':', '') === 'https' ? 'https' : 'http';\n },\n _onMetadata: function (data) {\n if (data && data.resourceSets.length) {\n var resource = this.resource = data.resourceSets[0].resources[0];\n deepExtend(this._view.options, {\n urlTemplate: resource.imageUrl.replace('{subdomain}', '#= subdomain #').replace('{quadkey}', '#= quadkey #').replace('{culture}', '#= culture #'),\n subdomains: resource.imageUrlSubdomains\n });\n var options = this.options;\n if (!defined(options.minZoom)) {\n options.minZoom = resource.zoomMin;\n }\n if (!defined(options.maxZoom)) {\n options.maxZoom = resource.zoomMax;\n }\n this._addAttribution();\n if (this.element.css('display') !== 'none') {\n this._reset();\n }\n }\n },\n _viewType: function () {\n return BingView;\n },\n _addAttribution: function () {\n var attr = this.map.attribution;\n if (attr) {\n var items = this.resource.imageryProviders;\n if (items) {\n for (var i = 0; i < items.length; i++) {\n var item = items[i];\n for (var y = 0; y < item.coverageAreas.length; y++) {\n var area = item.coverageAreas[y];\n attr.add({\n text: item.attribution,\n minZoom: area.zoomMin,\n maxZoom: area.zoomMax,\n extent: new Extent(new Location(area.bbox[2], area.bbox[1]), new Location(area.bbox[0], area.bbox[3]))\n });\n }\n }\n }\n }\n },\n imagerySet: function (value) {\n if (value) {\n this.options.imagerySet = value;\n this.map.attribution.clear();\n this._fetchMetadata();\n } else {\n return this.options.imagerySet;\n }\n }\n });\n var BingView = TileView.extend({\n options: { culture: 'en-US' },\n tileOptions: function (currentIndex) {\n var options = TileView.fn.tileOptions.call(this, currentIndex);\n options.culture = this.options.culture;\n options.quadkey = this.tileQuadKey(this.wrapIndex(currentIndex));\n return options;\n },\n tileQuadKey: function (index) {\n var quadKey = '', digit, mask, i;\n for (i = this._zoom; i > 0; i--) {\n digit = 0;\n mask = 1 << i - 1;\n if ((index.x & mask) !== 0) {\n digit++;\n }\n if ((index.y & mask) !== 0) {\n digit += 2;\n }\n quadKey += digit;\n }\n return quadKey;\n }\n });\n deepExtend(dataviz, {\n map: {\n layers: {\n bing: BingLayer,\n BingLayer: BingLayer,\n BingView: BingView\n }\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/layers/marker', [\n 'dataviz/map/layers/base',\n 'dataviz/map/location',\n 'kendo.data',\n 'kendo.tooltip'\n ], f);\n}(function () {\n (function ($, undefined) {\n var doc = document, math = Math, indexOf = $.inArray, proxy = $.proxy, kendo = window.kendo, Class = kendo.Class, DataSource = kendo.data.DataSource, Tooltip = kendo.ui.Tooltip, dataviz = kendo.dataviz, deepExtend = kendo.deepExtend, map = dataviz.map, Location = map.Location, Layer = map.layers.Layer;\n var MarkerLayer = Layer.extend({\n init: function (map, options) {\n Layer.fn.init.call(this, map, options);\n this._markerClick = proxy(this._markerClick, this);\n this.element.on('click', '.k-marker', this._markerClick);\n this.items = [];\n this._initDataSource();\n },\n destroy: function () {\n Layer.fn.destroy.call(this);\n this.element.off('click', '.k-marker', this._markerClick);\n this.dataSource.unbind('change', this._dataChange);\n this.clear();\n },\n options: {\n zIndex: 1000,\n autoBind: true,\n dataSource: {},\n locationField: 'location',\n titleField: 'title'\n },\n add: function (arg) {\n if ($.isArray(arg)) {\n for (var i = 0; i < arg.length; i++) {\n this._addOne(arg[i]);\n }\n } else {\n return this._addOne(arg);\n }\n },\n remove: function (marker) {\n marker.destroy();\n var index = indexOf(marker, this.items);\n if (index > -1) {\n this.items.splice(index, 1);\n }\n },\n clear: function () {\n for (var i = 0; i < this.items.length; i++) {\n this.items[i].destroy();\n }\n this.items = [];\n },\n update: function (marker) {\n var loc = marker.location();\n if (loc) {\n marker.showAt(this.map.locationToView(loc));\n var args = {\n marker: marker,\n layer: this\n };\n this.map.trigger('markerActivate', args);\n }\n },\n _reset: function () {\n Layer.fn._reset.call(this);\n var items = this.items;\n for (var i = 0; i < items.length; i++) {\n this.update(items[i]);\n }\n },\n bind: function (options, dataItem) {\n var marker = map.Marker.create(options, this.options);\n marker.dataItem = dataItem;\n var args = {\n marker: marker,\n layer: this\n };\n var cancelled = this.map.trigger('markerCreated', args);\n if (!cancelled) {\n this.add(marker);\n return marker;\n }\n },\n setDataSource: function (dataSource) {\n if (this.dataSource) {\n this.dataSource.unbind('change', this._dataChange);\n }\n this.dataSource = kendo.data.DataSource.create(dataSource);\n this.dataSource.bind('change', this._dataChange);\n if (this.options.autoBind) {\n this.dataSource.fetch();\n }\n },\n _addOne: function (arg) {\n var marker = Marker.create(arg, this.options);\n marker.addTo(this);\n return marker;\n },\n _initDataSource: function () {\n var dsOptions = this.options.dataSource;\n this._dataChange = proxy(this._dataChange, this);\n this.dataSource = DataSource.create(dsOptions).bind('change', this._dataChange);\n if (dsOptions && this.options.autoBind) {\n this.dataSource.fetch();\n }\n },\n _dataChange: function (e) {\n this._load(e.sender.view());\n },\n _load: function (data) {\n this._data = data;\n this.clear();\n var getLocation = kendo.getter(this.options.locationField);\n var getTitle = kendo.getter(this.options.titleField);\n for (var i = 0; i < data.length; i++) {\n var dataItem = data[i];\n this.bind({\n location: getLocation(dataItem),\n title: getTitle(dataItem)\n }, dataItem);\n }\n },\n _markerClick: function (e) {\n var args = {\n marker: $(e.target).data('kendoMarker'),\n layer: this\n };\n this.map.trigger('markerClick', args);\n }\n });\n var Marker = Class.extend({\n init: function (options) {\n this.options = options || {};\n },\n addTo: function (parent) {\n this.layer = parent.markers || parent;\n this.layer.items.push(this);\n this.layer.update(this);\n },\n location: function (value) {\n if (value) {\n this.options.location = Location.create(value).toArray();\n if (this.layer) {\n this.layer.update(this);\n }\n return this;\n } else {\n return Location.create(this.options.location);\n }\n },\n showAt: function (point) {\n this.render();\n this.element.css({\n left: math.round(point.x),\n top: math.round(point.y)\n });\n if (this.tooltip && this.tooltip.popup) {\n this.tooltip.popup._position();\n }\n },\n hide: function () {\n if (this.element) {\n this.element.remove();\n this.element = null;\n }\n if (this.tooltip) {\n this.tooltip.destroy();\n this.tooltip = null;\n }\n },\n destroy: function () {\n this.layer = null;\n this.hide();\n },\n render: function () {\n if (!this.element) {\n var options = this.options;\n var layer = this.layer;\n this.element = $(doc.createElement('span')).addClass('k-marker k-icon k-i-marker-' + kendo.toHyphens(options.shape || 'pin')).attr('title', options.title).attr(options.attributes || {}).data('kendoMarker', this).css('zIndex', options.zIndex);\n if (layer) {\n layer.element.append(this.element);\n }\n this.renderTooltip();\n }\n },\n renderTooltip: function () {\n var marker = this;\n var title = marker.options.title;\n var options = marker.options.tooltip || {};\n if (options && Tooltip) {\n var template = options.template;\n if (template) {\n var contentTemplate = kendo.template(template);\n options.content = function (e) {\n e.location = marker.location();\n e.marker = marker;\n return contentTemplate(e);\n };\n }\n if (title || options.content || options.contentUrl) {\n this.tooltip = new Tooltip(this.element, options);\n this.tooltip.marker = this;\n }\n }\n }\n });\n Marker.create = function (arg, defaults) {\n if (arg instanceof Marker) {\n return arg;\n }\n return new Marker(deepExtend({}, defaults, arg));\n };\n deepExtend(dataviz, {\n map: {\n layers: {\n marker: MarkerLayer,\n MarkerLayer: MarkerLayer\n },\n Marker: Marker\n }\n });\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('dataviz/map/main', [\n 'dataviz/map/crs',\n 'dataviz/map/location'\n ], f);\n}(function () {\n (function ($, undefined) {\n var doc = document, math = Math, min = math.min, pow = math.pow, proxy = $.proxy, kendo = window.kendo, Widget = kendo.ui.Widget, deepExtend = kendo.deepExtend, dataviz = kendo.dataviz, ui = dataviz.ui, g = kendo.geometry, Point = g.Point, map = dataviz.map, Extent = map.Extent, Location = map.Location, EPSG3857 = map.crs.EPSG3857, util = kendo.util, renderPos = util.renderPos, drawingUtil = kendo.drawing.util, defined = drawingUtil.defined, limit = drawingUtil.limitValue, valueOrDefault = drawingUtil.valueOrDefault;\n var CSS_PREFIX = 'k-', FRICTION = 0.9, FRICTION_MOBILE = 0.93, MOUSEWHEEL = 'DOMMouseScroll mousewheel', VELOCITY_MULTIPLIER = 5, DEFAULT_ZOOM_RATE = 1;\n var Map = Widget.extend({\n init: function (element, options) {\n kendo.destroy(element);\n Widget.fn.init.call(this, element);\n this._initOptions(options);\n this.bind(this.events, options);\n this.crs = new EPSG3857();\n this.element.addClass(CSS_PREFIX + this.options.name.toLowerCase()).css('position', 'relative').empty().append(doc.createElement('div'));\n this._viewOrigin = this._getOrigin();\n this._initScroller();\n this._initMarkers();\n this._initControls();\n this._initLayers();\n this._reset();\n this._mousewheel = proxy(this._mousewheel, this);\n this.element.bind(MOUSEWHEEL, this._mousewheel);\n },\n options: {\n name: 'Map',\n controls: {\n attribution: true,\n navigator: { panStep: 100 },\n zoom: true\n },\n layers: [],\n layerDefaults: {\n shape: {\n style: {\n fill: { color: '#fff' },\n stroke: {\n color: '#aaa',\n width: 0.5\n }\n }\n },\n bubble: {\n style: {\n fill: {\n color: '#fff',\n opacity: 0.5\n },\n stroke: {\n color: '#aaa',\n width: 0.5\n }\n }\n },\n marker: {\n shape: 'pinTarget',\n tooltip: { position: 'top' }\n }\n },\n center: [\n 0,\n 0\n ],\n zoom: 3,\n minSize: 256,\n minZoom: 1,\n maxZoom: 19,\n markers: [],\n markerDefaults: {\n shape: 'pinTarget',\n tooltip: { position: 'top' }\n },\n wraparound: true\n },\n events: [\n 'beforeReset',\n 'click',\n 'markerActivate',\n 'markerClick',\n 'markerCreated',\n 'pan',\n 'panEnd',\n 'reset',\n 'shapeClick',\n 'shapeCreated',\n 'shapeFeatureCreated',\n 'shapeMouseEnter',\n 'shapeMouseLeave',\n 'zoomEnd',\n 'zoomStart'\n ],\n destroy: function () {\n this.scroller.destroy();\n if (this.navigator) {\n this.navigator.destroy();\n }\n if (this.attribution) {\n this.attribution.destroy();\n }\n if (this.zoomControl) {\n this.zoomControl.destroy();\n }\n this.markers.destroy();\n for (var i = 0; i < this.layers.length; i++) {\n this.layers[i].destroy();\n }\n Widget.fn.destroy.call(this);\n },\n zoom: function (level) {\n var options = this.options;\n if (defined(level)) {\n level = math.round(limit(level, options.minZoom, options.maxZoom));\n if (options.zoom !== level) {\n options.zoom = level;\n this._reset();\n }\n return this;\n } else {\n return options.zoom;\n }\n },\n center: function (center) {\n if (center) {\n this.options.center = Location.create(center).toArray();\n this._reset();\n return this;\n } else {\n return Location.create(this.options.center);\n }\n },\n extent: function (extent) {\n if (extent) {\n this._setExtent(extent);\n return this;\n } else {\n return this._getExtent();\n }\n },\n setOptions: function (options) {\n Widget.fn.setOptions.call(this, options);\n this._reset();\n },\n locationToLayer: function (location, zoom) {\n var clamp = !this.options.wraparound;\n location = Location.create(location);\n return this.crs.toPoint(location, this._layerSize(zoom), clamp);\n },\n layerToLocation: function (point, zoom) {\n var clamp = !this.options.wraparound;\n point = Point.create(point);\n return this.crs.toLocation(point, this._layerSize(zoom), clamp);\n },\n locationToView: function (location) {\n location = Location.create(location);\n var origin = this.locationToLayer(this._viewOrigin);\n var point = this.locationToLayer(location);\n return point.translateWith(origin.scale(-1));\n },\n viewToLocation: function (point, zoom) {\n var origin = this.locationToLayer(this._getOrigin(), zoom);\n point = Point.create(point);\n point = point.clone().translateWith(origin);\n return this.layerToLocation(point, zoom);\n },\n eventOffset: function (e) {\n var point;\n var x;\n var y;\n var offset = this.element.offset();\n if (e.x || e.y) {\n var field = 'location';\n x = e.x[field] - offset.left;\n y = e.y[field] - offset.top;\n point = new g.Point(x, y);\n } else {\n var event = e.originalEvent || e;\n x = valueOrDefault(event.pageX, event.clientX) - offset.left;\n y = valueOrDefault(event.pageY, event.clientY) - offset.top;\n point = new g.Point(x, y);\n }\n return point;\n },\n eventToView: function (e) {\n var cursor = this.eventOffset(e);\n return this.locationToView(this.viewToLocation(cursor));\n },\n eventToLayer: function (e) {\n return this.locationToLayer(this.eventToLocation(e));\n },\n eventToLocation: function (e) {\n var cursor = this.eventOffset(e);\n return this.viewToLocation(cursor);\n },\n viewSize: function () {\n var element = this.element;\n var scale = this._layerSize();\n var width = element.width();\n if (!this.options.wraparound) {\n width = min(scale, width);\n }\n return {\n width: width,\n height: min(scale, element.height())\n };\n },\n exportVisual: function () {\n this._reset();\n return false;\n },\n _setOrigin: function (origin, zoom) {\n var size = this.viewSize(), topLeft;\n origin = this._origin = Location.create(origin);\n topLeft = this.locationToLayer(origin, zoom);\n topLeft.x += size.width / 2;\n topLeft.y += size.height / 2;\n this.options.center = this.layerToLocation(topLeft, zoom).toArray();\n return this;\n },\n _getOrigin: function (invalidate) {\n var size = this.viewSize(), topLeft;\n if (invalidate || !this._origin) {\n topLeft = this.locationToLayer(this.center());\n topLeft.x -= size.width / 2;\n topLeft.y -= size.height / 2;\n this._origin = this.layerToLocation(topLeft);\n }\n return this._origin;\n },\n _setExtent: function (extent) {\n var raw = Extent.create(extent);\n var se = raw.se.clone();\n if (this.options.wraparound && se.lng < 0 && extent.nw.lng > 0) {\n se.lng = 180 + (180 + se.lng);\n }\n extent = new Extent(raw.nw, se);\n this.center(extent.center());\n var width = this.element.width();\n var height = this.element.height();\n for (var zoom = this.options.maxZoom; zoom >= this.options.minZoom; zoom--) {\n var topLeft = this.locationToLayer(extent.nw, zoom);\n var bottomRight = this.locationToLayer(extent.se, zoom);\n var layerWidth = math.abs(bottomRight.x - topLeft.x);\n var layerHeight = math.abs(bottomRight.y - topLeft.y);\n if (layerWidth <= width && layerHeight <= height) {\n break;\n }\n }\n this.zoom(zoom);\n },\n _getExtent: function () {\n var nw = this._getOrigin();\n var bottomRight = this.locationToLayer(nw);\n var size = this.viewSize();\n bottomRight.x += size.width;\n bottomRight.y += size.height;\n var se = this.layerToLocation(bottomRight);\n return new Extent(nw, se);\n },\n _zoomAround: function (pivot, level) {\n this._setOrigin(this.layerToLocation(pivot, level), level);\n this.zoom(level);\n },\n _initControls: function () {\n var controls = this.options.controls;\n if (ui.Attribution && controls.attribution) {\n this._createAttribution(controls.attribution);\n }\n if (!kendo.support.mobileOS) {\n if (ui.Navigator && controls.navigator) {\n this._createNavigator(controls.navigator);\n }\n if (ui.ZoomControl && controls.zoom) {\n this._createZoomControl(controls.zoom);\n }\n }\n },\n _createControlElement: function (options, defaultPos) {\n var pos = options.position || defaultPos;\n var posSelector = '.' + renderPos(pos).replace(' ', '.');\n var wrap = $('.k-map-controls' + posSelector, this.element);\n if (wrap.length === 0) {\n wrap = $('
').addClass('k-map-controls ' + renderPos(pos)).appendTo(this.element);\n }\n return $('
').appendTo(wrap);\n },\n _createAttribution: function (options) {\n var element = this._createControlElement(options, 'bottomRight');\n this.attribution = new ui.Attribution(element, options);\n },\n _createNavigator: function (options) {\n var element = this._createControlElement(options, 'topLeft');\n var navigator = this.navigator = new ui.Navigator(element, options);\n this._navigatorPan = proxy(this._navigatorPan, this);\n navigator.bind('pan', this._navigatorPan);\n this._navigatorCenter = proxy(this._navigatorCenter, this);\n navigator.bind('center', this._navigatorCenter);\n },\n _navigatorPan: function (e) {\n var map = this;\n var scroller = map.scroller;\n var x = scroller.scrollLeft + e.x;\n var y = scroller.scrollTop - e.y;\n var bounds = this._virtualSize;\n var height = this.element.height();\n var width = this.element.width();\n x = limit(x, bounds.x.min, bounds.x.max - width);\n y = limit(y, bounds.y.min, bounds.y.max - height);\n map.scroller.one('scroll', function (e) {\n map._scrollEnd(e);\n });\n map.scroller.scrollTo(-x, -y);\n },\n _navigatorCenter: function () {\n this.center(this.options.center);\n },\n _createZoomControl: function (options) {\n var element = this._createControlElement(options, 'topLeft');\n var zoomControl = this.zoomControl = new ui.ZoomControl(element, options);\n this._zoomControlChange = proxy(this._zoomControlChange, this);\n zoomControl.bind('change', this._zoomControlChange);\n },\n _zoomControlChange: function (e) {\n if (!this.trigger('zoomStart', { originalEvent: e })) {\n this.zoom(this.zoom() + e.delta);\n this.trigger('zoomEnd', { originalEvent: e });\n }\n },\n _initScroller: function () {\n var friction = kendo.support.mobileOS ? FRICTION_MOBILE : FRICTION;\n var zoomable = this.options.zoomable !== false;\n var scroller = this.scroller = new kendo.mobile.ui.Scroller(this.element.children(0), {\n friction: friction,\n velocityMultiplier: VELOCITY_MULTIPLIER,\n zoom: zoomable,\n mousewheelScrolling: false,\n supportDoubleTap: true\n });\n scroller.bind('scroll', proxy(this._scroll, this));\n scroller.bind('scrollEnd', proxy(this._scrollEnd, this));\n scroller.userEvents.bind('gesturestart', proxy(this._scaleStart, this));\n scroller.userEvents.bind('gestureend', proxy(this._scale, this));\n scroller.userEvents.bind('doubleTap', proxy(this._doubleTap, this));\n scroller.userEvents.bind('tap', proxy(this._tap, this));\n this.scrollElement = scroller.scrollElement;\n },\n _initLayers: function () {\n var defs = this.options.layers, layers = this.layers = [];\n for (var i = 0; i < defs.length; i++) {\n var options = defs[i];\n var type = options.type || 'shape';\n var defaults = this.options.layerDefaults[type];\n var impl = dataviz.map.layers[type];\n layers.push(new impl(this, deepExtend({}, defaults, options)));\n }\n },\n _initMarkers: function () {\n this.markers = new map.layers.MarkerLayer(this, this.options.markerDefaults);\n this.markers.add(this.options.markers);\n },\n _scroll: function (e) {\n var origin = this.locationToLayer(this._viewOrigin).round();\n var movable = e.sender.movable;\n var offset = new g.Point(movable.x, movable.y).scale(-1).scale(1 / movable.scale);\n origin.x += offset.x;\n origin.y += offset.y;\n this._scrollOffset = offset;\n this._setOrigin(this.layerToLocation(origin));\n this.trigger('pan', {\n originalEvent: e,\n origin: this._getOrigin(),\n center: this.center()\n });\n },\n _scrollEnd: function (e) {\n if (!this._scrollOffset || !this._panComplete()) {\n return;\n }\n this._scrollOffset = null;\n this._panEndTS = new Date();\n this.trigger('panEnd', {\n originalEvent: e,\n origin: this._getOrigin(),\n center: this.center()\n });\n },\n _panComplete: function () {\n return new Date() - (this._panEndTS || 0) > 50;\n },\n _scaleStart: function (e) {\n if (this.trigger('zoomStart', { originalEvent: e })) {\n var touch = e.touches[1];\n if (touch) {\n touch.cancel();\n }\n }\n },\n _scale: function (e) {\n var scale = this.scroller.movable.scale;\n var zoom = this._scaleToZoom(scale);\n var gestureCenter = new g.Point(e.center.x, e.center.y);\n var centerLocation = this.viewToLocation(gestureCenter, zoom);\n var centerPoint = this.locationToLayer(centerLocation, zoom);\n var originPoint = centerPoint.translate(-gestureCenter.x, -gestureCenter.y);\n this._zoomAround(originPoint, zoom);\n this.trigger('zoomEnd', { originalEvent: e });\n },\n _scaleToZoom: function (scaleDelta) {\n var scale = this._layerSize() * scaleDelta;\n var tiles = scale / this.options.minSize;\n var zoom = math.log(tiles) / math.log(2);\n return math.round(zoom);\n },\n _reset: function () {\n if (this.attribution) {\n this.attribution.filter(this.center(), this.zoom());\n }\n this._viewOrigin = this._getOrigin(true);\n this._resetScroller();\n this.trigger('beforeReset');\n this.trigger('reset');\n },\n _resetScroller: function () {\n var scroller = this.scroller;\n var x = scroller.dimensions.x;\n var y = scroller.dimensions.y;\n var scale = this._layerSize();\n var nw = this.extent().nw;\n var topLeft = this.locationToLayer(nw).round();\n scroller.movable.round = true;\n scroller.reset();\n scroller.userEvents.cancel();\n var zoom = this.zoom();\n scroller.dimensions.forcedMinScale = pow(2, this.options.minZoom - zoom);\n scroller.dimensions.maxScale = pow(2, this.options.maxZoom - zoom);\n var xBounds = {\n min: -topLeft.x,\n max: scale - topLeft.x\n };\n var yBounds = {\n min: -topLeft.y,\n max: scale - topLeft.y\n };\n if (this.options.wraparound) {\n xBounds.max = 20 * scale;\n xBounds.min = -xBounds.max;\n }\n if (this.options.pannable === false) {\n var viewSize = this.viewSize();\n xBounds.min = yBounds.min = 0;\n xBounds.max = viewSize.width;\n yBounds.max = viewSize.height;\n }\n x.makeVirtual();\n y.makeVirtual();\n x.virtualSize(xBounds.min, xBounds.max);\n y.virtualSize(yBounds.min, yBounds.max);\n this._virtualSize = {\n x: xBounds,\n y: yBounds\n };\n },\n _renderLayers: function () {\n var defs = this.options.layers, layers = this.layers = [], scrollWrap = this.scrollWrap;\n scrollWrap.empty();\n for (var i = 0; i < defs.length; i++) {\n var options = defs[i];\n var type = options.type || 'shape';\n var defaults = this.options.layerDefaults[type];\n var impl = dataviz.map.layers[type];\n layers.push(new impl(this, deepExtend({}, defaults, options)));\n }\n },\n _layerSize: function (zoom) {\n zoom = valueOrDefault(zoom, this.options.zoom);\n return this.options.minSize * pow(2, zoom);\n },\n _tap: function (e) {\n if (!this._panComplete()) {\n return;\n }\n var cursor = this.eventOffset(e);\n this.trigger('click', {\n originalEvent: e,\n location: this.viewToLocation(cursor)\n });\n },\n _doubleTap: function (e) {\n var options = this.options;\n if (options.zoomable !== false) {\n if (!this.trigger('zoomStart', { originalEvent: e })) {\n var toZoom = this.zoom() + DEFAULT_ZOOM_RATE;\n var cursor = this.eventOffset(e);\n var location = this.viewToLocation(cursor);\n var postZoom = this.locationToLayer(location, toZoom);\n var origin = postZoom.translate(-cursor.x, -cursor.y);\n this._zoomAround(origin, toZoom);\n this.trigger('zoomEnd', { originalEvent: e });\n }\n }\n },\n _mousewheel: function (e) {\n e.preventDefault();\n var delta = dataviz.mwDelta(e) > 0 ? -1 : 1;\n var options = this.options;\n var fromZoom = this.zoom();\n var toZoom = limit(fromZoom + delta, options.minZoom, options.maxZoom);\n if (options.zoomable !== false && toZoom !== fromZoom) {\n if (!this.trigger('zoomStart', { originalEvent: e })) {\n var cursor = this.eventOffset(e);\n var location = this.viewToLocation(cursor);\n var postZoom = this.locationToLayer(location, toZoom);\n var origin = postZoom.translate(-cursor.x, -cursor.y);\n this._zoomAround(origin, toZoom);\n this.trigger('zoomEnd', { originalEvent: e });\n }\n }\n }\n });\n dataviz.ui.plugin(Map);\n }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.dataviz.map', [\n 'kendo.data',\n 'kendo.userevents',\n 'kendo.tooltip',\n 'kendo.mobile.scroller',\n 'kendo.draganddrop',\n 'kendo.dataviz.core',\n 'dataviz/map/location',\n 'dataviz/map/attribution',\n 'dataviz/map/navigator',\n 'dataviz/map/zoom',\n 'dataviz/map/crs',\n 'dataviz/map/layers/base',\n 'dataviz/map/layers/shape',\n 'dataviz/map/layers/bubble',\n 'dataviz/map/layers/tile',\n 'dataviz/map/layers/bing',\n 'dataviz/map/layers/marker',\n 'dataviz/map/main'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'dataviz.map',\n name: 'Map',\n category: 'dataviz',\n description: 'The Kendo DataViz Map displays spatial data',\n depends: [\n 'data',\n 'userevents',\n 'tooltip',\n 'dataviz.core',\n 'drawing',\n 'mobile.scroller'\n ]\n };\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));"]}