(function(){function vi(){return window.location.hostname.indexOf("staging.scribblemaps.com")!=-1}function k(n){return n==null||n==""||n==undefined?!0:!1}function tt(n,t){var i=document.createElement("link");t&&(i.onload=function(){pi=!0;t()});i.setAttribute("rel","stylesheet");i.setAttribute("type","text/css");i.setAttribute("href",n);document.getElementsByTagName("head")[0].appendChild(i)}function et(n,t,i){var r,u;document.readyState==="complete"||document.readyState==="interactive"?(r=document.createElement("script"),r.src=n,r.type="text/javascript",i&&r.setAttribute("crossorigin","anonymous"),r.onload=r.onreadystatechange=function(){this.readyState&&this.readyState!=="loaded"&&this.readyState!=="complete"||(t&&t(),r.onload=r.onreadystatechange=null)},u=document.getElementsByTagName("script")[0],u.parentNode.insertBefore(r,u)):setTimeout(function(){et(n,t,i)},100)}function lr(){return window.sm_overrides&&window.sm_overrides.baseAPI&&window.sm_overrides.baseAPI.indexOf("google")==-1?!1:!0}function ot(){clearTimeout(ni);ni=setTimeout(function(){c()},250)}function ar(){for(var n=0;n<nt.length;n++)if(nt[n].opts.useStatic&&(!window.L||!window.L.Map))return ot(),!1;return(u=="google"||u=="googleEnterprise"||u=="googleKey")&&lr()?window.google!=null&&window.google.maps!=null?!0:(ot(),!1):u=="bing"?window.Microsoft&&window.Microsoft.Maps?!0:(ot(),!1):u=="arcgis"?window.esri&&window.esri.layers?!0:(ot(),!1):u=="cesium"?window.Cesium?!0:(ot(),!1):window.L&&window.L.Map?!0:(ot(),!1)}function vr(){if(ti==gt.length)return!0}function c(){return yi&&ct&&pi&&ar()&&vr()?(clearTimeout(ni),yr(),window[st]&&!ii&&(ii=!0,window[st]()),!0):!1}function yr(){for(var n=0;n<nt.length;n++)nt[n].makeReal();nt=[];l=[]}function wi(){for(var n=0;n<nt.length;n++)nt[n].createLoader()}function di(n,t,i,r,u,f){var e;if(ci.indexOf(t)==-1){if(ci.push(t),v[t].css)for(e=0;e<v[t].css.length;e++)tt(n+v[t].css[e]);if(window.sm_overrides&&window.sm_overrides.baseAPI)et(window.sm_overrides.baseAPI.replace("{gurl}",ki).replace("{key}",i).replace("{clientId}",r).replace("{libraries}",u).replace("{lang}",f),function(){c()});else for(t=="bing"&&vt=="https://"&&(v[t].scripts[0]+="&s=1"),e=0;e<v[t].scripts.length;e++)et((n+v[t].scripts[e]).replace("{gurl}",ki).replace("{key}",i).replace("{clientId}",r).replace("{libraries}",u).replace("{lang}",f),function(){c()})}}function gi(){var i="",t;return i!=""&&g!="null"?i:n.projectId||n.pId?n.projectId||n.pId:ui&&(t=ui.src.match(/pId=([0-9a-zA-Z-]+)/),t&&t[1])?t[1]:null}function kr(){var t="css/",i,r;for(vi()&&(t="staging-css/"),i=h&&h!=""?"?d="+h:"",n.theme=="dark"?tt(b+t+"dark.css"+i,function(){c()}):n.theme=="light"?tt(b+t+"light.css"+i,function(){c()}):n.theme=="light2021"?tt(b+t+"light2021.css"+i,function(){c()}):n.theme=="dark2021"?tt(b+t+"dark2021.css"+i,function(){c()}):n.theme=="ash2021"?tt(b+t+"ash2021.css"+i,function(){c()}):tt(b+t+"modern.css"+i,function(){c()}),tt(ft+"themes/icons/glyphicons.css"),r=0;r<gt.length;r++)et(gt[r],function(){ti++;c()});et(er,function(){yi=!0;c()},!0)}function ir(n){return n==null||n==""?!0:!1}function rr(){var t=n.key,i=n.libraries,r=n.clientId,f=ir(hi)?ir(n.lang)?"":n.lang:hi,e=navigator.languages?navigator.languages[0]:navigator.language||navigator.userLanguage;di(dt,u,t,r,i,f);kr()}var y,t,p,r,ht,yt,f,o,d,i,pt,s,wt,ti,ii,lt,ri,bt,a,it,ut,w,fi,ei,u,g,nr,tr,ur;window.scribblemaps=window.scribblemaps||{};var nt=[],vt=document.location.protocol=="https:"?"https://":"http://",si=!0,kt="1.613",hi="",st="";st=st==""?null:st;var h="2023-02-22",dt="",ci=[],fr=document.URL.indexOf("http://")===-1&&document.URL.indexOf("https://")===-1;fr&&(dt="http:");var li="cdn.scribblemaps.com",ft=vt+li+"/api/js/shared/",b=vt+li+"/api/js/"+kt+"/",ai=vt+"www.scribblemaps.com/",er=vi()?b+"staging-scripts/main.js"+(h&&h!=""?"?d="+h:""):b+"scripts/main.js"+(h&&h!=""?"?d="+h:"");var or=ft+"scripts/sanitizer.js"+(h&&h!=""?"?d="+h:""),sr=ft+"scripts/apis/date-fns.js"+(h&&h!=""?"?d="+h:""),gt=[or,sr],e=function(n,t,i){window.scribblemaps[n]=t;i||(window[n]||window[n]==t?window[n]!=t&&console.log("Could not register global variable "+n+" variable available using scribblemaps."+n):window[n]=t)};y={};y.SEARCH="0";y.ZOOM="1";y.TOOLBOX="2";y.LINE_SETTINGS="3";y.LINE_COLOR="4";y.FILL_COLOR="5";y.MAP_TYPE="6";y.LEGEND="7";y.GPS="10";y.LAYERS="undefined";y.OVERLAY_LIST="8";e("ControlType",y,!0);t={};t.NONE="none";t.MENU="menu";t.DRAG="drag";t.DRAGEDIT="dragEdit";t.DRAGEDITADVANCED="dragEditAdvanced";t.DRAW="scribble";t.DRAWSNAP="scribbleSnap";t.LINE="line";t.LINESNAP="lineSnap";t.PEN="pen";t.FLIGHT_LINE="flightLine";t.EDIT="edit";t.EDITADVANCED="editAdvanced";t.LABEL="label";t.LABELMULTI="labelMulti";t.POLYGON="polygon";t.MARKER="marker";t.SINGLE_MARKER="singleMarker";t.ERASER="eraser";t.CIRCLE="circle";t.RECTANGLE="rectangle";t.FILL="fill";t.SELECT="select";t.IMAGE="image";t.CONNECTED_LINE="connectedLine";t.ROUTE="route";t.ROTATE="rotate";t.SPLIT_LINE="splitLine";t.SPLIT="splitLine";t.STYLE_PICKER="stylePicker";t.DIMENSION_LINE="dimensionLine";e("ToolType",t,!0);p={};p.LINE="1";p.RECT="2";p.CIRCLE="3";p.POLYGON="4";p.LABEL="5";p.MARKER="6";p.IMAGE="7";p.FLIGHT_LINE="16";p.INFO_BUBBLE="17";p.MEDIA_MARKER="18";p.POINT="19";e("OverlayType",p,!0);r={};r.MARKER="1";r.TEXT_EDITOR="2";r.SETTINGS="3";r.LOAD_MAP="4";r.SAVE_MAP="5";r.WIDGET="6";r.MAP_INFO="7";r.MENU="8";r.SAVE_IMAGE="9";r.SEND_TO_FRIEND="10";r.LEGEND_CREATOR="11";r.DIRECTIONS_CREATOR="12";r.MANAGE_USERS="13";r.REGION_HIGHLIGHTER="15";r.GIS="18";r.SAVE_POSTER="19";r.LAYERS="20";r.LIST_IMPORT="25";r.FILTER="27";r.GEOJSON_IMPORT="28";r.SATELLITE="29";r.IMAGE_OVERLAY="30";r.CATALOG="31";r.MAPS="36";r.IMPORT_FILE="38";e("PanelType",r,!0);ht={};ht.NONE="none";ht.MGRS="mgrs";ht.UKNG="ukng";e("GridType",ht,!0);yt={};yt.DEFAULT=0;yt.SMALL=1;e("ControlModes",yt,!0);f={};f.NEW_MAP="newMap";f.LOAD_MAP="loadMap";f.SAVE_MAP="saveMap";f.OFFLINE_LOAD_MAP="offlineLoadMap";f.OFFLINE_SAVE_MAP="offlineSaveMap";f.WIDGET="getWidget";f.SEND_TO_FRIEND="sendToFriend";f.SAVE_IMAGE="saveImage";f.SAVE_PDF="savePDF";f.FACEBOOK="facebook";f.KML_DOWNLOAD="saveKML";f.GPX_DOWNLOAD="saveGPX";f.DXF_DOWNLOAD="saveDXF";f.SHP_DOWNLOAD="saveSHP";f.JSON_DOWNLOAD="saveJSON";f.CSV_DOWNLOAD="saveCSV";f.MANAGE_USERS="manageUsers";f.SAVE_TEMPLATE="saveTemplate";f.LOAD_TEMPLATE="loadTemplate";e("MenuType",f,!0);o={};o.MILLIMETRE="mm";o.CENTIMETRE="cm";o.METRE="m";o.KILOMETRE="km";o.INCH="mm";o.FOOT="ft";o.YARD="yd";o.MILE="mi";o.NAUTICAL_MILE="nmi";o.SQUARE_CENTIMETRE="sqcm";o.SQUARE_METRE="sqm";o.SQUARE_KILOMETRE="sqkm";o.HECTARE="ha";o.SQUARE_INCH="sqin";o.SQUARE_FOOT="sqft";o.SQUARE_YARD="sqyd";o.SQUARE_MILE="sqmi";o.ACRE="acre";e("MeasureType",o,!0);d={};d.ZOOM_START="zoom_start";d.ZOOM_END="zoom_end";d.CHANGED="view_changed";d.TILES_LOADED="tiles_loaded";d.MOVED="view_moved";d.RENDERED="view_rendered";d.GRID_CHANGED="grid_changed";e("ViewEvent",d,!0);i={};i.NEW_MAP="new_map";i.MAP_SAVE_ERROR="save_error";i.MAP_SAVE_START="save_start";i.MAP_SAVED="save_complete";i.DATA_IMPORTED="data_imported";i.MAP_LOADED="map_loaded";i.MAP_LOAD_ERROR="map_load_error";i.MAP_NOT_AUTHORIZED="map_not_authorized";i.MAP_PASSWORD_ERROR="map_password_error";i.MAP_PASSWORD_REQUIRED="map_password_required";i.SMJSON_ERROR="smjson_error";i.BASE_TYPE_CHANGED="basetype_changed";i.OVERLAY_HIDDEN="overlay_hidden";i.OVERLAY_SHOWN="overlay_shown";i.OVERLAY_ADDED="overlay_added";i.OVERLAY_REMOVED="overlay_removed";i.OVERLAY_CHANGED="overlay_changed";i.OVERLAY_META_CHANGED="overlay_meta_changed";i.OVERLAY_OVER="overlay_over";i.OVERLAY_OUT="overlay_out";i.OVERLAY_CLICK="overlay_click";i.OVERLAY_MOVE="overlay_move";i.OVERLAY_UP="overlay_up";i.OVERLAY_DOWN="overlay_down";i.GROUP_ADDED="group_added";i.GROUP_REMOVED="group_removed";i.GROUP_META_CHANGED="group_meta_changed";e("MapEvent",i,!0);pt={};pt.STYLE_CHANGED="style_changed";pt.MARKER_CHANGED="marker_changed";e("DrawEvent",pt,!0);s={};s.VIEWLOADER_OPEN="viewloader_open";s.VIEWLOADER_CLOSE="viewloader_close";s.ALERT_CLOSE="alert_close";s.ALERT_OPEN="alert_open";s.PANEL_CLOSE="panel_close";s.PANEL_OPEN="panel_open";s.PANEL_MARKER_SELECT="marker_select";s.LEGEND_CREATED="legend_created";s.LEGEND_REMOVED="legend_removed";s.TOOL_SELECT="tool_select";s.GIS_RUN="gis_run";s.LIST_MAPPED="list_mapped";s.MENU_SELECT="menu_select";s.THEME_CHANGED="theme_changed";s.SUBMENU_SELECT="submenu_select";s.SEARCH_ITEM_SELECT="search_item_select";e("UIEvent",s,!0);wt={};wt.ALL_READY="ready";wt.SETTINGS_CHANGED="settings_changed";e("CoreEvent",wt,!0);e("CapType",{SQUARE:1,ROUND:0},!0);e("JoinType",{MITER:1,ROUND:0},!0);e("LineType",{SOLID:0,DASHED:1,ARROW:2,ARROW_ONLY:3,DOTS:4,DOTS_ONLY:5,ARROW_END:6,ARROW_ENDS:7},!0);var hr=!1,cr=!1,yi=!1,ct=!1,pi=!1,ni=-1;ti=0;ii=!1;lt=document.onreadystatechange;document.readyState!=="complete"&&document.readyState!=="interactive"||ct?document.onreadystatechange=function(){ct||((document.readyState==="complete"||document.readyState==="interactive")&&(ct=!0,wi(),c()),lt&&lt())}:(ct=!0,wi(),c(),lt&&lt());var l=[],bi=function(n,t,i){return function(){return l.push({group:n,fname:t,args:arguments,sm:i}),i}},at={clustering:["setSize","setRangePixels","enable","disable","clusterViewOverride"],data:["addListener","removeListener","getSMJSON","importGeoJSON","getGeoJSON"],view:["getUICenter","addListener","removeListener","pixelToLatLng","latLngToPixel","getZoom","getMaxZoom","setZoom","lockView","unlockView","lockToBounds","render","getBounds","setBounds","getCenter","setCenter","fitContent","setGrid","getGridCenter","getGridType"],draw:["setGroup","setStyle","rectangle","circle","polygon","line","infoBubble","label","mediaMarker","marker","point","image"],map:["setFilters","clearFilters","dataProviders","setType","openInfoWindow","closeInfoWindow","getOverlays","addOverlay","getGroups","addOverlayToGroup","createOverlayGroup","removeOverlay","wipe","import","importById","load","loadById","save","startAutoSave","stopAutoSave","getMapType","saveCurrent","importKML","loadSmJSON","importSmJSON","addListener","removeListener","createNewMap","isFresh","hasUpdates"],layers:["setMapDataLayers","setBase","add","remove","addAt","removeAt","clear","createTileLayer"],utils:["unitTypes","convertUnit","geoCode","distances","bindEvent","unbindEvent","optimizeRoute"],ui:["toggleFullMobile","isHalted","setFSContainer","setMode","setSettings","setSearchEngine","enableImageryUpload","enableOLRendering","disableOLRendering","enableCtrlZoom","forceEnable","addTooltip","enableMarkerUpload","disableMarkerUpload","getCurrentTool","getControlElement","showCrosshairs","hideCrosshairs","setMapTypes","editMarker","addListener","removeListener","setStyle","hideDomElements","showDomElements","showControls","hideControls","enableOverlayUpload","disableOverlayUpload","setSearchControlMode","showLoader","hideLoader","showAlert","hideAlert","closeGallery","setAvailableTools","setMapInfoIcons","setMenuIcons","enableOverlayListEdit","enableUserGIS","disableUserGIS","setMapTypeControlMode","getSearchControls","setTool","createTool","styleControl","createLegend","removeLegend","setMarkerLibrary","enableAdvancedSearch","runScript","disableAdvancedSearch","setTheme","showMenu","showMenuIcon","addDomElement","hidePanel","showColorPicker","showCustomPanel","hideNotice","showNotice","hideMenuIcon","setSearchRegion","setSearchBounds","enableLegendEdit","disableLegendEdit","enableFullPolygonErase","disableFullPolygonErase","enableManageUsers","enableLayersModule"],settings:["hideGraphics","showGraphics","setCRS","setInternalSettings","disableDevCatch","clearListeners","setToImperial","noPasswordSkip","updateCredentials","disableChangesHalt","enableChangesHalt","setToMetric","setFrameRate","toggleFullScreen","disableZoom","enableZoom","disableLineSnap","disableInteractivity","enableInteractivity","enableLineSnap","resize","setMeasurementUnits","getMeasurementUnits","set","get"],addListener:[],removeListener:[],getBaseAPIMap:[]},pr=function(n){for(var t=0;t<l.length;t++)l[t].sm===n&&(l[t].fname?n[l[t].group][l[t].fname].apply(n[l[t].group],l[t].args):n[l[t].group].apply(n[l[t].group],l[t].args))},ki="maps.googleapis.com";ri=!1;bt=function(t,i,r){var f,o,u,e;i=k(i)?{}:i;this.opts=i;i.sm_date=h;i.sm_version=kt;f=document.createElement("div");this.createLoader=function(){f.className=n.theme=="dark"?"sm_loader sm_dark":"sm_loader sm_light";Object.prototype.toString.call(t)=="[object String]"?document.getElementById(t).appendChild(f):t instanceof Array?t[0].appendChild(f):t.appendChild(f)};this.makeReal=function(){for(var s,u,e=[],n=0;n<l.length;n++)l[n].sm==this&&e.push(l[n]);s=this;o=new window.ScribbleMapCore(t,i,r,e);o.placeHolder=this;for(u in o)this[u]=o[u];pr(this);f.parentNode&&f.parentNode.removeChild(f);delete this.makeReal;delete this.createLoader};for(u in at){for(this[u]={},e=0;e<at[u].length;e++)this[u][at[u][e]]=bi(u,at[u][e],this);at[u].length==0&&(this[u]=bi(u,null,this))}nt.push(this);i&&i.useStatic&&window.L==null&&(ri||(ri=!0,di(dt,"leaflet")));c()};window.ScribbleMap||(window.ScribbleMap=bt);var a=document.getElementsByTagName("script"),ui,n={libraries:"places"},rt=window.scribblemaps.settings;if(window.scribblemaps&&window.scribblemaps.settings){!rt.baseAPI&&(rt.key||rt.clientId)&&(rt.baseAPI="google",rt.libraries="places");for(a in rt)n[a]=rt[a]}else{for(it=0;it<a.length;it++)if(a[it].innerHTML.toString().indexOf("{")!=-1&&(ui=a[it],a[it].innerHTML&&a[it].innerHTML!=null))try{if(ut=eval("("+a[it].innerHTML+")"),window.scribblemaps.settings){for(w in ut)window.scribblemaps.settings[w]=ut[w];for(w in n)window.scribblemaps.settings[w]||(window.scribblemaps.settings[w]=n[w]);n=window.scribblemaps.settings}else{for(w in n)ut[w]||(ut[w]=n[w]);n=ut;window.scribblemaps.settings=ut}break}catch(dr){}e("settings",n)}window.scribblemaps.settings.sharedLoc=ft;window.scribblemaps.settings.baseLoc=b;fi="sm_goog_mapLoadCallback";window[fi]=function(){hr=!0;c()};ei="sm_bing_mapLoadCallback";window[ei]=function(){cr=!0;c()};var oi=function(){return si?"&callback="+fi:""},wr=function(){return window.location.hostname.indexOf("scribblemaps.com")!=-1||window.location.hostname.indexOf("mapyourlist.com")!=-1||window.location.hostname.indexOf("lifestorage.com")!=-1||window.location.hostname.indexOf("smwidgets-east-staging.azurewebsites.net")!=-1||window.location.hostname.indexOf("northcottglobalsolutions.com")!=-1||window.location.hostname.indexOf("localhost")!=-1},br=function(){return si?"callback="+ei:""},v={};if(v.bing={scripts:["//www.bing.com/api/maps/mapcontrol?"+br()]},v.leaflet={scripts:[ft+"scripts/apis/leaflet/leaflet.js"],css:[ft+"scripts/apis/leaflet/leaflet.css"]},v.mapquest={scripts:["//cdnjs.cloudflare.com/ajax/libs/leaflet/0.6.4/leaflet.js","//www.mapquestapi.com/sdk/leaflet/v1.0/mq-map.js?key={key}"],css:["//cdnjs.cloudflare.com/ajax/libs/leaflet/0.6.4/leaflet.css"]},v.google={scripts:["//{gurl}/maps/api/js?v=3&language={lang}&libraries={libraries}&key={key}"+oi()]},v.googleKey={scripts:["//{gurl}/maps/api/js?v=3&language={lang}&libraries={libraries}&key={key}"+oi()]},v.googleEnterprise={scripts:["//{gurl}/maps/api/js?v=3&language={lang}&libraries={libraries}&client={clientId}"+oi()]},v.arcgis={scripts:["//serverapi.arcgisonline.com/jsapi/arcgis/3.4/"],css:["//serverapi.arcgisonline.com/jsapi/arcgis/3.4/js/esri/css/esri.css"]},n.baseLoc=b,u=n.baseAPI,g=gi(),g&&g!=""&&g!="null"&&(n.projectId=g),nr=["google","googleEnterprise","bing","nokia","arcgis","mapquest"],u&&u!=""?u=="google"&&n.clientId?u="googleEnterprise":u=="google"&&n.key&&(u="googleKey"):n.clientId?(u="googleEnterprise",n.baseAPI="google"):n.key?(u="google",n.baseAPI="google"):u="leaflet",g&&g!=""&&g!="null")window.$SMLicense=function(t){t?(u=nr[t.providerId-1],n.license=t,n.baseAPI=u,n.key=t.apiKey,n.clientId=t.clientId,n.appID=t.otherKey):n.projectId=null;u=="google"&&n.clientId?u="googleEnterprise":u=="google"&&n.key&&(u="googleKey");window.scribblemaps.settings=n;a=document.getElementsByTagName("script");for(var i=0;i<a.length;i++)if(a[i].src.indexOf(ai)!=-1){a[i].parentNode.removeChild(a[i]);break}window.$SMLicense=undefined;rr()},tr=ai+"api/projects/"+gi()+"/license?callback=$SMLicense&v="+(new Date).getTime(),et(tr);else if(wr())rr();else throw"API implementations require a key contact support@scribblemaps.com";ur=function(n,t,i,r){t=k(t)?{}:t;t.sm_date=h;t.sm_version=kt;t.mode="viewer";k(t.tools)&&(t.tools=[]);k(t.fillColorControl)&&(t.fillColorControl=!1);k(t.undoControl)&&(t.undoControl=!1);k(t.lineColorControl)&&(t.lineColorControl=!1);k(t.searchControl)&&(t.searchControl=!1);k(t.lineSettingsControl)&&(t.lineSettingsControl=!1);var u=new bt(n,t,r);return k(i)||i.password==null||i.password==undefined?k(i)||u.map.loadById(i):u.map.load(i),u};e("ScribbleMapsAPIs",v);e("ScribbleMap",bt,!0);e("ScribbleMapViewer",ur)})()