Advertisement
Guest User

Untitled

a guest
Sep 30th, 2017
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*!
  2.  *
  3.  * Jquery Mapael - Dynamic maps jQuery plugin (based on raphael.js)
  4.  * Requires jQuery and Mapael >=2.0.0
  5.  *
  6.  * Map of Australia
  7.  *
  8.  * @author author name
  9.  */
  10. (function (factory) {
  11.     if (typeof exports === 'object') {
  12.         // CommonJS
  13.         module.exports = factory(require('jquery'), require('jquery-mapael'));
  14.     } else if (typeof define === 'function' && define.amd) {
  15.         // AMD. Register as an anonymous module.
  16.         define(['jquery', 'mapael'], factory);
  17.     } else {
  18.         // Browser globals
  19.         factory(jQuery, jQuery.mapael);
  20.     }
  21. }(function ($, Mapael) {
  22.  
  23.     "use strict";
  24.    
  25.     $.extend(true, Mapael,
  26.         {
  27.             maps :  {
  28.                 australia : {
  29.                     width : 760.14435,
  30.                     height : 821.64587,
  31.                     getCoords : function (lat, lon) {
  32.                         // todo
  33.                         return {"x" : long, "y" : lat};
  34.                     },
  35.                     'elems': {
  36.                         "southern" : "m 746.7,698.29 c 3.96,-67.65 8.73,-148.2 10.59,-179 1.86,-30.8 3.12,-56.28 2.8,-56.63 -0.33,-0.35 -38.39,-1.14 -84.59,-1.77 -46.2,-0.63 -118.13,-1.62 -159.83,-2.2 -41.71,-0.58 -76.05,-0.84 -76.32,-0.57 -0.68,0.68 5.82,168.04 6.56,168.8 0.33,0.34 6.22,0 13.1,-0.76 9.51,-1.05 14.84,-2.25 22.26,-5 12.07,-4.47 17.99,-4.4 25.46,0.3 2.63,1.66 7.08,4.46 9.88,6.22 3.98,2.51 7.58,3.65 16.5,5.23 23.47,4.16 46.42,14.09 48.19,20.85 0.67,2.56 -2.32,6.38 -6.25,8.01 -5.41,2.24 -3.46,5.06 4.47,6.46 5.39,0.95 11.37,4.56 15.95,9.63 5.96,6.59 7.75,11.78 8.61,24.92 0.81,12.29 1.83,16.18 5.18,19.76 2.15,2.3 6.16,2.92 8.65,1.34 0.86,-0.54 1.64,-3.65 2.05,-8.1 0.76,-8.28 0.69,-8.2 19.81,-23.83 7.03,-5.75 12.44,-11.27 17.41,-17.8 6.16,-8.09 7.58,-9.42 9.77,-9.17 3.21,0.38 5.28,4.42 5.88,11.5 0.71,8.47 -0.44,12.03 -5.74,17.68 -6.2,6.62 -7.11,8.5 -8.15,16.74 -0.92,7.29 -3.38,13.18 -6.81,16.28 -2.79,2.53 -2.67,3.12 0.96,4.62 2.71,1.12 3.29,1.05 4.92,-0.63 1.02,-1.05 3.07,-5.94 4.56,-10.88 5.49,-18.18 15.56,-20.96 22.86,-6.32 3.83,7.68 3.51,12.72 -1.41,22.06 -2.2,4.18 -4,7.85 -4,8.17 0,0.32 3.76,0.57 8.35,0.57 7.02,0 8.88,0.36 11.66,2.25 8.27,5.63 12.42,14.78 14.04,31.01 0.56,5.63 1.74,12.49 2.61,15.24 4.31,13.56 15.5,29.04 20.49,28.33 l 2.35,-0.33 7.2,-123 z",
  37.                         "western" : "m 153.76,751.79 c 14.8,-3.53 26.02,-9.68 30.77,-16.85 2.88,-4.36 6.85,-6.9 13.27,-8.49 4.34,-1.08 4.86,-1.56 7.43,-6.93 3.16,-6.59 3.83,-6.96 15.78,-8.67 4.96,-0.71 12.68,-2.85 18.56,-5.14 5.53,-2.16 11.06,-3.92 12.29,-3.92 1.23,0 5.6,1.78 9.71,3.96 4.11,2.18 8.04,3.79 8.71,3.58 0.68,-0.21 6.19,-1.96 12.24,-3.89 6.05,-1.93 13.55,-4.21 16.66,-5.08 6.95,-1.93 9.45,-4.68 13.83,-15.22 1.78,-4.28 3.93,-8.83 4.76,-10.11 2.24,-3.43 8.81,-6.89 16.74,-8.82 9.01,-2.2 11.46,-3.48 19.13,-9.99 11.43,-9.7 18.58,-11.89 35.35,-10.86 12.54,0.77 16,-0.26 30.78,-9.21 5.23,-3.16 11.7,-6.21 14.57,-6.86 l 5.17,-1.17 -0.3,-8.92 c -0.16,-4.9 -4.55,-118.11 -9.75,-251.57 C 424.25,234.17 420,123.7 420,122.13 c 0,-2.48 -0.55,-3.02 -4.25,-4.17 -5.65,-1.75 -11.7,-5.53 -26.98,-16.82 C 373.51,89.85 365.51,85.79 358.57,85.79 l -4.93,-7.9e-4 -9.57,9.96 c -10.38,10.81 -13.26,12.51 -23,13.61 -4.01,0.45 -7.02,1.38 -8.15,2.52 -2.14,2.14 -4.47,9.54 -5.43,17.23 -0.42,3.4 -1.47,6.36 -2.71,7.69 -1.83,1.97 -2.64,2.1 -8.92,1.47 -10.64,-1.07 -12.49,1.68 -6.32,9.44 4.11,5.17 5,7.97 3.75,11.73 -1.72,5.16 -5.48,6.89 -14.35,6.58 C 271.17,165.75 264,167.47 264,169.6 c 0,0.5 2.47,4.69 5.48,9.3 3.01,4.61 5.49,9.15 5.5,10.09 0.01,0.94 -1.83,3.19 -4.09,5 -2.26,1.81 -4.74,4.53 -5.53,6.05 -1.8,3.47 -5.75,3.73 -7.57,0.5 -0.7,-1.24 -3.98,-8.26 -7.29,-15.61 -3.31,-7.35 -6.47,-13.4 -7.01,-13.45 C 240.1,171.18 225,195.94 225,201.82 c 0,1.54 1.57,7.82 3.5,13.96 4.04,12.89 3.79,14.39 -2.59,15.41 -6.22,1 -10.15,5.46 -12.27,13.96 -2.36,9.44 -5.59,15.4 -12.29,22.63 -10.59,11.44 -24.76,19.76 -37.4,21.98 -3.55,0.62 -8.85,1.54 -11.78,2.04 -3.53,0.61 -6.43,1.88 -8.6,3.78 -7.52,6.6 -31.7,19 -50.08,25.67 -29.36,10.67 -35.53,13.83 -37.6,19.31 -1.6,4.22 -4.62,6.99 -14.98,13.73 -9.64,6.27 -13.51,10.2 -20.38,20.67 -3.93,5.99 -5.65,7.24 -8.66,6.28 C 9.89,380.62 8.51,376.52 7.39,367.84 6.88,363.87 6.49,362.93 5.95,364.38 4.97,367.05 0,394.21 0,396.93 c 0,1.19 2.06,5.94 4.58,10.56 5.27,9.66 5.28,10.62 0.3,24.98 -5.46,15.76 -3.47,21.87 11.69,35.81 C 27.96,478.75 32,485.74 32,494.98 c 0,7.69 -1.62,11.25 -7.85,17.28 C 21.32,515 19,517.8 19,518.5 c 0,0.69 3.82,5.48 8.49,10.64 8.82,9.75 12.45,15.94 12.49,21.3 0.03,3.78 4.59,10.01 17.8,24.33 5.1,5.53 9.75,11.29 10.32,12.79 0.57,1.51 2.78,9.61 4.9,18 4.43,17.5 7.32,24.46 13,31.24 7.18,8.58 11.53,21.2 14.48,42 1.69,11.93 2,30.24 0.56,32.93 -0.53,0.99 -2.3,2.07 -3.92,2.39 -8.04,1.61 -11.89,14.9 -6.01,20.77 1.71,1.71 2.8,1.9 7.78,1.33 7.64,-0.86 10.89,0.86 16.11,8.55 2.23,3.28 4.96,6.45 6.08,7.05 6.19,3.32 18.71,3.3 32.69,-0.04 z",
  38.                         "northern" : "m 678.11,454.54 c 0.06,-0.14 2.68,-65.5 5.82,-145.25 l 5.71,-145 -2.07,-2.19 c -1.14,-1.2 -8.96,-6.05 -17.38,-10.76 -30.57,-17.13 -47.69,-29.19 -53.3,-37.55 -3.63,-5.41 -3.68,-8.51 -0.19,-11.32 11.26,-9.06 13.26,-12.64 15.79,-28.31 1.65,-10.18 2.97,-12.44 8.94,-15.33 C 649.81,54.76 662,39.18 662,32.53 c 0,-1.95 -0.73,-2.8 -3.15,-3.64 -5.77,-2.01 -10.46,-1.38 -14.2,1.9 -5.01,4.4 -9.24,4.12 -15.15,-1 -4.91,-4.25 -7.47,-4.81 -11.5,-2.5 -3.66,2.09 -7.43,1.81 -12.77,-0.95 -3.44,-1.79 -7.55,-2.74 -15.09,-3.5 -17.54,-1.77 -23.91,-3.92 -40.81,-13.76 -11.15,-6.49 -20.68,-9.92 -24.74,-8.9 C 522.37,0.73 522,1.37 522,4.61 c 0,2.08 0.93,6.53 2.06,9.89 2.8,8.3 2.34,13.92 -1.39,16.68 -2.66,1.97 -4.06,2.1 -23.5,2.1 -20.58,0 -20.7,0.01 -25.19,2.66 -5.45,3.2 -14.3,13.13 -16.99,19.05 -1.07,2.36 -1.96,6.14 -1.97,8.39 -0.02,2.88 -0.65,4.66 -2.14,6 -6.55,5.9 -11.26,16.53 -12.92,29.16 -1.41,10.73 -3.52,16 -7.33,18.32 -1.72,1.05 -3.92,1.91 -4.88,1.92 -1.53,0 -1.74,1.05 -1.7,8.25 0.09,15.51 12.51,323.64 13.06,324.19 0.3,0.3 35.84,1.02 78.97,1.58 43.13,0.57 84.04,1.15 90.92,1.29 19.71,0.4 68.99,0.71 69.11,0.44 z"
  39.                     }
  40.                 }
  41.             }
  42.         }
  43.     );
  44.  
  45.     return Mapael;
  46.  
  47. }));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement