-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.min.js
1 lines (1 loc) · 3.79 KB
/
index.min.js
1
var __FUNC=function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=1)}([function(e,t){e.exports.default=e.exports=((e="",t=(""+e).length)=>{return RegExp(`\\d{${t}}`,"ig").test(e)})},function(e,t,r){const n=r(2),o=r(3),a=r(9),u=r(11),s=r(14),i=r(15);e.exports.default=e.exports={serviceAPI:n,Validate:o,Url:a,Storage:u,Rotate:s,Form:i}},function(e,t){},function(e,t,r){const n=r(0),o=r(4),a=r(5),u=r(6),s=r(7),i=r(8);e.exports.default=e.exports={isNumber:n,isIdCard:o,isPhoneNumber:a,isEqual:u,isEmail:s,isEmpty:i}},function(e,t,r){const n=r(0);e.exports.default=e.exports=((e="")=>{let t=String(e).trim();if(18===t.length){let e;if("x"===t.substr(-1,1).toLowerCase()&&n(t.substring(0,17))||n(t)){e=JSON.parse(t.replace(/(\d{6})(\d{4})(\d{2})(\d{2})(\d{2})(\d{1})((\d|x|X){1})/,'{"areaCode":"$1","year":"$2","month":"$3","day":"$4","other":"$5","gender":"$6","flag":"$7"}'));let n=new Date,{areaCode:o,year:a,month:u,day:s,gender:i,flag:l}=e;if(a<1900||a>n.getFullYear()||u>12||s>new Date(a,u,0).getDate())return!1;{var r=0;let e=[7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2],n=["1","0","X","9","8","7","6","5","4","3","2"];return t.substring(0,17).split("").forEach((t,n)=>{r+=t*e[n]}),n[r%11]===l.toUpperCase()&&{areaCode:o,year:a,month:u,day:s,gender:i%2?1:0}}}return!1}return!1})},function(e,t,r){const n=r(0);e.exports.default=e.exports=(e=>{if(n(e)&&11===String(e).length){let t=JSON.parse(String(e).replace(/(\d{1})([345789]{1})(\d{9})/,'{"firstNum":"$1","sencondNum":"$2","others":"$3"}')),{firstNum:r,secondNum:n}=t;return!("1"!==r&&!n)}return!1})},function(e,t){e.exports.default=e.exports=((e,t,r=!1)=>r?e===t:e==t)},function(e,t){e.exports.default=e.exports=((e="")=>{if("string"==typeof e)return/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e);return!1})},function(e,t){e.exports.default=e.exports=((e="")=>!e.trim().length)},function(e,t,r){const n=r(10);e.exports.default=e.exports=n},function(e,t){e.exports.default=e.exports=((e=window.location.href,t="")=>{let r={};return e.replace(/([^(?|#)=&]+)(=([^&]*))?/g,(e,t,n,o)=>{r[t]=o}),t?r[t]:r})},function(e,t,r){const n=r(12),o=r(13);e.exports.default=e.exports={setStorage:n,getStorage:o}},function(e,t){e.exports.default=e.exports=((e,t,r=!0)=>{e&&r?sessionStorage.setItem(e,JSON.stringify(t)):localStorage.setItem(e,JSON.stringify(t))})},function(e,t){e.exports.default=e.exports=((e,t=!0)=>e&&t?JSON.parse(sessionStorage[e]):JSON.parse(localStorage[e]))},function(e,t){e.exports.default=e.exports=((e=[0,0],t=[0,0])=>{let r=t[0]-e[0],n=t[1]-e[1],o=180*Math.atan2(Math.abs(r),Math.abs(n))/Math.PI;return 0===r?0===n?0:n>0?-90:90:0===n?r>0?0:-180:r>0?n>0?o-90:90-o:n>0?-(90+o):90+o})},function(e,t){const r={getData(e=""){let t={};return document.querySelectorAll("body [name]").forEach(e=>{let r=e.getAttribute("name"),n=e.value;t[r]=n}),e?t[e]:t},setData(e="",t){e&&(document.querySelector(`[name=${e}]`).value=t)}};e.exports.default=e.exports=r}]);