Commit 80cd89afbadfffee94c7d7641a2dc872991a8e64
1 parent
f100849ced
Exists in
master
vector maps
Showing
7 changed files
with
3656 additions
and
1 deletions
Show diff stats
app/index.html
... | ... | @@ -29,6 +29,7 @@ |
29 | 29 | <link rel="stylesheet" href="css/base-admin-3.css"/> |
30 | 30 | <link rel="stylesheet" href="css/base-admin-3-responsive.css"/> |
31 | 31 | <link rel="stylesheet" href="css/custom.css"/> |
32 | + <link rel="stylesheet" href="jvectormap-204/jquery-jvectormap-2.0.4.css"/> | |
32 | 33 | |
33 | 34 | <link href="css/bootstrap-responsive.min.css" rel="stylesheet"> |
34 | 35 | <link href="http://fonts.googleapis.com/css?family=Open+Sans:400italic,600italic,400,600" rel="stylesheet"> |
... | ... | @@ -134,6 +135,11 @@ |
134 | 135 | <script src="https://code.highcharts.com/maps/highmaps.js"></script> |
135 | 136 | <script src="https://code.highcharts.com/maps/modules/data.js"></script> |
136 | 137 | <script src="https://code.highcharts.com/mapdata/countries/us/us-all.js"></script> |
138 | + | |
139 | + | |
140 | + <script src="jvectormap-204/jquery-jvectormap-2.0.4.min.js"></script> | |
141 | + <script src="jvectormap-204/jquery-jvectormap-us-lcc.js"></script> | |
142 | + | |
137 | 143 | <!-- Controllers --> |
138 | 144 | <script src="js/app.js"></script> |
139 | 145 | <script src="js/app.constant.js"></script> | ... | ... |
app/js/app.constant.js
... | ... | @@ -4,9 +4,10 @@ |
4 | 4 | angular.module('acufuel') |
5 | 5 | |
6 | 6 | .constant('BASE_URL', { |
7 | - url: 'http://54.149.169.33:8080/ws' | |
7 | + // url: 'http://54.149.169.33:8080/ws' | |
8 | 8 | //url: 'http://192.168.1.175:8080/ws' |
9 | 9 | //url: 'http://192.168.1.8:8080/ws' |
10 | + url: 'http://192.168.2.137:8080/ws' | |
10 | 11 | |
11 | 12 | }) |
12 | 13 | ... | ... |
app/jvectormap-204/jquery-jvectormap-2.0.3.css
... | ... | @@ -0,0 +1,135 @@ |
1 | +svg { | |
2 | + touch-action: none; | |
3 | +} | |
4 | + | |
5 | +.jvectormap-container { | |
6 | + width: 100%; | |
7 | + height: 100%; | |
8 | + position: relative; | |
9 | + overflow: hidden; | |
10 | + touch-action: none; | |
11 | +} | |
12 | + | |
13 | +.jvectormap-tip { | |
14 | + position: absolute; | |
15 | + display: none; | |
16 | + border: solid 1px #CDCDCD; | |
17 | + border-radius: 3px; | |
18 | + background: #292929; | |
19 | + color: white; | |
20 | + font-family: sans-serif, Verdana; | |
21 | + font-size: smaller; | |
22 | + padding: 3px; | |
23 | +} | |
24 | + | |
25 | +.jvectormap-zoomin, .jvectormap-zoomout, .jvectormap-goback { | |
26 | + position: absolute; | |
27 | + left: 10px; | |
28 | + border-radius: 3px; | |
29 | + background: #292929; | |
30 | + padding: 3px; | |
31 | + color: white; | |
32 | + cursor: pointer; | |
33 | + line-height: 10px; | |
34 | + text-align: center; | |
35 | + box-sizing: content-box; | |
36 | +} | |
37 | + | |
38 | +.jvectormap-zoomin, .jvectormap-zoomout { | |
39 | + width: 10px; | |
40 | + height: 10px; | |
41 | +} | |
42 | + | |
43 | +.jvectormap-zoomin { | |
44 | + top: 10px; | |
45 | +} | |
46 | + | |
47 | +.jvectormap-zoomout { | |
48 | + top: 30px; | |
49 | +} | |
50 | + | |
51 | +.jvectormap-goback { | |
52 | + bottom: 10px; | |
53 | + z-index: 1000; | |
54 | + padding: 6px; | |
55 | +} | |
56 | + | |
57 | +.jvectormap-spinner { | |
58 | + position: absolute; | |
59 | + left: 0; | |
60 | + top: 0; | |
61 | + right: 0; | |
62 | + bottom: 0; | |
63 | + background: center no-repeat url(data:image/gif;base64,R0lGODlhIAAgAPMAAP///wAAAMbGxoSEhLa2tpqamjY2NlZWVtjY2OTk5Ly8vB4eHgQEBAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJCgAAACwAAAAAIAAgAAAE5xDISWlhperN52JLhSSdRgwVo1ICQZRUsiwHpTJT4iowNS8vyW2icCF6k8HMMBkCEDskxTBDAZwuAkkqIfxIQyhBQBFvAQSDITM5VDW6XNE4KagNh6Bgwe60smQUB3d4Rz1ZBApnFASDd0hihh12BkE9kjAJVlycXIg7CQIFA6SlnJ87paqbSKiKoqusnbMdmDC2tXQlkUhziYtyWTxIfy6BE8WJt5YJvpJivxNaGmLHT0VnOgSYf0dZXS7APdpB309RnHOG5gDqXGLDaC457D1zZ/V/nmOM82XiHRLYKhKP1oZmADdEAAAh+QQJCgAAACwAAAAAIAAgAAAE6hDISWlZpOrNp1lGNRSdRpDUolIGw5RUYhhHukqFu8DsrEyqnWThGvAmhVlteBvojpTDDBUEIFwMFBRAmBkSgOrBFZogCASwBDEY/CZSg7GSE0gSCjQBMVG023xWBhklAnoEdhQEfyNqMIcKjhRsjEdnezB+A4k8gTwJhFuiW4dokXiloUepBAp5qaKpp6+Ho7aWW54wl7obvEe0kRuoplCGepwSx2jJvqHEmGt6whJpGpfJCHmOoNHKaHx61WiSR92E4lbFoq+B6QDtuetcaBPnW6+O7wDHpIiK9SaVK5GgV543tzjgGcghAgAh+QQJCgAAACwAAAAAIAAgAAAE7hDISSkxpOrN5zFHNWRdhSiVoVLHspRUMoyUakyEe8PTPCATW9A14E0UvuAKMNAZKYUZCiBMuBakSQKG8G2FzUWox2AUtAQFcBKlVQoLgQReZhQlCIJesQXI5B0CBnUMOxMCenoCfTCEWBsJColTMANldx15BGs8B5wlCZ9Po6OJkwmRpnqkqnuSrayqfKmqpLajoiW5HJq7FL1Gr2mMMcKUMIiJgIemy7xZtJsTmsM4xHiKv5KMCXqfyUCJEonXPN2rAOIAmsfB3uPoAK++G+w48edZPK+M6hLJpQg484enXIdQFSS1u6UhksENEQAAIfkECQoAAAAsAAAAACAAIAAABOcQyEmpGKLqzWcZRVUQnZYg1aBSh2GUVEIQ2aQOE+G+cD4ntpWkZQj1JIiZIogDFFyHI0UxQwFugMSOFIPJftfVAEoZLBbcLEFhlQiqGp1Vd140AUklUN3eCA51C1EWMzMCezCBBmkxVIVHBWd3HHl9JQOIJSdSnJ0TDKChCwUJjoWMPaGqDKannasMo6WnM562R5YluZRwur0wpgqZE7NKUm+FNRPIhjBJxKZteWuIBMN4zRMIVIhffcgojwCF117i4nlLnY5ztRLsnOk+aV+oJY7V7m76PdkS4trKcdg0Zc0tTcKkRAAAIfkECQoAAAAsAAAAACAAIAAABO4QyEkpKqjqzScpRaVkXZWQEximw1BSCUEIlDohrft6cpKCk5xid5MNJTaAIkekKGQkWyKHkvhKsR7ARmitkAYDYRIbUQRQjWBwJRzChi9CRlBcY1UN4g0/VNB0AlcvcAYHRyZPdEQFYV8ccwR5HWxEJ02YmRMLnJ1xCYp0Y5idpQuhopmmC2KgojKasUQDk5BNAwwMOh2RtRq5uQuPZKGIJQIGwAwGf6I0JXMpC8C7kXWDBINFMxS4DKMAWVWAGYsAdNqW5uaRxkSKJOZKaU3tPOBZ4DuK2LATgJhkPJMgTwKCdFjyPHEnKxFCDhEAACH5BAkKAAAALAAAAAAgACAAAATzEMhJaVKp6s2nIkolIJ2WkBShpkVRWqqQrhLSEu9MZJKK9y1ZrqYK9WiClmvoUaF8gIQSNeF1Er4MNFn4SRSDARWroAIETg1iVwuHjYB1kYc1mwruwXKC9gmsJXliGxc+XiUCby9ydh1sOSdMkpMTBpaXBzsfhoc5l58Gm5yToAaZhaOUqjkDgCWNHAULCwOLaTmzswadEqggQwgHuQsHIoZCHQMMQgQGubVEcxOPFAcMDAYUA85eWARmfSRQCdcMe0zeP1AAygwLlJtPNAAL19DARdPzBOWSm1brJBi45soRAWQAAkrQIykShQ9wVhHCwCQCACH5BAkKAAAALAAAAAAgACAAAATrEMhJaVKp6s2nIkqFZF2VIBWhUsJaTokqUCoBq+E71SRQeyqUToLA7VxF0JDyIQh/MVVPMt1ECZlfcjZJ9mIKoaTl1MRIl5o4CUKXOwmyrCInCKqcWtvadL2SYhyASyNDJ0uIiRMDjI0Fd30/iI2UA5GSS5UDj2l6NoqgOgN4gksEBgYFf0FDqKgHnyZ9OX8HrgYHdHpcHQULXAS2qKpENRg7eAMLC7kTBaixUYFkKAzWAAnLC7FLVxLWDBLKCwaKTULgEwbLA4hJtOkSBNqITT3xEgfLpBtzE/jiuL04RGEBgwWhShRgQExHBAAh+QQJCgAAACwAAAAAIAAgAAAE7xDISWlSqerNpyJKhWRdlSAVoVLCWk6JKlAqAavhO9UkUHsqlE6CwO1cRdCQ8iEIfzFVTzLdRAmZX3I2SfZiCqGk5dTESJeaOAlClzsJsqwiJwiqnFrb2nS9kmIcgEsjQydLiIlHehhpejaIjzh9eomSjZR+ipslWIRLAgMDOR2DOqKogTB9pCUJBagDBXR6XB0EBkIIsaRsGGMMAxoDBgYHTKJiUYEGDAzHC9EACcUGkIgFzgwZ0QsSBcXHiQvOwgDdEwfFs0sDzt4S6BK4xYjkDOzn0unFeBzOBijIm1Dgmg5YFQwsCMjp1oJ8LyIAACH5BAkKAAAALAAAAAAgACAAAATwEMhJaVKp6s2nIkqFZF2VIBWhUsJaTokqUCoBq+E71SRQeyqUToLA7VxF0JDyIQh/MVVPMt1ECZlfcjZJ9mIKoaTl1MRIl5o4CUKXOwmyrCInCKqcWtvadL2SYhyASyNDJ0uIiUd6GGl6NoiPOH16iZKNlH6KmyWFOggHhEEvAwwMA0N9GBsEC6amhnVcEwavDAazGwIDaH1ipaYLBUTCGgQDA8NdHz0FpqgTBwsLqAbWAAnIA4FWKdMLGdYGEgraigbT0OITBcg5QwPT4xLrROZL6AuQAPUS7bxLpoWidY0JtxLHKhwwMJBTHgPKdEQAACH5BAkKAAAALAAAAAAgACAAAATrEMhJaVKp6s2nIkqFZF2VIBWhUsJaTokqUCoBq+E71SRQeyqUToLA7VxF0JDyIQh/MVVPMt1ECZlfcjZJ9mIKoaTl1MRIl5o4CUKXOwmyrCInCKqcWtvadL2SYhyASyNDJ0uIiUd6GAULDJCRiXo1CpGXDJOUjY+Yip9DhToJA4RBLwMLCwVDfRgbBAaqqoZ1XBMHswsHtxtFaH1iqaoGNgAIxRpbFAgfPQSqpbgGBqUD1wBXeCYp1AYZ19JJOYgH1KwA4UBvQwXUBxPqVD9L3sbp2BNk2xvvFPJd+MFCN6HAAIKgNggY0KtEBAAh+QQJCgAAACwAAAAAIAAgAAAE6BDISWlSqerNpyJKhWRdlSAVoVLCWk6JKlAqAavhO9UkUHsqlE6CwO1cRdCQ8iEIfzFVTzLdRAmZX3I2SfYIDMaAFdTESJeaEDAIMxYFqrOUaNW4E4ObYcCXaiBVEgULe0NJaxxtYksjh2NLkZISgDgJhHthkpU4mW6blRiYmZOlh4JWkDqILwUGBnE6TYEbCgevr0N1gH4At7gHiRpFaLNrrq8HNgAJA70AWxQIH1+vsYMDAzZQPC9VCNkDWUhGkuE5PxJNwiUK4UfLzOlD4WvzAHaoG9nxPi5d+jYUqfAhhykOFwJWiAAAIfkECQoAAAAsAAAAACAAIAAABPAQyElpUqnqzaciSoVkXVUMFaFSwlpOCcMYlErAavhOMnNLNo8KsZsMZItJEIDIFSkLGQoQTNhIsFehRww2CQLKF0tYGKYSg+ygsZIuNqJksKgbfgIGepNo2cIUB3V1B3IvNiBYNQaDSTtfhhx0CwVPI0UJe0+bm4g5VgcGoqOcnjmjqDSdnhgEoamcsZuXO1aWQy8KAwOAuTYYGwi7w5h+Kr0SJ8MFihpNbx+4Erq7BYBuzsdiH1jCAzoSfl0rVirNbRXlBBlLX+BP0XJLAPGzTkAuAOqb0WT5AH7OcdCm5B8TgRwSRKIHQtaLCwg1RAAAOwAAAAAAAAAAAA==); | |
64 | +} | |
65 | + | |
66 | +.jvectormap-legend-title { | |
67 | + font-weight: bold; | |
68 | + font-size: 14px; | |
69 | + text-align: center; | |
70 | +} | |
71 | + | |
72 | +.jvectormap-legend-cnt { | |
73 | + position: absolute; | |
74 | +} | |
75 | + | |
76 | +.jvectormap-legend-cnt-h { | |
77 | + bottom: 0; | |
78 | + right: 0; | |
79 | +} | |
80 | + | |
81 | +.jvectormap-legend-cnt-v { | |
82 | + top: 0; | |
83 | + right: 0; | |
84 | +} | |
85 | + | |
86 | +.jvectormap-legend { | |
87 | + background: black; | |
88 | + color: white; | |
89 | + border-radius: 3px; | |
90 | +} | |
91 | + | |
92 | +.jvectormap-legend-cnt-h .jvectormap-legend { | |
93 | + float: left; | |
94 | + margin: 0 10px 10px 0; | |
95 | + padding: 3px 3px 1px 3px; | |
96 | +} | |
97 | + | |
98 | +.jvectormap-legend-cnt-h .jvectormap-legend .jvectormap-legend-tick { | |
99 | + float: left; | |
100 | +} | |
101 | + | |
102 | +.jvectormap-legend-cnt-v .jvectormap-legend { | |
103 | + margin: 10px 10px 0 0; | |
104 | + padding: 3px; | |
105 | +} | |
106 | + | |
107 | +.jvectormap-legend-cnt-h .jvectormap-legend-tick { | |
108 | + width: 40px; | |
109 | +} | |
110 | + | |
111 | +.jvectormap-legend-cnt-h .jvectormap-legend-tick-sample { | |
112 | + height: 15px; | |
113 | +} | |
114 | + | |
115 | +.jvectormap-legend-cnt-v .jvectormap-legend-tick-sample { | |
116 | + height: 20px; | |
117 | + width: 20px; | |
118 | + display: inline-block; | |
119 | + vertical-align: middle; | |
120 | +} | |
121 | + | |
122 | +.jvectormap-legend-tick-text { | |
123 | + font-size: 12px; | |
124 | +} | |
125 | + | |
126 | +.jvectormap-legend-cnt-h .jvectormap-legend-tick-text { | |
127 | + text-align: center; | |
128 | +} | |
129 | + | |
130 | +.jvectormap-legend-cnt-v .jvectormap-legend-tick-text { | |
131 | + display: inline-block; | |
132 | + vertical-align: middle; | |
133 | + line-height: 20px; | |
134 | + padding-left: 3px; | |
135 | +} | |
0 | 136 | \ No newline at end of file | ... | ... |
app/jvectormap-204/jquery-jvectormap-2.0.3.min.js
... | ... | @@ -0,0 +1,2 @@ |
1 | +!function($){var apiParams={set:{colors:1,values:1,backgroundColor:1,scaleColors:1,normalizeFunction:1,focus:1},get:{selectedRegions:1,selectedMarkers:1,mapObject:1,regionName:1}};$.fn.vectorMap=function(options){var map,methodName,map=this.children(".jvectormap-container").data("mapObject");if("addMap"===options)jvm.Map.maps[arguments[1]]=arguments[2];else{if(("set"===options||"get"===options)&&apiParams[options][arguments[1]])return methodName=arguments[1].charAt(0).toUpperCase()+arguments[1].substr(1),map[options+methodName].apply(map,Array.prototype.slice.call(arguments,2));options=options||{},options.container=this,map=new jvm.Map(options)}return this}}(jQuery),function(factory){"function"==typeof define&&define.amd?define(["jquery"],factory):"object"==typeof exports?module.exports=factory:factory(jQuery)}(function($){function handler(event){var orgEvent=event||window.event,args=slice.call(arguments,1),delta=0,deltaX=0,deltaY=0,absDelta=0;if(event=$.event.fix(orgEvent),event.type="mousewheel","detail"in orgEvent&&(deltaY=-1*orgEvent.detail),"wheelDelta"in orgEvent&&(deltaY=orgEvent.wheelDelta),"wheelDeltaY"in orgEvent&&(deltaY=orgEvent.wheelDeltaY),"wheelDeltaX"in orgEvent&&(deltaX=-1*orgEvent.wheelDeltaX),"axis"in orgEvent&&orgEvent.axis===orgEvent.HORIZONTAL_AXIS&&(deltaX=-1*deltaY,deltaY=0),delta=0===deltaY?deltaX:deltaY,"deltaY"in orgEvent&&(deltaY=-1*orgEvent.deltaY,delta=deltaY),"deltaX"in orgEvent&&(deltaX=orgEvent.deltaX,0===deltaY&&(delta=-1*deltaX)),0!==deltaY||0!==deltaX){if(1===orgEvent.deltaMode){var lineHeight=$.data(this,"mousewheel-line-height");delta*=lineHeight,deltaY*=lineHeight,deltaX*=lineHeight}else if(2===orgEvent.deltaMode){var pageHeight=$.data(this,"mousewheel-page-height");delta*=pageHeight,deltaY*=pageHeight,deltaX*=pageHeight}return absDelta=Math.max(Math.abs(deltaY),Math.abs(deltaX)),(!lowestDelta||lowestDelta>absDelta)&&(lowestDelta=absDelta,shouldAdjustOldDeltas(orgEvent,absDelta)&&(lowestDelta/=40)),shouldAdjustOldDeltas(orgEvent,absDelta)&&(delta/=40,deltaX/=40,deltaY/=40),delta=Math[delta>=1?"floor":"ceil"](delta/lowestDelta),deltaX=Math[deltaX>=1?"floor":"ceil"](deltaX/lowestDelta),deltaY=Math[deltaY>=1?"floor":"ceil"](deltaY/lowestDelta),event.deltaX=deltaX,event.deltaY=deltaY,event.deltaFactor=lowestDelta,event.deltaMode=0,args.unshift(event,delta,deltaX,deltaY),nullLowestDeltaTimeout&&clearTimeout(nullLowestDeltaTimeout),nullLowestDeltaTimeout=setTimeout(nullLowestDelta,200),($.event.dispatch||$.event.handle).apply(this,args)}}function nullLowestDelta(){lowestDelta=null}function shouldAdjustOldDeltas(orgEvent,absDelta){return special.settings.adjustOldDeltas&&"mousewheel"===orgEvent.type&&absDelta%120===0}var nullLowestDeltaTimeout,lowestDelta,toFix=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],toBind="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],slice=Array.prototype.slice;if($.event.fixHooks)for(var i=toFix.length;i;)$.event.fixHooks[toFix[--i]]=$.event.mouseHooks;var special=$.event.special.mousewheel={version:"3.1.9",setup:function(){if(this.addEventListener)for(var i=toBind.length;i;)this.addEventListener(toBind[--i],handler,!1);else this.onmousewheel=handler;$.data(this,"mousewheel-line-height",special.getLineHeight(this)),$.data(this,"mousewheel-page-height",special.getPageHeight(this))},teardown:function(){if(this.removeEventListener)for(var i=toBind.length;i;)this.removeEventListener(toBind[--i],handler,!1);else this.onmousewheel=null},getLineHeight:function(elem){return parseInt($(elem)["offsetParent"in $.fn?"offsetParent":"parent"]().css("fontSize"),10)},getPageHeight:function(elem){return $(elem).height()},settings:{adjustOldDeltas:!0}};$.fn.extend({mousewheel:function(fn){return fn?this.bind("mousewheel",fn):this.trigger("mousewheel")},unmousewheel:function(fn){return this.unbind("mousewheel",fn)}})});var jvm={inherits:function(child,parent){function temp(){}temp.prototype=parent.prototype,child.prototype=new temp,child.prototype.constructor=child,child.parentClass=parent},mixin:function(target,source){var prop;for(prop in source.prototype)source.prototype.hasOwnProperty(prop)&&(target.prototype[prop]=source.prototype[prop])},min:function(values){var i,min=Number.MAX_VALUE;if(values instanceof Array)for(i=0;i<values.length;i++)values[i]<min&&(min=values[i]);else for(i in values)values[i]<min&&(min=values[i]);return min},max:function(values){var i,max=Number.MIN_VALUE;if(values instanceof Array)for(i=0;i<values.length;i++)values[i]>max&&(max=values[i]);else for(i in values)values[i]>max&&(max=values[i]);return max},keys:function(object){var key,keys=[];for(key in object)keys.push(key);return keys},values:function(object){var key,i,values=[];for(i=0;i<arguments.length;i++){object=arguments[i];for(key in object)values.push(object[key])}return values},whenImageLoaded:function(url){var deferred=new jvm.$.Deferred,img=jvm.$("<img/>");return img.error(function(){deferred.reject()}).load(function(){deferred.resolve(img)}),img.attr("src",url),deferred},isImageUrl:function(s){return/\.\w{3,4}$/.test(s)}};jvm.$=jQuery,Array.prototype.indexOf||(Array.prototype.indexOf=function(searchElement,fromIndex){var k;if(null==this)throw new TypeError('"this" is null or not defined');var O=Object(this),len=O.length>>>0;if(0===len)return-1;var n=+fromIndex||0;if(1/0===Math.abs(n)&&(n=0),n>=len)return-1;for(k=Math.max(n>=0?n:len-Math.abs(n),0);len>k;){if(k in O&&O[k]===searchElement)return k;k++}return-1}),jvm.AbstractElement=function(name,config){this.node=this.createElement(name),this.name=name,this.properties={},config&&this.set(config)},jvm.AbstractElement.prototype.set=function(property,value){var key;if("object"==typeof property)for(key in property)this.properties[key]=property[key],this.applyAttr(key,property[key]);else this.properties[property]=value,this.applyAttr(property,value)},jvm.AbstractElement.prototype.get=function(property){return this.properties[property]},jvm.AbstractElement.prototype.applyAttr=function(property,value){this.node.setAttribute(property,value)},jvm.AbstractElement.prototype.remove=function(){jvm.$(this.node).remove()},jvm.AbstractCanvasElement=function(container,width,height){this.container=container,this.setSize(width,height),this.rootElement=new jvm[this.classPrefix+"GroupElement"],this.node.appendChild(this.rootElement.node),this.container.appendChild(this.node)},jvm.AbstractCanvasElement.prototype.add=function(element,group){group=group||this.rootElement,group.add(element),element.canvas=this},jvm.AbstractCanvasElement.prototype.addPath=function(config,style,group){var el=new jvm[this.classPrefix+"PathElement"](config,style);return this.add(el,group),el},jvm.AbstractCanvasElement.prototype.addCircle=function(config,style,group){var el=new jvm[this.classPrefix+"CircleElement"](config,style);return this.add(el,group),el},jvm.AbstractCanvasElement.prototype.addImage=function(config,style,group){var el=new jvm[this.classPrefix+"ImageElement"](config,style);return this.add(el,group),el},jvm.AbstractCanvasElement.prototype.addText=function(config,style,group){var el=new jvm[this.classPrefix+"TextElement"](config,style);return this.add(el,group),el},jvm.AbstractCanvasElement.prototype.addGroup=function(parentGroup){var el=new jvm[this.classPrefix+"GroupElement"];return parentGroup?parentGroup.node.appendChild(el.node):this.node.appendChild(el.node),el.canvas=this,el},jvm.AbstractShapeElement=function(name,config,style){this.style=style||{},this.style.current=this.style.current||{},this.isHovered=!1,this.isSelected=!1,this.updateStyle()},jvm.AbstractShapeElement.prototype.setStyle=function(property,value){var styles={};"object"==typeof property?styles=property:styles[property]=value,jvm.$.extend(this.style.current,styles),this.updateStyle()},jvm.AbstractShapeElement.prototype.updateStyle=function(){var attrs={};jvm.AbstractShapeElement.mergeStyles(attrs,this.style.initial),jvm.AbstractShapeElement.mergeStyles(attrs,this.style.current),this.isHovered&&jvm.AbstractShapeElement.mergeStyles(attrs,this.style.hover),this.isSelected&&(jvm.AbstractShapeElement.mergeStyles(attrs,this.style.selected),this.isHovered&&jvm.AbstractShapeElement.mergeStyles(attrs,this.style.selectedHover)),this.set(attrs)},jvm.AbstractShapeElement.mergeStyles=function(styles,newStyles){var key;newStyles=newStyles||{};for(key in newStyles)null===newStyles[key]?delete styles[key]:styles[key]=newStyles[key]},jvm.SVGElement=function(){jvm.SVGElement.parentClass.apply(this,arguments)},jvm.inherits(jvm.SVGElement,jvm.AbstractElement),jvm.SVGElement.svgns="http://www.w3.org/2000/svg",jvm.SVGElement.prototype.createElement=function(tagName){return document.createElementNS(jvm.SVGElement.svgns,tagName)},jvm.SVGElement.prototype.addClass=function(className){this.node.setAttribute("class",className)},jvm.SVGElement.prototype.getElementCtr=function(ctr){return jvm["SVG"+ctr]},jvm.SVGElement.prototype.getBBox=function(){return this.node.getBBox()},jvm.SVGGroupElement=function(){jvm.SVGGroupElement.parentClass.call(this,"g")},jvm.inherits(jvm.SVGGroupElement,jvm.SVGElement),jvm.SVGGroupElement.prototype.add=function(element){this.node.appendChild(element.node)},jvm.SVGCanvasElement=function(){this.classPrefix="SVG",jvm.SVGCanvasElement.parentClass.call(this,"svg"),this.defsElement=new jvm.SVGElement("defs"),this.node.appendChild(this.defsElement.node),jvm.AbstractCanvasElement.apply(this,arguments)},jvm.inherits(jvm.SVGCanvasElement,jvm.SVGElement),jvm.mixin(jvm.SVGCanvasElement,jvm.AbstractCanvasElement),jvm.SVGCanvasElement.prototype.setSize=function(width,height){this.width=width,this.height=height,this.node.setAttribute("width",width),this.node.setAttribute("height",height)},jvm.SVGCanvasElement.prototype.applyTransformParams=function(scale,transX,transY){this.scale=scale,this.transX=transX,this.transY=transY,this.rootElement.node.setAttribute("transform","scale("+scale+") translate("+transX+", "+transY+")")},jvm.SVGShapeElement=function(name,config){jvm.SVGShapeElement.parentClass.call(this,name,config),jvm.AbstractShapeElement.apply(this,arguments)},jvm.inherits(jvm.SVGShapeElement,jvm.SVGElement),jvm.mixin(jvm.SVGShapeElement,jvm.AbstractShapeElement),jvm.SVGShapeElement.prototype.applyAttr=function(attr,value){var patternEl,imageEl,that=this;"fill"===attr&&jvm.isImageUrl(value)?jvm.SVGShapeElement.images[value]?this.applyAttr("fill","url(#image"+jvm.SVGShapeElement.images[value]+")"):jvm.whenImageLoaded(value).then(function(img){imageEl=new jvm.SVGElement("image"),imageEl.node.setAttributeNS("http://www.w3.org/1999/xlink","href",value),imageEl.applyAttr("x","0"),imageEl.applyAttr("y","0"),imageEl.applyAttr("width",img[0].width),imageEl.applyAttr("height",img[0].height),patternEl=new jvm.SVGElement("pattern"),patternEl.applyAttr("id","image"+jvm.SVGShapeElement.imageCounter),patternEl.applyAttr("x",0),patternEl.applyAttr("y",0),patternEl.applyAttr("width",img[0].width/2),patternEl.applyAttr("height",img[0].height/2),patternEl.applyAttr("viewBox","0 0 "+img[0].width+" "+img[0].height),patternEl.applyAttr("patternUnits","userSpaceOnUse"),patternEl.node.appendChild(imageEl.node),that.canvas.defsElement.node.appendChild(patternEl.node),jvm.SVGShapeElement.images[value]=jvm.SVGShapeElement.imageCounter++,that.applyAttr("fill","url(#image"+jvm.SVGShapeElement.images[value]+")")}):jvm.SVGShapeElement.parentClass.prototype.applyAttr.apply(this,arguments)},jvm.SVGShapeElement.imageCounter=1,jvm.SVGShapeElement.images={},jvm.SVGPathElement=function(config,style){jvm.SVGPathElement.parentClass.call(this,"path",config,style),this.node.setAttribute("fill-rule","evenodd")},jvm.inherits(jvm.SVGPathElement,jvm.SVGShapeElement),jvm.SVGCircleElement=function(config,style){jvm.SVGCircleElement.parentClass.call(this,"circle",config,style)},jvm.inherits(jvm.SVGCircleElement,jvm.SVGShapeElement),jvm.SVGImageElement=function(config,style){jvm.SVGImageElement.parentClass.call(this,"image",config,style)},jvm.inherits(jvm.SVGImageElement,jvm.SVGShapeElement),jvm.SVGImageElement.prototype.applyAttr=function(attr,value){var that=this;"image"==attr?jvm.whenImageLoaded(value).then(function(img){that.node.setAttributeNS("http://www.w3.org/1999/xlink","href",value),that.width=img[0].width,that.height=img[0].height,that.applyAttr("width",that.width),that.applyAttr("height",that.height),that.applyAttr("x",that.cx-that.width/2),that.applyAttr("y",that.cy-that.height/2),jvm.$(that.node).trigger("imageloaded",[img])}):"cx"==attr?(this.cx=value,this.width&&this.applyAttr("x",value-this.width/2)):"cy"==attr?(this.cy=value,this.height&&this.applyAttr("y",value-this.height/2)):jvm.SVGImageElement.parentClass.prototype.applyAttr.apply(this,arguments)},jvm.SVGTextElement=function(config,style){jvm.SVGTextElement.parentClass.call(this,"text",config,style)},jvm.inherits(jvm.SVGTextElement,jvm.SVGShapeElement),jvm.SVGTextElement.prototype.applyAttr=function(attr,value){"text"===attr?this.node.textContent=value:jvm.SVGTextElement.parentClass.prototype.applyAttr.apply(this,arguments)},jvm.VMLElement=function(){jvm.VMLElement.VMLInitialized||jvm.VMLElement.initializeVML(),jvm.VMLElement.parentClass.apply(this,arguments)},jvm.inherits(jvm.VMLElement,jvm.AbstractElement),jvm.VMLElement.VMLInitialized=!1,jvm.VMLElement.initializeVML=function(){try{document.namespaces.rvml||document.namespaces.add("rvml","urn:schemas-microsoft-com:vml"),jvm.VMLElement.prototype.createElement=function(tagName){return document.createElement("<rvml:"+tagName+' class="rvml">')}}catch(e){jvm.VMLElement.prototype.createElement=function(tagName){return document.createElement("<"+tagName+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}document.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)"),jvm.VMLElement.VMLInitialized=!0},jvm.VMLElement.prototype.getElementCtr=function(ctr){return jvm["VML"+ctr]},jvm.VMLElement.prototype.addClass=function(className){jvm.$(this.node).addClass(className)},jvm.VMLElement.prototype.applyAttr=function(attr,value){this.node[attr]=value},jvm.VMLElement.prototype.getBBox=function(){var node=jvm.$(this.node);return{x:node.position().left/this.canvas.scale,y:node.position().top/this.canvas.scale,width:node.width()/this.canvas.scale,height:node.height()/this.canvas.scale}},jvm.VMLGroupElement=function(){jvm.VMLGroupElement.parentClass.call(this,"group"),this.node.style.left="0px",this.node.style.top="0px",this.node.coordorigin="0 0"},jvm.inherits(jvm.VMLGroupElement,jvm.VMLElement),jvm.VMLGroupElement.prototype.add=function(element){this.node.appendChild(element.node)},jvm.VMLCanvasElement=function(){this.classPrefix="VML",jvm.VMLCanvasElement.parentClass.call(this,"group"),jvm.AbstractCanvasElement.apply(this,arguments),this.node.style.position="absolute"},jvm.inherits(jvm.VMLCanvasElement,jvm.VMLElement),jvm.mixin(jvm.VMLCanvasElement,jvm.AbstractCanvasElement),jvm.VMLCanvasElement.prototype.setSize=function(width,height){var paths,groups,i,l;if(this.width=width,this.height=height,this.node.style.width=width+"px",this.node.style.height=height+"px",this.node.coordsize=width+" "+height,this.node.coordorigin="0 0",this.rootElement){for(paths=this.rootElement.node.getElementsByTagName("shape"),i=0,l=paths.length;l>i;i++)paths[i].coordsize=width+" "+height,paths[i].style.width=width+"px",paths[i].style.height=height+"px";for(groups=this.node.getElementsByTagName("group"),i=0,l=groups.length;l>i;i++)groups[i].coordsize=width+" "+height,groups[i].style.width=width+"px",groups[i].style.height=height+"px"}},jvm.VMLCanvasElement.prototype.applyTransformParams=function(scale,transX,transY){this.scale=scale,this.transX=transX,this.transY=transY,this.rootElement.node.coordorigin=this.width-transX-this.width/100+","+(this.height-transY-this.height/100),this.rootElement.node.coordsize=this.width/scale+","+this.height/scale},jvm.VMLShapeElement=function(name,config){jvm.VMLShapeElement.parentClass.call(this,name,config),this.fillElement=new jvm.VMLElement("fill"),this.strokeElement=new jvm.VMLElement("stroke"),this.node.appendChild(this.fillElement.node),this.node.appendChild(this.strokeElement.node),this.node.stroked=!1,jvm.AbstractShapeElement.apply(this,arguments)},jvm.inherits(jvm.VMLShapeElement,jvm.VMLElement),jvm.mixin(jvm.VMLShapeElement,jvm.AbstractShapeElement),jvm.VMLShapeElement.prototype.applyAttr=function(attr,value){switch(attr){case"fill":this.node.fillcolor=value;break;case"fill-opacity":this.fillElement.node.opacity=Math.round(100*value)+"%";break;case"stroke":this.node.stroked="none"===value?!1:!0,this.node.strokecolor=value;break;case"stroke-opacity":this.strokeElement.node.opacity=Math.round(100*value)+"%";break;case"stroke-width":this.node.stroked=0===parseInt(value,10)?!1:!0,this.node.strokeweight=value;break;case"d":this.node.path=jvm.VMLPathElement.pathSvgToVml(value);break;default:jvm.VMLShapeElement.parentClass.prototype.applyAttr.apply(this,arguments)}},jvm.VMLPathElement=function(config,style){var scale=new jvm.VMLElement("skew");jvm.VMLPathElement.parentClass.call(this,"shape",config,style),this.node.coordorigin="0 0",scale.node.on=!0,scale.node.matrix="0.01,0,0,0.01,0,0",scale.node.offset="0,0",this.node.appendChild(scale.node)},jvm.inherits(jvm.VMLPathElement,jvm.VMLShapeElement),jvm.VMLPathElement.prototype.applyAttr=function(attr,value){"d"===attr?this.node.path=jvm.VMLPathElement.pathSvgToVml(value):jvm.VMLShapeElement.prototype.applyAttr.call(this,attr,value)},jvm.VMLPathElement.pathSvgToVml=function(path){var ctrlx,ctrly,cx=0,cy=0;return path=path.replace(/(-?\d+)e(-?\d+)/g,"0"),path.replace(/([MmLlHhVvCcSs])\s*((?:-?\d*(?:\.\d+)?\s*,?\s*)+)/g,function(segment,letter,coords){coords=coords.replace(/(\d)-/g,"$1,-").replace(/^\s+/g,"").replace(/\s+$/g,"").replace(/\s+/g,",").split(","),coords[0]||coords.shift();for(var i=0,l=coords.length;l>i;i++)coords[i]=Math.round(100*coords[i]);switch(letter){case"m":return cx+=coords[0],cy+=coords[1],"t"+coords.join(",");case"M":return cx=coords[0],cy=coords[1],"m"+coords.join(",");case"l":return cx+=coords[0],cy+=coords[1],"r"+coords.join(",");case"L":return cx=coords[0],cy=coords[1],"l"+coords.join(",");case"h":return cx+=coords[0],"r"+coords[0]+",0";case"H":return cx=coords[0],"l"+cx+","+cy;case"v":return cy+=coords[0],"r0,"+coords[0];case"V":return cy=coords[0],"l"+cx+","+cy;case"c":return ctrlx=cx+coords[coords.length-4],ctrly=cy+coords[coords.length-3],cx+=coords[coords.length-2],cy+=coords[coords.length-1],"v"+coords.join(",");case"C":return ctrlx=coords[coords.length-4],ctrly=coords[coords.length-3],cx=coords[coords.length-2],cy=coords[coords.length-1],"c"+coords.join(",");case"s":return coords.unshift(cy-ctrly),coords.unshift(cx-ctrlx),ctrlx=cx+coords[coords.length-4],ctrly=cy+coords[coords.length-3],cx+=coords[coords.length-2],cy+=coords[coords.length-1],"v"+coords.join(",");case"S":return coords.unshift(cy+cy-ctrly),coords.unshift(cx+cx-ctrlx),ctrlx=coords[coords.length-4],ctrly=coords[coords.length-3],cx=coords[coords.length-2],cy=coords[coords.length-1],"c"+coords.join(",")}return""}).replace(/z/g,"e")},jvm.VMLCircleElement=function(config,style){jvm.VMLCircleElement.parentClass.call(this,"oval",config,style)},jvm.inherits(jvm.VMLCircleElement,jvm.VMLShapeElement),jvm.VMLCircleElement.prototype.applyAttr=function(attr,value){switch(attr){case"r":this.node.style.width=2*value+"px",this.node.style.height=2*value+"px",this.applyAttr("cx",this.get("cx")||0),this.applyAttr("cy",this.get("cy")||0);break;case"cx":if(!value)return;this.node.style.left=value-(this.get("r")||0)+"px";break;case"cy":if(!value)return;this.node.style.top=value-(this.get("r")||0)+"px";break;default:jvm.VMLCircleElement.parentClass.prototype.applyAttr.call(this,attr,value)}},jvm.VectorCanvas=function(container,width,height){return this.mode=window.SVGAngle?"svg":"vml",this.impl="svg"==this.mode?new jvm.SVGCanvasElement(container,width,height):new jvm.VMLCanvasElement(container,width,height),this.impl.mode=this.mode,this.impl},jvm.SimpleScale=function(scale){this.scale=scale},jvm.SimpleScale.prototype.getValue=function(value){return value},jvm.OrdinalScale=function(scale){this.scale=scale},jvm.OrdinalScale.prototype.getValue=function(value){return this.scale[value]},jvm.OrdinalScale.prototype.getTicks=function(){var key,ticks=[];for(key in this.scale)ticks.push({label:key,value:this.scale[key]});return ticks},jvm.NumericScale=function(scale,normalizeFunction,minValue,maxValue){this.scale=[],normalizeFunction=normalizeFunction||"linear",scale&&this.setScale(scale),normalizeFunction&&this.setNormalizeFunction(normalizeFunction),"undefined"!=typeof minValue&&this.setMin(minValue),"undefined"!=typeof maxValue&&this.setMax(maxValue)},jvm.NumericScale.prototype={setMin:function(min){this.clearMinValue=min,this.minValue="function"==typeof this.normalize?this.normalize(min):min},setMax:function(max){this.clearMaxValue=max,this.maxValue="function"==typeof this.normalize?this.normalize(max):max},setScale:function(scale){var i;for(this.scale=[],i=0;i<scale.length;i++)this.scale[i]=[scale[i]]},setNormalizeFunction:function(f){"polynomial"===f?this.normalize=function(value){return Math.pow(value,.2)}:"linear"===f?delete this.normalize:this.normalize=f,this.setMin(this.clearMinValue),this.setMax(this.clearMaxValue)},getValue:function(value){var l,c,lengthes=[],fullLength=0,i=0;for("function"==typeof this.normalize&&(value=this.normalize(value)),i=0;i<this.scale.length-1;i++)l=this.vectorLength(this.vectorSubtract(this.scale[i+1],this.scale[i])),lengthes.push(l),fullLength+=l;for(c=(this.maxValue-this.minValue)/fullLength,i=0;i<lengthes.length;i++)lengthes[i]*=c;for(i=0,value-=this.minValue;value-lengthes[i]>=0;)value-=lengthes[i],i++;return value=this.vectorToNum(i==this.scale.length-1?this.scale[i]:this.vectorAdd(this.scale[i],this.vectorMult(this.vectorSubtract(this.scale[i+1],this.scale[i]),value/lengthes[i])))},vectorToNum:function(vector){var i,num=0;for(i=0;i<vector.length;i++)num+=Math.round(vector[i])*Math.pow(256,vector.length-i-1);return num},vectorSubtract:function(vector1,vector2){var i,vector=[];for(i=0;i<vector1.length;i++)vector[i]=vector1[i]-vector2[i];return vector},vectorAdd:function(vector1,vector2){var i,vector=[];for(i=0;i<vector1.length;i++)vector[i]=vector1[i]+vector2[i];return vector},vectorMult:function(vector,num){var i,result=[];for(i=0;i<vector.length;i++)result[i]=vector[i]*num;return result},vectorLength:function(vector){var i,result=0;for(i=0;i<vector.length;i++)result+=vector[i]*vector[i];return Math.sqrt(result)},getTicks:function(){var tick,v,m=5,extent=[this.clearMinValue,this.clearMaxValue],span=extent[1]-extent[0],step=Math.pow(10,Math.floor(Math.log(span/m)/Math.LN10)),err=m/span*step,ticks=[];for(.15>=err?step*=10:.35>=err?step*=5:.75>=err&&(step*=2),extent[0]=Math.floor(extent[0]/step)*step,extent[1]=Math.ceil(extent[1]/step)*step,tick=extent[0];tick<=extent[1];)v=tick==extent[0]?this.clearMinValue:tick==extent[1]?this.clearMaxValue:tick,ticks.push({label:tick,value:this.getValue(v)}),tick+=step;return ticks}},jvm.ColorScale=function(){jvm.ColorScale.parentClass.apply(this,arguments)},jvm.inherits(jvm.ColorScale,jvm.NumericScale),jvm.ColorScale.prototype.setScale=function(scale){var i;for(i=0;i<scale.length;i++)this.scale[i]=jvm.ColorScale.rgbToArray(scale[i])},jvm.ColorScale.prototype.getValue=function(value){return jvm.ColorScale.numToRgb(jvm.ColorScale.parentClass.prototype.getValue.call(this,value))},jvm.ColorScale.arrayToRgb=function(ar){var d,i,rgb="#";for(i=0;i<ar.length;i++)d=ar[i].toString(16),rgb+=1==d.length?"0"+d:d;return rgb},jvm.ColorScale.numToRgb=function(num){for(num=num.toString(16);num.length<6;)num="0"+num;return"#"+num},jvm.ColorScale.rgbToArray=function(rgb){return rgb=rgb.substr(1),[parseInt(rgb.substr(0,2),16),parseInt(rgb.substr(2,2),16),parseInt(rgb.substr(4,2),16)]},jvm.Legend=function(params){this.params=params||{},this.map=this.params.map,this.series=this.params.series,this.body=jvm.$("<div/>"),this.body.addClass("jvectormap-legend"),this.params.cssClass&&this.body.addClass(this.params.cssClass),params.vertical?this.map.legendCntVertical.append(this.body):this.map.legendCntHorizontal.append(this.body),this.render()},jvm.Legend.prototype.render=function(){var i,tick,sample,label,ticks=this.series.scale.getTicks(),inner=jvm.$("<div/>").addClass("jvectormap-legend-inner");for(this.body.html(""),this.params.title&&this.body.append(jvm.$("<div/>").addClass("jvectormap-legend-title").html(this.params.title)),this.body.append(inner),i=0;i<ticks.length;i++){switch(tick=jvm.$("<div/>").addClass("jvectormap-legend-tick"),sample=jvm.$("<div/>").addClass("jvectormap-legend-tick-sample"),this.series.params.attribute){case"fill":jvm.isImageUrl(ticks[i].value)?sample.css("background","url("+ticks[i].value+")"):sample.css("background",ticks[i].value);break;case"stroke":sample.css("background",ticks[i].value);break;case"image":sample.css("background","url("+ticks[i].value+") no-repeat center center");break;case"r":jvm.$("<div/>").css({"border-radius":ticks[i].value,border:this.map.params.markerStyle.initial["stroke-width"]+"px "+this.map.params.markerStyle.initial.stroke+" solid",width:2*ticks[i].value+"px",height:2*ticks[i].value+"px",background:this.map.params.markerStyle.initial.fill}).appendTo(sample)}tick.append(sample),label=ticks[i].label,this.params.labelRender&&(label=this.params.labelRender(label)),tick.append(jvm.$("<div>"+label+" </div>").addClass("jvectormap-legend-tick-text")),inner.append(tick)}inner.append(jvm.$("<div/>").css("clear","both"))},jvm.DataSeries=function(params,elements,map){var scaleConstructor;params=params||{},params.attribute=params.attribute||"fill",this.elements=elements,this.params=params,this.map=map,params.attributes&&this.setAttributes(params.attributes),jvm.$.isArray(params.scale)?(scaleConstructor="fill"===params.attribute||"stroke"===params.attribute?jvm.ColorScale:jvm.NumericScale,this.scale=new scaleConstructor(params.scale,params.normalizeFunction,params.min,params.max)):this.scale=params.scale?new jvm.OrdinalScale(params.scale):new jvm.SimpleScale(params.scale),this.values=params.values||{},this.setValues(this.values),this.params.legend&&(this.legend=new jvm.Legend($.extend({map:this.map,series:this},this.params.legend)))},jvm.DataSeries.prototype={setAttributes:function(key,attr){var code,attrs=key;if("string"==typeof key)this.elements[key]&&this.elements[key].setStyle(this.params.attribute,attr);else for(code in attrs)this.elements[code]&&this.elements[code].element.setStyle(this.params.attribute,attrs[code])},setValues:function(values){var val,cc,max=-Number.MAX_VALUE,min=Number.MAX_VALUE,attrs={};if(this.scale instanceof jvm.OrdinalScale||this.scale instanceof jvm.SimpleScale)for(cc in values)attrs[cc]=values[cc]?this.scale.getValue(values[cc]):this.elements[cc].element.style.initial[this.params.attribute];else{if("undefined"==typeof this.params.min||"undefined"==typeof this.params.max)for(cc in values)val=parseFloat(values[cc]),val>max&&(max=val),min>val&&(min=val);"undefined"==typeof this.params.min?(this.scale.setMin(min),this.params.min=min):this.scale.setMin(this.params.min),"undefined"==typeof this.params.max?(this.scale.setMax(max),this.params.max=max):this.scale.setMax(this.params.max);for(cc in values)"indexOf"!=cc&&(val=parseFloat(values[cc]),attrs[cc]=isNaN(val)?this.elements[cc].element.style.initial[this.params.attribute]:this.scale.getValue(val))}this.setAttributes(attrs),jvm.$.extend(this.values,values)},clear:function(){var key,attrs={};for(key in this.values)this.elements[key]&&(attrs[key]=this.elements[key].element.shape.style.initial[this.params.attribute]);this.setAttributes(attrs),this.values={}},setScale:function(scale){this.scale.setScale(scale),this.values&&this.setValues(this.values)},setNormalizeFunction:function(f){this.scale.setNormalizeFunction(f),this.values&&this.setValues(this.values)}},jvm.Proj={degRad:180/Math.PI,radDeg:Math.PI/180,radius:6381372,sgn:function(n){return n>0?1:0>n?-1:n},mill:function(lat,lng,c){return{x:this.radius*(lng-c)*this.radDeg,y:-this.radius*Math.log(Math.tan((45+.4*lat)*this.radDeg))/.8}},mill_inv:function(x,y,c){return{lat:(2.5*Math.atan(Math.exp(.8*y/this.radius))-5*Math.PI/8)*this.degRad,lng:(c*this.radDeg+x/this.radius)*this.degRad}},merc:function(lat,lng,c){return{x:this.radius*(lng-c)*this.radDeg,y:-this.radius*Math.log(Math.tan(Math.PI/4+lat*Math.PI/360))}},merc_inv:function(x,y,c){return{lat:(2*Math.atan(Math.exp(y/this.radius))-Math.PI/2)*this.degRad,lng:(c*this.radDeg+x/this.radius)*this.degRad}},aea:function(lat,lng,c){var fi0=0,lambda0=c*this.radDeg,fi1=29.5*this.radDeg,fi2=45.5*this.radDeg,fi=lat*this.radDeg,lambda=lng*this.radDeg,n=(Math.sin(fi1)+Math.sin(fi2))/2,C=Math.cos(fi1)*Math.cos(fi1)+2*n*Math.sin(fi1),theta=n*(lambda-lambda0),ro=Math.sqrt(C-2*n*Math.sin(fi))/n,ro0=Math.sqrt(C-2*n*Math.sin(fi0))/n;return{x:ro*Math.sin(theta)*this.radius,y:-(ro0-ro*Math.cos(theta))*this.radius}},aea_inv:function(xCoord,yCoord,c){var x=xCoord/this.radius,y=yCoord/this.radius,fi0=0,lambda0=c*this.radDeg,fi1=29.5*this.radDeg,fi2=45.5*this.radDeg,n=(Math.sin(fi1)+Math.sin(fi2))/2,C=Math.cos(fi1)*Math.cos(fi1)+2*n*Math.sin(fi1),ro0=Math.sqrt(C-2*n*Math.sin(fi0))/n,ro=Math.sqrt(x*x+(ro0-y)*(ro0-y)),theta=Math.atan(x/(ro0-y));return{lat:Math.asin((C-ro*ro*n*n)/(2*n))*this.degRad,lng:(lambda0+theta/n)*this.degRad}},lcc:function(lat,lng,c){var fi0=0,lambda0=c*this.radDeg,lambda=lng*this.radDeg,fi1=33*this.radDeg,fi2=45*this.radDeg,fi=lat*this.radDeg,n=Math.log(Math.cos(fi1)*(1/Math.cos(fi2)))/Math.log(Math.tan(Math.PI/4+fi2/2)*(1/Math.tan(Math.PI/4+fi1/2))),F=Math.cos(fi1)*Math.pow(Math.tan(Math.PI/4+fi1/2),n)/n,ro=F*Math.pow(1/Math.tan(Math.PI/4+fi/2),n),ro0=F*Math.pow(1/Math.tan(Math.PI/4+fi0/2),n);return{x:ro*Math.sin(n*(lambda-lambda0))*this.radius,y:-(ro0-ro*Math.cos(n*(lambda-lambda0)))*this.radius}},lcc_inv:function(xCoord,yCoord,c){var x=xCoord/this.radius,y=yCoord/this.radius,fi0=0,lambda0=c*this.radDeg,fi1=33*this.radDeg,fi2=45*this.radDeg,n=Math.log(Math.cos(fi1)*(1/Math.cos(fi2)))/Math.log(Math.tan(Math.PI/4+fi2/2)*(1/Math.tan(Math.PI/4+fi1/2))),F=Math.cos(fi1)*Math.pow(Math.tan(Math.PI/4+fi1/2),n)/n,ro0=F*Math.pow(1/Math.tan(Math.PI/4+fi0/2),n),ro=this.sgn(n)*Math.sqrt(x*x+(ro0-y)*(ro0-y)),theta=Math.atan(x/(ro0-y));return{lat:(2*Math.atan(Math.pow(F/ro,1/n))-Math.PI/2)*this.degRad,lng:(lambda0+theta/n)*this.degRad}}},jvm.MapObject=function(){},jvm.MapObject.prototype.getLabelText=function(key){var text;return text=this.config.label?"function"==typeof this.config.label.render?this.config.label.render(key):key:null},jvm.MapObject.prototype.getLabelOffsets=function(key){var offsets;return this.config.label&&("function"==typeof this.config.label.offsets?offsets=this.config.label.offsets(key):"object"==typeof this.config.label.offsets&&(offsets=this.config.label.offsets[key])),offsets||[0,0]},jvm.MapObject.prototype.setHovered=function(isHovered){this.isHovered!==isHovered&&(this.isHovered=isHovered,this.shape.isHovered=isHovered,this.shape.updateStyle(),this.label&&(this.label.isHovered=isHovered,this.label.updateStyle()))},jvm.MapObject.prototype.setSelected=function(isSelected){this.isSelected!==isSelected&&(this.isSelected=isSelected,this.shape.isSelected=isSelected,this.shape.updateStyle(),this.label&&(this.label.isSelected=isSelected,this.label.updateStyle()),jvm.$(this.shape).trigger("selected",[isSelected]))},jvm.MapObject.prototype.setStyle=function(){this.shape.setStyle.apply(this.shape,arguments)},jvm.MapObject.prototype.remove=function(){this.shape.remove(),this.label&&this.label.remove()},jvm.Region=function(config){var bbox,text,offsets;this.config=config,this.map=this.config.map,this.shape=config.canvas.addPath({d:config.path,"data-code":config.code},config.style,config.canvas.rootElement),this.shape.addClass("jvectormap-region jvectormap-element"),bbox=this.shape.getBBox(),text=this.getLabelText(config.code),this.config.label&&text&&(offsets=this.getLabelOffsets(config.code),this.labelX=bbox.x+bbox.width/2+offsets[0],this.labelY=bbox.y+bbox.height/2+offsets[1],this.label=config.canvas.addText({text:text,"text-anchor":"middle","alignment-baseline":"central",x:this.labelX,y:this.labelY,"data-code":config.code},config.labelStyle,config.labelsGroup),this.label.addClass("jvectormap-region jvectormap-element")) | |
2 | +},jvm.inherits(jvm.Region,jvm.MapObject),jvm.Region.prototype.updateLabelPosition=function(){this.label&&this.label.set({x:this.labelX*this.map.scale+this.map.transX*this.map.scale,y:this.labelY*this.map.scale+this.map.transY*this.map.scale})},jvm.Marker=function(config){var text;this.config=config,this.map=this.config.map,this.isImage=!!this.config.style.initial.image,this.createShape(),text=this.getLabelText(config.index),this.config.label&&text&&(this.offsets=this.getLabelOffsets(config.index),this.labelX=config.cx/this.map.scale-this.map.transX,this.labelY=config.cy/this.map.scale-this.map.transY,this.label=config.canvas.addText({text:text,"data-index":config.index,dy:"0.6ex",x:this.labelX,y:this.labelY},config.labelStyle,config.labelsGroup),this.label.addClass("jvectormap-marker jvectormap-element"))},jvm.inherits(jvm.Marker,jvm.MapObject),jvm.Marker.prototype.createShape=function(){var that=this;this.shape&&this.shape.remove(),this.shape=this.config.canvas[this.isImage?"addImage":"addCircle"]({"data-index":this.config.index,cx:this.config.cx,cy:this.config.cy},this.config.style,this.config.group),this.shape.addClass("jvectormap-marker jvectormap-element"),this.isImage&&jvm.$(this.shape.node).on("imageloaded",function(){that.updateLabelPosition()})},jvm.Marker.prototype.updateLabelPosition=function(){this.label&&this.label.set({x:this.labelX*this.map.scale+this.offsets[0]+this.map.transX*this.map.scale+5+(this.isImage?(this.shape.width||0)/2:this.shape.properties.r),y:this.labelY*this.map.scale+this.map.transY*this.map.scale+this.offsets[1]})},jvm.Marker.prototype.setStyle=function(property){var isImage;jvm.Marker.parentClass.prototype.setStyle.apply(this,arguments),"r"===property&&this.updateLabelPosition(),isImage=!!this.shape.get("image"),isImage!=this.isImage&&(this.isImage=isImage,this.config.style=jvm.$.extend(!0,{},this.shape.style),this.createShape())},jvm.Map=function(params){var e,map=this;if(this.params=jvm.$.extend(!0,{},jvm.Map.defaultParams,params),!jvm.Map.maps[this.params.map])throw new Error("Attempt to use map which was not loaded: "+this.params.map);this.mapData=jvm.Map.maps[this.params.map],this.markers={},this.regions={},this.regionsColors={},this.regionsData={},this.container=jvm.$("<div>").addClass("jvectormap-container"),this.params.container&&this.params.container.append(this.container),this.container.data("mapObject",this),this.defaultWidth=this.mapData.width,this.defaultHeight=this.mapData.height,this.setBackgroundColor(this.params.backgroundColor),this.onResize=function(){map.updateSize()},jvm.$(window).resize(this.onResize);for(e in jvm.Map.apiEvents)this.params[e]&&this.container.bind(jvm.Map.apiEvents[e]+".jvectormap",this.params[e]);this.canvas=new jvm.VectorCanvas(this.container[0],this.width,this.height),this.params.bindTouchEvents&&("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch?this.bindContainerTouchEvents():window.MSGesture&&this.bindContainerPointerEvents()),this.bindContainerEvents(),this.bindElementEvents(),this.createTip(),this.params.zoomButtons&&this.bindZoomButtons(),this.createRegions(),this.createMarkers(this.params.markers||{}),this.updateSize(),this.params.focusOn&&("string"==typeof this.params.focusOn?this.params.focusOn={region:this.params.focusOn}:jvm.$.isArray(this.params.focusOn)&&(this.params.focusOn={regions:this.params.focusOn}),this.setFocus(this.params.focusOn)),this.params.selectedRegions&&this.setSelectedRegions(this.params.selectedRegions),this.params.selectedMarkers&&this.setSelectedMarkers(this.params.selectedMarkers),this.legendCntHorizontal=jvm.$("<div/>").addClass("jvectormap-legend-cnt jvectormap-legend-cnt-h"),this.legendCntVertical=jvm.$("<div/>").addClass("jvectormap-legend-cnt jvectormap-legend-cnt-v"),this.container.append(this.legendCntHorizontal),this.container.append(this.legendCntVertical),this.params.series&&this.createSeries()},jvm.Map.prototype={transX:0,transY:0,scale:1,baseTransX:0,baseTransY:0,baseScale:1,width:0,height:0,setBackgroundColor:function(backgroundColor){this.container.css("background-color",backgroundColor)},resize:function(){var curBaseScale=this.baseScale;this.width/this.height>this.defaultWidth/this.defaultHeight?(this.baseScale=this.height/this.defaultHeight,this.baseTransX=Math.abs(this.width-this.defaultWidth*this.baseScale)/(2*this.baseScale)):(this.baseScale=this.width/this.defaultWidth,this.baseTransY=Math.abs(this.height-this.defaultHeight*this.baseScale)/(2*this.baseScale)),this.scale*=this.baseScale/curBaseScale,this.transX*=this.baseScale/curBaseScale,this.transY*=this.baseScale/curBaseScale},updateSize:function(){this.width=this.container.width(),this.height=this.container.height(),this.resize(),this.canvas.setSize(this.width,this.height),this.applyTransform()},reset:function(){var key,i;for(key in this.series)for(i=0;i<this.series[key].length;i++)this.series[key][i].clear();this.scale=this.baseScale,this.transX=this.baseTransX,this.transY=this.baseTransY,this.applyTransform()},applyTransform:function(){var maxTransX,maxTransY,minTransX,minTransY;this.defaultWidth*this.scale<=this.width?(maxTransX=(this.width-this.defaultWidth*this.scale)/(2*this.scale),minTransX=(this.width-this.defaultWidth*this.scale)/(2*this.scale)):(maxTransX=0,minTransX=(this.width-this.defaultWidth*this.scale)/this.scale),this.defaultHeight*this.scale<=this.height?(maxTransY=(this.height-this.defaultHeight*this.scale)/(2*this.scale),minTransY=(this.height-this.defaultHeight*this.scale)/(2*this.scale)):(maxTransY=0,minTransY=(this.height-this.defaultHeight*this.scale)/this.scale),this.transY>maxTransY?this.transY=maxTransY:this.transY<minTransY&&(this.transY=minTransY),this.transX>maxTransX?this.transX=maxTransX:this.transX<minTransX&&(this.transX=minTransX),this.canvas.applyTransformParams(this.scale,this.transX,this.transY),this.markers&&this.repositionMarkers(),this.repositionLabels(),this.container.trigger("viewportChange",[this.scale/this.baseScale,this.transX,this.transY])},bindContainerEvents:function(){var oldPageX,oldPageY,mouseDown=!1,map=this;this.params.panOnDrag&&(this.container.mousemove(function(e){return mouseDown&&(map.transX-=(oldPageX-e.pageX)/map.scale,map.transY-=(oldPageY-e.pageY)/map.scale,map.applyTransform(),oldPageX=e.pageX,oldPageY=e.pageY),!1}).mousedown(function(e){return mouseDown=!0,oldPageX=e.pageX,oldPageY=e.pageY,!1}),this.onContainerMouseUp=function(){mouseDown=!1},jvm.$("body").mouseup(this.onContainerMouseUp)),this.params.zoomOnScroll&&this.container.mousewheel(function(event){var offset=jvm.$(map.container).offset(),centerX=event.pageX-offset.left,centerY=event.pageY-offset.top,zoomStep=Math.pow(1+map.params.zoomOnScrollSpeed/1e3,event.deltaFactor*event.deltaY);map.tip.hide(),map.setScale(map.scale*zoomStep,centerX,centerY),event.preventDefault()})},bindContainerTouchEvents:function(){var touchStartScale,touchStartDistance,touchX,touchY,centerTouchX,centerTouchY,lastTouchesLength,map=this,handleTouchEvent=function(e){var offset,scale,transXOld,transYOld,touches=e.originalEvent.touches;"touchstart"==e.type&&(lastTouchesLength=0),1==touches.length?(1==lastTouchesLength&&(transXOld=map.transX,transYOld=map.transY,map.transX-=(touchX-touches[0].pageX)/map.scale,map.transY-=(touchY-touches[0].pageY)/map.scale,map.applyTransform(),map.tip.hide(),(transXOld!=map.transX||transYOld!=map.transY)&&e.preventDefault()),touchX=touches[0].pageX,touchY=touches[0].pageY):2==touches.length&&(2==lastTouchesLength?(scale=Math.sqrt(Math.pow(touches[0].pageX-touches[1].pageX,2)+Math.pow(touches[0].pageY-touches[1].pageY,2))/touchStartDistance,map.setScale(touchStartScale*scale,centerTouchX,centerTouchY),map.tip.hide(),e.preventDefault()):(offset=jvm.$(map.container).offset(),centerTouchX=touches[0].pageX>touches[1].pageX?touches[1].pageX+(touches[0].pageX-touches[1].pageX)/2:touches[0].pageX+(touches[1].pageX-touches[0].pageX)/2,centerTouchY=touches[0].pageY>touches[1].pageY?touches[1].pageY+(touches[0].pageY-touches[1].pageY)/2:touches[0].pageY+(touches[1].pageY-touches[0].pageY)/2,centerTouchX-=offset.left,centerTouchY-=offset.top,touchStartScale=map.scale,touchStartDistance=Math.sqrt(Math.pow(touches[0].pageX-touches[1].pageX,2)+Math.pow(touches[0].pageY-touches[1].pageY,2)))),lastTouchesLength=touches.length};jvm.$(this.container).bind("touchstart",handleTouchEvent),jvm.$(this.container).bind("touchmove",handleTouchEvent)},bindContainerPointerEvents:function(){var map=this,gesture=new MSGesture,element=this.container[0],handlePointerDownEvent=function(e){gesture.addPointer(e.pointerId)},handleGestureEvent=function(e){var transXOld,transYOld;(0!=e.translationX||0!=e.translationY)&&(transXOld=map.transX,transYOld=map.transY,map.transX+=e.translationX/map.scale,map.transY+=e.translationY/map.scale,map.applyTransform(),map.tip.hide(),(transXOld!=map.transX||transYOld!=map.transY)&&e.preventDefault()),1!=e.scale&&(map.setScale(map.scale*e.scale,e.offsetX,e.offsetY),map.tip.hide(),e.preventDefault())};gesture.target=element,element.addEventListener("MSGestureChange",handleGestureEvent,!1),element.addEventListener("pointerdown",handlePointerDownEvent,!1)},bindElementEvents:function(){var pageX,pageY,mouseMoved,map=this;this.container.mousemove(function(e){Math.abs(pageX-e.pageX)+Math.abs(pageY-e.pageY)>2&&(mouseMoved=!0)}),this.container.delegate("[class~='jvectormap-element']","mouseover mouseout",function(e){var baseVal=jvm.$(this).attr("class").baseVal||jvm.$(this).attr("class"),type=-1===baseVal.indexOf("jvectormap-region")?"marker":"region",code=jvm.$(this).attr("region"==type?"data-code":"data-index"),element="region"==type?map.regions[code].element:map.markers[code].element,tipText="region"==type?map.mapData.paths[code].name:map.markers[code].config.name||"",tipShowEvent=jvm.$.Event(type+"TipShow.jvectormap"),overEvent=jvm.$.Event(type+"Over.jvectormap");"mouseover"==e.type?(map.container.trigger(overEvent,[code]),overEvent.isDefaultPrevented()||element.setHovered(!0),map.tip.text(tipText),map.container.trigger(tipShowEvent,[map.tip,code]),tipShowEvent.isDefaultPrevented()||(map.tip.show(),map.tipWidth=map.tip.width(),map.tipHeight=map.tip.height())):(element.setHovered(!1),map.tip.hide(),map.container.trigger(type+"Out.jvectormap",[code]))}),this.container.delegate("[class~='jvectormap-element']","mousedown",function(e){pageX=e.pageX,pageY=e.pageY,mouseMoved=!1}),this.container.delegate("[class~='jvectormap-element']","mouseup",function(){var baseVal=jvm.$(this).attr("class").baseVal?jvm.$(this).attr("class").baseVal:jvm.$(this).attr("class"),type=-1===baseVal.indexOf("jvectormap-region")?"marker":"region",code=jvm.$(this).attr("region"==type?"data-code":"data-index"),clickEvent=jvm.$.Event(type+"Click.jvectormap"),element="region"==type?map.regions[code].element:map.markers[code].element;mouseMoved||(map.container.trigger(clickEvent,[code]),("region"===type&&map.params.regionsSelectable||"marker"===type&&map.params.markersSelectable)&&(clickEvent.isDefaultPrevented()||(map.params[type+"sSelectableOne"]&&map.clearSelected(type+"s"),element.setSelected(!element.isSelected))))})},bindZoomButtons:function(){var map=this;jvm.$("<div/>").addClass("jvectormap-zoomin").text("+").appendTo(this.container),jvm.$("<div/>").addClass("jvectormap-zoomout").html("−").appendTo(this.container),this.container.find(".jvectormap-zoomin").click(function(){map.setScale(map.scale*map.params.zoomStep,map.width/2,map.height/2,!1,map.params.zoomAnimate)}),this.container.find(".jvectormap-zoomout").click(function(){map.setScale(map.scale/map.params.zoomStep,map.width/2,map.height/2,!1,map.params.zoomAnimate)})},createTip:function(){var map=this;this.tip=jvm.$("<div/>").addClass("jvectormap-tip").appendTo(jvm.$("body")),this.container.mousemove(function(e){var left=e.pageX-15-map.tipWidth,top=e.pageY-15-map.tipHeight;5>left&&(left=e.pageX+15),5>top&&(top=e.pageY+15),map.tip.css({left:left,top:top})})},setScale:function(scale,anchorX,anchorY,isCentered,animate){var interval,scaleStart,scaleDiff,transXStart,transXDiff,transYStart,transYDiff,transX,transY,viewportChangeEvent=jvm.$.Event("zoom.jvectormap"),that=this,i=0,count=Math.abs(Math.round(60*(scale-this.scale)/Math.max(scale,this.scale))),deferred=new jvm.$.Deferred;return scale>this.params.zoomMax*this.baseScale?scale=this.params.zoomMax*this.baseScale:scale<this.params.zoomMin*this.baseScale&&(scale=this.params.zoomMin*this.baseScale),"undefined"!=typeof anchorX&&"undefined"!=typeof anchorY&&(zoomStep=scale/this.scale,isCentered?(transX=anchorX+this.defaultWidth*(this.width/(this.defaultWidth*scale))/2,transY=anchorY+this.defaultHeight*(this.height/(this.defaultHeight*scale))/2):(transX=this.transX-(zoomStep-1)/scale*anchorX,transY=this.transY-(zoomStep-1)/scale*anchorY)),animate&&count>0?(scaleStart=this.scale,scaleDiff=(scale-scaleStart)/count,transXStart=this.transX*this.scale,transYStart=this.transY*this.scale,transXDiff=(transX*scale-transXStart)/count,transYDiff=(transY*scale-transYStart)/count,interval=setInterval(function(){i+=1,that.scale=scaleStart+scaleDiff*i,that.transX=(transXStart+transXDiff*i)/that.scale,that.transY=(transYStart+transYDiff*i)/that.scale,that.applyTransform(),i==count&&(clearInterval(interval),that.container.trigger(viewportChangeEvent,[scale/that.baseScale]),deferred.resolve())},10)):(this.transX=transX,this.transY=transY,this.scale=scale,this.applyTransform(),this.container.trigger(viewportChangeEvent,[scale/this.baseScale]),deferred.resolve()),deferred},setFocus:function(config){var bbox,itemBbox,newBbox,codes,i,point;if(config=config||{},config.region?codes=[config.region]:config.regions&&(codes=config.regions),codes){for(i=0;i<codes.length;i++)this.regions[codes[i]]&&(itemBbox=this.regions[codes[i]].element.shape.getBBox(),itemBbox&&("undefined"==typeof bbox?bbox=itemBbox:(newBbox={x:Math.min(bbox.x,itemBbox.x),y:Math.min(bbox.y,itemBbox.y),width:Math.max(bbox.x+bbox.width,itemBbox.x+itemBbox.width)-Math.min(bbox.x,itemBbox.x),height:Math.max(bbox.y+bbox.height,itemBbox.y+itemBbox.height)-Math.min(bbox.y,itemBbox.y)},bbox=newBbox)));return this.setScale(Math.min(this.width/bbox.width,this.height/bbox.height),-(bbox.x+bbox.width/2),-(bbox.y+bbox.height/2),!0,config.animate)}return config.lat&&config.lng?(point=this.latLngToPoint(config.lat,config.lng),config.x=this.transX-point.x/this.scale,config.y=this.transY-point.y/this.scale):config.x&&config.y&&(config.x*=-this.defaultWidth,config.y*=-this.defaultHeight),this.setScale(config.scale*this.baseScale,config.x,config.y,!0,config.animate)},getSelected:function(type){var key,selected=[];for(key in this[type])this[type][key].element.isSelected&&selected.push(key);return selected},getSelectedRegions:function(){return this.getSelected("regions")},getSelectedMarkers:function(){return this.getSelected("markers")},setSelected:function(type,keys){var i;if("object"!=typeof keys&&(keys=[keys]),jvm.$.isArray(keys))for(i=0;i<keys.length;i++)this[type][keys[i]].element.setSelected(!0);else for(i in keys)this[type][i].element.setSelected(!!keys[i])},setSelectedRegions:function(keys){this.setSelected("regions",keys)},setSelectedMarkers:function(keys){this.setSelected("markers",keys)},clearSelected:function(type){var i,select={},selected=this.getSelected(type);for(i=0;i<selected.length;i++)select[selected[i]]=!1;this.setSelected(type,select)},clearSelectedRegions:function(){this.clearSelected("regions")},clearSelectedMarkers:function(){this.clearSelected("markers")},getMapObject:function(){return this},getRegionName:function(code){return this.mapData.paths[code].name},createRegions:function(){var key,region,map=this;this.regionLabelsGroup=this.regionLabelsGroup||this.canvas.addGroup();for(key in this.mapData.paths)region=new jvm.Region({map:this,path:this.mapData.paths[key].path,code:key,style:jvm.$.extend(!0,{},this.params.regionStyle),labelStyle:jvm.$.extend(!0,{},this.params.regionLabelStyle),canvas:this.canvas,labelsGroup:this.regionLabelsGroup,label:"vml"!=this.canvas.mode?this.params.labels&&this.params.labels.regions:null}),jvm.$(region.shape).bind("selected",function(e,isSelected){map.container.trigger("regionSelected.jvectormap",[jvm.$(this.node).attr("data-code"),isSelected,map.getSelectedRegions()])}),this.regions[key]={element:region,config:this.mapData.paths[key]}},createMarkers:function(markers){var i,marker,point,markerConfig,markersArray,map=this;if(this.markersGroup=this.markersGroup||this.canvas.addGroup(),this.markerLabelsGroup=this.markerLabelsGroup||this.canvas.addGroup(),jvm.$.isArray(markers))for(markersArray=markers.slice(),markers={},i=0;i<markersArray.length;i++)markers[i]=markersArray[i];for(i in markers)markerConfig=markers[i]instanceof Array?{latLng:markers[i]}:markers[i],point=this.getMarkerPosition(markerConfig),point!==!1&&(marker=new jvm.Marker({map:this,style:jvm.$.extend(!0,{},this.params.markerStyle,{initial:markerConfig.style||{}}),labelStyle:jvm.$.extend(!0,{},this.params.markerLabelStyle),index:i,cx:point.x,cy:point.y,group:this.markersGroup,canvas:this.canvas,labelsGroup:this.markerLabelsGroup,label:"vml"!=this.canvas.mode?this.params.labels&&this.params.labels.markers:null}),jvm.$(marker.shape).bind("selected",function(e,isSelected){map.container.trigger("markerSelected.jvectormap",[jvm.$(this.node).attr("data-index"),isSelected,map.getSelectedMarkers()])}),this.markers[i]&&this.removeMarkers([i]),this.markers[i]={element:marker,config:markerConfig})},repositionMarkers:function(){var i,point;for(i in this.markers)point=this.getMarkerPosition(this.markers[i].config),point!==!1&&this.markers[i].element.setStyle({cx:point.x,cy:point.y})},repositionLabels:function(){var key;for(key in this.regions)this.regions[key].element.updateLabelPosition();for(key in this.markers)this.markers[key].element.updateLabelPosition()},getMarkerPosition:function(markerConfig){return jvm.Map.maps[this.params.map].projection?this.latLngToPoint.apply(this,markerConfig.latLng||[0,0]):{x:markerConfig.coords[0]*this.scale+this.transX*this.scale,y:markerConfig.coords[1]*this.scale+this.transY*this.scale}},addMarker:function(key,marker,seriesData){var values,i,markers={},data=[],seriesData=seriesData||[];for(markers[key]=marker,i=0;i<seriesData.length;i++)values={},"undefined"!=typeof seriesData[i]&&(values[key]=seriesData[i]),data.push(values);this.addMarkers(markers,data)},addMarkers:function(markers,seriesData){var i;for(seriesData=seriesData||[],this.createMarkers(markers),i=0;i<seriesData.length;i++)this.series.markers[i].setValues(seriesData[i]||{})},removeMarkers:function(markers){var i;for(i=0;i<markers.length;i++)this.markers[markers[i]].element.remove(),delete this.markers[markers[i]]},removeAllMarkers:function(){var i,markers=[];for(i in this.markers)markers.push(i);this.removeMarkers(markers)},latLngToPoint:function(lat,lng){var point,inset,bbox,proj=jvm.Map.maps[this.params.map].projection,centralMeridian=proj.centralMeridian;return-180+centralMeridian>lng&&(lng+=360),point=jvm.Proj[proj.type](lat,lng,centralMeridian),inset=this.getInsetForPoint(point.x,point.y),inset?(bbox=inset.bbox,point.x=(point.x-bbox[0].x)/(bbox[1].x-bbox[0].x)*inset.width*this.scale,point.y=(point.y-bbox[0].y)/(bbox[1].y-bbox[0].y)*inset.height*this.scale,{x:point.x+this.transX*this.scale+inset.left*this.scale,y:point.y+this.transY*this.scale+inset.top*this.scale}):!1},pointToLatLng:function(x,y){var i,inset,bbox,nx,ny,proj=jvm.Map.maps[this.params.map].projection,centralMeridian=proj.centralMeridian,insets=jvm.Map.maps[this.params.map].insets;for(i=0;i<insets.length;i++)if(inset=insets[i],bbox=inset.bbox,nx=x-(this.transX*this.scale+inset.left*this.scale),ny=y-(this.transY*this.scale+inset.top*this.scale),nx=nx/(inset.width*this.scale)*(bbox[1].x-bbox[0].x)+bbox[0].x,ny=ny/(inset.height*this.scale)*(bbox[1].y-bbox[0].y)+bbox[0].y,nx>bbox[0].x&&nx<bbox[1].x&&ny>bbox[0].y&&ny<bbox[1].y)return jvm.Proj[proj.type+"_inv"](nx,-ny,centralMeridian);return!1},getInsetForPoint:function(x,y){var i,bbox,insets=jvm.Map.maps[this.params.map].insets;for(i=0;i<insets.length;i++)if(bbox=insets[i].bbox,x>bbox[0].x&&x<bbox[1].x&&y>bbox[0].y&&y<bbox[1].y)return insets[i]},createSeries:function(){var i,key;this.series={markers:[],regions:[]};for(key in this.params.series)for(i=0;i<this.params.series[key].length;i++)this.series[key][i]=new jvm.DataSeries(this.params.series[key][i],this[key],this)},remove:function(){this.tip.remove(),this.container.remove(),jvm.$(window).unbind("resize",this.onResize),jvm.$("body").unbind("mouseup",this.onContainerMouseUp)}},jvm.Map.maps={},jvm.Map.defaultParams={map:"world_mill_en",backgroundColor:"#505050",zoomButtons:!0,zoomOnScroll:!0,zoomOnScrollSpeed:3,panOnDrag:!0,zoomMax:8,zoomMin:1,zoomStep:1.6,zoomAnimate:!0,regionsSelectable:!1,markersSelectable:!1,bindTouchEvents:!0,regionStyle:{initial:{fill:"white","fill-opacity":1,stroke:"none","stroke-width":0,"stroke-opacity":1},hover:{"fill-opacity":.8,cursor:"pointer"},selected:{fill:"yellow"},selectedHover:{}},regionLabelStyle:{initial:{"font-family":"Verdana","font-size":"12","font-weight":"bold",cursor:"default",fill:"black"},hover:{cursor:"pointer"}},markerStyle:{initial:{fill:"grey",stroke:"#505050","fill-opacity":1,"stroke-width":1,"stroke-opacity":1,r:5},hover:{stroke:"black","stroke-width":2,cursor:"pointer"},selected:{fill:"blue"},selectedHover:{}},markerLabelStyle:{initial:{"font-family":"Verdana","font-size":"12","font-weight":"bold",cursor:"default",fill:"black"},hover:{cursor:"pointer"}}},jvm.Map.apiEvents={onRegionTipShow:"regionTipShow",onRegionOver:"regionOver",onRegionOut:"regionOut",onRegionClick:"regionClick",onRegionSelected:"regionSelected",onMarkerTipShow:"markerTipShow",onMarkerOver:"markerOver",onMarkerOut:"markerOut",onMarkerClick:"markerClick",onMarkerSelected:"markerSelected",onViewportChange:"viewportChange"},jvm.MultiMap=function(params){var that=this;this.maps={},this.params=jvm.$.extend(!0,{},jvm.MultiMap.defaultParams,params),this.params.maxLevel=this.params.maxLevel||Number.MAX_VALUE,this.params.main=this.params.main||{},this.params.main.multiMapLevel=0,this.history=[this.addMap(this.params.main.map,this.params.main)],this.defaultProjection=this.history[0].mapData.projection.type,this.mapsLoaded={},this.params.container.css({position:"relative"}),this.backButton=jvm.$("<div/>").addClass("jvectormap-goback").text("Back").appendTo(this.params.container),this.backButton.hide(),this.backButton.click(function(){that.goBack()}),this.spinner=jvm.$("<div/>").addClass("jvectormap-spinner").appendTo(this.params.container),this.spinner.hide()},jvm.MultiMap.prototype={addMap:function(name,config){var cnt=jvm.$("<div/>").css({width:"100%",height:"100%"});return this.params.container.append(cnt),this.maps[name]=new jvm.Map(jvm.$.extend(config,{container:cnt})),this.params.maxLevel>config.multiMapLevel&&this.maps[name].container.on("regionClick.jvectormap",{scope:this},function(e,code){var multimap=e.data.scope,mapName=multimap.params.mapNameByCode(code,multimap);multimap.drillDownPromise&&"pending"===multimap.drillDownPromise.state()||multimap.drillDown(mapName,code)}),this.maps[name]},downloadMap:function(code){var that=this,deferred=jvm.$.Deferred();return this.mapsLoaded[code]?deferred.resolve():jvm.$.get(this.params.mapUrlByCode(code,this)).then(function(){that.mapsLoaded[code]=!0,deferred.resolve()},function(){deferred.reject()}),deferred},drillDown:function(name,code){var currentMap=this.history[this.history.length-1],that=this,focusPromise=currentMap.setFocus({region:code,animate:!0}),downloadPromise=this.downloadMap(code);focusPromise.then(function(){"pending"===downloadPromise.state()&&that.spinner.show()}),downloadPromise.always(function(){that.spinner.hide()}),this.drillDownPromise=jvm.$.when(downloadPromise,focusPromise),this.drillDownPromise.then(function(){currentMap.params.container.hide(),that.maps[name]?that.maps[name].params.container.show():that.addMap(name,{map:name,multiMapLevel:currentMap.params.multiMapLevel+1}),that.history.push(that.maps[name]),that.backButton.show()})},goBack:function(){var currentMap=this.history.pop(),prevMap=this.history[this.history.length-1],that=this;currentMap.setFocus({scale:1,x:.5,y:.5,animate:!0}).then(function(){currentMap.params.container.hide(),prevMap.params.container.show(),prevMap.updateSize(),1===that.history.length&&that.backButton.hide(),prevMap.setFocus({scale:1,x:.5,y:.5,animate:!0})})}},jvm.MultiMap.defaultParams={mapNameByCode:function(code,multiMap){return code.toLowerCase()+"_"+multiMap.defaultProjection+"_en"},mapUrlByCode:function(code,multiMap){return"jquery-jvectormap-data-"+code.toLowerCase()+"-"+multiMap.defaultProjection+"-en.js"}}; | |
0 | 3 | \ No newline at end of file | ... | ... |
app/jvectormap-204/jquery-jvectormap-2.0.4.css
... | ... | @@ -0,0 +1,135 @@ |
1 | +svg { | |
2 | + touch-action: none; | |
3 | +} | |
4 | + | |
5 | +.jvectormap-container { | |
6 | + width: 100%; | |
7 | + height: 100%; | |
8 | + position: relative; | |
9 | + overflow: hidden; | |
10 | + touch-action: none; | |
11 | +} | |
12 | + | |
13 | +.jvectormap-tip { | |
14 | + position: absolute; | |
15 | + display: none; | |
16 | + border: solid 1px #CDCDCD; | |
17 | + border-radius: 3px; | |
18 | + background: #292929; | |
19 | + color: white; | |
20 | + font-family: sans-serif, Verdana; | |
21 | + font-size: smaller; | |
22 | + padding: 3px; | |
23 | +} | |
24 | + | |
25 | +.jvectormap-zoomin, .jvectormap-zoomout, .jvectormap-goback { | |
26 | + position: absolute; | |
27 | + left: 10px; | |
28 | + border-radius: 3px; | |
29 | + background: #292929; | |
30 | + padding: 3px; | |
31 | + color: white; | |
32 | + cursor: pointer; | |
33 | + line-height: 10px; | |
34 | + text-align: center; | |
35 | + box-sizing: content-box; | |
36 | +} | |
37 | + | |
38 | +.jvectormap-zoomin, .jvectormap-zoomout { | |
39 | + width: 10px; | |
40 | + height: 10px; | |
41 | +} | |
42 | + | |
43 | +.jvectormap-zoomin { | |
44 | + top: 10px; | |
45 | +} | |
46 | + | |
47 | +.jvectormap-zoomout { | |
48 | + top: 30px; | |
49 | +} | |
50 | + | |
51 | +.jvectormap-goback { | |
52 | + bottom: 10px; | |
53 | + z-index: 1000; | |
54 | + padding: 6px; | |
55 | +} | |
56 | + | |
57 | +.jvectormap-spinner { | |
58 | + position: absolute; | |
59 | + left: 0; | |
60 | + top: 0; | |
61 | + right: 0; | |
62 | + bottom: 0; | |
63 | + background: center no-repeat url(data:image/gif;base64,R0lGODlhIAAgAPMAAP///wAAAMbGxoSEhLa2tpqamjY2NlZWVtjY2OTk5Ly8vB4eHgQEBAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJCgAAACwAAAAAIAAgAAAE5xDISWlhperN52JLhSSdRgwVo1ICQZRUsiwHpTJT4iowNS8vyW2icCF6k8HMMBkCEDskxTBDAZwuAkkqIfxIQyhBQBFvAQSDITM5VDW6XNE4KagNh6Bgwe60smQUB3d4Rz1ZBApnFASDd0hihh12BkE9kjAJVlycXIg7CQIFA6SlnJ87paqbSKiKoqusnbMdmDC2tXQlkUhziYtyWTxIfy6BE8WJt5YJvpJivxNaGmLHT0VnOgSYf0dZXS7APdpB309RnHOG5gDqXGLDaC457D1zZ/V/nmOM82XiHRLYKhKP1oZmADdEAAAh+QQJCgAAACwAAAAAIAAgAAAE6hDISWlZpOrNp1lGNRSdRpDUolIGw5RUYhhHukqFu8DsrEyqnWThGvAmhVlteBvojpTDDBUEIFwMFBRAmBkSgOrBFZogCASwBDEY/CZSg7GSE0gSCjQBMVG023xWBhklAnoEdhQEfyNqMIcKjhRsjEdnezB+A4k8gTwJhFuiW4dokXiloUepBAp5qaKpp6+Ho7aWW54wl7obvEe0kRuoplCGepwSx2jJvqHEmGt6whJpGpfJCHmOoNHKaHx61WiSR92E4lbFoq+B6QDtuetcaBPnW6+O7wDHpIiK9SaVK5GgV543tzjgGcghAgAh+QQJCgAAACwAAAAAIAAgAAAE7hDISSkxpOrN5zFHNWRdhSiVoVLHspRUMoyUakyEe8PTPCATW9A14E0UvuAKMNAZKYUZCiBMuBakSQKG8G2FzUWox2AUtAQFcBKlVQoLgQReZhQlCIJesQXI5B0CBnUMOxMCenoCfTCEWBsJColTMANldx15BGs8B5wlCZ9Po6OJkwmRpnqkqnuSrayqfKmqpLajoiW5HJq7FL1Gr2mMMcKUMIiJgIemy7xZtJsTmsM4xHiKv5KMCXqfyUCJEonXPN2rAOIAmsfB3uPoAK++G+w48edZPK+M6hLJpQg484enXIdQFSS1u6UhksENEQAAIfkECQoAAAAsAAAAACAAIAAABOcQyEmpGKLqzWcZRVUQnZYg1aBSh2GUVEIQ2aQOE+G+cD4ntpWkZQj1JIiZIogDFFyHI0UxQwFugMSOFIPJftfVAEoZLBbcLEFhlQiqGp1Vd140AUklUN3eCA51C1EWMzMCezCBBmkxVIVHBWd3HHl9JQOIJSdSnJ0TDKChCwUJjoWMPaGqDKannasMo6WnM562R5YluZRwur0wpgqZE7NKUm+FNRPIhjBJxKZteWuIBMN4zRMIVIhffcgojwCF117i4nlLnY5ztRLsnOk+aV+oJY7V7m76PdkS4trKcdg0Zc0tTcKkRAAAIfkECQoAAAAsAAAAACAAIAAABO4QyEkpKqjqzScpRaVkXZWQEximw1BSCUEIlDohrft6cpKCk5xid5MNJTaAIkekKGQkWyKHkvhKsR7ARmitkAYDYRIbUQRQjWBwJRzChi9CRlBcY1UN4g0/VNB0AlcvcAYHRyZPdEQFYV8ccwR5HWxEJ02YmRMLnJ1xCYp0Y5idpQuhopmmC2KgojKasUQDk5BNAwwMOh2RtRq5uQuPZKGIJQIGwAwGf6I0JXMpC8C7kXWDBINFMxS4DKMAWVWAGYsAdNqW5uaRxkSKJOZKaU3tPOBZ4DuK2LATgJhkPJMgTwKCdFjyPHEnKxFCDhEAACH5BAkKAAAALAAAAAAgACAAAATzEMhJaVKp6s2nIkolIJ2WkBShpkVRWqqQrhLSEu9MZJKK9y1ZrqYK9WiClmvoUaF8gIQSNeF1Er4MNFn4SRSDARWroAIETg1iVwuHjYB1kYc1mwruwXKC9gmsJXliGxc+XiUCby9ydh1sOSdMkpMTBpaXBzsfhoc5l58Gm5yToAaZhaOUqjkDgCWNHAULCwOLaTmzswadEqggQwgHuQsHIoZCHQMMQgQGubVEcxOPFAcMDAYUA85eWARmfSRQCdcMe0zeP1AAygwLlJtPNAAL19DARdPzBOWSm1brJBi45soRAWQAAkrQIykShQ9wVhHCwCQCACH5BAkKAAAALAAAAAAgACAAAATrEMhJaVKp6s2nIkqFZF2VIBWhUsJaTokqUCoBq+E71SRQeyqUToLA7VxF0JDyIQh/MVVPMt1ECZlfcjZJ9mIKoaTl1MRIl5o4CUKXOwmyrCInCKqcWtvadL2SYhyASyNDJ0uIiRMDjI0Fd30/iI2UA5GSS5UDj2l6NoqgOgN4gksEBgYFf0FDqKgHnyZ9OX8HrgYHdHpcHQULXAS2qKpENRg7eAMLC7kTBaixUYFkKAzWAAnLC7FLVxLWDBLKCwaKTULgEwbLA4hJtOkSBNqITT3xEgfLpBtzE/jiuL04RGEBgwWhShRgQExHBAAh+QQJCgAAACwAAAAAIAAgAAAE7xDISWlSqerNpyJKhWRdlSAVoVLCWk6JKlAqAavhO9UkUHsqlE6CwO1cRdCQ8iEIfzFVTzLdRAmZX3I2SfZiCqGk5dTESJeaOAlClzsJsqwiJwiqnFrb2nS9kmIcgEsjQydLiIlHehhpejaIjzh9eomSjZR+ipslWIRLAgMDOR2DOqKogTB9pCUJBagDBXR6XB0EBkIIsaRsGGMMAxoDBgYHTKJiUYEGDAzHC9EACcUGkIgFzgwZ0QsSBcXHiQvOwgDdEwfFs0sDzt4S6BK4xYjkDOzn0unFeBzOBijIm1Dgmg5YFQwsCMjp1oJ8LyIAACH5BAkKAAAALAAAAAAgACAAAATwEMhJaVKp6s2nIkqFZF2VIBWhUsJaTokqUCoBq+E71SRQeyqUToLA7VxF0JDyIQh/MVVPMt1ECZlfcjZJ9mIKoaTl1MRIl5o4CUKXOwmyrCInCKqcWtvadL2SYhyASyNDJ0uIiUd6GGl6NoiPOH16iZKNlH6KmyWFOggHhEEvAwwMA0N9GBsEC6amhnVcEwavDAazGwIDaH1ipaYLBUTCGgQDA8NdHz0FpqgTBwsLqAbWAAnIA4FWKdMLGdYGEgraigbT0OITBcg5QwPT4xLrROZL6AuQAPUS7bxLpoWidY0JtxLHKhwwMJBTHgPKdEQAACH5BAkKAAAALAAAAAAgACAAAATrEMhJaVKp6s2nIkqFZF2VIBWhUsJaTokqUCoBq+E71SRQeyqUToLA7VxF0JDyIQh/MVVPMt1ECZlfcjZJ9mIKoaTl1MRIl5o4CUKXOwmyrCInCKqcWtvadL2SYhyASyNDJ0uIiUd6GAULDJCRiXo1CpGXDJOUjY+Yip9DhToJA4RBLwMLCwVDfRgbBAaqqoZ1XBMHswsHtxtFaH1iqaoGNgAIxRpbFAgfPQSqpbgGBqUD1wBXeCYp1AYZ19JJOYgH1KwA4UBvQwXUBxPqVD9L3sbp2BNk2xvvFPJd+MFCN6HAAIKgNggY0KtEBAAh+QQJCgAAACwAAAAAIAAgAAAE6BDISWlSqerNpyJKhWRdlSAVoVLCWk6JKlAqAavhO9UkUHsqlE6CwO1cRdCQ8iEIfzFVTzLdRAmZX3I2SfYIDMaAFdTESJeaEDAIMxYFqrOUaNW4E4ObYcCXaiBVEgULe0NJaxxtYksjh2NLkZISgDgJhHthkpU4mW6blRiYmZOlh4JWkDqILwUGBnE6TYEbCgevr0N1gH4At7gHiRpFaLNrrq8HNgAJA70AWxQIH1+vsYMDAzZQPC9VCNkDWUhGkuE5PxJNwiUK4UfLzOlD4WvzAHaoG9nxPi5d+jYUqfAhhykOFwJWiAAAIfkECQoAAAAsAAAAACAAIAAABPAQyElpUqnqzaciSoVkXVUMFaFSwlpOCcMYlErAavhOMnNLNo8KsZsMZItJEIDIFSkLGQoQTNhIsFehRww2CQLKF0tYGKYSg+ygsZIuNqJksKgbfgIGepNo2cIUB3V1B3IvNiBYNQaDSTtfhhx0CwVPI0UJe0+bm4g5VgcGoqOcnjmjqDSdnhgEoamcsZuXO1aWQy8KAwOAuTYYGwi7w5h+Kr0SJ8MFihpNbx+4Erq7BYBuzsdiH1jCAzoSfl0rVirNbRXlBBlLX+BP0XJLAPGzTkAuAOqb0WT5AH7OcdCm5B8TgRwSRKIHQtaLCwg1RAAAOwAAAAAAAAAAAA==); | |
64 | +} | |
65 | + | |
66 | +.jvectormap-legend-title { | |
67 | + font-weight: bold; | |
68 | + font-size: 14px; | |
69 | + text-align: center; | |
70 | +} | |
71 | + | |
72 | +.jvectormap-legend-cnt { | |
73 | + position: absolute; | |
74 | +} | |
75 | + | |
76 | +.jvectormap-legend-cnt-h { | |
77 | + bottom: 0; | |
78 | + right: 0; | |
79 | +} | |
80 | + | |
81 | +.jvectormap-legend-cnt-v { | |
82 | + top: 0; | |
83 | + right: 0; | |
84 | +} | |
85 | + | |
86 | +.jvectormap-legend { | |
87 | + background: black; | |
88 | + color: white; | |
89 | + border-radius: 3px; | |
90 | +} | |
91 | + | |
92 | +.jvectormap-legend-cnt-h .jvectormap-legend { | |
93 | + float: left; | |
94 | + margin: 0 10px 10px 0; | |
95 | + padding: 3px 3px 1px 3px; | |
96 | +} | |
97 | + | |
98 | +.jvectormap-legend-cnt-h .jvectormap-legend .jvectormap-legend-tick { | |
99 | + float: left; | |
100 | +} | |
101 | + | |
102 | +.jvectormap-legend-cnt-v .jvectormap-legend { | |
103 | + margin: 10px 10px 0 0; | |
104 | + padding: 3px; | |
105 | +} | |
106 | + | |
107 | +.jvectormap-legend-cnt-h .jvectormap-legend-tick { | |
108 | + width: 40px; | |
109 | +} | |
110 | + | |
111 | +.jvectormap-legend-cnt-h .jvectormap-legend-tick-sample { | |
112 | + height: 15px; | |
113 | +} | |
114 | + | |
115 | +.jvectormap-legend-cnt-v .jvectormap-legend-tick-sample { | |
116 | + height: 20px; | |
117 | + width: 20px; | |
118 | + display: inline-block; | |
119 | + vertical-align: middle; | |
120 | +} | |
121 | + | |
122 | +.jvectormap-legend-tick-text { | |
123 | + font-size: 12px; | |
124 | +} | |
125 | + | |
126 | +.jvectormap-legend-cnt-h .jvectormap-legend-tick-text { | |
127 | + text-align: center; | |
128 | +} | |
129 | + | |
130 | +.jvectormap-legend-cnt-v .jvectormap-legend-tick-text { | |
131 | + display: inline-block; | |
132 | + vertical-align: middle; | |
133 | + line-height: 20px; | |
134 | + padding-left: 3px; | |
135 | +} | |
0 | 136 | \ No newline at end of file | ... | ... |
app/jvectormap-204/jquery-jvectormap-2.0.4.min.js
... | ... | @@ -0,0 +1,3375 @@ |
1 | +/** | |
2 | + * jVectorMap version 2.0.4 | |
3 | + * | |
4 | + * Copyright 2011-2014, Kirill Lebedev | |
5 | + * | |
6 | + */ | |
7 | + | |
8 | +(function( $ ){ | |
9 | + var apiParams = { | |
10 | + set: { | |
11 | + colors: 1, | |
12 | + values: 1, | |
13 | + backgroundColor: 1, | |
14 | + scaleColors: 1, | |
15 | + normalizeFunction: 1, | |
16 | + focus: 1 | |
17 | + }, | |
18 | + get: { | |
19 | + selectedRegions: 1, | |
20 | + selectedMarkers: 1, | |
21 | + mapObject: 1, | |
22 | + regionName: 1 | |
23 | + } | |
24 | + }; | |
25 | + | |
26 | + $.fn.vectorMap = function(options) { | |
27 | + var map, | |
28 | + methodName, | |
29 | + map = this.children('.jvectormap-container').data('mapObject'); | |
30 | + | |
31 | + if (options === 'addMap') { | |
32 | + jvm.Map.maps[arguments[1]] = arguments[2]; | |
33 | + } else if ((options === 'set' || options === 'get') && apiParams[options][arguments[1]]) { | |
34 | + methodName = arguments[1].charAt(0).toUpperCase()+arguments[1].substr(1); | |
35 | + return map[options+methodName].apply(map, Array.prototype.slice.call(arguments, 2)); | |
36 | + } else { | |
37 | + options = options || {}; | |
38 | + options.container = this; | |
39 | + map = new jvm.Map(options); | |
40 | + } | |
41 | + | |
42 | + return this; | |
43 | + }; | |
44 | +})( jQuery ); | |
45 | +/*! Copyright (c) 2013 Brandon Aaron (http://brandon.aaron.sh) | |
46 | + * Licensed under the MIT License (LICENSE.txt). | |
47 | + * | |
48 | + * Version: 3.1.9 | |
49 | + * | |
50 | + * Requires: jQuery 1.2.2+ | |
51 | + */ | |
52 | + | |
53 | +(function (factory) { | |
54 | + if ( typeof define === 'function' && define.amd ) { | |
55 | + // AMD. Register as an anonymous module. | |
56 | + define(['jquery'], factory); | |
57 | + } else if (typeof exports === 'object') { | |
58 | + // Node/CommonJS style for Browserify | |
59 | + module.exports = factory; | |
60 | + } else { | |
61 | + // Browser globals | |
62 | + factory(jQuery); | |
63 | + } | |
64 | +}(function ($) { | |
65 | + | |
66 | + var toFix = ['wheel', 'mousewheel', 'DOMMouseScroll', 'MozMousePixelScroll'], | |
67 | + toBind = ( 'onwheel' in document || document.documentMode >= 9 ) ? | |
68 | + ['wheel'] : ['mousewheel', 'DomMouseScroll', 'MozMousePixelScroll'], | |
69 | + slice = Array.prototype.slice, | |
70 | + nullLowestDeltaTimeout, lowestDelta; | |
71 | + | |
72 | + if ( $.event.fixHooks ) { | |
73 | + for ( var i = toFix.length; i; ) { | |
74 | + $.event.fixHooks[ toFix[--i] ] = $.event.mouseHooks; | |
75 | + } | |
76 | + } | |
77 | + | |
78 | + var special = $.event.special.mousewheel = { | |
79 | + version: '3.1.9', | |
80 | + | |
81 | + setup: function() { | |
82 | + if ( this.addEventListener ) { | |
83 | + for ( var i = toBind.length; i; ) { | |
84 | + this.addEventListener( toBind[--i], handler, false ); | |
85 | + } | |
86 | + } else { | |
87 | + this.onmousewheel = handler; | |
88 | + } | |
89 | + // Store the line height and page height for this particular element | |
90 | + $.data(this, 'mousewheel-line-height', special.getLineHeight(this)); | |
91 | + $.data(this, 'mousewheel-page-height', special.getPageHeight(this)); | |
92 | + }, | |
93 | + | |
94 | + teardown: function() { | |
95 | + if ( this.removeEventListener ) { | |
96 | + for ( var i = toBind.length; i; ) { | |
97 | + this.removeEventListener( toBind[--i], handler, false ); | |
98 | + } | |
99 | + } else { | |
100 | + this.onmousewheel = null; | |
101 | + } | |
102 | + }, | |
103 | + | |
104 | + getLineHeight: function(elem) { | |
105 | + return parseInt($(elem)['offsetParent' in $.fn ? 'offsetParent' : 'parent']().css('fontSize'), 10); | |
106 | + }, | |
107 | + | |
108 | + getPageHeight: function(elem) { | |
109 | + return $(elem).height(); | |
110 | + }, | |
111 | + | |
112 | + settings: { | |
113 | + adjustOldDeltas: true | |
114 | + } | |
115 | + }; | |
116 | + | |
117 | + $.fn.extend({ | |
118 | + mousewheel: function(fn) { | |
119 | + return fn ? this.bind('mousewheel', fn) : this.trigger('mousewheel'); | |
120 | + }, | |
121 | + | |
122 | + unmousewheel: function(fn) { | |
123 | + return this.unbind('mousewheel', fn); | |
124 | + } | |
125 | + }); | |
126 | + | |
127 | + | |
128 | + function handler(event) { | |
129 | + var orgEvent = event || window.event, | |
130 | + args = slice.call(arguments, 1), | |
131 | + delta = 0, | |
132 | + deltaX = 0, | |
133 | + deltaY = 0, | |
134 | + absDelta = 0; | |
135 | + event = $.event.fix(orgEvent); | |
136 | + event.type = 'mousewheel'; | |
137 | + | |
138 | + // Old school scrollwheel delta | |
139 | + if ( 'detail' in orgEvent ) { deltaY = orgEvent.detail * -1; } | |
140 | + if ( 'wheelDelta' in orgEvent ) { deltaY = orgEvent.wheelDelta; } | |
141 | + if ( 'wheelDeltaY' in orgEvent ) { deltaY = orgEvent.wheelDeltaY; } | |
142 | + if ( 'wheelDeltaX' in orgEvent ) { deltaX = orgEvent.wheelDeltaX * -1; } | |
143 | + | |
144 | + // Firefox < 17 horizontal scrolling related to DOMMouseScroll event | |
145 | + if ( 'axis' in orgEvent && orgEvent.axis === orgEvent.HORIZONTAL_AXIS ) { | |
146 | + deltaX = deltaY * -1; | |
147 | + deltaY = 0; | |
148 | + } | |
149 | + | |
150 | + // Set delta to be deltaY or deltaX if deltaY is 0 for backwards compatabilitiy | |
151 | + delta = deltaY === 0 ? deltaX : deltaY; | |
152 | + | |
153 | + // New school wheel delta (wheel event) | |
154 | + if ( 'deltaY' in orgEvent ) { | |
155 | + deltaY = orgEvent.deltaY * -1; | |
156 | + delta = deltaY; | |
157 | + } | |
158 | + if ( 'deltaX' in orgEvent ) { | |
159 | + deltaX = orgEvent.deltaX; | |
160 | + if ( deltaY === 0 ) { delta = deltaX * -1; } | |
161 | + } | |
162 | + | |
163 | + // No change actually happened, no reason to go any further | |
164 | + if ( deltaY === 0 && deltaX === 0 ) { return; } | |
165 | + | |
166 | + // Need to convert lines and pages to pixels if we aren't already in pixels | |
167 | + // There are three delta modes: | |
168 | + // * deltaMode 0 is by pixels, nothing to do | |
169 | + // * deltaMode 1 is by lines | |
170 | + // * deltaMode 2 is by pages | |
171 | + if ( orgEvent.deltaMode === 1 ) { | |
172 | + var lineHeight = $.data(this, 'mousewheel-line-height'); | |
173 | + delta *= lineHeight; | |
174 | + deltaY *= lineHeight; | |
175 | + deltaX *= lineHeight; | |
176 | + } else if ( orgEvent.deltaMode === 2 ) { | |
177 | + var pageHeight = $.data(this, 'mousewheel-page-height'); | |
178 | + delta *= pageHeight; | |
179 | + deltaY *= pageHeight; | |
180 | + deltaX *= pageHeight; | |
181 | + } | |
182 | + | |
183 | + // Store lowest absolute delta to normalize the delta values | |
184 | + absDelta = Math.max( Math.abs(deltaY), Math.abs(deltaX) ); | |
185 | + | |
186 | + if ( !lowestDelta || absDelta < lowestDelta ) { | |
187 | + lowestDelta = absDelta; | |
188 | + | |
189 | + // Adjust older deltas if necessary | |
190 | + if ( shouldAdjustOldDeltas(orgEvent, absDelta) ) { | |
191 | + lowestDelta /= 40; | |
192 | + } | |
193 | + } | |
194 | + | |
195 | + // Adjust older deltas if necessary | |
196 | + if ( shouldAdjustOldDeltas(orgEvent, absDelta) ) { | |
197 | + // Divide all the things by 40! | |
198 | + delta /= 40; | |
199 | + deltaX /= 40; | |
200 | + deltaY /= 40; | |
201 | + } | |
202 | + | |
203 | + // Get a whole, normalized value for the deltas | |
204 | + delta = Math[ delta >= 1 ? 'floor' : 'ceil' ](delta / lowestDelta); | |
205 | + deltaX = Math[ deltaX >= 1 ? 'floor' : 'ceil' ](deltaX / lowestDelta); | |
206 | + deltaY = Math[ deltaY >= 1 ? 'floor' : 'ceil' ](deltaY / lowestDelta); | |
207 | + | |
208 | + // Add information to the event object | |
209 | + event.deltaX = deltaX; | |
210 | + event.deltaY = deltaY; | |
211 | + event.deltaFactor = lowestDelta; | |
212 | + // Go ahead and set deltaMode to 0 since we converted to pixels | |
213 | + // Although this is a little odd since we overwrite the deltaX/Y | |
214 | + // properties with normalized deltas. | |
215 | + event.deltaMode = 0; | |
216 | + | |
217 | + // Add event and delta to the front of the arguments | |
218 | + args.unshift(event, delta, deltaX, deltaY); | |
219 | + | |
220 | + // Clearout lowestDelta after sometime to better | |
221 | + // handle multiple device types that give different | |
222 | + // a different lowestDelta | |
223 | + // Ex: trackpad = 3 and mouse wheel = 120 | |
224 | + if (nullLowestDeltaTimeout) { clearTimeout(nullLowestDeltaTimeout); } | |
225 | + nullLowestDeltaTimeout = setTimeout(nullLowestDelta, 200); | |
226 | + | |
227 | + return ($.event.dispatch || $.event.handle).apply(this, args); | |
228 | + } | |
229 | + | |
230 | + function nullLowestDelta() { | |
231 | + lowestDelta = null; | |
232 | + } | |
233 | + | |
234 | + function shouldAdjustOldDeltas(orgEvent, absDelta) { | |
235 | + // If this is an older event and the delta is divisable by 120, | |
236 | + // then we are assuming that the browser is treating this as an | |
237 | + // older mouse wheel event and that we should divide the deltas | |
238 | + // by 40 to try and get a more usable deltaFactor. | |
239 | + // Side note, this actually impacts the reported scroll distance | |
240 | + // in older browsers and can cause scrolling to be slower than native. | |
241 | + // Turn this off by setting $.event.special.mousewheel.settings.adjustOldDeltas to false. | |
242 | + return special.settings.adjustOldDeltas && orgEvent.type === 'mousewheel' && absDelta % 120 === 0; | |
243 | + } | |
244 | + | |
245 | +}));/** | |
246 | + * @namespace jvm Holds core methods and classes used by jVectorMap. | |
247 | + */ | |
248 | +var jvm = { | |
249 | + | |
250 | + /** | |
251 | + * Inherits child's prototype from the parent's one. | |
252 | + * @param {Function} child | |
253 | + * @param {Function} parent | |
254 | + */ | |
255 | + inherits: function(child, parent) { | |
256 | + function temp() {} | |
257 | + temp.prototype = parent.prototype; | |
258 | + child.prototype = new temp(); | |
259 | + child.prototype.constructor = child; | |
260 | + child.parentClass = parent; | |
261 | + }, | |
262 | + | |
263 | + /** | |
264 | + * Mixes in methods from the source constructor to the target one. | |
265 | + * @param {Function} target | |
266 | + * @param {Function} source | |
267 | + */ | |
268 | + mixin: function(target, source){ | |
269 | + var prop; | |
270 | + | |
271 | + for (prop in source.prototype) { | |
272 | + if (source.prototype.hasOwnProperty(prop)) { | |
273 | + target.prototype[prop] = source.prototype[prop]; | |
274 | + } | |
275 | + } | |
276 | + }, | |
277 | + | |
278 | + min: function(values){ | |
279 | + var min = Number.MAX_VALUE, | |
280 | + i; | |
281 | + | |
282 | + if (values instanceof Array) { | |
283 | + for (i = 0; i < values.length; i++) { | |
284 | + if (values[i] < min) { | |
285 | + min = values[i]; | |
286 | + } | |
287 | + } | |
288 | + } else { | |
289 | + for (i in values) { | |
290 | + if (values[i] < min) { | |
291 | + min = values[i]; | |
292 | + } | |
293 | + } | |
294 | + } | |
295 | + return min; | |
296 | + }, | |
297 | + | |
298 | + max: function(values){ | |
299 | + var max = Number.MIN_VALUE, | |
300 | + i; | |
301 | + | |
302 | + if (values instanceof Array) { | |
303 | + for (i = 0; i < values.length; i++) { | |
304 | + if (values[i] > max) { | |
305 | + max = values[i]; | |
306 | + } | |
307 | + } | |
308 | + } else { | |
309 | + for (i in values) { | |
310 | + if (values[i] > max) { | |
311 | + max = values[i]; | |
312 | + } | |
313 | + } | |
314 | + } | |
315 | + return max; | |
316 | + }, | |
317 | + | |
318 | + keys: function(object){ | |
319 | + var keys = [], | |
320 | + key; | |
321 | + | |
322 | + for (key in object) { | |
323 | + keys.push(key); | |
324 | + } | |
325 | + return keys; | |
326 | + }, | |
327 | + | |
328 | + values: function(object){ | |
329 | + var values = [], | |
330 | + key, | |
331 | + i; | |
332 | + | |
333 | + for (i = 0; i < arguments.length; i++) { | |
334 | + object = arguments[i]; | |
335 | + for (key in object) { | |
336 | + values.push(object[key]); | |
337 | + } | |
338 | + } | |
339 | + return values; | |
340 | + }, | |
341 | + | |
342 | + whenImageLoaded: function(url){ | |
343 | + var deferred = new jvm.$.Deferred(), | |
344 | + img = jvm.$('<img/>'); | |
345 | + | |
346 | + img.error(function(){ | |
347 | + deferred.reject(); | |
348 | + }).load(function(){ | |
349 | + deferred.resolve(img); | |
350 | + }); | |
351 | + img.attr('src', url); | |
352 | + | |
353 | + return deferred; | |
354 | + }, | |
355 | + | |
356 | + isImageUrl: function(s){ | |
357 | + return /\.\w{3,4}$/.test(s); | |
358 | + } | |
359 | +}; | |
360 | + | |
361 | +jvm.$ = jQuery; | |
362 | + | |
363 | +/** | |
364 | + * indexOf polyfill for IE < 9 | |
365 | + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/indexOf | |
366 | + */ | |
367 | +if (!Array.prototype.indexOf) { | |
368 | + Array.prototype.indexOf = function (searchElement, fromIndex) { | |
369 | + | |
370 | + var k; | |
371 | + | |
372 | + // 1. Let O be the result of calling ToObject passing | |
373 | + // the this value as the argument. | |
374 | + if (this == null) { | |
375 | + throw new TypeError('"this" is null or not defined'); | |
376 | + } | |
377 | + | |
378 | + var O = Object(this); | |
379 | + | |
380 | + // 2. Let lenValue be the result of calling the Get | |
381 | + // internal method of O with the argument "length". | |
382 | + // 3. Let len be ToUint32(lenValue). | |
383 | + var len = O.length >>> 0; | |
384 | + | |
385 | + // 4. If len is 0, return -1. | |
386 | + if (len === 0) { | |
387 | + return -1; | |
388 | + } | |
389 | + | |
390 | + // 5. If argument fromIndex was passed let n be | |
391 | + // ToInteger(fromIndex); else let n be 0. | |
392 | + var n = +fromIndex || 0; | |
393 | + | |
394 | + if (Math.abs(n) === Infinity) { | |
395 | + n = 0; | |
396 | + } | |
397 | + | |
398 | + // 6. If n >= len, return -1. | |
399 | + if (n >= len) { | |
400 | + return -1; | |
401 | + } | |
402 | + | |
403 | + // 7. If n >= 0, then Let k be n. | |
404 | + // 8. Else, n<0, Let k be len - abs(n). | |
405 | + // If k is less than 0, then let k be 0. | |
406 | + k = Math.max(n >= 0 ? n : len - Math.abs(n), 0); | |
407 | + | |
408 | + // 9. Repeat, while k < len | |
409 | + while (k < len) { | |
410 | + // a. Let Pk be ToString(k). | |
411 | + // This is implicit for LHS operands of the in operator | |
412 | + // b. Let kPresent be the result of calling the | |
413 | + // HasProperty internal method of O with argument Pk. | |
414 | + // This step can be combined with c | |
415 | + // c. If kPresent is true, then | |
416 | + // i. Let elementK be the result of calling the Get | |
417 | + // internal method of O with the argument ToString(k). | |
418 | + // ii. Let same be the result of applying the | |
419 | + // Strict Equality Comparison Algorithm to | |
420 | + // searchElement and elementK. | |
421 | + // iii. If same is true, return k. | |
422 | + if (k in O && O[k] === searchElement) { | |
423 | + return k; | |
424 | + } | |
425 | + k++; | |
426 | + } | |
427 | + return -1; | |
428 | + }; | |
429 | +}/** | |
430 | + * Basic wrapper for DOM element. | |
431 | + * @constructor | |
432 | + * @param {String} name Tag name of the element | |
433 | + * @param {Object} config Set of parameters to initialize element with | |
434 | + */ | |
435 | +jvm.AbstractElement = function(name, config){ | |
436 | + /** | |
437 | + * Underlying DOM element | |
438 | + * @type {DOMElement} | |
439 | + * @private | |
440 | + */ | |
441 | + this.node = this.createElement(name); | |
442 | + | |
443 | + /** | |
444 | + * Name of underlying element | |
445 | + * @type {String} | |
446 | + * @private | |
447 | + */ | |
448 | + this.name = name; | |
449 | + | |
450 | + /** | |
451 | + * Internal store of attributes | |
452 | + * @type {Object} | |
453 | + * @private | |
454 | + */ | |
455 | + this.properties = {}; | |
456 | + | |
457 | + if (config) { | |
458 | + this.set(config); | |
459 | + } | |
460 | +}; | |
461 | + | |
462 | +/** | |
463 | + * Set attribute of the underlying DOM element. | |
464 | + * @param {String} name Name of attribute | |
465 | + * @param {Number|String} config Set of parameters to initialize element with | |
466 | + */ | |
467 | +jvm.AbstractElement.prototype.set = function(property, value){ | |
468 | + var key; | |
469 | + | |
470 | + if (typeof property === 'object') { | |
471 | + for (key in property) { | |
472 | + this.properties[key] = property[key]; | |
473 | + this.applyAttr(key, property[key]); | |
474 | + } | |
475 | + } else { | |
476 | + this.properties[property] = value; | |
477 | + this.applyAttr(property, value); | |
478 | + } | |
479 | +}; | |
480 | + | |
481 | +/** | |
482 | + * Returns value of attribute. | |
483 | + * @param {String} name Name of attribute | |
484 | + */ | |
485 | +jvm.AbstractElement.prototype.get = function(property){ | |
486 | + return this.properties[property]; | |
487 | +}; | |
488 | + | |
489 | +/** | |
490 | + * Applies attribute value to the underlying DOM element. | |
491 | + * @param {String} name Name of attribute | |
492 | + * @param {Number|String} config Value of attribute to apply | |
493 | + * @private | |
494 | + */ | |
495 | +jvm.AbstractElement.prototype.applyAttr = function(property, value){ | |
496 | + this.node.setAttribute(property, value); | |
497 | +}; | |
498 | + | |
499 | +jvm.AbstractElement.prototype.remove = function(){ | |
500 | + jvm.$(this.node).remove(); | |
501 | +};/** | |
502 | + * Implements abstract vector canvas. | |
503 | + * @constructor | |
504 | + * @param {HTMLElement} container Container to put element to. | |
505 | + * @param {Number} width Width of canvas. | |
506 | + * @param {Number} height Height of canvas. | |
507 | + */ | |
508 | +jvm.AbstractCanvasElement = function(container, width, height){ | |
509 | + this.container = container; | |
510 | + this.setSize(width, height); | |
511 | + this.rootElement = new jvm[this.classPrefix+'GroupElement'](); | |
512 | + this.node.appendChild( this.rootElement.node ); | |
513 | + this.container.appendChild(this.node); | |
514 | +} | |
515 | + | |
516 | +/** | |
517 | + * Add element to the certain group inside of the canvas. | |
518 | + * @param {HTMLElement} element Element to add to canvas. | |
519 | + * @param {HTMLElement} group Group to add element into or into root group if not provided. | |
520 | + */ | |
521 | +jvm.AbstractCanvasElement.prototype.add = function(element, group){ | |
522 | + group = group || this.rootElement; | |
523 | + group.add(element); | |
524 | + element.canvas = this; | |
525 | +} | |
526 | + | |
527 | +/** | |
528 | + * Create path and add it to the canvas. | |
529 | + * @param {Object} config Parameters of path to create. | |
530 | + * @param {Object} style Styles of the path to create. | |
531 | + * @param {HTMLElement} group Group to add path into. | |
532 | + */ | |
533 | +jvm.AbstractCanvasElement.prototype.addPath = function(config, style, group){ | |
534 | + var el = new jvm[this.classPrefix+'PathElement'](config, style); | |
535 | + | |
536 | + this.add(el, group); | |
537 | + return el; | |
538 | +}; | |
539 | + | |
540 | +/** | |
541 | + * Create circle and add it to the canvas. | |
542 | + * @param {Object} config Parameters of path to create. | |
543 | + * @param {Object} style Styles of the path to create. | |
544 | + * @param {HTMLElement} group Group to add circle into. | |
545 | + */ | |
546 | +jvm.AbstractCanvasElement.prototype.addCircle = function(config, style, group){ | |
547 | + var el = new jvm[this.classPrefix+'CircleElement'](config, style); | |
548 | + | |
549 | + this.add(el, group); | |
550 | + return el; | |
551 | +}; | |
552 | + | |
553 | +/** | |
554 | + * Create circle and add it to the canvas. | |
555 | + * @param {Object} config Parameters of path to create. | |
556 | + * @param {Object} style Styles of the path to create. | |
557 | + * @param {HTMLElement} group Group to add circle into. | |
558 | + */ | |
559 | +jvm.AbstractCanvasElement.prototype.addImage = function(config, style, group){ | |
560 | + var el = new jvm[this.classPrefix+'ImageElement'](config, style); | |
561 | + | |
562 | + this.add(el, group); | |
563 | + return el; | |
564 | +}; | |
565 | + | |
566 | +/** | |
567 | + * Create text and add it to the canvas. | |
568 | + * @param {Object} config Parameters of path to create. | |
569 | + * @param {Object} style Styles of the path to create. | |
570 | + * @param {HTMLElement} group Group to add circle into. | |
571 | + */ | |
572 | +jvm.AbstractCanvasElement.prototype.addText = function(config, style, group){ | |
573 | + var el = new jvm[this.classPrefix+'TextElement'](config, style); | |
574 | + | |
575 | + this.add(el, group); | |
576 | + return el; | |
577 | +}; | |
578 | + | |
579 | +/** | |
580 | + * Add group to the another group inside of the canvas. | |
581 | + * @param {HTMLElement} group Group to add circle into or root group if not provided. | |
582 | + */ | |
583 | +jvm.AbstractCanvasElement.prototype.addGroup = function(parentGroup){ | |
584 | + var el = new jvm[this.classPrefix+'GroupElement'](); | |
585 | + | |
586 | + if (parentGroup) { | |
587 | + parentGroup.node.appendChild(el.node); | |
588 | + } else { | |
589 | + this.node.appendChild(el.node); | |
590 | + } | |
591 | + el.canvas = this; | |
592 | + return el; | |
593 | +};/** | |
594 | + * Abstract shape element. Shape element represents some visual vector or raster object. | |
595 | + * @constructor | |
596 | + * @param {String} name Tag name of the element. | |
597 | + * @param {Object} config Set of parameters to initialize element with. | |
598 | + * @param {Object} style Object with styles to set on element initialization. | |
599 | + */ | |
600 | +jvm.AbstractShapeElement = function(name, config, style){ | |
601 | + this.style = style || {}; | |
602 | + this.style.current = this.style.current || {}; | |
603 | + this.isHovered = false; | |
604 | + this.isSelected = false; | |
605 | + this.updateStyle(); | |
606 | +}; | |
607 | + | |
608 | +/** | |
609 | + * Set element's style. | |
610 | + * @param {Object|String} property Could be string to set only one property or object to set several style properties at once. | |
611 | + * @param {String} value Value to set in case only one property should be set. | |
612 | + */ | |
613 | +jvm.AbstractShapeElement.prototype.setStyle = function(property, value){ | |
614 | + var styles = {}; | |
615 | + | |
616 | + if (typeof property === 'object') { | |
617 | + styles = property; | |
618 | + } else { | |
619 | + styles[property] = value; | |
620 | + } | |
621 | + jvm.$.extend(this.style.current, styles); | |
622 | + this.updateStyle(); | |
623 | +}; | |
624 | + | |
625 | + | |
626 | +jvm.AbstractShapeElement.prototype.updateStyle = function(){ | |
627 | + var attrs = {}; | |
628 | + | |
629 | + jvm.AbstractShapeElement.mergeStyles(attrs, this.style.initial); | |
630 | + jvm.AbstractShapeElement.mergeStyles(attrs, this.style.current); | |
631 | + if (this.isHovered) { | |
632 | + jvm.AbstractShapeElement.mergeStyles(attrs, this.style.hover); | |
633 | + } | |
634 | + if (this.isSelected) { | |
635 | + jvm.AbstractShapeElement.mergeStyles(attrs, this.style.selected); | |
636 | + if (this.isHovered) { | |
637 | + jvm.AbstractShapeElement.mergeStyles(attrs, this.style.selectedHover); | |
638 | + } | |
639 | + } | |
640 | + this.set(attrs); | |
641 | +}; | |
642 | + | |
643 | +jvm.AbstractShapeElement.mergeStyles = function(styles, newStyles){ | |
644 | + var key; | |
645 | + | |
646 | + newStyles = newStyles || {}; | |
647 | + for (key in newStyles) { | |
648 | + if (newStyles[key] === null) { | |
649 | + delete styles[key]; | |
650 | + } else { | |
651 | + styles[key] = newStyles[key]; | |
652 | + } | |
653 | + } | |
654 | +}/** | |
655 | + * Wrapper for SVG element. | |
656 | + * @constructor | |
657 | + * @extends jvm.AbstractElement | |
658 | + * @param {String} name Tag name of the element | |
659 | + * @param {Object} config Set of parameters to initialize element with | |
660 | + */ | |
661 | + | |
662 | +jvm.SVGElement = function(name, config){ | |
663 | + jvm.SVGElement.parentClass.apply(this, arguments); | |
664 | +} | |
665 | + | |
666 | +jvm.inherits(jvm.SVGElement, jvm.AbstractElement); | |
667 | + | |
668 | +jvm.SVGElement.svgns = "http://www.w3.org/2000/svg"; | |
669 | + | |
670 | +/** | |
671 | + * Creates DOM element. | |
672 | + * @param {String} tagName Name of element | |
673 | + * @private | |
674 | + * @returns DOMElement | |
675 | + */ | |
676 | +jvm.SVGElement.prototype.createElement = function( tagName ){ | |
677 | + return document.createElementNS( jvm.SVGElement.svgns, tagName ); | |
678 | +}; | |
679 | + | |
680 | +/** | |
681 | + * Adds CSS class for underlying DOM element. | |
682 | + * @param {String} className Name of CSS class name | |
683 | + */ | |
684 | +jvm.SVGElement.prototype.addClass = function( className ){ | |
685 | + this.node.setAttribute('class', className); | |
686 | +}; | |
687 | + | |
688 | +/** | |
689 | + * Returns constructor for element by name prefixed with 'VML'. | |
690 | + * @param {String} ctr Name of basic constructor to return | |
691 | + * proper implementation for. | |
692 | + * @returns Function | |
693 | + * @private | |
694 | + */ | |
695 | +jvm.SVGElement.prototype.getElementCtr = function( ctr ){ | |
696 | + return jvm['SVG'+ctr]; | |
697 | +}; | |
698 | + | |
699 | +jvm.SVGElement.prototype.getBBox = function(){ | |
700 | + return this.node.getBBox(); | |
701 | +};jvm.SVGGroupElement = function(){ | |
702 | + jvm.SVGGroupElement.parentClass.call(this, 'g'); | |
703 | +} | |
704 | + | |
705 | +jvm.inherits(jvm.SVGGroupElement, jvm.SVGElement); | |
706 | + | |
707 | +jvm.SVGGroupElement.prototype.add = function(element){ | |
708 | + this.node.appendChild( element.node ); | |
709 | +};jvm.SVGCanvasElement = function(container, width, height){ | |
710 | + this.classPrefix = 'SVG'; | |
711 | + jvm.SVGCanvasElement.parentClass.call(this, 'svg'); | |
712 | + | |
713 | + this.defsElement = new jvm.SVGElement('defs'); | |
714 | + this.node.appendChild( this.defsElement.node ); | |
715 | + | |
716 | + jvm.AbstractCanvasElement.apply(this, arguments); | |
717 | +} | |
718 | + | |
719 | +jvm.inherits(jvm.SVGCanvasElement, jvm.SVGElement); | |
720 | +jvm.mixin(jvm.SVGCanvasElement, jvm.AbstractCanvasElement); | |
721 | + | |
722 | +jvm.SVGCanvasElement.prototype.setSize = function(width, height){ | |
723 | + this.width = width; | |
724 | + this.height = height; | |
725 | + this.node.setAttribute('width', width); | |
726 | + this.node.setAttribute('height', height); | |
727 | +}; | |
728 | + | |
729 | +jvm.SVGCanvasElement.prototype.applyTransformParams = function(scale, transX, transY) { | |
730 | + this.scale = scale; | |
731 | + this.transX = transX; | |
732 | + this.transY = transY; | |
733 | + this.rootElement.node.setAttribute('transform', 'scale('+scale+') translate('+transX+', '+transY+')'); | |
734 | +};jvm.SVGShapeElement = function(name, config, style){ | |
735 | + jvm.SVGShapeElement.parentClass.call(this, name, config); | |
736 | + jvm.AbstractShapeElement.apply(this, arguments); | |
737 | +}; | |
738 | + | |
739 | +jvm.inherits(jvm.SVGShapeElement, jvm.SVGElement); | |
740 | +jvm.mixin(jvm.SVGShapeElement, jvm.AbstractShapeElement); | |
741 | + | |
742 | +jvm.SVGShapeElement.prototype.applyAttr = function(attr, value){ | |
743 | + var patternEl, | |
744 | + imageEl, | |
745 | + that = this; | |
746 | + | |
747 | + if (attr === 'fill' && jvm.isImageUrl(value)) { | |
748 | + if (!jvm.SVGShapeElement.images[value]) { | |
749 | + jvm.whenImageLoaded(value).then(function(img){ | |
750 | + imageEl = new jvm.SVGElement('image'); | |
751 | + imageEl.node.setAttributeNS('http://www.w3.org/1999/xlink', 'href', value); | |
752 | + imageEl.applyAttr('x', '0'); | |
753 | + imageEl.applyAttr('y', '0'); | |
754 | + imageEl.applyAttr('width', img[0].width); | |
755 | + imageEl.applyAttr('height', img[0].height); | |
756 | + | |
757 | + patternEl = new jvm.SVGElement('pattern'); | |
758 | + patternEl.applyAttr('id', 'image'+jvm.SVGShapeElement.imageCounter); | |
759 | + patternEl.applyAttr('x', 0); | |
760 | + patternEl.applyAttr('y', 0); | |
761 | + patternEl.applyAttr('width', img[0].width / 2); | |
762 | + patternEl.applyAttr('height', img[0].height / 2); | |
763 | + patternEl.applyAttr('viewBox', '0 0 '+img[0].width+' '+img[0].height); | |
764 | + patternEl.applyAttr('patternUnits', 'userSpaceOnUse'); | |
765 | + patternEl.node.appendChild( imageEl.node ); | |
766 | + | |
767 | + that.canvas.defsElement.node.appendChild( patternEl.node ); | |
768 | + | |
769 | + jvm.SVGShapeElement.images[value] = jvm.SVGShapeElement.imageCounter++; | |
770 | + | |
771 | + that.applyAttr('fill', 'url(#image'+jvm.SVGShapeElement.images[value]+')'); | |
772 | + }); | |
773 | + } else { | |
774 | + this.applyAttr('fill', 'url(#image'+jvm.SVGShapeElement.images[value]+')'); | |
775 | + } | |
776 | + } else { | |
777 | + jvm.SVGShapeElement.parentClass.prototype.applyAttr.apply(this, arguments); | |
778 | + } | |
779 | +}; | |
780 | + | |
781 | +jvm.SVGShapeElement.imageCounter = 1; | |
782 | +jvm.SVGShapeElement.images = {};jvm.SVGPathElement = function(config, style){ | |
783 | + jvm.SVGPathElement.parentClass.call(this, 'path', config, style); | |
784 | + this.node.setAttribute('fill-rule', 'evenodd'); | |
785 | +} | |
786 | + | |
787 | +jvm.inherits(jvm.SVGPathElement, jvm.SVGShapeElement);jvm.SVGCircleElement = function(config, style){ | |
788 | + jvm.SVGCircleElement.parentClass.call(this, 'circle', config, style); | |
789 | +}; | |
790 | + | |
791 | +jvm.inherits(jvm.SVGCircleElement, jvm.SVGShapeElement);jvm.SVGImageElement = function(config, style){ | |
792 | + jvm.SVGImageElement.parentClass.call(this, 'image', config, style); | |
793 | +}; | |
794 | + | |
795 | +jvm.inherits(jvm.SVGImageElement, jvm.SVGShapeElement); | |
796 | + | |
797 | +jvm.SVGImageElement.prototype.applyAttr = function(attr, value){ | |
798 | + var that = this; | |
799 | + | |
800 | + if (attr == 'image') { | |
801 | + jvm.whenImageLoaded(value).then(function(img){ | |
802 | + that.node.setAttributeNS('http://www.w3.org/1999/xlink', 'href', value); | |
803 | + that.width = img[0].width; | |
804 | + that.height = img[0].height; | |
805 | + that.applyAttr('width', that.width); | |
806 | + that.applyAttr('height', that.height); | |
807 | + | |
808 | + that.applyAttr('x', that.cx - that.width / 2); | |
809 | + that.applyAttr('y', that.cy - that.height / 2); | |
810 | + | |
811 | + jvm.$(that.node).trigger('imageloaded', [img]); | |
812 | + }); | |
813 | + } else if(attr == 'cx') { | |
814 | + this.cx = value; | |
815 | + if (this.width) { | |
816 | + this.applyAttr('x', value - this.width / 2); | |
817 | + } | |
818 | + } else if(attr == 'cy') { | |
819 | + this.cy = value; | |
820 | + if (this.height) { | |
821 | + this.applyAttr('y', value - this.height / 2); | |
822 | + } | |
823 | + } else { | |
824 | + jvm.SVGImageElement.parentClass.prototype.applyAttr.apply(this, arguments); | |
825 | + } | |
826 | +};jvm.SVGTextElement = function(config, style){ | |
827 | + jvm.SVGTextElement.parentClass.call(this, 'text', config, style); | |
828 | +} | |
829 | + | |
830 | +jvm.inherits(jvm.SVGTextElement, jvm.SVGShapeElement); | |
831 | + | |
832 | +jvm.SVGTextElement.prototype.applyAttr = function(attr, value){ | |
833 | + if (attr === 'text') { | |
834 | + this.node.textContent = value; | |
835 | + } else { | |
836 | + jvm.SVGTextElement.parentClass.prototype.applyAttr.apply(this, arguments); | |
837 | + } | |
838 | +};/** | |
839 | + * Wrapper for VML element. | |
840 | + * @constructor | |
841 | + * @extends jvm.AbstractElement | |
842 | + * @param {String} name Tag name of the element | |
843 | + * @param {Object} config Set of parameters to initialize element with | |
844 | + */ | |
845 | + | |
846 | +jvm.VMLElement = function(name, config){ | |
847 | + if (!jvm.VMLElement.VMLInitialized) { | |
848 | + jvm.VMLElement.initializeVML(); | |
849 | + } | |
850 | + | |
851 | + jvm.VMLElement.parentClass.apply(this, arguments); | |
852 | +}; | |
853 | + | |
854 | +jvm.inherits(jvm.VMLElement, jvm.AbstractElement); | |
855 | + | |
856 | +/** | |
857 | + * Shows if VML was already initialized for the current document or not. | |
858 | + * @static | |
859 | + * @private | |
860 | + * @type {Boolean} | |
861 | + */ | |
862 | +jvm.VMLElement.VMLInitialized = false; | |
863 | + | |
864 | +/** | |
865 | + * Initializes VML handling before creating the first element | |
866 | + * (adds CSS class and creates namespace). Adds one of two forms | |
867 | + * of createElement method depending of support by browser. | |
868 | + * @static | |
869 | + * @private | |
870 | + */ | |
871 | + | |
872 | + // The following method of VML handling is borrowed from the | |
873 | + // Raphael library by Dmitry Baranovsky. | |
874 | + | |
875 | +jvm.VMLElement.initializeVML = function(){ | |
876 | + try { | |
877 | + if (!document.namespaces.rvml) { | |
878 | + document.namespaces.add("rvml","urn:schemas-microsoft-com:vml"); | |
879 | + } | |
880 | + /** | |
881 | + * Creates DOM element. | |
882 | + * @param {String} tagName Name of element | |
883 | + * @private | |
884 | + * @returns DOMElement | |
885 | + */ | |
886 | + jvm.VMLElement.prototype.createElement = function (tagName) { | |
887 | + return document.createElement('<rvml:' + tagName + ' class="rvml">'); | |
888 | + }; | |
889 | + } catch (e) { | |
890 | + /** | |
891 | + * @private | |
892 | + */ | |
893 | + jvm.VMLElement.prototype.createElement = function (tagName) { | |
894 | + return document.createElement('<' + tagName + ' xmlns="urn:schemas-microsoft.com:vml" class="rvml">'); | |
895 | + }; | |
896 | + } | |
897 | + document.createStyleSheet().addRule(".rvml", "behavior:url(#default#VML)"); | |
898 | + jvm.VMLElement.VMLInitialized = true; | |
899 | +}; | |
900 | + | |
901 | +/** | |
902 | + * Returns constructor for element by name prefixed with 'VML'. | |
903 | + * @param {String} ctr Name of basic constructor to return | |
904 | + * proper implementation for. | |
905 | + * @returns Function | |
906 | + * @private | |
907 | + */ | |
908 | +jvm.VMLElement.prototype.getElementCtr = function( ctr ){ | |
909 | + return jvm['VML'+ctr]; | |
910 | +}; | |
911 | + | |
912 | +/** | |
913 | + * Adds CSS class for underlying DOM element. | |
914 | + * @param {String} className Name of CSS class name | |
915 | + */ | |
916 | +jvm.VMLElement.prototype.addClass = function( className ){ | |
917 | + jvm.$(this.node).addClass(className); | |
918 | +}; | |
919 | + | |
920 | +/** | |
921 | + * Applies attribute value to the underlying DOM element. | |
922 | + * @param {String} name Name of attribute | |
923 | + * @param {Number|String} config Value of attribute to apply | |
924 | + * @private | |
925 | + */ | |
926 | +jvm.VMLElement.prototype.applyAttr = function( attr, value ){ | |
927 | + this.node[attr] = value; | |
928 | +}; | |
929 | + | |
930 | +/** | |
931 | + * Returns boundary box for the element. | |
932 | + * @returns {Object} Boundary box with numeric fields: x, y, width, height | |
933 | + * @override | |
934 | + */ | |
935 | +jvm.VMLElement.prototype.getBBox = function(){ | |
936 | + var node = jvm.$(this.node); | |
937 | + | |
938 | + return { | |
939 | + x: node.position().left / this.canvas.scale, | |
940 | + y: node.position().top / this.canvas.scale, | |
941 | + width: node.width() / this.canvas.scale, | |
942 | + height: node.height() / this.canvas.scale | |
943 | + }; | |
944 | +};jvm.VMLGroupElement = function(){ | |
945 | + jvm.VMLGroupElement.parentClass.call(this, 'group'); | |
946 | + | |
947 | + this.node.style.left = '0px'; | |
948 | + this.node.style.top = '0px'; | |
949 | + this.node.coordorigin = "0 0"; | |
950 | +}; | |
951 | + | |
952 | +jvm.inherits(jvm.VMLGroupElement, jvm.VMLElement); | |
953 | + | |
954 | +jvm.VMLGroupElement.prototype.add = function(element){ | |
955 | + this.node.appendChild( element.node ); | |
956 | +};jvm.VMLCanvasElement = function(container, width, height){ | |
957 | + this.classPrefix = 'VML'; | |
958 | + jvm.VMLCanvasElement.parentClass.call(this, 'group'); | |
959 | + jvm.AbstractCanvasElement.apply(this, arguments); | |
960 | + this.node.style.position = 'absolute'; | |
961 | +}; | |
962 | + | |
963 | +jvm.inherits(jvm.VMLCanvasElement, jvm.VMLElement); | |
964 | +jvm.mixin(jvm.VMLCanvasElement, jvm.AbstractCanvasElement); | |
965 | + | |
966 | +jvm.VMLCanvasElement.prototype.setSize = function(width, height){ | |
967 | + var paths, | |
968 | + groups, | |
969 | + i, | |
970 | + l; | |
971 | + | |
972 | + this.width = width; | |
973 | + this.height = height; | |
974 | + this.node.style.width = width + "px"; | |
975 | + this.node.style.height = height + "px"; | |
976 | + this.node.coordsize = width+' '+height; | |
977 | + this.node.coordorigin = "0 0"; | |
978 | + if (this.rootElement) { | |
979 | + paths = this.rootElement.node.getElementsByTagName('shape'); | |
980 | + for(i = 0, l = paths.length; i < l; i++) { | |
981 | + paths[i].coordsize = width+' '+height; | |
982 | + paths[i].style.width = width+'px'; | |
983 | + paths[i].style.height = height+'px'; | |
984 | + } | |
985 | + groups = this.node.getElementsByTagName('group'); | |
986 | + for(i = 0, l = groups.length; i < l; i++) { | |
987 | + groups[i].coordsize = width+' '+height; | |
988 | + groups[i].style.width = width+'px'; | |
989 | + groups[i].style.height = height+'px'; | |
990 | + } | |
991 | + } | |
992 | +}; | |
993 | + | |
994 | +jvm.VMLCanvasElement.prototype.applyTransformParams = function(scale, transX, transY) { | |
995 | + this.scale = scale; | |
996 | + this.transX = transX; | |
997 | + this.transY = transY; | |
998 | + this.rootElement.node.coordorigin = (this.width-transX-this.width/100)+','+(this.height-transY-this.height/100); | |
999 | + this.rootElement.node.coordsize = this.width/scale+','+this.height/scale; | |
1000 | +};jvm.VMLShapeElement = function(name, config){ | |
1001 | + jvm.VMLShapeElement.parentClass.call(this, name, config); | |
1002 | + | |
1003 | + this.fillElement = new jvm.VMLElement('fill'); | |
1004 | + this.strokeElement = new jvm.VMLElement('stroke'); | |
1005 | + this.node.appendChild(this.fillElement.node); | |
1006 | + this.node.appendChild(this.strokeElement.node); | |
1007 | + this.node.stroked = false; | |
1008 | + | |
1009 | + jvm.AbstractShapeElement.apply(this, arguments); | |
1010 | +}; | |
1011 | + | |
1012 | +jvm.inherits(jvm.VMLShapeElement, jvm.VMLElement); | |
1013 | +jvm.mixin(jvm.VMLShapeElement, jvm.AbstractShapeElement); | |
1014 | + | |
1015 | +jvm.VMLShapeElement.prototype.applyAttr = function(attr, value){ | |
1016 | + switch (attr) { | |
1017 | + case 'fill': | |
1018 | + this.node.fillcolor = value; | |
1019 | + break; | |
1020 | + case 'fill-opacity': | |
1021 | + this.fillElement.node.opacity = Math.round(value*100)+'%'; | |
1022 | + break; | |
1023 | + case 'stroke': | |
1024 | + if (value === 'none') { | |
1025 | + this.node.stroked = false; | |
1026 | + } else { | |
1027 | + this.node.stroked = true; | |
1028 | + } | |
1029 | + this.node.strokecolor = value; | |
1030 | + break; | |
1031 | + case 'stroke-opacity': | |
1032 | + this.strokeElement.node.opacity = Math.round(value*100)+'%'; | |
1033 | + break; | |
1034 | + case 'stroke-width': | |
1035 | + if (parseInt(value, 10) === 0) { | |
1036 | + this.node.stroked = false; | |
1037 | + } else { | |
1038 | + this.node.stroked = true; | |
1039 | + } | |
1040 | + this.node.strokeweight = value; | |
1041 | + break; | |
1042 | + case 'd': | |
1043 | + this.node.path = jvm.VMLPathElement.pathSvgToVml(value); | |
1044 | + break; | |
1045 | + default: | |
1046 | + jvm.VMLShapeElement.parentClass.prototype.applyAttr.apply(this, arguments); | |
1047 | + } | |
1048 | +};jvm.VMLPathElement = function(config, style){ | |
1049 | + var scale = new jvm.VMLElement('skew'); | |
1050 | + | |
1051 | + jvm.VMLPathElement.parentClass.call(this, 'shape', config, style); | |
1052 | + | |
1053 | + this.node.coordorigin = "0 0"; | |
1054 | + | |
1055 | + scale.node.on = true; | |
1056 | + scale.node.matrix = '0.01,0,0,0.01,0,0'; | |
1057 | + scale.node.offset = '0,0'; | |
1058 | + | |
1059 | + this.node.appendChild(scale.node); | |
1060 | +}; | |
1061 | + | |
1062 | +jvm.inherits(jvm.VMLPathElement, jvm.VMLShapeElement); | |
1063 | + | |
1064 | +jvm.VMLPathElement.prototype.applyAttr = function(attr, value){ | |
1065 | + if (attr === 'd') { | |
1066 | + this.node.path = jvm.VMLPathElement.pathSvgToVml(value); | |
1067 | + } else { | |
1068 | + jvm.VMLShapeElement.prototype.applyAttr.call(this, attr, value); | |
1069 | + } | |
1070 | +}; | |
1071 | + | |
1072 | +jvm.VMLPathElement.pathSvgToVml = function(path) { | |
1073 | + var cx = 0, cy = 0, ctrlx, ctrly; | |
1074 | + | |
1075 | + path = path.replace(/(-?\d+)e(-?\d+)/g, '0'); | |
1076 | + return path.replace(/([MmLlHhVvCcSs])\s*((?:-?\d*(?:\.\d+)?\s*,?\s*)+)/g, function(segment, letter, coords, index){ | |
1077 | + coords = coords.replace(/(\d)-/g, '$1,-') | |
1078 | + .replace(/^\s+/g, '') | |
1079 | + .replace(/\s+$/g, '') | |
1080 | + .replace(/\s+/g, ',').split(','); | |
1081 | + if (!coords[0]) coords.shift(); | |
1082 | + for (var i=0, l=coords.length; i<l; i++) { | |
1083 | + coords[i] = Math.round(100*coords[i]); | |
1084 | + } | |
1085 | + switch (letter) { | |
1086 | + case 'm': | |
1087 | + cx += coords[0]; | |
1088 | + cy += coords[1]; | |
1089 | + return 't'+coords.join(','); | |
1090 | + case 'M': | |
1091 | + cx = coords[0]; | |
1092 | + cy = coords[1]; | |
1093 | + return 'm'+coords.join(','); | |
1094 | + case 'l': | |
1095 | + cx += coords[0]; | |
1096 | + cy += coords[1]; | |
1097 | + return 'r'+coords.join(','); | |
1098 | + case 'L': | |
1099 | + cx = coords[0]; | |
1100 | + cy = coords[1]; | |
1101 | + return 'l'+coords.join(','); | |
1102 | + case 'h': | |
1103 | + cx += coords[0]; | |
1104 | + return 'r'+coords[0]+',0'; | |
1105 | + case 'H': | |
1106 | + cx = coords[0]; | |
1107 | + return 'l'+cx+','+cy; | |
1108 | + case 'v': | |
1109 | + cy += coords[0]; | |
1110 | + return 'r0,'+coords[0]; | |
1111 | + case 'V': | |
1112 | + cy = coords[0]; | |
1113 | + return 'l'+cx+','+cy; | |
1114 | + case 'c': | |
1115 | + ctrlx = cx + coords[coords.length-4]; | |
1116 | + ctrly = cy + coords[coords.length-3]; | |
1117 | + cx += coords[coords.length-2]; | |
1118 | + cy += coords[coords.length-1]; | |
1119 | + return 'v'+coords.join(','); | |
1120 | + case 'C': | |
1121 | + ctrlx = coords[coords.length-4]; | |
1122 | + ctrly = coords[coords.length-3]; | |
1123 | + cx = coords[coords.length-2]; | |
1124 | + cy = coords[coords.length-1]; | |
1125 | + return 'c'+coords.join(','); | |
1126 | + case 's': | |
1127 | + coords.unshift(cy-ctrly); | |
1128 | + coords.unshift(cx-ctrlx); | |
1129 | + ctrlx = cx + coords[coords.length-4]; | |
1130 | + ctrly = cy + coords[coords.length-3]; | |
1131 | + cx += coords[coords.length-2]; | |
1132 | + cy += coords[coords.length-1]; | |
1133 | + return 'v'+coords.join(','); | |
1134 | + case 'S': | |
1135 | + coords.unshift(cy+cy-ctrly); | |
1136 | + coords.unshift(cx+cx-ctrlx); | |
1137 | + ctrlx = coords[coords.length-4]; | |
1138 | + ctrly = coords[coords.length-3]; | |
1139 | + cx = coords[coords.length-2]; | |
1140 | + cy = coords[coords.length-1]; | |
1141 | + return 'c'+coords.join(','); | |
1142 | + } | |
1143 | + return ''; | |
1144 | + }).replace(/z/g, 'e'); | |
1145 | +};jvm.VMLCircleElement = function(config, style){ | |
1146 | + jvm.VMLCircleElement.parentClass.call(this, 'oval', config, style); | |
1147 | +}; | |
1148 | + | |
1149 | +jvm.inherits(jvm.VMLCircleElement, jvm.VMLShapeElement); | |
1150 | + | |
1151 | +jvm.VMLCircleElement.prototype.applyAttr = function(attr, value){ | |
1152 | + switch (attr) { | |
1153 | + case 'r': | |
1154 | + this.node.style.width = value*2+'px'; | |
1155 | + this.node.style.height = value*2+'px'; | |
1156 | + this.applyAttr('cx', this.get('cx') || 0); | |
1157 | + this.applyAttr('cy', this.get('cy') || 0); | |
1158 | + break; | |
1159 | + case 'cx': | |
1160 | + if (!value) return; | |
1161 | + this.node.style.left = value - (this.get('r') || 0) + 'px'; | |
1162 | + break; | |
1163 | + case 'cy': | |
1164 | + if (!value) return; | |
1165 | + this.node.style.top = value - (this.get('r') || 0) + 'px'; | |
1166 | + break; | |
1167 | + default: | |
1168 | + jvm.VMLCircleElement.parentClass.prototype.applyAttr.call(this, attr, value); | |
1169 | + } | |
1170 | +};/** | |
1171 | + * Class for vector images manipulations. | |
1172 | + * @constructor | |
1173 | + * @param {DOMElement} container to place canvas to | |
1174 | + * @param {Number} width | |
1175 | + * @param {Number} height | |
1176 | + */ | |
1177 | +jvm.VectorCanvas = function(container, width, height) { | |
1178 | + this.mode = window.SVGAngle ? 'svg' : 'vml'; | |
1179 | + | |
1180 | + if (this.mode == 'svg') { | |
1181 | + this.impl = new jvm.SVGCanvasElement(container, width, height); | |
1182 | + } else { | |
1183 | + this.impl = new jvm.VMLCanvasElement(container, width, height); | |
1184 | + } | |
1185 | + this.impl.mode = this.mode; | |
1186 | + return this.impl; | |
1187 | +};jvm.SimpleScale = function(scale){ | |
1188 | + this.scale = scale; | |
1189 | +}; | |
1190 | + | |
1191 | +jvm.SimpleScale.prototype.getValue = function(value){ | |
1192 | + return value; | |
1193 | +};jvm.OrdinalScale = function(scale){ | |
1194 | + this.scale = scale; | |
1195 | +}; | |
1196 | + | |
1197 | +jvm.OrdinalScale.prototype.getValue = function(value){ | |
1198 | + return this.scale[value]; | |
1199 | +}; | |
1200 | + | |
1201 | +jvm.OrdinalScale.prototype.getTicks = function(){ | |
1202 | + var ticks = [], | |
1203 | + key; | |
1204 | + | |
1205 | + for (key in this.scale) { | |
1206 | + ticks.push({ | |
1207 | + label: key, | |
1208 | + value: this.scale[key] | |
1209 | + }); | |
1210 | + } | |
1211 | + | |
1212 | + return ticks; | |
1213 | +};jvm.NumericScale = function(scale, normalizeFunction, minValue, maxValue) { | |
1214 | + this.scale = []; | |
1215 | + | |
1216 | + normalizeFunction = normalizeFunction || 'linear'; | |
1217 | + | |
1218 | + if (scale) this.setScale(scale); | |
1219 | + if (normalizeFunction) this.setNormalizeFunction(normalizeFunction); | |
1220 | + if (typeof minValue !== 'undefined' ) this.setMin(minValue); | |
1221 | + if (typeof maxValue !== 'undefined' ) this.setMax(maxValue); | |
1222 | +}; | |
1223 | + | |
1224 | +jvm.NumericScale.prototype = { | |
1225 | + setMin: function(min) { | |
1226 | + this.clearMinValue = min; | |
1227 | + if (typeof this.normalize === 'function') { | |
1228 | + this.minValue = this.normalize(min); | |
1229 | + } else { | |
1230 | + this.minValue = min; | |
1231 | + } | |
1232 | + }, | |
1233 | + | |
1234 | + setMax: function(max) { | |
1235 | + this.clearMaxValue = max; | |
1236 | + if (typeof this.normalize === 'function') { | |
1237 | + this.maxValue = this.normalize(max); | |
1238 | + } else { | |
1239 | + this.maxValue = max; | |
1240 | + } | |
1241 | + }, | |
1242 | + | |
1243 | + setScale: function(scale) { | |
1244 | + var i; | |
1245 | + | |
1246 | + this.scale = []; | |
1247 | + for (i = 0; i < scale.length; i++) { | |
1248 | + this.scale[i] = [scale[i]]; | |
1249 | + } | |
1250 | + }, | |
1251 | + | |
1252 | + setNormalizeFunction: function(f) { | |
1253 | + if (f === 'polynomial') { | |
1254 | + this.normalize = function(value) { | |
1255 | + return Math.pow(value, 0.2); | |
1256 | + } | |
1257 | + } else if (f === 'linear') { | |
1258 | + delete this.normalize; | |
1259 | + } else { | |
1260 | + this.normalize = f; | |
1261 | + } | |
1262 | + this.setMin(this.clearMinValue); | |
1263 | + this.setMax(this.clearMaxValue); | |
1264 | + }, | |
1265 | + | |
1266 | + getValue: function(value) { | |
1267 | + var lengthes = [], | |
1268 | + fullLength = 0, | |
1269 | + l, | |
1270 | + i = 0, | |
1271 | + c; | |
1272 | + | |
1273 | + if (typeof this.normalize === 'function') { | |
1274 | + value = this.normalize(value); | |
1275 | + } | |
1276 | + for (i = 0; i < this.scale.length-1; i++) { | |
1277 | + l = this.vectorLength(this.vectorSubtract(this.scale[i+1], this.scale[i])); | |
1278 | + lengthes.push(l); | |
1279 | + fullLength += l; | |
1280 | + } | |
1281 | + | |
1282 | + c = (this.maxValue - this.minValue) / fullLength; | |
1283 | + for (i=0; i<lengthes.length; i++) { | |
1284 | + lengthes[i] *= c; | |
1285 | + } | |
1286 | + | |
1287 | + i = 0; | |
1288 | + value -= this.minValue; | |
1289 | + while (value - lengthes[i] >= 0) { | |
1290 | + value -= lengthes[i]; | |
1291 | + i++; | |
1292 | + } | |
1293 | + | |
1294 | + if (i == this.scale.length - 1) { | |
1295 | + value = this.vectorToNum(this.scale[i]) | |
1296 | + } else { | |
1297 | + value = ( | |
1298 | + this.vectorToNum( | |
1299 | + this.vectorAdd(this.scale[i], | |
1300 | + this.vectorMult( | |
1301 | + this.vectorSubtract(this.scale[i+1], this.scale[i]), | |
1302 | + (value) / (lengthes[i]) | |
1303 | + ) | |
1304 | + ) | |
1305 | + ) | |
1306 | + ); | |
1307 | + } | |
1308 | + | |
1309 | + return value; | |
1310 | + }, | |
1311 | + | |
1312 | + vectorToNum: function(vector) { | |
1313 | + var num = 0, | |
1314 | + i; | |
1315 | + | |
1316 | + for (i = 0; i < vector.length; i++) { | |
1317 | + num += Math.round(vector[i])*Math.pow(256, vector.length-i-1); | |
1318 | + } | |
1319 | + return num; | |
1320 | + }, | |
1321 | + | |
1322 | + vectorSubtract: function(vector1, vector2) { | |
1323 | + var vector = [], | |
1324 | + i; | |
1325 | + | |
1326 | + for (i = 0; i < vector1.length; i++) { | |
1327 | + vector[i] = vector1[i] - vector2[i]; | |
1328 | + } | |
1329 | + return vector; | |
1330 | + }, | |
1331 | + | |
1332 | + vectorAdd: function(vector1, vector2) { | |
1333 | + var vector = [], | |
1334 | + i; | |
1335 | + | |
1336 | + for (i = 0; i < vector1.length; i++) { | |
1337 | + vector[i] = vector1[i] + vector2[i]; | |
1338 | + } | |
1339 | + return vector; | |
1340 | + }, | |
1341 | + | |
1342 | + vectorMult: function(vector, num) { | |
1343 | + var result = [], | |
1344 | + i; | |
1345 | + | |
1346 | + for (i = 0; i < vector.length; i++) { | |
1347 | + result[i] = vector[i] * num; | |
1348 | + } | |
1349 | + return result; | |
1350 | + }, | |
1351 | + | |
1352 | + vectorLength: function(vector) { | |
1353 | + var result = 0, | |
1354 | + i; | |
1355 | + for (i = 0; i < vector.length; i++) { | |
1356 | + result += vector[i] * vector[i]; | |
1357 | + } | |
1358 | + return Math.sqrt(result); | |
1359 | + }, | |
1360 | + | |
1361 | + /* Derived from d3 implementation https://github.com/mbostock/d3/blob/master/src/scale/linear.js#L94 */ | |
1362 | + getTicks: function(){ | |
1363 | + var m = 5, | |
1364 | + extent = [this.clearMinValue, this.clearMaxValue], | |
1365 | + span = extent[1] - extent[0], | |
1366 | + step = Math.pow(10, Math.floor(Math.log(span / m) / Math.LN10)), | |
1367 | + err = m / span * step, | |
1368 | + ticks = [], | |
1369 | + tick, | |
1370 | + v; | |
1371 | + | |
1372 | + if (err <= .15) step *= 10; | |
1373 | + else if (err <= .35) step *= 5; | |
1374 | + else if (err <= .75) step *= 2; | |
1375 | + | |
1376 | + extent[0] = Math.floor(extent[0] / step) * step; | |
1377 | + extent[1] = Math.ceil(extent[1] / step) * step; | |
1378 | + | |
1379 | + tick = extent[0]; | |
1380 | + while (tick <= extent[1]) { | |
1381 | + if (tick == extent[0]) { | |
1382 | + v = this.clearMinValue; | |
1383 | + } else if (tick == extent[1]) { | |
1384 | + v = this.clearMaxValue; | |
1385 | + } else { | |
1386 | + v = tick; | |
1387 | + } | |
1388 | + ticks.push({ | |
1389 | + label: tick, | |
1390 | + value: this.getValue(v) | |
1391 | + }); | |
1392 | + tick += step; | |
1393 | + } | |
1394 | + | |
1395 | + return ticks; | |
1396 | + } | |
1397 | +}; | |
1398 | +jvm.ColorScale = function(colors, normalizeFunction, minValue, maxValue) { | |
1399 | + jvm.ColorScale.parentClass.apply(this, arguments); | |
1400 | +} | |
1401 | + | |
1402 | +jvm.inherits(jvm.ColorScale, jvm.NumericScale); | |
1403 | + | |
1404 | +jvm.ColorScale.prototype.setScale = function(scale) { | |
1405 | + var i; | |
1406 | + | |
1407 | + for (i = 0; i < scale.length; i++) { | |
1408 | + this.scale[i] = jvm.ColorScale.rgbToArray(scale[i]); | |
1409 | + } | |
1410 | +}; | |
1411 | + | |
1412 | +jvm.ColorScale.prototype.getValue = function(value) { | |
1413 | + return jvm.ColorScale.numToRgb(jvm.ColorScale.parentClass.prototype.getValue.call(this, value)); | |
1414 | +}; | |
1415 | + | |
1416 | +jvm.ColorScale.arrayToRgb = function(ar) { | |
1417 | + var rgb = '#', | |
1418 | + d, | |
1419 | + i; | |
1420 | + | |
1421 | + for (i = 0; i < ar.length; i++) { | |
1422 | + d = ar[i].toString(16); | |
1423 | + rgb += d.length == 1 ? '0'+d : d; | |
1424 | + } | |
1425 | + return rgb; | |
1426 | +}; | |
1427 | + | |
1428 | +jvm.ColorScale.numToRgb = function(num) { | |
1429 | + num = num.toString(16); | |
1430 | + | |
1431 | + while (num.length < 6) { | |
1432 | + num = '0' + num; | |
1433 | + } | |
1434 | + | |
1435 | + return '#'+num; | |
1436 | +}; | |
1437 | + | |
1438 | +jvm.ColorScale.rgbToArray = function(rgb) { | |
1439 | + rgb = rgb.substr(1); | |
1440 | + return [parseInt(rgb.substr(0, 2), 16), parseInt(rgb.substr(2, 2), 16), parseInt(rgb.substr(4, 2), 16)]; | |
1441 | +};/** | |
1442 | + * Represents map legend. | |
1443 | + * @constructor | |
1444 | + * @param {Object} params Configuration parameters. | |
1445 | + * @param {String} params.cssClass Additional CSS class to apply to legend element. | |
1446 | + * @param {Boolean} params.vertical If <code>true</code> legend will be rendered as vertical. | |
1447 | + * @param {String} params.title Legend title. | |
1448 | + * @param {Function} params.labelRender Method to convert series values to legend labels. | |
1449 | + */ | |
1450 | +jvm.Legend = function(params) { | |
1451 | + this.params = params || {}; | |
1452 | + this.map = this.params.map; | |
1453 | + this.series = this.params.series; | |
1454 | + this.body = jvm.$('<div/>'); | |
1455 | + this.body.addClass('jvectormap-legend'); | |
1456 | + if (this.params.cssClass) { | |
1457 | + this.body.addClass(this.params.cssClass); | |
1458 | + } | |
1459 | + | |
1460 | + if (params.vertical) { | |
1461 | + this.map.legendCntVertical.append( this.body ); | |
1462 | + } else { | |
1463 | + this.map.legendCntHorizontal.append( this.body ); | |
1464 | + } | |
1465 | + | |
1466 | + this.render(); | |
1467 | +} | |
1468 | + | |
1469 | +jvm.Legend.prototype.render = function(){ | |
1470 | + var ticks = this.series.scale.getTicks(), | |
1471 | + i, | |
1472 | + inner = jvm.$('<div/>').addClass('jvectormap-legend-inner'), | |
1473 | + tick, | |
1474 | + sample, | |
1475 | + label; | |
1476 | + | |
1477 | + this.body.html(''); | |
1478 | + if (this.params.title) { | |
1479 | + this.body.append( | |
1480 | + jvm.$('<div/>').addClass('jvectormap-legend-title').html(this.params.title) | |
1481 | + ); | |
1482 | + } | |
1483 | + this.body.append(inner); | |
1484 | + | |
1485 | + for (i = 0; i < ticks.length; i++) { | |
1486 | + tick = jvm.$('<div/>').addClass('jvectormap-legend-tick'); | |
1487 | + sample = jvm.$('<div/>').addClass('jvectormap-legend-tick-sample'); | |
1488 | + | |
1489 | + switch (this.series.params.attribute) { | |
1490 | + case 'fill': | |
1491 | + if (jvm.isImageUrl(ticks[i].value)) { | |
1492 | + sample.css('background', 'url('+ticks[i].value+')'); | |
1493 | + } else { | |
1494 | + sample.css('background', ticks[i].value); | |
1495 | + } | |
1496 | + break; | |
1497 | + case 'stroke': | |
1498 | + sample.css('background', ticks[i].value); | |
1499 | + break; | |
1500 | + case 'image': | |
1501 | + sample.css('background', 'url('+ticks[i].value+') no-repeat center center'); | |
1502 | + break; | |
1503 | + case 'r': | |
1504 | + jvm.$('<div/>').css({ | |
1505 | + 'border-radius': ticks[i].value, | |
1506 | + border: this.map.params.markerStyle.initial['stroke-width']+'px '+ | |
1507 | + this.map.params.markerStyle.initial['stroke']+' solid', | |
1508 | + width: ticks[i].value * 2 + 'px', | |
1509 | + height: ticks[i].value * 2 + 'px', | |
1510 | + background: this.map.params.markerStyle.initial['fill'] | |
1511 | + }).appendTo(sample); | |
1512 | + break; | |
1513 | + } | |
1514 | + tick.append( sample ); | |
1515 | + label = ticks[i].label; | |
1516 | + if (this.params.labelRender) { | |
1517 | + label = this.params.labelRender(label); | |
1518 | + } | |
1519 | + tick.append( jvm.$('<div>'+label+' </div>').addClass('jvectormap-legend-tick-text') ); | |
1520 | + inner.append(tick); | |
1521 | + } | |
1522 | + inner.append( jvm.$('<div/>').css('clear', 'both') ); | |
1523 | +}/** | |
1524 | + * Creates data series. | |
1525 | + * @constructor | |
1526 | + * @param {Object} params Parameters to initialize series with. | |
1527 | + * @param {Array} params.values The data set to visualize. | |
1528 | + * @param {String} params.attribute Numberic or color attribute to use for data visualization. This could be: <code>fill</code>, <code>stroke</code>, <code>fill-opacity</code>, <code>stroke-opacity</code> for markers and regions and <code>r</code> (radius) for markers only. | |
1529 | + * @param {Array} params.scale Values used to map a dimension of data to a visual representation. The first value sets visualization for minimum value from the data set and the last value sets visualization for the maximum value. There also could be intermidiate values. Default value is <code>['#C8EEFF', '#0071A4']</code> | |
1530 | + * @param {Function|String} params.normalizeFunction The function used to map input values to the provided scale. This parameter could be provided as function or one of the strings: <code>'linear'</code> or <code>'polynomial'</code>, while <code>'linear'</code> is used by default. The function provided takes value from the data set as an input and returns corresponding value from the scale. | |
1531 | + * @param {Number} params.min Minimum value of the data set. Could be calculated automatically if not provided. | |
1532 | + * @param {Number} params.min Maximum value of the data set. Could be calculated automatically if not provided. | |
1533 | + */ | |
1534 | +jvm.DataSeries = function(params, elements, map) { | |
1535 | + var scaleConstructor; | |
1536 | + | |
1537 | + params = params || {}; | |
1538 | + params.attribute = params.attribute || 'fill'; | |
1539 | + | |
1540 | + this.elements = elements; | |
1541 | + this.params = params; | |
1542 | + this.map = map; | |
1543 | + | |
1544 | + if (params.attributes) { | |
1545 | + this.setAttributes(params.attributes); | |
1546 | + } | |
1547 | + | |
1548 | + if (jvm.$.isArray(params.scale)) { | |
1549 | + scaleConstructor = (params.attribute === 'fill' || params.attribute === 'stroke') ? jvm.ColorScale : jvm.NumericScale; | |
1550 | + this.scale = new scaleConstructor(params.scale, params.normalizeFunction, params.min, params.max); | |
1551 | + } else if (params.scale) { | |
1552 | + this.scale = new jvm.OrdinalScale(params.scale); | |
1553 | + } else { | |
1554 | + this.scale = new jvm.SimpleScale(params.scale); | |
1555 | + } | |
1556 | + | |
1557 | + this.values = params.values || {}; | |
1558 | + this.setValues(this.values); | |
1559 | + | |
1560 | + if (this.params.legend) { | |
1561 | + this.legend = new jvm.Legend($.extend({ | |
1562 | + map: this.map, | |
1563 | + series: this | |
1564 | + }, this.params.legend)) | |
1565 | + } | |
1566 | +}; | |
1567 | + | |
1568 | +jvm.DataSeries.prototype = { | |
1569 | + setAttributes: function(key, attr){ | |
1570 | + var attrs = key, | |
1571 | + code; | |
1572 | + | |
1573 | + if (typeof key == 'string') { | |
1574 | + if (this.elements[key]) { | |
1575 | + this.elements[key].setStyle(this.params.attribute, attr); | |
1576 | + } | |
1577 | + } else { | |
1578 | + for (code in attrs) { | |
1579 | + if (this.elements[code]) { | |
1580 | + this.elements[code].element.setStyle(this.params.attribute, attrs[code]); | |
1581 | + } | |
1582 | + } | |
1583 | + } | |
1584 | + }, | |
1585 | + | |
1586 | + /** | |
1587 | + * Set values for the data set. | |
1588 | + * @param {Object} values Object which maps codes of regions or markers to values. | |
1589 | + */ | |
1590 | + setValues: function(values) { | |
1591 | + var max = -Number.MAX_VALUE, | |
1592 | + min = Number.MAX_VALUE, | |
1593 | + val, | |
1594 | + cc, | |
1595 | + attrs = {}; | |
1596 | + | |
1597 | + if (!(this.scale instanceof jvm.OrdinalScale) && !(this.scale instanceof jvm.SimpleScale)) { | |
1598 | + // we have a color scale as an array | |
1599 | + if (typeof this.params.min === 'undefined' || typeof this.params.max === 'undefined') { | |
1600 | + // min and/or max are not defined, so calculate them | |
1601 | + for (cc in values) { | |
1602 | + val = parseFloat(values[cc]); | |
1603 | + if (val > max) max = val; | |
1604 | + if (val < min) min = val; | |
1605 | + } | |
1606 | + } | |
1607 | + | |
1608 | + if (typeof this.params.min === 'undefined') { | |
1609 | + this.scale.setMin(min); | |
1610 | + this.params.min = min; | |
1611 | + } else { | |
1612 | + this.scale.setMin(this.params.min); | |
1613 | + } | |
1614 | + | |
1615 | + if (typeof this.params.max === 'undefined') { | |
1616 | + this.scale.setMax(max); | |
1617 | + this.params.max = max; | |
1618 | + } else { | |
1619 | + this.scale.setMax(this.params.max); | |
1620 | + } | |
1621 | + | |
1622 | + for (cc in values) { | |
1623 | + if (cc != 'indexOf') { | |
1624 | + val = parseFloat(values[cc]); | |
1625 | + if (!isNaN(val)) { | |
1626 | + attrs[cc] = this.scale.getValue(val); | |
1627 | + } else { | |
1628 | + attrs[cc] = this.elements[cc].element.style.initial[this.params.attribute]; | |
1629 | + } | |
1630 | + } | |
1631 | + } | |
1632 | + } else { | |
1633 | + for (cc in values) { | |
1634 | + if (values[cc]) { | |
1635 | + attrs[cc] = this.scale.getValue(values[cc]); | |
1636 | + } else { | |
1637 | + attrs[cc] = this.elements[cc].element.style.initial[this.params.attribute]; | |
1638 | + } | |
1639 | + } | |
1640 | + } | |
1641 | + | |
1642 | + this.setAttributes(attrs); | |
1643 | + jvm.$.extend(this.values, values); | |
1644 | + }, | |
1645 | + | |
1646 | + clear: function(){ | |
1647 | + var key, | |
1648 | + attrs = {}; | |
1649 | + | |
1650 | + for (key in this.values) { | |
1651 | + if (this.elements[key]) { | |
1652 | + attrs[key] = this.elements[key].element.shape.style.initial[this.params.attribute]; | |
1653 | + } | |
1654 | + } | |
1655 | + this.setAttributes(attrs); | |
1656 | + this.values = {}; | |
1657 | + }, | |
1658 | + | |
1659 | + /** | |
1660 | + * Set scale of the data series. | |
1661 | + * @param {Array} scale Values representing scale. | |
1662 | + */ | |
1663 | + setScale: function(scale) { | |
1664 | + this.scale.setScale(scale); | |
1665 | + if (this.values) { | |
1666 | + this.setValues(this.values); | |
1667 | + } | |
1668 | + }, | |
1669 | + | |
1670 | + /** | |
1671 | + * Set normalize function of the data series. | |
1672 | + * @param {Function|String} normilizeFunction. | |
1673 | + */ | |
1674 | + setNormalizeFunction: function(f) { | |
1675 | + this.scale.setNormalizeFunction(f); | |
1676 | + if (this.values) { | |
1677 | + this.setValues(this.values); | |
1678 | + } | |
1679 | + } | |
1680 | +}; | |
1681 | +/** | |
1682 | + * Contains methods for transforming point on sphere to | |
1683 | + * Cartesian coordinates using various projections. | |
1684 | + * @class | |
1685 | + */ | |
1686 | +jvm.Proj = { | |
1687 | + degRad: 180 / Math.PI, | |
1688 | + radDeg: Math.PI / 180, | |
1689 | + radius: 6381372, | |
1690 | + | |
1691 | + sgn: function(n){ | |
1692 | + if (n > 0) { | |
1693 | + return 1; | |
1694 | + } else if (n < 0) { | |
1695 | + return -1; | |
1696 | + } else { | |
1697 | + return n; | |
1698 | + } | |
1699 | + }, | |
1700 | + | |
1701 | + /** | |
1702 | + * Converts point on sphere to the Cartesian coordinates using Miller projection | |
1703 | + * @param {Number} lat Latitude in degrees | |
1704 | + * @param {Number} lng Longitude in degrees | |
1705 | + * @param {Number} c Central meridian in degrees | |
1706 | + */ | |
1707 | + mill: function(lat, lng, c){ | |
1708 | + return { | |
1709 | + x: this.radius * (lng - c) * this.radDeg, | |
1710 | + y: - this.radius * Math.log(Math.tan((45 + 0.4 * lat) * this.radDeg)) / 0.8 | |
1711 | + }; | |
1712 | + }, | |
1713 | + | |
1714 | + /** | |
1715 | + * Inverse function of mill() | |
1716 | + * Converts Cartesian coordinates to point on sphere using Miller projection | |
1717 | + * @param {Number} x X of point in Cartesian system as integer | |
1718 | + * @param {Number} y Y of point in Cartesian system as integer | |
1719 | + * @param {Number} c Central meridian in degrees | |
1720 | + */ | |
1721 | + mill_inv: function(x, y, c){ | |
1722 | + return { | |
1723 | + lat: (2.5 * Math.atan(Math.exp(0.8 * y / this.radius)) - 5 * Math.PI / 8) * this.degRad, | |
1724 | + lng: (c * this.radDeg + x / this.radius) * this.degRad | |
1725 | + }; | |
1726 | + }, | |
1727 | + | |
1728 | + /** | |
1729 | + * Converts point on sphere to the Cartesian coordinates using Mercator projection | |
1730 | + * @param {Number} lat Latitude in degrees | |
1731 | + * @param {Number} lng Longitude in degrees | |
1732 | + * @param {Number} c Central meridian in degrees | |
1733 | + */ | |
1734 | + merc: function(lat, lng, c){ | |
1735 | + return { | |
1736 | + x: this.radius * (lng - c) * this.radDeg, | |
1737 | + y: - this.radius * Math.log(Math.tan(Math.PI / 4 + lat * Math.PI / 360)) | |
1738 | + }; | |
1739 | + }, | |
1740 | + | |
1741 | + /** | |
1742 | + * Inverse function of merc() | |
1743 | + * Converts Cartesian coordinates to point on sphere using Mercator projection | |
1744 | + * @param {Number} x X of point in Cartesian system as integer | |
1745 | + * @param {Number} y Y of point in Cartesian system as integer | |
1746 | + * @param {Number} c Central meridian in degrees | |
1747 | + */ | |
1748 | + merc_inv: function(x, y, c){ | |
1749 | + return { | |
1750 | + lat: (2 * Math.atan(Math.exp(y / this.radius)) - Math.PI / 2) * this.degRad, | |
1751 | + lng: (c * this.radDeg + x / this.radius) * this.degRad | |
1752 | + }; | |
1753 | + }, | |
1754 | + | |
1755 | + /** | |
1756 | + * Converts point on sphere to the Cartesian coordinates using Albers Equal-Area Conic | |
1757 | + * projection | |
1758 | + * @see <a href="http://mathworld.wolfram.com/AlbersEqual-AreaConicProjection.html">Albers Equal-Area Conic projection</a> | |
1759 | + * @param {Number} lat Latitude in degrees | |
1760 | + * @param {Number} lng Longitude in degrees | |
1761 | + * @param {Number} c Central meridian in degrees | |
1762 | + */ | |
1763 | + aea: function(lat, lng, c){ | |
1764 | + var fi0 = 0, | |
1765 | + lambda0 = c * this.radDeg, | |
1766 | + fi1 = 29.5 * this.radDeg, | |
1767 | + fi2 = 45.5 * this.radDeg, | |
1768 | + fi = lat * this.radDeg, | |
1769 | + lambda = lng * this.radDeg, | |
1770 | + n = (Math.sin(fi1)+Math.sin(fi2)) / 2, | |
1771 | + C = Math.cos(fi1)*Math.cos(fi1)+2*n*Math.sin(fi1), | |
1772 | + theta = n*(lambda-lambda0), | |
1773 | + ro = Math.sqrt(C-2*n*Math.sin(fi))/n, | |
1774 | + ro0 = Math.sqrt(C-2*n*Math.sin(fi0))/n; | |
1775 | + | |
1776 | + return { | |
1777 | + x: ro * Math.sin(theta) * this.radius, | |
1778 | + y: - (ro0 - ro * Math.cos(theta)) * this.radius | |
1779 | + }; | |
1780 | + }, | |
1781 | + | |
1782 | + /** | |
1783 | + * Converts Cartesian coordinates to the point on sphere using Albers Equal-Area Conic | |
1784 | + * projection | |
1785 | + * @see <a href="http://mathworld.wolfram.com/AlbersEqual-AreaConicProjection.html">Albers Equal-Area Conic projection</a> | |
1786 | + * @param {Number} x X of point in Cartesian system as integer | |
1787 | + * @param {Number} y Y of point in Cartesian system as integer | |
1788 | + * @param {Number} c Central meridian in degrees | |
1789 | + */ | |
1790 | + aea_inv: function(xCoord, yCoord, c){ | |
1791 | + var x = xCoord / this.radius, | |
1792 | + y = yCoord / this.radius, | |
1793 | + fi0 = 0, | |
1794 | + lambda0 = c * this.radDeg, | |
1795 | + fi1 = 29.5 * this.radDeg, | |
1796 | + fi2 = 45.5 * this.radDeg, | |
1797 | + n = (Math.sin(fi1)+Math.sin(fi2)) / 2, | |
1798 | + C = Math.cos(fi1)*Math.cos(fi1)+2*n*Math.sin(fi1), | |
1799 | + ro0 = Math.sqrt(C-2*n*Math.sin(fi0))/n, | |
1800 | + ro = Math.sqrt(x*x+(ro0-y)*(ro0-y)), | |
1801 | + theta = Math.atan( x / (ro0 - y) ); | |
1802 | + | |
1803 | + return { | |
1804 | + lat: (Math.asin((C - ro * ro * n * n) / (2 * n))) * this.degRad, | |
1805 | + lng: (lambda0 + theta / n) * this.degRad | |
1806 | + }; | |
1807 | + }, | |
1808 | + | |
1809 | + /** | |
1810 | + * Converts point on sphere to the Cartesian coordinates using Lambert conformal | |
1811 | + * conic projection | |
1812 | + * @see <a href="http://mathworld.wolfram.com/LambertConformalConicProjection.html">Lambert Conformal Conic Projection</a> | |
1813 | + * @param {Number} lat Latitude in degrees | |
1814 | + * @param {Number} lng Longitude in degrees | |
1815 | + * @param {Number} c Central meridian in degrees | |
1816 | + */ | |
1817 | + lcc: function(lat, lng, c){ | |
1818 | + var fi0 = 0, | |
1819 | + lambda0 = c * this.radDeg, | |
1820 | + lambda = lng * this.radDeg, | |
1821 | + fi1 = 33 * this.radDeg, | |
1822 | + fi2 = 45 * this.radDeg, | |
1823 | + fi = lat * this.radDeg, | |
1824 | + n = Math.log( Math.cos(fi1) * (1 / Math.cos(fi2)) ) / Math.log( Math.tan( Math.PI / 4 + fi2 / 2) * (1 / Math.tan( Math.PI / 4 + fi1 / 2) ) ), | |
1825 | + F = ( Math.cos(fi1) * Math.pow( Math.tan( Math.PI / 4 + fi1 / 2 ), n ) ) / n, | |
1826 | + ro = F * Math.pow( 1 / Math.tan( Math.PI / 4 + fi / 2 ), n ), | |
1827 | + ro0 = F * Math.pow( 1 / Math.tan( Math.PI / 4 + fi0 / 2 ), n ); | |
1828 | + | |
1829 | + return { | |
1830 | + x: ro * Math.sin( n * (lambda - lambda0) ) * this.radius, | |
1831 | + y: - (ro0 - ro * Math.cos( n * (lambda - lambda0) ) ) * this.radius | |
1832 | + }; | |
1833 | + }, | |
1834 | + | |
1835 | + /** | |
1836 | + * Converts Cartesian coordinates to the point on sphere using Lambert conformal conic | |
1837 | + * projection | |
1838 | + * @see <a href="http://mathworld.wolfram.com/LambertConformalConicProjection.html">Lambert Conformal Conic Projection</a> | |
1839 | + * @param {Number} x X of point in Cartesian system as integer | |
1840 | + * @param {Number} y Y of point in Cartesian system as integer | |
1841 | + * @param {Number} c Central meridian in degrees | |
1842 | + */ | |
1843 | + lcc_inv: function(xCoord, yCoord, c){ | |
1844 | + var x = xCoord / this.radius, | |
1845 | + y = yCoord / this.radius, | |
1846 | + fi0 = 0, | |
1847 | + lambda0 = c * this.radDeg, | |
1848 | + fi1 = 33 * this.radDeg, | |
1849 | + fi2 = 45 * this.radDeg, | |
1850 | + n = Math.log( Math.cos(fi1) * (1 / Math.cos(fi2)) ) / Math.log( Math.tan( Math.PI / 4 + fi2 / 2) * (1 / Math.tan( Math.PI / 4 + fi1 / 2) ) ), | |
1851 | + F = ( Math.cos(fi1) * Math.pow( Math.tan( Math.PI / 4 + fi1 / 2 ), n ) ) / n, | |
1852 | + ro0 = F * Math.pow( 1 / Math.tan( Math.PI / 4 + fi0 / 2 ), n ), | |
1853 | + ro = this.sgn(n) * Math.sqrt(x*x+(ro0-y)*(ro0-y)), | |
1854 | + theta = Math.atan( x / (ro0 - y) ); | |
1855 | + | |
1856 | + return { | |
1857 | + lat: (2 * Math.atan(Math.pow(F/ro, 1/n)) - Math.PI / 2) * this.degRad, | |
1858 | + lng: (lambda0 + theta / n) * this.degRad | |
1859 | + }; | |
1860 | + } | |
1861 | +};jvm.MapObject = function(config){}; | |
1862 | + | |
1863 | +jvm.MapObject.prototype.getLabelText = function(key){ | |
1864 | + var text; | |
1865 | + | |
1866 | + if (this.config.label) { | |
1867 | + if (typeof this.config.label.render === 'function') { | |
1868 | + text = this.config.label.render(key); | |
1869 | + } else { | |
1870 | + text = key; | |
1871 | + } | |
1872 | + } else { | |
1873 | + text = null; | |
1874 | + } | |
1875 | + return text; | |
1876 | +} | |
1877 | + | |
1878 | +jvm.MapObject.prototype.getLabelOffsets = function(key){ | |
1879 | + var offsets; | |
1880 | + | |
1881 | + if (this.config.label) { | |
1882 | + if (typeof this.config.label.offsets === 'function') { | |
1883 | + offsets = this.config.label.offsets(key); | |
1884 | + } else if (typeof this.config.label.offsets === 'object') { | |
1885 | + offsets = this.config.label.offsets[key]; | |
1886 | + } | |
1887 | + } | |
1888 | + return offsets || [0, 0]; | |
1889 | +} | |
1890 | + | |
1891 | +/** | |
1892 | + * Set hovered state to the element. Hovered state means mouse cursor is over element. Styles will be updates respectively. | |
1893 | + * @param {Boolean} isHovered <code>true</code> to make element hovered, <code>false</code> otherwise. | |
1894 | + */ | |
1895 | +jvm.MapObject.prototype.setHovered = function(isHovered){ | |
1896 | + if (this.isHovered !== isHovered) { | |
1897 | + this.isHovered = isHovered; | |
1898 | + this.shape.isHovered = isHovered; | |
1899 | + this.shape.updateStyle(); | |
1900 | + if (this.label) { | |
1901 | + this.label.isHovered = isHovered; | |
1902 | + this.label.updateStyle(); | |
1903 | + } | |
1904 | + } | |
1905 | +}; | |
1906 | + | |
1907 | +/** | |
1908 | + * Set selected state to the element. Styles will be updates respectively. | |
1909 | + * @param {Boolean} isSelected <code>true</code> to make element selected, <code>false</code> otherwise. | |
1910 | + */ | |
1911 | +jvm.MapObject.prototype.setSelected = function(isSelected){ | |
1912 | + if (this.isSelected !== isSelected) { | |
1913 | + this.isSelected = isSelected; | |
1914 | + this.shape.isSelected = isSelected; | |
1915 | + this.shape.updateStyle(); | |
1916 | + if (this.label) { | |
1917 | + this.label.isSelected = isSelected; | |
1918 | + this.label.updateStyle(); | |
1919 | + } | |
1920 | + jvm.$(this.shape).trigger('selected', [isSelected]); | |
1921 | + } | |
1922 | +}; | |
1923 | + | |
1924 | +jvm.MapObject.prototype.setStyle = function(){ | |
1925 | + this.shape.setStyle.apply(this.shape, arguments); | |
1926 | +}; | |
1927 | + | |
1928 | +jvm.MapObject.prototype.remove = function(){ | |
1929 | + this.shape.remove(); | |
1930 | + if (this.label) { | |
1931 | + this.label.remove(); | |
1932 | + } | |
1933 | +};jvm.Region = function(config){ | |
1934 | + var bbox, | |
1935 | + text, | |
1936 | + offsets, | |
1937 | + labelDx, | |
1938 | + labelDy; | |
1939 | + | |
1940 | + this.config = config; | |
1941 | + this.map = this.config.map; | |
1942 | + | |
1943 | + this.shape = config.canvas.addPath({ | |
1944 | + d: config.path, | |
1945 | + 'data-code': config.code | |
1946 | + }, config.style, config.canvas.rootElement); | |
1947 | + this.shape.addClass('jvectormap-region jvectormap-element'); | |
1948 | + | |
1949 | + bbox = this.shape.getBBox(); | |
1950 | + | |
1951 | + text = this.getLabelText(config.code); | |
1952 | + if (this.config.label && text) { | |
1953 | + offsets = this.getLabelOffsets(config.code); | |
1954 | + this.labelX = bbox.x + bbox.width / 2 + offsets[0]; | |
1955 | + this.labelY = bbox.y + bbox.height / 2 + offsets[1]; | |
1956 | + this.label = config.canvas.addText({ | |
1957 | + text: text, | |
1958 | + 'text-anchor': 'middle', | |
1959 | + 'alignment-baseline': 'central', | |
1960 | + x: this.labelX, | |
1961 | + y: this.labelY, | |
1962 | + 'data-code': config.code | |
1963 | + }, config.labelStyle, config.labelsGroup); | |
1964 | + this.label.addClass('jvectormap-region jvectormap-element'); | |
1965 | + } | |
1966 | +}; | |
1967 | + | |
1968 | +jvm.inherits(jvm.Region, jvm.MapObject); | |
1969 | + | |
1970 | +jvm.Region.prototype.updateLabelPosition = function(){ | |
1971 | + if (this.label) { | |
1972 | + this.label.set({ | |
1973 | + x: this.labelX * this.map.scale + this.map.transX * this.map.scale, | |
1974 | + y: this.labelY * this.map.scale + this.map.transY * this.map.scale | |
1975 | + }); | |
1976 | + } | |
1977 | +};jvm.Marker = function(config){ | |
1978 | + var text, | |
1979 | + offsets; | |
1980 | + | |
1981 | + this.config = config; | |
1982 | + this.map = this.config.map; | |
1983 | + | |
1984 | + this.isImage = !!this.config.style.initial.image; | |
1985 | + this.createShape(); | |
1986 | + | |
1987 | + text = this.getLabelText(config.index); | |
1988 | + if (this.config.label && text) { | |
1989 | + this.offsets = this.getLabelOffsets(config.index); | |
1990 | + this.labelX = config.cx / this.map.scale - this.map.transX; | |
1991 | + this.labelY = config.cy / this.map.scale - this.map.transY; | |
1992 | + this.label = config.canvas.addText({ | |
1993 | + text: text, | |
1994 | + 'data-index': config.index, | |
1995 | + dy: "0.6ex", | |
1996 | + x: this.labelX, | |
1997 | + y: this.labelY | |
1998 | + }, config.labelStyle, config.labelsGroup); | |
1999 | + | |
2000 | + this.label.addClass('jvectormap-marker jvectormap-element'); | |
2001 | + } | |
2002 | +}; | |
2003 | + | |
2004 | +jvm.inherits(jvm.Marker, jvm.MapObject); | |
2005 | + | |
2006 | +jvm.Marker.prototype.createShape = function(){ | |
2007 | + var that = this; | |
2008 | + | |
2009 | + if (this.shape) { | |
2010 | + this.shape.remove(); | |
2011 | + } | |
2012 | + this.shape = this.config.canvas[this.isImage ? 'addImage' : 'addCircle']({ | |
2013 | + "data-index": this.config.index, | |
2014 | + cx: this.config.cx, | |
2015 | + cy: this.config.cy | |
2016 | + }, this.config.style, this.config.group); | |
2017 | + | |
2018 | + this.shape.addClass('jvectormap-marker jvectormap-element'); | |
2019 | + | |
2020 | + if (this.isImage) { | |
2021 | + jvm.$(this.shape.node).on('imageloaded', function(){ | |
2022 | + that.updateLabelPosition(); | |
2023 | + }); | |
2024 | + } | |
2025 | +}; | |
2026 | + | |
2027 | +jvm.Marker.prototype.updateLabelPosition = function(){ | |
2028 | + if (this.label) { | |
2029 | + this.label.set({ | |
2030 | + x: this.labelX * this.map.scale + this.offsets[0] + | |
2031 | + this.map.transX * this.map.scale + 5 + (this.isImage ? (this.shape.width || 0) / 2 : this.shape.properties.r), | |
2032 | + y: this.labelY * this.map.scale + this.map.transY * this.map.scale + this.offsets[1] | |
2033 | + }); | |
2034 | + } | |
2035 | +}; | |
2036 | + | |
2037 | +jvm.Marker.prototype.setStyle = function(property, value){ | |
2038 | + var isImage; | |
2039 | + | |
2040 | + jvm.Marker.parentClass.prototype.setStyle.apply(this, arguments); | |
2041 | + | |
2042 | + if (property === 'r') { | |
2043 | + this.updateLabelPosition(); | |
2044 | + } | |
2045 | + | |
2046 | + isImage = !!this.shape.get('image'); | |
2047 | + if (isImage != this.isImage) { | |
2048 | + this.isImage = isImage; | |
2049 | + this.config.style = jvm.$.extend(true, {}, this.shape.style); | |
2050 | + this.createShape(); | |
2051 | + } | |
2052 | +};/** | |
2053 | + * Creates map, draws paths, binds events. | |
2054 | + * @constructor | |
2055 | + * @param {Object} params Parameters to initialize map with. | |
2056 | + * @param {String} params.map Name of the map in the format <code>territory_proj_lang</code> where <code>territory</code> is a unique code or name of the territory which the map represents (ISO 3166 standard is used where possible), <code>proj</code> is a name of projection used to generate representation of the map on the plane (projections are named according to the conventions of proj4 utility) and <code>lang</code> is a code of the language, used for the names of regions. | |
2057 | + * @param {String} params.backgroundColor Background color of the map in CSS format. | |
2058 | + * @param {Boolean} params.zoomOnScroll When set to true map could be zoomed using mouse scroll. Default value is <code>true</code>. | |
2059 | + * @param {Boolean} params.zoomOnScrollSpeed Mouse scroll speed. Number from 1 to 10. Default value is <code>3</code>. | |
2060 | + * @param {Boolean} params.panOnDrag When set to true, the map pans when being dragged. Default value is <code>true</code>. | |
2061 | + * @param {Number} params.zoomMax Indicates the maximum zoom ratio which could be reached zooming the map. Default value is <code>8</code>. | |
2062 | + * @param {Number} params.zoomMin Indicates the minimum zoom ratio which could be reached zooming the map. Default value is <code>1</code>. | |
2063 | + * @param {Number} params.zoomStep Indicates the multiplier used to zoom map with +/- buttons. Default value is <code>1.6</code>. | |
2064 | + * @param {Boolean} params.zoomAnimate Indicates whether or not to animate changing of map zoom with zoom buttons. | |
2065 | + * @param {Boolean} params.regionsSelectable When set to true regions of the map could be selected. Default value is <code>false</code>. | |
2066 | + * @param {Boolean} params.regionsSelectableOne Allow only one region to be selected at the moment. Default value is <code>false</code>. | |
2067 | + * @param {Boolean} params.markersSelectable When set to true markers on the map could be selected. Default value is <code>false</code>. | |
2068 | + * @param {Boolean} params.markersSelectableOne Allow only one marker to be selected at the moment. Default value is <code>false</code>. | |
2069 | + * @param {Object} params.regionStyle Set the styles for the map's regions. Each region or marker has four states: <code>initial</code> (default state), <code>hover</code> (when the mouse cursor is over the region or marker), <code>selected</code> (when region or marker is selected), <code>selectedHover</code> (when the mouse cursor is over the region or marker and it's selected simultaneously). Styles could be set for each of this states. Default value for that parameter is: | |
2070 | +<pre>{ | |
2071 | + initial: { | |
2072 | + fill: 'white', | |
2073 | + "fill-opacity": 1, | |
2074 | + stroke: 'none', | |
2075 | + "stroke-width": 0, | |
2076 | + "stroke-opacity": 1 | |
2077 | + }, | |
2078 | + hover: { | |
2079 | + "fill-opacity": 0.8, | |
2080 | + cursor: 'pointer' | |
2081 | + }, | |
2082 | + selected: { | |
2083 | + fill: 'yellow' | |
2084 | + }, | |
2085 | + selectedHover: { | |
2086 | + } | |
2087 | +}</pre> | |
2088 | +* @param {Object} params.regionLabelStyle Set the styles for the regions' labels. Each region or marker has four states: <code>initial</code> (default state), <code>hover</code> (when the mouse cursor is over the region or marker), <code>selected</code> (when region or marker is selected), <code>selectedHover</code> (when the mouse cursor is over the region or marker and it's selected simultaneously). Styles could be set for each of this states. Default value for that parameter is: | |
2089 | +<pre>{ | |
2090 | + initial: { | |
2091 | + 'font-family': 'Verdana', | |
2092 | + 'font-size': '12', | |
2093 | + 'font-weight': 'bold', | |
2094 | + cursor: 'default', | |
2095 | + fill: 'black' | |
2096 | + }, | |
2097 | + hover: { | |
2098 | + cursor: 'pointer' | |
2099 | + } | |
2100 | +}</pre> | |
2101 | + * @param {Object} params.markerStyle Set the styles for the map's markers. Any parameter suitable for <code>regionStyle</code> could be used as well as numeric parameter <code>r</code> to set the marker's radius. Default value for that parameter is: | |
2102 | +<pre>{ | |
2103 | + initial: { | |
2104 | + fill: 'grey', | |
2105 | + stroke: '#505050', | |
2106 | + "fill-opacity": 1, | |
2107 | + "stroke-width": 1, | |
2108 | + "stroke-opacity": 1, | |
2109 | + r: 5 | |
2110 | + }, | |
2111 | + hover: { | |
2112 | + stroke: 'black', | |
2113 | + "stroke-width": 2, | |
2114 | + cursor: 'pointer' | |
2115 | + }, | |
2116 | + selected: { | |
2117 | + fill: 'blue' | |
2118 | + }, | |
2119 | + selectedHover: { | |
2120 | + } | |
2121 | +}</pre> | |
2122 | + * @param {Object} params.markerLabelStyle Set the styles for the markers' labels. Default value for that parameter is: | |
2123 | +<pre>{ | |
2124 | + initial: { | |
2125 | + 'font-family': 'Verdana', | |
2126 | + 'font-size': '12', | |
2127 | + 'font-weight': 'bold', | |
2128 | + cursor: 'default', | |
2129 | + fill: 'black' | |
2130 | + }, | |
2131 | + hover: { | |
2132 | + cursor: 'pointer' | |
2133 | + } | |
2134 | +}</pre> | |
2135 | + * @param {Object|Array} params.markers Set of markers to add to the map during initialization. In case of array is provided, codes of markers will be set as string representations of array indexes. Each marker is represented by <code>latLng</code> (array of two numeric values), <code>name</code> (string which will be show on marker's tip) and any marker styles. | |
2136 | + * @param {Object} params.series Object with two keys: <code>markers</code> and <code>regions</code>. Each of which is an array of series configs to be applied to the respective map elements. See <a href="jvm.DataSeries.html">DataSeries</a> description for a list of parameters available. | |
2137 | + * @param {Object|String} params.focusOn This parameter sets the initial position and scale of the map viewport. See <code>setFocus</code> docuemntation for possible parameters. | |
2138 | + * @param {Object} params.labels Defines parameters for rendering static labels. Object could contain two keys: <code>regions</code> and <code>markers</code>. Each key value defines configuration object with the following possible options: | |
2139 | +<ul> | |
2140 | + <li><code>render {Function}</code> - defines method for converting region code or marker index to actual label value.</li> | |
2141 | + <li><code>offsets {Object|Function}</code> - provides method or object which could be used to define label offset by region code or marker index.</li> | |
2142 | +</ul> | |
2143 | +<b>Plase note: static labels feature is not supported in Internet Explorer 8 and below.</b> | |
2144 | + * @param {Array|Object|String} params.selectedRegions Set initially selected regions. | |
2145 | + * @param {Array|Object|String} params.selectedMarkers Set initially selected markers. | |
2146 | + * @param {Function} params.onRegionTipShow <code>(Event e, Object tip, String code)</code> Will be called right before the region tip is going to be shown. | |
2147 | + * @param {Function} params.onRegionOver <code>(Event e, String code)</code> Will be called on region mouse over event. | |
2148 | + * @param {Function} params.onRegionOut <code>(Event e, String code)</code> Will be called on region mouse out event. | |
2149 | + * @param {Function} params.onRegionClick <code>(Event e, String code)</code> Will be called on region click event. | |
2150 | + * @param {Function} params.onRegionSelected <code>(Event e, String code, Boolean isSelected, Array selectedRegions)</code> Will be called when region is (de)selected. <code>isSelected</code> parameter of the callback indicates whether region is selected or not. <code>selectedRegions</code> contains codes of all currently selected regions. | |
2151 | + * @param {Function} params.onMarkerTipShow <code>(Event e, Object tip, String code)</code> Will be called right before the marker tip is going to be shown. | |
2152 | + * @param {Function} params.onMarkerOver <code>(Event e, String code)</code> Will be called on marker mouse over event. | |
2153 | + * @param {Function} params.onMarkerOut <code>(Event e, String code)</code> Will be called on marker mouse out event. | |
2154 | + * @param {Function} params.onMarkerClick <code>(Event e, String code)</code> Will be called on marker click event. | |
2155 | + * @param {Function} params.onMarkerSelected <code>(Event e, String code, Boolean isSelected, Array selectedMarkers)</code> Will be called when marker is (de)selected. <code>isSelected</code> parameter of the callback indicates whether marker is selected or not. <code>selectedMarkers</code> contains codes of all currently selected markers. | |
2156 | + * @param {Function} params.onViewportChange <code>(Event e, Number scale)</code> Triggered when the map's viewport is changed (map was panned or zoomed). | |
2157 | + */ | |
2158 | +jvm.Map = function(params) { | |
2159 | + var map = this, | |
2160 | + e; | |
2161 | + | |
2162 | + this.params = jvm.$.extend(true, {}, jvm.Map.defaultParams, params); | |
2163 | + | |
2164 | + if (!jvm.Map.maps[this.params.map]) { | |
2165 | + throw new Error('Attempt to use map which was not loaded: '+this.params.map); | |
2166 | + } | |
2167 | + | |
2168 | + this.mapData = jvm.Map.maps[this.params.map]; | |
2169 | + this.markers = {}; | |
2170 | + this.regions = {}; | |
2171 | + this.regionsColors = {}; | |
2172 | + this.regionsData = {}; | |
2173 | + | |
2174 | + this.container = jvm.$('<div>').addClass('jvectormap-container'); | |
2175 | + if (this.params.container) { | |
2176 | + this.params.container.append( this.container ); | |
2177 | + } | |
2178 | + this.container.data('mapObject', this); | |
2179 | + | |
2180 | + this.defaultWidth = this.mapData.width; | |
2181 | + this.defaultHeight = this.mapData.height; | |
2182 | + | |
2183 | + this.setBackgroundColor(this.params.backgroundColor); | |
2184 | + | |
2185 | + this.onResize = function(){ | |
2186 | + map.updateSize(); | |
2187 | + } | |
2188 | + jvm.$(window).resize(this.onResize); | |
2189 | + | |
2190 | + for (e in jvm.Map.apiEvents) { | |
2191 | + if (this.params[e]) { | |
2192 | + this.container.bind(jvm.Map.apiEvents[e]+'.jvectormap', this.params[e]); | |
2193 | + } | |
2194 | + } | |
2195 | + | |
2196 | + this.canvas = new jvm.VectorCanvas(this.container[0], this.width, this.height); | |
2197 | + | |
2198 | + if (this.params.bindTouchEvents) { | |
2199 | + if (('ontouchstart' in window) || (window.DocumentTouch && document instanceof DocumentTouch)) { | |
2200 | + this.bindContainerTouchEvents(); | |
2201 | + } else if (window.MSGesture) { | |
2202 | + this.bindContainerPointerEvents(); | |
2203 | + } | |
2204 | + } | |
2205 | + this.bindContainerEvents(); | |
2206 | + this.bindElementEvents(); | |
2207 | + this.createTip(); | |
2208 | + if (this.params.zoomButtons) { | |
2209 | + this.bindZoomButtons(); | |
2210 | + } | |
2211 | + | |
2212 | + this.createRegions(); | |
2213 | + this.createMarkers(this.params.markers || {}); | |
2214 | + | |
2215 | + this.updateSize(); | |
2216 | + | |
2217 | + if (this.params.focusOn) { | |
2218 | + if (typeof this.params.focusOn === 'string') { | |
2219 | + this.params.focusOn = {region: this.params.focusOn}; | |
2220 | + } else if (jvm.$.isArray(this.params.focusOn)) { | |
2221 | + this.params.focusOn = {regions: this.params.focusOn}; | |
2222 | + } | |
2223 | + this.setFocus(this.params.focusOn); | |
2224 | + } | |
2225 | + | |
2226 | + if (this.params.selectedRegions) { | |
2227 | + this.setSelectedRegions(this.params.selectedRegions); | |
2228 | + } | |
2229 | + if (this.params.selectedMarkers) { | |
2230 | + this.setSelectedMarkers(this.params.selectedMarkers); | |
2231 | + } | |
2232 | + | |
2233 | + this.legendCntHorizontal = jvm.$('<div/>').addClass('jvectormap-legend-cnt jvectormap-legend-cnt-h'); | |
2234 | + this.legendCntVertical = jvm.$('<div/>').addClass('jvectormap-legend-cnt jvectormap-legend-cnt-v'); | |
2235 | + this.container.append(this.legendCntHorizontal); | |
2236 | + this.container.append(this.legendCntVertical); | |
2237 | + | |
2238 | + if (this.params.series) { | |
2239 | + this.createSeries(); | |
2240 | + } | |
2241 | +}; | |
2242 | + | |
2243 | +jvm.Map.prototype = { | |
2244 | + transX: 0, | |
2245 | + transY: 0, | |
2246 | + scale: 1, | |
2247 | + baseTransX: 0, | |
2248 | + baseTransY: 0, | |
2249 | + baseScale: 1, | |
2250 | + | |
2251 | + width: 0, | |
2252 | + height: 0, | |
2253 | + | |
2254 | + /** | |
2255 | + * Set background color of the map. | |
2256 | + * @param {String} backgroundColor Background color in CSS format. | |
2257 | + */ | |
2258 | + setBackgroundColor: function(backgroundColor) { | |
2259 | + this.container.css('background-color', backgroundColor); | |
2260 | + }, | |
2261 | + | |
2262 | + resize: function() { | |
2263 | + var curBaseScale = this.baseScale; | |
2264 | + if (this.width / this.height > this.defaultWidth / this.defaultHeight) { | |
2265 | + this.baseScale = this.height / this.defaultHeight; | |
2266 | + this.baseTransX = Math.abs(this.width - this.defaultWidth * this.baseScale) / (2 * this.baseScale); | |
2267 | + } else { | |
2268 | + this.baseScale = this.width / this.defaultWidth; | |
2269 | + this.baseTransY = Math.abs(this.height - this.defaultHeight * this.baseScale) / (2 * this.baseScale); | |
2270 | + } | |
2271 | + this.scale *= this.baseScale / curBaseScale; | |
2272 | + this.transX *= this.baseScale / curBaseScale; | |
2273 | + this.transY *= this.baseScale / curBaseScale; | |
2274 | + }, | |
2275 | + | |
2276 | + /** | |
2277 | + * Synchronize the size of the map with the size of the container. Suitable in situations where the size of the container is changed programmatically or container is shown after it became visible. | |
2278 | + */ | |
2279 | + updateSize: function(){ | |
2280 | + this.width = this.container.width(); | |
2281 | + this.height = this.container.height(); | |
2282 | + this.resize(); | |
2283 | + this.canvas.setSize(this.width, this.height); | |
2284 | + this.applyTransform(); | |
2285 | + }, | |
2286 | + | |
2287 | + /** | |
2288 | + * Reset all the series and show the map with the initial zoom. | |
2289 | + */ | |
2290 | + reset: function() { | |
2291 | + var key, | |
2292 | + i; | |
2293 | + | |
2294 | + for (key in this.series) { | |
2295 | + for (i = 0; i < this.series[key].length; i++) { | |
2296 | + this.series[key][i].clear(); | |
2297 | + } | |
2298 | + } | |
2299 | + this.scale = this.baseScale; | |
2300 | + this.transX = this.baseTransX; | |
2301 | + this.transY = this.baseTransY; | |
2302 | + this.applyTransform(); | |
2303 | + }, | |
2304 | + | |
2305 | + applyTransform: function() { | |
2306 | + var maxTransX, | |
2307 | + maxTransY, | |
2308 | + minTransX, | |
2309 | + minTransY; | |
2310 | + | |
2311 | + if (this.defaultWidth * this.scale <= this.width) { | |
2312 | + maxTransX = (this.width - this.defaultWidth * this.scale) / (2 * this.scale); | |
2313 | + minTransX = (this.width - this.defaultWidth * this.scale) / (2 * this.scale); | |
2314 | + } else { | |
2315 | + maxTransX = 0; | |
2316 | + minTransX = (this.width - this.defaultWidth * this.scale) / this.scale; | |
2317 | + } | |
2318 | + | |
2319 | + if (this.defaultHeight * this.scale <= this.height) { | |
2320 | + maxTransY = (this.height - this.defaultHeight * this.scale) / (2 * this.scale); | |
2321 | + minTransY = (this.height - this.defaultHeight * this.scale) / (2 * this.scale); | |
2322 | + } else { | |
2323 | + maxTransY = 0; | |
2324 | + minTransY = (this.height - this.defaultHeight * this.scale) / this.scale; | |
2325 | + } | |
2326 | + | |
2327 | + if (this.transY > maxTransY) { | |
2328 | + this.transY = maxTransY; | |
2329 | + } else if (this.transY < minTransY) { | |
2330 | + this.transY = minTransY; | |
2331 | + } | |
2332 | + if (this.transX > maxTransX) { | |
2333 | + this.transX = maxTransX; | |
2334 | + } else if (this.transX < minTransX) { | |
2335 | + this.transX = minTransX; | |
2336 | + } | |
2337 | + | |
2338 | + this.canvas.applyTransformParams(this.scale, this.transX, this.transY); | |
2339 | + | |
2340 | + if (this.markers) { | |
2341 | + this.repositionMarkers(); | |
2342 | + } | |
2343 | + | |
2344 | + this.repositionLabels(); | |
2345 | + | |
2346 | + this.container.trigger('viewportChange', [this.scale/this.baseScale, this.transX, this.transY]); | |
2347 | + }, | |
2348 | + | |
2349 | + bindContainerEvents: function(){ | |
2350 | + var mouseDown = false, | |
2351 | + oldPageX, | |
2352 | + oldPageY, | |
2353 | + map = this; | |
2354 | + | |
2355 | + if (this.params.panOnDrag) { | |
2356 | + this.container.mousemove(function(e){ | |
2357 | + if (mouseDown) { | |
2358 | + map.transX -= (oldPageX - e.pageX) / map.scale; | |
2359 | + map.transY -= (oldPageY - e.pageY) / map.scale; | |
2360 | + | |
2361 | + map.applyTransform(); | |
2362 | + | |
2363 | + oldPageX = e.pageX; | |
2364 | + oldPageY = e.pageY; | |
2365 | + } | |
2366 | + return false; | |
2367 | + }).mousedown(function(e){ | |
2368 | + mouseDown = true; | |
2369 | + oldPageX = e.pageX; | |
2370 | + oldPageY = e.pageY; | |
2371 | + return false; | |
2372 | + }); | |
2373 | + | |
2374 | + this.onContainerMouseUp = function(){ | |
2375 | + mouseDown = false; | |
2376 | + }; | |
2377 | + jvm.$('body').mouseup(this.onContainerMouseUp); | |
2378 | + } | |
2379 | + | |
2380 | + if (this.params.zoomOnScroll) { | |
2381 | + this.container.mousewheel(function(event, delta, deltaX, deltaY) { | |
2382 | + var offset = jvm.$(map.container).offset(), | |
2383 | + centerX = event.pageX - offset.left, | |
2384 | + centerY = event.pageY - offset.top, | |
2385 | + zoomStep = Math.pow(1 + map.params.zoomOnScrollSpeed / 1000, event.deltaFactor * event.deltaY); | |
2386 | + | |
2387 | + map.tip.hide(); | |
2388 | + | |
2389 | + map.setScale(map.scale * zoomStep, centerX, centerY); | |
2390 | + event.preventDefault(); | |
2391 | + }); | |
2392 | + } | |
2393 | + }, | |
2394 | + | |
2395 | + bindContainerTouchEvents: function(){ | |
2396 | + var touchStartScale, | |
2397 | + touchStartDistance, | |
2398 | + map = this, | |
2399 | + touchX, | |
2400 | + touchY, | |
2401 | + centerTouchX, | |
2402 | + centerTouchY, | |
2403 | + lastTouchesLength, | |
2404 | + handleTouchEvent = function(e){ | |
2405 | + var touches = e.originalEvent.touches, | |
2406 | + offset, | |
2407 | + scale, | |
2408 | + transXOld, | |
2409 | + transYOld; | |
2410 | + | |
2411 | + if (e.type == 'touchstart') { | |
2412 | + lastTouchesLength = 0; | |
2413 | + } | |
2414 | + | |
2415 | + if (touches.length == 1) { | |
2416 | + if (lastTouchesLength == 1) { | |
2417 | + transXOld = map.transX; | |
2418 | + transYOld = map.transY; | |
2419 | + map.transX -= (touchX - touches[0].pageX) / map.scale; | |
2420 | + map.transY -= (touchY - touches[0].pageY) / map.scale; | |
2421 | + map.applyTransform(); | |
2422 | + map.tip.hide(); | |
2423 | + if (transXOld != map.transX || transYOld != map.transY) { | |
2424 | + e.preventDefault(); | |
2425 | + } | |
2426 | + } | |
2427 | + touchX = touches[0].pageX; | |
2428 | + touchY = touches[0].pageY; | |
2429 | + } else if (touches.length == 2) { | |
2430 | + if (lastTouchesLength == 2) { | |
2431 | + scale = Math.sqrt( | |
2432 | + Math.pow(touches[0].pageX - touches[1].pageX, 2) + | |
2433 | + Math.pow(touches[0].pageY - touches[1].pageY, 2) | |
2434 | + ) / touchStartDistance; | |
2435 | + map.setScale( | |
2436 | + touchStartScale * scale, | |
2437 | + centerTouchX, | |
2438 | + centerTouchY | |
2439 | + ) | |
2440 | + map.tip.hide(); | |
2441 | + e.preventDefault(); | |
2442 | + } else { | |
2443 | + offset = jvm.$(map.container).offset(); | |
2444 | + if (touches[0].pageX > touches[1].pageX) { | |
2445 | + centerTouchX = touches[1].pageX + (touches[0].pageX - touches[1].pageX) / 2; | |
2446 | + } else { | |
2447 | + centerTouchX = touches[0].pageX + (touches[1].pageX - touches[0].pageX) / 2; | |
2448 | + } | |
2449 | + if (touches[0].pageY > touches[1].pageY) { | |
2450 | + centerTouchY = touches[1].pageY + (touches[0].pageY - touches[1].pageY) / 2; | |
2451 | + } else { | |
2452 | + centerTouchY = touches[0].pageY + (touches[1].pageY - touches[0].pageY) / 2; | |
2453 | + } | |
2454 | + centerTouchX -= offset.left; | |
2455 | + centerTouchY -= offset.top; | |
2456 | + touchStartScale = map.scale; | |
2457 | + touchStartDistance = Math.sqrt( | |
2458 | + Math.pow(touches[0].pageX - touches[1].pageX, 2) + | |
2459 | + Math.pow(touches[0].pageY - touches[1].pageY, 2) | |
2460 | + ); | |
2461 | + } | |
2462 | + } | |
2463 | + | |
2464 | + lastTouchesLength = touches.length; | |
2465 | + }; | |
2466 | + | |
2467 | + jvm.$(this.container).bind('touchstart', handleTouchEvent); | |
2468 | + jvm.$(this.container).bind('touchmove', handleTouchEvent); | |
2469 | + }, | |
2470 | + | |
2471 | + bindContainerPointerEvents: function(){ | |
2472 | + var map = this, | |
2473 | + gesture = new MSGesture(), | |
2474 | + element = this.container[0], | |
2475 | + handlePointerDownEvent = function(e){ | |
2476 | + gesture.addPointer(e.pointerId); | |
2477 | + }, | |
2478 | + handleGestureEvent = function(e){ | |
2479 | + var offset, | |
2480 | + scale, | |
2481 | + transXOld, | |
2482 | + transYOld; | |
2483 | + | |
2484 | + if (e.translationX != 0 || e.translationY != 0) { | |
2485 | + transXOld = map.transX; | |
2486 | + transYOld = map.transY; | |
2487 | + map.transX += e.translationX / map.scale; | |
2488 | + map.transY += e.translationY / map.scale; | |
2489 | + map.applyTransform(); | |
2490 | + map.tip.hide(); | |
2491 | + if (transXOld != map.transX || transYOld != map.transY) { | |
2492 | + e.preventDefault(); | |
2493 | + } | |
2494 | + } | |
2495 | + if (e.scale != 1) { | |
2496 | + map.setScale( | |
2497 | + map.scale * e.scale, | |
2498 | + e.offsetX, | |
2499 | + e.offsetY | |
2500 | + ) | |
2501 | + map.tip.hide(); | |
2502 | + e.preventDefault(); | |
2503 | + } | |
2504 | + }; | |
2505 | + | |
2506 | + gesture.target = element; | |
2507 | + element.addEventListener("MSGestureChange", handleGestureEvent, false); | |
2508 | + element.addEventListener("pointerdown", handlePointerDownEvent, false); | |
2509 | + }, | |
2510 | + | |
2511 | + bindElementEvents: function(){ | |
2512 | + var map = this, | |
2513 | + pageX, | |
2514 | + pageY, | |
2515 | + mouseMoved; | |
2516 | + | |
2517 | + this.container.mousemove(function(e){ | |
2518 | + if (Math.abs(pageX - e.pageX) + Math.abs(pageY - e.pageY) > 2) { | |
2519 | + mouseMoved = true; | |
2520 | + } | |
2521 | + }); | |
2522 | + | |
2523 | + /* Can not use common class selectors here because of the bug in jQuery | |
2524 | + SVG handling, use with caution. */ | |
2525 | + this.container.delegate("[class~='jvectormap-element']", 'mouseover mouseout', function(e){ | |
2526 | + var baseVal = jvm.$(this).attr('class').baseVal || jvm.$(this).attr('class'), | |
2527 | + type = baseVal.indexOf('jvectormap-region') === -1 ? 'marker' : 'region', | |
2528 | + code = type == 'region' ? jvm.$(this).attr('data-code') : jvm.$(this).attr('data-index'), | |
2529 | + element = type == 'region' ? map.regions[code].element : map.markers[code].element, | |
2530 | + tipText = type == 'region' ? map.mapData.paths[code].name : (map.markers[code].config.name || ''), | |
2531 | + tipShowEvent = jvm.$.Event(type+'TipShow.jvectormap'), | |
2532 | + overEvent = jvm.$.Event(type+'Over.jvectormap'); | |
2533 | + | |
2534 | + if (e.type == 'mouseover') { | |
2535 | + map.container.trigger(overEvent, [code]); | |
2536 | + if (!overEvent.isDefaultPrevented()) { | |
2537 | + element.setHovered(true); | |
2538 | + } | |
2539 | + | |
2540 | + map.tip.text(tipText); | |
2541 | + map.container.trigger(tipShowEvent, [map.tip, code]); | |
2542 | + if (!tipShowEvent.isDefaultPrevented()) { | |
2543 | + map.tip.show(); | |
2544 | + map.tipWidth = map.tip.width(); | |
2545 | + map.tipHeight = map.tip.height(); | |
2546 | + } | |
2547 | + } else { | |
2548 | + element.setHovered(false); | |
2549 | + map.tip.hide(); | |
2550 | + map.container.trigger(type+'Out.jvectormap', [code]); | |
2551 | + } | |
2552 | + }); | |
2553 | + | |
2554 | + /* Can not use common class selectors here because of the bug in jQuery | |
2555 | + SVG handling, use with caution. */ | |
2556 | + this.container.delegate("[class~='jvectormap-element']", 'mousedown', function(e){ | |
2557 | + pageX = e.pageX; | |
2558 | + pageY = e.pageY; | |
2559 | + mouseMoved = false; | |
2560 | + }); | |
2561 | + | |
2562 | + /* Can not use common class selectors here because of the bug in jQuery | |
2563 | + SVG handling, use with caution. */ | |
2564 | + this.container.delegate("[class~='jvectormap-element']", 'mouseup', function(){ | |
2565 | + var baseVal = jvm.$(this).attr('class').baseVal ? jvm.$(this).attr('class').baseVal : jvm.$(this).attr('class'), | |
2566 | + type = baseVal.indexOf('jvectormap-region') === -1 ? 'marker' : 'region', | |
2567 | + code = type == 'region' ? jvm.$(this).attr('data-code') : jvm.$(this).attr('data-index'), | |
2568 | + clickEvent = jvm.$.Event(type+'Click.jvectormap'), | |
2569 | + element = type == 'region' ? map.regions[code].element : map.markers[code].element; | |
2570 | + | |
2571 | + if (!mouseMoved) { | |
2572 | + map.container.trigger(clickEvent, [code]); | |
2573 | + if ((type === 'region' && map.params.regionsSelectable) || (type === 'marker' && map.params.markersSelectable)) { | |
2574 | + if (!clickEvent.isDefaultPrevented()) { | |
2575 | + if (map.params[type+'sSelectableOne']) { | |
2576 | + map.clearSelected(type+'s'); | |
2577 | + } | |
2578 | + element.setSelected(!element.isSelected); | |
2579 | + } | |
2580 | + } | |
2581 | + } | |
2582 | + }); | |
2583 | + }, | |
2584 | + | |
2585 | + bindZoomButtons: function() { | |
2586 | + var map = this; | |
2587 | + | |
2588 | + jvm.$('<div/>').addClass('jvectormap-zoomin').text('+').appendTo(this.container); | |
2589 | + jvm.$('<div/>').addClass('jvectormap-zoomout').html('−').appendTo(this.container); | |
2590 | + | |
2591 | + this.container.find('.jvectormap-zoomin').click(function(){ | |
2592 | + map.setScale(map.scale * map.params.zoomStep, map.width / 2, map.height / 2, false, map.params.zoomAnimate); | |
2593 | + }); | |
2594 | + this.container.find('.jvectormap-zoomout').click(function(){ | |
2595 | + map.setScale(map.scale / map.params.zoomStep, map.width / 2, map.height / 2, false, map.params.zoomAnimate); | |
2596 | + }); | |
2597 | + }, | |
2598 | + | |
2599 | + createTip: function(){ | |
2600 | + var map = this; | |
2601 | + | |
2602 | + this.tip = jvm.$('<div/>').addClass('jvectormap-tip').appendTo(jvm.$('body')); | |
2603 | + | |
2604 | + this.container.mousemove(function(e){ | |
2605 | + var left = e.pageX-15-map.tipWidth, | |
2606 | + top = e.pageY-15-map.tipHeight; | |
2607 | + | |
2608 | + if (left < 5) { | |
2609 | + left = e.pageX + 15; | |
2610 | + } | |
2611 | + if (top < 5) { | |
2612 | + top = e.pageY + 15; | |
2613 | + } | |
2614 | + | |
2615 | + map.tip.css({ | |
2616 | + left: left, | |
2617 | + top: top | |
2618 | + }); | |
2619 | + }); | |
2620 | + }, | |
2621 | + | |
2622 | + setScale: function(scale, anchorX, anchorY, isCentered, animate) { | |
2623 | + var viewportChangeEvent = jvm.$.Event('zoom.jvectormap'), | |
2624 | + interval, | |
2625 | + that = this, | |
2626 | + i = 0, | |
2627 | + count = Math.abs(Math.round((scale - this.scale) * 60 / Math.max(scale, this.scale))), | |
2628 | + scaleStart, | |
2629 | + scaleDiff, | |
2630 | + transXStart, | |
2631 | + transXDiff, | |
2632 | + transYStart, | |
2633 | + transYDiff, | |
2634 | + transX, | |
2635 | + transY, | |
2636 | + deferred = new jvm.$.Deferred(); | |
2637 | + | |
2638 | + if (scale > this.params.zoomMax * this.baseScale) { | |
2639 | + scale = this.params.zoomMax * this.baseScale; | |
2640 | + } else if (scale < this.params.zoomMin * this.baseScale) { | |
2641 | + scale = this.params.zoomMin * this.baseScale; | |
2642 | + } | |
2643 | + | |
2644 | + if (typeof anchorX != 'undefined' && typeof anchorY != 'undefined') { | |
2645 | + zoomStep = scale / this.scale; | |
2646 | + if (isCentered) { | |
2647 | + transX = anchorX + this.defaultWidth * (this.width / (this.defaultWidth * scale)) / 2; | |
2648 | + transY = anchorY + this.defaultHeight * (this.height / (this.defaultHeight * scale)) / 2; | |
2649 | + } else { | |
2650 | + transX = this.transX - (zoomStep - 1) / scale * anchorX; | |
2651 | + transY = this.transY - (zoomStep - 1) / scale * anchorY; | |
2652 | + } | |
2653 | + } | |
2654 | + | |
2655 | + if (animate && count > 0) { | |
2656 | + scaleStart = this.scale; | |
2657 | + scaleDiff = (scale - scaleStart) / count; | |
2658 | + transXStart = this.transX * this.scale; | |
2659 | + transYStart = this.transY * this.scale; | |
2660 | + transXDiff = (transX * scale - transXStart) / count; | |
2661 | + transYDiff = (transY * scale - transYStart) / count; | |
2662 | + interval = setInterval(function(){ | |
2663 | + i += 1; | |
2664 | + that.scale = scaleStart + scaleDiff * i; | |
2665 | + that.transX = (transXStart + transXDiff * i) / that.scale; | |
2666 | + that.transY = (transYStart + transYDiff * i) / that.scale; | |
2667 | + that.applyTransform(); | |
2668 | + if (i == count) { | |
2669 | + clearInterval(interval); | |
2670 | + that.container.trigger(viewportChangeEvent, [scale/that.baseScale]); | |
2671 | + deferred.resolve(); | |
2672 | + } | |
2673 | + }, 10); | |
2674 | + } else { | |
2675 | + this.transX = transX; | |
2676 | + this.transY = transY; | |
2677 | + this.scale = scale; | |
2678 | + this.applyTransform(); | |
2679 | + this.container.trigger(viewportChangeEvent, [scale/this.baseScale]); | |
2680 | + deferred.resolve(); | |
2681 | + } | |
2682 | + | |
2683 | + return deferred; | |
2684 | + }, | |
2685 | + | |
2686 | + /** | |
2687 | + * Set the map's viewport to the specific point and set zoom of the map to the specific level. Point and zoom level could be defined in two ways: using the code of some region to focus on or a central point and zoom level as numbers. | |
2688 | + * @param This method takes a configuration object as the single argument. The options passed to it are the following: | |
2689 | + * @param {Array} params.regions Array of region codes to zoom to. | |
2690 | + * @param {String} params.region Region code to zoom to. | |
2691 | + * @param {Number} params.scale Map scale to set. | |
2692 | + * @param {Number} params.lat Latitude to set viewport to. | |
2693 | + * @param {Number} params.lng Longitude to set viewport to. | |
2694 | + * @param {Number} params.x Number from 0 to 1 specifying the horizontal coordinate of the central point of the viewport. | |
2695 | + * @param {Number} params.y Number from 0 to 1 specifying the vertical coordinate of the central point of the viewport. | |
2696 | + * @param {Boolean} params.animate Indicates whether or not to animate the scale change and transition. | |
2697 | + */ | |
2698 | + setFocus: function(config){ | |
2699 | + var bbox, | |
2700 | + itemBbox, | |
2701 | + newBbox, | |
2702 | + codes, | |
2703 | + i, | |
2704 | + point; | |
2705 | + | |
2706 | + config = config || {}; | |
2707 | + | |
2708 | + if (config.region) { | |
2709 | + codes = [config.region]; | |
2710 | + } else if (config.regions) { | |
2711 | + codes = config.regions; | |
2712 | + } | |
2713 | + | |
2714 | + if (codes) { | |
2715 | + for (i = 0; i < codes.length; i++) { | |
2716 | + if (this.regions[codes[i]]) { | |
2717 | + itemBbox = this.regions[codes[i]].element.shape.getBBox(); | |
2718 | + if (itemBbox) { | |
2719 | + if (typeof bbox == 'undefined') { | |
2720 | + bbox = itemBbox; | |
2721 | + } else { | |
2722 | + newBbox = { | |
2723 | + x: Math.min(bbox.x, itemBbox.x), | |
2724 | + y: Math.min(bbox.y, itemBbox.y), | |
2725 | + width: Math.max(bbox.x + bbox.width, itemBbox.x + itemBbox.width) - Math.min(bbox.x, itemBbox.x), | |
2726 | + height: Math.max(bbox.y + bbox.height, itemBbox.y + itemBbox.height) - Math.min(bbox.y, itemBbox.y) | |
2727 | + } | |
2728 | + bbox = newBbox; | |
2729 | + } | |
2730 | + } | |
2731 | + } | |
2732 | + } | |
2733 | + return this.setScale( | |
2734 | + Math.min(this.width / bbox.width, this.height / bbox.height), | |
2735 | + - (bbox.x + bbox.width / 2), | |
2736 | + - (bbox.y + bbox.height / 2), | |
2737 | + true, | |
2738 | + config.animate | |
2739 | + ); | |
2740 | + } else { | |
2741 | + if (config.lat && config.lng) { | |
2742 | + point = this.latLngToPoint(config.lat, config.lng); | |
2743 | + config.x = this.transX - point.x / this.scale; | |
2744 | + config.y = this.transY - point.y / this.scale; | |
2745 | + } else if (config.x && config.y) { | |
2746 | + config.x *= -this.defaultWidth; | |
2747 | + config.y *= -this.defaultHeight; | |
2748 | + } | |
2749 | + return this.setScale(config.scale * this.baseScale, config.x, config.y, true, config.animate); | |
2750 | + } | |
2751 | + }, | |
2752 | + | |
2753 | + getSelected: function(type){ | |
2754 | + var key, | |
2755 | + selected = []; | |
2756 | + | |
2757 | + for (key in this[type]) { | |
2758 | + if (this[type][key].element.isSelected) { | |
2759 | + selected.push(key); | |
2760 | + } | |
2761 | + } | |
2762 | + return selected; | |
2763 | + }, | |
2764 | + | |
2765 | + /** | |
2766 | + * Return the codes of currently selected regions. | |
2767 | + * @returns {Array} | |
2768 | + */ | |
2769 | + getSelectedRegions: function(){ | |
2770 | + return this.getSelected('regions'); | |
2771 | + }, | |
2772 | + | |
2773 | + /** | |
2774 | + * Return the codes of currently selected markers. | |
2775 | + * @returns {Array} | |
2776 | + */ | |
2777 | + getSelectedMarkers: function(){ | |
2778 | + return this.getSelected('markers'); | |
2779 | + }, | |
2780 | + | |
2781 | + setSelected: function(type, keys){ | |
2782 | + var i; | |
2783 | + | |
2784 | + if (typeof keys != 'object') { | |
2785 | + keys = [keys]; | |
2786 | + } | |
2787 | + | |
2788 | + if (jvm.$.isArray(keys)) { | |
2789 | + for (i = 0; i < keys.length; i++) { | |
2790 | + this[type][keys[i]].element.setSelected(true); | |
2791 | + } | |
2792 | + } else { | |
2793 | + for (i in keys) { | |
2794 | + this[type][i].element.setSelected(!!keys[i]); | |
2795 | + } | |
2796 | + } | |
2797 | + }, | |
2798 | + | |
2799 | + /** | |
2800 | + * Set or remove selected state for the regions. | |
2801 | + * @param {String|Array|Object} keys If <code>String</code> or <code>Array</code> the region(s) with the corresponding code(s) will be selected. If <code>Object</code> was provided its keys are codes of regions, state of which should be changed. Selected state will be set if value is true, removed otherwise. | |
2802 | + */ | |
2803 | + setSelectedRegions: function(keys){ | |
2804 | + this.setSelected('regions', keys); | |
2805 | + }, | |
2806 | + | |
2807 | + /** | |
2808 | + * Set or remove selected state for the markers. | |
2809 | + * @param {String|Array|Object} keys If <code>String</code> or <code>Array</code> the marker(s) with the corresponding code(s) will be selected. If <code>Object</code> was provided its keys are codes of markers, state of which should be changed. Selected state will be set if value is true, removed otherwise. | |
2810 | + */ | |
2811 | + setSelectedMarkers: function(keys){ | |
2812 | + this.setSelected('markers', keys); | |
2813 | + }, | |
2814 | + | |
2815 | + clearSelected: function(type){ | |
2816 | + var select = {}, | |
2817 | + selected = this.getSelected(type), | |
2818 | + i; | |
2819 | + | |
2820 | + for (i = 0; i < selected.length; i++) { | |
2821 | + select[selected[i]] = false; | |
2822 | + }; | |
2823 | + | |
2824 | + this.setSelected(type, select); | |
2825 | + }, | |
2826 | + | |
2827 | + /** | |
2828 | + * Remove the selected state from all the currently selected regions. | |
2829 | + */ | |
2830 | + clearSelectedRegions: function(){ | |
2831 | + this.clearSelected('regions'); | |
2832 | + }, | |
2833 | + | |
2834 | + /** | |
2835 | + * Remove the selected state from all the currently selected markers. | |
2836 | + */ | |
2837 | + clearSelectedMarkers: function(){ | |
2838 | + this.clearSelected('markers'); | |
2839 | + }, | |
2840 | + | |
2841 | + /** | |
2842 | + * Return the instance of Map. Useful when instantiated as a jQuery plug-in. | |
2843 | + * @returns {Map} | |
2844 | + */ | |
2845 | + getMapObject: function(){ | |
2846 | + return this; | |
2847 | + }, | |
2848 | + | |
2849 | + /** | |
2850 | + * Return the name of the region by region code. | |
2851 | + * @returns {String} | |
2852 | + */ | |
2853 | + getRegionName: function(code){ | |
2854 | + return this.mapData.paths[code].name; | |
2855 | + }, | |
2856 | + | |
2857 | + createRegions: function(){ | |
2858 | + var key, | |
2859 | + region, | |
2860 | + map = this; | |
2861 | + | |
2862 | + this.regionLabelsGroup = this.regionLabelsGroup || this.canvas.addGroup(); | |
2863 | + | |
2864 | + for (key in this.mapData.paths) { | |
2865 | + region = new jvm.Region({ | |
2866 | + map: this, | |
2867 | + path: this.mapData.paths[key].path, | |
2868 | + code: key, | |
2869 | + style: jvm.$.extend(true, {}, this.params.regionStyle), | |
2870 | + labelStyle: jvm.$.extend(true, {}, this.params.regionLabelStyle), | |
2871 | + canvas: this.canvas, | |
2872 | + labelsGroup: this.regionLabelsGroup, | |
2873 | + label: this.canvas.mode != 'vml' ? (this.params.labels && this.params.labels.regions) : null | |
2874 | + }); | |
2875 | + | |
2876 | + jvm.$(region.shape).bind('selected', function(e, isSelected){ | |
2877 | + map.container.trigger('regionSelected.jvectormap', [jvm.$(this.node).attr('data-code'), isSelected, map.getSelectedRegions()]); | |
2878 | + }); | |
2879 | + this.regions[key] = { | |
2880 | + element: region, | |
2881 | + config: this.mapData.paths[key] | |
2882 | + }; | |
2883 | + } | |
2884 | + }, | |
2885 | + | |
2886 | + createMarkers: function(markers) { | |
2887 | + var i, | |
2888 | + marker, | |
2889 | + point, | |
2890 | + markerConfig, | |
2891 | + markersArray, | |
2892 | + map = this; | |
2893 | + | |
2894 | + this.markersGroup = this.markersGroup || this.canvas.addGroup(); | |
2895 | + this.markerLabelsGroup = this.markerLabelsGroup || this.canvas.addGroup(); | |
2896 | + | |
2897 | + if (jvm.$.isArray(markers)) { | |
2898 | + markersArray = markers.slice(); | |
2899 | + markers = {}; | |
2900 | + for (i = 0; i < markersArray.length; i++) { | |
2901 | + markers[i] = markersArray[i]; | |
2902 | + } | |
2903 | + } | |
2904 | + | |
2905 | + for (i in markers) { | |
2906 | + markerConfig = markers[i] instanceof Array ? {latLng: markers[i]} : markers[i]; | |
2907 | + point = this.getMarkerPosition( markerConfig ); | |
2908 | + | |
2909 | + if (point !== false) { | |
2910 | + marker = new jvm.Marker({ | |
2911 | + map: this, | |
2912 | + style: jvm.$.extend(true, {}, this.params.markerStyle, {initial: markerConfig.style || {}}), | |
2913 | + labelStyle: jvm.$.extend(true, {}, this.params.markerLabelStyle), | |
2914 | + index: i, | |
2915 | + cx: point.x, | |
2916 | + cy: point.y, | |
2917 | + group: this.markersGroup, | |
2918 | + canvas: this.canvas, | |
2919 | + labelsGroup: this.markerLabelsGroup, | |
2920 | + label: this.canvas.mode != 'vml' ? (this.params.labels && this.params.labels.markers) : null | |
2921 | + }); | |
2922 | + | |
2923 | + jvm.$(marker.shape).bind('selected', function(e, isSelected){ | |
2924 | + map.container.trigger('markerSelected.jvectormap', [jvm.$(this.node).attr('data-index'), isSelected, map.getSelectedMarkers()]); | |
2925 | + }); | |
2926 | + if (this.markers[i]) { | |
2927 | + this.removeMarkers([i]); | |
2928 | + } | |
2929 | + this.markers[i] = {element: marker, config: markerConfig}; | |
2930 | + } | |
2931 | + } | |
2932 | + }, | |
2933 | + | |
2934 | + repositionMarkers: function() { | |
2935 | + var i, | |
2936 | + point; | |
2937 | + | |
2938 | + for (i in this.markers) { | |
2939 | + point = this.getMarkerPosition( this.markers[i].config ); | |
2940 | + if (point !== false) { | |
2941 | + this.markers[i].element.setStyle({cx: point.x, cy: point.y}); | |
2942 | + } | |
2943 | + } | |
2944 | + }, | |
2945 | + | |
2946 | + repositionLabels: function() { | |
2947 | + var key; | |
2948 | + | |
2949 | + for (key in this.regions) { | |
2950 | + this.regions[key].element.updateLabelPosition(); | |
2951 | + } | |
2952 | + | |
2953 | + for (key in this.markers) { | |
2954 | + this.markers[key].element.updateLabelPosition(); | |
2955 | + } | |
2956 | + }, | |
2957 | + | |
2958 | + getMarkerPosition: function(markerConfig) { | |
2959 | + if (jvm.Map.maps[this.params.map].projection) { | |
2960 | + return this.latLngToPoint.apply(this, markerConfig.latLng || [0, 0]); | |
2961 | + } else { | |
2962 | + return { | |
2963 | + x: markerConfig.coords[0]*this.scale + this.transX*this.scale, | |
2964 | + y: markerConfig.coords[1]*this.scale + this.transY*this.scale | |
2965 | + }; | |
2966 | + } | |
2967 | + }, | |
2968 | + | |
2969 | + /** | |
2970 | + * Add one marker to the map. | |
2971 | + * @param {String} key Marker unique code. | |
2972 | + * @param {Object} marker Marker configuration parameters. | |
2973 | + * @param {Array} seriesData Values to add to the data series. | |
2974 | + */ | |
2975 | + addMarker: function(key, marker, seriesData){ | |
2976 | + var markers = {}, | |
2977 | + data = [], | |
2978 | + values, | |
2979 | + i, | |
2980 | + seriesData = seriesData || []; | |
2981 | + | |
2982 | + markers[key] = marker; | |
2983 | + | |
2984 | + for (i = 0; i < seriesData.length; i++) { | |
2985 | + values = {}; | |
2986 | + if (typeof seriesData[i] !== 'undefined') { | |
2987 | + values[key] = seriesData[i]; | |
2988 | + } | |
2989 | + data.push(values); | |
2990 | + } | |
2991 | + this.addMarkers(markers, data); | |
2992 | + }, | |
2993 | + | |
2994 | + /** | |
2995 | + * Add set of marker to the map. | |
2996 | + * @param {Object|Array} markers Markers to add to the map. In case of array is provided, codes of markers will be set as string representations of array indexes. | |
2997 | + * @param {Array} seriesData Values to add to the data series. | |
2998 | + */ | |
2999 | + addMarkers: function(markers, seriesData){ | |
3000 | + var i; | |
3001 | + | |
3002 | + seriesData = seriesData || []; | |
3003 | + | |
3004 | + this.createMarkers(markers); | |
3005 | + for (i = 0; i < seriesData.length; i++) { | |
3006 | + this.series.markers[i].setValues(seriesData[i] || {}); | |
3007 | + }; | |
3008 | + }, | |
3009 | + | |
3010 | + /** | |
3011 | + * Remove some markers from the map. | |
3012 | + * @param {Array} markers Array of marker codes to be removed. | |
3013 | + */ | |
3014 | + removeMarkers: function(markers){ | |
3015 | + var i; | |
3016 | + | |
3017 | + for (i = 0; i < markers.length; i++) { | |
3018 | + this.markers[ markers[i] ].element.remove(); | |
3019 | + delete this.markers[ markers[i] ]; | |
3020 | + }; | |
3021 | + }, | |
3022 | + | |
3023 | + /** | |
3024 | + * Remove all markers from the map. | |
3025 | + */ | |
3026 | + removeAllMarkers: function(){ | |
3027 | + var i, | |
3028 | + markers = []; | |
3029 | + | |
3030 | + for (i in this.markers) { | |
3031 | + markers.push(i); | |
3032 | + } | |
3033 | + this.removeMarkers(markers) | |
3034 | + }, | |
3035 | + | |
3036 | + /** | |
3037 | + * Converts coordinates expressed as latitude and longitude to the coordinates in pixels on the map. | |
3038 | + * @param {Number} lat Latitide of point in degrees. | |
3039 | + * @param {Number} lng Longitude of point in degrees. | |
3040 | + */ | |
3041 | + latLngToPoint: function(lat, lng) { | |
3042 | + var point, | |
3043 | + proj = jvm.Map.maps[this.params.map].projection, | |
3044 | + centralMeridian = proj.centralMeridian, | |
3045 | + inset, | |
3046 | + bbox; | |
3047 | + | |
3048 | + if (lng < (-180 + centralMeridian)) { | |
3049 | + lng += 360; | |
3050 | + } | |
3051 | + | |
3052 | + point = jvm.Proj[proj.type](lat, lng, centralMeridian); | |
3053 | + | |
3054 | + inset = this.getInsetForPoint(point.x, point.y); | |
3055 | + if (inset) { | |
3056 | + bbox = inset.bbox; | |
3057 | + | |
3058 | + point.x = (point.x - bbox[0].x) / (bbox[1].x - bbox[0].x) * inset.width * this.scale; | |
3059 | + point.y = (point.y - bbox[0].y) / (bbox[1].y - bbox[0].y) * inset.height * this.scale; | |
3060 | + | |
3061 | + return { | |
3062 | + x: point.x + this.transX*this.scale + inset.left*this.scale, | |
3063 | + y: point.y + this.transY*this.scale + inset.top*this.scale | |
3064 | + }; | |
3065 | + } else { | |
3066 | + return false; | |
3067 | + } | |
3068 | + }, | |
3069 | + | |
3070 | + /** | |
3071 | + * Converts cartesian coordinates into coordinates expressed as latitude and longitude. | |
3072 | + * @param {Number} x X-axis of point on map in pixels. | |
3073 | + * @param {Number} y Y-axis of point on map in pixels. | |
3074 | + */ | |
3075 | + pointToLatLng: function(x, y) { | |
3076 | + var proj = jvm.Map.maps[this.params.map].projection, | |
3077 | + centralMeridian = proj.centralMeridian, | |
3078 | + insets = jvm.Map.maps[this.params.map].insets, | |
3079 | + i, | |
3080 | + inset, | |
3081 | + bbox, | |
3082 | + nx, | |
3083 | + ny; | |
3084 | + | |
3085 | + for (i = 0; i < insets.length; i++) { | |
3086 | + inset = insets[i]; | |
3087 | + bbox = inset.bbox; | |
3088 | + | |
3089 | + nx = x - (this.transX*this.scale + inset.left*this.scale); | |
3090 | + ny = y - (this.transY*this.scale + inset.top*this.scale); | |
3091 | + | |
3092 | + nx = (nx / (inset.width * this.scale)) * (bbox[1].x - bbox[0].x) + bbox[0].x; | |
3093 | + ny = (ny / (inset.height * this.scale)) * (bbox[1].y - bbox[0].y) + bbox[0].y; | |
3094 | + | |
3095 | + if (nx > bbox[0].x && nx < bbox[1].x && ny > bbox[0].y && ny < bbox[1].y) { | |
3096 | + return jvm.Proj[proj.type + '_inv'](nx, -ny, centralMeridian); | |
3097 | + } | |
3098 | + } | |
3099 | + | |
3100 | + return false; | |
3101 | + }, | |
3102 | + | |
3103 | + getInsetForPoint: function(x, y){ | |
3104 | + var insets = jvm.Map.maps[this.params.map].insets, | |
3105 | + i, | |
3106 | + bbox; | |
3107 | + | |
3108 | + for (i = 0; i < insets.length; i++) { | |
3109 | + bbox = insets[i].bbox; | |
3110 | + if (x > bbox[0].x && x < bbox[1].x && y > bbox[0].y && y < bbox[1].y) { | |
3111 | + return insets[i]; | |
3112 | + } | |
3113 | + } | |
3114 | + }, | |
3115 | + | |
3116 | + createSeries: function(){ | |
3117 | + var i, | |
3118 | + key; | |
3119 | + | |
3120 | + this.series = { | |
3121 | + markers: [], | |
3122 | + regions: [] | |
3123 | + }; | |
3124 | + | |
3125 | + for (key in this.params.series) { | |
3126 | + for (i = 0; i < this.params.series[key].length; i++) { | |
3127 | + this.series[key][i] = new jvm.DataSeries( | |
3128 | + this.params.series[key][i], | |
3129 | + this[key], | |
3130 | + this | |
3131 | + ); | |
3132 | + } | |
3133 | + } | |
3134 | + }, | |
3135 | + | |
3136 | + /** | |
3137 | + * Gracefully remove the map and and all its accessories, unbind event handlers. | |
3138 | + */ | |
3139 | + remove: function(){ | |
3140 | + this.tip.remove(); | |
3141 | + this.container.remove(); | |
3142 | + jvm.$(window).unbind('resize', this.onResize); | |
3143 | + jvm.$('body').unbind('mouseup', this.onContainerMouseUp); | |
3144 | + } | |
3145 | +}; | |
3146 | + | |
3147 | +jvm.Map.maps = {}; | |
3148 | +jvm.Map.defaultParams = { | |
3149 | + map: 'world_mill_en', | |
3150 | + backgroundColor: '#505050', | |
3151 | + zoomButtons: true, | |
3152 | + zoomOnScroll: true, | |
3153 | + zoomOnScrollSpeed: 3, | |
3154 | + panOnDrag: true, | |
3155 | + zoomMax: 8, | |
3156 | + zoomMin: 1, | |
3157 | + zoomStep: 1.6, | |
3158 | + zoomAnimate: true, | |
3159 | + regionsSelectable: false, | |
3160 | + markersSelectable: false, | |
3161 | + bindTouchEvents: true, | |
3162 | + regionStyle: { | |
3163 | + initial: { | |
3164 | + fill: 'white', | |
3165 | + "fill-opacity": 1, | |
3166 | + stroke: 'none', | |
3167 | + "stroke-width": 0, | |
3168 | + "stroke-opacity": 1 | |
3169 | + }, | |
3170 | + hover: { | |
3171 | + "fill-opacity": 0.8, | |
3172 | + cursor: 'pointer' | |
3173 | + }, | |
3174 | + selected: { | |
3175 | + fill: 'yellow' | |
3176 | + }, | |
3177 | + selectedHover: { | |
3178 | + } | |
3179 | + }, | |
3180 | + regionLabelStyle: { | |
3181 | + initial: { | |
3182 | + 'font-family': 'Verdana', | |
3183 | + 'font-size': '12', | |
3184 | + 'font-weight': 'bold', | |
3185 | + cursor: 'default', | |
3186 | + fill: 'black' | |
3187 | + }, | |
3188 | + hover: { | |
3189 | + cursor: 'pointer' | |
3190 | + } | |
3191 | + }, | |
3192 | + markerStyle: { | |
3193 | + initial: { | |
3194 | + fill: 'grey', | |
3195 | + stroke: '#505050', | |
3196 | + "fill-opacity": 1, | |
3197 | + "stroke-width": 1, | |
3198 | + "stroke-opacity": 1, | |
3199 | + r: 5 | |
3200 | + }, | |
3201 | + hover: { | |
3202 | + stroke: 'black', | |
3203 | + "stroke-width": 2, | |
3204 | + cursor: 'pointer' | |
3205 | + }, | |
3206 | + selected: { | |
3207 | + fill: 'blue' | |
3208 | + }, | |
3209 | + selectedHover: { | |
3210 | + } | |
3211 | + }, | |
3212 | + markerLabelStyle: { | |
3213 | + initial: { | |
3214 | + 'font-family': 'Verdana', | |
3215 | + 'font-size': '12', | |
3216 | + 'font-weight': 'bold', | |
3217 | + cursor: 'default', | |
3218 | + fill: 'black' | |
3219 | + }, | |
3220 | + hover: { | |
3221 | + cursor: 'pointer' | |
3222 | + } | |
3223 | + } | |
3224 | +}; | |
3225 | +jvm.Map.apiEvents = { | |
3226 | + onRegionTipShow: 'regionTipShow', | |
3227 | + onRegionOver: 'regionOver', | |
3228 | + onRegionOut: 'regionOut', | |
3229 | + onRegionClick: 'regionClick', | |
3230 | + onRegionSelected: 'regionSelected', | |
3231 | + onMarkerTipShow: 'markerTipShow', | |
3232 | + onMarkerOver: 'markerOver', | |
3233 | + onMarkerOut: 'markerOut', | |
3234 | + onMarkerClick: 'markerClick', | |
3235 | + onMarkerSelected: 'markerSelected', | |
3236 | + onViewportChange: 'viewportChange' | |
3237 | +};/** | |
3238 | + * Creates map with drill-down functionality. | |
3239 | + * @constructor | |
3240 | + * @param {Object} params Parameters to initialize map with. | |
3241 | + * @param {Number} params.maxLevel Maximum number of levels user can go through | |
3242 | + * @param {Object} params.main Config of the main map. See <a href="./jvm-map/">jvm.Map</a> for more information. | |
3243 | + * @param {Function} params.mapNameByCode Function go generate map name by region code. Default value is: | |
3244 | +<pre> | |
3245 | +function(code, multiMap) { | |
3246 | + return code.toLowerCase()+'_'+ | |
3247 | + multiMap.defaultProjection+'_en'; | |
3248 | +} | |
3249 | +</pre> | |
3250 | + * @param {Function} params.mapUrlByCode Function to generate map url by region code. Default value is: | |
3251 | +<pre> | |
3252 | +function(code, multiMap){ | |
3253 | + return 'jquery-jvectormap-data-'+ | |
3254 | + code.toLowerCase()+'-'+ | |
3255 | + multiMap.defaultProjection+'-en.js'; | |
3256 | +} | |
3257 | +</pre> | |
3258 | + */ | |
3259 | +jvm.MultiMap = function(params) { | |
3260 | + var that = this; | |
3261 | + | |
3262 | + this.maps = {}; | |
3263 | + this.params = jvm.$.extend(true, {}, jvm.MultiMap.defaultParams, params); | |
3264 | + this.params.maxLevel = this.params.maxLevel || Number.MAX_VALUE; | |
3265 | + this.params.main = this.params.main || {}; | |
3266 | + this.params.main.multiMapLevel = 0; | |
3267 | + this.history = [ this.addMap(this.params.main.map, this.params.main) ]; | |
3268 | + this.defaultProjection = this.history[0].mapData.projection.type; | |
3269 | + this.mapsLoaded = {}; | |
3270 | + | |
3271 | + this.params.container.css({position: 'relative'}); | |
3272 | + this.backButton = jvm.$('<div/>').addClass('jvectormap-goback').text('Back').appendTo(this.params.container); | |
3273 | + this.backButton.hide(); | |
3274 | + this.backButton.click(function(){ | |
3275 | + that.goBack(); | |
3276 | + }); | |
3277 | + | |
3278 | + this.spinner = jvm.$('<div/>').addClass('jvectormap-spinner').appendTo(this.params.container); | |
3279 | + this.spinner.hide(); | |
3280 | +}; | |
3281 | + | |
3282 | +jvm.MultiMap.prototype = { | |
3283 | + addMap: function(name, config){ | |
3284 | + var cnt = jvm.$('<div/>').css({ | |
3285 | + width: '100%', | |
3286 | + height: '100%' | |
3287 | + }); | |
3288 | + | |
3289 | + this.params.container.append(cnt); | |
3290 | + | |
3291 | + this.maps[name] = new jvm.Map(jvm.$.extend(config, {container: cnt})); | |
3292 | + if (this.params.maxLevel > config.multiMapLevel) { | |
3293 | + this.maps[name].container.on('regionClick.jvectormap', {scope: this}, function(e, code){ | |
3294 | + var multimap = e.data.scope, | |
3295 | + mapName = multimap.params.mapNameByCode(code, multimap); | |
3296 | + | |
3297 | + if (!multimap.drillDownPromise || multimap.drillDownPromise.state() !== 'pending') { | |
3298 | + multimap.drillDown(mapName, code); | |
3299 | + } | |
3300 | + }); | |
3301 | + } | |
3302 | + | |
3303 | + | |
3304 | + return this.maps[name]; | |
3305 | + }, | |
3306 | + | |
3307 | + downloadMap: function(code){ | |
3308 | + var that = this, | |
3309 | + deferred = jvm.$.Deferred(); | |
3310 | + | |
3311 | + if (!this.mapsLoaded[code]) { | |
3312 | + jvm.$.get(this.params.mapUrlByCode(code, this)).then(function(){ | |
3313 | + that.mapsLoaded[code] = true; | |
3314 | + deferred.resolve(); | |
3315 | + }, function(){ | |
3316 | + deferred.reject(); | |
3317 | + }); | |
3318 | + } else { | |
3319 | + deferred.resolve(); | |
3320 | + } | |
3321 | + return deferred; | |
3322 | + }, | |
3323 | + | |
3324 | + drillDown: function(name, code){ | |
3325 | + var currentMap = this.history[this.history.length - 1], | |
3326 | + that = this, | |
3327 | + focusPromise = currentMap.setFocus({region: code, animate: true}), | |
3328 | + downloadPromise = this.downloadMap(code); | |
3329 | + | |
3330 | + focusPromise.then(function(){ | |
3331 | + if (downloadPromise.state() === 'pending') { | |
3332 | + that.spinner.show(); | |
3333 | + } | |
3334 | + }); | |
3335 | + downloadPromise.always(function(){ | |
3336 | + that.spinner.hide(); | |
3337 | + }); | |
3338 | + this.drillDownPromise = jvm.$.when(downloadPromise, focusPromise); | |
3339 | + this.drillDownPromise.then(function(){ | |
3340 | + currentMap.params.container.hide(); | |
3341 | + if (!that.maps[name]) { | |
3342 | + that.addMap(name, {map: name, multiMapLevel: currentMap.params.multiMapLevel + 1}); | |
3343 | + } else { | |
3344 | + that.maps[name].params.container.show(); | |
3345 | + } | |
3346 | + that.history.push( that.maps[name] ); | |
3347 | + that.backButton.show(); | |
3348 | + }); | |
3349 | + }, | |
3350 | + | |
3351 | + goBack: function(){ | |
3352 | + var currentMap = this.history.pop(), | |
3353 | + prevMap = this.history[this.history.length - 1], | |
3354 | + that = this; | |
3355 | + | |
3356 | + currentMap.setFocus({scale: 1, x: 0.5, y: 0.5, animate: true}).then(function(){ | |
3357 | + currentMap.params.container.hide(); | |
3358 | + prevMap.params.container.show(); | |
3359 | + prevMap.updateSize(); | |
3360 | + if (that.history.length === 1) { | |
3361 | + that.backButton.hide(); | |
3362 | + } | |
3363 | + prevMap.setFocus({scale: 1, x: 0.5, y: 0.5, animate: true}); | |
3364 | + }); | |
3365 | + } | |
3366 | +}; | |
3367 | + | |
3368 | +jvm.MultiMap.defaultParams = { | |
3369 | + mapNameByCode: function(code, multiMap){ | |
3370 | + return code.toLowerCase()+'_'+multiMap.defaultProjection+'_en'; | |
3371 | + }, | |
3372 | + mapUrlByCode: function(code, multiMap){ | |
3373 | + return 'jquery-jvectormap-data-'+code.toLowerCase()+'-'+multiMap.defaultProjection+'-en.js'; | |
3374 | + } | |
3375 | +} | ... | ... |
app/jvectormap-204/jquery-jvectormap-us-lcc.js
... | ... | @@ -0,0 +1 @@ |
1 | +jQuery.fn.vectorMap('addMap', 'us_lcc',{"insets": [{"width": 220, "top": 440, "height": 192.76093370153905, "bbox": [{"y": -9264259.168284032, "x": -4695169.263875983}, {"y": -6764278.677986234, "x": -1841916.2872271966}], "left": 0}, {"width": 80, "top": 460, "height": 171.28243723090768, "bbox": [{"y": -4783904.929675324, "x": -5950370.881002157}, {"y": -4215886.671550633, "x": -5685069.537883626}], "left": 245}, {"width": 900, "top": 0, "height": 551.796858257794, "bbox": [{"y": -5998735.631562797, "x": -2035185.0941474987}, {"y": -3186828.4463602225, "x": 2551133.999209847}], "left": 0}], "paths": {"US-VA": {"path": "M684.14,290.06l1.59,-0.92l1.65,-0.49l1.11,-0.95l3.57,-1.7l0.73,-2.31l0.83,-0.2l2.31,-1.54l0.04,-1.79l2.04,-1.86l-0.13,-1.56l0.25,-0.41l5.0,-4.09l4.74,-5.97l0.1,0.61l0.97,0.52l0.34,1.35l1.33,0.71l0.71,0.79l1.47,0.07l2.1,1.08l1.41,-0.11l0.79,-0.41l0.76,-1.22l1.18,-0.57l0.53,-1.36l2.74,1.43l1.42,-1.1l2.25,-1.01l0.76,0.05l1.07,-0.96l0.33,-0.82l-0.49,-0.94l0.23,-0.41l1.91,0.55l3.25,-2.63l0.3,-0.1l0.51,0.71l0.66,-0.08l2.37,-2.33l0.17,-0.85l-0.5,-0.49l0.98,-1.12l0.1,-0.6l-0.29,-0.5l-1.01,-0.43l0.69,-2.99l2.58,-4.76l0.54,-2.12l-0.02,-1.88l1.6,-2.53l-0.22,-0.92l0.24,-0.83l0.5,-0.48l0.38,-1.68l-0.02,-3.13l1.23,0.17l1.19,1.69l3.81,0.37l0.58,-0.28l1.03,-2.5l0.18,-2.33l0.7,-1.04l-0.05,-1.59l0.75,-2.28l1.8,0.72l0.65,-0.18l1.29,-3.27l0.57,0.04l0.59,-0.39l0.51,-1.19l0.81,-0.68l0.43,-1.78l1.36,-2.42l-0.37,-2.53l0.53,-1.74l-0.32,-1.97l9.23,4.37l0.58,-0.3l0.61,-3.94l2.61,-0.11l0.63,0.55l1.06,0.21l-0.5,1.72l0.62,0.87l1.62,0.81l2.53,-0.08l1.04,1.14l1.5,0.11l2.25,1.66l0.01,1.29l0.45,1.24l-1.66,0.97l-0.11,0.65l-0.64,0.14l-0.27,0.45l-0.44,4.96l-0.36,0.13l-0.04,0.49l1.16,0.93l-0.28,0.11l-0.03,0.76l2.03,-0.04l2.4,-1.47l0.49,-0.72l0.34,0.71l-0.51,0.64l1.23,0.86l0.69,0.12l0.43,1.08l1.63,0.48l1.94,-0.23l0.84,0.41l0.82,-0.66l0.89,0.01l0.24,0.59l1.34,0.45l0.47,1.08l1.12,-0.06l0.03,0.3l1.19,0.39l2.85,0.59l0.4,0.98l-0.87,-0.4l-0.56,0.45l0.9,1.7l-0.35,0.56l0.62,0.77l-0.42,0.88l0.23,0.58l-1.36,-0.33l-0.59,-0.7l-0.66,0.19l-0.1,0.43l-2.47,-2.23l-0.56,0.06l-0.37,-0.54l-0.53,0.33l-1.48,-1.28l-1.19,-0.36l-0.43,-0.62l-0.91,-0.37l-0.71,-1.26l-0.77,-0.62l-1.34,-0.1l-1.12,-0.78l-1.17,0.07l-0.39,0.52l0.48,0.71l1.1,-0.03l0.64,0.66l1.33,0.05l0.59,0.4l0.39,1.49l2.75,1.5l1.87,1.83l1.96,0.57l1.6,2.05l0.98,0.22l1.36,-0.46l1.26,0.45l-0.58,0.69l0.31,0.48l2.03,0.3l0.27,0.71l0.46,0.11l0.32,1.91l-0.58,-0.81l-0.52,-0.21l-0.4,0.21l-1.14,-0.97l-0.58,0.3l0.11,0.81l-0.3,0.68l0.7,0.69l-0.16,0.59l0.52,0.28l0.44,-0.15l0.28,0.33l-1.4,0.74l-6.2,-4.58l-0.57,0.12l-0.19,0.81l0.25,0.53l2.3,1.47l2.11,2.07l2.79,1.12l1.25,-0.69l0.46,1.03l1.27,0.23l-0.43,0.66l0.3,0.56l0.93,-0.2l0.01,1.21l-0.92,0.42l-0.57,0.74l-0.65,-0.86l-3.16,-1.19l-0.43,-1.5l-0.6,-0.57l-0.86,-0.1l-1.2,0.68l-1.72,-0.41l-0.37,-1.13l-0.71,-0.04l-0.05,1.3l-0.33,0.41l-1.44,-1.28l-0.51,0.09l-0.49,0.57l-0.65,-0.38l-0.99,0.46l-2.23,-0.07l-0.37,0.94l0.35,0.45l1.91,0.18l1.4,-0.33l0.85,0.23l0.56,-0.69l0.64,0.86l1.35,0.4l1.96,-0.34l0.83,0.7l0.84,0.1l0.51,-0.56l0.79,2.4l1.35,0.11l0.24,0.42l1.69,0.67l0.45,0.65l-0.57,1.02l0.57,0.43l1.72,-1.32l0.89,-0.03l0.84,0.63l0.79,-0.28l-0.62,-0.88l-0.01,-0.81l-0.46,-0.31l4.0,0.01l0.93,-0.74l2.09,3.43l-0.39,0.7l0.68,3.03l-1.2,-0.55l-0.01,0.86l-33.6,8.85l-34.62,8.17l-19.56,3.56l-11.81,1.37l-0.82,0.62l-28.25,5.27ZM782.78,223.24l0.11,0.07l-0.08,0.05l0.0,-0.02l-0.03,-0.11ZM809.83,243.56l0.52,-1.13l-0.63,-0.6l0.57,-0.97l-0.39,-0.71l-0.03,-0.47l0.43,-0.35l-0.18,-0.72l0.63,-0.3l0.22,-0.6l0.12,-2.29l1.01,-0.4l-0.13,-0.88l0.48,-0.15l-0.27,-1.51l-0.77,-0.39l0.85,-0.56l0.1,-0.95l2.64,-1.04l0.33,2.42l-3.8,10.38l0.17,1.1l-0.47,0.31l-0.32,1.08l0.28,4.22l-1.12,-1.77l0.22,-0.92l-0.34,-1.54l0.27,-0.97l-0.38,-0.29Z", "name": "Virginia"}, "US-PA": {"path": "M717.54,161.49l0.63,-0.19l4.28,-3.74l1.16,5.12l0.48,0.3l34.82,-8.31l34.25,-9.05l1.43,0.55l0.73,1.36l0.63,0.12l0.77,-0.34l1.24,0.56l0.16,0.84l0.81,0.39l-0.15,0.58l0.92,2.65l1.92,2.02l2.12,0.71l2.21,-0.24l0.72,0.77l-0.89,0.87l-0.71,1.48l-0.16,2.23l-1.39,3.33l-1.36,1.59l0.04,0.79l1.8,1.66l-0.29,1.63l-0.84,0.44l-0.22,0.65l0.15,1.46l1.06,2.82l0.53,0.24l1.2,-0.2l1.2,2.33l0.96,0.56l0.66,-0.27l0.61,0.88l4.26,2.64l0.12,0.39l-1.28,0.94l-3.69,4.22l-0.22,0.75l0.18,0.88l-1.35,1.14l-0.84,0.16l-1.32,1.09l-0.31,0.65l-1.73,-0.09l-2.03,0.86l-1.14,1.36l-0.4,1.38l-37.23,9.65l-39.12,9.07l-10.34,-47.41l1.91,-1.23l3.06,-3.05Z", "name": "Pennsylvania"}, "US-TN": {"path": "M573.21,341.39l0.85,-0.82l0.29,-1.35l1.01,0.04l0.65,-0.79l-1.01,-4.82l1.41,-1.91l0.06,-1.31l1.19,-0.47l0.36,-0.48l-0.64,-1.29l0.57,-1.2l-0.9,-1.3l2.56,-1.56l1.09,-1.12l-0.14,-0.84l-0.85,-0.52l0.13,-0.18l0.34,-0.16l0.85,0.36l0.45,-0.33l-0.27,-1.3l-0.85,-0.88l0.05,-0.69l0.5,-1.41l1.01,-1.1l-1.35,-2.02l1.37,-0.22l0.61,-0.55l-0.14,-0.64l-1.18,-0.79l0.82,-0.15l0.58,-0.54l0.13,-0.69l-0.59,-1.35l0.02,-0.36l0.38,0.53l0.47,0.07l1.18,-1.14l23.75,-2.95l0.35,-0.41l-0.1,-1.33l-0.84,-2.34l2.99,-0.1l0.82,0.57l22.86,-3.69l7.67,-0.52l7.52,-0.92l32.92,-4.79l1.11,-0.6l29.37,-5.47l0.73,-0.6l3.56,-0.57l-0.39,1.41l0.44,0.84l-0.39,1.97l0.36,0.8l-1.15,-0.02l-1.71,1.79l-1.19,3.85l-0.55,0.69l-0.57,0.08l-0.64,-0.72l-1.44,-0.0l-2.66,1.74l-1.41,2.71l-0.96,0.89l-0.34,-0.33l-0.14,-1.04l-0.73,-0.52l-0.53,0.15l-2.3,1.81l-0.29,1.31l-0.94,-0.23l-0.89,0.48l-0.16,0.76l0.33,0.71l-0.84,2.15l-1.29,0.07l-1.75,1.14l-1.89,2.29l-0.78,0.28l-2.28,2.45l-4.05,0.81l-2.58,1.7l-0.49,1.08l-0.88,0.55l-0.55,0.8l-0.17,2.85l-0.35,0.6l-1.66,0.53l-0.89,-0.15l-1.06,1.14l0.23,5.18l-20.28,3.48l-21.69,3.21l-25.85,3.15l-0.13,0.28l-7.42,0.94l-28.82,3.33Z", "name": "Tennessee"}, "US-WV": {"path": "M694.56,248.96l3.95,-1.56l0.35,-0.7l0.11,-2.72l1.15,-0.23l0.4,-0.61l-0.59,-2.46l-0.62,-1.21l0.48,-0.64l0.34,-2.74l0.67,-1.64l0.46,-0.39l1.25,0.52l0.41,0.68l-0.13,1.12l0.71,0.44l0.77,-0.44l0.47,-1.41l0.5,0.21l0.57,-0.2l0.2,-0.45l-0.65,-2.06l-0.75,-0.53l0.8,-0.78l-0.27,-1.69l0.73,-1.98l1.65,-0.53l0.16,-1.58l1.01,-1.41l0.44,-0.09l0.65,0.77l0.67,0.18l2.27,-1.59l1.49,-1.63l0.78,-1.81l2.44,-2.66l0.36,-2.38l-0.74,-0.98l0.7,-2.31l-0.25,-0.75l0.58,-0.58l-0.29,-3.38l0.45,-3.87l0.53,-0.79l0.07,-1.1l-0.39,-1.18l-0.4,-0.32l-0.05,-1.97l-1.58,-1.86l0.44,-0.53l0.85,-0.11l0.3,-0.33l4.15,19.0l0.48,0.31l16.61,-3.72l2.23,10.49l0.51,0.37l2.05,-2.49l0.97,-0.56l0.34,-1.02l1.62,-1.98l0.25,-1.03l0.52,-0.4l1.2,0.42l0.73,-0.32l1.31,-2.58l0.6,-0.46l-0.04,-0.85l0.42,0.58l1.81,0.49l3.2,-0.61l0.77,-0.86l0.07,-1.44l1.99,-0.76l1.02,-1.68l0.67,-0.11l3.17,1.44l1.8,-0.73l-0.44,1.01l0.56,0.9l1.27,0.4l0.09,0.95l1.13,0.4l0.1,1.18l0.34,0.41l-0.56,3.59l-9.05,-4.28l-0.64,0.25l-0.3,1.14l0.39,1.58l-0.51,1.61l0.42,2.24l-1.35,2.39l-0.41,1.74l-0.72,0.53l-0.41,1.09l-0.28,0.22l-0.61,-0.22l-0.37,0.33l-1.23,3.25l-1.85,-0.74l-0.64,0.26l-0.93,2.75l0.09,1.44l-0.73,1.14l-0.18,2.3l-0.88,2.18l-3.26,-0.31l-1.45,-1.71l-1.71,-0.22l-0.5,0.42l-0.25,2.14l0.2,1.28l-0.31,1.43l-0.49,0.45l-0.31,1.03l0.23,0.91l-1.57,2.42l-0.03,2.07l-0.51,1.98l-2.56,4.69l-0.73,3.13l0.15,0.76l1.14,0.52l-1.08,1.37l0.06,0.6l0.44,0.39l-2.15,2.12l-0.55,-0.69l-0.84,0.16l-3.12,2.53l-1.04,-0.54l-1.31,0.27l-0.43,0.9l0.46,1.14l-0.91,0.91l-0.73,-0.04l-2.27,1.02l-1.21,0.97l-2.2,-1.31l-0.73,0.0l-0.81,1.57l-1.1,0.5l-1.22,1.46l-1.09,0.1l-1.99,-1.05l-1.31,0.0l-0.62,-0.72l-1.2,-0.58l-0.31,-1.31l-0.88,-0.53l0.35,-0.66l-0.31,-0.81l-0.85,-0.36l-0.84,0.25l-1.34,-0.15l-1.27,-1.16l-2.07,-0.75l-0.77,-1.4l-1.59,-1.2l-0.71,-1.46l-1.0,-0.57l-0.13,-1.07l-1.39,-0.92l-2.01,-2.21l0.7,-2.0l-0.26,-1.59l-0.67,-1.43Z", "name": "West Virginia"}, "US-NV": {"path": "M139.04,328.96l-12.67,-16.85l-36.47,-50.77l-25.22,-34.32l14.11,-63.11l46.89,9.68l47.02,8.11l-19.27,123.79l-0.91,1.13l-1.0,2.15l-0.44,0.17l-1.35,-0.23l-0.97,-2.22l-0.7,-0.63l-1.42,0.2l-1.95,-1.02l-1.61,0.21l-1.79,0.93l-0.78,2.44l0.87,2.57l-0.61,0.95l-0.25,1.29l0.37,3.08l-0.77,2.5l0.76,3.67l-0.15,3.03l-0.31,1.05l-1.05,0.3l0.2,1.3l-0.53,0.61Z", "name": "Nevada"}, "US-TX": {"path": "M276.21,412.55l33.26,2.09l32.98,1.42l0.41,-0.38l3.72,-97.67l25.96,0.65l26.39,0.23l0.05,41.51l0.44,0.4l1.03,-0.13l0.79,0.27l3.76,3.77l1.67,0.2l0.88,-0.57l2.5,0.64l0.6,-0.67l0.11,-1.04l0.61,0.75l0.93,0.22l0.38,0.92l0.77,0.77l-0.01,1.62l0.53,0.83l2.86,0.41l1.26,-0.2l1.39,0.88l2.8,0.68l1.83,-0.56l0.63,0.1l1.9,1.78l1.41,-0.11l1.26,-1.41l2.44,0.26l1.68,-0.45l0.32,2.59l2.31,0.73l-0.04,2.06l1.56,0.77l1.82,-0.65l1.58,-1.66l1.03,-0.64l0.41,0.19l0.45,1.62l2.02,0.2l0.25,1.04l0.72,0.47l1.47,-0.21l0.89,-0.93l0.39,0.33l0.59,-0.08l0.61,-0.98l0.26,0.4l-0.45,1.22l0.14,0.76l0.68,1.13l0.78,0.41l0.57,-0.04l0.6,-0.5l0.69,-2.34l0.91,-0.65l0.35,-1.53l0.57,-0.14l0.41,0.14l0.29,0.98l0.58,0.63l1.21,0.01l0.83,0.49l1.26,-0.2l0.69,-1.33l0.49,0.15l-0.13,0.69l0.49,0.69l1.21,0.44l0.49,0.71l1.53,-0.05l1.5,1.72l0.51,0.02l0.63,-0.62l0.08,-0.71l1.5,-0.1l0.93,-1.42l1.89,-0.41l1.67,-1.13l1.53,0.83l1.51,-0.22l0.29,-0.83l2.3,-0.73l0.53,-0.55l0.51,0.32l0.38,0.87l1.83,0.41l1.7,-0.06l1.87,-1.14l0.42,-1.04l1.07,0.3l2.25,1.54l1.16,0.17l1.8,2.05l2.15,0.39l1.05,0.91l0.76,-0.11l2.5,0.84l1.05,0.03l0.37,0.78l1.39,0.96l1.45,-0.12l0.39,-0.71l0.81,0.36l0.88,-0.4l0.93,0.34l0.76,-0.16l0.64,0.36l2.31,33.8l1.52,1.66l1.31,0.82l1.26,1.86l0.58,1.62l-0.09,2.64l1.01,1.2l0.85,0.39l-0.11,0.85l0.75,0.54l0.29,0.87l0.66,0.69l-0.19,1.17l1.01,1.02l0.6,1.63l0.51,0.34l0.55,-0.11l-0.16,1.71l0.82,1.21l-0.64,0.25l-0.35,0.68l0.78,1.26l-0.55,0.89l0.19,1.39l-0.75,2.69l-0.75,0.85l-0.36,1.55l-0.79,1.13l0.65,2.0l-0.83,2.29l0.17,1.08l0.84,1.2l-0.18,1.01l0.5,1.61l-0.24,1.41l-1.18,1.79l-1.18,0.4l-1.16,2.74l-0.02,2.11l1.4,1.68l-3.45,0.1l-7.41,3.83l-0.02,-0.44l-0.69,-0.23l-0.24,0.23l-0.79,-0.43l-3.41,1.15l0.65,-1.32l0.34,-2.05l-0.35,-1.36l-0.8,-0.79l-1.8,0.16l-1.18,2.6l-0.43,0.16l-0.36,-0.66l-2.39,-1.23l-0.4,0.31l-0.18,0.82l0.23,0.45l1.08,0.38l-0.3,0.83l0.54,0.82l-0.47,0.64l0.04,1.0l1.5,0.76l-0.45,0.47l0.5,1.13l0.91,0.23l0.28,0.38l-0.41,1.27l-0.46,-0.12l-0.98,0.82l-1.73,2.27l-1.19,-0.4l-0.49,0.12l0.33,1.01l0.08,2.57l-1.86,1.51l-1.91,2.13l-0.97,0.37l-4.13,2.94l-3.32,0.46l-2.56,1.08l-0.2,1.14l-0.76,-0.35l-2.05,0.9l-0.34,-0.35l-1.13,0.19l0.43,-0.89l-0.53,-0.6l-1.44,0.23l-1.23,1.1l-0.61,-0.63l-0.11,-1.21l-1.39,-0.82l-0.5,0.44l0.66,1.45l0.02,1.14l-0.73,0.09l-0.54,-0.44l-0.76,-0.0l-0.56,-1.35l-1.47,-0.37l-0.58,0.39l0.04,0.55l0.95,1.72l0.03,1.25l0.58,0.37l0.37,-0.16l1.15,0.79l-0.76,0.38l-0.12,0.91l0.7,0.23l1.09,-0.55l0.97,0.61l-4.3,2.46l-0.58,-0.13l-0.37,-1.46l-0.51,-0.19l-1.14,-1.48l-0.48,-0.03l-0.49,0.51l0.12,0.64l-0.64,0.35l-0.05,0.51l1.2,1.64l-0.31,1.06l0.33,0.86l-1.67,1.82l-0.38,0.2l0.38,-0.65l-0.19,-0.73l0.25,-0.74l-0.46,-0.68l-0.52,0.17l-0.72,1.11l0.26,0.73l-0.4,0.97l-0.08,-1.15l-0.52,-0.55l-1.96,1.31l-0.78,-0.33l-0.7,0.52l0.07,0.76l-0.82,1.01l0.02,0.49l1.26,0.64l0.03,0.57l0.79,0.28l0.7,-1.43l0.87,-0.42l0.01,0.64l-2.84,4.43l-1.24,-1.01l-1.37,0.39l-0.33,-0.35l-2.42,0.4l-0.46,-0.32l-0.66,0.17l-0.18,0.58l0.42,0.62l0.55,0.38l1.55,0.03l0.54,1.58l2.09,1.05l-2.71,7.78l-0.22,0.11l-0.38,-0.56l-0.34,0.1l0.18,-0.78l-0.57,-0.43l-2.37,1.99l-1.69,-2.35l-1.24,-0.98l-0.61,0.4l0.09,0.53l1.46,2.04l-0.24,0.47l0.42,0.5l-1.24,-0.21l-0.33,0.63l0.51,0.57l0.9,0.24l1.13,-0.16l0.66,0.64l1.38,0.18l1.01,-0.03l1.01,-0.63l-0.35,1.63l0.24,0.79l-0.98,0.72l0.38,1.63l-1.13,0.15l-0.43,0.41l0.41,2.15l-0.33,1.63l0.45,0.64l0.85,0.24l0.89,2.93l0.72,2.88l-0.92,0.84l0.63,0.49l-0.08,1.31l0.72,0.3l0.18,0.63l0.59,0.29l0.4,1.84l0.7,0.32l0.44,3.3l0.8,0.56l0.7,0.08l-0.55,1.15l0.33,1.11l-0.64,0.8l-0.85,-0.05l-0.54,0.46l0.09,1.34l-0.5,-0.34l-0.5,0.26l-0.39,-0.68l-1.5,-0.46l-2.95,-2.6l-2.23,-0.18l-0.81,-0.52l-4.24,0.1l-0.91,0.44l-0.79,-0.64l-1.65,0.24l-2.14,-0.91l-0.74,-1.0l-0.61,-0.14l-0.2,-0.74l-1.18,-0.5l-1.0,-0.02l-2.0,-0.89l-1.47,0.4l-0.84,-1.12l-0.61,-0.21l-1.44,-1.42l-1.98,0.01l-1.48,-0.66l-0.86,0.12l-1.64,-0.43l0.31,-1.21l-0.56,-1.11l-0.82,-0.3l0.32,-0.3l-0.27,-1.48l0.58,-1.23l-0.36,-0.68l0.9,-0.4l0.12,-0.54l-1.04,-0.54l-0.92,0.68l-0.33,-0.32l0.03,-1.12l-0.6,-0.86l0.32,-0.09l0.54,-1.47l-0.22,-0.7l-0.71,0.09l-1.04,0.99l-0.58,-0.91l-0.86,-0.29l-0.26,-1.37l-1.53,-0.79l0.29,-0.67l-0.24,-0.77l0.34,-2.23l-0.45,-0.97l-1.06,-1.03l0.66,-2.03l0.05,-1.21l-0.18,-0.71l-0.54,-0.33l-0.15,-1.85l-1.86,-1.46l-0.86,0.22l-0.3,-0.42l-0.81,-0.11l-0.75,-1.33l-2.24,-1.74l0.01,-0.7l-0.51,-0.59l0.12,-0.88l-0.98,-0.93l-0.08,-0.76l-1.13,-0.62l-1.31,-2.92l-2.68,-1.5l-0.38,-0.92l-1.14,-0.6l-0.06,-1.18l-0.82,-1.2l-0.6,-1.98l0.42,-0.23l-0.04,-0.72l-1.04,-0.5l-0.26,-1.31l-0.82,-0.58l-0.95,-1.76l-0.61,-2.41l-1.86,-2.38l-0.87,-4.28l-1.82,-1.35l0.05,-0.7l-0.76,-1.22l-4.1,-2.85l-0.3,-1.4l1.69,-0.02l0.8,-0.84l-0.29,-0.39l-0.66,-0.06l-0.09,-0.73l0.08,-0.89l0.65,-0.7l-0.11,-0.74l-0.48,0.05l-0.77,0.73l-0.45,0.69l0.01,0.67l-0.89,0.15l-0.4,1.07l-0.54,-0.04l-0.75,-0.47l-0.62,-1.14l-0.45,-0.16l0.06,-0.68l-0.42,-0.69l-0.77,-0.2l-0.65,0.3l-0.33,-0.54l-0.73,-0.13l-0.89,-2.18l-1.5,-0.8l-0.86,0.27l-0.44,-0.88l-0.61,0.1l-0.25,0.61l-1.06,0.16l-2.91,-0.47l-0.39,-0.38l-1.5,-0.03l-0.79,0.29l-0.77,-0.44l-2.68,0.27l-2.44,-1.09l-1.15,-0.89l-0.68,-0.07l-1.04,0.83l-0.65,1.62l-2.0,-0.18l-0.52,0.45l-0.49,-0.17l-2.54,0.78l-3.1,6.29l-0.19,1.78l-0.77,0.67l-0.38,1.81l0.35,0.59l-1.99,0.99l-0.75,1.33l-1.07,0.62l-0.63,0.84l-0.3,1.1l-2.94,-0.35l-1.04,-0.88l-0.55,0.3l-1.7,-1.22l-1.32,-1.65l-2.92,-0.86l-1.16,-0.96l-0.02,-0.67l-0.42,-0.41l-2.77,-0.52l-2.29,-1.05l-1.9,-1.77l-0.91,-1.55l-0.97,-0.92l-1.54,-0.29l-1.78,-1.27l-0.22,-0.56l-1.14,-0.97l-0.83,-2.92l-0.87,-1.02l-0.24,-1.11l-0.76,-1.28l-0.26,-2.35l0.53,-3.06l-3.01,-5.09l-0.05,-1.94l-1.26,-2.52l-0.99,-0.44l-0.43,-1.24l-1.44,-0.82l-2.16,-2.18l-1.03,-0.1l-2.02,-1.26l-3.19,-3.36l-0.59,-1.55l-3.14,-2.56l-1.59,-2.45l-1.2,-0.95l-0.61,-1.05l-4.44,-2.61l-2.4,-5.42l-1.38,-1.09l-1.13,-0.08l-1.76,-1.68l-0.78,-3.04ZM503.54,468.27l-0.35,0.19l0.19,-0.17l0.16,-0.02ZM500.15,470.92l-0.13,0.17l-0.05,0.03l0.18,-0.2ZM468.78,489.53l0.04,0.02l-0.03,0.02l-0.0,-0.05ZM455.16,548.69l0.78,-0.54l0.25,-0.71l0.11,1.14l-1.14,0.11Z", "name": "Texas"}, "US-NH": {"path": "M830.64,105.83l0.18,-1.32l-1.48,-5.32l0.52,-1.45l-0.31,-2.2l0.98,-1.86l-0.16,-2.28l0.61,-2.28l-0.45,-0.61l0.27,-2.29l-0.98,-3.77l0.07,-0.7l0.3,-0.46l1.83,-0.83l0.68,-1.39l1.42,-1.64l0.72,-1.8l-0.26,-1.12l0.51,-0.63l-2.38,-3.45l0.83,-3.26l-0.12,-0.78l-0.82,-1.28l0.27,-0.59l-0.24,-0.7l0.44,-3.2l-0.37,-0.82l0.89,-1.5l2.44,0.3l0.64,-0.87l13.42,34.51l0.88,3.61l2.62,2.16l0.88,0.32l0.38,1.58l1.73,1.27l0.01,0.35l0.78,0.22l-0.05,0.57l-0.43,3.07l-1.57,0.26l-1.31,1.21l-0.5,0.94l-0.96,0.38l-0.49,1.67l-1.08,1.44l-17.58,4.99l-1.71,-1.39l-0.42,-0.87l-0.12,-1.98l0.53,-0.59l0.03,-0.52l-1.08,-5.12Z", "name": "New Hampshire"}, "US-NY": {"path": "M823.24,168.46l-0.84,-0.69l0.8,-3.2l1.03,-0.31l0.37,-0.48l0.74,0.19l0.63,-0.33l-0.06,-0.57l0.43,-0.06l0.27,-0.66l0.72,-0.32l-0.22,-1.4l0.73,-0.47l0.36,0.55l1.04,-0.17l0.48,-0.33l0.01,-0.54l1.46,-0.2l0.23,-0.73l1.66,-0.01l0.91,-0.55l0.44,-1.21l0.62,0.24l0.42,-0.5l4.32,-1.34l2.34,-1.14l2.34,-2.85l0.17,0.15l-2.5,3.42l-0.01,0.46l0.57,0.37l1.59,-0.35l0.28,0.59l-1.29,1.2l-2.05,0.56l-0.37,0.58l-1.16,0.43l0.24,0.42l-0.24,0.3l-0.69,-0.14l-0.74,0.7l-1.04,0.18l-0.37,0.55l-1.41,0.47l-0.25,0.67l-1.34,0.21l-0.44,0.7l-1.35,0.97l-2.76,1.37l-1.02,0.89l-1.04,0.1l-0.31,0.92l-0.28,0.04l-0.28,-0.66l-1.44,-0.22l-0.87,0.75l0.08,0.95l-0.94,0.57ZM845.5,154.69l0.86,-2.12l1.18,-0.5l0.59,-0.93l0.82,0.32l0.12,-0.83l0.75,0.61l-3.81,3.69l-0.51,-0.26ZM846.32,148.86l0.15,-0.09l0.08,-0.01l-0.11,0.18l-0.12,-0.07ZM723.15,157.04l3.74,-3.85l1.26,-2.18l1.74,-1.86l1.16,-0.78l1.25,-3.34l2.08,-2.14l-0.22,-1.82l-1.63,-2.37l0.42,-1.12l-0.18,-0.77l-0.84,-0.52l-2.1,0.02l0.04,-0.98l-0.59,-2.2l4.96,-2.97l4.47,-1.84l2.38,-0.23l1.83,-0.76l5.64,-0.31l3.14,1.2l3.15,-1.71l5.49,-1.13l0.59,0.44l0.67,-0.21l0.11,-0.98l3.21,-1.88l0.67,-2.04l1.86,-1.77l0.77,-1.27l1.12,0.02l1.12,-0.53l1.05,-1.64l-0.47,-0.69l0.35,-1.19l-0.26,-0.51l-0.64,0.03l-0.18,-1.16l-0.95,-1.56l-1.01,-0.6l0.12,-0.18l0.6,0.38l0.53,-0.27l0.73,-1.44l-0.02,-0.91l0.8,-0.65l-0.03,-0.98l-0.93,-0.18l-0.6,0.71l-0.27,0.12l0.54,-1.29l-0.82,-0.62l-1.26,0.06l-0.86,0.78l-0.99,-0.68l2.02,-2.52l1.76,-1.49l1.64,-2.64l0.7,-0.57l0.88,-1.54l0.07,-0.56l-0.5,-0.93l0.76,-1.9l4.74,-7.65l4.72,-4.55l2.83,-0.54l19.59,-5.9l0.42,0.87l-0.06,2.0l1.03,1.2l0.48,3.78l2.33,3.2l-0.07,1.88l0.88,2.39l-0.58,1.07l0.04,3.4l0.72,0.88l1.35,2.72l0.2,1.08l0.62,0.83l0.16,3.89l0.56,0.83l0.54,0.07l0.53,-0.61l0.05,-0.86l0.33,-0.08l1.06,1.09l4.01,14.3l0.12,1.57l0.63,1.07l0.47,14.76l0.61,0.61l3.71,15.98l1.27,1.3l-2.79,3.18l0.03,0.55l1.76,1.57l-1.84,3.35l0.22,1.05l-1.03,0.46l-0.28,-4.19l-0.58,-2.19l-0.76,-1.59l-1.47,-1.06l-0.18,-1.11l-0.7,-0.09l-0.41,1.32l0.82,1.43l0.95,0.67l0.97,2.73l-13.79,-3.78l-1.29,-1.43l-2.39,0.27l-0.63,-0.41l-1.06,-0.13l-1.76,-1.86l-0.76,-2.29l0.11,-0.72l-0.36,-0.62l-0.55,-0.2l0.08,-0.45l-0.36,-0.42l-1.65,-0.64l-1.08,0.33l-0.76,-1.38l-1.71,-0.71l-34.56,9.14l-34.42,8.21l-1.15,-5.06Z", "name": "New York"}, "US-HI": {"path": "M289.66,630.16l0.24,-0.58l-0.28,-0.95l-1.77,-3.99l-1.27,-1.57l0.33,-1.12l-0.21,-0.54l0.85,-1.99l5.41,-5.78l1.31,-5.81l0.54,-0.71l0.68,-2.55l-0.22,-2.84l0.59,-2.08l1.42,-0.94l1.74,-0.09l1.46,-0.58l1.64,0.34l3.06,-1.35l1.66,-0.06l1.32,-1.24l0.16,-3.59l0.47,-1.44l1.22,-1.85l1.43,-0.62l2.82,2.78l-0.22,1.9l1.09,1.9l0.77,2.48l1.75,1.19l2.11,2.99l3.92,8.81l0.45,3.8l-2.56,3.79l0.13,0.55l0.78,0.49l1.33,0.25l0.29,0.8l-0.04,0.65l-0.96,1.27l-0.21,2.11l0.49,2.34l1.03,1.71l0.12,1.4l-0.47,0.55l-2.69,0.79l-1.58,-0.36l-2.8,0.47l-1.31,-0.44l-0.51,0.21l-1.06,-0.37l-1.2,0.05l-3.45,-1.14l-0.94,-1.07l-1.5,-0.76l-3.21,0.18l-1.16,-0.37l-4.07,-0.34l-2.13,0.37l-1.28,1.39l-2.16,0.4l-1.4,0.92l-1.91,0.26ZM303.88,566.35l1.79,-2.71l0.79,-2.13l-0.28,-0.9l-0.58,-0.46l-1.23,0.05l-1.53,-2.52l-0.18,-3.02l0.4,-1.13l1.1,-1.03l1.04,-0.61l0.47,0.15l0.7,-0.28l0.98,0.52l0.73,1.6l0.08,0.76l-0.37,0.8l0.1,2.69l1.16,0.25l2.04,1.18l1.83,0.14l1.99,1.89l0.52,3.71l0.6,0.38l0.06,1.23l2.27,3.06l-0.23,1.37l-0.81,0.9l-0.92,0.45l-0.91,-0.22l-0.93,0.35l-0.73,-0.45l-1.88,-0.26l-2.04,-1.47l-3.41,-0.57l-1.01,-1.16l-1.53,-0.89l-0.1,-1.64ZM273.91,515.43l-0.16,-0.42l0.72,-2.08l-0.24,-1.84l0.51,-1.27l-0.25,-1.82l1.0,-1.55l-0.24,-1.54l3.46,2.39l2.82,-0.18l1.22,-0.71l1.4,-0.13l1.04,0.49l0.19,1.24l-0.18,1.17l-0.48,0.58l-0.13,2.74l0.4,0.68l-0.02,0.68l-0.89,0.49l-0.74,1.42l0.57,2.71l0.62,0.46l0.74,-0.22l-0.39,0.92l0.28,1.01l-0.41,0.43l-0.21,1.15l0.58,1.52l-1.4,0.18l-0.26,-0.88l-2.91,-0.97l-0.01,-0.97l-0.8,-1.42l0.23,-0.9l-0.25,-0.63l-1.17,0.27l-0.49,-0.9l0.25,-0.39l1.09,0.08l0.49,-0.62l-0.41,-1.08l-0.7,-0.2l-0.32,-0.7l-0.54,0.32l-0.47,-0.68l-0.39,0.3l-0.01,2.25l-3.11,-1.39ZM285.47,518.52l0.17,-0.35l-0.09,-0.24l0.31,0.3l-0.39,0.29ZM246.37,461.62l2.26,-0.44l0.62,-0.59l0.66,-0.15l1.44,0.59l4.03,0.44l0.7,1.58l1.15,-0.06l1.17,1.29l0.97,0.23l0.75,1.01l0.23,1.77l-0.32,1.29l-0.64,0.74l-2.3,0.94l-1.66,2.26l-0.67,-0.23l-0.46,0.57l-3.24,0.14l-3.78,-4.33l-0.16,-2.14l-1.73,-2.53l0.13,-1.44l0.81,-0.95Z", "name": "Hawaii"}, "US-VT": {"path": "M805.89,73.65l25.93,-8.31l0.91,1.83l-0.71,2.38l-0.01,1.54l2.25,2.7l-0.5,0.59l0.28,1.12l-0.65,1.6l-1.33,1.51l-0.63,1.32l-1.72,0.73l-0.61,0.93l-0.09,0.98l0.97,3.7l-0.26,2.43l0.41,0.53l-0.58,2.1l0.18,2.17l-0.98,1.87l0.29,2.34l-0.52,1.54l1.49,5.38l-0.2,1.21l1.1,5.24l-0.57,0.85l0.14,2.29l0.61,1.24l1.51,1.06l-11.69,3.25l-4.48,-16.58l-1.73,-1.55l-0.9,0.26l-0.29,1.19l-0.12,-0.25l-0.15,-3.88l-0.69,-0.99l-0.15,-0.97l-1.4,-2.82l-0.63,-0.67l-0.02,-3.13l0.58,-1.15l-0.89,-2.54l0.06,-1.92l-0.4,-0.91l-1.57,-1.6l-0.39,-0.8l-0.45,-3.69l-1.04,-1.25l0.09,-1.87l-0.44,-0.99Z", "name": "Vermont"}, "US-NM": {"path": "M230.61,422.6l12.24,-122.38l25.75,2.35l26.19,1.96l26.22,1.52l25.84,1.07l-0.32,10.07l-0.75,0.39l-3.7,97.65l-32.56,-1.41l-33.71,-2.12l-0.44,0.75l0.53,2.31l0.44,1.25l1.0,0.77l-30.7,-2.59l-0.44,0.36l-0.85,9.43l-14.73,-1.4Z", "name": "New Mexico"}, "US-NC": {"path": "M678.54,321.43l0.92,0.16l1.52,-0.4l0.42,-0.39l0.52,-0.97l0.11,-2.67l1.34,-1.19l0.47,-1.04l2.25,-1.47l2.13,-0.54l0.76,0.17l1.32,-0.53l2.36,-2.52l0.78,-0.25l1.84,-2.28l1.49,-1.0l1.55,-0.2l1.14,-2.63l-0.29,-1.2l1.66,0.04l0.5,-1.63l0.93,-0.77l1.08,-0.77l0.52,1.49l1.07,0.32l1.34,-1.17l1.34,-2.62l2.49,-1.6l0.79,0.07l0.83,0.78l1.05,-0.21l0.84,-1.07l1.46,-4.14l1.08,-1.1l1.48,0.07l0.43,-0.31l-0.7,-1.24l0.39,-1.97l-0.43,-0.89l0.38,-1.23l7.44,-0.94l19.59,-3.57l37.27,-8.83l31.15,-8.25l0.41,1.18l3.57,3.14l1.01,1.48l-1.21,-0.97l-0.17,-0.62l-0.93,-0.38l-0.52,0.06l-0.23,0.65l0.67,0.52l0.6,1.52l-0.54,0.02l-0.92,-0.73l-2.32,-0.75l-0.41,-0.47l-0.55,0.14l-0.31,0.69l0.15,0.64l1.38,0.42l1.69,1.33l-1.1,0.66l-2.5,-1.14l-0.35,0.51l0.15,0.42l1.6,1.13l-4.09,-1.12l-0.46,0.15l0.02,0.48l0.61,0.69l1.7,0.78l-0.96,0.58l0.0,0.6l-0.43,0.52l-1.48,0.76l-0.9,-0.75l-0.6,0.23l-0.1,0.35l-0.2,-0.13l-1.33,-2.26l0.19,-2.6l-0.43,-0.47l-0.89,-0.21l-0.36,0.64l0.63,0.69l-0.43,0.98l-0.01,1.02l0.5,1.7l1.62,2.14l-0.3,1.26l0.49,0.29l2.97,-0.63l2.09,-1.51l0.27,0.01l0.38,0.78l0.76,-0.34l1.57,0.03l0.15,-0.72l-0.56,-0.3l1.28,-0.77l2.04,-0.49l-0.08,1.17l0.64,0.28l-0.59,0.87l0.9,1.16l-0.84,0.12l-0.18,0.67l1.39,0.43l0.26,0.92l-1.21,0.07l-0.18,0.66l0.67,0.57l1.25,-0.18l0.52,0.25l0.4,-0.38l0.16,-1.93l-0.77,-3.28l0.41,-0.49l0.57,0.42l0.93,0.04l0.28,-0.42l-0.29,-0.59l0.46,-0.58l1.74,1.8l0.01,1.39l0.62,0.88l-0.53,0.19l-0.25,0.47l0.91,1.12l-0.08,0.35l-0.42,0.55l-0.78,0.1l-0.91,-0.83l-0.31,0.34l0.14,1.24l-1.07,1.62l0.2,0.55l-0.32,0.22l-0.15,0.98l-0.73,0.55l0.1,0.9l-0.89,0.97l-1.06,0.22l-0.6,-0.36l-0.51,0.52l-0.94,-0.79l-0.86,0.12l-0.4,-0.81l-0.59,-0.2l-0.51,0.38l0.09,0.93l-0.52,0.23l-1.42,-1.21l1.3,-0.41l0.23,-0.88l-0.57,-0.42l-2.03,0.34l-1.13,1.02l0.3,0.67l0.44,0.15l-0.05,0.37l0.16,0.44l0.34,0.24l-0.03,0.12l-0.58,-0.33l-1.69,0.85l-1.13,-0.41l-1.45,0.08l-3.33,-0.64l0.44,1.07l0.98,0.43l0.36,0.63l1.51,-0.23l4.05,0.95l3.52,0.06l0.47,0.41l-0.05,0.51l-0.99,0.07l-0.24,0.72l-1.61,1.45l0.33,0.58l1.85,-0.03l-2.54,3.5l-1.68,0.07l-1.61,-0.94l-0.9,-0.17l-1.22,-0.99l-1.12,0.09l0.08,0.47l1.05,1.11l2.35,2.03l2.69,0.22l1.32,0.46l1.69,-2.16l0.52,0.45l1.18,0.31l0.39,-0.58l-0.55,-0.87l0.87,0.14l0.2,0.56l0.66,0.22l1.62,-1.2l-0.17,0.59l0.29,0.57l-0.29,0.38l-0.43,-0.2l-0.4,0.38l0.04,0.89l-0.96,1.72l0.02,0.78l-0.72,-0.06l-0.07,-0.73l-1.13,-0.58l-0.41,0.48l0.29,1.46l-0.35,-0.92l-0.84,-0.35l-1.21,1.08l-0.21,0.52l0.25,0.26l-2.03,0.35l-2.75,1.86l-0.68,-1.01l-0.75,-0.29l-0.36,0.49l0.44,1.24l-0.57,-0.01l-0.09,0.82l-0.93,1.72l-0.91,0.85l-0.59,-0.25l0.48,-0.69l-0.03,-0.77l-1.07,-0.9l-0.09,-0.52l-1.69,-0.38l-0.15,0.47l0.44,1.14l0.2,0.32l0.59,0.07l0.3,0.59l-0.88,0.38l-0.08,0.71l0.66,0.62l0.77,0.16l-0.0,0.36l-2.12,1.68l-1.9,2.65l-1.98,4.29l-0.33,2.11l0.13,1.34l-0.16,-1.03l-1.02,-1.57l-0.55,-0.16l-0.29,0.48l1.21,3.9l-0.62,2.26l-3.92,0.24l-1.43,0.67l-0.36,-0.51l-0.58,-0.17l-0.53,1.07l-1.9,1.16l-0.61,-0.01l-23.45,-14.89l-1.05,-0.01l-18.73,3.7l-0.67,-2.73l-3.28,-2.77l-0.46,0.08l-1.23,1.32l-0.02,-1.27l-0.82,-0.52l-22.89,3.59l-0.64,-0.26l-0.62,0.46l-0.25,0.65l-3.99,1.95l-0.89,1.23l-1.02,0.09l-4.79,2.68l-21.02,4.1l-0.36,-4.48l0.71,-0.95ZM818.99,269.92l0.19,0.35l0.24,0.37l-0.46,-0.4l0.02,-0.32ZM809.62,288.62l0.21,0.33l-0.17,-0.08l-0.04,-0.25ZM817.51,297.28l0.15,-0.36l0.16,0.07l-0.13,0.28l-0.18,0.02ZM814.92,297.28l-0.06,-0.28l-0.03,-0.11l0.3,0.25l-0.21,0.13Z", "name": "North Carolina"}, "US-ND": {"path": "M439.14,45.59l2.07,7.04l-0.73,2.58l0.57,2.4l-0.27,1.19l0.48,2.03l0.02,3.32l1.42,4.0l0.45,0.55l-0.08,0.99l0.39,1.54l0.62,0.75l1.49,3.79l-0.05,3.94l0.42,0.71l0.51,8.42l0.51,1.54l0.51,0.25l-0.47,2.66l0.36,1.64l-0.14,1.76l0.69,1.11l0.2,2.17l0.49,1.14l1.81,2.57l0.16,2.21l0.51,1.08l0.17,1.4l-0.24,1.36l0.29,1.75l-27.88,0.76l-28.37,0.2l-28.37,-0.38l-28.47,-0.97l2.91,-66.2l23.02,0.82l25.48,0.43l25.49,-0.06l24.02,-0.51Z", "name": "North Dakota"}, "US-NE": {"path": "M423.34,177.3l3.93,2.68l3.94,1.88l1.33,-0.22l0.51,-0.47l0.36,-1.07l0.48,-0.2l2.5,0.33l1.32,-0.47l1.59,0.24l3.45,-0.65l2.38,1.96l1.41,0.14l1.55,0.76l1.45,0.08l0.89,1.09l1.48,0.17l-0.06,0.97l1.69,2.06l3.32,0.59l-0.02,2.52l1.14,1.92l0.01,2.27l1.16,1.06l0.34,1.69l1.74,1.44l0.07,1.85l1.51,2.07l-0.49,2.3l0.44,3.05l0.52,0.54l0.93,-0.2l-0.03,1.23l1.21,0.49l-0.4,2.32l0.21,0.45l1.11,0.39l-0.59,0.75l-0.09,1.0l0.13,0.59l0.82,0.49l0.16,1.42l-0.26,0.91l0.26,1.26l0.55,0.6l0.3,1.89l-0.22,1.31l0.23,0.71l-0.57,0.9l0.03,0.78l0.45,0.87l1.23,0.62l0.26,2.47l1.1,0.5l0.03,0.78l1.19,2.7l-0.23,0.95l1.16,0.21l0.8,0.98l1.1,0.23l-0.15,0.95l1.31,1.64l-0.21,1.1l0.49,0.89l-26.2,1.1l-27.91,0.67l-27.92,0.15l-27.96,-0.37l0.47,-21.33l-0.39,-0.41l-32.43,-1.09l1.91,-42.7l43.42,1.28l44.73,-0.05Z", "name": "Nebraska"}, "US-LA": {"path": "M510.31,412.96l-1.38,-21.63l25.75,-1.93l25.95,-2.35l0.35,0.82l1.49,0.64l-0.92,1.34l-0.25,2.12l0.5,0.72l1.18,0.3l-1.21,0.47l-0.45,0.78l0.46,1.35l1.05,0.83l0.08,2.13l0.47,0.54l1.52,0.73l0.45,1.04l1.43,0.42l-0.87,1.22l-0.85,2.34l-0.76,0.05l-0.52,0.51l-0.02,0.73l0.63,0.72l-0.21,1.16l-1.35,0.96l-1.08,1.89l-1.38,0.68l-0.68,0.83l-0.79,2.41l-0.24,3.51l-1.55,1.75l0.13,1.2l0.63,0.95l-0.35,2.37l-1.62,0.3l-0.59,0.57l0.29,0.97l0.65,0.59l-0.25,1.41l0.99,1.51l-1.18,1.19l-0.08,0.45l0.4,0.23l6.22,-0.58l29.4,-3.07l-0.67,3.47l-0.52,1.02l-0.19,2.25l0.7,0.98l-0.09,0.66l0.61,1.0l1.32,0.7l1.23,1.42l0.15,0.88l0.9,1.38l0.14,1.05l1.13,1.84l-1.87,0.4l-0.38,-0.08l-0.02,-0.56l-0.54,-0.57l-1.29,0.28l-1.19,-0.59l-1.52,0.18l-0.62,-0.98l-1.25,-0.86l-2.85,-0.46l-1.25,0.64l-1.39,2.31l-1.3,1.43l-0.41,0.92l0.07,1.2l0.56,0.89l0.83,0.56l4.28,0.81l3.36,-1.02l1.33,-1.2l0.68,-1.21l0.35,0.59l1.09,0.42l0.59,-0.41l0.81,0.02l0.51,-0.47l-0.76,1.23l-1.13,-0.11l-0.58,0.32l-0.38,0.62l0.0,0.84l0.78,1.22l1.49,-0.03l0.66,0.9l1.11,0.48l1.45,-0.67l0.46,-1.11l-0.02,-1.37l0.93,-0.58l0.42,-1.0l0.24,0.05l0.11,1.17l-0.24,0.25l0.19,0.57l0.43,0.15l-0.07,0.75l1.35,1.08l0.35,-0.17l-0.48,0.6l0.19,0.63l-0.24,0.18l-0.85,-0.72l-0.71,-0.08l-1.0,1.9l-0.85,0.15l-0.46,0.54l0.17,1.2l-1.03,-0.48l-1.01,0.07l0.05,0.46l1.16,1.07l-1.18,-0.14l-0.92,0.61l0.69,0.43l1.28,2.05l2.76,0.96l-0.08,1.21l0.34,0.4l2.08,-0.33l0.78,0.17l0.18,0.53l0.74,0.32l1.36,-0.35l0.54,0.78l1.08,-0.47l1.15,0.74l0.14,0.3l-0.41,0.63l1.55,0.86l-0.39,0.66l0.39,0.58l-0.18,0.63l-0.95,1.52l-1.32,-1.57l-0.68,0.34l0.1,0.67l-0.39,0.13l0.4,-1.91l-1.33,-0.76l-0.5,0.51l0.2,1.18l-0.55,0.46l-0.27,-1.03l-0.58,-0.25l-0.91,-1.28l0.03,-0.77l-0.97,-0.13l-0.47,0.51l-1.42,-0.16l-0.75,-0.77l-2.33,-0.08l0.38,-0.87l-0.13,-0.66l-0.64,-0.69l-0.92,0.05l0.09,-0.97l-0.37,-0.36l-0.91,-0.03l-0.22,0.6l-0.86,-0.38l-0.48,0.27l-2.64,-1.26l-1.25,-0.02l-0.68,-0.64l-0.61,0.19l-0.3,0.57l-0.05,1.26l1.74,0.94l1.69,0.34l-0.15,0.92l0.29,0.4l-0.34,0.35l0.23,0.69l-0.76,0.95l-0.02,0.67l0.82,0.97l-0.96,1.45l-1.34,0.95l-0.78,-1.16l0.21,-1.51l-0.35,-0.93l-0.49,-0.18l-0.4,0.36l-1.16,-1.08l-0.6,0.43l-0.77,-1.06l-0.63,-0.2l-0.63,1.34l-0.86,0.26l-0.89,-0.53l-0.85,0.54l-0.1,0.62l0.49,0.41l-0.68,0.57l-0.13,1.46l-0.46,0.13l-0.4,0.85l-0.93,0.09l-0.12,-0.69l-1.61,-0.4l-0.76,0.99l-1.94,-0.94l-0.3,-0.54l-1.0,0.01l-0.35,0.61l-1.18,-0.51l0.43,-0.41l-0.0,-1.47l-0.39,-0.57l-1.92,-1.2l-0.08,-0.54l-0.84,-0.71l-0.1,-0.92l0.73,-1.16l-0.35,-1.14l-0.88,-0.19l-0.34,0.57l0.16,0.43l-0.58,0.82l0.04,0.92l-1.82,-0.4l0.07,-0.39l-0.47,-0.54l-1.98,0.77l-0.71,-2.23l-1.33,0.24l-0.19,-2.14l-1.31,-0.35l-1.9,0.3l-1.09,0.66l-0.22,-0.71l0.85,-0.27l-0.06,-0.8l-0.61,-0.58l-1.04,-0.1l-0.86,0.43l-0.95,-0.14l-0.4,0.81l-2.01,1.12l-0.64,-0.31l-1.29,0.72l0.54,1.37l0.81,0.31l1.06,1.56l-1.28,0.37l-1.83,1.07l-7.69,-0.89l-6.75,-2.3l-3.48,-0.65l-6.9,0.72l-3.43,0.81l-1.58,0.74l-0.92,-1.42l1.21,-0.46l0.79,-0.99l0.26,-2.31l-0.6,-0.84l1.15,-1.63l0.23,-1.6l-0.5,-1.84l0.07,-1.46l-0.67,-0.7l-0.22,-1.05l0.83,-2.22l-0.64,-1.95l0.77,-0.85l0.29,-1.49l0.79,-0.94l0.78,-2.84l-0.19,-1.42l0.58,-0.98l-0.76,-1.33l0.84,-0.39l0.19,-0.44l-0.9,-1.35l0.02,-2.13l-1.08,-0.23l-0.58,-1.57l-0.92,-0.84l0.28,-1.27l-0.82,-0.75l-0.33,-0.95l-0.65,-0.34l0.22,-0.98l-1.17,-0.57l-0.81,-0.93l0.15,-2.45l-0.69,-1.93l-1.34,-1.97l-2.65,-2.19ZM550.68,462.64l0.02,-0.01l0.0,0.01l-0.02,0.0ZM609.66,467.12l-0.03,-0.03l-0.09,-0.04l0.15,-0.01l-0.03,0.09ZM609.67,465.5l-0.02,-0.02l0.04,-0.01l-0.02,0.03ZM568.94,468.85l-2.02,-0.42l-0.67,-0.5l0.74,-0.44l0.35,-0.77l0.4,0.49l0.84,0.2l-0.14,0.62l0.51,0.81Z", "name": "Louisiana"}, "US-SD": {"path": "M337.09,132.35l0.3,-0.53l0.79,-19.92l28.48,0.97l28.39,0.38l28.39,-0.2l27.76,-0.76l-0.17,1.71l-0.72,1.71l-2.9,2.47l-0.41,1.28l1.59,2.13l1.06,2.06l0.55,0.36l1.74,0.24l1.02,0.84l0.58,1.02l1.51,38.64l-1.84,0.09l-0.42,0.56l0.24,1.42l0.88,1.12l0.01,1.44l-0.65,0.36l0.17,1.47l0.48,0.43l1.09,0.04l0.34,1.66l-0.16,0.9l-0.62,0.82l0.02,1.72l-0.68,2.42l-0.49,0.44l-0.67,1.87l0.5,1.1l1.33,1.06l-0.16,0.61l0.64,0.65l0.36,1.13l-1.66,-0.28l-0.34,-0.92l-0.85,-0.72l0.19,-0.6l-0.29,-0.59l-1.58,-0.22l-1.03,-1.16l-1.57,-0.11l-1.51,-0.74l-1.34,-0.11l-2.39,-1.97l-3.79,0.6l-1.65,-0.24l-1.19,0.46l-2.62,-0.32l-0.98,0.48l-0.76,1.43l-0.72,0.05l-3.67,-1.8l-4.13,-2.77l-44.89,0.05l-43.39,-1.27l1.86,-42.92Z", "name": "South Dakota"}, "US-DC": {"path": "M784.68,218.28l-0.46,-0.63l-1.55,-0.63l0.57,-1.0l2.04,1.2l-0.61,1.05Z", "name": "District of Columbia"}, "US-DE": {"path": "M799.88,195.02l0.47,-1.55l0.91,-1.11l1.73,-0.73l1.11,0.04l-0.32,0.54l-0.07,1.36l-0.46,1.08l-0.6,0.54l-0.08,0.77l0.13,0.61l1.03,0.82l0.13,2.27l4.01,3.21l1.16,3.91l1.97,1.62l0.48,1.23l3.19,2.18l1.35,-0.1l0.49,1.17l-0.59,0.27l-0.3,0.67l0.04,0.75l0.35,0.18l-0.81,0.57l-0.07,1.2l0.67,0.2l0.85,-0.73l0.72,0.33l0.3,-0.21l0.6,1.51l-9.84,2.76l-8.56,-25.36Z", "name": "Delaware"}, "US-FL": {"path": "M632.37,423.03l47.44,-7.21l1.55,1.89l0.89,2.71l1.48,0.99l49.06,-5.55l1.04,1.38l0.04,1.09l0.56,1.05l0.87,0.49l1.83,-0.32l0.85,-0.76l-0.18,-4.58l-1.0,-1.48l-0.24,-1.77l0.27,-0.74l0.62,-0.31l0.11,-0.7l5.64,0.9l4.05,-0.2l0.15,1.25l-0.76,-0.12l-0.32,0.43l0.26,1.54l2.14,1.8l0.23,1.01l0.42,0.37l0.31,1.93l5.44,11.5l1.85,3.07l7.28,10.24l0.63,0.35l6.95,7.56l-0.5,-0.03l-0.27,0.62l-1.37,-0.01l-0.35,-0.66l0.37,-1.4l-0.16,-0.56l-2.33,-0.91l-0.46,0.53l1.04,2.82l0.79,0.98l2.21,4.81l10.15,13.83l1.42,3.15l3.77,5.42l-1.4,-0.35l-0.42,0.74l0.81,0.66l0.86,0.24l0.56,-0.22l1.49,0.95l2.1,3.1l-0.5,0.37l-0.11,0.53l1.17,0.53l0.92,1.87l-0.07,1.08l0.6,0.97l0.65,2.7l-0.26,0.77l1.06,9.2l-0.3,1.1l0.47,0.69l0.55,3.19l-0.81,1.5l0.1,2.3l-0.84,0.77l-0.19,1.85l-0.47,0.87l0.24,1.51l-0.28,1.8l0.56,1.78l0.48,0.24l-1.15,1.88l-0.37,1.33l-0.95,0.25l-0.54,-0.23l-1.38,0.47l-0.34,1.1l-0.9,0.32l-0.16,0.6l-0.86,0.7l-1.45,0.15l-0.28,-0.33l-1.25,-0.09l-0.89,1.09l-3.19,1.18l-1.08,-0.61l-0.73,-1.08l0.04,-1.87l1.02,0.86l1.68,0.48l0.26,0.65l0.53,0.07l1.36,-0.75l0.19,-0.71l-0.27,-0.64l-1.61,-1.13l-2.43,-0.26l-0.92,-0.47l-0.89,-1.72l-0.91,-0.74l0.22,-1.01l-0.48,-0.28l-0.53,0.16l-1.43,-2.59l-0.44,-0.29l-0.65,0.08l-0.46,-0.63l0.22,-0.91l-0.72,-0.66l-1.23,-0.61l-1.08,-0.08l-0.77,-0.55l-0.58,0.19l-2.84,-0.59l-0.51,0.66l0.25,-0.96l-0.47,-0.42l-0.88,0.13l-0.27,-0.74l-0.9,-0.67l-0.63,-1.45l-0.56,-0.1l-0.77,-3.03l-0.79,-1.0l-0.18,-1.56l-0.45,-0.85l-0.73,-0.91l-0.49,-0.15l-0.1,0.95l-1.33,-0.26l1.08,-1.35l0.29,-0.76l-0.13,-0.64l0.86,-1.51l0.65,-0.35l0.27,-0.85l-0.62,-0.38l-1.42,0.96l-1.02,1.71l-0.26,1.83l-1.38,0.37l-0.22,-1.36l-0.81,-1.36l-0.32,-4.12l-0.88,-0.61l1.64,-1.37l0.21,-0.99l-0.59,-0.41l-3.06,1.98l-0.76,-0.67l-0.4,0.27l-1.29,-0.9l-0.37,0.75l1.15,1.1l0.53,0.1l1.3,2.05l-1.05,0.25l-1.45,-0.38l-0.87,-1.63l-1.14,-0.6l-1.99,-2.59l-1.07,-2.32l-1.31,-0.89l0.1,-0.89l-1.0,-1.82l-1.8,-0.98l0.08,-0.69l0.99,-0.41l-0.36,-0.5l0.44,-0.75l-0.4,-0.36l0.4,-1.23l2.45,-4.56l-1.08,-2.44l-0.69,-0.46l-0.92,0.43l-0.27,0.94l0.31,1.21l-0.25,0.04l-0.76,-2.47l-1.0,-0.27l-1.2,-0.88l-1.53,-0.3l0.32,1.97l-0.48,0.63l0.27,0.59l2.24,0.56l0.26,0.99l-0.35,2.51l-0.33,-0.6l-0.8,-0.21l-2.17,-1.54l-0.42,0.21l-0.3,-0.64l0.58,-2.14l0.04,-3.02l-0.69,-1.99l0.42,-0.52l0.47,-1.94l-0.25,-0.54l0.63,-3.08l-0.42,-5.47l-0.72,-1.57l0.36,-0.47l-0.49,-2.2l-2.13,-1.32l-0.05,-0.53l-0.56,-0.42l-0.11,-1.02l-0.93,-0.73l-0.56,-1.52l-0.64,-0.24l-1.45,0.33l-1.03,-0.19l-1.58,0.56l-1.17,-1.75l-1.52,-0.47l-0.19,-0.6l-1.37,-1.51l-0.88,-0.58l-0.62,0.08l-1.54,-1.16l-0.81,-0.21l-0.53,-2.76l-3.09,-1.12l-0.66,-0.59l-0.54,-1.23l-2.18,-1.92l-2.21,-1.07l-1.46,-0.11l-3.47,-1.66l-2.86,1.01l-1.01,-0.4l-1.04,0.43l-0.35,0.69l-1.34,0.69l-0.5,0.71l0.04,0.65l-0.75,-0.22l-0.59,0.6l0.68,0.93l1.52,0.06l0.42,0.21l-3.05,0.26l-1.58,1.53l-0.91,0.46l-1.29,1.58l-1.56,1.04l-0.33,0.14l0.2,-0.49l-0.26,-0.53l-0.67,-0.04l-2.07,2.27l-2.21,0.25l-2.12,1.08l-0.79,0.04l-0.29,-2.04l-1.74,-2.23l-2.23,-0.99l-0.18,-0.41l-2.55,-1.49l2.84,1.31l1.21,-0.76l-0.01,-0.74l-1.33,-0.33l-0.36,0.57l-0.22,-1.03l-0.34,-0.1l0.12,-0.52l-0.49,-0.33l-1.4,0.62l-2.32,-0.74l0.65,-1.09l0.83,-0.11l1.03,-1.46l-0.92,-0.95l-0.46,0.13l-0.49,1.02l-0.45,-0.03l-0.81,0.57l-0.73,-0.9l-0.7,0.1l-0.17,0.38l-1.34,0.74l-0.14,0.68l0.29,0.46l-3.99,-1.33l-5.08,-0.68l0.12,-0.24l1.28,0.29l0.61,-0.53l2.12,0.37l0.22,-0.78l-0.95,-1.02l0.08,-0.7l-0.63,-0.28l-0.5,0.32l-0.29,-0.47l-1.91,0.2l-2.26,1.12l0.29,-0.64l-0.41,-0.58l-0.96,0.36l-0.59,-0.25l-0.22,0.44l0.2,0.71l-1.46,0.81l-0.39,0.64l-5.21,1.01l0.31,-0.52l-0.4,-0.52l-1.36,-0.27l-0.73,-0.53l0.69,-0.54l0.0,-0.78l-0.68,-0.12l-0.82,-0.66l-0.46,0.11l0.15,0.76l-0.41,1.78l-1.06,-1.39l-0.7,-0.45l-0.55,0.07l-0.3,0.72l0.83,1.77l-0.25,0.8l-1.39,1.0l-0.05,1.04l-0.6,0.23l-0.17,0.57l-1.5,0.57l0.28,-0.66l-0.22,-0.45l1.14,-1.04l0.07,-0.74l-0.4,-0.58l-1.19,-0.23l-0.42,-0.84l0.3,-1.71l-0.19,-1.61l-2.19,-1.1l-2.42,-2.45l0.31,-1.45l-0.16,-1.04ZM646.6,433.39l-0.95,0.27l0.41,-0.45l0.54,0.17ZM667.51,434.81l0.99,-0.29l0.36,0.31l0.1,0.73l-1.44,-0.75ZM773.83,453.41l0.44,0.57l-0.43,0.77l-0.01,-1.35Z", "name": "Florida"}, "US-CT": {"path": "M824.61,156.52l2.8,-3.23l-0.07,-0.55l-1.32,-1.21l-3.64,-15.64l9.8,-2.55l0.6,0.44l0.65,-0.27l0.22,-0.58l14.13,-4.2l3.29,10.01l0.48,1.92l-0.03,1.68l-1.66,0.34l-0.91,0.82l-0.7,-0.35l-0.49,0.11l-0.18,0.91l-1.15,0.09l-1.26,1.27l-0.62,-0.12l-0.57,-0.99l-0.89,-0.07l-0.2,0.68l0.76,0.62l0.09,0.53l-0.89,-0.0l-1.01,0.88l-1.65,0.1l-1.14,0.95l-1.44,0.15l-1.2,0.94l-0.66,-0.97l-0.6,0.12l-0.99,2.44l-1.06,0.62l-0.24,1.01l-0.77,-0.25l-0.95,0.57l-0.08,0.85l-1.72,1.0l-1.92,2.28l-1.18,0.48l-0.24,0.39l-1.41,-1.19Z", "name": "Connecticut"}, "US-WA": {"path": "M39.74,56.58l0.38,-1.08l0.92,0.66l0.56,-0.13l0.55,-0.65l0.48,0.67l0.71,0.0l0.18,-0.77l-0.96,-1.49l0.86,-0.82l-0.07,-1.37l0.49,-0.38l-0.09,-1.04l0.81,-0.26l0.04,0.51l0.47,0.42l0.96,-0.3l-0.08,-0.68l-1.41,-1.85l-1.83,-0.12l-0.16,0.32l-0.77,-0.83l0.28,-1.64l0.65,0.54l0.52,-0.07l0.3,-0.56l-0.17,-0.69l3.35,-0.49l0.25,-0.67l-2.57,-1.32l-0.03,-0.8l-0.66,-0.58l-1.3,-0.33l0.44,-4.77l-0.48,-1.31l0.26,-0.72l-0.51,-0.49l0.6,-3.97l0.11,-4.43l-0.54,-1.04l-0.03,-0.99l-1.52,-2.38l0.4,-4.29l-0.19,-1.32l0.8,-0.8l0.05,-0.72l0.99,-1.45l-0.58,-1.46l1.03,0.82l0.44,0.01l3.29,3.38l0.99,0.36l2.14,2.46l3.7,1.54l1.2,0.08l0.78,0.72l0.67,0.31l0.6,-0.14l1.55,1.09l1.48,0.49l1.28,0.29l1.22,-0.61l0.52,0.31l0.45,0.73l-0.07,1.25l0.54,0.75l0.81,-0.23l0.08,-0.77l0.44,0.04l0.61,1.42l-0.41,0.58l0.34,0.5l0.56,-0.03l0.74,-0.84l-0.35,-1.73l1.05,-0.23l-0.46,0.23l-0.22,0.69l1.21,4.49l-0.47,0.1l-1.69,1.73l0.24,-1.3l-0.22,-0.41l-1.32,0.3l-0.39,0.81l0.08,0.96l-1.4,1.71l-2.0,1.38l-1.08,1.42l-0.97,0.69l-1.12,1.67l-0.07,0.71l0.61,0.61l0.95,0.12l2.78,-0.46l1.23,-0.58l-0.02,-0.7l-0.64,-0.23l-2.95,0.77l-0.34,-0.31l3.28,-3.44l3.07,-0.87l0.91,-1.52l1.75,-1.54l0.52,0.57l0.54,-0.18l0.25,-1.83l-0.1,2.29l0.25,0.92l-0.98,-0.22l-0.65,0.77l-0.4,-0.74l-0.53,-0.2l-0.4,0.64l0.29,2.37l-0.19,-1.08l-0.67,-0.22l-0.47,0.69l-0.07,0.76l0.46,0.68l-0.64,0.59l-0.0,0.45l0.41,0.17l1.68,-0.56l0.23,1.1l-1.1,1.8l-0.1,1.06l-0.84,0.7l0.12,1.02l-0.84,-0.69l1.14,-1.45l-0.22,-0.97l-1.98,1.07l-0.39,0.64l-0.03,-2.13l-0.52,0.01l-1.05,1.6l-1.27,0.53l-1.16,1.87l-1.51,0.29l-0.47,0.43l-0.22,1.19l1.11,-0.03l-0.26,0.36l0.26,0.38l0.92,0.03l0.05,0.68l0.53,0.47l0.52,-0.27l0.37,-1.77l0.14,0.42l0.83,-0.14l1.09,1.5l1.32,-0.61l1.66,-1.47l1.0,-1.57l0.62,0.79l0.73,0.14l0.44,-0.22l-0.05,-0.87l1.56,-0.54l0.36,-0.94l-0.32,-1.28l0.24,-1.2l-0.16,-1.37l0.83,0.21l0.31,-0.92l-0.18,-0.76l-0.71,-0.65l0.91,-1.14l0.1,-1.77l1.25,-1.25l0.63,-1.38l1.62,-0.49l0.79,-1.15l-0.44,-0.67l-0.51,-0.02l-0.84,-1.32l0.19,-2.12l-0.25,-0.88l0.5,-0.8l0.07,-0.84l-1.13,-1.76l-0.62,-0.41l-0.16,-0.67l0.19,-0.51l0.59,0.24l0.53,-0.33l0.26,-1.83l0.8,-0.24l0.31,-1.01l-0.57,-2.36l0.45,-0.55l-0.02,-0.86l-0.94,-0.9l-0.95,0.3l-1.05,-2.71l0.96,-1.87l41.1,9.79l38.76,7.97l-10.72,56.03l1.01,3.02l0.12,2.01l-1.02,1.3l0.71,1.89l-31.12,-6.19l-1.67,0.78l-7.23,-1.08l-1.69,0.9l-4.19,-0.16l-3.18,0.42l-1.65,0.73l-0.88,-0.27l-1.2,0.29l-1.5,-0.24l-2.42,-0.97l-0.91,0.45l-3.45,0.47l-2.1,-0.73l-1.65,0.28l-0.3,-1.37l-1.08,-0.89l-4.33,-1.5l-2.32,-0.14l-1.14,-0.52l-1.27,0.2l-1.9,0.84l-4.5,0.53l-2.25,-1.04l-1.6,-1.17l-1.84,-0.53l-0.62,-0.82l0.72,-6.82l-0.45,-0.95l-0.19,-1.91l-0.96,-1.36l-1.94,-1.7l-1.58,-0.24l-1.32,0.27l-1.91,-3.28l-2.07,-0.25l-0.56,-0.31l-0.09,-0.53l-0.54,-0.48l-1.22,0.27l-0.8,-0.16l-1.0,0.51l-1.01,-1.79l-0.92,-0.24ZM63.39,41.41l0.15,0.75l-0.42,0.47l0.01,-0.91l0.26,-0.31ZM73.09,21.84l-0.64,0.89l-0.16,0.52l0.21,-1.41l0.59,-0.0ZM73.02,17.03l-0.1,-0.06l0.06,-0.05l0.05,0.11ZM72.25,16.87l-0.78,0.39l0.38,-0.69l-0.06,-0.62l0.23,-0.07l0.23,1.0ZM58.99,44.09l0.13,-0.06l-0.02,0.02l-0.11,0.04Z", "name": "Washington"}, "US-KS": {"path": "M478.84,241.98l0.44,0.62l0.76,0.17l1.05,0.79l2.2,-1.07l-0.0,0.74l1.08,0.77l0.23,1.42l-0.95,-0.15l-0.59,0.31l-0.17,0.95l-1.15,1.36l-0.06,1.12l-0.79,0.5l0.04,0.63l1.57,2.07l2.01,1.46l0.2,1.11l0.42,0.84l0.75,0.55l0.33,1.09l1.9,0.89l1.54,0.25l2.74,46.05l-31.67,1.55l-32.09,0.92l-32.1,0.27l-32.17,-0.39l1.25,-64.41l27.97,0.37l27.93,-0.15l27.92,-0.67l27.75,-1.17l1.65,1.2Z", "name": "Kansas"}, "US-WI": {"path": "M510.81,127.46l0.4,-0.27l0.27,-0.9l-0.45,-1.48l0.03,-1.91l0.69,-1.16l0.52,-2.25l-1.62,-2.9l-0.83,-0.35l-1.28,-0.0l-0.22,-2.32l1.66,-2.27l-0.05,-0.78l0.76,-1.55l1.95,-1.09l0.48,-0.75l0.97,-0.25l0.45,-0.76l1.16,-0.14l1.03,-1.57l-1.02,-12.16l1.03,-0.35l0.22,-1.1l0.73,-0.98l0.78,0.7l1.68,0.64l2.61,-0.58l3.27,-1.59l2.64,-0.84l2.2,-2.14l0.31,0.29l1.39,-0.11l1.24,-1.49l0.78,-0.58l1.04,-0.1l0.4,-0.53l1.08,1.0l-0.47,1.7l-0.67,1.02l0.24,1.62l-1.19,2.23l0.64,0.65l2.49,-1.1l0.72,-0.87l2.16,1.21l2.34,0.47l0.44,0.54l0.86,-0.13l1.6,0.69l2.25,3.55l15.48,2.46l4.66,1.94l1.67,-0.17l1.63,0.41l1.33,-0.6l3.17,0.69l2.18,0.08l0.86,0.4l0.56,0.89l-0.41,1.1l0.41,0.77l3.4,0.61l1.41,1.12l-0.15,0.71l0.6,1.11l-0.35,0.81l0.44,1.25l-0.77,1.25l-0.02,1.76l0.91,0.63l1.38,-0.26l1.02,-0.73l0.2,0.25l-0.78,2.44l0.05,1.31l1.32,1.45l0.84,0.34l-0.23,2.01l-2.41,1.21l-0.51,0.78l0.04,1.25l-1.59,3.49l-0.38,3.49l1.12,0.82l0.91,-0.05l0.5,-0.37l0.49,-1.36l1.81,-1.47l0.65,-2.53l1.05,-1.7l0.59,0.17l0.58,-0.71l0.87,-0.4l1.13,1.11l0.59,0.19l-0.26,2.17l-1.17,2.85l-0.54,5.56l0.23,1.1l0.8,0.92l0.07,0.52l-0.5,0.98l-1.3,1.35l-0.84,3.87l0.16,2.55l0.72,1.19l0.07,1.23l-1.06,3.21l0.13,2.09l-0.72,2.1l-0.27,2.45l0.6,2.0l-0.03,1.31l0.49,0.53l-0.2,1.69l0.92,0.77l0.55,2.41l1.21,1.51l0.09,1.67l-0.32,1.43l0.49,2.91l-44.25,4.85l-0.2,-0.78l-1.57,-2.16l-4.95,-0.8l-1.06,-1.32l-0.37,-1.67l-0.91,-1.19l-0.88,-4.84l1.03,-2.6l-0.09,-0.98l-0.72,-0.78l-1.44,-0.47l-0.72,-1.74l-0.49,-5.97l-0.71,-1.39l-0.53,-2.54l-1.16,-0.6l-1.1,-1.55l-0.93,-0.11l-1.17,-0.74l-1.71,0.09l-2.68,-1.77l-2.31,-3.47l-2.64,-2.08l-2.94,-0.52l-0.73,-1.23l-1.13,-0.99l-3.12,-0.43l-3.54,-2.71l0.45,-1.24l-0.12,-1.61l0.25,-0.81l-0.89,-3.1Z", "name": "Wisconsin"}, "US-OR": {"path": "M11.16,140.88l0.67,-3.89l1.34,-2.47l0.24,-1.21l-0.0,-1.25l-0.46,-0.66l-0.13,-1.12l-0.42,-0.32l-0.1,-1.83l2.76,-3.56l2.24,-4.66l0.11,-1.09l0.43,-0.26l-0.0,0.79l0.73,0.11l0.43,-1.09l0.89,-0.82l0.22,0.94l1.39,0.29l-0.48,-2.63l-0.92,0.07l2.13,-3.75l1.12,-0.75l0.8,0.41l0.55,-0.33l-0.65,-1.36l-0.6,-0.31l1.75,-4.34l0.42,-0.38l0.05,-0.95l1.8,-5.44l0.99,-1.96l0.4,0.34l0.67,-0.28l-0.11,-0.97l-0.56,-0.32l0.99,-2.72l0.81,0.18l0.24,-0.45l-0.15,-0.52l-0.51,-0.28l0.57,-2.84l1.6,-2.68l0.86,-3.0l1.16,-1.74l1.01,-3.08l-0.07,-1.04l1.22,-1.09l0.05,-0.6l-0.46,-0.66l0.15,-0.52l0.5,0.64l0.45,0.06l0.4,-0.62l0.19,-1.39l-0.73,-0.73l0.52,-1.19l1.29,-0.77l0.06,-0.46l-0.86,-0.51l-0.25,-1.11l0.88,-2.17l-0.04,-1.44l0.93,-0.58l0.41,-0.85l0.12,-3.76l0.48,0.87l0.89,0.42l-0.05,0.91l0.55,0.54l0.44,-0.81l0.39,-0.13l-0.25,-0.99l1.11,0.86l1.53,0.02l1.46,-0.67l1.41,2.38l1.98,0.81l1.4,-0.65l0.91,0.07l1.7,1.53l0.76,1.05l0.19,1.9l0.42,0.78l-0.05,2.05l-0.4,1.24l0.18,0.93l-0.45,1.74l0.24,1.45l0.78,0.86l1.94,0.58l1.42,1.07l2.39,1.12l4.99,-0.48l2.91,-1.03l1.14,0.52l2.23,0.11l4.23,1.47l0.69,0.55l0.18,1.15l0.57,0.59l1.86,-0.25l2.1,0.73l3.79,-0.51l0.69,-0.42l2.18,0.95l1.64,0.26l1.2,-0.29l0.87,0.27l1.89,-0.76l3.07,-0.4l4.16,0.17l1.62,-0.9l7.15,1.08l0.96,-0.18l0.8,-0.58l31.2,6.2l0.22,1.81l0.91,1.83l1.15,0.64l1.95,1.88l0.55,2.46l-0.16,1.0l-3.72,4.51l-0.41,1.41l-1.41,2.61l-2.23,2.39l-0.67,2.67l-1.5,1.82l-2.24,1.48l-1.94,3.32l-1.5,1.26l-0.63,2.01l-0.13,1.86l0.28,0.92l0.56,0.62l0.54,0.04l0.39,-0.34l0.63,0.76l0.89,-0.04l0.06,0.87l0.8,0.95l-0.46,0.99l-0.65,0.05l-0.34,0.4l0.2,1.79l-1.04,2.53l-1.23,1.4l-7.11,38.71l-26.22,-5.22l-28.89,-6.33l-28.79,-6.92l-28.85,-7.56l-1.52,-2.51l0.28,-2.43l-0.28,-0.87Z", "name": "Oregon"}, "US-KY": {"path": "M584.43,307.29l0.34,-2.14l1.15,0.94l0.72,0.19l0.75,-0.36l0.46,-0.87l0.87,-3.5l-0.55,-1.72l0.38,-0.85l-0.11,-1.85l-1.28,-2.0l1.78,-3.17l1.25,-0.51l0.74,0.05l7.06,2.47l0.81,-0.2l0.65,-0.71l0.23,-1.91l-1.5,-2.1l-0.24,-1.4l0.19,-0.86l0.4,-0.52l1.1,-0.19l1.24,-0.83l3.01,-0.96l0.64,-0.51l0.14,-1.13l-1.54,-2.01l-0.08,-0.66l1.33,-1.95l0.14,-1.14l1.26,0.4l1.12,-1.32l-0.68,-1.97l1.93,0.87l1.72,-0.84l0.03,1.15l1.01,0.45l0.99,-0.94l0.02,-1.34l0.51,0.16l1.9,-0.97l4.43,1.46l0.64,0.92l0.86,0.17l0.59,-0.59l0.73,-2.49l1.39,-0.55l1.4,-1.33l0.87,1.26l0.77,0.41l1.16,-0.14l0.12,0.74l0.95,0.18l0.66,-0.62l0.02,-0.99l0.84,-0.38l0.27,-0.48l-0.25,-2.06l0.84,-0.4l0.34,-0.56l-0.06,-0.67l1.25,-0.57l0.34,-0.72l0.39,1.45l0.62,0.59l1.47,0.61l1.25,-0.01l1.12,0.79l0.52,-0.11l0.26,-0.54l1.1,-0.46l0.53,-0.69l0.03,-3.42l0.85,-2.15l1.03,0.17l1.55,-1.19l0.74,-3.41l1.04,-0.37l1.65,-2.21l-0.0,-0.81l-1.19,-2.81l2.79,-0.61l1.54,0.78l3.85,-2.82l2.24,-0.47l-0.18,-1.06l0.35,-1.45l-0.32,-0.36l-1.22,-0.02l0.57,-1.37l-1.09,-1.5l1.65,-1.82l1.82,1.15l0.92,-0.12l1.94,-1.02l0.78,0.86l1.76,0.51l0.57,1.26l0.94,0.9l0.8,1.8l2.6,0.63l1.88,-0.58l1.64,0.25l2.2,1.8l0.96,0.41l1.27,-0.19l0.6,-1.3l0.99,-0.54l1.36,0.48l1.34,0.02l1.34,1.06l1.26,-0.69l1.42,-0.16l1.8,-2.53l1.72,-1.04l0.94,2.3l0.7,0.81l2.46,0.77l1.36,0.94l0.75,1.02l0.95,3.27l-0.37,0.45l0.1,0.71l-0.44,0.61l0.02,0.53l2.26,2.56l1.36,0.89l-0.07,0.87l1.35,0.94l0.59,1.33l1.56,1.17l0.99,1.58l2.15,0.8l1.1,1.09l2.13,0.23l-4.83,6.08l-5.06,4.15l-0.42,0.86l0.23,1.22l-2.07,1.93l0.05,1.61l-3.06,1.65l-0.8,2.36l-1.71,0.61l-2.7,1.83l-1.66,0.49l-3.39,2.42l-32.85,4.78l-7.49,0.92l-7.71,0.53l-22.78,3.67l-0.64,-0.55l-3.64,0.12l-0.41,0.6l1.05,3.51l-23.07,2.87Z", "name": "Kentucky"}, "US-ME": {"path": "M837.16,56.83l0.85,-1.16l1.44,1.68l0.84,0.03l0.36,-2.12l-0.49,-2.18l1.71,0.33l0.72,-0.43l0.21,-0.52l-0.33,-0.69l-1.19,-0.45l-0.45,-0.61l0.17,-1.43l0.83,-2.04l2.05,-2.28l-0.01,-0.98l-0.53,-0.93l1.0,-1.66l0.36,-1.52l-0.23,-0.91l-1.02,-0.34l-0.09,-1.42l-0.41,-0.43l0.54,-0.97l-0.05,-0.63l-1.02,-1.25l0.1,-1.74l0.36,-0.64l-0.17,-0.98l1.19,-1.95l-1.07,-6.19l5.24,-19.08l2.24,-0.25l1.2,3.2l0.56,0.42l2.56,0.53l1.8,-1.76l1.66,-0.85l1.21,-1.74l1.25,-0.13l0.63,-0.48l0.22,-1.45l0.42,-0.3l1.36,0.03l3.71,1.38l1.16,0.96l2.38,1.03l8.78,22.69l0.65,0.64l-0.17,1.26l0.66,0.85l-0.08,1.53l-0.32,0.05l-0.23,0.66l1.73,1.1l1.79,0.19l0.82,0.4l1.88,-0.22l1.24,-0.66l0.36,0.85l-0.57,1.43l1.72,1.84l0.32,2.68l2.75,1.63l0.98,-0.12l0.46,-0.75l-0.07,-0.5l0.36,0.07l0.26,0.49l0.64,0.06l1.43,1.09l0.28,0.74l1.28,0.92l0.04,0.47l-0.52,-0.13l-0.38,0.41l0.19,0.77l-0.76,-0.14l-0.34,0.4l0.17,0.63l0.82,0.51l0.56,0.9l0.48,0.16l0.15,-0.88l0.38,-0.18l0.81,0.31l0.24,-0.83l0.35,0.4l-0.3,0.85l-0.52,0.19l-1.17,3.25l-0.63,-0.03l-0.31,0.44l-0.57,-1.04l-0.72,0.04l-0.3,0.51l-0.56,0.07l-0.01,0.49l0.59,0.84l-0.91,-0.44l-0.32,0.63l0.27,0.51l-1.2,-0.26l-0.36,0.3l-0.36,0.78l0.08,0.45l0.44,0.08l0.09,1.2l-0.38,-0.56l-0.55,-0.05l-0.38,0.45l-0.19,1.09l-0.5,-1.52l-1.14,0.03l-0.66,0.76l-0.34,1.48l0.6,0.61l-0.82,0.64l-0.7,-0.45l-0.72,1.04l0.11,0.64l1.0,0.61l-0.35,0.22l-0.09,0.82l-0.46,-0.2l-0.87,-1.79l-1.04,-0.44l-0.38,0.22l-0.45,-0.41l-0.56,0.64l-1.25,-0.17l-0.25,0.86l0.78,0.39l0.01,0.36l-0.52,-0.05l-0.55,0.41l-0.08,0.69l-0.51,-1.01l-1.17,-0.0l-0.15,0.65l0.53,0.86l-1.42,0.98l0.85,1.09l0.1,1.05l0.54,0.64l-0.97,-0.39l-0.96,0.23l-1.2,-0.4l-0.19,-0.9l0.74,-0.29l-0.09,-0.55l-0.43,-0.48l-0.67,-0.11l-0.3,0.33l-0.26,-2.35l-0.38,-0.21l-1.1,0.28l0.07,1.95l-1.82,1.94l0.03,0.5l1.27,1.44l-0.63,0.96l-0.14,3.85l0.79,1.39l-1.06,1.73l-0.8,-0.18l-0.44,0.94l-0.62,-0.05l-0.42,-1.14l-0.73,-0.2l-0.5,1.03l0.12,0.68l-0.44,0.6l0.15,2.4l-0.97,-0.99l0.13,-1.27l-0.25,-0.59l-0.81,0.3l-0.06,2.0l-0.44,-0.24l0.13,-1.54l-0.48,-0.39l-0.67,0.49l-0.73,3.04l-0.8,-1.95l0.16,-1.21l-0.4,-0.27l-0.46,0.21l-1.01,2.6l0.36,0.52l0.84,-0.16l0.98,2.05l-0.29,-0.58l-0.52,-0.22l-0.65,0.31l-0.06,0.64l-1.38,-0.08l-2.12,3.19l-0.51,1.86l0.3,0.59l-0.67,0.66l0.51,0.42l0.91,-0.23l0.37,0.9l-1.87,1.24l-0.13,1.03l0.68,1.35l-0.07,0.67l-0.77,1.3l-0.93,0.62l-0.53,1.29l0.46,1.54l-0.37,2.8l-0.8,-0.32l-0.41,0.6l-1.03,-0.73l-0.59,-1.83l-0.94,-0.35l-2.38,-1.94l-0.8,-3.42l-13.68,-35.18ZM864.38,81.29l0.09,0.25l-0.08,0.23l0.03,-0.28l-0.04,-0.2ZM865.8,81.48l0.47,0.69l-0.04,0.47l-0.32,-0.24l-0.11,-0.92ZM868.1,78.32l0.43,0.81l-0.16,0.15l-0.42,-0.18l0.15,-0.77ZM877.3,64.81l-0.14,0.2l-0.03,-0.23l0.17,0.03ZM873.47,75.16l0.01,0.02l-0.02,0.03l0.01,-0.05Z", "name": "Maine"}, "US-OH": {"path": "M666.21,180.79l1.66,0.34l0.97,-0.31l1.76,1.04l2.08,0.23l1.48,1.14l1.6,0.23l-2.06,1.16l-0.12,0.47l0.43,0.24l2.46,0.16l1.39,-1.1l1.77,-0.27l3.41,0.91l0.92,-0.09l1.47,-1.3l1.73,-0.6l3.06,-1.95l2.62,-0.06l1.09,-0.62l1.24,-0.08l1.06,-0.8l4.22,-5.44l4.51,-3.48l6.9,-4.4l6.01,27.6l-0.51,0.54l-1.28,0.43l-0.41,0.94l1.67,2.19l0.03,2.07l0.41,0.26l0.32,0.92l-0.04,0.75l-0.54,0.82l-0.48,4.03l0.19,3.16l-0.57,0.41l0.34,1.09l-0.34,1.72l-0.39,0.54l0.77,1.21l-0.24,1.84l-2.4,2.64l-0.82,1.85l-1.36,1.49l-1.24,0.68l-0.6,0.7l-0.88,-0.89l-1.18,0.15l-1.31,1.73l-0.08,1.3l-1.78,0.86l-0.77,2.22l0.28,1.55l-0.93,0.85l0.31,0.66l0.63,0.4l0.27,1.27l-0.8,0.18l-0.5,1.59l0.05,-0.91l-0.92,-1.23l-1.53,-0.52l-1.13,0.8l-0.75,1.87l-0.33,2.65l-0.53,0.82l1.24,3.51l-1.46,0.64l-0.43,3.33l-2.54,1.14l-1.01,0.06l-0.77,-1.04l-1.52,-1.07l-2.35,-0.69l-1.17,-1.87l-0.32,-1.12l-0.74,-0.34l-2.26,1.33l-1.09,1.28l-0.4,1.04l-1.43,0.17l-0.87,0.61l-1.12,-0.98l-3.15,-0.55l-1.37,0.72l-0.53,1.24l-0.72,0.06l-3.06,-2.19l-1.94,-0.26l-1.78,0.58l-2.15,-0.49l-0.55,-1.51l-0.97,-0.95l-0.64,-1.35l-2.04,-0.73l-1.15,-0.98l-2.28,1.15l-0.46,0.03l-1.8,-1.19l-0.61,0.21l-0.6,0.7l-8.94,-54.69l20.67,-4.41ZM676.79,183.05l0.5,-0.77l0.64,0.41l-0.44,0.34l-0.7,0.03Z", "name": "Ohio"}, "US-OK": {"path": "M399.79,359.94l-0.05,-41.46l-0.39,-0.4l-26.79,-0.23l-25.23,-0.63l0.32,-10.06l36.83,0.78l36.14,-0.07l36.12,-0.9l35.69,-1.7l0.62,10.51l4.61,23.98l1.48,37.44l-1.21,-0.21l-0.29,-0.36l-2.14,-0.2l-0.83,-0.78l-2.13,-0.38l-1.78,-2.03l-1.24,-0.21l-2.27,-1.54l-1.5,-0.39l-0.8,0.45l-0.23,0.87l-0.83,0.24l-0.46,0.62l-2.49,-0.13l-1.8,-1.46l-2.31,1.28l-1.17,0.2l-0.19,0.56l-0.63,0.27l-2.13,-0.76l-1.71,1.17l-2.07,0.51l-0.83,1.36l-1.49,0.07l-0.57,1.24l-1.27,-1.53l-1.71,-0.09l-0.32,-0.57l-1.21,-0.45l-0.02,-0.95l-0.44,-0.5l-1.24,-0.17l-0.74,1.37l-0.67,0.11l-0.84,-0.49l-0.98,0.07l-0.71,-1.5l-1.09,-0.34l-1.17,0.57l-0.45,1.69l-0.71,-0.08l-0.49,0.43l0.29,0.72l-0.5,1.66l-0.44,0.19l-0.86,-1.43l0.39,-1.64l-0.76,-0.85l-0.8,0.18l-0.49,0.76l-0.85,-0.18l-0.93,0.97l-1.08,0.13l-0.53,-1.35l-2.0,-0.18l-0.3,-1.46l-1.19,-0.53l-0.83,0.33l-2.13,2.14l-1.22,0.51l-0.98,-0.37l0.19,-1.23l-0.29,-1.12l-2.34,-0.66l-0.08,-2.15l-0.44,-0.55l-2.11,0.39l-2.53,-0.25l-0.64,0.26l-0.81,1.2l-0.96,0.06l-1.77,-1.75l-0.97,-0.12l-1.5,0.55l-2.7,-0.63l-1.86,-0.99l-1.05,0.25l-2.48,-0.3l-0.18,-2.09l-0.86,-0.86l-0.44,-1.01l-1.17,-0.41l-0.7,-0.82l-0.82,0.08l-0.44,1.63l-2.23,-0.67l-1.08,0.59l-0.97,-0.09l-3.81,-3.74l-1.13,-0.43l-0.81,0.08Z", "name": "Oklahoma"}, "US-ID": {"path": "M133.07,123.78l-0.34,-0.44l0.1,-1.98l0.55,-1.73l1.43,-1.2l2.14,-3.56l1.69,-0.91l1.4,-1.51l1.09,-2.13l0.06,-1.21l2.23,-2.39l1.45,-2.68l0.38,-1.36l2.06,-2.24l1.91,-2.8l0.04,-1.01l-0.76,-2.96l-2.11,-1.96l-0.86,-0.37l-0.84,-1.62l-0.39,-3.03l-0.58,-1.2l0.95,-1.18l-0.1,-2.36l-1.01,-2.71l10.72,-56.05l13.32,2.45l-3.77,21.07l1.25,2.93l0.98,1.29l0.25,1.57l1.15,1.79l-0.13,0.84l0.38,1.16l-1.0,0.96l0.82,1.79l-0.84,0.11l-0.28,0.71l1.91,1.71l1.01,2.06l2.23,1.25l0.47,1.49l1.14,1.46l1.46,2.82l0.08,0.69l1.62,1.83l-0.01,1.89l1.78,1.73l-0.08,1.36l0.74,0.19l0.9,-0.58l0.35,0.47l-0.36,0.55l0.06,0.54l1.1,0.97l1.61,0.16l1.81,-0.35l-0.65,2.62l-0.99,0.53l0.24,1.14l-1.86,3.73l0.05,1.72l-0.81,0.07l-0.37,0.54l0.59,1.33l-0.62,0.9l-0.04,1.17l0.96,0.94l-0.37,0.81l0.27,1.02l-1.57,0.42l-1.22,1.41l0.09,1.11l0.45,0.78l-0.14,0.74l-0.83,0.77l-0.21,1.52l1.48,0.64l1.37,1.8l0.78,0.28l1.08,-0.34l0.56,-0.79l1.85,-0.4l1.22,-1.27l0.82,-0.29l0.16,-0.76l0.78,0.82l0.22,0.71l1.05,0.65l-0.43,1.23l0.72,0.95l-0.35,1.37l0.56,1.35l-0.22,1.61l1.53,2.65l0.3,1.73l0.82,0.37l0.65,2.08l-0.19,0.98l-0.77,0.63l0.5,1.89l1.23,1.16l0.3,0.79l0.81,0.09l0.87,-0.36l1.04,0.93l1.04,2.79l-0.51,0.81l0.88,1.83l-0.28,0.59l0.11,0.98l2.28,2.42l0.97,-0.13l-0.0,-1.13l1.08,-0.88l0.93,-0.21l4.52,1.64l0.69,-0.31l0.68,-1.34l1.2,-0.39l2.25,0.94l3.3,-0.08l0.95,0.88l2.29,-0.56l3.22,0.8l0.46,-0.49l-0.67,-0.77l0.26,-1.05l0.74,-0.47l-0.06,-0.96l1.23,-0.5l0.48,0.37l1.06,2.11l0.12,1.11l1.35,1.95l0.73,0.45l-6.5,53.35l-47.53,-6.61l-47.0,-8.09l7.13,-38.72l1.13,-1.16l1.09,-2.65l-0.2,-1.73l0.74,-0.14l0.78,-1.6l-0.89,-1.27l-0.17,-1.2l-1.24,-0.09l-0.63,-0.82l-0.89,0.28Z", "name": "Idaho"}, "US-WY": {"path": "M218.9,209.28l10.46,-85.74l25.45,2.87l26.79,2.51l26.83,2.0l27.85,1.53l-3.81,86.29l-27.38,-1.48l-28.27,-2.06l-29.75,-2.75l-28.19,-3.17Z", "name": "Wyoming"}, "US-UT": {"path": "M220.64,188.38l-2.59,21.19l0.35,0.45l32.3,3.59l-8.57,85.74l-42.68,-4.9l-42.53,-6.06l16.56,-106.57l47.16,6.56Z", "name": "Utah"}, "US-IN": {"path": "M601.94,191.96l1.43,0.85l2.11,0.13l1.52,-0.39l2.63,-1.39l2.73,-2.09l32.18,-5.03l9.24,56.49l-0.66,1.15l0.31,0.91l0.81,0.76l-0.65,1.12l0.5,0.79l1.12,0.03l-0.36,1.11l0.18,0.5l-1.81,0.3l-3.18,2.54l-0.44,0.18l-1.41,-0.78l-3.46,0.93l-0.09,0.77l1.21,3.04l-1.4,1.87l-1.18,0.5l-0.45,0.88l-0.3,2.56l-1.12,0.88l-0.89,-0.25l-0.63,0.49l-0.85,1.93l0.06,3.09l-0.39,0.98l-1.39,0.85l-0.94,-0.66l-1.24,0.02l-1.48,-0.66l-0.63,-1.81l-1.89,-0.7l-0.44,0.3l-0.03,0.51l0.82,0.66l-0.62,0.3l-0.89,-0.34l-0.35,0.29l-0.04,0.48l0.55,0.9l-1.08,0.68l0.15,2.34l-1.06,0.65l0.0,0.82l-0.16,0.36l-0.26,-0.99l-1.61,0.19l-1.41,-1.65l-0.49,-0.07l-1.67,1.49l-1.57,0.69l-1.07,2.86l-0.82,-1.05l-2.8,-0.74l-1.11,-0.59l-1.08,-0.17l-1.76,0.92l-0.64,-1.0l-0.58,-0.18l-0.53,0.56l0.65,1.82l-0.33,0.82l-0.29,0.09l-0.03,-1.15l-0.43,-0.39l-2.04,0.81l-1.42,-0.81l-0.84,0.01l-0.48,0.95l0.72,1.52l-0.49,0.73l-1.16,-0.38l-0.08,-0.53l-0.52,-0.42l0.54,-0.62l-0.35,-3.04l0.95,-0.78l-0.08,-0.59l-0.43,-0.22l0.68,-0.45l0.25,-0.61l-1.18,-1.43l0.45,-1.15l0.33,0.19l1.38,-0.55l0.33,-1.77l0.55,-0.39l0.44,-0.91l-0.06,-0.81l1.52,-1.06l0.06,-0.69l-0.42,-0.9l0.57,-0.85l0.13,-1.27l0.87,-0.51l0.39,-1.89l-1.1,-2.5l0.05,-1.89l-0.94,-0.89l-0.62,-1.47l-1.06,-0.76l-0.04,-0.57l0.92,-1.38l-0.64,-2.21l1.27,-1.31l-6.7,-49.89Z", "name": "Indiana"}, "US-IL": {"path": "M541.14,227.8l0.87,-0.35l0.37,-0.67l-0.24,-2.29l-0.74,-0.91l0.15,-0.4l0.71,-0.69l2.42,-0.98l0.71,-0.64l0.63,-1.66l0.17,-2.07l1.64,-2.45l0.27,-0.93l-0.04,-1.21l-0.59,-1.92l-2.24,-1.84l-0.12,-1.74l0.66,-2.35l0.45,-0.37l4.61,-0.86l0.81,-0.41l0.82,-1.11l2.55,-1.0l1.43,-1.55l0.38,-3.25l1.42,-1.45l0.29,-0.74l0.32,-4.32l-0.77,-2.12l-4.03,-2.42l-0.28,-1.47l-0.49,-0.81l-3.66,-2.42l44.63,-4.88l0.0,2.62l0.58,2.56l1.39,2.46l1.31,0.92l0.77,2.56l1.27,2.67l1.43,1.81l6.81,50.68l-1.21,1.12l-0.1,0.69l0.68,1.72l-0.83,1.07l-0.03,1.1l1.2,1.07l0.57,1.38l0.9,0.8l-0.09,1.78l1.07,2.26l-0.27,1.46l-0.87,0.56l-0.21,1.45l-0.59,0.92l0.33,1.18l-1.48,1.12l-0.22,0.42l0.29,0.68l-0.93,1.16l-0.3,1.18l-1.65,0.68l-0.62,1.65l0.16,0.8l0.97,0.8l-1.27,1.14l0.4,0.75l-0.47,0.23l-0.12,0.55l0.43,2.88l-1.15,0.2l0.08,0.45l0.9,0.75l-0.47,0.17l-0.02,0.64l0.83,0.28l0.04,0.41l-1.3,1.94l-0.24,1.17l0.6,1.2l0.7,0.63l0.37,1.05l-3.31,1.23l-1.19,0.81l-1.25,0.25l-0.77,1.0l-0.17,2.02l1.71,2.75l0.07,0.52l-0.53,1.17l-0.97,0.03l-6.33,-2.35l-1.08,-0.07l-1.57,0.64l-0.68,0.71l-1.43,2.91l0.06,0.66l-1.19,-1.18l-0.79,0.14l-0.35,0.47l0.57,1.11l-1.23,-0.76l-0.02,-0.67l-1.61,-2.16l-0.4,-1.1l-0.76,-0.36l-0.05,-0.47l0.94,-1.33l0.2,-1.02l-0.33,-1.0l-1.45,-1.98l-0.48,-3.13l-2.27,-0.96l-1.56,-2.09l-1.96,-0.79l-1.73,-1.3l-1.57,-0.13l-1.83,-0.93l-2.33,-1.73l-2.36,-2.39l-0.37,-1.91l2.36,-6.76l-0.25,-2.28l0.98,-2.03l-0.39,-0.84l-2.67,-1.41l-2.6,-0.64l-1.28,0.45l-0.86,1.43l-0.91,0.16l-1.3,-1.86l-0.43,-1.49l0.15,-0.86l-0.54,-0.9l-0.29,-1.62l-0.83,-1.33l-0.94,-0.88l-4.12,-2.46l-1.01,-1.61l-4.55,-3.45l-0.74,-1.87l-1.05,-1.19l-0.04,-1.57l-0.97,-1.45l-0.76,-3.48l0.09,-2.89l0.6,-1.26ZM586.91,296.36l0.05,0.06l0.03,0.03l-0.05,-0.0l-0.04,-0.09Z", "name": "Illinois"}, "US-AK": {"path": "M64.07,549.59l0.11,-0.08l0.07,0.1l-0.16,-0.02l-0.02,-0.0ZM65.9,548.94l1.15,0.21l0.09,0.54l-1.36,0.86l-0.19,-0.22l0.34,-0.49l-0.03,-0.91ZM68.83,549.22l0.72,-0.13l0.35,-0.71l2.21,-0.52l2.72,0.02l1.81,0.72l0.94,0.83l-0.16,2.33l0.62,0.93l0.77,-0.37l0.01,-0.86l0.53,0.36l-0.15,0.55l1.01,1.13l-0.57,0.04l-0.74,-0.51l-0.68,0.59l-0.06,-0.77l-0.69,0.12l-1.35,-0.55l-0.86,0.31l-1.09,-0.24l-0.4,-0.56l0.52,-0.42l0.85,0.86l0.48,-0.03l0.21,-0.47l-0.58,-1.69l-1.1,-0.61l-1.21,0.35l-0.74,0.87l-1.35,0.42l-0.5,-0.37l-0.62,0.45l-0.75,-0.3l-0.61,0.38l0.44,-2.18ZM80.23,553.51l0.89,-0.72l-0.57,-1.66l0.19,-0.34l2.0,-1.17l3.95,-0.24l2.65,0.76l0.62,-0.36l1.0,0.3l0.79,1.09l0.71,-0.02l1.11,-1.84l2.84,-0.95l1.03,0.29l1.38,-0.53l0.82,0.02l-0.19,0.54l0.46,0.66l1.17,0.29l0.63,-0.96l-0.79,-0.26l0.3,-0.64l-0.18,-0.5l2.61,-2.72l1.09,0.01l0.53,0.83l0.67,-0.24l-0.05,-0.67l-0.97,-0.98l0.3,-0.74l1.08,-0.69l3.37,-0.38l-0.15,-0.66l2.84,-1.88l0.2,-0.48l-0.44,-0.28l-0.63,0.12l-0.68,0.69l-0.63,-0.08l-0.64,0.4l-5.42,-0.99l0.23,-1.25l-0.34,-0.8l1.17,-0.91l0.61,0.68l-0.22,1.3l0.94,-0.02l0.22,-0.78l0.04,-0.89l-0.86,-1.27l0.11,-0.9l-0.68,-0.24l-0.36,0.98l-0.99,0.48l0.24,-0.27l-0.27,-0.55l-0.39,-0.09l-0.9,1.11l-0.98,0.27l-0.63,2.04l-0.31,0.58l-0.48,0.09l-0.2,-0.96l0.45,-2.67l-0.17,-1.36l0.28,-0.62l-0.63,-0.68l-1.28,0.5l0.15,-0.69l-0.58,-0.98l0.33,-0.49l-0.01,-1.06l-2.98,-0.1l-0.51,-0.37l-1.39,-0.07l-0.41,-0.57l-1.3,0.81l-0.96,-0.23l-0.08,-0.54l-0.23,0.0l1.42,-0.3l0.01,-0.92l0.61,-0.89l1.53,-0.18l-0.01,-0.87l-1.24,-0.67l0.23,-0.55l1.01,-0.85l1.35,-0.08l0.48,-0.4l1.24,-5.12l1.52,-1.61l-0.2,-0.36l-0.43,-0.02l-0.14,-0.45l2.29,-1.32l1.24,0.24l0.86,-0.65l-0.78,-0.48l-0.29,-0.8l-0.61,0.62l-0.7,-0.1l-1.45,0.91l-1.33,0.17l-0.36,0.34l-0.55,-0.11l-0.17,0.47l0.43,0.94l-0.99,0.96l-0.38,-0.43l-2.31,-0.22l-2.11,-1.1l-1.39,-1.55l0.15,-0.54l0.72,-0.04l0.09,-0.67l-0.45,-1.33l0.12,-1.7l0.49,-0.76l-0.71,-0.29l-0.41,-1.37l0.91,-0.17l0.34,-0.7l-0.3,-0.39l-1.02,-0.29l1.79,0.04l0.71,-0.58l0.91,-0.05l-0.0,0.63l0.94,1.22l-0.13,0.37l-1.08,0.16l-0.61,0.5l0.32,0.54l1.17,-0.2l0.47,0.27l1.19,-0.35l0.15,0.16l-0.94,1.25l0.2,0.52l0.53,0.27l1.48,0.03l0.93,-0.7l-0.19,-1.09l0.58,-0.4l0.03,-1.36l-0.61,-0.3l-1.39,0.23l-1.67,-1.41l0.11,-0.67l-1.0,-1.28l1.09,0.1l0.51,-0.35l-0.15,-0.49l-0.96,-0.63l0.78,-0.57l0.04,-0.88l1.42,-0.34l0.5,0.29l0.76,-0.08l0.87,-0.5l-0.01,-0.57l-0.65,-0.29l-0.81,0.34l-1.77,-0.12l-1.23,0.74l-0.84,0.11l-0.37,0.62l-0.32,0.02l0.79,-1.18l0.09,-0.52l-0.49,-0.73l0.16,-0.4l0.76,0.05l0.53,-0.75l-0.24,-0.94l-0.81,-0.43l0.05,-0.13l1.73,0.72l0.4,-0.45l-0.48,-1.28l0.68,0.67l1.1,0.38l0.61,-1.67l0.75,-0.52l4.2,-1.12l0.39,0.28l0.14,0.97l-0.49,0.34l0.14,0.45l1.25,0.11l0.31,-0.4l-0.14,-1.28l2.0,-0.27l0.27,-0.58l-0.37,-0.31l-1.15,0.08l0.19,-0.42l0.58,-0.02l0.08,-0.65l1.3,-0.7l1.26,1.14l0.51,-0.73l-0.32,-0.89l0.84,-0.07l1.13,0.67l0.49,1.04l-0.19,0.62l-1.0,0.06l-0.37,0.71l1.8,0.12l-0.07,0.66l1.18,0.82l3.25,-0.18l2.02,-0.68l0.08,0.65l2.76,1.79l1.22,0.33l2.52,-0.64l1.04,-0.85l0.81,-2.12l1.09,-1.75l-0.06,-1.27l0.28,-0.34l-0.51,-1.26l0.7,0.88l0.65,0.23l1.61,-0.44l0.69,-0.71l0.3,-1.2l-0.2,-0.8l0.62,-0.43l-0.23,-0.42l-0.85,-0.43l-1.63,0.63l-0.73,-1.24l-1.37,0.25l-0.49,-0.34l-2.84,0.23l-0.91,0.63l0.48,-0.84l-0.22,-2.25l-1.64,-0.11l-0.42,-0.72l-2.3,-1.91l-1.11,-0.14l-0.82,-0.88l-0.95,0.18l-1.89,-2.85l-0.88,-1.8l0.17,-0.71l0.88,-0.41l0.55,-0.87l-0.32,-1.28l0.29,-0.68l0.67,0.3l1.18,-0.5l0.98,1.11l0.53,-0.41l-0.09,-0.76l-0.8,-1.4l-2.24,-2.89l-0.68,-2.8l1.13,0.06l0.98,0.64l1.39,-0.73l0.23,0.65l0.61,0.25l1.13,0.05l1.21,-0.46l1.85,0.27l0.11,0.79l0.88,1.04l1.25,0.45l0.54,-0.42l-0.5,-1.45l0.41,-0.07l1.94,0.34l0.33,0.23l0.01,0.51l0.64,0.16l1.74,-0.2l0.52,0.21l1.58,1.0l0.21,0.71l-1.26,0.72l-0.57,0.85l-1.46,-0.24l-0.08,0.66l0.62,0.56l-0.05,1.22l1.88,1.87l1.22,0.6l-0.37,0.8l2.11,1.01l0.34,1.48l0.52,0.21l0.44,-0.49l2.14,-1.01l0.48,1.05l-0.6,0.27l0.05,0.62l0.58,0.25l0.72,-0.33l0.62,-0.58l0.23,-1.15l-0.72,-1.46l0.85,0.07l0.38,2.05l0.57,0.54l1.42,0.73l0.81,-0.25l1.28,-2.09l-0.16,-0.33l-1.38,-0.37l-0.29,-1.14l-1.0,-0.57l-0.53,-0.1l-0.81,0.5l-0.32,-0.32l-0.08,-1.98l1.19,-0.97l1.15,0.25l0.46,-0.56l-0.58,-1.51l-1.24,-0.72l-0.07,-0.55l0.49,-0.72l-0.66,-0.49l-1.19,0.74l-0.18,-0.55l-0.94,-0.54l-1.42,-2.1l1.22,-1.89l0.79,-2.96l-0.79,-6.63l-0.86,-1.8l0.18,-1.26l-0.4,-1.42l0.5,0.16l1.69,-1.18l1.91,-2.1l1.09,1.35l1.83,1.33l2.42,1.38l1.65,0.34l1.74,-0.1l2.99,-0.82l2.37,-2.15l0.63,-0.18l0.21,-0.53l2.45,-0.49l1.91,-0.88l0.95,0.67l0.97,0.16l0.36,-0.25l0.77,0.55l0.96,0.16l0.4,0.46l0.44,-0.31l3.4,-0.45l-0.95,0.51l0.31,0.52l-0.92,0.48l-0.11,0.57l0.45,0.24l-0.33,1.28l0.21,0.46l0.68,-0.36l1.05,-1.92l1.22,0.53l0.94,-0.08l-0.07,-0.72l-1.17,-0.76l0.23,-1.11l1.51,-0.35l0.22,1.82l0.45,-0.0l0.27,-0.45l0.85,0.12l0.53,0.56l2.92,1.15l3.18,-0.45l2.91,-1.24l0.04,0.93l0.74,0.65l-0.36,0.39l0.14,0.59l0.66,0.09l0.53,0.55l-0.24,0.51l-0.86,0.25l-0.99,-0.36l-0.69,0.22l-0.28,0.66l0.21,0.52l-0.63,0.8l0.23,0.62l0.42,0.05l0.39,-0.38l1.11,0.36l1.29,-0.91l0.37,0.41l0.69,0.12l0.74,-0.53l0.1,0.89l-1.2,0.53l0.08,1.3l0.89,0.62l-0.01,0.71l0.67,0.21l1.2,-0.43l0.86,0.7l1.09,0.17l0.87,1.96l0.84,-0.25l0.32,0.47l-1.34,0.64l-0.35,0.75l-0.74,0.17l-0.15,0.49l0.37,0.49l1.84,0.92l-0.79,0.31l-0.03,0.62l1.43,1.05l0.32,0.93l0.38,0.22l0.57,-0.51l1.29,0.48l0.24,-0.21l0.38,0.5l-0.25,0.26l0.18,0.58l1.28,0.32l0.78,-0.15l1.7,1.07l0.55,1.19l0.87,0.91l-0.07,0.92l0.56,0.37l0.64,-0.12l0.58,0.96l-0.21,0.55l0.32,0.59l1.63,1.51l1.04,0.29l2.57,1.84l1.03,2.44l1.03,0.8l1.29,0.65l0.97,-0.2l0.54,0.29l0.0,0.63l1.61,-0.42l0.99,0.49l-0.04,0.41l0.54,0.37l0.28,-0.27l0.25,0.18l0.89,1.15l0.39,1.98l0.57,0.54l0.01,0.53l1.0,0.92l0.33,1.5l0.32,0.34l0.82,0.07l-39.47,81.59l0.13,0.49l1.53,1.53l0.88,-0.22l1.27,1.59l0.73,0.04l1.37,-0.52l2.05,0.8l-1.35,1.98l0.41,1.24l0.91,1.15l-0.09,1.44l2.27,6.16l-0.71,3.08l0.57,0.37l1.94,-0.52l0.07,0.39l-1.28,0.79l0.29,0.55l0.86,-0.28l0.94,0.74l0.28,1.73l-0.4,0.03l-0.1,0.46l0.24,0.4l1.09,0.29l-0.29,0.48l0.45,0.7l-0.21,0.66l-0.3,-0.02l-0.07,-0.63l-0.79,-0.86l-0.51,-0.03l-1.0,0.7l-0.24,-0.81l-1.07,-0.62l-1.1,-2.1l0.43,0.01l0.24,-0.76l-0.37,-0.33l-0.6,0.04l-0.45,-1.21l0.07,-1.52l-1.23,-2.55l0.27,-0.55l-1.12,-0.47l-1.3,-1.85l-0.25,-0.88l-1.58,-1.94l0.47,0.03l1.27,-0.85l-0.5,1.03l0.3,0.51l0.43,0.08l0.5,-0.4l0.61,-1.75l0.89,0.85l0.43,0.04l0.32,-0.36l-0.45,-0.93l-0.76,-0.48l-0.54,-2.01l-0.46,-0.2l-2.26,1.3l-2.22,0.07l-1.6,-1.02l-1.71,-2.11l0.54,-0.22l0.39,-0.78l0.09,-0.69l-0.37,-0.97l-0.91,0.11l-0.15,0.79l-0.86,0.01l-0.88,-1.12l-3.05,-2.41l-5.04,-1.42l-0.35,-1.48l0.26,-0.56l-1.72,-1.05l-0.06,-0.71l-0.46,-0.61l0.95,-0.82l0.38,-0.97l1.21,-0.32l0.19,-0.67l-1.03,-0.31l-2.69,1.33l-0.97,0.09l-0.14,-0.77l-0.87,-0.87l1.52,-1.1l-0.33,-0.49l-0.53,0.03l-0.45,-0.86l0.24,-0.67l-0.35,-1.29l-0.49,-0.26l-0.6,0.26l-0.5,-0.46l0.38,-0.8l-0.15,-0.26l0.67,-0.1l1.19,0.5l0.4,-0.44l-0.18,-0.68l-1.38,-0.79l-1.84,0.51l-0.54,-0.61l-1.1,-0.25l-0.21,-0.35l0.49,-1.21l-0.38,-0.37l-0.53,0.13l-1.01,1.23l-0.85,0.06l-0.1,-0.3l0.88,-0.71l1.57,-0.69l0.23,-0.77l-0.37,-0.35l-2.08,0.99l-0.3,-0.62l-1.38,-0.14l-0.77,0.65l0.29,0.65l-0.16,0.42l-1.74,-0.25l-0.87,1.12l0.23,0.62l0.85,-0.02l-0.25,0.45l-1.43,0.37l-0.42,0.71l0.42,0.35l0.99,-0.24l0.48,1.01l-0.54,0.15l-0.12,0.53l-0.73,-0.16l-0.68,0.65l0.07,0.62l-0.32,0.38l-1.11,0.43l-1.3,-1.04l0.18,-0.77l-1.09,-0.12l0.2,-0.99l-0.55,-0.38l-1.13,1.26l-0.32,-0.01l-0.2,-0.62l-0.51,-0.08l-0.5,0.6l-0.51,-0.08l-0.24,0.46l-0.76,-0.42l-0.31,0.67l-0.71,-0.56l-1.32,0.67l-0.16,-0.44l-0.96,0.0l-0.38,0.24l0.03,0.53l-2.07,0.52l-0.93,-0.91l-0.65,0.32l-0.43,-0.31l-1.23,0.04l-0.47,-1.21l0.32,0.14l0.66,-0.33l-0.03,-0.25l0.78,0.06l0.71,0.88l0.58,0.01l0.18,-0.75l1.0,0.15l1.81,-0.93l0.3,-0.47l-0.36,-0.57l-2.6,0.1l-0.62,-1.32l1.78,-1.53l2.04,-0.73l0.92,-1.02l0.52,-0.1l0.92,-1.26l0.29,-1.46l1.42,0.29l3.55,-0.47l0.12,1.19l0.6,0.59l1.39,0.23l2.44,2.75l0.48,-0.33l-0.01,-1.03l-1.68,-1.79l-0.75,-1.82l2.24,-0.91l2.12,0.24l0.27,-0.64l-0.84,-0.7l-1.69,-0.3l-1.11,0.38l-0.67,0.7l-0.93,-0.94l-0.66,-0.12l0.28,-0.52l-0.2,-0.67l-1.43,0.45l-1.58,-0.12l-1.07,0.63l-1.77,-0.47l-1.76,0.53l-0.39,0.8l-1.34,0.0l-2.02,0.7l-0.64,0.97l-0.73,0.34l-0.75,0.02l-0.42,-0.31l-0.41,-1.07l-1.12,-0.25l-0.27,0.27l0.14,0.52l0.39,0.08l0.34,2.37l-0.99,0.56l-2.34,-0.89l-0.47,0.26l0.04,0.67l0.73,0.42l-0.83,0.29l-0.08,-1.28l-0.29,-0.38l-0.86,0.81l-0.23,-0.48l-0.93,0.22l-0.14,0.68l-0.9,-0.46l-0.08,1.09l-1.5,-0.45l-0.65,0.34l-0.76,0.97l-0.86,0.31l-0.31,1.31l0.35,0.41l0.71,-0.1l1.04,0.81l0.14,0.9l0.45,0.39l-0.01,0.67l-0.96,0.66l-1.15,0.24l-1.03,-0.53l-1.06,0.61l-0.75,-0.15l-0.4,0.85l-1.47,-0.09l-0.39,0.34l0.07,0.6l-0.24,0.2l-0.01,-0.61l-0.37,-0.26l-0.47,0.52l-0.29,-0.2l-1.21,0.27l-1.09,-0.7l-1.11,0.75l-1.07,-0.19l-0.59,0.38l-0.6,-0.8l-1.0,0.83l-0.51,-0.21l-0.39,0.41l-0.56,-0.08l-0.41,-0.52l-0.89,0.41l-2.54,-0.02l-0.57,0.46l0.21,1.25l-0.69,0.19l-1.28,-0.58l-0.6,0.58l-0.27,-0.47l-2.11,0.42l-0.15,-0.78l-0.42,-0.26l-0.8,0.55l-0.88,0.01l-0.21,0.68l-0.09,-0.63l-0.43,-0.34l-1.98,-0.12l-0.8,0.43l-0.47,-0.43l-0.6,-0.03l-1.85,0.5l-0.29,0.78l-0.48,0.01l-0.92,0.84l-0.28,-0.29l-0.86,0.21l-1.71,-0.64l-0.82,-0.8l-0.67,0.17l-0.78,-0.82l-1.37,-0.24l-0.94,0.26ZM93.71,499.78l-0.1,0.04l-0.02,-0.1l0.03,-0.01l0.09,0.06ZM117.58,492.02l0.03,-0.03l0.02,0.04l-0.06,-0.02ZM152.12,547.72l-0.04,0.09l-0.09,0.02l0.1,-0.11l0.03,-0.01ZM152.08,548.92l0.07,-0.03l0.17,-0.09l-0.24,0.14l-0.01,-0.02ZM152.67,548.76l-0.0,-0.0l0.02,-0.0l-0.01,0.0ZM152.36,550.7l0.02,-0.26l0.38,-0.09l0.03,0.15l-0.43,0.2ZM93.62,554.78l0.03,0.02l-0.01,0.01l-0.02,-0.02l-0.01,-0.01ZM89.83,555.15l0.34,-0.25l0.08,0.33l-0.25,0.09l-0.17,-0.16ZM121.98,545.28l-0.0,-0.02l0.01,-0.0l-0.0,0.02ZM184.81,574.89l0.06,-1.26l0.41,-0.15l0.06,0.67l-0.52,0.75ZM192.94,585.46l2.13,0.07l0.92,-0.85l0.48,-1.1l0.64,0.02l0.68,-0.53l0.12,-0.67l1.51,0.19l2.05,-0.25l1.01,2.33l-0.69,0.81l0.01,1.79l0.97,0.93l0.15,1.08l0.43,0.37l-0.04,1.98l1.53,2.45l0.25,1.47l-0.62,-0.45l-0.74,0.01l-0.94,0.76l-0.8,1.23l-0.58,-1.41l-0.96,-0.8l0.2,-0.67l-0.22,-1.43l0.59,-1.58l-0.77,-0.57l0.61,-2.62l-0.07,-1.41l0.75,-1.75l-0.68,-0.27l-0.68,1.02l-0.74,-0.1l0.02,0.64l-0.45,0.43l0.28,1.41l-0.5,1.14l0.03,1.77l-0.16,1.06l-0.36,0.36l-0.15,2.47l-0.43,0.57l-0.34,-0.46l0.14,-1.79l-0.28,-0.5l-0.68,0.32l-1.06,-0.12l0.83,-1.68l-0.23,-1.74l1.16,0.09l0.44,-0.41l-0.08,-0.38l-1.07,-0.46l0.04,-1.16l-0.61,-0.36l-0.99,1.28l0.42,0.35l-0.32,0.47l-0.05,-0.5l-0.63,-0.3l0.36,-0.82l-0.28,-0.55l-0.35,-0.01l-0.15,-0.65l-0.45,-0.19l-0.29,0.53l-0.34,-0.87ZM205.18,595.9l0.51,1.31l-0.3,0.8l0.52,2.01l-0.04,1.35l1.23,8.07l-0.73,0.66l0.03,0.61l0.96,0.74l-0.67,1.0l0.04,0.5l0.69,0.74l-0.31,1.71l0.35,0.47l1.03,0.31l1.56,2.31l1.33,1.0l0.34,0.95l0.64,0.53l0.04,0.98l1.46,1.09l-0.25,0.97l-1.25,1.24l-0.44,1.68l-0.09,2.37l-2.17,2.05l-1.09,0.63l-0.6,-0.14l0.03,-1.17l-0.65,0.05l-0.33,1.13l-0.18,-0.03l0.19,-1.57l0.4,-0.15l0.69,0.34l2.37,-1.84l-0.23,-0.63l-0.63,0.14l-0.31,-0.64l-0.68,0.16l1.13,-4.24l-0.41,-0.3l-0.34,-1.2l0.66,-0.25l0.58,-0.92l-0.44,-0.25l-1.75,0.59l-0.61,-0.36l-2.71,0.37l0.59,-0.37l0.5,-1.51l1.69,0.53l0.77,-0.38l-0.04,-0.49l-1.84,-0.71l0.08,-1.11l-0.77,-0.65l0.06,-0.59l-0.47,-0.77l0.4,-0.53l-0.17,-0.67l-0.61,0.01l1.15,-1.43l-0.42,-0.3l-0.79,0.26l-0.61,-1.33l0.45,-0.28l0.28,-1.27l-0.4,-0.33l-0.76,0.13l-0.39,-1.3l-0.54,-0.28l-0.49,0.29l-0.33,-0.41l0.18,-0.35l0.92,0.32l1.06,-0.09l0.44,-0.34l-0.21,-0.7l-1.21,-0.13l0.36,-0.76l-0.58,-0.3l0.13,-0.39l0.77,-0.02l0.73,1.21l0.64,-0.16l-0.3,-1.29l-1.24,-2.0l0.24,-0.72l1.41,1.05l0.48,-0.66l-0.38,-0.53l-1.79,-0.94l0.27,-0.41l-0.22,-0.51l0.64,-0.87l-0.82,-0.31l-0.91,0.97l-0.16,-0.63l0.18,-0.84l0.79,-0.74l0.2,-0.75l0.6,-0.59l0.89,-0.15ZM208.93,628.74l-0.76,0.46l-0.29,-0.26l-0.78,0.13l0.79,-0.68l1.05,0.36ZM204.7,621.12l-0.12,0.63l0.35,0.39l-0.63,0.84l-0.59,-0.47l-0.26,1.1l-0.27,-0.4l0.14,-0.92l0.92,-0.33l0.46,-0.84ZM203.06,601.11l-0.0,-0.02l0.02,0.01l-0.02,0.01ZM203.18,603.81l-0.34,-0.04l0.02,-0.32l0.05,0.12l0.27,0.24ZM137.05,470.84l-0.06,-0.03l0.04,-0.04l0.01,0.06ZM137.68,467.58l-0.59,-0.91l0.33,-1.08l0.63,0.35l-0.37,1.64ZM92.9,502.02l-0.25,0.03l-0.08,-0.14l0.17,0.0l0.15,0.11ZM204.48,625.15l1.0,-0.44l0.32,-0.63l-0.17,-0.3l1.05,-0.42l0.65,-1.26l0.69,-0.03l0.38,2.81l-1.6,2.74l0.41,-1.01l-0.23,-0.46l0.25,-1.9l-0.4,-0.43l-0.41,0.19l-0.23,0.65l-0.86,0.28l-0.33,1.31l-0.53,-1.1ZM202.35,617.95l0.25,-0.5l0.37,-0.04l0.02,0.6l1.17,0.51l0.07,0.27l-0.43,0.14l-0.04,0.81l-0.4,0.1l0.01,-0.99l-1.02,-0.91ZM203.23,617.19l0.16,-0.22l0.23,-0.19l-0.11,0.41l-0.29,-0.0ZM199.26,608.11l1.69,1.02l0.54,0.56l0.07,0.61l0.6,0.17l0.27,-0.43l0.44,0.67l-0.64,1.89l-0.24,-1.66l-0.47,-0.54l-0.59,0.05l-0.24,1.08l0.31,0.48l-0.31,0.46l0.47,0.88l-0.32,0.3l-0.94,-0.68l-0.48,0.37l-0.38,-0.1l1.13,-3.21l-0.9,-1.94ZM197.31,623.55l0.01,0.0l-0.01,0.01l-0.0,-0.01ZM198.81,624.35l0.26,0.02l0.11,-0.51l-0.59,-0.54l0.25,-0.07l-0.02,-0.49l-0.44,-0.29l0.34,-0.37l0.79,-0.11l0.22,-0.65l-0.57,-0.31l-1.23,0.02l-0.3,-0.3l1.67,-1.02l0.2,-0.87l-0.35,-0.1l0.4,-1.16l0.17,0.45l1.31,0.99l0.54,2.03l-0.24,0.95l-0.7,0.33l-0.15,0.56l-0.79,0.26l-0.07,0.44l0.07,0.51l0.74,-0.12l-0.13,0.33l0.89,0.74l0.32,-0.1l0.26,0.69l-0.52,-0.09l-0.44,0.81l0.21,0.41l0.86,0.23l-1.47,0.87l0.11,0.69l0.55,0.33l-0.26,0.36l0.23,0.67l-0.41,0.46l-0.4,-0.23l0.29,-0.4l-0.39,-1.35l0.22,-0.99l-0.43,-0.46l-0.05,-1.6l-0.14,-0.45l-0.64,0.14l-0.3,-0.69ZM199.75,616.82l-0.17,-0.71l-1.16,-0.67l0.39,-0.43l0.81,0.86l0.45,-0.31l0.06,1.17l-0.38,0.09ZM197.37,623.67l-0.05,-0.02l-0.0,-0.02l0.05,0.04ZM196.66,606.6l0.33,-0.82l0.52,-0.2l-0.04,-0.51l0.45,-0.21l0.3,0.3l0.63,-0.48l-0.4,1.22l-1.81,0.71ZM198.89,604.61l-0.01,-0.65l-0.54,-0.16l-0.05,-0.34l0.76,-0.11l0.24,-0.62l-1.0,-0.3l-0.1,-0.43l0.83,-3.96l0.51,-0.53l0.83,0.21l0.33,0.43l-0.86,2.51l0.39,0.25l-0.02,1.64l0.47,0.58l-0.16,0.51l-0.61,-0.22l-0.32,0.32l0.32,1.13l-0.41,-0.58l-0.6,0.33ZM200.04,605.08l0.13,0.03l-0.1,0.05l-0.03,-0.08ZM199.16,596.43l0.05,-0.04l0.01,0.09l-0.03,0.01l-0.04,-0.06ZM197.12,612.93l-0.01,-0.15l0.07,-0.06l0.04,0.09l-0.1,0.12ZM197.33,612.08l-0.06,-0.48l-0.53,-0.15l0.73,0.1l0.13,0.42l-0.27,0.11ZM198.35,611.32l0.01,-0.01l0.0,0.02l-0.01,-0.01ZM197.87,610.42l-0.38,0.28l-0.52,-0.7l-0.52,-0.17l0.82,-0.43l0.68,0.1l-0.08,0.91ZM191.33,596.61l0.28,-0.22l0.69,1.31l0.58,-0.41l-0.6,-1.95l0.41,0.42l0.49,-0.01l0.16,-1.15l0.28,0.49l0.55,0.02l0.65,-0.5l0.66,1.13l-0.46,0.23l-0.8,-0.19l-0.18,0.34l-0.75,0.07l0.03,0.47l1.6,2.42l-0.11,0.82l0.9,0.54l1.03,-0.04l-0.5,1.86l-2.83,-4.15l-0.62,0.31l0.09,0.53l-0.36,0.23l0.52,0.89l-0.24,0.61l0.25,0.42l-0.54,0.21l0.09,-0.47l-0.52,-1.09l0.38,-0.21l-1.09,-2.94ZM193.48,602.03l0.43,0.29l0.44,-0.12l0.04,0.39l0.82,0.62l-0.22,0.42l0.25,2.62l-0.58,2.99l-0.37,1.02l-0.48,0.4l-0.72,2.12l-0.23,-2.46l1.21,-0.72l-0.28,-1.37l-0.48,-0.33l-0.14,-0.74l-0.67,0.01l0.4,-0.8l0.86,-0.1l0.21,-0.3l-0.1,-0.56l-0.63,-0.34l0.71,-0.45l-0.29,-1.35l-0.67,-0.27l0.66,-0.31l-0.16,-0.65ZM192.29,601.49l-0.06,-0.05l0.14,-0.07l-0.09,0.12ZM195.0,597.39l1.23,-0.62l0.83,0.47l0.53,0.88l-0.19,0.37l-0.49,-0.64l-0.66,-0.08l-0.07,0.81l0.44,0.65l-0.54,-0.27l-1.07,-1.56ZM121.33,556.22l0.0,-0.01l0.0,-0.14l0.12,0.22l-0.12,-0.07ZM121.63,556.52l0.34,0.43l0.6,-0.08l-0.09,-0.83l0.94,0.64l0.73,-1.24l0.55,0.06l-0.13,1.37l0.35,0.28l0.55,-0.18l0.23,0.39l-0.74,-0.19l-0.81,0.63l-0.18,-0.92l-0.38,-0.02l-0.89,0.78l-0.15,-0.3l-0.71,0.35l-0.2,-1.18ZM110.5,561.43l0.81,-0.15l0.21,0.12l-0.88,0.66l-0.14,-0.62ZM110.97,560.0l0.25,-1.19l-0.37,-0.6l1.31,-0.91l1.21,0.25l0.43,-0.37l0.94,0.55l-0.79,0.16l-0.0,0.49l0.53,0.38l-0.4,0.89l0.04,1.34l0.79,0.9l0.31,-0.36l-0.17,-0.75l0.49,-1.27l0.38,0.19l0.41,-0.34l1.04,0.1l0.46,-0.32l0.57,0.16l0.19,0.4l0.67,-0.25l0.34,-0.56l0.44,0.32l-0.3,0.81l0.26,0.39l0.51,-0.04l0.39,-0.54l1.36,0.25l-1.29,1.05l0.11,1.18l0.78,0.37l-0.89,0.38l-1.82,-1.92l-0.4,-0.14l-0.92,0.48l0.02,0.77l0.99,0.17l0.3,0.8l-0.21,0.14l-0.36,-0.15l-0.18,-0.71l-0.85,-0.3l-0.31,-0.47l-0.43,0.12l-0.31,0.69l-1.77,-0.5l-0.52,0.65l-0.34,-0.16l0.23,-0.45l-0.22,-0.44l-0.92,-0.01l-0.86,-1.21l-1.08,-0.43ZM117.01,558.18l-0.68,-0.83l0.25,-0.38l0.75,-0.12l0.13,0.54l-0.45,0.79ZM120.32,558.87l0.04,-0.38l0.3,0.01l-0.01,0.16l-0.33,0.21ZM111.96,563.74l-0.0,0.01l-0.03,-0.01l0.03,-0.0ZM111.89,563.74l-0.96,0.32l-0.07,-0.12l0.82,-0.21l0.2,0.01ZM87.34,465.77l-0.13,-0.41l0.43,-0.89l1.28,-0.69l-0.17,1.01l0.79,0.62l0.6,1.23l2.42,0.69l0.41,1.4l-0.83,0.98l1.05,1.74l-0.16,0.96l0.72,0.58l0.04,0.84l0.87,0.31l0.42,0.64l-0.15,0.18l-0.49,0.18l-0.64,-1.15l-0.65,-0.39l-1.91,0.11l0.1,-1.16l-0.52,-1.4l0.31,-0.61l-0.15,-1.23l-0.58,-1.94l-0.94,-0.77l-1.89,-0.25l-0.23,-0.59ZM80.1,501.23l0.23,-0.61l1.58,1.62l0.87,-0.36l0.48,0.38l0.88,-0.08l-0.05,0.41l0.81,0.18l0.17,0.93l0.89,0.58l0.07,0.37l-1.24,1.24l-0.43,1.25l-1.27,-0.9l-0.54,0.09l-1.62,-1.52l-0.38,-2.17l-0.5,-0.59l0.04,-0.82ZM54.96,547.61l0.39,-1.15l1.31,0.26l2.15,-0.87l0.65,0.92l0.8,-0.11l1.96,0.56l0.51,0.5l0.01,0.7l-0.63,1.37l-1.11,0.33l-2.38,-1.9l-1.42,-0.08l-0.79,0.41l-1.44,-0.93ZM36.84,544.83l0.33,0.0l0.55,0.6l-0.18,0.02l-0.7,-0.62ZM41.16,546.38l0.32,-0.36l-0.16,-0.33l0.41,-0.08l0.04,0.51l-0.42,0.48l-0.18,-0.21ZM43.06,546.71l-0.28,-0.33l-0.58,0.04l0.91,-0.23l0.42,-0.6l-1.01,-1.47l0.12,-0.46l0.56,-0.13l1.24,0.82l-0.45,0.54l0.08,0.67l-1.01,1.14ZM42.1,546.34l-0.2,-0.18l0.07,0.0l0.13,0.18ZM43.15,545.53l0.02,-0.02l0.01,0.02l-0.03,0.0l-0.0,-0.01ZM41.89,545.37l0.01,-0.1l0.02,0.01l-0.03,0.08ZM31.02,543.19l1.03,-0.84l0.79,0.02l0.69,0.7l-1.24,0.37l-1.27,-0.26ZM34.55,542.99l0.51,-0.93l0.85,-0.06l0.93,0.44l0.23,0.68l-0.52,0.4l-2.01,-0.54ZM4.68,527.21l0.36,0.16l-0.06,0.26l-0.13,0.03l-0.17,-0.45ZM6.0,527.21l-0.0,-0.7l0.53,0.08l0.05,0.74l-0.58,-0.12Z", "name": "Alaska"}, "US-NJ": {"path": "M802.89,165.46l1.3,-1.54l0.47,-1.56l0.49,-0.62l0.53,-1.44l0.1,-2.03l0.66,-1.34l0.92,-0.72l14.17,3.88l-0.35,5.95l-0.34,0.55l-0.23,-0.43l-0.69,0.12l-0.25,1.17l-0.76,0.97l0.14,1.4l-0.46,0.6l0.1,1.7l0.59,0.6l1.21,0.27l1.38,-0.45l2.31,0.2l0.95,6.8l-0.56,0.39l0.18,0.66l-0.6,0.94l0.47,0.57l-0.2,0.58l0.54,1.91l-0.46,1.98l0.11,0.6l0.62,0.62l-0.38,1.12l-0.49,0.45l-0.0,0.58l-0.92,1.13l0.03,0.51l-1.07,0.12l0.11,1.19l0.64,0.8l-0.81,0.56l-0.17,1.14l1.05,0.74l-0.31,0.29l-0.18,-0.44l-1.02,0.06l-0.43,1.49l-1.27,0.62l-0.19,0.44l0.46,0.55l0.79,0.05l-0.64,1.24l-0.25,1.48l-0.67,0.65l0.19,0.48l0.39,0.04l-0.88,1.55l0.08,0.93l-1.64,1.72l-0.13,-1.31l0.35,-2.41l-0.12,-0.85l-0.59,-0.8l-0.89,-0.26l-1.11,0.36l-0.82,-0.33l-1.51,0.9l-0.31,-0.69l-1.63,-0.92l-1.0,0.06l-0.66,-0.68l-0.7,0.08l-3.26,-1.95l-0.07,-1.7l-1.02,-0.91l0.48,-0.68l-0.0,-0.86l0.42,-0.83l-0.13,-0.72l0.5,-1.17l1.19,-1.17l2.59,-1.51l0.54,-0.86l-0.38,-0.83l0.49,-0.38l0.46,-1.42l1.23,-1.7l2.51,-2.23l0.18,-0.66l-0.48,-0.81l-4.29,-2.67l-0.76,-1.02l-0.9,0.25l-0.48,-0.32l-1.26,-2.4l-1.62,0.01l-1.03,-3.38l1.01,-1.02l0.35,-2.21l-1.88,-1.86Z", "name": "New Jersey"}, "US-CO": {"path": "M364.82,241.98l-1.26,64.81l-29.4,-0.94l-29.49,-1.5l-29.46,-2.05l-32.28,-2.88l8.57,-85.74l27.85,2.51l28.29,2.01l29.65,1.53l28.02,0.91l-0.47,21.33Z", "name": "Colorado"}, "US-MD": {"path": "M742.17,220.02l-2.1,-9.87l19.85,-4.7l-0.65,1.27l-0.95,0.09l-1.54,0.82l0.16,0.69l-0.41,0.49l0.23,0.76l-1.76,0.52l-1.48,0.05l-1.12,-0.36l0.2,-0.35l-0.3,-0.49l-1.11,-0.29l-0.46,1.78l-1.61,2.82l-1.38,-0.37l-1.03,0.63l-0.4,1.24l-1.59,1.92l-0.36,1.03l-0.88,0.46l-1.3,1.86ZM762.21,204.88l36.92,-9.56l8.68,25.66l0.46,0.25l1.06,-0.22l8.18,-2.18l-0.9,0.52l0.32,0.64l0.52,0.0l0.38,0.74l0.52,-0.06l-0.37,1.93l-0.13,-0.26l-0.47,0.07l-0.72,0.86l-0.15,2.66l-0.6,0.2l-0.35,0.7l-0.01,1.64l-3.61,1.41l-0.44,0.7l-2.2,0.46l-0.56,0.65l-0.31,-1.05l0.5,-0.31l0.85,-1.83l-0.41,-0.5l-0.43,0.12l0.06,-0.48l-0.44,-0.41l-2.29,0.66l0.29,-0.59l1.15,-0.84l-0.18,-0.69l-1.36,-0.15l0.37,-2.2l-0.19,-1.01l-0.91,0.17l-0.52,1.75l-0.35,-0.67l-0.62,-0.06l-0.44,0.47l-0.49,1.38l0.54,1.0l-2.89,-2.07l-0.43,-0.18l-0.6,0.37l-0.74,-0.74l0.36,-0.82l-0.04,-0.83l0.75,-0.6l-0.08,-1.33l2.56,0.19l0.77,-1.49l-0.34,-1.4l-0.72,0.28l-0.27,1.28l-0.98,-0.23l-0.38,-1.04l-0.52,-0.27l-0.55,0.23l-0.22,-0.66l-0.63,0.09l1.0,-0.81l0.21,-1.04l-0.54,-0.54l-0.75,0.83l-0.21,-0.59l1.06,-0.92l-0.26,-0.65l-0.54,-0.07l-0.51,-0.73l-0.42,0.23l-0.52,-0.35l0.81,-1.02l-0.25,-1.01l0.82,-1.93l-0.08,-0.85l-0.46,0.02l-0.66,0.67l-0.56,-0.16l-0.48,0.46l-0.19,0.96l-0.95,-1.16l0.73,-3.42l0.59,-0.52l0.07,-0.73l3.89,-0.83l0.48,-0.41l-0.24,-0.67l-0.45,-0.06l-2.37,0.59l0.87,-1.54l1.43,-0.07l0.35,-0.5l-0.99,-0.65l0.42,-1.88l-0.63,-0.32l-0.47,0.39l-0.86,1.93l0.18,-1.98l-0.6,-0.34l-0.88,1.42l-1.41,0.36l-0.3,1.63l0.39,0.53l0.64,0.11l-1.43,1.91l-0.21,-1.61l-0.64,-0.41l-0.6,0.72l0.08,1.44l-0.85,-0.28l-1.15,0.65l0.03,0.71l1.01,0.24l-0.36,0.53l-0.83,0.23l-0.05,0.34l-0.45,-0.03l-0.34,0.65l1.2,1.18l-0.28,0.18l-1.53,-0.73l-1.32,0.49l0.17,0.69l0.82,0.09l1.28,1.17l1.49,0.55l0.1,0.26l-0.44,0.33l-1.37,0.52l-0.11,1.18l1.84,1.0l0.45,0.58l-0.64,-0.4l-1.04,0.3l0.21,0.64l0.92,0.45l-0.33,0.47l0.41,1.13l0.6,0.09l-0.62,1.24l0.14,0.42l0.64,0.63l1.32,4.1l2.86,2.49l-0.0,0.34l-0.38,0.54l-0.68,-1.2l-1.22,-0.2l-1.7,-0.83l-1.53,-3.56l-0.74,-0.66l-0.27,0.69l1.19,3.86l0.66,0.9l1.46,0.78l1.3,0.28l1.5,1.34l0.88,-0.33l0.38,1.29l1.48,1.42l0.11,1.05l-1.09,-0.65l-0.34,-1.21l-0.64,-0.44l-0.45,0.05l-0.12,0.44l0.27,0.77l-0.74,0.14l-0.63,-0.71l-1.16,-0.35l-1.53,0.03l-0.92,0.44l-0.55,-0.19l-1.02,-2.14l-1.27,-0.68l-0.46,0.15l0.01,0.48l1.2,1.94l-0.68,-0.11l-0.29,-0.49l-0.9,-0.38l-1.63,-2.54l-0.48,-0.13l-0.42,1.46l-0.26,-0.73l-0.61,-0.03l-0.4,0.45l0.33,0.72l-0.17,0.68l-0.64,0.6l-0.57,-0.25l-0.64,-1.82l0.25,-1.12l0.71,-0.38l0.19,-0.5l-0.37,-0.51l0.83,-0.52l0.2,-1.59l1.06,-0.36l0.06,-0.66l-0.33,-0.4l0.22,-0.42l-0.38,-0.36l-0.04,-0.68l1.25,-2.18l-0.14,-0.54l-2.73,-1.61l-0.55,0.15l-0.68,1.19l-1.82,-0.34l-1.1,-1.16l-2.96,-0.04l-1.25,-0.87l0.6,-1.34l-0.41,-0.96l-1.19,-0.28l-0.89,-0.63l-2.7,0.11l-0.36,-0.22l-0.12,-1.24l-1.04,-0.58l0.09,-1.18l-0.51,-0.28l-0.48,0.2l-0.24,-0.62l-0.5,-0.13l0.24,-0.81l-0.46,-0.57l-0.69,-0.11l-1.81,0.69l-2.23,-1.21ZM791.64,212.03l0.29,-0.01l0.91,0.19l-0.42,0.4l-0.78,-0.58ZM798.41,217.74l0.0,0.15l-0.12,-0.09l0.12,-0.06ZM804.69,225.0l-0.02,0.32l-0.21,-0.13l0.23,-0.19ZM808.68,228.35l-0.14,0.28l-0.12,0.07l0.01,-0.23l0.25,-0.12ZM799.15,220.1l-0.05,0.01l-0.02,0.01l0.05,-0.03l0.02,0.01ZM798.81,220.25l-0.23,0.54l-0.17,0.12l0.14,-0.59l0.27,-0.07ZM797.68,216.65l-0.6,0.32l-0.58,-0.41l0.02,-0.51l0.16,-0.23l0.68,0.29l0.32,0.54ZM796.02,212.8l-0.23,0.49l-0.8,0.4l0.15,-1.15l0.88,0.26Z", "name": "Maryland"}, "US-MA": {"path": "M821.27,120.49l29.98,-8.43l1.51,-1.81l0.33,-1.48l0.94,-0.36l0.6,-1.04l1.16,-1.06l1.35,-0.12l-0.43,1.05l1.03,0.3l0.23,1.53l1.17,0.53l-0.06,0.32l0.39,0.27l1.31,0.16l-0.16,0.55l-2.27,1.81l-0.03,1.07l0.45,0.15l-1.09,1.41l0.24,1.06l-1.0,0.97l0.6,1.39l1.4,0.42l0.51,0.61l1.35,-0.59l0.32,-0.6l1.2,0.07l0.8,0.45l0.24,0.67l1.8,1.33l-0.06,1.23l-0.55,0.55l0.13,0.6l1.23,0.63l1.72,-0.26l0.69,1.17l0.23,1.13l0.9,0.66l1.33,0.38l1.47,-0.15l0.43,0.37l1.05,-0.25l2.89,-2.37l0.81,-1.12l0.54,0.01l0.58,1.82l-3.31,1.56l-0.93,0.83l-2.74,1.02l-0.47,1.63l-1.92,1.39l-0.84,-2.59l0.1,-1.34l-0.55,-0.3l-0.49,0.4l-0.93,-0.09l-0.3,0.51l0.25,0.9l-0.25,0.79l-0.4,0.07l-0.62,1.1l-0.61,-0.19l-0.49,0.49l0.23,1.83l-0.89,0.88l-0.64,-0.78l-0.47,0.02l-0.1,0.55l-0.26,0.04l-0.72,-1.98l-1.02,-0.34l0.42,-2.47l-0.21,-0.39l-0.77,0.41l-0.28,1.46l-0.69,0.21l-1.41,-0.61l-0.8,-2.08l-0.8,-0.21l-0.8,-2.11l-0.49,-0.23l-6.12,2.09l-0.3,-0.15l-14.81,4.4l-0.28,0.51l-0.47,-0.28l-0.86,0.18l-9.52,2.5l-0.25,-0.17l-0.46,-14.5ZM861.42,110.0l-0.02,-0.36l-0.15,-0.47l0.51,0.21l-0.35,0.62ZM877.17,122.31l-0.12,-0.41l0.25,0.34l-0.13,0.07ZM876.14,120.64l-0.78,0.01l-0.56,-1.17l0.57,0.43l0.77,0.73ZM872.32,119.17l-0.07,0.13l-0.08,-0.06l0.15,-0.07Z", "name": "Massachusetts"}, "US-AL": {"path": "M610.28,337.56l25.27,-3.08l19.47,-2.89l14.3,42.75l0.8,1.38l0.22,1.04l1.18,1.57l0.61,1.86l2.26,2.46l0.94,1.78l-0.1,2.12l1.81,1.11l-0.17,0.73l-0.64,0.11l-0.15,0.7l-0.98,0.85l-0.21,2.28l0.26,1.47l-0.76,2.29l-0.13,1.83l1.13,2.92l1.22,1.5l0.54,1.59l-0.05,5.02l-0.25,0.81l0.5,2.03l1.36,1.15l1.16,2.06l-47.89,7.28l-0.41,0.61l-0.06,3.0l2.67,2.74l2.02,0.95l-0.33,2.71l0.57,1.61l0.44,0.39l-0.94,1.7l-1.24,1.01l-1.14,-0.75l-0.34,0.49l0.67,1.46l-2.84,1.07l0.29,-0.64l-0.45,-0.86l-1.0,-0.76l-0.1,-1.11l-0.57,-0.21l-0.52,0.61l-0.32,-0.1l-0.9,-1.53l0.4,-1.68l-0.99,-2.21l-1.33,-0.64l-0.31,-0.89l-0.56,-0.17l-0.36,0.61l0.15,0.35l-0.76,3.11l0.01,5.1l-0.6,0.0l-0.25,-0.71l-2.24,-0.43l-1.65,0.32l-5.65,-31.94l-1.25,-65.94l-0.02,-0.37l-1.08,-0.62l-0.69,-1.0Z", "name": "Alabama"}, "US-MO": {"path": "M469.58,228.09l24.77,-0.8l18.99,-1.48l22.15,-2.65l0.42,0.34l0.4,0.89l2.44,1.61l0.29,0.73l1.21,0.85l-0.5,1.34l-0.09,3.17l0.79,3.59l0.96,1.41l0.03,1.56l1.11,1.35l0.47,1.53l4.99,4.01l1.07,1.66l4.95,3.23l0.7,1.12l0.28,1.59l0.51,0.8l-0.17,0.68l0.48,1.78l0.98,1.6l0.77,0.72l1.03,0.15l0.83,-0.56l0.83,-1.39l0.58,-0.19l2.42,0.59l1.69,0.74l0.84,0.75l-0.96,1.92l0.27,2.24l-2.36,6.77l0.02,1.01l0.71,1.89l4.7,3.96l2.0,1.02l1.46,0.08l1.67,1.27l1.93,0.78l1.52,2.07l2.05,0.8l0.43,2.91l1.74,2.84l-1.09,1.92l0.19,1.37l0.75,0.32l2.34,4.17l1.94,0.89l0.54,-0.32l0.0,-0.64l0.89,1.08l1.08,-0.08l0.15,1.81l-0.37,1.06l0.54,1.56l-1.06,3.81l-0.52,0.08l-1.38,-1.1l-0.65,0.13l-0.78,3.3l-0.52,0.73l0.13,-1.04l-0.56,-1.07l-0.96,-0.19l-0.74,0.63l0.02,1.04l0.53,0.64l-0.04,0.69l0.59,1.31l-0.2,0.39l-1.2,0.39l-0.17,0.42l1.0,1.36l-1.69,0.37l-0.13,0.62l1.54,1.93l-0.89,0.74l-0.63,2.1l-10.65,1.47l1.05,-2.24l0.87,-0.61l0.18,-0.86l1.44,-0.95l0.25,-0.95l0.92,-0.95l-0.23,-2.25l-1.06,-0.74l-0.2,-0.75l-1.09,-1.16l-39.38,3.78l-37.86,2.71l-3.3,-57.26l-1.04,-0.62l-1.2,-0.02l-1.52,-0.71l-0.2,-0.92l-1.11,-1.27l-0.37,-1.52l-0.56,-0.09l-0.3,-0.55l-1.13,-0.65l-1.4,-1.8l0.73,-0.5l0.09,-1.22l1.12,-1.25l0.09,-0.78l1.02,0.16l0.56,-0.42l-0.21,-2.21l-1.02,-0.72l-0.33,-1.09l-1.17,-0.0l-1.31,0.95l-0.82,-0.69l-0.73,-0.16l-2.68,-2.31l-1.05,-0.27l0.13,-1.58l-1.32,-1.69l0.09,-1.0l-0.37,-0.36l-1.02,-0.17l-0.59,-0.84l-0.83,-0.26l0.07,-0.52l-1.24,-2.84l-0.0,-0.72l-0.4,-0.49l-0.85,-0.28l-0.05,-0.52ZM585.15,295.46l-0.11,-0.1l-0.07,-0.14l0.11,-0.01l0.06,0.24Z", "name": "Missouri"}, "US-MN": {"path": "M444.27,70.94l-0.41,-1.38l0.05,-1.2l-0.48,-0.54l-1.37,-3.82l-0.01,-3.27l-0.47,-2.0l0.27,-1.14l-0.57,-2.36l0.73,-2.61l-2.07,-7.04l29.46,-1.27l0.46,-0.82l-0.41,-7.29l2.83,0.15l1.25,0.84l0.39,2.75l1.75,5.43l0.14,2.35l0.52,0.87l1.46,1.07l1.3,0.5l3.22,-0.37l0.39,0.87l0.54,0.38l5.23,0.03l0.38,0.24l0.55,1.61l0.72,0.62l4.26,-0.8l0.77,-0.66l0.07,-0.71l0.69,-0.36l1.73,-0.45l3.96,-0.03l1.42,0.71l3.38,0.67l-1.0,0.81l0.0,0.83l0.51,0.45l2.9,-0.07l0.53,2.12l1.59,2.33l0.71,0.05l1.03,-0.8l-0.05,-1.76l2.66,-0.47l1.44,2.2l2.01,0.8l1.53,0.18l0.55,0.58l-0.03,0.84l0.59,0.36l1.32,0.06l0.19,0.76l0.42,0.1l1.2,-0.22l1.12,0.22l2.21,-0.87l2.76,-2.6l2.47,-1.57l1.25,2.56l0.97,0.52l2.21,-0.68l0.87,0.36l5.96,-1.34l0.56,0.18l1.33,1.66l1.24,0.6l0.62,-0.01l1.6,-0.84l1.33,0.08l-0.92,1.05l-4.66,3.13l-6.32,2.87l-3.66,2.51l-2.13,2.53l-0.95,0.58l-6.57,8.77l-0.94,0.61l-1.06,1.57l-1.95,1.99l-4.15,3.59l-0.85,1.8l-0.55,0.44l-0.14,0.96l-0.77,-0.01l-0.46,0.51l1.03,12.27l-0.79,1.21l-1.04,0.08l-0.52,0.82l-0.82,0.16l-0.61,0.83l-2.06,1.2l-0.93,1.87l0.07,0.72l-1.69,2.4l-0.0,2.07l0.38,0.91l2.15,0.38l1.43,2.48l-0.51,1.92l-0.71,1.26l-0.04,2.12l0.46,1.32l-0.71,1.23l0.92,3.13l-0.49,4.07l3.96,3.01l3.02,0.38l1.9,2.23l2.88,0.48l2.46,1.91l2.4,3.56l2.64,1.78l2.09,0.08l1.07,0.7l0.88,0.09l0.82,1.35l1.27,0.83l0.28,2.01l0.68,1.29l0.41,4.78l-40.66,3.35l-40.67,2.18l-1.52,-38.79l-1.53,-2.05l-2.57,-0.78l-0.95,-1.91l-1.46,-1.79l0.21,-0.68l2.82,-2.34l0.93,-2.04l0.42,-2.54l-0.36,-1.59l0.23,-1.86l-0.18,-1.52l-0.51,-1.03l-0.19,-2.34l-1.82,-2.6l-0.47,-1.14l-0.22,-2.18l-0.66,-0.98l0.15,-1.67l-0.36,-1.54l0.52,-2.71l-1.08,-1.86l-0.51,-8.4l-0.42,-0.8l0.05,-3.96l-1.58,-4.0l-0.53,-0.66Z", "name": "Minnesota"}, "US-CA": {"path": "M3.09,213.26l1.2,-1.55l-0.39,-7.33l0.62,-1.82l1.46,-2.37l0.31,-2.59l-0.35,-1.2l0.2,-2.35l-0.7,-1.04l-1.22,-3.65l-0.57,-0.54l0.11,-0.92l-0.31,-0.88l-1.03,-0.89l-1.99,-3.3l0.53,-1.21l-0.24,-2.67l3.28,-4.42l0.87,0.32l1.32,-2.17l0.92,0.13l0.64,-0.22l0.41,-0.56l-0.27,-0.82l-0.71,-0.36l1.54,-2.62l0.13,-0.77l-0.42,-0.48l0.1,-1.31l0.86,-0.85l1.19,-2.2l1.29,-2.96l0.4,-2.06l-0.27,-1.0l0.08,-3.84l-1.23,-1.24l0.92,-1.21l0.96,-2.76l32.7,8.51l32.56,7.68l-14.08,63.6l25.33,34.46l36.47,50.78l13.27,17.63l-0.21,2.7l0.73,0.93l0.21,1.69l0.86,0.63l0.8,2.54l-0.08,0.9l0.63,1.44l-0.17,1.35l3.8,3.82l0.01,0.49l-1.96,1.49l-3.13,1.22l-1.21,1.96l-1.73,1.11l-0.34,0.81l0.37,1.02l-0.52,0.51l-0.1,0.89l0.07,2.27l-0.61,0.7l-0.66,2.41l-2.04,2.43l-1.61,0.12l-0.43,0.51l0.33,0.88l-0.6,1.33l0.53,1.11l-0.02,1.17l-0.79,2.66l0.57,1.01l2.75,1.15l0.33,0.83l-0.2,2.38l-1.19,0.76l-0.43,1.36l-2.29,-0.63l-1.26,0.59l-43.58,-3.75l0.05,-0.75l0.39,-0.06l0.31,-0.56l-0.11,-1.38l-1.09,-1.65l-1.09,0.01l0.17,-1.12l-0.24,-1.1l0.35,-0.13l0.37,-0.92l0.07,-2.45l-0.38,-2.63l-2.44,-5.65l-3.46,-4.08l-1.29,-1.97l-2.42,-2.13l-2.06,-2.85l-2.01,-1.06l-1.24,0.16l-0.3,0.87l-1.57,-0.96l-0.11,-0.37l0.64,-0.5l0.23,-0.94l-0.45,-2.63l-1.0,-1.95l-0.7,-0.58l-2.18,-0.45l-1.45,-0.15l-1.12,0.29l-0.49,-0.6l-1.66,-0.66l-3.05,-1.96l-1.24,-1.36l-0.52,-2.62l-0.88,-0.66l-1.76,-2.24l-1.66,-1.31l-1.92,-0.53l-1.1,0.23l-1.1,-0.73l-1.52,-0.16l-2.0,-1.53l-2.34,-0.86l-5.74,-0.73l-0.39,-1.68l-1.98,-1.54l1.34,-2.33l-0.32,-1.37l0.85,-2.18l-0.65,-1.26l1.2,-2.34l0.33,-2.38l-0.99,-1.24l-1.32,-0.27l-1.34,-1.4l-0.08,-0.73l1.45,-1.37l-0.49,-2.28l-0.34,-0.54l-1.68,-0.77l-1.86,-4.25l-1.79,-1.17l-0.31,-2.6l-1.61,-2.6l-0.2,-2.72l-1.01,-0.77l-1.11,-3.36l-2.15,-2.3l-0.75,-1.59l0.06,-3.87l0.48,-0.67l0.08,-0.76l-0.53,-0.6l0.52,-0.51l0.56,0.71l0.58,-0.09l0.81,-0.57l0.91,-1.6l0.83,0.02l0.09,-0.52l-0.5,-0.5l0.41,-0.86l-0.05,-0.93l-0.47,-2.2l-0.61,-1.2l-0.6,-0.44l-0.92,0.23l-2.03,-0.45l-1.45,-1.81l-0.85,-2.13l-0.53,-0.38l-0.31,-1.17l-0.46,-0.5l0.05,-1.1l0.87,-2.22l-0.19,-2.91l-0.88,-1.28l1.12,-2.68l0.23,-2.29l1.34,-0.18l0.21,1.49l-0.62,0.3l-0.12,2.68l1.73,1.18l0.69,1.4l1.0,0.72l0.39,1.0l0.89,0.41l0.85,-0.38l-0.18,-1.18l-0.67,-0.51l-0.36,-1.51l0.14,-1.97l-0.54,-1.25l-0.37,-0.02l-0.09,-0.12l0.61,-0.35l-0.0,-0.34l-1.61,-1.21l0.69,-0.65l-0.16,-1.86l-0.95,-0.37l-0.29,-0.6l1.05,-0.63l0.99,0.01l0.96,-0.68l1.25,1.03l2.63,-0.06l5.0,2.28l0.53,-0.21l0.06,-0.58l0.6,-0.65l-0.3,0.74l0.39,0.76l0.8,-0.05l0.36,-0.48l1.35,1.59l0.7,-0.16l0.03,-0.38l-0.53,-1.13l-0.96,-0.75l-0.26,-0.79l-0.65,-0.39l-1.09,-0.08l0.27,-0.56l-0.25,-0.54l-2.49,1.24l-0.7,-0.34l-0.76,0.17l-0.17,-0.55l-1.09,-0.26l0.29,-0.64l-0.35,-0.69l-1.08,-0.18l-1.87,1.53l-0.34,-0.46l-1.36,-0.55l-0.36,-0.87l-1.35,-1.35l-2.6,0.48l0.1,0.91l-0.7,1.18l0.52,0.72l-0.88,0.89l-0.09,2.24l-0.37,-0.09l-1.52,-2.06l-1.18,-0.35l-1.15,-2.42l-1.41,-1.2l0.1,-0.68l-0.67,-0.19l0.73,-1.14l0.92,2.04l0.44,0.25l0.34,-0.38l-1.74,-5.6l-0.97,-0.79l0.2,-0.82l-0.52,-2.26l-2.7,-3.31l-0.98,-2.96l-2.59,-4.32l-0.84,-2.17ZM31.31,240.12l-0.09,0.13l-0.63,0.21l-0.2,-0.07l0.92,-0.28Z", "name": "California"}, "US-IA": {"path": "M453.69,165.6l42.87,-2.29l40.6,-3.34l0.97,2.5l2.0,0.98l0.08,0.58l-0.89,1.79l-0.15,1.04l0.92,5.04l0.93,1.24l0.39,1.73l1.47,1.69l4.95,0.81l1.27,2.0l-0.3,1.02l0.29,0.66l3.63,2.32l0.86,2.38l3.85,2.26l0.62,1.65l-0.3,4.16l-1.64,1.96l-0.49,1.92l0.14,1.27l-1.25,1.35l-2.52,0.97l-0.89,1.17l-0.55,0.25l-4.57,0.84l-0.89,0.72l-0.6,1.69l-0.15,2.53l0.4,1.06l2.02,1.44l0.55,2.61l-1.86,3.22l-0.21,2.21l-0.52,1.4l-2.89,1.39l-1.02,1.02l-0.2,0.99l0.72,0.85l0.21,2.11l-0.58,0.24l-1.34,-0.81l-0.31,-0.75l-1.29,-0.8l-0.29,-0.5l-0.89,-0.35l-0.3,-0.8l-0.95,-0.67l-22.35,2.69l-15.16,1.21l-7.61,0.53l-20.83,0.54l-0.22,-1.04l-1.3,-0.72l-0.33,-0.66l0.57,-1.13l-0.21,-0.95l0.21,-1.37l-0.36,-2.16l-0.6,-0.71l0.06,-3.6l-1.05,-0.49l0.05,-0.88l0.71,-1.01l-0.05,-0.44l-1.31,-0.55l0.33,-2.51l-0.41,-0.45l-0.89,-0.16l0.23,-0.78l-0.3,-0.58l-0.51,-0.25l-0.74,0.23l-0.42,-2.77l0.5,-2.33l-0.2,-0.67l-1.37,-1.69l-0.08,-1.89l-1.79,-1.52l-0.36,-1.72l-1.09,-0.93l0.03,-2.15l-1.11,-1.85l0.21,-1.67l-0.27,-1.08l-1.38,-0.66l-0.88,-2.14l0.04,-0.63l-1.81,-1.79l0.56,-1.58l0.54,-0.47l0.72,-2.66l0.01,-1.67l0.54,-0.68l0.21,-1.18l-0.51,-2.22l-1.33,-0.28l-0.05,-0.72l0.45,-0.56l-0.0,-1.7l-0.96,-1.41l-0.05,-0.86Z", "name": "Iowa"}, "US-MI": {"path": "M613.3,123.01l1.01,-0.11l0.46,-0.67l-0.39,-3.2l1.08,-0.11l0.66,-1.43l1.19,0.47l0.65,-0.34l0.74,-2.59l0.82,-1.2l0.55,-1.68l0.55,-0.19l-0.57,0.87l0.61,1.65l-0.7,1.8l0.71,0.41l-0.46,2.61l0.89,1.42l0.73,-0.06l0.52,0.55l0.64,-0.24l0.88,-2.26l0.64,-3.51l-0.09,-2.07l-0.78,-3.41l0.58,-1.03l2.12,-1.65l2.74,-0.57l0.98,-0.64l0.28,-0.64l-0.25,-0.54l-1.76,-0.09l-0.97,-0.85l-0.53,-1.98l1.83,-2.99l-0.11,-0.73l1.72,-0.24l0.74,-0.95l4.18,1.97l0.83,0.12l1.98,-0.42l1.38,0.39l0.99,0.79l1.19,1.76l2.74,-0.21l1.71,1.0l1.92,0.07l0.81,0.63l1.16,0.23l1.45,-0.07l1.77,1.03l0.0,1.12l1.05,1.3l0.64,0.2l0.37,0.9l-0.14,0.56l-0.67,-0.25l-0.93,0.58l-0.22,1.83l0.82,1.29l1.61,0.97l0.7,1.36l0.67,2.25l-0.1,1.73l0.8,5.78l-0.78,0.65l-0.4,0.87l-0.74,0.08l-0.79,0.82l-0.14,4.45l-1.12,0.49l-0.17,0.82l-1.86,0.44l-0.72,0.61l-0.56,2.6l0.26,0.45l-0.15,2.27l0.27,0.91l1.33,1.18l2.9,0.81l0.91,-0.08l1.07,-1.23l0.59,-1.44l0.62,0.19l0.39,-0.25l0.99,-3.58l0.59,-1.06l-0.08,-0.51l0.92,-1.41l1.43,-0.44l1.06,-0.69l0.82,-1.1l0.87,-0.45l2.07,0.57l2.15,1.75l1.22,2.13l2.05,5.85l0.83,1.58l1.05,3.67l1.52,3.58l1.42,2.21l-0.43,3.38l0.46,2.45l-0.46,2.76l-0.36,0.45l-0.58,-1.19l0.02,-0.84l-1.47,-0.5l-0.47,0.09l-1.47,1.36l-0.05,0.83l0.54,0.65l-0.81,0.57l-0.29,0.79l0.3,2.9l-0.48,0.75l-1.62,0.93l-1.05,1.84l-0.41,3.69l0.28,1.54l-0.32,0.92l-0.42,0.19l0.02,0.9l-0.63,0.31l-0.88,1.59l-0.49,1.28l-0.02,1.04l-0.52,0.91l-20.52,4.38l-0.15,-0.91l-0.46,-0.33l-31.47,4.93l1.86,-2.22l1.82,-5.87l1.42,-3.03l0.98,-4.96l0.08,-5.29l-1.11,-6.42l-2.21,-4.24l0.6,-0.5l0.3,-0.78l-0.57,-0.42l-1.08,0.55l-4.01,-7.31l0.08,-1.35l0.97,-2.05l-0.02,-0.97l-0.76,-3.1l-1.29,-1.63l-0.05,-0.61l1.71,-2.73l1.2,-4.12l-0.25,-5.32l-0.78,-1.58l1.09,-1.16ZM622.19,118.65l0.0,-0.07l0.11,-0.12l-0.01,0.03l-0.11,0.16ZM622.44,117.74l-0.07,-0.16l0.07,-0.14l0.0,0.3ZM544.06,91.23l4.86,-2.41l3.53,-3.66l5.76,-1.39l1.38,-0.86l2.34,-2.74l0.98,0.03l1.51,-0.74l0.99,-2.27l2.79,-2.88l0.24,1.74l1.85,0.59l0.06,1.45l0.67,0.14l0.51,0.6l-0.15,3.17l0.45,0.96l-0.34,0.48l0.21,0.47l0.74,-0.02l1.06,-2.23l1.07,-0.91l-0.41,1.16l0.59,0.44l0.83,-0.68l0.52,-1.23l1.0,-0.44l3.09,-0.27l1.5,0.2l1.19,0.93l1.54,0.44l0.48,1.05l2.32,2.59l1.17,0.54l0.54,1.56l0.73,0.34l1.87,0.06l0.72,-0.41l1.06,-0.06l1.39,-1.1l1.01,1.11l1.11,0.64l1.01,-0.26l0.67,-0.83l1.88,1.05l0.64,-0.34l1.63,-2.61l2.8,-1.92l1.68,-1.66l0.92,0.1l3.25,-1.23l5.17,-0.28l3.23,-2.12l2.27,-0.9l1.52,-0.12l0.01,3.27l0.3,0.71l-0.35,1.11l0.46,0.7l0.68,0.28l0.91,-0.41l2.2,0.69l1.14,-0.44l1.02,-0.88l0.67,0.48l0.21,0.7l0.85,0.22l1.22,-0.78l0.78,-1.59l0.68,-0.29l1.06,0.22l1.34,-1.16l0.53,-0.01l0.23,0.08l-0.28,2.03l0.77,1.33l-1.11,-0.03l-0.36,0.5l0.85,1.83l-0.86,1.05l0.12,0.45l0.84,0.79l1.36,-0.43l0.6,0.47l0.62,0.04l0.18,1.2l0.99,0.87l1.53,0.5l-1.17,0.69l-4.96,-0.11l-0.53,0.3l-1.35,-0.16l-0.88,0.42l-0.67,-0.75l-1.63,-0.06l-0.59,0.47l-0.06,1.22l-0.49,0.76l0.4,2.05l-0.92,-0.22l-0.9,-0.92l-0.78,-0.13l-1.97,-1.64l-2.41,-0.58l-1.6,0.05l-1.04,-0.5l-2.88,0.49l-0.6,0.45l-1.16,2.54l-3.47,0.76l-0.57,0.77l-2.06,-0.32l-2.81,0.95l-0.68,0.84l-0.54,2.52l-0.77,0.29l-0.81,0.88l-0.65,0.28l0.15,-1.96l-0.75,-0.9l-1.02,0.34l-0.76,0.93l-0.97,-0.39l-0.68,0.17l-0.36,0.4l0.11,0.82l-0.72,2.02l-1.2,0.6l-0.11,-1.37l-0.47,-1.06l0.33,-1.69l-0.17,-0.37l-0.67,-0.16l-0.44,0.57l-0.58,2.13l-0.2,2.57l-1.11,0.91l-1.25,3.04l-0.6,2.66l-2.52,5.34l-0.69,0.74l0.13,0.91l-1.41,-1.27l0.17,-1.74l0.62,-1.69l-0.42,-0.81l-0.62,-0.3l-1.35,0.86l-1.16,0.1l0.03,-1.29l0.8,-1.45l-0.42,-1.34l0.29,-1.09l-0.58,-0.98l0.14,-0.83l-1.91,-1.54l-1.1,-0.05l-0.59,-0.43l-1.48,0.01l0.29,-1.37l-0.95,-1.45l-1.13,-0.51l-2.23,-0.09l-3.2,-0.69l-1.55,0.6l-1.43,-0.42l-1.62,0.17l-4.57,-1.93l-15.38,-2.44l-2.01,-3.4l-1.89,-0.96l-0.76,0.26l-0.1,-0.3ZM603.99,101.57l-0.0,0.52l-0.46,0.32l-0.69,1.4l0.08,0.57l-0.66,-0.58l0.9,-2.16l0.83,-0.07ZM570.97,75.73l-0.51,-0.27l-1.16,0.07l-0.05,-1.58l0.99,-1.03l1.16,-2.12l1.82,-1.52l0.63,-0.01l0.52,-0.59l2.07,-0.91l3.33,-0.44l1.1,0.67l-0.54,0.38l-1.32,-0.12l-2.25,0.79l0.15,0.87l0.72,0.13l-1.19,1.01l-1.39,1.91l-0.69,0.29l-0.34,1.46l-1.14,1.38l-0.64,2.06l-0.67,-0.87l0.74,-0.98l0.12,-1.97l-0.84,-0.22l-0.59,0.93l-0.04,0.67Z", "name": "Michigan"}, "US-GA": {"path": "M655.82,331.47l22.09,-3.74l20.71,-4.04l-0.06,0.57l-2.59,3.34l-0.4,1.72l0.12,1.22l0.83,0.77l2.89,0.87l2.72,1.98l0.84,0.22l1.91,-0.39l0.6,0.24l0.81,1.61l1.52,1.57l1.06,2.46l1.34,0.8l0.85,1.14l0.56,0.26l1.01,1.74l1.08,0.28l1.19,0.97l3.84,1.79l2.44,3.1l2.27,0.55l2.56,1.63l0.51,2.31l1.26,0.99l0.48,-0.17l0.31,0.48l-0.09,0.62l0.79,0.71l0.79,0.08l0.57,1.19l5.02,1.81l0.41,1.76l1.56,1.7l1.04,1.98l-0.07,0.8l0.49,0.68l0.12,1.23l1.05,0.78l2.43,0.76l0.28,0.53l0.58,0.23l1.14,2.53l0.77,0.56l0.1,2.67l0.78,1.47l1.39,0.88l1.53,-0.28l1.46,0.74l1.46,0.1l-0.59,0.78l-0.56,-0.35l-0.47,0.28l-0.4,0.99l0.63,0.9l-0.37,0.48l-1.39,-0.14l-0.78,-0.54l-0.65,0.45l0.26,0.71l-0.48,0.53l0.36,0.6l1.45,0.23l-0.57,1.35l-1.44,0.29l-1.09,-0.43l-0.6,0.22l0.04,0.82l1.47,0.58l-1.74,3.74l0.37,1.73l-0.47,0.98l0.87,1.46l-2.31,-0.16l-0.46,0.3l0.07,0.63l0.55,0.33l2.78,0.21l1.08,0.65l-0.02,0.34l-0.56,0.22l-0.87,1.96l-0.52,-1.41l-0.45,-0.12l-0.6,0.34l-0.14,0.84l0.35,0.96l-0.61,0.12l-0.02,0.84l-0.3,0.16l0.07,0.46l1.35,1.13l-1.09,1.04l0.33,0.47l0.78,0.07l-0.38,0.92l0.06,0.88l-0.46,0.52l1.12,1.65l0.04,0.76l-0.8,0.34l-2.66,-0.14l-4.09,-0.92l-1.31,0.36l-0.17,0.74l-0.68,0.26l-0.34,1.25l0.29,2.08l0.96,1.35l0.17,4.26l-1.99,0.42l-0.55,-0.92l-0.13,-1.3l-1.35,-1.81l-49.48,5.58l-0.73,-0.55l-0.89,-2.69l-0.96,-1.5l-0.57,-0.37l0.15,-0.68l-0.74,-1.5l-1.84,-1.79l-0.44,-1.74l0.25,-0.8l0.03,-5.18l-0.62,-1.8l-1.2,-1.45l-1.05,-2.63l0.11,-1.65l0.77,-2.36l-0.26,-1.52l0.18,-2.1l1.62,-1.34l0.45,-1.47l-0.56,-0.6l-1.43,-0.67l0.08,-2.14l-0.99,-1.85l-2.2,-2.38l-1.05,-2.78l-0.76,-0.67l-0.17,-0.95l-0.78,-1.35l-14.25,-42.57Z", "name": "Georgia"}, "US-AZ": {"path": "M127.77,383.37l0.45,-1.79l1.3,-1.26l0.54,-1.11l0.48,-0.25l1.67,0.63l0.97,-0.03l0.52,-0.45l0.29,-1.16l1.32,-0.98l0.26,-2.71l-0.45,-1.24l-0.84,-0.66l-2.08,-0.68l-0.3,-0.61l0.81,-2.37l0.01,-1.38l-0.51,-1.19l0.57,-0.84l-0.2,-0.86l1.58,-0.25l2.32,-2.76l0.66,-2.41l0.66,-0.79l0.04,-3.14l0.56,-0.61l-0.28,-1.41l1.72,-1.11l1.05,-1.82l3.18,-1.25l2.05,-1.54l0.27,-0.53l-0.12,-1.03l-3.25,-3.48l-0.51,-0.22l0.23,-1.24l-0.65,-1.44l0.08,-0.9l-0.87,-2.74l-0.84,-0.56l-0.18,-1.63l-0.68,-0.79l0.21,-3.49l0.59,-0.85l-0.29,-0.84l1.03,-0.39l0.41,-1.4l0.15,-3.16l-0.75,-3.61l0.77,-2.51l-0.38,-2.96l0.86,-2.51l-0.8,-1.85l-0.03,-0.9l0.79,-1.84l2.55,-0.6l1.75,1.0l1.43,-0.18l0.96,2.22l0.78,0.71l1.54,0.15l1.02,-0.48l1.04,-2.23l0.95,-1.17l2.64,-16.67l42.55,6.06l42.7,4.9l-12.24,122.38l-37.08,-4.25l-36.45,-19.18l-28.5,-15.73Z", "name": "Arizona"}, "US-MT": {"path": "M167.49,59.83l0.72,-0.1l0.33,-0.38l-0.88,-2.02l0.85,-0.96l-0.38,-1.32l0.1,-0.97l-1.22,-1.96l-0.22,-1.51l-1.02,-1.36l-1.16,-2.48l3.76,-21.0l43.48,7.0l42.88,5.45l42.61,4.01l42.99,2.63l-3.73,86.79l-28.11,-1.54l-26.82,-2.0l-26.78,-2.51l-25.83,-2.91l-0.45,0.35l-1.28,10.36l-1.51,-2.01l-0.02,-0.91l-1.17,-2.35l-1.24,-0.75l-1.81,0.9l0.02,1.05l-0.72,0.42l-0.35,1.55l-2.42,-0.42l-1.92,0.55l-0.92,-0.85l-3.36,0.07l-2.38,-0.98l-1.68,0.56l-0.85,1.47l-4.66,-1.63l-1.3,0.36l-1.13,0.89l-0.31,0.66l-1.65,-1.41l0.22,-1.42l-0.89,-1.71l0.4,-0.36l0.07,-0.62l-1.16,-3.07l-1.44,-1.25l-1.45,0.34l-0.21,-0.64l-1.07,-0.9l-0.4,-1.37l0.68,-0.6l0.21,-1.41l-0.75,-2.38l-0.77,-0.36l-0.3,-1.58l-1.49,-2.55l0.24,-1.51l-0.55,-1.27l0.35,-1.4l-0.72,-0.86l0.49,-0.97l-0.21,-0.75l-1.14,-0.76l-0.13,-0.59l-0.84,-0.92l-0.8,-0.4l-0.51,0.37l-0.08,0.75l-0.7,0.26l-1.14,1.21l-1.75,0.35l-1.22,1.06l-1.08,-0.86l-0.63,-1.01l-1.05,-0.45l0.02,-0.86l0.74,-0.63l0.25,-1.06l-0.6,-1.61l0.91,-1.09l1.07,-0.08l0.83,-0.8l-0.25,-1.14l0.39,-1.07l-0.94,-0.81l-0.04,-0.81l0.67,-1.28l-0.58,-1.08l0.74,-0.06l0.39,-0.42l-0.03,-1.78l1.85,-3.73l-0.13,-1.05l0.89,-0.62l0.63,-3.18l-0.78,-0.51l-1.8,0.36l-1.33,-0.12l-0.64,-0.56l0.37,-0.84l-0.61,-0.98l-0.66,-0.23l-0.73,0.35l-0.06,-0.95l-1.73,-1.65l0.06,-1.86l-1.66,-1.85l-0.08,-0.69l-1.52,-2.92l-1.06,-1.31l-0.55,-1.65l-2.34,-1.37l-0.93,-1.98l-1.44,-1.22Z", "name": "Montana"}, "US-MS": {"path": "M557.16,430.87l0.67,-0.97l-1.06,-1.76l0.18,-1.63l-0.82,-0.87l1.7,-0.26l0.47,-0.54l0.39,-2.74l-0.79,-1.81l1.57,-1.8l0.24,-3.57l0.74,-2.26l1.89,-1.25l1.15,-1.97l1.4,-1.04l0.34,-0.78l-0.04,-0.99l-0.64,-0.95l1.15,-0.28l0.96,-2.58l0.91,-1.31l-0.16,-0.86l-1.55,-0.42l-0.35,-0.95l-1.84,-1.03l-0.08,-2.13l-0.94,-0.73l-0.45,-0.83l-0.02,-0.37l1.14,-0.29l0.46,-0.68l-0.26,-0.89l-1.41,-0.48l0.23,-1.76l0.98,-1.53l-0.78,-1.06l-1.08,-0.3l-0.16,-2.8l0.9,-0.54l0.22,-0.8l-0.63,-2.5l-1.26,-0.65l0.7,-1.32l-0.08,-2.2l-2.03,-1.49l1.13,-0.47l0.12,-1.4l-1.35,-0.87l1.57,-2.02l0.93,-0.31l0.36,-0.68l-0.52,-1.55l0.42,-1.35l-0.89,-0.87l2.84,-1.1l0.59,-0.76l-0.09,-1.06l-1.42,-0.93l1.39,-1.07l0.61,-1.76l0.95,-0.17l0.34,-0.97l-0.2,-0.76l1.48,-0.44l1.22,-1.21l0.06,-3.49l-0.47,-1.51l0.36,-1.76l0.74,0.08l0.68,-0.33l0.42,-0.87l-0.41,-1.04l2.73,-1.71l0.58,-1.05l-0.29,-1.26l36.58,-4.31l0.87,1.23l0.85,0.44l1.25,65.95l5.71,32.91l-0.73,0.7l-1.55,-0.29l-0.91,-0.94l-1.32,1.07l-1.24,0.18l-2.05,-1.2l-2.01,-0.23l-0.84,0.37l-0.34,0.44l0.32,0.41l-0.56,0.37l-3.99,1.69l-0.05,-0.5l-0.97,-0.51l-1.0,0.05l-0.58,1.0l0.76,0.61l-1.6,1.22l-0.32,1.28l-0.69,0.31l-1.34,-0.05l-1.18,-1.87l-0.09,-0.89l-0.93,-1.47l-0.21,-1.01l-1.42,-1.63l-1.17,-0.53l-0.47,-0.77l0.1,-0.63l-0.7,-0.92l0.2,-1.99l0.5,-0.94l0.65,-2.99l-0.07,-1.23l-0.43,-0.28l-34.86,3.59Z", "name": "Mississippi"}, "US-SC": {"path": "M699.47,323.52l4.87,-2.71l1.03,-0.06l1.11,-1.38l3.94,-1.92l0.45,-0.88l0.63,0.21l22.62,-3.59l0.31,0.13l-0.1,0.97l0.46,0.66l0.71,0.0l1.21,-1.3l2.85,2.48l0.48,2.44l0.56,0.51l19.54,-3.73l23.17,14.63l0.02,0.54l-2.47,2.19l-2.42,3.67l-2.38,5.71l-0.07,2.72l-1.09,-0.21l0.84,-2.71l-0.64,-0.22l-0.76,0.87l-0.55,1.38l-0.1,1.54l0.85,0.94l1.06,0.22l0.45,0.89l-0.75,0.09l-0.4,0.56l-0.88,0.03l-0.23,0.69l0.95,0.43l-1.1,1.13l-0.07,1.01l-1.35,0.65l-0.5,-0.6l-0.5,-0.07l-1.06,0.87l-0.55,1.77l0.43,0.86l-1.19,1.23l-0.6,1.44l-1.2,1.02l-0.91,-0.39l0.27,-0.59l-0.54,-0.73l-1.37,0.32l-0.11,0.44l0.37,0.76l-0.52,0.03l0.06,0.76l2.04,0.98l-0.12,0.38l-0.88,0.95l-1.22,0.24l-0.24,0.51l0.33,0.44l-2.29,1.36l-1.44,-0.82l-0.56,0.11l-0.1,0.68l1.2,0.76l-1.54,1.58l-0.73,-0.74l-0.49,0.53l-0.0,0.73l-1.55,-0.35l-1.35,-0.82l-0.44,0.5l0.17,0.52l-1.73,0.19l-0.44,0.37l-0.05,0.78l0.65,0.21l0.18,-0.15l1.25,-0.03l-0.25,0.55l0.43,0.25l1.92,-0.17l0.11,0.21l-0.97,0.87l-0.32,0.78l0.57,0.49l0.94,-0.54l0.03,0.21l-1.12,1.1l-1.0,0.45l-0.22,-2.03l-0.7,-0.26l-0.23,-1.54l-0.89,-0.14l-0.3,0.58l0.88,2.67l-1.14,-0.65l-0.64,-0.99l-0.41,-1.75l-0.66,-0.2l-0.53,-0.62l-0.69,0.01l-0.26,0.6l0.86,1.01l0.01,0.67l1.13,1.81l-0.01,0.86l1.24,1.16l-0.63,0.34l0.03,0.98l-1.18,3.56l-1.53,-0.76l-1.53,0.27l-0.98,-0.66l-0.55,-1.02l-0.19,-2.92l-0.87,-0.74l-1.08,-2.45l-1.05,-0.93l-3.25,-1.29l-0.51,-2.63l-1.14,-2.15l-1.44,-1.55l-0.07,-1.06l-0.78,-1.2l-4.85,-1.62l-0.6,-1.26l-1.21,-0.35l0.01,-0.7l-0.54,-0.86l-0.87,0.01l-0.74,-0.59l0.02,-1.2l-0.67,-1.25l-2.72,-1.73l-2.17,-0.49l-2.39,-3.07l-3.96,-1.86l-1.23,-1.01l-0.83,-0.11l-1.06,-1.78l-0.51,-0.21l-0.92,-1.19l-1.19,-0.66l-1.01,-2.38l-1.55,-1.62l-1.04,-1.84l-1.06,-0.36l-2.4,0.24l-2.77,-2.14l-1.07,0.03l-2.24,-1.23l0.35,-2.19l2.59,-3.31l0.15,-1.06ZM752.83,373.64l0.73,-0.08l0.52,0.44l-1.22,1.91l0.28,-1.22l-0.3,-1.05Z", "name": "South Carolina"}, "US-RI": {"path": "M852.19,141.17l0.22,-0.46l-0.55,-2.18l-3.23,-9.82l5.59,-1.92l0.78,2.02l0.81,0.24l0.19,0.72l0.09,0.41l-0.77,0.26l0.03,0.29l0.52,1.43l0.59,0.53l-0.59,0.11l-0.45,0.73l0.88,0.94l-0.13,1.21l0.91,1.86l0.04,1.64l-0.27,0.71l-0.9,0.18l-3.57,2.39l-0.19,-1.28ZM856.9,131.28l0.26,0.09l0.01,0.09l-0.17,-0.08l-0.1,-0.11ZM858.29,131.92l0.25,0.52l-0.05,0.32l-0.16,0.01l-0.05,-0.85Z", "name": "Rhode Island"}, "US-AR": {"path": "M499.95,377.26l-1.49,-37.57l-4.53,-23.62l37.82,-2.71l39.16,-3.76l0.8,1.57l1.02,0.69l0.11,1.73l-0.77,0.56l-0.22,0.92l-1.42,0.93l-0.29,1.03l-0.83,0.54l-1.19,2.56l0.02,0.7l0.53,0.25l10.98,-1.52l0.87,0.91l-1.18,0.36l-0.52,0.95l0.25,0.49l0.84,0.39l-3.61,2.69l0.02,0.84l0.83,1.01l-0.59,1.14l0.62,0.95l-1.42,0.74l-0.11,1.43l-1.45,2.07l0.12,1.62l0.92,3.05l-0.14,0.27l-1.42,0.25l-0.5,1.71l-1.52,0.95l-0.04,0.51l0.8,0.89l0.05,0.63l-1.11,1.2l-2.03,1.13l-0.21,0.62l0.43,0.98l-0.19,0.26l-1.24,0.04l-0.42,0.67l-0.32,1.87l0.47,1.55l0.03,3.04l-1.27,1.09l-1.55,0.14l0.23,1.47l-0.21,0.48l-0.93,0.25l-0.59,1.75l-1.49,1.19l-0.02,0.93l1.4,0.75l-0.02,0.68l-1.24,0.3l-2.24,1.23l0.04,0.67l0.99,0.8l-0.45,1.13l0.54,1.36l-1.09,0.61l-1.9,2.56l0.52,0.7l1.01,0.48l0.01,0.56l-0.99,0.29l-0.42,0.64l0.51,0.83l1.64,0.99l0.07,1.74l-0.59,0.98l-0.09,0.84l1.35,0.78l0.51,2.15l-1.09,1.01l0.07,2.1l-25.97,2.35l-25.74,1.93l-0.86,-11.43l-1.19,-0.85l-0.9,0.17l-0.83,-0.35l-0.93,0.39l-1.23,-0.33l-0.56,0.72l-0.47,0.01l-0.49,-0.48l-0.83,-0.14l-0.63,-0.99Z", "name": "Arkansas"}}, "height": 632.760933701539, "projection": {"type": "lcc", "centralMeridian": -100.0}, "width": 900.0}); | |
0 | 2 | \ No newline at end of file | ... | ... |