2 lines
8.3 KiB
JavaScript
2 lines
8.3 KiB
JavaScript
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages3/common/vendor"],{1041:function(e,t,r){"use strict";(function(e){function r(e,t,r,n,i,o){var a,c=[e+r/2,t+n/2],u=[i,o];return u[0]<=c[0]&&u[1]<=c[1]?a=3:u[0]>=c[0]&&u[1]<=c[1]?a=2:u[0]<=c[0]&&u[1]>=c[1]?a=4:u[0]>=c[0]&&u[1]>=c[1]&&(a=1),a}function n(e,t){var r=e.imageLeft,n=e.imageTop;t=t||e.scale;var i=e.imageWidth,o=e.imageHeight;e.angle/90%2&&(i=e.imageHeight,o=e.imageWidth);var a=e.clipX,c=e.clipWidth,u=e.clipY,s=e.clipHeight,l=function(e){return e*t/2},d=l(i),f=l(o);return r=a+d>=r?r:a+d,r=a+c-d<=r?r:a+c-d,n=u+f>=n?n:u+f,n=u+s-f<=n?n:u+s-f,{left:r,top:n,scale:t}}function i(e,t){t=t||e.scale;var r=e.imageWidth,n=e.imageHeight,i=e.clipWidth,o=e.clipHeight,a=e.angle;return a/90%2&&(r=n,n=r),r*t<i&&(t=i/r),n*t<o&&(t=Math.max(t,o/n)),t}function o(t,r,n){var i=t,o=r,a=n.clipWidth,c=n.clipHeight,u=n.sysinfo,s=n.width,l=n.height;if(i&&o)i/o>(a||s)/(a||l)?(o=c||l,i=t/r*o):(i=a||s,o=r/t*i);else{var d=u||e.getSystemInfoSync();i=d.windowWidth,o=0}return{imageWidth:i,imageHeight:o}}function a(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}function c(e,t){var r=t.touches[0].clientX,n=t.touches[0].clientY,i=e.clipWidth,o=e.clipHeight,a=e.clipY,c=e.clipX,u=e.clipStart,s=e.isLockRatio,l=e.maxWidth,d=e.minWidth,f=e.maxHeight,g=e.minHeight;l/=2,d/=2,g/=2,f/=2;var h=i,p=o,m=a,w=c,v=function(){h=h<=l?h>=d?h:d:l,p=p<=f?p>=g?p:g:f},b=function(){return v(),!(h>l||h<d||p>f||p<g)||!s};switch(p=u.height+(u.corner>1&&u.corner<4?1:-1)*(u.y-n),u.corner){case 1:if(h=u.width-u.x+r,s&&(p=h/(i/o)),!b())return;break;case 2:if(h=u.width-u.x+r,s&&(p=h/(i/o)),!b())return;m=u.clipY-(p-u.height);break;case 3:if(h=u.width+u.x-r,s&&(p=h/(i/o)),!b())return;m=u.clipY-(p-u.height),w=u.clipX-(h-u.width);break;case 4:if(h=u.width+u.x-r,s&&(p=h/(i/o)),!b())return;w=u.clipX-(h-u.width);break;default:break}return{width:h,height:p,clipX:w,clipY:m}}function u(e,t,r){var n=t-e.touchRelative[0].x,i=r-e.touchRelative[0].y;return{left:n,top:i}}Object.defineProperty(t,"__esModule",{value:!0}),t.calcImageOffset=n,t.calcImageScale=i,t.calcImageSize=o,t.calcPythagoreanTheorem=a,t.clipTouchMoveOfCalculate=c,t.determineDirection=r,t.imageTouchMoveOfCalcOffset=u}).call(this,r(2)["default"])},452:function(e,t,r){"use strict";var n=r(4);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(11)),o=n(r(453));function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){(0,i.default)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var u=c({username:{rules:[{required:!0,errorMessage:"请输入用户名"},{minLength:3,maxLength:32,errorMessage:"用户名长度在 {minLength} 到 {maxLength} 个字符"},{validateFunction:function(e,t,r,n){return(/^1\d{10}$/.test(t)||/^(\w-*\.*)+@(\w-?)+(\.\w{2,})+$/.test(t))&&n("用户名不能是:手机号或邮箱"),/^\d+$/.test(t)&&n("用户名不能为纯数字"),/[\u4E00-\u9FA5\uF900-\uFA2D]{1,}/.test(t)&&n("用户名不能包含中文"),!0}}],label:"用户名"},nickname:{rules:[{minLength:3,maxLength:32,errorMessage:"昵称长度在 {minLength} 到 {maxLength} 个字符"},{validateFunction:function(e,t,r,n){return(/^1\d{10}$/.test(t)||/^(\w-*\.*)+@(\w-?)+(\.\w{2,})+$/.test(t))&&n("昵称不能是:手机号或邮箱"),/^\d+$/.test(t)&&n("昵称不能为纯数字"),/[\u4E00-\u9FA5\uF900-\uFA2D]{1,}/.test(t)&&n("昵称不能包含中文"),!0}}],label:"昵称"}},o.default.getPwdRules());t.default=u},453:function(e,t,r){"use strict";var n=r(4);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(43)),o=i.default.passwordStrength,a={super:/^(?=.*[0-9])(?=.*[a-z])(?=.*[A-Z])(?=.*[~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/])[0-9a-zA-Z~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/]{8,16}$/,strong:/^(?=.*[0-9])(?=.*[a-zA-Z])(?=.*[~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/])[0-9a-zA-Z~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/]{8,16}$/,medium:/^(?![0-9]+$)(?![a-zA-Z]+$)(?![~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/]+$)[0-9a-zA-Z~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/]{8,16}$/,weak:/^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*_\-+=`|\\(){}[\]:;"'<>,.?/]{6,16}$/},c={normal:{noPwd:"请输入密码",noRePwd:"再次输入密码",rePwdErr:"两次输入密码不一致"},passwordStrengthError:{super:"密码必须包含大小写字母、数字和特殊符号,密码长度必须在8-16位之间",strong:"密码必须包含字母、数字和特殊符号,密码长度必须在8-16位之间",medium:"密码必须为字母、数字和特殊符号任意两种的组合,密码长度必须在8-16位之间",weak:"密码必须包含字母,密码长度必须在6-16位之间"}};function u(e){return!(o&&a[o]&&!new RegExp(a[o]).test(e))||c.passwordStrengthError[o]}function s(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"password",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"password2",r={};return r[e]={rules:[{required:!0,errorMessage:c.normal.noPwd},{validateFunction:function(e,t,r,n){var i=u(t);return!0!==i&&n(i),!0}}]},t&&(r[t]={rules:[{required:!0,errorMessage:c.normal.noRePwd},{validateFunction:function(t,r,n,i){return r!=n[e]&&i(c.normal.rePwdErr),!0}}]}),r}var l={ERROR:c,validPwd:u,getPwdRules:s};t.default=l},454:function(e,t,r){"use strict";(function(e){var n=r(4);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(11)),o=r(184),a=n(r(43));function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){(0,i.default)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var s={data:function(){return{config:a.default,uniIdRedirectUrl:"",isMounted:!1}},onUnload:function(){},mounted:function(){this.isMounted=!0},onLoad:function(t){var r=this;if(t.is_weixin_redirect){if(e.showLoading({mask:!0}),window.location.href.includes("#")){var n=window.location.href.split("?")[1].split("&");n.forEach((function(e){var r=e.split("=");"code"==r[0]&&(t.code=r[1])}))}this.$nextTick((function(e){r.$refs.uniFabLogin.login({code:t.code},"weixin")}))}t.uniIdRedirectUrl&&(this.uniIdRedirectUrl=decodeURIComponent(t.uniIdRedirectUrl)),1===getCurrentPages().length&&(e.hideHomeButton(),console.log("已隐藏:返回首页按钮"))},computed:{needAgreements:function(){if(this.isMounted)return!!this.$refs.agreements&&this.$refs.agreements.needAgreements},agree:{get:function(){if(this.isMounted)return!this.$refs.agreements||this.$refs.agreements.isAgree},set:function(e){this.$refs.agreements?this.$refs.agreements.isAgree=e:console.log("不存在 隐私政策协议组件")}}},methods:{loginSuccess:function(e){o.mutations.loginSuccess(u(u({},e),{},{uniIdRedirectUrl:this.uniIdRedirectUrl}))}}},l=s;t.default=l}).call(this,r(2)["default"])},573:function(e,t,r){var n=r(574);function i(e,t){if(null==e)return{};var r,i,o=n(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}e.exports=i,e.exports.__esModule=!0,e.exports["default"]=e.exports},574:function(e,t){function r(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}e.exports=r,e.exports.__esModule=!0,e.exports["default"]=e.exports},575:function(e,t,r){"use strict";function n(e){if(!e||"string"!==typeof e||18!==e.length)return!1;for(var t=[7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2],r=[1,0,"x",9,8,7,6,5,4,3,2],n=e.substring(17),i=0,o=0;o<17;o++)i+=Number(e.charAt(o))*t[o];return r[i%11].toString()===n.toLowerCase()}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n;t.default=i}}]);
|
|
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages3/common/vendor.js.map
|