This file is indexed.

/usr/share/javascript/polymaps/polymaps.min.js is in libjs-polymaps 2.5.1+ds1-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

1
if(!org)var org={};org.polymaps||(org.polymaps={}),function(a){function d(b){var c=b.indexOf(":");return c<0?b:{space:a.ns[b.substring(0,c)],local:b.substring(c+1)}}function e(a){for(var b=0;b<e.maps.length;b++)e.maps[b].resize()}function f(a){return 360/Math.PI*Math.atan(Math.exp(a*Math.PI/180))-90}function g(a){return 180/Math.PI*Math.log(Math.tan(Math.PI/4+a*Math.PI/360))}function i(a,b){if(a.row>b.row){var c=a;a=b,b=c}return{x0:a.column,y0:a.row,x1:b.column,y1:b.row,dx:b.column-a.column,dy:b.row-a.row}}function j(a,b,c,d,e){var f=Math.max(c,Math.floor(b.y0)),g=Math.min(d,Math.ceil(b.y1));if(a.x0==b.x0&&a.y0==b.y0?a.x0+b.dy/a.dy*a.dx<b.x1:a.x1-b.dy/a.dy*a.dx<b.x0){var h=a;a=b,b=h}var i=a.dx/a.dy,j=b.dx/b.dy,k=a.dx>0,l=b.dx<0;for(var m=f;m<g;m++){var n=i*Math.max(0,Math.min(a.dy,m+k-a.y0))+a.x0,o=j*Math.max(0,Math.min(b.dy,m+l-b.y0))+b.x0;e(Math.floor(o),Math.ceil(n),m)}}function k(a,b,c,d,e,f){var g=i(a,b),h=i(b,c),k=i(c,a);if(g.dy>h.dy){var l=g;g=h,h=l}if(g.dy>k.dy){var l=g;g=k,k=l}if(h.dy>k.dy){var l=h;h=k,k=l}g.dy&&j(k,g,d,e,f),h.dy&&j(k,h,d,e,f)}a.version="2.5.1";var c={x:0,y:0};a.ns={svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink"},a.id=function(){var a=0;return function(){return++a}}(),a.svg=function(b){return document.createElementNS(a.ns.svg,b)},a.transform=function(a,b,c,d,e,f){var g={},h,i,j;return arguments.length||(a=1,c=0,e=0,b=0,d=1,f=0),g.zoomFraction=function(e){return arguments.length?(i=e,h=Math.floor(i+Math.log(Math.sqrt(a*a+b*b+c*c+d*d))/Math.LN2),j=Math.pow(2,-h),g):i},g.apply=function(g){var i=Math.pow(2,-g.zoom),j=Math.pow(2,g.zoom-h);return{column:(a*g.column*i+c*g.row*i+e)*j,row:(b*g.column*i+d*g.row*i+f)*j,zoom:g.zoom-h}},g.unapply=function(g){var i=Math.pow(2,-g.zoom),j=Math.pow(2,g.zoom+h);return{column:(g.column*i*d-g.row*i*c-e*d+f*c)/(a*d-b*c)*j,row:(g.column*i*b-g.row*i*a-e*b+f*a)/(c*b-d*a)*j,zoom:g.zoom+h}},g.toString=function(){return"matrix("+[a*j,b*j,c*j,d*j].join(" ")+" 0 0)"},g.zoomFraction(0)},a.cache=function(a,b){function j(a){i--,b&&b(a),delete e[a.key];if(a.next)a.next.prev=a.prev;else if(g=a.prev)g.next=null;if(a.prev)a.prev.next=a.next;else if(f=a.next)f.prev=null}function k(){for(var a=g;i>h;a=a.prev){if(!a)break;if(a.lock)continue;j(a)}}var c={},d={},e={},f=null,g=null,h=64,i=0;return c.peek=function(a){return e[[a.zoom,a.column,a.row].join("/")]},c.load=function(b,c){var h=[b.zoom,b.column,b.row].join("/"),j=e[h];return j?(j.prev&&(j.prev.next=j.next,j.next?j.next.prev=j.prev:g=j.prev,j.prev=null,j.next=f,f.prev=j,f=j),j.lock=1,d[h]=j,j):(j={key:h,column:b.column,row:b.row,zoom:b.zoom,next:f,prev:null,lock:1},a.call(null,j,c),d[h]=e[h]=j,f?f.prev=j:g=j,f=j,i++,j)},c.unload=function(a){if(a in d){var b=d[a];return b.lock=0,delete d[a],b.request&&b.request.abort(!1)&&j(b),b}return!1},c.locks=function(){return d},c.size=function(a){return arguments.length?(h=a,k(),c):h},c.flush=function(){return k(),c},c.clear=function(){for(var a in e){var h=e[a];h.request&&h.request.abort(!1),b&&b(e[a]),h.lock&&(h.lock=0,h.element.parentNode.removeChild(h.element))}return d={},e={},f=g=null,i=0,c},c},a.url=function(b){function e(e){var f=e.zoom<0?1:1<<e.zoom,g=e.column;if(d)g=e.column%f,g<0&&(g+=f);else if(g<0||g>=f)return null;return b.replace(/{(.)}/g,function(b,d){switch(d){case"S":return c[(Math.abs(e.zoom)+e.row+g)%c.length];case"Z":return e.zoom;case"X":return g;case"Y":return e.row;case"B":var f=a.map.coordinateLocation({row:e.row,column:g,zoom:e.zoom}),h=a.map.coordinateLocation({row:e.row+1,column:g+1,zoom:e.zoom}),i=Math.ceil(Math.log(e.zoom)/Math.LN2);return h.lat.toFixed(i)+","+f.lon.toFixed(i)+","+f.lat.toFixed(i)+","+h.lon.toFixed(i)}return d})}var c=[],d=!0;return e.template=function(a){return arguments.length?(b=a,e):b},e.hosts=function(a){return arguments.length?(c=a,e):c},e.repeat=function(a){return arguments.length?(d=a,e):d},e},a.dispatch=function(a){var b={};return a.on=function(c,d){var e=b[c]||(b[c]=[]);for(var f=0;f<e.length;f++)if(e[f].handler==d)return a;return e.push({handler:d,on:!0}),a},a.off=function(c,d){var e=b[c];if(e)for(var f=0;f<e.length;f++){var g=e[f];if(g.handler==d){g.on=!1,e.splice(f,1);break}}return a},function(c){var d=b[c.type];if(!d)return;d=d.slice();for(var e=0;e<d.length;e++){var f=d[e];f.on&&f.handler.call(a,c)}}},a.queue=function(){function e(){if(c>=d||!b.length)return;c++,b.pop()()}function f(a){for(var c=0;c<b.length;c++)if(b[c]==a)return b.splice(c,1),!0;return!1}function g(a,d,g){function i(){h=new XMLHttpRequest,g&&h.overrideMimeType&&h.overrideMimeType(g),h.open("GET",a,!0),h.onreadystatechange=function(a){h.readyState==4&&(c--,h.status<300&&d(h),e())},h.send(null)}function j(a){return f(i)?!0:a&&h?(h.abort(),!0):!1}var h;return b.push(i),e(),{abort:j}}function h(a,b,c){return g(a,function(a){a.responseText&&b(a.responseText)},c)}function i(a,b){return g(a,function(a){a.responseText&&b(JSON.parse(a.responseText))},"application/json")}function j(a,b){return g(a,function(a){a.responseXML&&b(a.responseXML)},"application/xml")}function k(d,g,h){function j(){i=document.createElement("img"),i.onerror=function(){c--,e()},i.onload=function(){c--,h(i),e()},i.src=g,d.setAttributeNS(a.ns.xlink,"href",g)}function k(a){return f(j)?!0:a&&i?(i.src="about:",!0):!1}var i;return b.push(j),e(),{abort:k}}var b=[],c=0,d=6;return{text:h,xml:j,json:i,image:k}}(),a.map=function(){function A(){r&&(o<r[0]?o=r[0]:o>r[1]&&(o=r[1])),p=o-(o=Math.round(o)),q=Math.pow(2,p)}function B(){if(!z)return;var a=45/Math.pow(2,o+p-3),b=Math.max(Math.abs(u*l.x+t*l.y),Math.abs(w*l.x+v*l.y)),c=f(x-b*a/m.y),d=f(y+b*a/m.y);n.lat=Math.max(c,Math.min(d,n.lat));var e=Math.max(Math.abs(u*l.y+t*l.x),Math.abs(w*l.y+v*l.x)),g=z[0].lon-e*a/m.x,h=z[1].lon+e*a/m.x;n.lon=Math.max(g,Math.min(h,n.lon))}var d={},i,j,k=c,l=c,m={x:256,y:256},n={lat:37.76487,lon:-122.41948},o=12,p=0,q=1,r=[1,18],s=0,t=1,u=0,v=1,w=0,x=-180,y=180,z=[{lat:f(x),lon:-Infinity},{lat:f(y),lon:Infinity}];d.locationCoordinate=function(b){var c=a.map.locationCoordinate(b),d=Math.pow(2,o);return c.column*=d,c.row*=d,c.zoom+=o,c},d.coordinateLocation=a.map.coordinateLocation,d.coordinatePoint=function(a,b){var c=Math.pow(2,o-b.zoom),d=Math.pow(2,o-a.zoom),e=(b.column*c-a.column*d)*m.x*q,f=(b.row*c-a.row*d)*m.y*q;return{x:l.x+t*e-u*f,y:l.y+u*e+t*f}},d.pointCoordinate=function(a,b){var c=Math.pow(2,o-a.zoom),d=(b.x-l.x)/q,e=(b.y-l.y)/q;return{column:a.column*c+(v*d-w*e)/m.x,row:a.row*c+(w*d+v*e)/m.y,zoom:o}},d.locationPoint=function(a){var b=Math.pow(2,o+p-3)/45,c=(a.lon-n.lon)*b*m.x,d=(g(n.lat)-g(a.lat))*b*m.y;return{x:l.x+t*c-u*d,y:l.y+u*c+t*d}},d.pointLocation=function(a){var b=45/Math.pow(2,o+p-3),c=(a.x-l.x)*b,d=(a.y-l.y)*b;return{lon:n.lon+(v*c-w*d)/m.x,lat:f(g(n.lat)-(w*c+v*d)/m.y)}};var C=a.svg("rect");return C.setAttribute("visibility","hidden"),C.setAttribute("pointer-events","all"),d.container=function(a){return arguments.length?(i=a,i.setAttribute("class","map"),i.appendChild(C),d.resize()):i},d.focusableParent=function(){for(var a=i;a;a=a.parentNode)if(a.tabIndex>=0)return a;return window},d.mouse=function(b){var c=(i.ownerSVGElement||i).createSVGPoint();if(h<0&&(window.scrollX||window.scrollY)){var d=document.body.appendChild(a.svg("svg"));d.style.position="absolute",d.style.top=d.style.left="0px";var e=d.getScreenCTM();h=!e.f&&!e.e,document.body.removeChild(d)}return h?(c.x=b.pageX,c.y=b.pageY):(c.x=b.clientX,c.y=b.clientY),c.matrixTransform(i.getScreenCTM().inverse())},d.size=function(a){return arguments.length?(j=a,d.resize()):k},d.resize=function(){return j?(k=j,e.remove(d)):(C.setAttribute("width","100%"),C.setAttribute("height","100%"),b=C.getBBox(),k={x:b.width,y:b.height},e.add(d)),C.setAttribute("width",k.x),C.setAttribute("height",k.y),l={x:k.x/2,y:k.y/2},B(),d.dispatch({type:"resize"}),d},d.tileSize=function(a){return arguments.length?(m=a,d.dispatch({type:"move"}),d):m},d.center=function(a){return arguments.length?(n=a,B(),d.dispatch({type:"move"}),d):n},d.panBy=function(a){var b=45/Math.pow(2,o+p-3),c=a.x*b,e=a.y*b;return d.center({lon:n.lon+(w*e-v*c)/m.x,lat:f(g(n.lat)+(w*c+v*e)/m.y)})},d.centerRange=function(a){return arguments.length?(z=a,z?(x=z[0].lat>-90?g(z[0].lat):-Infinity,y=z[0].lat<90?g(z[1].lat):Infinity):(x=-Infinity,y=Infinity),B(),d.dispatch({type:"move"}),d):z},d.zoom=function(a){return arguments.length?(o=a,A(),d.center(n)):o+p},d.zoomBy=function(a,b,c){if(arguments.length<2)return d.zoom(o+p+a);arguments.length<3&&(c=d.pointLocation(b)),o=o+p+a,A();var e=d.locationPoint(c);return d.panBy({x:b.x-e.x,y:b.y-e.y})},d.zoomRange=function(a){return arguments.length?(r=a,d.zoom(o+p)):r},d.extent=function(a){if(!arguments.length)return[d.pointLocation({x:0,y:k.y}),d.pointLocation({x:k.x,y:0})];var b=d.locationPoint(a[0]),c=d.locationPoint(a[1]),e=Math.max((c.x-b.x)/k.x,(b.y-c.y)/k.y),f=d.pointLocation({x:(b.x+c.x)/2,y:(b.y+c.y)/2});return o=o+p-Math.log(e)/Math.LN2,A(),d.center(f)},d.angle=function(a){return arguments.length?(s=a,t=Math.cos(s),u=Math.sin(s),v=Math.cos(-s),w=Math.sin(-s),B(),d.dispatch({type:"move"}),d):s},d.add=function(a){return a.map(d),d},d.remove=function(a){return a.map(null),d},d.dispatch=a.dispatch(d),d},e.maps=[],e.add=function(a){for(var b=0;b<e.maps.length;b++)if(e.maps[b]==a)return;e.maps.push(a)},e.remove=function(a){for(var b=0;b<e.maps.length;b++)if(e.maps[b]==a){e.maps.splice(b,1);return}},window.addEventListener&&(window.addEventListener("resize",e,!1),window.addEventListener("load",e,!1)),a.map.locationCoordinate=function(a){var b=1/360;return{column:(a.lon+180)*b,row:(180-g(a.lat))*b,zoom:0}},a.map.coordinateLocation=function(a){var b=45/Math.pow(2,a.zoom-3);return{lon:b*a.column-180,lat:f(180-b*a.row)}};var h=/WebKit/.test(navigator.userAgent)?-1:0;a.layer=function(b,d){function r(a){var b=p[0].nextSibling;for(;o<a;o++){m.insertBefore(p[-4],b),m.insertBefore(p[2],b),m.insertBefore(p[1],b);var c=p[-4];for(var d=-4;d<2;)p[d]=p[++d];p[d]=c}}function s(a){var b=p[0].nextSibling;for(;o>a;o--){m.insertBefore(p[-1],b),m.insertBefore(p[2],p[-4]);var c=p[2];for(var d=2;d>-4;)p[d]=p[--d];p[d]=c}}function t(){function D(b){var c=b.zoom,d=c<0?1:1<<c,e=b.column%d,f=b.row;return e<0&&(e+=d),{locationPoint:function(b){var d=a.map.locationCoordinate(b),g=Math.pow(2,c-d.zoom);return{x:t.x*(g*d.column-e),y:t.y*(g*d.row-f)}}}}function K(a,b,c){var d=x.zoom,e=2-B,g=4+B;for(var h=a;h<b;h++){var i=f.load({column:h,row:c,zoom:d},D);if(!i.ready&&!(i.key in F)){i.proxyRefs={};var j,k,l;for(var m=1;m<=e;m++){k=!0;for(var n=0,o=1<<m;n<=o;n++)for(var p=0;p<=o;p++)l=f.peek(j={column:(h<<m)+p,row:(c<<m)+n,zoom:d+m}),l&&l.ready?(F[l.key]=f.load(j),l.proxyCount++,i.proxyRefs[l.key]=l):k=!1;if(k)break}if(!k)for(var m=1;m<=g;m++){l=f.peek(j={column:h>>m,row:c>>m,zoom:d-m});if(l&&l.ready){F[l.key]=f.load(j),l.proxyCount++,i.proxyRefs[l.key]=l;break}}}F[i.key]=i}}var b=e.map(),d=b.zoom(),j=d-(d=Math.round(d)),l=b.size(),q=b.angle(),t=b.tileSize(),u=b.locationCoordinate(b.center());if(o!=d){o<d?r(d):o>d?s(d):o=d;for(var v=-4;v<=2;v++){var w=p[v];w.setAttribute("class","zoom"+(v<0?"":"+")+v+" zoom"+(d+v)),w.setAttribute("transform","scale("+Math.pow(2,-v)+")")}}m.setAttribute("transform","translate("+l.x/2+","+l.y/2+")"+(q?"rotate("+q/Math.PI*180+")":"")+(j?"scale("+Math.pow(2,j)+")":"")+(n?n.zoomFraction(j):""));var x=b.pointCoordinate(u,c),y=b.pointCoordinate(u,{x:l.x,y:0}),z=b.pointCoordinate(u,l),A=b.pointCoordinate(u,{x:0,y:l.y});!j&&!q&&!n&&(u.column=(Math.round(t.x*u.column)+(l.x&1)/2)/t.x,u.row=(Math.round(t.y*u.row)+(l.y&1)/2)/t.y),n&&(x=n.unapply(x),y=n.unapply(y),z=n.unapply(z),A=n.unapply(A),u=n.unapply(u));var B=i?i(x.zoom)-x.zoom:0;if(B){var C=Math.pow(2,B);x.column*=C,x.row*=C,y.column*=C,y.row*=C,z.column*=C,z.row*=C,A.column*=C,A.row*=C,x.zoom=y.zoom=z.zoom=A.zoom+=B}var E=f.locks(),F={};for(var G in E)E[G].proxyCount=0;if(h&&B>-5&&B<3){var H=x.zoom<0?1:1<<x.zoom;if(g)k(x,y,z,0,H,K),k(z,A,x,0,H,K);else{var I=Math.floor((x.column+z.column)/2),J=Math.max(0,Math.min(H-1,Math.floor((y.row+A.row)/2))),v=Math.min(4,x.zoom);I=I>>v<<v,J=J>>v<<v,K(I,I+1,J)}}for(var G in F){var L=F[G],C=Math.pow(2,L.level=L.zoom-u.zoom);L.element.setAttribute("transform","translate("+(L.x=t.x*(L.column-u.column*C))+","+(L.y=t.y*(L.row-u.row*C))+")")}for(var G in E)if(!(G in F)){var L=f.unload(G);L.element.parentNode.removeChild(L.element),delete L.proxyRefs}for(var G in F){var L=F[G];L.element.parentNode!=p[L.level]&&(p[L.level].appendChild(L.element),e.show&&e.show(L))}f.flush(),e.dispatch({type:"move"})}function u(a){if(a.tile.proxyRefs){for(var b in a.tile.proxyRefs){var c=a.tile.proxyRefs[b];--c.proxyCount<=0&&f.unload(b)&&c.element.parentNode.removeChild(c.element)}delete a.tile.proxyRefs}}var e={},f=e.cache=a.cache(b,d).size(512),g=!0,h=!0,i,j,l,m=a.svg("g"),n,o,p={};m.setAttribute("class","layer");for(var q=-4;q<=-1;q++)p[q]=m.appendChild(a.svg("g"));for(var q=2;q>=1;q--)p[q]=m.appendChild(a.svg("g"));return p[0]=m.appendChild(a.svg("g")),e.map=function(a){if(!arguments.length)return l;if(l){if(l==a)return m.parentNode.appendChild(m),e;l.off("move",t).off("resize",t),m.parentNode.removeChild(m)}return l=a,l&&(l.container().appendChild(m),e.init&&e.init(m),l.on("move",t).on("resize",t),t()),e},e.container=function(){return m},e.levels=function(){return p},e.id=function(a){return arguments.length?(j=a,m.setAttribute("id",a),e):j},e.visible=function(a){return arguments.length?((h=a)?m.removeAttribute("visibility"):m.setAttribute("visibility","hidden"),l&&t(),e):h},e.transform=function(a){return arguments.length?(n=a,l&&t(),e):n},e.zoom=function(a){return arguments.length?(i=typeof a=="function"||a==null?a:function(){return a},l&&t(),e):i},e.tile=function(a){return arguments.length?(g=a,l&&t(),e):g},e.reload=function(){return f.clear(),l&&t(),e},e.dispatch=a.dispatch(e),e.on("load",u),e},a.image=function(){function d(d){var e=d.element=a.svg("image"),f=b.map().tileSize();e.setAttribute("preserveAspectRatio","none"),e.setAttribute("width",f.x),e.setAttribute("height",f.y);if(typeof c=="function"){e.setAttribute("opacity",0);var g=c(d);g!=null?d.request=a.queue.image(e,g,function(a){delete d.request,d.ready=!0,d.img=a,e.removeAttribute("opacity"),b.dispatch({type:"load",tile:d})}):(d.ready=!0,b.dispatch({type:"load",tile:d}))}else d.ready=!0,c!=null&&e.setAttributeNS(a.ns.xlink,"href",c),b.dispatch({type:"load",tile:d})}function e(a){a.request&&a.request.abort(!0)}var b=a.layer(d,e),c;return b.url=function(d){return arguments.length?(c=typeof d=="string"&&/{.}/.test(d)?a.url(d):d,b.reload()):c},b},a.geoJson=function(b){function n(a){var b={lat:0,lon:0};return function(c){b.lat=c[1],b.lon=c[0];var d=a(b);return c.x=d.x,c.y=d.y,d}}function o(a,b){return a&&a.type in q&&q[a.type](a,b)}function r(a,b,c){return a.type in s&&s[a.type](a,b,c)}function t(d,f){function h(a){var e=[];a.next&&(d.request=b(a.next.href,h));switch(a.type){case"FeatureCollection":for(var i=0;i<a.features.length;i++){var j=a.features[i],k=o(j.geometry,f);k&&e.push({element:g.appendChild(k),data:j})}break;case"Feature":var k=o(a.geometry,f);k&&e.push({element:g.appendChild(k),data:a});break;default:var k=o(a,f);k&&e.push({element:g.appendChild(k),data:{type:"Feature",geometry:a}})}d.ready=!0,e.push.apply(d.features,e),c.dispatch({type:"load",tile:d,features:e})}var g=d.element=a.svg("g");d.features=[],f=n(f(d).locationPoint),e!=null?d.request=b(typeof e=="function"?e(d):e,h):h({type:"FeatureCollection",features:m||[]})}function u(a){a.request&&a.request.abort(!0)}function v(){var a=c.map().zoom(),b=c.cache.locks(),d,e,f,g,h,i,j;if(k=="fixed"){for(d in b)if((e=b[d]).scale!=a){j="scale("+Math.pow(2,e.zoom-a)+")",g=-1,h=(f=e.features).length;while(++g<h)r((i=f[g]).data.geometry,i.element,j);e.scale=a}}else for(d in b){g=-1,h=(f=(e=b[d]).features).length;while(++g<h)r((i=f[g]).data.geometry,i.element,"");delete e.scale}}var c=a.layer(t,u),d=c.container(),e,f=!0,g="org.polymaps."+a.id(),h="url(#"+g+")",i=d.insertBefore(a.svg("clipPath"),d.firstChild),j=i.appendChild(a.svg("rect")),k="auto",l=null,m;d.setAttribute("fill-rule","evenodd"),i.setAttribute("id",g),arguments.length||(b=a.queue.json);var q={Point:function(b,c){var d=c(b.coordinates),e=a.svg("circle");return e.setAttribute("r",4.5),e.setAttribute("transform","translate("+d.x+","+d.y+")"),e},MultiPoint:function(b,c){var d=a.svg("g"),e=b.coordinates,f,g,h=-1,i=e.length;while(++h<i)g=d.appendChild(a.svg("circle")),g.setAttribute("r",4.5),g.setAttribute("transform","translate("+(f=c(e[h])).x+","+f.y+")");return d},LineString:function(b,c){var d=a.svg("path"),e=["M"],f=b.coordinates,g,h=-1,i=f.length;while(++h<i)e.push((g=c(f[h])).x,",",g.y,"L");e.pop();if(!e.length)return;return d.setAttribute("d",e.join("")),d},MultiLineString:function(b,c){var d=a.svg("path"),e=[],f=b.coordinates,g,h=-1,i,j=f.length,k;while(++h<j){g=f[h],i=-1,k=g.length,e.push("M");while(++i<k)e.push((p=c(g[i])).x,",",p.y,"L");e.pop()}if(!e.length)return;return d.setAttribute("d",e.join("")),d},Polygon:function(b,c){var d=a.svg("path"),e=[],f=b.coordinates,g,h=-1,i,j=f.length,k;while(++h<j){g=f[h],i=-1,k=g.length-1,e.push("M");while(++i<k)e.push((p=c(g[i])).x,",",p.y,"L");e[e.length-1]="Z"}if(!e.length)return;return d.setAttribute("d",e.join("")),d},MultiPolygon:function(b,c){var d=a.svg("path"),e=[],f=b.coordinates,g,h,i=-1,j,k,l=f.length,m,n;while(++i<l){g=f[i],j=-1,m=g.length;while(++j<m){h=g[j],k=-1,n=h.length-1,e.push("M");while(++k<n)e.push((p=c(h[k])).x,",",p.y,"L");e[e.length-1]="Z"}}if(!e.length)return;return d.setAttribute("d",e.join("")),d},GeometryCollection:function(b,c){var d=a.svg("g"),e=-1,f=b.geometries,g=f.length,h;while(++e<g)h=o(f[e],c),h&&d.appendChild(h);return d}},s={Point:function(a,b,c){var d=a.coordinates;b.setAttribute("transform","translate("+d.x+","+d.y+")"+c)},MultiPoint:function(a,b,c){var d=a.coordinates,e=-1,f=h.length,g=b.firstChild,h;while(++e<f)h=d[e],g.setAttribute("transform","translate("+h.x+","+h.y+")"+c),g=g.nextSibling}};c.url=function(b){return arguments.length?(e=typeof b=="string"&&/{.}/.test(b)?a.url(b):b,e!=null&&(m=null),typeof e=="string"&&c.tile(!1),c.reload()):e},c.features=function(a){if(!arguments.length)return m;if(m=a)e=null,c.tile(!1);return c.reload()},c.clip=function(a){if(!arguments.length)return f;f&&d.removeChild(i),(f=a)&&d.insertBefore(i,d.firstChild);var b=c.cache.locks();for(var e in b)f?b[e].element.setAttribute("clip-path",h):b[e].element.removeAttribute("clip-path");return c};var w=c.tile;c.tile=function(a){return arguments.length&&!a&&c.clip(a),w.apply(c,arguments)};var x=c.map;return c.map=function(a){if(a&&j){var b=a.tileSize();j.setAttribute("width",b.x),j.setAttribute("height",b.y)}return x.apply(c,arguments)},c.scale=function(a){return arguments.length?((k=a)?c.on("move",v):c.off("move",v),c.map()&&v(),c):k},c.show=function(a){return f?a.element.setAttribute("clip-path",h):a.element.removeAttribute("clip-path"),c.dispatch({type:"show",tile:a,features:a.features}),c},c.reshow=function(){var a=c.cache.locks();for(var b in a)c.show(a[b]);return c},c},a.dblclick=function(){function e(a){var d=c.zoom();a.shiftKey?d=Math.ceil(d)-d-1:d=1-d+Math.floor(d),b==="mouse"?c.zoomBy(d,c.mouse(a)):c.zoomBy(d)}var a={},b="mouse",c,d;return a.zoom=function(c){return arguments.length?(b=c,a):b},a.map=function(b){if(!arguments.length)return c;c&&(d.removeEventListener("dblclick",e,!1),d=null);if(c=b)d=c.container(),d.addEventListener("dblclick",e,!1);return a},a},a.drag=function(){function e(a){if(a.shiftKey)return;d={x:a.clientX,y:a.clientY},b.focusableParent().focus(),a.preventDefault(),document.body.style.setProperty("cursor","move",null)}function f(a){if(!d)return;b.panBy({x:a.clientX-d.x,y:a.clientY-d.y}),d.x=a.clientX,d.y=a.clientY}function g(a){if(!d)return;f(a),d=null,document.body.style.removeProperty("cursor")}var a={},b,c,d;return a.map=function(d){if(!arguments.length)return b;b&&(c.removeEventListener("mousedown",e,!1),c=null);if(b=d)c=b.container(),c.addEventListener("mousedown",e,!1);return a},window.addEventListener("mousemove",f,!1),window.addEventListener("mouseup",g,!1),a},a.wheel=function(){function i(a){f=null}function l(a){var c=a.wheelDelta||-a.detail,h;if(c)if(d){try{k.scrollTop=1e3,k.dispatchEvent(a),c=1e3-k.scrollTop}catch(j){}c*=.005}else{var l=Date.now();l-b>200?(c=c>0?1:-1,b=l):c=0}if(c)switch(e){case"mouse":h=g.mouse(a),f||(f=g.pointLocation(h)),g.off("move",i).zoomBy(c,h,f).on("move",i);break;case"location":g.zoomBy(c,g.locationPoint(f),f);break;default:g.zoomBy(c)}return a.preventDefault(),!1}var a={},b=0,c=0,d=!0,e="mouse",f,g,h,j=document.createElement("div"),k=document.createElement("div");return k.style.visibility="hidden",k.style.top="0px",k.style.height="0px",k.style.width="0px",k.style.overflowY="scroll",j.style.height="2000px",k.appendChild(j),document.body.appendChild(k),a.smooth=function(b){return arguments.length?(d=b,a):d},a.zoom=function(b,c){return arguments.length?(e=b,f=c,g&&(e=="mouse"?g.on("move",i):g.off("move",i)),a):e},a.map=function(b){if(!arguments.length)return g;g&&(h.removeEventListener("mousemove",i,!1),h.removeEventListener("mousewheel",l,!1),h.removeEventListener("MozMousePixelScroll",l,!1),h=null,g.off("move",i));if(g=b)e=="mouse"&&g.on("move",i),h=g.container(),h.addEventListener("mousemove",i,!1),h.addEventListener("mousewheel",l,!1),h.addEventListener("MozMousePixelScroll",l,!1);return a},a},a.arrow=function(){function j(a){if(a.ctrlKey||a.altKey||a.metaKey)return;var e=Date.now(),i=0,j=0;switch(a.keyCode){case 37:b.left||(c=e,b.left=1,b.right||(i=g));break;case 39:b.right||(c=e,b.right=1,b.left||(i=-g));break;case 38:b.up||(c=e,b.up=1,b.down||(j=g));break;case 40:b.down||(c=e,b.down=1,b.up||(j=-g));break;default:return}(i||j)&&h.panBy({x:i,y:j}),!d&&b.left|b.right|b.up|b.down&&(d=setInterval(m,f)),a.preventDefault()}function k(a){c=Date.now();switch(a.keyCode){case 37:b.left=0;break;case 39:b.right=0;break;case 38:b.up=0;break;case 40:b.down=0;break;default:return}d&&!(b.left|b.right|b.up|b.down)&&(d=clearInterval(d)),a.preventDefault()}function l(a){switch(a.charCode){case 45:case 95:h.zoom(Math.ceil(h.zoom())-1);break;case 43:case 61:h.zoom(Math.floor(h.zoom())+1);break;default:return}a.preventDefault()}function m(){if(!h)return;if(Date.now()<c+e)return;var a=(b.left-b.right)*g,d=(b.up-b.down)*g;(a||d)&&h.panBy({x:a,y:d})}var a={},b={left:0,right:0,up:0,down:0},c=0,d,e=250,f=50,g=16,h,i;return a.map=function(b){if(!arguments.length)return h;h&&(i.removeEventListener("keypress",l,!1),i.removeEventListener("keydown",j,!1),i.removeEventListener("keyup",k,!1),i=null);if(h=b)i=h.focusableParent(),i.addEventListener("keypress",l,!1),i.addEventListener("keydown",j,!1),i.addEventListener("keyup",k,!1);return a},a.speed=function(b){return arguments.length?(g=b,a):g},a},a.hash=function(){function g(){var a=f(d);b!==a&&location.replace(b=a)}function h(){if(location.hash===b)return;e(d,(b=location.hash).substring(1))&&g()}var a={},b,c=90-1e-8,d,e=function(a,b){var d=b.split("/").map(Number);if(d.length<3||d.some(isNaN))return!0;var e=a.size();a.zoomBy(d[0]-a.zoom(),{x:e.x/2,y:e.y/2},{lat:Math.min(c,Math.max(-c,d[1])),lon:d[2]})},f=function(a){var b=a.center(),c=a.zoom(),d=Math.max(0,Math.ceil(Math.log(c)/Math.LN2));return"#"+c.toFixed(2)+"/"+b.lat.toFixed(d)+"/"+b.lon.toFixed(d)};return a.map=function(b){if(!arguments.length)return d;d&&(d.off("move",g),window.removeEventListener("hashchange",h,!1));if(d=b)d.on("move",g),window.addEventListener("hashchange",h,!1),location.hash?h():g();return a},a.parser=function(b){return arguments.length?(e=b,a):e},a.formatter=function(b){return arguments.length?(f=b,a):f},a},a.touch=function(){function j(a){var b=-1,d=a.touches.length,e=Date.now();if(d==1&&e-f<300){var j=c.zoom();c.zoomBy(1-j+Math.floor(j),c.mouse(a.touches[0])),a.preventDefault()}f=e,g=c.zoom(),h=c.angle();while(++b<d)e=a.touches[b],i[e.identifier]=c.pointLocation(c.mouse(e))}function k(b){switch(b.touches.length){case 1:var d=b.touches[0];c.zoomBy(0,c.mouse(d),i[d.identifier]),b.preventDefault();break;case 2:var d=b.touches[0],f=b.touches[1],j=c.mouse(d),k=c.mouse(f),l={x:(j.x+k.x)/2,y:(j.y+k.y)/2},m=a.map.locationCoordinate(i[d.identifier]),n=a.map.locationCoordinate(i[f.identifier]),o={row:(m.row+n.row)/2,column:(m.column+n.column)/2,zoom:0},p=a.map.coordinateLocation(o);c.zoomBy(Math.log(b.scale)/Math.LN2+g-c.zoom(),l,p),e&&c.angle(b.rotation/180*Math.PI+h),b.preventDefault()}}var b={},c,d,e=!1,f=0,g,h,i={};return window.addEventListener("touchmove",k,!1),b.rotate=function(a){return arguments.length?(e=a,b):e},b.map=function(a){if(!arguments.length)return c;c&&(d.removeEventListener("touchstart",j,!1),d=null);if(c=a)d=c.container(),d.addEventListener("touchstart",j,!1);return b},b},a.interact=function(){var b={},c=a.drag(),d=a.wheel(),e=a.dblclick(),f=a.touch(),g=a.arrow();return b.map=function(a){return c.map(a),d.map(a),e.map(a),f.map(a),g.map(a),b},b},a.compass=function(){function v(a){return c.setAttribute("class","compass active"),n||(n=setInterval(w,i)),o&&s.panBy(o),g=Date.now(),F(a)}function w(){o&&Date.now()>g+h&&s.panBy(o)}function x(a){if(a.shiftKey)return q={x0:s.mouse(a)},s.focusableParent().focus(),F(a)}function y(a){if(!q)return;q.x1=s.mouse(a),r.setAttribute("x",Math.min(q.x0.x,q.x1.x)),r.setAttribute("y",Math.min(q.x0.y,q.x1.y)),r.setAttribute("width",Math.abs(q.x0.x-q.x1.x)),r.setAttribute("height",Math.abs(q.x0.y-q.x1.y)),r.removeAttribute("display")}function z(a){c.setAttribute("class","compass"),q&&(q.x1&&(s.extent([s.pointLocation({x:Math.min(q.x0.x,q.x1.x),y:Math.max(q.x0.y,q.x1.y)}),s.pointLocation({x:Math.max(q.x0.x,q.x1.x),y:Math.min(q.x0.y,q.x1.y)})]),r.setAttribute("display","none")),q=null),n&&(clearInterval(n),n=0)}function A(a){return function(){a?this.setAttribute("class","active"):this.removeAttribute("class"),o=a}}function B(a){return function(b){c.setAttribute("class","compass active");var d=s.zoom();return s.zoom(a<0?Math.ceil(d)-1:Math.floor(d)+1),F(b)}}function C(a){return function(b){return s.zoom(a),F(b)}}function D(){this.setAttribute("class","active")}function E(){this.removeAttribute("class")}function F(a){return a.stopPropagation(),a.preventDefault(),!1}function G(b){var c=Math.SQRT1_2*e,d=e*.7,f=e*.2,g=a.svg("g"),h=g.appendChild(a.svg("path")),i=g.appendChild(a.svg("path"));return h.setAttribute("class","direction"),h.setAttribute("pointer-events","all"),h.setAttribute("d","M0,0L"+c+","+c+"A"+e+","+e+" 0 0,1 "+ -c+","+c+"Z"),i.setAttribute("class","chevron"),i.setAttribute("d","M"+f+","+(d-f)+"L0,"+d+" "+ -f+","+(d-f)),i.setAttribute("pointer-events","none"),g.addEventListener("mousedown",v,!1),g.addEventListener("mouseover",A(b),!1),g.addEventListener("mouseout",A(null),!1),g.addEventListener("dblclick",F,!1),g}function H(b){var c=e*.4,d=c/2,f=a.svg("g"),g=f.appendChild(a.svg("path")),h=f.appendChild(a.svg("path")),i=f.appendChild(a.svg("path")),j=f.appendChild(a.svg("path"));return g.setAttribute("class","back"),g.setAttribute("d","M"+ -c+",0V"+ -c+"A"+c+","+c+" 0 1,1 "+c+","+ -c+"V0Z"),h.setAttribute("class","direction"),h.setAttribute("d",g.getAttribute("d")),i.setAttribute("class","chevron"),i.setAttribute("d","M"+ -d+","+ -c+"H"+d+(b>0?"M0,"+(-c-d)+"V"+ -d:"")),j.setAttribute("class","fore"),j.setAttribute("fill","none"),j.setAttribute("d",g.getAttribute("d")),f.addEventListener("mousedown",B(b),!1),f.addEventListener("mouseover",D,!1),f.addEventListener("mouseout",E,!1),f.addEventListener("dblclick",F,!1),f}function I(b){var c=e*.2,d=e*.4,f=a.svg("g"),g=f.appendChild(a.svg("rect")),h=f.appendChild(a.svg("path"));return g.setAttribute("pointer-events","all"),g.setAttribute("fill","none"),g.setAttribute("x",-d),g.setAttribute("y",-0.75*d),g.setAttribute("width",2*d),g.setAttribute("height",1.5*d),h.setAttribute("class","chevron"),h.setAttribute("d","M"+ -c+",0H"+c),f.addEventListener("mousedown",C(b),!1),f.addEventListener("dblclick",F,!1),f}function J(){var a=e+6,b=a,f=s.size();switch(j){case"top-left":break;case"top-right":a=f.x-a;break;case"bottom-left":b=f.y-b;break;case"bottom-right":a=f.x-a,b=f.y-b}c.setAttribute("transform","translate("+a+","+b+")"),r.setAttribute("transform","translate("+ -a+","+ -b+")");for(var g in d)g==s.zoom()?d[g].setAttribute("class","active"):d[g].removeAttribute("class")}function K(){while(c.lastChild)c.removeChild(c.lastChild);c.appendChild(r);if(m!="none"){p=c.appendChild(a.svg("g")),p.setAttribute("class","pan");var b=p.appendChild(a.svg("circle"));b.setAttribute("class","back"),b.setAttribute("r",e);var g=p.appendChild(G({x:0,y:-f}));g.setAttribute("transform","rotate(0)");var h=p.appendChild(G({x:f,y:0}));h.setAttribute("transform","rotate(90)");var i=p.appendChild(G({x:0,y:f}));i.setAttribute("transform","rotate(180)");var n=p.appendChild(G({x:-f,y:0}));n.setAttribute("transform","rotate(270)");var o=p.appendChild(a.svg("circle"));o.setAttribute("fill","none"),o.setAttribute("class","fore"),o.setAttribute("r",e)}else p=null;if(k!="none"){l=c.appendChild(a.svg("g")),l.setAttribute("class","zoom");var q=-0.5;if(k=="big"){d={};for(var t=s.zoomRange()[0],q=0;t<=s.zoomRange()[1];t++,q++)(d[t]=l.appendChild(I(t))).setAttribute("transform","translate(0,"+ -(q+.75)*e*.4+")")}var u=m=="none"?.4:2;l.setAttribute("transform","translate(0,"+e*(/^top-/.test(j)?u+(q+.5)*.4:-u)+")"),l.appendChild(H(1)).setAttribute("transform","translate(0,"+ -(q+.5)*e*.4+")"),l.appendChild(H(-1)).setAttribute("transform","scale(-1)")}else l=null;J()}var b={},c=a.svg("g"),d={},e=30,f=16,g=0,h=250,i=50,j="top-left",k="small",l,m="small",n,o,p,q,r=a.svg("rect"),s,t,u;return c.setAttribute("class","compass"),r.setAttribute("class","back fore"),r.setAttribute("pointer-events","none"),r.setAttribute("display","none"),b.radius=function(a){return arguments.length?(e=a,s&&K(),b):e},b.speed=function(a){return arguments.length?(f=a,b):e},b.position=function(a){return arguments.length?(j=a,s&&K(),b):j},b.pan=function(a){return arguments.length?(m=a,s&&K(),b):m},b.zoom=function(a){return arguments.length?(k=a,s&&K(),b):k},b.map=function(a){if(!arguments.length)return s;s&&(t.removeEventListener("mousedown",x,!1),t.removeChild(c),t=null,u.removeEventListener("mousemove",y,!1),u.removeEventListener("mouseup",z,!1),u=null,s.off("move",J).off("resize",J));if(s=a)t=s.container(),t.appendChild(c),t.addEventListener("mousedown",x,!1),u=t.ownerDocument.defaultView,u.addEventListener("mousemove",y,!1),u.addEventListener("mouseup",z,!1),s.on("move",J).on("resize",J),K();return b},b},a.grid=function(){function f(b){var f,g=e.firstChild,h=d.size(),i=d.pointLocation(c),j=d.pointLocation(h),k=Math.pow(2,4-Math.round(d.zoom()));i.lat=Math.floor(i.lat/k)*k,i.lon=Math.ceil(i.lon/k)*k;for(var l;(l=d.locationPoint(i).x)<=h.x;i.lon+=k)g||(g=e.appendChild(a.svg("line"))),g.setAttribute("x1",l),g.setAttribute("x2",l),g.setAttribute("y1",0),g.setAttribute("y2",h.y),g=g.nextSibling;for(var m;(m=d.locationPoint(i).y)<=h.y;i.lat-=k)g||(g=e.appendChild(a.svg("line"))),g.setAttribute("y1",m),g.setAttribute("y2",m),g.setAttribute("x1",0),g.setAttribute("x2",h.x),g=g.nextSibling;while(g){var n=g.nextSibling;e.removeChild(g),g=n}}var b={},d,e=a.svg("g");return e.setAttribute("class","grid"),b.map=function(a){if(!arguments.length)return d;d&&(e.parentNode.removeChild(e),d.off("move",f).off("resize",f));if(d=a)d.on("move",f).on("resize",f),d.container().appendChild(e),d.dispatch({type:"move"});return b},b},a.stylist=function(){function f(d){var f=d.features.length,g=b.length,h=c.length,i,j,k,l,m,n,o;for(n=0;n<f;++n){if(!(k=(i=d.features[n]).element))continue;j=i.data;for(o=0;o<g;++o)m=(l=b[o]).value,typeof m=="function"&&(m=m.call(null,j)),m==null?l.name.local?k.removeAttributeNS(l.name.space,l.name.local):k.removeAttribute(l.name):l.name.local?k.setAttributeNS(l.name.space,l.name.local,m):k.setAttribute(l.name,m);for(o=0;o<h;++o)m=(l=c[o]).value,typeof m=="function"&&(m=m.call(null,j)),m==null?k.style.removeProperty(l.name):k.style.setProperty(l.name,m,l.priority);if(m=e){typeof m=="function"&&(m=m.call(null,j));while(k.lastChild)k.removeChild(k.lastChild);m!=null&&k.appendChild(a.svg("title")).appendChild(document.createTextNode(m))}}}var b=[],c=[],e;return f.attr=function(a,c){return b.push({name:d(a),value:c}),f},f.style=function(a,b,d){return c.push({name:a,value:b,priority:arguments.length<3?null:d}),f},f.title=function(a){return e=a,f},f}}(org.polymaps);