-
Notifications
You must be signed in to change notification settings - Fork 49
/
pikazLocation.js
2 lines (2 loc) · 72.3 KB
/
pikazLocation.js
1
2
/*! For license information please see pikazLocation.js.LICENSE.txt */
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.pikazLocation=t():e.pikazLocation=t()}(this,(function(){return(()=>{var e={483:(e,t,n)=>{e.exports=function e(t,n,r){function o(a,s){if(!n[a]){if(!t[a]){if(i)return i(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[a]={exports:{}};t[a][0].call(u.exports,(function(e){return o(t[a][1][e]||e)}),u,u.exports,e,t,n,r)}return n[a].exports}for(var i=void 0,a=0;a<r.length;a++)o(r[a]);return o}({1:[function(e,t,r){(function(e){"use strict";var n,r,o=e.MutationObserver||e.WebKitMutationObserver;if(o){var i=0,a=new o(l),s=e.document.createTextNode("");a.observe(s,{characterData:!0}),n=function(){s.data=i=++i%2}}else if(e.setImmediate||void 0===e.MessageChannel)n="document"in e&&"onreadystatechange"in e.document.createElement("script")?function(){var t=e.document.createElement("script");t.onreadystatechange=function(){l(),t.onreadystatechange=null,t.parentNode.removeChild(t),t=null},e.document.documentElement.appendChild(t)}:function(){setTimeout(l,0)};else{var c=new e.MessageChannel;c.port1.onmessage=l,n=function(){c.port2.postMessage(0)}}var u=[];function l(){var e,t;r=!0;for(var n=u.length;n;){for(t=u,u=[],e=-1;++e<n;)t[e]();n=u.length}r=!1}t.exports=function(e){1!==u.push(e)||r||n()}}).call(this,void 0!==n.g?n.g:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],2:[function(e,t,n){"use strict";var r=e(1);function o(){}var i={},a=["REJECTED"],s=["FULFILLED"],c=["PENDING"];function u(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=c,this.queue=[],this.outcome=void 0,e!==o&&h(this,e)}function l(e,t,n){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof n&&(this.onRejected=n,this.callRejected=this.otherCallRejected)}function f(e,t,n){r((function(){var r;try{r=t(n)}catch(t){return i.reject(e,t)}r===e?i.reject(e,new TypeError("Cannot resolve promise with itself")):i.resolve(e,r)}))}function d(e){var t=e&&e.then;if(e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function h(e,t){var n=!1;function r(t){n||(n=!0,i.reject(e,t))}function o(t){n||(n=!0,i.resolve(e,t))}var a=p((function(){t(o,r)}));"error"===a.status&&r(a.value)}function p(e,t){var n={};try{n.value=e(t),n.status="success"}catch(e){n.status="error",n.value=e}return n}t.exports=u,u.prototype.catch=function(e){return this.then(null,e)},u.prototype.then=function(e,t){if("function"!=typeof e&&this.state===s||"function"!=typeof t&&this.state===a)return this;var n=new this.constructor(o);return this.state!==c?f(n,this.state===s?e:t,this.outcome):this.queue.push(new l(n,e,t)),n},l.prototype.callFulfilled=function(e){i.resolve(this.promise,e)},l.prototype.otherCallFulfilled=function(e){f(this.promise,this.onFulfilled,e)},l.prototype.callRejected=function(e){i.reject(this.promise,e)},l.prototype.otherCallRejected=function(e){f(this.promise,this.onRejected,e)},i.resolve=function(e,t){var n=p(d,t);if("error"===n.status)return i.reject(e,n.value);var r=n.value;if(r)h(e,r);else{e.state=s,e.outcome=t;for(var o=-1,a=e.queue.length;++o<a;)e.queue[o].callFulfilled(t)}return e},i.reject=function(e,t){e.state=a,e.outcome=t;for(var n=-1,r=e.queue.length;++n<r;)e.queue[n].callRejected(t);return e},u.resolve=function(e){return e instanceof this?e:i.resolve(new this(o),e)},u.reject=function(e){var t=new this(o);return i.reject(t,e)},u.all=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a=new Array(n),s=0,c=-1,u=new this(o);++c<n;)l(e[c],c);return u;function l(e,o){t.resolve(e).then((function(e){a[o]=e,++s!==n||r||(r=!0,i.resolve(u,a))}),(function(e){r||(r=!0,i.reject(u,e))}))}},u.race=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n,r=e.length,a=!1;if(!r)return this.resolve([]);for(var s=-1,c=new this(o);++s<r;)n=e[s],t.resolve(n).then((function(e){a||(a=!0,i.resolve(c,e))}),(function(e){a||(a=!0,i.reject(c,e))}));return c}},{1:1}],3:[function(e,t,r){(function(t){"use strict";"function"!=typeof t.Promise&&(t.Promise=e(2))}).call(this,void 0!==n.g?n.g:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{2:2}],4:[function(e,t,n){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};var o=function(){try{if("undefined"!=typeof indexedDB)return indexedDB;if("undefined"!=typeof webkitIndexedDB)return webkitIndexedDB;if("undefined"!=typeof mozIndexedDB)return mozIndexedDB;if("undefined"!=typeof OIndexedDB)return OIndexedDB;if("undefined"!=typeof msIndexedDB)return msIndexedDB}catch(e){return}}();function i(e,t){e=e||[],t=t||{};try{return new Blob(e,t)}catch(o){if("TypeError"!==o.name)throw o;for(var n=new("undefined"!=typeof BlobBuilder?BlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder?MozBlobBuilder:WebKitBlobBuilder),r=0;r<e.length;r+=1)n.append(e[r]);return n.getBlob(t.type)}}"undefined"==typeof Promise&&e(3);var a=Promise;function s(e,t){t&&e.then((function(e){t(null,e)}),(function(e){t(e)}))}function c(e,t,n){"function"==typeof t&&e.then(t),"function"==typeof n&&e.catch(n)}function u(e){return"string"!=typeof e&&(console.warn(e+" used as a key, but it is not a string."),e=String(e)),e}function l(){if(arguments.length&&"function"==typeof arguments[arguments.length-1])return arguments[arguments.length-1]}var f="local-forage-detect-blob-support",d=void 0,h={},p=Object.prototype.toString,m="readonly",y="readwrite";function v(e){for(var t=e.length,n=new ArrayBuffer(t),r=new Uint8Array(n),o=0;o<t;o++)r[o]=e.charCodeAt(o);return n}function g(e){return"boolean"==typeof d?a.resolve(d):function(e){return new a((function(t){var n=e.transaction(f,y),r=i([""]);n.objectStore(f).put(r,"key"),n.onabort=function(e){e.preventDefault(),e.stopPropagation(),t(!1)},n.oncomplete=function(){var e=navigator.userAgent.match(/Chrome\/(\d+)/),n=navigator.userAgent.match(/Edge\//);t(n||!e||parseInt(e[1],10)>=43)}})).catch((function(){return!1}))}(e).then((function(e){return d=e}))}function b(e){var t=h[e.name],n={};n.promise=new a((function(e,t){n.resolve=e,n.reject=t})),t.deferredOperations.push(n),t.dbReady?t.dbReady=t.dbReady.then((function(){return n.promise})):t.dbReady=n.promise}function w(e){var t=h[e.name].deferredOperations.pop();if(t)return t.resolve(),t.promise}function E(e,t){var n=h[e.name].deferredOperations.pop();if(n)return n.reject(t),n.promise}function S(e,t){return new a((function(n,r){if(h[e.name]=h[e.name]||{forages:[],db:null,dbReady:null,deferredOperations:[]},e.db){if(!t)return n(e.db);b(e),e.db.close()}var i=[e.name];t&&i.push(e.version);var a=o.open.apply(o,i);t&&(a.onupgradeneeded=function(t){var n=a.result;try{n.createObjectStore(e.storeName),t.oldVersion<=1&&n.createObjectStore(f)}catch(n){if("ConstraintError"!==n.name)throw n;console.warn('The database "'+e.name+'" has been upgraded from version '+t.oldVersion+" to version "+t.newVersion+', but the storage "'+e.storeName+'" already exists.')}}),a.onerror=function(e){e.preventDefault(),r(a.error)},a.onsuccess=function(){var t=a.result;t.onversionchange=function(e){e.target.close()},n(t),w(e)}}))}function _(e){return S(e,!1)}function O(e){return S(e,!0)}function A(e,t){if(!e.db)return!0;var n=!e.db.objectStoreNames.contains(e.storeName),r=e.version<e.db.version,o=e.version>e.db.version;if(r&&(e.version!==t&&console.warn('The database "'+e.name+"\" can't be downgraded from version "+e.db.version+" to version "+e.version+"."),e.version=e.db.version),o||n){if(n){var i=e.db.version+1;i>e.version&&(e.version=i)}return!0}return!1}function R(e){return i([v(atob(e.data))],{type:e.type})}function C(e){return e&&e.__local_forage_encoded_blob}function j(e){var t=this,n=t._initReady().then((function(){var e=h[t._dbInfo.name];if(e&&e.dbReady)return e.dbReady}));return c(n,e,e),n}function I(e,t,n,r){void 0===r&&(r=1);try{var o=e.db.transaction(e.storeName,t);n(null,o)}catch(o){if(r>0&&(!e.db||"InvalidStateError"===o.name||"NotFoundError"===o.name))return a.resolve().then((function(){if(!e.db||"NotFoundError"===o.name&&!e.db.objectStoreNames.contains(e.storeName)&&e.version<=e.db.version)return e.db&&(e.version=e.db.version+1),O(e)})).then((function(){return function(e){b(e);for(var t=h[e.name],n=t.forages,r=0;r<n.length;r++){var o=n[r];o._dbInfo.db&&(o._dbInfo.db.close(),o._dbInfo.db=null)}return e.db=null,_(e).then((function(t){return e.db=t,A(e)?O(e):t})).then((function(r){e.db=t.db=r;for(var o=0;o<n.length;o++)n[o]._dbInfo.db=r})).catch((function(t){throw E(e,t),t}))}(e).then((function(){I(e,t,n,r-1)}))})).catch(n);n(o)}}var N={_driver:"asyncStorage",_initStorage:function(e){var t=this,n={db:null};if(e)for(var r in e)n[r]=e[r];var o=h[n.name];o||(o={forages:[],db:null,dbReady:null,deferredOperations:[]},h[n.name]=o),o.forages.push(t),t._initReady||(t._initReady=t.ready,t.ready=j);var i=[];function s(){return a.resolve()}for(var c=0;c<o.forages.length;c++){var u=o.forages[c];u!==t&&i.push(u._initReady().catch(s))}var l=o.forages.slice(0);return a.all(i).then((function(){return n.db=o.db,_(n)})).then((function(e){return n.db=e,A(n,t._defaultConfig.version)?O(n):e})).then((function(e){n.db=o.db=e,t._dbInfo=n;for(var r=0;r<l.length;r++){var i=l[r];i!==t&&(i._dbInfo.db=n.db,i._dbInfo.version=n.version)}}))},_support:function(){try{if(!o||!o.open)return!1;var e="undefined"!=typeof openDatabase&&/(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)&&!/BlackBerry/.test(navigator.platform),t="function"==typeof fetch&&-1!==fetch.toString().indexOf("[native code");return(!e||t)&&"undefined"!=typeof indexedDB&&"undefined"!=typeof IDBKeyRange}catch(e){return!1}}(),iterate:function(e,t){var n=this,r=new a((function(t,r){n.ready().then((function(){I(n._dbInfo,m,(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName).openCursor(),s=1;a.onsuccess=function(){var n=a.result;if(n){var r=n.value;C(r)&&(r=R(r));var o=e(r,n.key,s++);void 0!==o?t(o):n.continue()}else t()},a.onerror=function(){r(a.error)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},getItem:function(e,t){var n=this;e=u(e);var r=new a((function(t,r){n.ready().then((function(){I(n._dbInfo,m,(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName).get(e);a.onsuccess=function(){var e=a.result;void 0===e&&(e=null),C(e)&&(e=R(e)),t(e)},a.onerror=function(){r(a.error)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},setItem:function(e,t,n){var r=this;e=u(e);var o=new a((function(n,o){var i;r.ready().then((function(){return i=r._dbInfo,"[object Blob]"===p.call(t)?g(i.db).then((function(e){return e?t:(n=t,new a((function(e,t){var r=new FileReader;r.onerror=t,r.onloadend=function(t){var r=btoa(t.target.result||"");e({__local_forage_encoded_blob:!0,data:r,type:n.type})},r.readAsBinaryString(n)})));var n})):t})).then((function(t){I(r._dbInfo,y,(function(i,a){if(i)return o(i);try{var s=a.objectStore(r._dbInfo.storeName);null===t&&(t=void 0);var c=s.put(t,e);a.oncomplete=function(){void 0===t&&(t=null),n(t)},a.onabort=a.onerror=function(){var e=c.error?c.error:c.transaction.error;o(e)}}catch(e){o(e)}}))})).catch(o)}));return s(o,n),o},removeItem:function(e,t){var n=this;e=u(e);var r=new a((function(t,r){n.ready().then((function(){I(n._dbInfo,y,(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName).delete(e);i.oncomplete=function(){t()},i.onerror=function(){r(a.error)},i.onabort=function(){var e=a.error?a.error:a.transaction.error;r(e)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},clear:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){I(t._dbInfo,y,(function(r,o){if(r)return n(r);try{var i=o.objectStore(t._dbInfo.storeName).clear();o.oncomplete=function(){e()},o.onabort=o.onerror=function(){var e=i.error?i.error:i.transaction.error;n(e)}}catch(e){n(e)}}))})).catch(n)}));return s(n,e),n},length:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){I(t._dbInfo,m,(function(r,o){if(r)return n(r);try{var i=o.objectStore(t._dbInfo.storeName).count();i.onsuccess=function(){e(i.result)},i.onerror=function(){n(i.error)}}catch(e){n(e)}}))})).catch(n)}));return s(n,e),n},key:function(e,t){var n=this,r=new a((function(t,r){e<0?t(null):n.ready().then((function(){I(n._dbInfo,m,(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName),s=!1,c=a.openKeyCursor();c.onsuccess=function(){var n=c.result;n?0===e||s?t(n.key):(s=!0,n.advance(e)):t(null)},c.onerror=function(){r(c.error)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},keys:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){I(t._dbInfo,m,(function(r,o){if(r)return n(r);try{var i=o.objectStore(t._dbInfo.storeName).openKeyCursor(),a=[];i.onsuccess=function(){var t=i.result;t?(a.push(t.key),t.continue()):e(a)},i.onerror=function(){n(i.error)}}catch(e){n(e)}}))})).catch(n)}));return s(n,e),n},dropInstance:function(e,t){t=l.apply(this,arguments);var n=this.config();(e="function"!=typeof e&&e||{}).name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var r,i=this;if(e.name){var c=e.name===n.name&&i._dbInfo.db?a.resolve(i._dbInfo.db):_(e).then((function(t){var n=h[e.name],r=n.forages;n.db=t;for(var o=0;o<r.length;o++)r[o]._dbInfo.db=t;return t}));r=e.storeName?c.then((function(t){if(t.objectStoreNames.contains(e.storeName)){var n=t.version+1;b(e);var r=h[e.name],i=r.forages;t.close();for(var s=0;s<i.length;s++){var c=i[s];c._dbInfo.db=null,c._dbInfo.version=n}var u=new a((function(t,r){var i=o.open(e.name,n);i.onerror=function(e){i.result.close(),r(e)},i.onupgradeneeded=function(){i.result.deleteObjectStore(e.storeName)},i.onsuccess=function(){var e=i.result;e.close(),t(e)}}));return u.then((function(e){r.db=e;for(var t=0;t<i.length;t++){var n=i[t];n._dbInfo.db=e,w(n._dbInfo)}})).catch((function(t){throw(E(e,t)||a.resolve()).catch((function(){})),t}))}})):c.then((function(t){b(e);var n=h[e.name],r=n.forages;t.close();for(var i=0;i<r.length;i++)r[i]._dbInfo.db=null;var s=new a((function(t,n){var r=o.deleteDatabase(e.name);r.onerror=function(){var e=r.result;e&&e.close(),n(r.error)},r.onblocked=function(){console.warn('dropInstance blocked for database "'+e.name+'" until all open connections are closed')},r.onsuccess=function(){var e=r.result;e&&e.close(),t(e)}}));return s.then((function(e){n.db=e;for(var t=0;t<r.length;t++)w(r[t]._dbInfo)})).catch((function(t){throw(E(e,t)||a.resolve()).catch((function(){})),t}))}))}else r=a.reject("Invalid arguments");return s(r,t),r}};var x="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",T=/^~~local_forage_type~([^~]+)~/,k="__lfsc__:",D=k.length,B="arbf",P="blob",F="si08",L="ui08",U="uic8",M="si16",z="si32",q="ur16",H="ui32",W="fl32",J="fl64",V=D+B.length,K=Object.prototype.toString;function G(e){var t,n,r,o,i,a=.75*e.length,s=e.length,c=0;"="===e[e.length-1]&&(a--,"="===e[e.length-2]&&a--);var u=new ArrayBuffer(a),l=new Uint8Array(u);for(t=0;t<s;t+=4)n=x.indexOf(e[t]),r=x.indexOf(e[t+1]),o=x.indexOf(e[t+2]),i=x.indexOf(e[t+3]),l[c++]=n<<2|r>>4,l[c++]=(15&r)<<4|o>>2,l[c++]=(3&o)<<6|63&i;return u}function $(e){var t,n=new Uint8Array(e),r="";for(t=0;t<n.length;t+=3)r+=x[n[t]>>2],r+=x[(3&n[t])<<4|n[t+1]>>4],r+=x[(15&n[t+1])<<2|n[t+2]>>6],r+=x[63&n[t+2]];return n.length%3==2?r=r.substring(0,r.length-1)+"=":n.length%3==1&&(r=r.substring(0,r.length-2)+"=="),r}var X={serialize:function(e,t){var n="";if(e&&(n=K.call(e)),e&&("[object ArrayBuffer]"===n||e.buffer&&"[object ArrayBuffer]"===K.call(e.buffer))){var r,o=k;e instanceof ArrayBuffer?(r=e,o+=B):(r=e.buffer,"[object Int8Array]"===n?o+=F:"[object Uint8Array]"===n?o+=L:"[object Uint8ClampedArray]"===n?o+=U:"[object Int16Array]"===n?o+=M:"[object Uint16Array]"===n?o+=q:"[object Int32Array]"===n?o+=z:"[object Uint32Array]"===n?o+=H:"[object Float32Array]"===n?o+=W:"[object Float64Array]"===n?o+=J:t(new Error("Failed to get type for BinaryArray"))),t(o+$(r))}else if("[object Blob]"===n){var i=new FileReader;i.onload=function(){var n="~~local_forage_type~"+e.type+"~"+$(this.result);t("__lfsc__:blob"+n)},i.readAsArrayBuffer(e)}else try{t(JSON.stringify(e))}catch(n){console.error("Couldn't convert value into a JSON string: ",e),t(null,n)}},deserialize:function(e){if(e.substring(0,D)!==k)return JSON.parse(e);var t,n=e.substring(V),r=e.substring(D,V);if(r===P&&T.test(n)){var o=n.match(T);t=o[1],n=n.substring(o[0].length)}var a=G(n);switch(r){case B:return a;case P:return i([a],{type:t});case F:return new Int8Array(a);case L:return new Uint8Array(a);case U:return new Uint8ClampedArray(a);case M:return new Int16Array(a);case q:return new Uint16Array(a);case z:return new Int32Array(a);case H:return new Uint32Array(a);case W:return new Float32Array(a);case J:return new Float64Array(a);default:throw new Error("Unkown type: "+r)}},stringToBuffer:G,bufferToString:$};function Q(e,t,n,r){e.executeSql("CREATE TABLE IF NOT EXISTS "+t.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],n,r)}function Y(e,t,n,r,o,i){e.executeSql(n,r,o,(function(e,a){a.code===a.SYNTAX_ERR?e.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[t.storeName],(function(e,s){s.rows.length?i(e,a):Q(e,t,(function(){e.executeSql(n,r,o,i)}),i)}),i):i(e,a)}),i)}function Z(e,t,n,r){var o=this;e=u(e);var i=new a((function(i,a){o.ready().then((function(){void 0===t&&(t=null);var s=t,c=o._dbInfo;c.serializer.serialize(t,(function(t,u){u?a(u):c.db.transaction((function(n){Y(n,c,"INSERT OR REPLACE INTO "+c.storeName+" (key, value) VALUES (?, ?)",[e,t],(function(){i(s)}),(function(e,t){a(t)}))}),(function(t){if(t.code===t.QUOTA_ERR){if(r>0)return void i(Z.apply(o,[e,s,n,r-1]));a(t)}}))}))})).catch(a)}));return s(i,n),i}function ee(e){return new a((function(t,n){e.transaction((function(r){r.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'",[],(function(n,r){for(var o=[],i=0;i<r.rows.length;i++)o.push(r.rows.item(i).name);t({db:e,storeNames:o})}),(function(e,t){n(t)}))}),(function(e){n(e)}))}))}var te={_driver:"webSQLStorage",_initStorage:function(e){var t=this,n={db:null};if(e)for(var r in e)n[r]="string"!=typeof e[r]?e[r].toString():e[r];var o=new a((function(e,r){try{n.db=openDatabase(n.name,String(n.version),n.description,n.size)}catch(e){return r(e)}n.db.transaction((function(o){Q(o,n,(function(){t._dbInfo=n,e()}),(function(e,t){r(t)}))}),r)}));return n.serializer=X,o},_support:"function"==typeof openDatabase,iterate:function(e,t){var n=this,r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){Y(n,o,"SELECT * FROM "+o.storeName,[],(function(n,r){for(var i=r.rows,a=i.length,s=0;s<a;s++){var c=i.item(s),u=c.value;if(u&&(u=o.serializer.deserialize(u)),void 0!==(u=e(u,c.key,s+1)))return void t(u)}t()}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},getItem:function(e,t){var n=this;e=u(e);var r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){Y(n,o,"SELECT * FROM "+o.storeName+" WHERE key = ? LIMIT 1",[e],(function(e,n){var r=n.rows.length?n.rows.item(0).value:null;r&&(r=o.serializer.deserialize(r)),t(r)}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},setItem:function(e,t,n){return Z.apply(this,[e,t,n,1])},removeItem:function(e,t){var n=this;e=u(e);var r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){Y(n,o,"DELETE FROM "+o.storeName+" WHERE key = ?",[e],(function(){t()}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},clear:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){Y(t,r,"DELETE FROM "+r.storeName,[],(function(){e()}),(function(e,t){n(t)}))}))})).catch(n)}));return s(n,e),n},length:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){Y(t,r,"SELECT COUNT(key) as c FROM "+r.storeName,[],(function(t,n){var r=n.rows.item(0).c;e(r)}),(function(e,t){n(t)}))}))})).catch(n)}));return s(n,e),n},key:function(e,t){var n=this,r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){Y(n,o,"SELECT key FROM "+o.storeName+" WHERE id = ? LIMIT 1",[e+1],(function(e,n){var r=n.rows.length?n.rows.item(0).key:null;t(r)}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},keys:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){Y(t,r,"SELECT key FROM "+r.storeName,[],(function(t,n){for(var r=[],o=0;o<n.rows.length;o++)r.push(n.rows.item(o).key);e(r)}),(function(e,t){n(t)}))}))})).catch(n)}));return s(n,e),n},dropInstance:function(e,t){t=l.apply(this,arguments);var n=this.config();(e="function"!=typeof e&&e||{}).name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var r,o=this;return s(r=e.name?new a((function(t){var r;r=e.name===n.name?o._dbInfo.db:openDatabase(e.name,"","",0),e.storeName?t({db:r,storeNames:[e.storeName]}):t(ee(r))})).then((function(e){return new a((function(t,n){e.db.transaction((function(r){function o(e){return new a((function(t,n){r.executeSql("DROP TABLE IF EXISTS "+e,[],(function(){t()}),(function(e,t){n(t)}))}))}for(var i=[],s=0,c=e.storeNames.length;s<c;s++)i.push(o(e.storeNames[s]));a.all(i).then((function(){t()})).catch((function(e){n(e)}))}),(function(e){n(e)}))}))})):a.reject("Invalid arguments"),t),r}};function ne(e,t){var n=e.name+"/";return e.storeName!==t.storeName&&(n+=e.storeName+"/"),n}function re(){return!function(){var e="_localforage_support_test";try{return localStorage.setItem(e,!0),localStorage.removeItem(e),!1}catch(e){return!0}}()||localStorage.length>0}var oe={_driver:"localStorageWrapper",_initStorage:function(e){var t={};if(e)for(var n in e)t[n]=e[n];return t.keyPrefix=ne(e,this._defaultConfig),re()?(this._dbInfo=t,t.serializer=X,a.resolve()):a.reject()},_support:function(){try{return"undefined"!=typeof localStorage&&"setItem"in localStorage&&!!localStorage.setItem}catch(e){return!1}}(),iterate:function(e,t){var n=this,r=n.ready().then((function(){for(var t=n._dbInfo,r=t.keyPrefix,o=r.length,i=localStorage.length,a=1,s=0;s<i;s++){var c=localStorage.key(s);if(0===c.indexOf(r)){var u=localStorage.getItem(c);if(u&&(u=t.serializer.deserialize(u)),void 0!==(u=e(u,c.substring(o),a++)))return u}}}));return s(r,t),r},getItem:function(e,t){var n=this;e=u(e);var r=n.ready().then((function(){var t=n._dbInfo,r=localStorage.getItem(t.keyPrefix+e);return r&&(r=t.serializer.deserialize(r)),r}));return s(r,t),r},setItem:function(e,t,n){var r=this;e=u(e);var o=r.ready().then((function(){void 0===t&&(t=null);var n=t;return new a((function(o,i){var a=r._dbInfo;a.serializer.serialize(t,(function(t,r){if(r)i(r);else try{localStorage.setItem(a.keyPrefix+e,t),o(n)}catch(e){"QuotaExceededError"!==e.name&&"NS_ERROR_DOM_QUOTA_REACHED"!==e.name||i(e),i(e)}}))}))}));return s(o,n),o},removeItem:function(e,t){var n=this;e=u(e);var r=n.ready().then((function(){var t=n._dbInfo;localStorage.removeItem(t.keyPrefix+e)}));return s(r,t),r},clear:function(e){var t=this,n=t.ready().then((function(){for(var e=t._dbInfo.keyPrefix,n=localStorage.length-1;n>=0;n--){var r=localStorage.key(n);0===r.indexOf(e)&&localStorage.removeItem(r)}}));return s(n,e),n},length:function(e){var t=this.keys().then((function(e){return e.length}));return s(t,e),t},key:function(e,t){var n=this,r=n.ready().then((function(){var t,r=n._dbInfo;try{t=localStorage.key(e)}catch(e){t=null}return t&&(t=t.substring(r.keyPrefix.length)),t}));return s(r,t),r},keys:function(e){var t=this,n=t.ready().then((function(){for(var e=t._dbInfo,n=localStorage.length,r=[],o=0;o<n;o++){var i=localStorage.key(o);0===i.indexOf(e.keyPrefix)&&r.push(i.substring(e.keyPrefix.length))}return r}));return s(n,e),n},dropInstance:function(e,t){if(t=l.apply(this,arguments),!(e="function"!=typeof e&&e||{}).name){var n=this.config();e.name=e.name||n.name,e.storeName=e.storeName||n.storeName}var r,o=this;return r=e.name?new a((function(t){e.storeName?t(ne(e,o._defaultConfig)):t(e.name+"/")})).then((function(e){for(var t=localStorage.length-1;t>=0;t--){var n=localStorage.key(t);0===n.indexOf(e)&&localStorage.removeItem(n)}})):a.reject("Invalid arguments"),s(r,t),r}},ie=function(e,t){for(var n=e.length,r=0;r<n;){if((o=e[r])===(i=t)||"number"==typeof o&&"number"==typeof i&&isNaN(o)&&isNaN(i))return!0;r++}var o,i;return!1},ae=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},se={},ce={},ue={INDEXEDDB:N,WEBSQL:te,LOCALSTORAGE:oe},le=[ue.INDEXEDDB._driver,ue.WEBSQL._driver,ue.LOCALSTORAGE._driver],fe=["dropInstance"],de=["clear","getItem","iterate","key","keys","length","removeItem","setItem"].concat(fe),he={description:"",driver:le.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1};function pe(e,t){e[t]=function(){var n=arguments;return e.ready().then((function(){return e[t].apply(e,n)}))}}function me(){for(var e=1;e<arguments.length;e++){var t=arguments[e];if(t)for(var n in t)t.hasOwnProperty(n)&&(ae(t[n])?arguments[0][n]=t[n].slice():arguments[0][n]=t[n])}return arguments[0]}var ye=function(){function e(t){for(var n in function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),ue)if(ue.hasOwnProperty(n)){var r=ue[n],o=r._driver;this[n]=o,se[o]||this.defineDriver(r)}this._defaultConfig=me({},he),this._config=me({},this._defaultConfig,t),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver).catch((function(){}))}return e.prototype.config=function(e){if("object"===(void 0===e?"undefined":r(e))){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var t in e){if("storeName"===t&&(e[t]=e[t].replace(/\W/g,"_")),"version"===t&&"number"!=typeof e[t])return new Error("Database version must be a number.");this._config[t]=e[t]}return!("driver"in e)||!e.driver||this.setDriver(this._config.driver)}return"string"==typeof e?this._config[e]:this._config},e.prototype.defineDriver=function(e,t,n){var r=new a((function(t,n){try{var r=e._driver,o=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!e._driver)return void n(o);for(var i=de.concat("_initStorage"),c=0,u=i.length;c<u;c++){var l=i[c];if((!ie(fe,l)||e[l])&&"function"!=typeof e[l])return void n(o)}!function(){for(var t=function(e){return function(){var t=new Error("Method "+e+" is not implemented by the current driver"),n=a.reject(t);return s(n,arguments[arguments.length-1]),n}},n=0,r=fe.length;n<r;n++){var o=fe[n];e[o]||(e[o]=t(o))}}();var f=function(n){se[r]&&console.info("Redefining LocalForage driver: "+r),se[r]=e,ce[r]=n,t()};"_support"in e?e._support&&"function"==typeof e._support?e._support().then(f,n):f(!!e._support):f(!0)}catch(e){n(e)}}));return c(r,t,n),r},e.prototype.driver=function(){return this._driver||null},e.prototype.getDriver=function(e,t,n){var r=se[e]?a.resolve(se[e]):a.reject(new Error("Driver not found."));return c(r,t,n),r},e.prototype.getSerializer=function(e){var t=a.resolve(X);return c(t,e),t},e.prototype.ready=function(e){var t=this,n=t._driverSet.then((function(){return null===t._ready&&(t._ready=t._initDriver()),t._ready}));return c(n,e,e),n},e.prototype.setDriver=function(e,t,n){var r=this;ae(e)||(e=[e]);var o=this._getSupportedDrivers(e);function i(){r._config.driver=r.driver()}function s(e){return r._extend(e),i(),r._ready=r._initStorage(r._config),r._ready}var u=null!==this._driverSet?this._driverSet.catch((function(){return a.resolve()})):a.resolve();return this._driverSet=u.then((function(){var e=o[0];return r._dbInfo=null,r._ready=null,r.getDriver(e).then((function(e){r._driver=e._driver,i(),r._wrapLibraryMethodsWithReady(),r._initDriver=function(e){return function(){var t=0;return function n(){for(;t<e.length;){var o=e[t];return t++,r._dbInfo=null,r._ready=null,r.getDriver(o).then(s).catch(n)}i();var c=new Error("No available storage method found.");return r._driverSet=a.reject(c),r._driverSet}()}}(o)}))})).catch((function(){i();var e=new Error("No available storage method found.");return r._driverSet=a.reject(e),r._driverSet})),c(this._driverSet,t,n),this._driverSet},e.prototype.supports=function(e){return!!ce[e]},e.prototype._extend=function(e){me(this,e)},e.prototype._getSupportedDrivers=function(e){for(var t=[],n=0,r=e.length;n<r;n++){var o=e[n];this.supports(o)&&t.push(o)}return t},e.prototype._wrapLibraryMethodsWithReady=function(){for(var e=0,t=de.length;e<t;e++)pe(this,de[e])},e.prototype.createInstance=function(t){return new e(t)},e}(),ve=new ye;t.exports=ve},{3:3}]},{},[4])(4)},961:(e,t,n)=>{var r,o=function(){var e=String.fromCharCode,t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",r={};function o(e,t){if(!r[e]){r[e]={};for(var n=0;n<e.length;n++)r[e][e.charAt(n)]=n}return r[e][t]}var i={compressToBase64:function(e){if(null==e)return"";var n=i._compress(e,6,(function(e){return t.charAt(e)}));switch(n.length%4){default:case 0:return n;case 1:return n+"===";case 2:return n+"==";case 3:return n+"="}},decompressFromBase64:function(e){return null==e?"":""==e?null:i._decompress(e.length,32,(function(n){return o(t,e.charAt(n))}))},compressToUTF16:function(t){return null==t?"":i._compress(t,15,(function(t){return e(t+32)}))+" "},decompressFromUTF16:function(e){return null==e?"":""==e?null:i._decompress(e.length,16384,(function(t){return e.charCodeAt(t)-32}))},compressToUint8Array:function(e){for(var t=i.compress(e),n=new Uint8Array(2*t.length),r=0,o=t.length;r<o;r++){var a=t.charCodeAt(r);n[2*r]=a>>>8,n[2*r+1]=a%256}return n},decompressFromUint8Array:function(t){if(null==t)return i.decompress(t);for(var n=new Array(t.length/2),r=0,o=n.length;r<o;r++)n[r]=256*t[2*r]+t[2*r+1];var a=[];return n.forEach((function(t){a.push(e(t))})),i.decompress(a.join(""))},compressToEncodedURIComponent:function(e){return null==e?"":i._compress(e,6,(function(e){return n.charAt(e)}))},decompressFromEncodedURIComponent:function(e){return null==e?"":""==e?null:(e=e.replace(/ /g,"+"),i._decompress(e.length,32,(function(t){return o(n,e.charAt(t))})))},compress:function(t){return i._compress(t,16,(function(t){return e(t)}))},_compress:function(e,t,n){if(null==e)return"";var r,o,i,a={},s={},c="",u="",l="",f=2,d=3,h=2,p=[],m=0,y=0;for(i=0;i<e.length;i+=1)if(c=e.charAt(i),Object.prototype.hasOwnProperty.call(a,c)||(a[c]=d++,s[c]=!0),u=l+c,Object.prototype.hasOwnProperty.call(a,u))l=u;else{if(Object.prototype.hasOwnProperty.call(s,l)){if(l.charCodeAt(0)<256){for(r=0;r<h;r++)m<<=1,y==t-1?(y=0,p.push(n(m)),m=0):y++;for(o=l.charCodeAt(0),r=0;r<8;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1}else{for(o=1,r=0;r<h;r++)m=m<<1|o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o=0;for(o=l.charCodeAt(0),r=0;r<16;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1}0==--f&&(f=Math.pow(2,h),h++),delete s[l]}else for(o=a[l],r=0;r<h;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1;0==--f&&(f=Math.pow(2,h),h++),a[u]=d++,l=String(c)}if(""!==l){if(Object.prototype.hasOwnProperty.call(s,l)){if(l.charCodeAt(0)<256){for(r=0;r<h;r++)m<<=1,y==t-1?(y=0,p.push(n(m)),m=0):y++;for(o=l.charCodeAt(0),r=0;r<8;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1}else{for(o=1,r=0;r<h;r++)m=m<<1|o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o=0;for(o=l.charCodeAt(0),r=0;r<16;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1}0==--f&&(f=Math.pow(2,h),h++),delete s[l]}else for(o=a[l],r=0;r<h;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1;0==--f&&(f=Math.pow(2,h),h++)}for(o=2,r=0;r<h;r++)m=m<<1|1&o,y==t-1?(y=0,p.push(n(m)),m=0):y++,o>>=1;for(;;){if(m<<=1,y==t-1){p.push(n(m));break}y++}return p.join("")},decompress:function(e){return null==e?"":""==e?null:i._decompress(e.length,32768,(function(t){return e.charCodeAt(t)}))},_decompress:function(t,n,r){var o,i,a,s,c,u,l,f=[],d=4,h=4,p=3,m="",y=[],v={val:r(0),position:n,index:1};for(o=0;o<3;o+=1)f[o]=o;for(a=0,c=Math.pow(2,2),u=1;u!=c;)s=v.val&v.position,v.position>>=1,0==v.position&&(v.position=n,v.val=r(v.index++)),a|=(s>0?1:0)*u,u<<=1;switch(a){case 0:for(a=0,c=Math.pow(2,8),u=1;u!=c;)s=v.val&v.position,v.position>>=1,0==v.position&&(v.position=n,v.val=r(v.index++)),a|=(s>0?1:0)*u,u<<=1;l=e(a);break;case 1:for(a=0,c=Math.pow(2,16),u=1;u!=c;)s=v.val&v.position,v.position>>=1,0==v.position&&(v.position=n,v.val=r(v.index++)),a|=(s>0?1:0)*u,u<<=1;l=e(a);break;case 2:return""}for(f[3]=l,i=l,y.push(l);;){if(v.index>t)return"";for(a=0,c=Math.pow(2,p),u=1;u!=c;)s=v.val&v.position,v.position>>=1,0==v.position&&(v.position=n,v.val=r(v.index++)),a|=(s>0?1:0)*u,u<<=1;switch(l=a){case 0:for(a=0,c=Math.pow(2,8),u=1;u!=c;)s=v.val&v.position,v.position>>=1,0==v.position&&(v.position=n,v.val=r(v.index++)),a|=(s>0?1:0)*u,u<<=1;f[h++]=e(a),l=h-1,d--;break;case 1:for(a=0,c=Math.pow(2,16),u=1;u!=c;)s=v.val&v.position,v.position>>=1,0==v.position&&(v.position=n,v.val=r(v.index++)),a|=(s>0?1:0)*u,u<<=1;f[h++]=e(a),l=h-1,d--;break;case 2:return y.join("")}if(0==d&&(d=Math.pow(2,p),p++),f[l])m=f[l];else{if(l!==h)return null;m=i+i.charAt(0)}y.push(m),f[h++]=i+m.charAt(0),i=m,0==--d&&(d=Math.pow(2,p),p++)}}};return i}();void 0===(r=function(){return o}.call(t,n,t,e))||(e.exports=r)},895:e=>{e.exports=function(e,t,n,r){var o=e[0],i=e[1],a=!1;void 0===n&&(n=0),void 0===r&&(r=t.length);for(var s=(r-n)/2,c=0,u=s-1;c<s;u=c++){var l=t[n+2*c+0],f=t[n+2*c+1],d=t[n+2*u+0],h=t[n+2*u+1];f>i!=h>i&&o<(d-l)*(i-f)/(h-f)+l&&(a=!a)}return a}},946:(e,t,n)=>{const r=n(909),o=async()=>await r.get({dir:"areaList",file:"index"}),i=({name:e,list:t})=>{let n=e;const r=t.find((e=>-1!==n.indexOf(e.name)));if(r){const t=r.name.length;return n=n.slice(t,e.length),{id:r.id,name:n,children:r.children}}const o=t.find((e=>-1!==n.indexOf(e.shortName)));if(o){const t=o.shortName.length;return n=n.slice(t,e.length),{id:o.id,name:n,children:o.children}}return null},a=async(e="",t)=>{let n=e;const r={province:"",city:"",district:""};let a=t;t||(a=await o());const s=i({name:n,list:a});if(s){n=s.name,r.province=s.id;const e=s.children,t=i({name:n,list:e});if(t){n=t.name,r.city=t.id;const e=i({name:n,list:t.children});return e&&(n=e.name,r.district=e.id),r}const o=e.reduce(((e,t)=>t.children?e.concat(t.children):e),[]),a=i({name:n,list:o});return a&&(n=a.name,r.district=a.id),r}const c=a.reduce(((e,t)=>t.children?e.concat(t.children):e),[]),u=i({name:n,list:c});if(u){n=u.name,r.city=u.id;const e=i({name:n,list:u.children});e&&(n=e.name,r.district=e.id)}return r},s=async(e={})=>{let{code:t}={...e};t="string"==typeof t?t:t.toString();const n={province:"",provinceCode:"",city:"",cityCode:"",district:"",districtCode:"",code:t,address:""};if((await o()).every((e=>e.id===t?(n.province=e.name,n.provinceCode=e.id,!1):!e.children||e.children.every((r=>r.id===t?(n.province=e.name,n.provinceCode=e.id,n.city=r.name,n.cityCode=r.id,!1):!r.children||r.children.every((o=>o.id!==t||(n.province=e.name,n.provinceCode=e.id,n.city=r.name,n.cityCode=r.id,n.district=o.name,n.districtCode=o.id,!1))))))))throw new Error("未找到该地区");return n.address=n.province+n.city+n.district,n},c=async({provinceCode:e,cityCode:t,districtCode:n})=>{const o={province:{},city:{},district:{}};if(e){const t=await r.get({dir:"province",file:e});o.province={code:t.id,location:t.location,name:t.name,pinyin:t.pinyin}}if(t){const n=(await r.get({dir:"city",file:e})).find((e=>e.id===t));o.city={code:n.id,location:n.location,name:n.name,pinyin:n.pinyin}}if(n){const e=(await r.get({dir:"district",file:t})).find((e=>e.id===n));o.district={code:e.id,location:e.location,name:e.name,pinyin:e.pinyin}}return o},u=async(e,t)=>{let n=t;if(n||(n=await o()),!e)return n.map((e=>({code:e.id,name:e.name})));for(let t=0;t<n.length;t++){const r=n[t];if(r.id===e&&r.children)return r.children.map((e=>({code:e.id,name:e.name})));if(r.children){const t=await u(e,r.children);if(t)return t}}};e.exports={getList:u,searchCodeInfo:async({code:e,detail:t})=>{const{province:n,city:r,district:o,address:i,provinceCode:a,cityCode:u,districtCode:l}=await s({code:e}),f={province:n,city:r,district:o,address:i,code:e};if(t){const e=await c({provinceCode:a,cityCode:u,districtCode:l});f.detail=e}return f},searchStrAddress:async e=>{const{province:t,city:n,district:r}=await a(e);return r||n||t||null},analysisAddress:a,searchCodeDetailInfo:async({code:e})=>{const{provinceCode:t,cityCode:n,districtCode:r}=await s({code:e}),o=await c({provinceCode:t,cityCode:n,districtCode:r});return Object.keys(o.district).length?o.district:Object.keys(o.city).length?o.city:Object.keys(o.province).length?o.province:void 0}}},182:e=>{e.exports=new class{constructor(){this.config={timeout:1e4,enableHighAccuracy:!1,detail:!1},this.cdn=["https://npm.onmicrosoft.cn/@pikaz/location/lib","https://unpkg.com/@pikaz/location/lib"],this.userCdn=""}set(e){this.config={...this.config,...e},this.config.url&&(this.userCdn=this.config.url)}}},955:(e,t,n)=>{const r=n(909),o=n(895),i=n(182),a=({latitude:e,longitude:t,address:n})=>n.find((n=>n.polygon.find((n=>{if(o([t,e],n))return n}))));e.exports={getGeo:(e={})=>{const{enableHighAccuracy:t,timeout:n}={...i.config,...e};return new Promise(((e,r)=>{if(navigator.geolocation){const o=navigator.geolocation.watchPosition((t=>{const{latitude:n,longitude:r}=t.coords;navigator.geolocation.clearWatch(o),e({latitude:n,longitude:r})}),(e=>{switch(navigator.geolocation.clearWatch(o),e.code){case e.PERMISSION_DENIED:r(new Error("html5已拒绝定位"));break;case e.POSITION_UNAVAILABLE:r(new Error("html5位置信息不可用"));break;case e.TIMEOUT:r(new Error("定位超时"));break;case e.UNKNOWN_ERROR:r(new Error("html5定位未知错误"))}}),{enableHighAccuracy:t,timeout:n,maximumAge:0})}else r(new Error("浏览器不支持HTML5定位"))}))},getGeoCode:async({latitude:e,longitude:t})=>{try{let n="";const o=(await r.get({dir:"province",file:"short"})).filter((n=>a({latitude:e,longitude:t,address:[n]})));let i="";for(let n=0;n<o.length;n++){const{id:s}=o[n],c=await r.get({dir:"province",file:s}),u=a({latitude:e,longitude:t,address:[c]});u&&(i=u)}if(i){n=i.id;const o=await r.get({dir:"city",file:i.id}),s=a({latitude:e,longitude:t,address:o});if(s){n=s.id;const o=await r.get({dir:"district",file:s.id}),i=a({latitude:e,longitude:t,address:o});i&&(n=i.id)}}if(!n)throw new Error("非中国境内");return n}catch(e){throw e}}}},909:(e,t,n)=>{const r=n(218),{decompressFromEncodedURIComponent:o}=n(961),i=n(483),a=n(182),{version:s,fileDate:c}=n(147);e.exports=new class{constructor(){this.local=null,this.localConfig={name:"pikazLocation",storeName:"v"+s.split(".")[0]+"."+s.split(".")[1]}}async get({dir:e,file:t}){if(!this.local){const e=i.createInstance(this.localConfig);await e.ready(),this.local=e}const n=`${e}-${t}-${c[e]}`,s=await this.local.getItem(n);if(s)return s;try{const i=await(async({file:e})=>{const t=r.CancelToken;let n;const i=async(e,i)=>{const s=await r({url:`${e}/static/${i}.json`,method:"get",dataType:"json",cancelToken:new t((function(e){n=e})),timeout:a.timeout});if(!s||!s.data||"[object String]"!=Object.prototype.toString.call(s.data.s))throw new Error("未获取到文件");const c=o(s.data.s);return JSON.parse(c)};try{const t=a.userCdn;if(t)return await i(t,e);throw new Error("未找到设置的url")}catch(t){const r=a.cdn.map((t=>new Promise((n=>{i(t,e).then((e=>{n(e)})).catch((()=>{}))}))));try{return await Promise.race(r)}catch(e){throw new Error("定位失败")}finally{n()}}})({file:`${e}/${t}`});return this.local.setItem(n,i),i}catch(e){throw new Error("定位失败")}}async getVal({key:e,gainVal:t,expiration:n}){if(!this.local){const e=i.createInstance(this.localConfig);await e.ready(),this.local=e}const r=(new Date).getTime(),o=n||0,a=`local-${e}`,s=await this.local.getItem(a);if(s&&s.expiration>r)return s.val;const c=await t();return await this.local.setItem(a,{val:c,expiration:r+o}),c}async clear(){await this.local.clear()}}},138:(e,t,n)=>{const r=n(182),{getGeo:o,getGeoCode:i}=n(955),{getList:a,searchCodeInfo:s,searchStrAddress:c,searchCodeDetailInfo:u}=n(946),{getIpCode:l}=n(454),f=async(e,t={})=>{let{timeout:n}={...r.config,...t};return await Promise.race([e(t),new Promise(((e,t)=>{setTimeout((()=>{t(new Error("定位超时"))}),n)}))])},d=async(e={})=>{let{timeout:t,enableHighAccuracy:n,detail:a,latitude:c,longitude:u}={...r.config,...e};if(!c||!u){const{latitude:e,longitude:r}=await o({timeout:t,enableHighAccuracy:n});c=e,u=r}return await f((async()=>{const e=await i({latitude:c,longitude:u});if(!e)throw new Error("非中国境内");return{...await s({code:e,detail:a}),latitude:c,longitude:u}}),{timeout:t})},h=async(e={})=>{let{detail:t,ip:n}={...r.config,...e};const{code:o,ip:i}=await l({ip:n});return n||(n=i),{...await s({code:o,detail:t}),ip:n}},p=async(e={})=>{const{address:t,detail:n}={...r.config,...e},o=await c(t);if(!o)throw new Error("解析地址失败,请确认地址包含省级或市级名称");return await s({code:o,detail:n})},m=async(e={})=>{const{code:t,detail:n}={...r.config,...e};return await s({code:t,detail:n})};e.exports={setConfig:({timeout:e,url:t})=>{r.set({timeout:e,url:t})},getLocation:async(e={})=>{try{return{...await d(e),type:"h5"}}catch(t){return{...await f(h,e),type:"ip"}}},getH5Location:d,getIpLocation:e=>f(h,e),searchList:async(e={})=>{const{code:t}={...e};return await a(t||"")||[]},searchCodeAddress:e=>f(m,e),searchAddress:e=>f(p,e),searchCodeDetail:e=>f(u,e)}},454:(e,t,n)=>{const{decompressFromEncodedURIComponent:r}=n(961),o=n(909),i=e=>{const t=e.split(".").reduce(((e,t)=>`${e}${(e=>{const t=e.split("").reverse();return new Array(3).fill(0).map(((e,n)=>t[n]||0)).reverse().join("")})(t)}`),"");return Number(t)},a=()=>new Promise(((e,t)=>{const n="ipCallback"+(new Date).getTime(),o=document.createElement("script");o.onerror=()=>{t(new Error("获取ip失败"))},window[n]=n=>{n&&n.ip?e(n.ip):t(new Error("ip定位失败"))},o.src=r("BYFxAcGcC4HpYIbgJYDpkoGYE9UHsAnAc1gH5NCBbBEAXgCtI8A7cAMjYGMEAbHgIwScA1rSA")+n,document.body.appendChild(o)}));e.exports={addZero:i,getIpCode:async(e={})=>{let{ip:t}={...e};t||(t=await o.getVal({key:"ip",gainVal:a,expiration:864e5}));const n=t.split(".").map((e=>Number(e)||0));if(4!==n.length)throw new Error("ip格式错误,只支持ipv4");return{code:(await o.get({dir:"ip",file:`${n[0]}.${n[1]}`})).reduce(((e,n)=>{const{district:r,id:o}=n,a=i(t);return a>=r[0]&&a<=r[1]?o:e}),""),ip:t}}}},218:(e,t,n)=>{"use strict";function r(e,t){return function(){return e.apply(t,arguments)}}const{toString:o}=Object.prototype,{getPrototypeOf:i}=Object,a=(s=Object.create(null),e=>{const t=o.call(e);return s[t]||(s[t]=t.slice(8,-1).toLowerCase())});var s;const c=e=>(e=e.toLowerCase(),t=>a(t)===e),u=e=>t=>typeof t===e,{isArray:l}=Array,f=u("undefined"),d=c("ArrayBuffer"),h=u("string"),p=u("function"),m=u("number"),y=e=>null!==e&&"object"==typeof e,v=e=>{if("object"!==a(e))return!1;const t=i(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},g=c("Date"),b=c("File"),w=c("Blob"),E=c("FileList"),S=c("URLSearchParams");function _(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),l(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{const o=n?Object.getOwnPropertyNames(e):Object.keys(e),i=o.length;let a;for(r=0;r<i;r++)a=o[r],t.call(null,e[a],a,e)}}function O(e,t){t=t.toLowerCase();const n=Object.keys(e);let r,o=n.length;for(;o-- >0;)if(r=n[o],t===r.toLowerCase())return r;return null}const A="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:n.g,R=e=>!f(e)&&e!==A,C=(j="undefined"!=typeof Uint8Array&&i(Uint8Array),e=>j&&e instanceof j);var j;const I=c("HTMLFormElement"),N=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),x=c("RegExp"),T=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};_(n,((n,o)=>{let i;!1!==(i=t(n,o,e))&&(r[o]=i||n)})),Object.defineProperties(e,r)},k="abcdefghijklmnopqrstuvwxyz",D="0123456789",B={DIGIT:D,ALPHA:k,ALPHA_DIGIT:k+k.toUpperCase()+D},P=c("AsyncFunction");var F={isArray:l,isArrayBuffer:d,isBuffer:function(e){return null!==e&&!f(e)&&null!==e.constructor&&!f(e.constructor)&&p(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||p(e.append)&&("formdata"===(t=a(e))||"object"===t&&p(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&d(e.buffer),t},isString:h,isNumber:m,isBoolean:e=>!0===e||!1===e,isObject:y,isPlainObject:v,isUndefined:f,isDate:g,isFile:b,isBlob:w,isRegExp:x,isFunction:p,isStream:e=>y(e)&&p(e.pipe),isURLSearchParams:S,isTypedArray:C,isFileList:E,forEach:_,merge:function e(){const{caseless:t}=R(this)&&this||{},n={},r=(r,o)=>{const i=t&&O(n,o)||o;v(n[i])&&v(r)?n[i]=e(n[i],r):v(r)?n[i]=e({},r):l(r)?n[i]=r.slice():n[i]=r};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&_(arguments[e],r);return n},extend:(e,t,n,{allOwnKeys:o}={})=>(_(t,((t,o)=>{n&&p(t)?e[o]=r(t,n):e[o]=t}),{allOwnKeys:o}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:(e,t,n,r)=>{let o,a,s;const c={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),a=o.length;a-- >0;)s=o[a],r&&!r(s,e,t)||c[s]||(t[s]=e[s],c[s]=!0);e=!1!==n&&i(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:a,kindOfTest:c,endsWith:(e,t,n)=>{e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return-1!==r&&r===n},toArray:e=>{if(!e)return null;if(l(e))return e;let t=e.length;if(!m(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let r;for(;(r=n.next())&&!r.done;){const n=r.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{let n;const r=[];for(;null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:I,hasOwnProperty:N,hasOwnProp:N,reduceDescriptors:T,freezeMethods:e=>{T(e,((t,n)=>{if(p(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];p(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:(e,t)=>{const n={},r=e=>{e.forEach((e=>{n[e]=!0}))};return l(e)?r(e):r(String(e).split(t)),n},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n})),noop:()=>{},toFiniteNumber:(e,t)=>(e=+e,Number.isFinite(e)?e:t),findKey:O,global:A,isContextDefined:R,ALPHABET:B,generateString:(e=16,t=B.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n},isSpecCompliantForm:function(e){return!!(e&&p(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(y(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[r]=e;const o=l(e)?[]:{};return _(e,((e,t)=>{const i=n(e,r+1);!f(i)&&(o[t]=i)})),t[r]=void 0,o}}return e};return n(e,0)},isAsyncFn:P,isThenable:e=>e&&(y(e)||p(e))&&p(e.then)&&p(e.catch)};function L(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}F.inherits(L,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:F.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const U=L.prototype,M={};function z(e){return F.isPlainObject(e)||F.isArray(e)}function q(e){return F.endsWith(e,"[]")?e.slice(0,-2):e}function H(e,t,n){return e?e.concat(t).map((function(e,t){return e=q(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((e=>{M[e]={value:e}})),Object.defineProperties(L,M),Object.defineProperty(U,"isAxiosError",{value:!0}),L.from=(e,t,n,r,o,i)=>{const a=Object.create(U);return F.toFlatObject(e,a,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),L.call(a,e.message,t,n,r,o),a.cause=e,a.name=e.name,i&&Object.assign(a,i),a};const W=F.toFlatObject(F,{},null,(function(e){return/^is[A-Z]/.test(e)}));function J(e,t,n){if(!F.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(n=F.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!F.isUndefined(t[e])}))).metaTokens,o=n.visitor||u,i=n.dots,a=n.indexes,s=(n.Blob||"undefined"!=typeof Blob&&Blob)&&F.isSpecCompliantForm(t);if(!F.isFunction(o))throw new TypeError("visitor must be a function");function c(e){if(null===e)return"";if(F.isDate(e))return e.toISOString();if(!s&&F.isBlob(e))throw new L("Blob is not supported. Use a Buffer instead.");return F.isArrayBuffer(e)||F.isTypedArray(e)?s&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function u(e,n,o){let s=e;if(e&&!o&&"object"==typeof e)if(F.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(F.isArray(e)&&function(e){return F.isArray(e)&&!e.some(z)}(e)||(F.isFileList(e)||F.endsWith(n,"[]"))&&(s=F.toArray(e)))return n=q(n),s.forEach((function(e,r){!F.isUndefined(e)&&null!==e&&t.append(!0===a?H([n],r,i):null===a?n:n+"[]",c(e))})),!1;return!!z(e)||(t.append(H(o,n,i),c(e)),!1)}const l=[],f=Object.assign(W,{defaultVisitor:u,convertValue:c,isVisitable:z});if(!F.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!F.isUndefined(n)){if(-1!==l.indexOf(n))throw Error("Circular reference detected in "+r.join("."));l.push(n),F.forEach(n,(function(n,i){!0===(!(F.isUndefined(n)||null===n)&&o.call(t,n,F.isString(i)?i.trim():i,r,f))&&e(n,r?r.concat(i):[i])})),l.pop()}}(e),t}function V(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function K(e,t){this._pairs=[],e&&J(e,this,t)}const G=K.prototype;function $(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function X(e,t,n){if(!t)return e;const r=n&&n.encode||$,o=n&&n.serialize;let i;if(i=o?o(t,n):F.isURLSearchParams(t)?t.toString():new K(t,n).toString(r),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}G.append=function(e,t){this._pairs.push([e,t])},G.toString=function(e){const t=e?function(t){return e.call(this,t,V)}:V;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};var Q=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){F.forEach(this.handlers,(function(t){null!==t&&e(t)}))}},Y={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Z={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:K,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]};const ee="undefined"!=typeof window&&"undefined"!=typeof document,te=(ne="undefined"!=typeof navigator&&navigator.product,ee&&["ReactNative","NativeScript","NS"].indexOf(ne)<0);var ne;const re="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts;var oe={...Object.freeze({__proto__:null,hasBrowserEnv:ee,hasStandardBrowserWebWorkerEnv:re,hasStandardBrowserEnv:te}),...Z};function ie(e){function t(e,n,r,o){let i=e[o++];const a=Number.isFinite(+i),s=o>=e.length;return i=!i&&F.isArray(r)?r.length:i,s?(F.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!a):(r[i]&&F.isObject(r[i])||(r[i]=[]),t(e,n,r[i],o)&&F.isArray(r[i])&&(r[i]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r<o;r++)i=n[r],t[i]=e[i];return t}(r[i])),!a)}if(F.isFormData(e)&&F.isFunction(e.entries)){const n={};return F.forEachEntry(e,((e,r)=>{t(function(e){return F.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),r,n,0)})),n}return null}const ae={transitional:Y,adapter:["xhr","http"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=F.isObject(e);if(o&&F.isHTMLForm(e)&&(e=new FormData(e)),F.isFormData(e))return r&&r?JSON.stringify(ie(e)):e;if(F.isArrayBuffer(e)||F.isBuffer(e)||F.isStream(e)||F.isFile(e)||F.isBlob(e))return e;if(F.isArrayBufferView(e))return e.buffer;if(F.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return J(e,new oe.classes.URLSearchParams,Object.assign({visitor:function(e,t,n,r){return oe.isNode&&F.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((i=F.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return J(i?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(F.isString(e))try{return(0,JSON.parse)(e),F.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||ae.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(e&&F.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(e){if(n){if("SyntaxError"===e.name)throw L.from(e,L.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:oe.classes.FormData,Blob:oe.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};F.forEach(["delete","get","head","post","put","patch"],(e=>{ae.headers[e]={}}));var se=ae;const ce=F.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),ue=Symbol("internals");function le(e){return e&&String(e).trim().toLowerCase()}function fe(e){return!1===e||null==e?e:F.isArray(e)?e.map(fe):String(e)}function de(e,t,n,r,o){return F.isFunction(r)?r.call(this,t,n):(o&&(t=n),F.isString(t)?F.isString(r)?-1!==t.indexOf(r):F.isRegExp(r)?r.test(t):void 0:void 0)}class he{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=le(t);if(!o)throw new Error("header name must be a non-empty string");const i=F.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=fe(e))}const i=(e,t)=>F.forEach(e,((e,n)=>o(e,n,t)));return F.isPlainObject(e)||e instanceof this.constructor?i(e,t):F.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim())?i((e=>{const t={};let n,r,o;return e&&e.split("\n").forEach((function(e){o=e.indexOf(":"),n=e.substring(0,o).trim().toLowerCase(),r=e.substring(o+1).trim(),!n||t[n]&&ce[n]||("set-cookie"===n?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)})),t})(e),t):null!=e&&o(t,e,n),this}get(e,t){if(e=le(e)){const n=F.findKey(this,e);if(n){const e=this[n];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}(e);if(F.isFunction(t))return t.call(this,e,n);if(F.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=le(e)){const n=F.findKey(this,e);return!(!n||void 0===this[n]||t&&!de(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=le(e)){const o=F.findKey(n,e);!o||t&&!de(0,n[o],o,t)||(delete n[o],r=!0)}}return F.isArray(e)?e.forEach(o):o(e),r}clear(e){const t=Object.keys(this);let n=t.length,r=!1;for(;n--;){const o=t[n];e&&!de(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return F.forEach(this,((r,o)=>{const i=F.findKey(n,o);if(i)return t[i]=fe(r),void delete t[o];const a=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,n)=>t.toUpperCase()+n))}(o):String(o).trim();a!==o&&delete t[o],t[a]=fe(r),n[a]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return F.forEach(this,((n,r)=>{null!=n&&!1!==n&&(t[r]=e&&F.isArray(n)?n.join(", "):n)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const n=new this(e);return t.forEach((e=>n.set(e))),n}static accessor(e){const t=(this[ue]=this[ue]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=le(e);t[r]||(function(e,t){const n=F.toCamelCase(" "+t);["get","set","has"].forEach((r=>{Object.defineProperty(e,r+n,{value:function(e,n,o){return this[r].call(this,t,e,n,o)},configurable:!0})}))}(n,e),t[r]=!0)}return F.isArray(e)?e.forEach(r):r(e),this}}he.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),F.reduceDescriptors(he.prototype,(({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}})),F.freezeMethods(he);var pe=he;function me(e,t){const n=this||se,r=t||n,o=pe.from(r.headers);let i=r.data;return F.forEach(e,(function(e){i=e.call(n,i,o.normalize(),t?t.status:void 0)})),o.normalize(),i}function ye(e){return!(!e||!e.__CANCEL__)}function ve(e,t,n){L.call(this,null==e?"canceled":e,L.ERR_CANCELED,t,n),this.name="CanceledError"}F.inherits(ve,L,{__CANCEL__:!0});var ge=oe.hasStandardBrowserEnv?{write(e,t,n,r,o,i){const a=[e+"="+encodeURIComponent(t)];F.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),F.isString(r)&&a.push("path="+r),F.isString(o)&&a.push("domain="+o),!0===i&&a.push("secure"),document.cookie=a.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read:()=>null,remove(){}};function be(e,t){return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}var we=oe.hasStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a");let n;function r(n){let r=n;return e&&(t.setAttribute("href",r),r=t.href),t.setAttribute("href",r),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:"/"===t.pathname.charAt(0)?t.pathname:"/"+t.pathname}}return n=r(window.location.href),function(e){const t=F.isString(e)?r(e):e;return t.protocol===n.protocol&&t.host===n.host}}():function(){return!0};function Ee(e,t){let n=0;const r=function(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o,i=0,a=0;return t=void 0!==t?t:1e3,function(s){const c=Date.now(),u=r[a];o||(o=c),n[i]=s,r[i]=c;let l=a,f=0;for(;l!==i;)f+=n[l++],l%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),c-o<t)return;const d=u&&c-u;return d?Math.round(1e3*f/d):void 0}}(50,250);return o=>{const i=o.loaded,a=o.lengthComputable?o.total:void 0,s=i-n,c=r(s);n=i;const u={loaded:i,total:a,progress:a?i/a:void 0,bytes:s,rate:c||void 0,estimated:c&&a&&i<=a?(a-i)/c:void 0,event:o};u[t?"download":"upload"]=!0,e(u)}}const Se={http:null,xhr:"undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,n){let r=e.data;const o=pe.from(e.headers).normalize();let i,a,{responseType:s,withXSRFToken:c}=e;function u(){e.cancelToken&&e.cancelToken.unsubscribe(i),e.signal&&e.signal.removeEventListener("abort",i)}if(F.isFormData(r))if(oe.hasStandardBrowserEnv||oe.hasStandardBrowserWebWorkerEnv)o.setContentType(!1);else if(!1!==(a=o.getContentType())){const[e,...t]=a?a.split(";").map((e=>e.trim())).filter(Boolean):[];o.setContentType([e||"multipart/form-data",...t].join("; "))}let l=new XMLHttpRequest;if(e.auth){const t=e.auth.username||"",n=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.set("Authorization","Basic "+btoa(t+":"+n))}const f=be(e.baseURL,e.url);function d(){if(!l)return;const r=pe.from("getAllResponseHeaders"in l&&l.getAllResponseHeaders());!function(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new L("Request failed with status code "+n.status,[L.ERR_BAD_REQUEST,L.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}((function(e){t(e),u()}),(function(e){n(e),u()}),{data:s&&"text"!==s&&"json"!==s?l.response:l.responseText,status:l.status,statusText:l.statusText,headers:r,config:e,request:l}),l=null}if(l.open(e.method.toUpperCase(),X(f,e.params,e.paramsSerializer),!0),l.timeout=e.timeout,"onloadend"in l?l.onloadend=d:l.onreadystatechange=function(){l&&4===l.readyState&&(0!==l.status||l.responseURL&&0===l.responseURL.indexOf("file:"))&&setTimeout(d)},l.onabort=function(){l&&(n(new L("Request aborted",L.ECONNABORTED,e,l)),l=null)},l.onerror=function(){n(new L("Network Error",L.ERR_NETWORK,e,l)),l=null},l.ontimeout=function(){let t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const r=e.transitional||Y;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(new L(t,r.clarifyTimeoutError?L.ETIMEDOUT:L.ECONNABORTED,e,l)),l=null},oe.hasStandardBrowserEnv&&(c&&F.isFunction(c)&&(c=c(e)),c||!1!==c&&we(f))){const t=e.xsrfHeaderName&&e.xsrfCookieName&&ge.read(e.xsrfCookieName);t&&o.set(e.xsrfHeaderName,t)}void 0===r&&o.setContentType(null),"setRequestHeader"in l&&F.forEach(o.toJSON(),(function(e,t){l.setRequestHeader(t,e)})),F.isUndefined(e.withCredentials)||(l.withCredentials=!!e.withCredentials),s&&"json"!==s&&(l.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&l.addEventListener("progress",Ee(e.onDownloadProgress,!0)),"function"==typeof e.onUploadProgress&&l.upload&&l.upload.addEventListener("progress",Ee(e.onUploadProgress)),(e.cancelToken||e.signal)&&(i=t=>{l&&(n(!t||t.type?new ve(null,e,l):t),l.abort(),l=null)},e.cancelToken&&e.cancelToken.subscribe(i),e.signal&&(e.signal.aborted?i():e.signal.addEventListener("abort",i)));const h=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(f);h&&-1===oe.protocols.indexOf(h)?n(new L("Unsupported protocol "+h+":",L.ERR_BAD_REQUEST,e)):l.send(r||null)}))}};F.forEach(Se,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));const _e=e=>`- ${e}`,Oe=e=>F.isFunction(e)||null===e||!1===e;var Ae=e=>{e=F.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let i=0;i<t;i++){let t;if(n=e[i],r=n,!Oe(n)&&(r=Se[(t=String(n)).toLowerCase()],void 0===r))throw new L(`Unknown adapter '${t}'`);if(r)break;o[t||"#"+i]=r}if(!r){const e=Object.entries(o).map((([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build")));throw new L("There is no suitable adapter to dispatch the request "+(t?e.length>1?"since :\n"+e.map(_e).join("\n"):" "+_e(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return r};function Re(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new ve(null,e)}function Ce(e){return Re(e),e.headers=pe.from(e.headers),e.data=me.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Ae(e.adapter||se.adapter)(e).then((function(t){return Re(e),t.data=me.call(e,e.transformResponse,t),t.headers=pe.from(t.headers),t}),(function(t){return ye(t)||(Re(e),t&&t.response&&(t.response.data=me.call(e,e.transformResponse,t.response),t.response.headers=pe.from(t.response.headers))),Promise.reject(t)}))}const je=e=>e instanceof pe?e.toJSON():e;function Ie(e,t){t=t||{};const n={};function r(e,t,n){return F.isPlainObject(e)&&F.isPlainObject(t)?F.merge.call({caseless:n},e,t):F.isPlainObject(t)?F.merge({},t):F.isArray(t)?t.slice():t}function o(e,t,n){return F.isUndefined(t)?F.isUndefined(e)?void 0:r(void 0,e,n):r(e,t,n)}function i(e,t){if(!F.isUndefined(t))return r(void 0,t)}function a(e,t){return F.isUndefined(t)?F.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function s(n,o,i){return i in t?r(n,o):i in e?r(void 0,n):void 0}const c={url:i,method:i,data:i,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(e,t)=>o(je(e),je(t),!0)};return F.forEach(Object.keys(Object.assign({},e,t)),(function(r){const i=c[r]||o,a=i(e[r],t[r],r);F.isUndefined(a)&&i!==s||(n[r]=a)})),n}const Ne={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{Ne[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));const xe={};Ne.transitional=function(e,t,n){function r(e,t){return"[Axios v1.6.2] Transitional option '"+e+"'"+t+(n?". "+n:"")}return(n,o,i)=>{if(!1===e)throw new L(r(o," has been removed"+(t?" in "+t:"")),L.ERR_DEPRECATED);return t&&!xe[o]&&(xe[o]=!0,console.warn(r(o," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,o,i)}};var Te={assertOptions:function(e,t,n){if("object"!=typeof e)throw new L("options must be an object",L.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],a=t[i];if(a){const t=e[i],n=void 0===t||a(t,i,e);if(!0!==n)throw new L("option "+i+" must be "+n,L.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new L("Unknown option "+i,L.ERR_BAD_OPTION)}},validators:Ne};const ke=Te.validators;class De{constructor(e){this.defaults=e,this.interceptors={request:new Q,response:new Q}}request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Ie(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;void 0!==n&&Te.assertOptions(n,{silentJSONParsing:ke.transitional(ke.boolean),forcedJSONParsing:ke.transitional(ke.boolean),clarifyTimeoutError:ke.transitional(ke.boolean)},!1),null!=r&&(F.isFunction(r)?t.paramsSerializer={serialize:r}:Te.assertOptions(r,{encode:ke.function,serialize:ke.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=o&&F.merge(o.common,o[t.method]);o&&F.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete o[e]})),t.headers=pe.concat(i,o);const a=[];let s=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(s=s&&e.synchronous,a.unshift(e.fulfilled,e.rejected))}));const c=[];let u;this.interceptors.response.forEach((function(e){c.push(e.fulfilled,e.rejected)}));let l,f=0;if(!s){const e=[Ce.bind(this),void 0];for(e.unshift.apply(e,a),e.push.apply(e,c),l=e.length,u=Promise.resolve(t);f<l;)u=u.then(e[f++],e[f++]);return u}l=a.length;let d=t;for(f=0;f<l;){const e=a[f++],t=a[f++];try{d=e(d)}catch(e){t.call(this,e);break}}try{u=Ce.call(this,d)}catch(e){return Promise.reject(e)}for(f=0,l=c.length;f<l;)u=u.then(c[f++],c[f++]);return u}getUri(e){return X(be((e=Ie(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}F.forEach(["delete","get","head","options"],(function(e){De.prototype[e]=function(t,n){return this.request(Ie(n||{},{method:e,url:t,data:(n||{}).data}))}})),F.forEach(["post","put","patch"],(function(e){function t(t){return function(n,r,o){return this.request(Ie(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}De.prototype[e]=t(),De.prototype[e+"Form"]=t(!0)}));var Be=De;class Pe{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise((function(e){t=e}));const n=this;this.promise.then((e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null})),this.promise.then=e=>{let t;const r=new Promise((e=>{n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e,r,o){n.reason||(n.reason=new ve(e,r,o),t(n.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}static source(){let e;return{token:new Pe((function(t){e=t})),cancel:e}}}var Fe=Pe;const Le={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Le).forEach((([e,t])=>{Le[t]=e}));var Ue=Le;const Me=function e(t){const n=new Be(t),o=r(Be.prototype.request,n);return F.extend(o,Be.prototype,n,{allOwnKeys:!0}),F.extend(o,n,null,{allOwnKeys:!0}),o.create=function(n){return e(Ie(t,n))},o}(se);Me.Axios=Be,Me.CanceledError=ve,Me.CancelToken=Fe,Me.isCancel=ye,Me.VERSION="1.6.2",Me.toFormData=J,Me.AxiosError=L,Me.Cancel=Me.CanceledError,Me.all=function(e){return Promise.all(e)},Me.spread=function(e){return function(t){return e.apply(null,t)}},Me.isAxiosError=function(e){return F.isObject(e)&&!0===e.isAxiosError},Me.mergeConfig=Ie,Me.AxiosHeaders=pe,Me.formToJSON=e=>ie(F.isHTMLForm(e)?new FormData(e):e),Me.getAdapter=Ae,Me.HttpStatusCode=Ue,Me.default=Me,e.exports=Me},147:e=>{"use strict";e.exports=JSON.parse('{"name":"@pikaz/location","version":"1.0.9","description":"used to obtain location from the browser","private":false,"main":"lib/pikazLocation.js","module":"lib/pikazLocationModule.js","scripts":{"compress":"node utils/compress.js","analysisip":"node utils/analysisIp.js","build":"webpack && webpack --config module.config.js"},"keywords":["geolocation","location","longitude","latitude","province","city","district"],"files":["lib"],"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/pikaz-18/pikaz-location.git"},"author":"pikaz","license":"MIT","bugs":{"url":"https://github.com/pikaz-18/pikaz-location/issues"},"homepage":"https://github.com/pikaz-18/pikaz-location#readme","devDependencies":{"clean-webpack-plugin":"^4.0.0","copy-webpack-plugin":"^10.2.0","object-hash":"^3.0.0","webpack":"^5.65.0","webpack-cli":"^4.9.1"},"dependencies":{"axios":"^1.6.2","localforage":"^1.10.0","lz-string":"^1.4.4","point-in-polygon":"^1.1.0"},"fileDate":{"areaList":"202212301139","city":"202212301139","district":"202212301139","ip":"2024532110","province":"202317042"},"fileCode":{"areaList":"64b5a33f94b14ae208fca152fdc89dca1048360a","city":"7827eb2bc906b83df109ab24242ce68f98f9558b","district":"14d77ce6236e2025a4b1e3900cc70d0c32a62d0b","ip":"befa0a8a45fdc238a0fb4e4a3011dae43a06c1b4","province":"629a3c20a32e0de95e0633e0385234e2b7886c2d"}}')}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}return n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n(138)})()}));