12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- ;(function(){function _slicedToArray(arr,i){return _arrayWithHoles(arr)||_iterableToArrayLimit(arr,i)||_unsupportedIterableToArray(arr,i)||_nonIterableRest();}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _iterableToArrayLimit(arr,i){var _i=arr==null?null:typeof Symbol!=="undefined"&&arr[Symbol.iterator]||arr["@@iterator"];if(_i==null)return;var _arr=[];var _n=true;var _d=false;var _s,_e;try{for(_i=_i.call(arr);!(_n=(_s=_i.next()).done);_n=true){_arr.push(_s.value);if(i&&_arr.length===i)break;}}catch(err){_d=true;_e=err;}finally{try{if(!_n&&_i["return"]!=null)_i["return"]();}finally{if(_d)throw _e;}}return _arr;}function _arrayWithHoles(arr){if(Array.isArray(arr))return arr;}function _createForOfIteratorHelper(o,allowArrayLike){var it=typeof Symbol!=="undefined"&&o[Symbol.iterator]||o["@@iterator"];if(!it){if(Array.isArray(o)||(it=_unsupportedIterableToArray(o))||allowArrayLike&&o&&typeof o.length==="number"){if(it)o=it;var i=0;var F=function F(){};return{s:F,n:function n(){if(i>=o.length)return{done:true};return{done:false,value:o[i++]};},e:function e(_e2){throw _e2;},f:F};}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}var normalCompletion=true,didErr=false,err;return{s:function s(){it=it.call(o);},n:function n(){var step=it.next();normalCompletion=step.done;return step;},e:function e(_e3){didErr=true;err=_e3;},f:function f(){try{if(!normalCompletion&&it.return!=null)it.return();}finally{if(didErr)throw err;}}};}function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread();}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen);}function _iterableToArray(iter){if(typeof Symbol!=="undefined"&&iter[Symbol.iterator]!=null||iter["@@iterator"]!=null)return Array.from(iter);}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr);}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++){arr2[i]=arr[i];}return arr2;}function _typeof(obj){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj;}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;},_typeof(obj);}function asyncGeneratorStep(gen,resolve,reject,_next,_throw,key,arg){try{var info=gen[key](arg);var value=info.value;}catch(error){reject(error);return;}if(info.done){resolve(value);}else{Promise.resolve(value).then(_next,_throw);}}function _asyncToGenerator(fn){return function(){var self=this,args=arguments;return new Promise(function(resolve,reject){var gen=fn.apply(self,args);function _next(value){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"next",value);}function _throw(err){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"throw",err);}_next(undefined);});};}function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value:value,enumerable:true,configurable:true,writable:true});}else{obj[key]=value;}return obj;}var __vite_style__=document.createElement('style');__vite_style__.innerHTML="._col-field-group_1vk7j_1{margin:0 .37333rem .32rem;border-radius:.26667rem;overflow:hidden;background-color:#fff;padding:.32rem;padding-bottom:0}._col-field-group_1vk7j_1 .van-field{padding-left:0;padding-right:0}.van-radio-group--horizontal{display:flex;flex-wrap:wrap}:root{--van-radio-size: .53333rem;--van-radio-border-color: var(--van-gray-5);--van-radio-transition-duration: var(--van-animation-duration-fast);--van-radio-label-margin: var(--van-padding-xs);--van-radio-label-color: var(--van-text-color);--van-radio-checked-icon-color: var(--van-primary-color);--van-radio-disabled-icon-color: var(--van-gray-5);--van-radio-disabled-label-color: var(--van-text-color-3);--van-radio-disabled-background-color: var(--van-border-color)}.van-radio{display:flex;align-items:center;overflow:hidden;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.van-radio--disabled{cursor:not-allowed}.van-radio--label-disabled{cursor:default}.van-radio--horizontal{margin-right:var(--van-padding-sm)}.van-radio__icon{flex:none;height:1em;font-size:var(--van-radio-size);line-height:1em;cursor:pointer}.van-radio__icon .van-icon{display:block;box-sizing:border-box;width:1.25em;height:1.25em;color:transparent;font-size:.8em;line-height:1.25;text-align:center;border:.02667rem solid var(--van-radio-border-color);transition-duration:var(--van-radio-transition-duration);transition-property:color,border-color,background-color}.van-radio__icon--round .van-icon{border-radius:100%}.van-radio__icon--checked .van-icon{color:var(--van-white);background-color:var(--van-radio-checked-icon-color);border-color:var(--van-radio-checked-icon-color)}.van-radio__icon--disabled{cursor:not-allowed}.van-radio__icon--disabled .van-icon{background-color:var(--van-radio-disabled-background-color);border-color:var(--van-radio-disabled-icon-color)}.van-radio__icon--disabled.van-radio__icon--checked .van-icon{color:var(--van-radio-disabled-icon-color)}.van-radio__label{margin-left:var(--van-radio-label-margin);color:var(--van-radio-label-color);line-height:var(--van-radio-size)}.van-radio__label--left{margin:0 var(--van-radio-label-margin) 0 0}.van-radio__label--disabled{color:var(--van-radio-disabled-label-color)}._subjects_1ijt0_1{padding:.4rem .4rem 2.13333rem}._subjects_1ijt0_1 ._title_1ijt0_4{padding:.32rem 0;color:#333;font-size:.42667rem}._subjects_1ijt0_1 ._title_1ijt0_4:before{content:\" \";display:inline-block;width:.08rem;height:.42667rem;background:#2dc7aa;border-radius:.08rem;margin-right:.21333rem;vertical-align:text-bottom}._subjects_1ijt0_1 ._btn-group_1ijt0_19{position:fixed;bottom:0;left:0;right:0;margin:.32rem}._subjects_1ijt0_1 ._subject-list_1ijt0_26{display:flex;align-items:center;flex-wrap:wrap}._subjects_1ijt0_1 ._subject-list_1ijt0_26 ._subject-item_1ijt0_31{position:relative;width:2.88rem;height:2.88rem;margin-right:.26667rem;margin-bottom:.26667rem;border-radius:.18667rem;overflow:hidden}._subjects_1ijt0_1 ._subject-list_1ijt0_26 ._subject-item_1ijt0_31:nth-child(3n){margin-right:0}._subjects_1ijt0_1 ._subject-list_1ijt0_26 ._topBg_1ijt0_43{position:absolute;top:0;left:0;width:100%;height:100%;background:linear-gradient(180deg,rgba(0,0,0,0) 0%,rgba(0,0,0,.54) 100%)}._subjects_1ijt0_1 ._subject-list_1ijt0_26 ._checkbox_1ijt0_51{position:absolute;right:.18667rem;top:.18667rem}._subjects_1ijt0_1 ._subject-list_1ijt0_26 ._name_1ijt0_56{position:absolute;bottom:.18667rem;left:.18667rem;font-size:.42667rem;font-weight:500;color:#fff;line-height:.58667rem}._subjects_1ijt0_1 ._subject-list_1ijt0_26 .van-checkbox__icon,._subjects_1ijt0_1 ._subject-list_1ijt0_26 .van-radio__icon{height:.58667rem}._subjects_1ijt0_1 ._subject-list_1ijt0_26 .van-checkbox__icon .van-icon,._subjects_1ijt0_1 ._subject-list_1ijt0_26 .van-radio__icon .van-icon{border:0}._subjects_1ijt0_1 ._subject-list_1ijt0_26 .van-checkbox__icon--checked .van-icon,._subjects_1ijt0_1 ._subject-list_1ijt0_26 .van-radio__icon--checked .van-icon{background:transparent;border:transparent}:root{--van-image-preview-index-text-color: var(--van-white);--van-image-preview-index-font-size: var(--van-font-size-md);--van-image-preview-index-line-height: var(--van-line-height-md);--van-image-preview-index-text-shadow: 0 .02667rem .02667rem var(--van-gray-8);--van-image-preview-overlay-background-color: rgba(0, 0, 0, .9);--van-image-preview-close-icon-size: .58667rem;--van-image-preview-close-icon-color: var(--van-gray-5);--van-image-preview-close-icon-margin: var(--van-padding-md);--van-image-preview-close-icon-z-index: 1}.van-image-preview{position:fixed;top:0;left:0;width:100%;height:100%;background-color:transparent;transform:none}.van-image-preview__swipe{height:100%}.van-image-preview__swipe-item{display:flex;align-items:center;justify-content:center;overflow:hidden}.van-image-preview__cover{position:absolute;top:0;left:0}.van-image-preview__image{width:100%;transition-property:transform}.van-image-preview__image--vertical{width:auto;height:100%}.van-image-preview__image img{-webkit-user-drag:none}.van-image-preview__image .van-image__error{top:30%;height:40%}.van-image-preview__image .van-image__error-icon{font-size:.96rem}.van-image-preview__image .van-image__loading{background-color:transparent}.van-image-preview__index{position:absolute;top:var(--van-padding-md);left:50%;color:var(--van-image-preview-index-text-color);font-size:var(--van-image-preview-index-font-size);line-height:var(--van-image-preview-index-line-height);text-shadow:var(--van-image-preview-index-text-shadow);transform:translate(-50%)}.van-image-preview__overlay{background:var(--van-image-preview-overlay-background-color)}.van-image-preview__close-icon{position:absolute;z-index:var(--van-image-preview-close-icon-z-index);color:var(--van-image-preview-close-icon-color);font-size:var(--van-image-preview-close-icon-size)}.van-image-preview__close-icon--top-left{top:var(--van-image-preview-close-icon-margin);left:var(--van-image-preview-close-icon-margin)}.van-image-preview__close-icon--top-right{top:var(--van-image-preview-close-icon-margin);right:var(--van-image-preview-close-icon-margin)}.van-image-preview__close-icon--bottom-left{bottom:var(--van-image-preview-close-icon-margin);left:var(--van-image-preview-close-icon-margin)}.van-image-preview__close-icon--bottom-right{right:var(--van-image-preview-close-icon-margin);bottom:var(--van-image-preview-close-icon-margin)}:root{--van-uploader-size: 2.13333rem;--van-uploader-icon-size: .64rem;--van-uploader-icon-color: var(--van-gray-4);--van-uploader-text-color: var(--van-text-color-2);--van-uploader-text-font-size: var(--van-font-size-sm);--van-uploader-upload-background-color: var(--van-gray-1);--van-uploader-upload-active-color: var(--van-active-color);--van-uploader-delete-color: var(--van-white);--van-uploader-delete-icon-size: .37333rem;--van-uploader-delete-background-color: rgba(0, 0, 0, .7);--van-uploader-file-background-color: var(--van-background-color);--van-uploader-file-icon-size: .53333rem;--van-uploader-file-icon-color: var(--van-gray-7);--van-uploader-file-name-padding: 0 var(--van-padding-base);--van-uploader-file-name-margin-top: var(--van-padding-xs);--van-uploader-file-name-font-size: var(--van-font-size-sm);--van-uploader-file-name-text-color: var(--van-gray-7);--van-uploader-mask-text-color: var(--van-white);--van-uploader-mask-background-color: rgba(50, 50, 51, .88);--van-uploader-mask-icon-size: .58667rem;--van-uploader-mask-message-font-size: var(--van-font-size-sm);--van-uploader-mask-message-line-height: var(--van-line-height-xs);--van-uploader-loading-icon-size: .58667rem;--van-uploader-loading-icon-color: var(--van-white);--van-uploader-disabled-opacity: var(--van-disabled-opacity)}.van-uploader{position:relative;display:inline-block}.van-uploader__wrapper{display:flex;flex-wrap:wrap}.van-uploader__wrapper--disabled{opacity:var(--van-uploader-disabled-opacity)}.van-uploader__input{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;cursor:pointer;opacity:0}.van-uploader__input-wrapper{position:relative}.van-uploader__input:disabled{cursor:not-allowed}.van-uploader__upload{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;box-sizing:border-box;width:var(--van-uploader-size);height:var(--van-uploader-size);margin:0 var(--van-padding-xs) var(--van-padding-xs) 0;background:var(--van-uploader-upload-background-color)}.van-uploader__upload:active{background-color:var(--van-uploader-upload-active-color)}.van-uploader__upload--readonly:active{background-color:var(--van-uploader-upload-background-color)}.van-uploader__upload-icon{color:var(--van-uploader-icon-color);font-size:var(--van-uploader-icon-size)}.van-uploader__upload-text{margin-top:var(--van-padding-xs);color:var(--van-uploader-text-color);font-size:var(--van-uploader-text-font-size)}.van-uploader__preview{position:relative;margin:0 var(--van-padding-xs) var(--van-padding-xs) 0;cursor:pointer}.van-uploader__preview-image{display:block;width:var(--van-uploader-size);height:var(--van-uploader-size);overflow:hidden}.van-uploader__preview-delete{position:absolute;top:0;right:0;width:var(--van-uploader-delete-icon-size);height:var(--van-uploader-delete-icon-size);background:var(--van-uploader-delete-background-color);border-radius:0 0 0 .32rem}.van-uploader__preview-delete-icon{position:absolute;top:0;right:0;color:var(--van-uploader-delete-color);font-size:var(--van-uploader-delete-icon-size);transform:scale(.7) translate(10%,-10%)}.van-uploader__preview-cover{position:absolute;top:0;right:0;bottom:0;left:0}.van-uploader__mask{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;flex-direction:column;align-items:center;justify-content:center;color:var(--van-uploader-mask-text-color);background:var(--van-uploader-mask-background-color)}.van-uploader__mask-icon{font-size:var(--van-uploader-mask-icon-size)}.van-uploader__mask-message{margin-top:.16rem;padding:0 var(--van-padding-base);font-size:var(--van-uploader-mask-message-font-size);line-height:var(--van-uploader-mask-message-line-height)}.van-uploader__loading{width:var(--van-uploader-loading-icon-size);height:var(--van-uploader-loading-icon-size);color:var(--van-uploader-loading-icon-color)}.van-uploader__file{display:flex;flex-direction:column;align-items:center;justify-content:center;width:var(--van-uploader-size);height:var(--van-uploader-size);background:var(--van-uploader-file-background-color)}.van-uploader__file-icon{color:var(--van-uploader-file-icon-color);font-size:var(--van-uploader-file-icon-size)}.van-uploader__file-name{box-sizing:border-box;width:100%;margin-top:var(--van-uploader-file-name-margin-top);padding:var(--van-uploader-file-name-padding);color:var(--van-uploader-file-name-text-color);font-size:var(--van-uploader-file-name-font-size);text-align:center}._uploader-section_jyku5_1{margin:.26667rem 0;height:3.86667rem;border:.02667rem dashed #ccc;border-radius:.26667rem;box-sizing:border-box;position:relative}._uploader-section_jyku5_1 ._img-close_jyku5_9{position:absolute;top:.21333rem;right:.26667rem;z-index:99;font-size:.42667rem;background-color:#333;color:#fff;width:.58667rem;height:.58667rem;display:flex;justify-content:center;align-items:center;border-radius:50%}._uploader-section_jyku5_1 ._col-uploader_jyku5_24,._uploader-section_jyku5_1 .van-uploader{width:100%;height:100%;align-items:center;display:flex;justify-content:center}._uploader-section_jyku5_1 .van-uploader__wrapper,._uploader-section_jyku5_1 .van-uploader__input-wrapper{display:flex;align-items:center;justify-content:center;width:inherit;height:inherit}._uploader-section_jyku5_1 ._uploader_jyku5_1{display:flex;align-items:center;justify-content:center;flex-direction:column}._uploader-section_jyku5_1 ._uploader_jyku5_1 ._uploaderText_jyku5_52{font-size:.37333rem;color:#999;margin-top:.21333rem}._uploader-section_jyku5_1 ._uploadImg_jyku5_57{width:100%;height:100%;overflow:hidden}.vue-cropper[data-v-be5e5ddc]{position:relative;width:100%;height:100%;box-sizing:border-box;user-select:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;direction:ltr;touch-action:none;text-align:left;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC)}.cropper-box[data-v-be5e5ddc],.cropper-box-canvas[data-v-be5e5ddc],.cropper-drag-box[data-v-be5e5ddc],.cropper-crop-box[data-v-be5e5ddc],.cropper-face[data-v-be5e5ddc]{position:absolute;top:0;right:0;bottom:0;left:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.cropper-box-canvas img[data-v-be5e5ddc]{position:relative;text-align:left;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transform:none;max-width:none;max-height:none}.cropper-box[data-v-be5e5ddc]{overflow:hidden}.cropper-move[data-v-be5e5ddc]{cursor:move}.cropper-crop[data-v-be5e5ddc]{cursor:crosshair}.cropper-modal[data-v-be5e5ddc]{background:rgba(0,0,0,.5)}.cropper-view-box[data-v-be5e5ddc]{display:block;overflow:hidden;width:100%;height:100%;outline:.02667rem solid #39f;outline-color:rgba(51,153,255,.75);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.cropper-view-box img[data-v-be5e5ddc]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;text-align:left;max-width:none;max-height:none}.cropper-face[data-v-be5e5ddc]{top:0;left:0;background-color:#fff;opacity:.1}.crop-info[data-v-be5e5ddc]{position:absolute;left:0;min-width:1.73333rem;text-align:center;color:#fff;line-height:.53333rem;background-color:rgba(0,0,0,.8);font-size:.32rem}.crop-line[data-v-be5e5ddc]{position:absolute;display:block;width:100%;height:100%;opacity:.1}.line-w[data-v-be5e5ddc]{top:-.08rem;left:0;height:.13333rem;cursor:n-resize}.line-a[data-v-be5e5ddc]{top:0;left:-.08rem;width:.13333rem;cursor:w-resize}.line-s[data-v-be5e5ddc]{bottom:-.08rem;left:0;height:.13333rem;cursor:s-resize}.line-d[data-v-be5e5ddc]{top:0;right:-.08rem;width:.13333rem;cursor:e-resize}.crop-point[data-v-be5e5ddc]{position:absolute;width:.21333rem;height:.21333rem;opacity:.75;background-color:#39f;border-radius:100%}.point1[data-v-be5e5ddc]{top:-.10667rem;left:-.10667rem;cursor:nw-resize}.point2[data-v-be5e5ddc]{top:-.13333rem;left:50%;margin-left:-.08rem;cursor:n-resize}.point3[data-v-be5e5ddc]{top:-.10667rem;right:-.10667rem;cursor:ne-resize}.point4[data-v-be5e5ddc]{top:50%;left:-.10667rem;margin-top:-.08rem;cursor:w-resize}.point5[data-v-be5e5ddc]{top:50%;right:-.10667rem;margin-top:-.08rem;cursor:e-resize}.point6[data-v-be5e5ddc]{bottom:-.13333rem;left:-.10667rem;cursor:sw-resize}.point7[data-v-be5e5ddc]{bottom:-.13333rem;left:50%;margin-left:-.08rem;cursor:s-resize}.point8[data-v-be5e5ddc]{bottom:-.13333rem;right:-.10667rem;cursor:se-resize}@media screen and (max-width: 500px){.crop-point[data-v-be5e5ddc]{position:absolute;width:.53333rem;height:.53333rem;opacity:.45;background-color:#39f;border-radius:100%}.point1[data-v-be5e5ddc]{top:-.26667rem;left:-.26667rem}.point2[data-v-be5e5ddc],.point4[data-v-be5e5ddc],.point5[data-v-be5e5ddc],.point7[data-v-be5e5ddc]{display:none}.point3[data-v-be5e5ddc]{top:-.26667rem;right:-.26667rem}.point4[data-v-be5e5ddc]{top:0;left:0}.point6[data-v-be5e5ddc]{bottom:-.26667rem;left:-.26667rem}.point8[data-v-be5e5ddc]{bottom:-.26667rem;right:-.26667rem}}._upbtn_4fh9z_1{width:100%;height:100%}._uploadWarper_4fh9z_5{position:absolute;left:0;right:0;top:0;bottom:0}._bg_4fh9z_12{position:fixed;top:0;height:100vh;width:100%;background-color:#000;left:0;z-index:521}._btn_4fh9z_21{height:8vw;padding:0;line-height:8vw;font-size:4vw;padding:0 3.5vw;border-radius:1.333vw;text-align:center}._btn1_4fh9z_33{height:8vw;line-height:8vw;font-size:4vw;padding:0 4vw;border-radius:1.333vw;text-align:center;background-color:#5b6e96}._img_4fh9z_44{height:8vw;width:8vw;position:absolute;left:calc(50% - 4vw);background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAZrElEQVR4Xu1dCbBtRXVdC4SAoggOcR6CCkbjbOKAE2iBqAE0kRLFGUVxiCZGVAzOChogDpiIEAaljEMciBGHoFFU1ERRSo0WGnHAKaJoYrRiuVLr/75Vl/f/e+/0cPoMt3fVrff+f717WLvX7dN9du9NNGkINATWRYANm4ZAQ2B9BBpB2uxoCGyAQCNImx4NgUaQNgcaAmkItBUkDbemtSIINIKsiKHbMNMQaARJw61prQgCjSArYug2zDQEGkHScGtaK4JAI8iKGLoNMw2BRpA03JrWiiDQCFLR0JJ+B8A1wmf3pd8X/+eflivW+5D035pUQqARpDDQkvYEcEsAt1j6ufjdfyshlwJY+/n24v9I/qpEI60OoBEkYxZI2gnAvQAcAOA+gRClSJDRM3wBwPkAPgbgMyR/nFPZKus2gkRaX9KdAewLYD8ABwLYObKKIYp/CsAnTZZAmO8O0YkpttkIsonVJHmv8CAA+wdi3GqKhl7T53MBbPmQ/MEMxtPbEBpBtgOtpF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vzlZamoAttLjcwBqk2OQLFClB7Nc3ywJsrSaOPWCiZKSn6RP3OdSt2NdmRjnz2VAa8cxa4KE1cRJfEySlExXc7V77rgcIfFNQwdUyB1EF/3ZE2RpNfF99yeET0r23S54zr3MyhBjYciVIcgSUZyi2kTxuxOvLk02R2DliLGyBFkiije5JonJMsSJ1+bTcvgSK0uMlSfIElH83sAkOTycDA0/LYfvwcoToxFkzSSU5ONVX856UPjcePh5WrUHXwXgdxiOnD+rdxk5KK7cHqQLWJJ2WSKKCXPdLnoTLOMAewtSzPaoNscujSCboCdp90AWu7DsC+BWOYCPQNePTwtSOId9kw0QaASJnB6S7OdkouwXPGN3jqyidvFLAHiluDg8Pl1YuwNTbq8RJMN6knYKV4DtOu6Ad3b92DOjylzVbwOwJ61jgZkQF5NcyduRuUC2TXopBLfd7JsgJsrCV8o/F7+XII/9tRYfxyH+t/D5Isnv9TSsla22rSAVTS/Jb/AdJM0f720Wvy//1BIBlsnwU5L+d5OKCDSCVAS7NTU9BBpBpmez1uOKCDSCVAS7NTU9BBpBpmez1uOKCDSCVAS7NTU9BBpBpmez1uOKCDSCVAS7NTU9BBpBpmez1uOKCDSCVAS7NTU9BBpBpmez1uOKCDSCVAS7NTU9BBpBpmez1uOKCPw/JjUpXx7VFvoAAAAASUVORK5CYII=);background-size:100% 100%}._btndiv_4fh9z_53{height:13.333vw;color:#fff;justify-content:space-between;display:flex;align-items:center;padding:0 4vw;line-height:13.333vw;font-size:4vw;position:relative}._wrapper_4fh9z_64{height:calc(100vh - 21.333vw);padding:4vw}._wrapper_4fh9z_64 .crop-point{opacity:0;z-index:523}._wrapper_4fh9z_64 .cropper-view-box{outline:.02667rem solid #fff;border:.02667rem solid #fff}._wrapper_4fh9z_64 .vue-cropper{background-color:#000;background-image:none}\n";document.head.appendChild(__vite_style__);System.register(['./vendor-legacy.7b5913a8.js','./index-legacy.637f3556.js','./index-legacy.f25f109a3.js','./index-legacy.8d0fc168.js','./index-legacy.637f35562.js','./main-legacy.2ff65a75.js'],function(exports){'use strict';var defineComponent,createVNode,CheckboxGroup,Fragment,Image$1,Loading,Checkbox,Icon,isVNode,RadioGroup,Radio,Button,createTextVNode,Popup,createElementBlock,withDirectives,vShow,createBaseVNode,normalizeStyle,createCommentVNode,normalizeClass,toDisplayString,openBlock,Toast,useCustomFieldValue,Uploader,ColResult,request;return{setters:[function(module){defineComponent=module.d;createVNode=module.b;CheckboxGroup=module.v;Fragment=module.F;Image$1=module.m;Loading=module.L;Checkbox=module.u;Icon=module.I;isVNode=module.w;RadioGroup=module.x;Radio=module.y;Button=module.B;createTextVNode=module.f;Popup=module.P;createElementBlock=module.z;withDirectives=module.A;vShow=module.G;createBaseVNode=module.H;normalizeStyle=module.J;createCommentVNode=module.K;normalizeClass=module.M;toDisplayString=module.N;openBlock=module.o;Toast=module.T;useCustomFieldValue=module.O;Uploader=module.U;},function(){},function(){},function(module){ColResult=module.C;},function(){},function(module){request=module.r;}],execute:function execute(){var _Object$freeze,_Object$freeze2;var checkBoxActive="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAAAXNSR0IArs4c6QAAAilJREFUSEu1lc9rE1EQx7+zMTSFFCUWom1sF5Q0mDTqKbb2kpsX8aTUS29tse1FelLRg4IHL0XBv8ESD6JevAViNNZfYMRmRaE/QKFNqG02JJtsuk/eKwlJzOaHNnt8b+Yzs/OdmUcw+bxvQg4wY5wk6TyAUwQ4uSkDNgB8ZobxEiQtfh29vFUPQbWHcjhs6+lO3WAGu0YEu1lgEYQhQxItqLnee6vBoFZpWwX2xB7LVhx4BjB/I+DfdxTXUbyojFxZLd2VwXtQSxRAf3vQsvVPHbtjJbgAi9+3pZbaz7Q2BYqrWm+Al0WAh98+uQPGbv1jptVuRHe/nL10m7j6BKw1E6rVoFxQBgyS9/XijCRJj1p1rLQ7bT+MzUIOvwrZKnfDMGbJFws9J+BCu+Bx53Fcl89gaWcTU0qkyp0BLzh4jYCBdsATR9yYH/RDM3Yx9y2K9+lkLXidhmMh3thdteD5AT9cNjtu/niHrFEsX0/2eTB3zCfOZpUoPqmpejnlTcEP3KMIOvrxMZ3EjBJFjoNcXky7TkItFnBVeYV4pu4080B501J0SxY8HDqHwEEnPqSTWM78xkSfG9t6HtOJCBLZbdPqMWC9oXhdZMHC0AjGDh0VkC1dw+RyBN9zOw0lEeI1azcrSbh/IgCf3YGpRAQrmtpUZ9FurQ4IH1HWFLm38cSAdGykO7qEONwTeypboe/v2iyVriOLvgSXV8K2no19fpoqRf/fx/QP4JsHStReaXAAAAAASUVORK5CYII=";var __glob_8_9=/*#__PURE__*/Object.freeze((_Object$freeze={__proto__:null},_defineProperty(_Object$freeze,Symbol.toStringTag,'Module'),_defineProperty(_Object$freeze,'default',checkBoxActive),_Object$freeze));exports('_',__glob_8_9);var checkBoxDefault="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAAAXNSR0IArs4c6QAAAS1JREFUSEu11aFKREEUxvHfFIPJYrEJCoJFBINr0qTBZvEJBEG7wWTwAQTBJ7DYDJo0qUEQiyAoCAaLxWSwjBy5V9Z1l1127504853/zJw555ukw8g5j2IdK5jEUCH9whPOcJxSem+HSK2TOedh7BbQezzgo0U3gmnMBBx7KaXPZs0fcM55Aid4wQ1ypxsV8xE/j3GspZSeS/0vuICe4xRvXYCty2NYxXIJ/wEX17/GZR/QcpOAL6IRaSnB+5hCwAcZDTymlHZS8fq3OOwhp902jYNuYi7A21jCVbeoHtcXcBHgqMe7NiXVI+efLEpxNsBRIkf9UjrEbQT4FQcVg7dqBdeWitoer7ZyC3usvkEKr6i+pWs1oQIeXlytbZbNUYvRN8Gr/5qa23rQz/Qb9Z6P6bQiKtgAAAAASUVORK5CYII=";var __glob_8_10=/*#__PURE__*/Object.freeze((_Object$freeze2={__proto__:null},_defineProperty(_Object$freeze2,Symbol.toStringTag,'Module'),_defineProperty(_Object$freeze2,'default',checkBoxDefault),_Object$freeze2));exports('a',__glob_8_10);var styles$3={"col-field-group":"_col-field-group_1vk7j_1"};var ColFieldGroup=exports('C',defineComponent({name:"ColFieldGroup",render:function render(){return createVNode("div",{"class":styles$3['col-field-group']},[this.$slots.default&&this.$slots.default()]);}}));var index$4='';var index$3='';var subjects="_subjects_1ijt0_1";var title="_title_1ijt0_4";var topBg="_topBg_1ijt0_43";var checkbox="_checkbox_1ijt0_51";var name="_name_1ijt0_56";var styles$2={subjects:subjects,title:title,"btn-group":"_btn-group_1ijt0_19","subject-list":"_subject-list_1ijt0_26","subject-item":"_subject-item_1ijt0_31",topBg:topBg,checkbox:checkbox,name:name};function _isSlot(s){return typeof s==='function'||Object.prototype.toString.call(s)==='[object Object]'&&!isVNode(s);}var SubjectModel=exports('S',defineComponent({name:"SubjectList",props:{onChoice:{type:Function,default:function _default(item){}},choiceSubjectIds:{type:Array,default:[]},subjectList:{type:Array,default:[]},max:{// 最多可选数量
- type:Number,default:5},selectType:{// 选择类型,Radio:单选,Checkbox:多选
- type:String,default:'Checkbox'}},data:function data(){return{checkBox:[],checkboxRefs:[],radio:null// 单选
- };},mounted:function mounted(){var _this=this;return _asyncToGenerator(/*#__PURE__*/regeneratorRuntime.mark(function _callee(){return regeneratorRuntime.wrap(function _callee$(_context){while(1){switch(_context.prev=_context.next){case 0:_this.checkBox=_this.choiceSubjectIds;case 1:case"end":return _context.stop();}}},_callee);}))();},methods:{onSelect:function onSelect(id){if(this.selectType==='Checkbox'){this.checkboxRefs[id].toggle();}else if(this.selectType==='Radio'){this.radio=id;}}},render:function render(){var _this2=this;var _slot,_slot2;return createVNode("div",{"class":styles$2.subjects},[this.subjectList.length?this.selectType==='Checkbox'?createVNode(CheckboxGroup,{"modelValue":this.checkBox,"onUpdate:modelValue":function onUpdateModelValue($event){return _this2.checkBox=$event;},"max":this.max},_isSlot(_slot=this.subjectList.map(function(item){return item.subjects&&item.subjects.length>0?createVNode(Fragment,null,[createVNode("div",{"class":styles$2.title},[item.name]),createVNode("div",{"class":styles$2['subject-list']},[item.subjects&&item.subjects.map(function(sub){return createVNode("div",{"class":styles$2['subject-item'],"onClick":function onClick(){return _this2.onSelect(sub.id);}},[createVNode(Image$1,{"src":sub.img,"width":"100%","height":"100%","fit":"cover"},{loading:function loading(){return createVNode(Loading,{"type":"spinner","size":20},null);}}),createVNode("div",{"class":styles$2.topBg},[createVNode(Checkbox,{"name":sub.id,"class":styles$2.checkbox,"ref":function ref(el){return _this2.checkboxRefs[sub.id]=el;}},{icon:function icon(props){return createVNode(Icon,{"name":props.checked?checkBoxActive:checkBoxDefault,"size":"22"},null);}}),createVNode("p",{"class":styles$2.name},[sub.name])])]);})])]):null;}))?_slot:{default:function _default(){return[_slot];}}):createVNode(RadioGroup,{"modelValue":this.radio,"onUpdate:modelValue":function onUpdateModelValue($event){return _this2.radio=$event;}},_isSlot(_slot2=this.subjectList.map(function(item){return item.subjects&&item.subjects.length>0?createVNode(Fragment,null,[createVNode("div",{"class":styles$2.title},[item.name]),createVNode("div",{"class":styles$2['subject-list']},[item.subjects&&item.subjects.map(function(sub){return createVNode("div",{"class":styles$2['subject-item'],"onClick":function onClick(){return _this2.onSelect(sub.id);}},[createVNode(Image$1,{"src":sub.img,"width":"100%","height":"100%","fit":"cover"},{loading:function loading(){return createVNode(Loading,{"type":"spinner","size":20},null);}}),createVNode("div",{"class":styles$2.topBg},[createVNode(Radio,{"name":sub.id,"class":styles$2.checkbox},{icon:function icon(props){return createVNode(Icon,{"name":props.checked?checkBoxActive:checkBoxDefault,"size":"22"},null);}}),createVNode("p",{"class":styles$2.name},[sub.name])])]);})])]):null;}))?_slot2:{default:function _default(){return[_slot2];}}):createVNode(ColResult,{"tips":"暂无声部数据","btnStatus":false},null),createVNode("div",{"class":styles$2["btn-group"]},[createVNode(Button,{"round":true,"block":true,"type":"primary","onClick":function onClick(){return _this2.onChoice(_this2.selectType==='Checkbox'?_this2.checkBox:_this2.radio);}},{default:function _default(){return[createTextVNode("\u786E\u5B9A")];}})])]);}}));var queryString={};var strictUriEncode=function strictUriEncode(str){return encodeURIComponent(str).replace(/[!'()*]/g,function(x){return"%".concat(x.charCodeAt(0).toString(16).toUpperCase());});};var token='%[a-f0-9]{2}';var singleMatcher=new RegExp(token,'gi');var multiMatcher=new RegExp('('+token+')+','gi');function decodeComponents(components,split){try{// Try to decode the entire string first
- return decodeURIComponent(components.join(''));}catch(err){// Do nothing
- }if(components.length===1){return components;}split=split||1;// Split the array in 2 parts
- var left=components.slice(0,split);var right=components.slice(split);return Array.prototype.concat.call([],decodeComponents(left),decodeComponents(right));}function decode(input){try{return decodeURIComponent(input);}catch(err){var tokens=input.match(singleMatcher);for(var i=1;i<tokens.length;i++){input=decodeComponents(tokens,i).join('');tokens=input.match(singleMatcher);}return input;}}function customDecodeURIComponent(input){// Keep track of all the replacements and prefill the map with the `BOM`
- var replaceMap={'%FE%FF':"\uFFFD\uFFFD",'%FF%FE':"\uFFFD\uFFFD"};var match=multiMatcher.exec(input);while(match){try{// Decode as big chunks as possible
- replaceMap[match[0]]=decodeURIComponent(match[0]);}catch(err){var result=decode(match[0]);if(result!==match[0]){replaceMap[match[0]]=result;}}match=multiMatcher.exec(input);}// Add `%C2` at the end of the map to make sure it does not replace the combinator before everything else
- replaceMap['%C2']="\uFFFD";var entries=Object.keys(replaceMap);for(var i=0;i<entries.length;i++){// Replace all decoded components
- var key=entries[i];input=input.replace(new RegExp(key,'g'),replaceMap[key]);}return input;}var decodeUriComponent=function decodeUriComponent(encodedURI){if(typeof encodedURI!=='string'){throw new TypeError('Expected `encodedURI` to be of type `string`, got `'+_typeof(encodedURI)+'`');}try{encodedURI=encodedURI.replace(/\+/g,' ');// Try the built in decoder first
- return decodeURIComponent(encodedURI);}catch(err){// Fallback to a more advanced decoder
- return customDecodeURIComponent(encodedURI);}};var splitOnFirst=function splitOnFirst(string,separator){if(!(typeof string==='string'&&typeof separator==='string')){throw new TypeError('Expected the arguments to be of type `string`');}if(separator===''){return[string];}var separatorIndex=string.indexOf(separator);if(separatorIndex===-1){return[string];}return[string.slice(0,separatorIndex),string.slice(separatorIndex+separator.length)];};var filterObj=function filterObj(obj,predicate){var ret={};var keys=Object.keys(obj);var isArr=Array.isArray(predicate);for(var i=0;i<keys.length;i++){var key=keys[i];var val=obj[key];if(isArr?predicate.indexOf(key)!==-1:predicate(key,val,obj)){ret[key]=val;}}return ret;};(function(exports){var strictUriEncode$1=strictUriEncode;var decodeComponent=decodeUriComponent;var splitOnFirst$1=splitOnFirst;var filterObject=filterObj;var isNullOrUndefined=function isNullOrUndefined(value){return value===null||value===undefined;};var encodeFragmentIdentifier=Symbol('encodeFragmentIdentifier');function encoderForArrayFormat(options){switch(options.arrayFormat){case'index':return function(key){return function(result,value){var index=result.length;if(value===undefined||options.skipNull&&value===null||options.skipEmptyString&&value===''){return result;}if(value===null){return[].concat(_toConsumableArray(result),[[encode(key,options),'[',index,']'].join('')]);}return[].concat(_toConsumableArray(result),[[encode(key,options),'[',encode(index,options),']=',encode(value,options)].join('')]);};};case'bracket':return function(key){return function(result,value){if(value===undefined||options.skipNull&&value===null||options.skipEmptyString&&value===''){return result;}if(value===null){return[].concat(_toConsumableArray(result),[[encode(key,options),'[]'].join('')]);}return[].concat(_toConsumableArray(result),[[encode(key,options),'[]=',encode(value,options)].join('')]);};};case'colon-list-separator':return function(key){return function(result,value){if(value===undefined||options.skipNull&&value===null||options.skipEmptyString&&value===''){return result;}if(value===null){return[].concat(_toConsumableArray(result),[[encode(key,options),':list='].join('')]);}return[].concat(_toConsumableArray(result),[[encode(key,options),':list=',encode(value,options)].join('')]);};};case'comma':case'separator':case'bracket-separator':{var keyValueSep=options.arrayFormat==='bracket-separator'?'[]=':'=';return function(key){return function(result,value){if(value===undefined||options.skipNull&&value===null||options.skipEmptyString&&value===''){return result;}// Translate null to an empty string so that it doesn't serialize as 'null'
- value=value===null?'':value;if(result.length===0){return[[encode(key,options),keyValueSep,encode(value,options)].join('')];}return[[result,encode(value,options)].join(options.arrayFormatSeparator)];};};}default:return function(key){return function(result,value){if(value===undefined||options.skipNull&&value===null||options.skipEmptyString&&value===''){return result;}if(value===null){return[].concat(_toConsumableArray(result),[encode(key,options)]);}return[].concat(_toConsumableArray(result),[[encode(key,options),'=',encode(value,options)].join('')]);};};}}function parserForArrayFormat(options){var result;switch(options.arrayFormat){case'index':return function(key,value,accumulator){result=/\[(\d*)\]$/.exec(key);key=key.replace(/\[\d*\]$/,'');if(!result){accumulator[key]=value;return;}if(accumulator[key]===undefined){accumulator[key]={};}accumulator[key][result[1]]=value;};case'bracket':return function(key,value,accumulator){result=/(\[\])$/.exec(key);key=key.replace(/\[\]$/,'');if(!result){accumulator[key]=value;return;}if(accumulator[key]===undefined){accumulator[key]=[value];return;}accumulator[key]=[].concat(accumulator[key],value);};case'colon-list-separator':return function(key,value,accumulator){result=/(:list)$/.exec(key);key=key.replace(/:list$/,'');if(!result){accumulator[key]=value;return;}if(accumulator[key]===undefined){accumulator[key]=[value];return;}accumulator[key]=[].concat(accumulator[key],value);};case'comma':case'separator':return function(key,value,accumulator){var isArray=typeof value==='string'&&value.includes(options.arrayFormatSeparator);var isEncodedArray=typeof value==='string'&&!isArray&&decode(value,options).includes(options.arrayFormatSeparator);value=isEncodedArray?decode(value,options):value;var newValue=isArray||isEncodedArray?value.split(options.arrayFormatSeparator).map(function(item){return decode(item,options);}):value===null?value:decode(value,options);accumulator[key]=newValue;};case'bracket-separator':return function(key,value,accumulator){var isArray=/(\[\])$/.test(key);key=key.replace(/\[\]$/,'');if(!isArray){accumulator[key]=value?decode(value,options):value;return;}var arrayValue=value===null?[]:value.split(options.arrayFormatSeparator).map(function(item){return decode(item,options);});if(accumulator[key]===undefined){accumulator[key]=arrayValue;return;}accumulator[key]=[].concat(accumulator[key],arrayValue);};default:return function(key,value,accumulator){if(accumulator[key]===undefined){accumulator[key]=value;return;}accumulator[key]=[].concat(accumulator[key],value);};}}function validateArrayFormatSeparator(value){if(typeof value!=='string'||value.length!==1){throw new TypeError('arrayFormatSeparator must be single character string');}}function encode(value,options){if(options.encode){return options.strict?strictUriEncode$1(value):encodeURIComponent(value);}return value;}function decode(value,options){if(options.decode){return decodeComponent(value);}return value;}function keysSorter(input){if(Array.isArray(input)){return input.sort();}if(_typeof(input)==='object'){return keysSorter(Object.keys(input)).sort(function(a,b){return Number(a)-Number(b);}).map(function(key){return input[key];});}return input;}function removeHash(input){var hashStart=input.indexOf('#');if(hashStart!==-1){input=input.slice(0,hashStart);}return input;}function getHash(url){var hash='';var hashStart=url.indexOf('#');if(hashStart!==-1){hash=url.slice(hashStart);}return hash;}function extract(input){input=removeHash(input);var queryStart=input.indexOf('?');if(queryStart===-1){return'';}return input.slice(queryStart+1);}function parseValue(value,options){if(options.parseNumbers&&!Number.isNaN(Number(value))&&typeof value==='string'&&value.trim()!==''){value=Number(value);}else if(options.parseBooleans&&value!==null&&(value.toLowerCase()==='true'||value.toLowerCase()==='false')){value=value.toLowerCase()==='true';}return value;}function parse(query,options){options=Object.assign({decode:true,sort:true,arrayFormat:'none',arrayFormatSeparator:',',parseNumbers:false,parseBooleans:false},options);validateArrayFormatSeparator(options.arrayFormatSeparator);var formatter=parserForArrayFormat(options);// Create an object with no prototype
- var ret=Object.create(null);if(typeof query!=='string'){return ret;}query=query.trim().replace(/^[?#&]/,'');if(!query){return ret;}var _iterator=_createForOfIteratorHelper(query.split('&')),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var param=_step.value;if(param===''){continue;}var _splitOnFirst$=splitOnFirst$1(options.decode?param.replace(/\+/g,' '):param,'='),_splitOnFirst$2=_slicedToArray(_splitOnFirst$,2),_key=_splitOnFirst$2[0],_value=_splitOnFirst$2[1];// Missing `=` should be `null`:
- // http://w3.org/TR/2012/WD-url-20120524/#collect-url-parameters
- _value=_value===undefined?null:['comma','separator','bracket-separator'].includes(options.arrayFormat)?_value:decode(_value,options);formatter(decode(_key,options),_value,ret);}}catch(err){_iterator.e(err);}finally{_iterator.f();}for(var _i=0,_Object$keys=Object.keys(ret);_i<_Object$keys.length;_i++){var key=_Object$keys[_i];var value=ret[key];if(_typeof(value)==='object'&&value!==null){for(var _i2=0,_Object$keys2=Object.keys(value);_i2<_Object$keys2.length;_i2++){var k=_Object$keys2[_i2];value[k]=parseValue(value[k],options);}}else{ret[key]=parseValue(value,options);}}if(options.sort===false){return ret;}return(options.sort===true?Object.keys(ret).sort():Object.keys(ret).sort(options.sort)).reduce(function(result,key){var value=ret[key];if(Boolean(value)&&_typeof(value)==='object'&&!Array.isArray(value)){// Sort object keys, not values
- result[key]=keysSorter(value);}else{result[key]=value;}return result;},Object.create(null));}exports.extract=extract;exports.parse=parse;exports.stringify=function(object,options){if(!object){return'';}options=Object.assign({encode:true,strict:true,arrayFormat:'none',arrayFormatSeparator:','},options);validateArrayFormatSeparator(options.arrayFormatSeparator);var shouldFilter=function shouldFilter(key){return options.skipNull&&isNullOrUndefined(object[key])||options.skipEmptyString&&object[key]==='';};var formatter=encoderForArrayFormat(options);var objectCopy={};for(var _i3=0,_Object$keys3=Object.keys(object);_i3<_Object$keys3.length;_i3++){var key=_Object$keys3[_i3];if(!shouldFilter(key)){objectCopy[key]=object[key];}}var keys=Object.keys(objectCopy);if(options.sort!==false){keys.sort(options.sort);}return keys.map(function(key){var value=object[key];if(value===undefined){return'';}if(value===null){return encode(key,options);}if(Array.isArray(value)){if(value.length===0&&options.arrayFormat==='bracket-separator'){return encode(key,options)+'[]';}return value.reduce(formatter(key),[]).join('&');}return encode(key,options)+'='+encode(value,options);}).filter(function(x){return x.length>0;}).join('&');};exports.parseUrl=function(url,options){options=Object.assign({decode:true},options);var _splitOnFirst$3=splitOnFirst$1(url,'#'),_splitOnFirst$4=_slicedToArray(_splitOnFirst$3,2),url_=_splitOnFirst$4[0],hash=_splitOnFirst$4[1];return Object.assign({url:url_.split('?')[0]||'',query:parse(extract(url),options)},options&&options.parseFragmentIdentifier&&hash?{fragmentIdentifier:decode(hash,options)}:{});};exports.stringifyUrl=function(object,options){options=Object.assign(_defineProperty({encode:true,strict:true},encodeFragmentIdentifier,true),options);var url=removeHash(object.url).split('?')[0]||'';var queryFromUrl=exports.extract(object.url);var parsedQueryFromUrl=exports.parse(queryFromUrl,{sort:false});var query=Object.assign(parsedQueryFromUrl,object.query);var queryString=exports.stringify(query,options);if(queryString){queryString="?".concat(queryString);}var hash=getHash(object.url);if(object.fragmentIdentifier){hash="#".concat(options[encodeFragmentIdentifier]?encode(object.fragmentIdentifier,options):object.fragmentIdentifier);}return"".concat(url).concat(queryString).concat(hash);};exports.pick=function(input,filter,options){options=Object.assign(_defineProperty({parseFragmentIdentifier:true},encodeFragmentIdentifier,false),options);var _exports$parseUrl=exports.parseUrl(input,options),url=_exports$parseUrl.url,query=_exports$parseUrl.query,fragmentIdentifier=_exports$parseUrl.fragmentIdentifier;return exports.stringifyUrl({url:url,query:filterObject(query,filter),fragmentIdentifier:fragmentIdentifier},options);};exports.exclude=function(input,filter,options){var exclusionFilter=Array.isArray(filter)?function(key){return!filter.includes(key);}:function(key,value){return!filter(key,value);};return exports.pick(input,exclusionFilter,options);};})(queryString);var qs=queryString;var ColPopup=exports('b',defineComponent({name:'col-popup',props:{modelValue:{type:Boolean,default:false}},data:function data(){return{popupShow:false};},watch:{modelValue:function modelValue(val){this.hashState();}},mounted:function mounted(){window.addEventListener('hashchange',this.onHash,false);},unmounted:function unmounted(){window.removeEventListener('hashchange',this.onHash,false);},methods:{onHash:function onHash(){this.$emit("update:modelValue",false);},onPopupClose:function onPopupClose(val){this.$emit("update:modelValue",val);this.hashState();},hashState:function hashState(){// 打开弹窗
- if(this.modelValue){var splitUrl=window.location.hash.slice(1).split('?');var query=qs.parse(splitUrl[1]);var times=0;for(var key in query){times++;}var origin=window.location.href;var url=times>0?'&cPop='+ +new Date():'?cPop='+ +new Date();history.pushState("","","".concat(origin).concat(url));}else{var _splitUrl=window.location.hash.slice(1).split('?');var _query=qs.parse(_splitUrl[1]);if(_query.cPop){window.history.go(-1);}}if(this.$refs.protocolPopup){this.$refs.protocolPopup.scrollTop=0;}}},render:function render(){var _this3=this;return createVNode(Popup,{"ref":"protocolPopup","show":this.modelValue,"transitionAppear":true,"position":"bottom","style":{height:'100%'}},{default:function _default(){return[_this3.$slots.default&&_this3.$slots.default()];}});}}));var index$2='';var index$1='';var uploader="_uploader_jyku5_1";var uploaderText="_uploaderText_jyku5_52";var uploadImg="_uploadImg_jyku5_57";var styles$1={"uploader-section":"_uploader-section_jyku5_1","img-close":"_img-close_jyku5_9","col-uploader":"_col-uploader_jyku5_24",uploader:uploader,uploaderText:uploaderText,uploadImg:uploadImg};var index='';var Exif={};Exif.getData=function(img){return new Promise(function(reslove,reject){var obj={};getImageData(img).then(function(data){obj.arrayBuffer=data;obj.orientation=getOrientation(data);reslove(obj);}).catch(function(error){reject(error);});});};function getImageData(img){var data=null;return new Promise(function(reslove,reject){if(img.src){if(/^data\:/i.test(img.src)){data=base64ToArrayBuffer(img.src);reslove(data);}else if(/^blob\:/i.test(img.src)){var fileReader=new FileReader();fileReader.onload=function(e){data=e.target.result;reslove(data);};objectURLToBlob(img.src,function(blob){fileReader.readAsArrayBuffer(blob);});}else{var http=new XMLHttpRequest();http.onload=function(){if(this.status==200||this.status===0){data=http.response;reslove(data);}else{throw"Could not load image";}http=null;};http.open("GET",img.src,true);http.responseType="arraybuffer";http.send(null);}}else{reject("img error");}});}function objectURLToBlob(url,callback){var http=new XMLHttpRequest();http.open("GET",url,true);http.responseType="blob";http.onload=function(e){if(this.status==200||this.status===0){callback(this.response);}};http.send();}function base64ToArrayBuffer(base64){base64=base64.replace(/^data\:([^\;]+)\;base64,/gmi,"");var binary=atob(base64);var len=binary.length;var buffer=new ArrayBuffer(len);var view=new Uint8Array(buffer);for(var i=0;i<len;i++){view[i]=binary.charCodeAt(i);}return buffer;}function getStringFromCharCode(dataView,start,length){var str="";var i;for(i=start,length+=start;i<length;i++){str+=String.fromCharCode(dataView.getUint8(i));}return str;}function getOrientation(arrayBuffer){var dataView=new DataView(arrayBuffer);var length=dataView.byteLength;var orientation;var exifIDCode;var tiffOffset;var firstIFDOffset;var littleEndian;var endianness;var app1Start;var ifdStart;var offset;var i;if(dataView.getUint8(0)===255&&dataView.getUint8(1)===216){offset=2;while(offset<length){if(dataView.getUint8(offset)===255&&dataView.getUint8(offset+1)===225){app1Start=offset;break;}offset++;}}if(app1Start){exifIDCode=app1Start+4;tiffOffset=app1Start+10;if(getStringFromCharCode(dataView,exifIDCode,4)==="Exif"){endianness=dataView.getUint16(tiffOffset);littleEndian=endianness===18761;if(littleEndian||endianness===19789){if(dataView.getUint16(tiffOffset+2,littleEndian)===42){firstIFDOffset=dataView.getUint32(tiffOffset+4,littleEndian);if(firstIFDOffset>=8){ifdStart=tiffOffset+firstIFDOffset;}}}}}if(ifdStart){length=dataView.getUint16(ifdStart,littleEndian);for(i=0;i<length;i++){offset=ifdStart+i*12+2;if(dataView.getUint16(offset,littleEndian)===274){offset+=8;orientation=dataView.getUint16(offset,littleEndian);break;}}}return orientation;}var _export_sfc=function _export_sfc(sfc,props){var target=sfc.__vccOpts||sfc;var _iterator2=_createForOfIteratorHelper(props),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var _step2$value=_slicedToArray(_step2.value,2),key=_step2$value[0],val=_step2$value[1];target[key]=val;}}catch(err){_iterator2.e(err);}finally{_iterator2.f();}return target;};var _sfc_main=defineComponent({data:function data(){return{w:0,h:0,scale:1,x:0,y:0,loading:true,trueWidth:0,trueHeight:0,move:true,moveX:0,moveY:0,crop:false,cropping:false,cropW:0,cropH:0,cropOldW:0,cropOldH:0,canChangeX:false,canChangeY:false,changeCropTypeX:1,changeCropTypeY:1,cropX:0,cropY:0,cropChangeX:0,cropChangeY:0,cropOffsertX:0,cropOffsertY:0,support:"",touches:[],touchNow:false,rotate:0,isIos:false,orientation:0,imgs:"",coe:0.2,scaling:false,scalingSet:"",coeStatus:"",isCanShow:true};},props:{img:{type:[String,Blob,null,File],default:""},outputSize:{type:Number,default:1},outputType:{type:String,default:"jpeg"},info:{type:Boolean,default:true},canScale:{type:Boolean,default:true},autoCrop:{type:Boolean,default:false},autoCropWidth:{type:[Number,String],default:0},autoCropHeight:{type:[Number,String],default:0},fixed:{type:Boolean,default:false},fixedNumber:{type:Array,default:function _default(){return[1,1];}},fixedBox:{type:Boolean,default:false},full:{type:Boolean,default:false},canMove:{type:Boolean,default:true},canMoveBox:{type:Boolean,default:true},original:{type:Boolean,default:false},centerBox:{type:Boolean,default:false},high:{type:Boolean,default:true},infoTrue:{type:Boolean,default:false},maxImgSize:{type:[Number,String],default:2e3},enlarge:{type:[Number,String],default:1},preW:{type:[Number,String],default:0},mode:{type:String,default:"contain"},limitMinSize:{type:[Number,Array,String],default:function _default(){return 10;}}},computed:{cropInfo:function cropInfo(){var obj={};obj.top=this.cropOffsertY>21?"-21px":"0px";obj.width=this.cropW>0?this.cropW:0;obj.height=this.cropH>0?this.cropH:0;if(this.infoTrue){var dpr=1;if(this.high&&!this.full){dpr=window.devicePixelRatio;}if(this.enlarge!==1&!this.full){dpr=Math.abs(Number(this.enlarge));}obj.width=obj.width*dpr;obj.height=obj.height*dpr;if(this.full){obj.width=obj.width/this.scale;obj.height=obj.height/this.scale;}}obj.width=obj.width.toFixed(0);obj.height=obj.height.toFixed(0);return obj;},isIE:function isIE(){var isIE=!!window.ActiveXObject||"ActiveXObject"in window;return isIE;},passive:function passive(){return this.isIE?null:{passive:false};}},watch:{img:function img(){this.checkedImg();},imgs:function imgs(val){if(val===""){return;}this.reload();},cropW:function cropW(){this.showPreview();},cropH:function cropH(){this.showPreview();},cropOffsertX:function cropOffsertX(){this.showPreview();},cropOffsertY:function cropOffsertY(){this.showPreview();},scale:function scale(val,oldVal){this.showPreview();},x:function x(){this.showPreview();},y:function y(){this.showPreview();},autoCrop:function autoCrop(val){if(val){this.goAutoCrop();}},autoCropWidth:function autoCropWidth(){if(this.autoCrop){this.goAutoCrop();}},autoCropHeight:function autoCropHeight(){if(this.autoCrop){this.goAutoCrop();}},mode:function mode(){this.checkedImg();},rotate:function rotate(){this.showPreview();if(this.autoCrop){this.goAutoCrop(this.cropW,this.cropH);}else{if(this.cropW>0||this.cropH>0){this.goAutoCrop(this.cropW,this.cropH);}}}},methods:{getVersion:function getVersion(name){var arr=navigator.userAgent.split(" ");var chromeVersion="";var result=0;var reg=new RegExp(name,"i");for(var i=0;i<arr.length;i++){if(reg.test(arr[i]))chromeVersion=arr[i];}if(chromeVersion){result=chromeVersion.split("/")[1].split(".");}else{result=["0","0","0"];}return result;},checkOrientationImage:function checkOrientationImage(img,orientation,width,height){var _this4=this;if(this.getVersion("chrome")[0]>=81){orientation=-1;}else{if(this.getVersion("safari")[0]>=605){var safariVersion=this.getVersion("version");if(safariVersion[0]>13&&safariVersion[1]>1){orientation=-1;}}else{var isIos=navigator.userAgent.toLowerCase().match(/cpu iphone os (.*?) like mac os/);if(isIos){var version=isIos[1];version=version.split("_");if(version[0]>13||version[0]>=13&&version[1]>=4){orientation=-1;}}}}var canvas=document.createElement("canvas");var ctx=canvas.getContext("2d");ctx.save();switch(orientation){case 2:canvas.width=width;canvas.height=height;ctx.translate(width,0);ctx.scale(-1,1);break;case 3:canvas.width=width;canvas.height=height;ctx.translate(width/2,height/2);ctx.rotate(180*Math.PI/180);ctx.translate(-width/2,-height/2);break;case 4:canvas.width=width;canvas.height=height;ctx.translate(0,height);ctx.scale(1,-1);break;case 5:canvas.height=width;canvas.width=height;ctx.rotate(0.5*Math.PI);ctx.scale(1,-1);break;case 6:canvas.width=height;canvas.height=width;ctx.translate(height/2,width/2);ctx.rotate(90*Math.PI/180);ctx.translate(-width/2,-height/2);break;case 7:canvas.height=width;canvas.width=height;ctx.rotate(0.5*Math.PI);ctx.translate(width,-height);ctx.scale(-1,1);break;case 8:canvas.height=width;canvas.width=height;ctx.translate(height/2,width/2);ctx.rotate(-90*Math.PI/180);ctx.translate(-width/2,-height/2);break;default:canvas.width=width;canvas.height=height;}ctx.drawImage(img,0,0,width,height);ctx.restore();canvas.toBlob(function(blob){var data=URL.createObjectURL(blob);URL.revokeObjectURL(_this4.imgs);_this4.imgs=data;},"image/"+this.outputType,1);},checkedImg:function checkedImg(){var _this5=this;if(this.img===null||this.img===""){this.imgs="";this.clearCrop();return;}this.loading=true;this.scale=1;this.rotate=0;this.clearCrop();var img=new Image();img.onload=function(){if(_this5.img===""){_this5.$emit("img-load","error");return false;}var width=img.width;var height=img.height;Exif.getData(img).then(function(data){_this5.orientation=data.orientation||1;var max=Number(_this5.maxImgSize);if(!_this5.orientation&&width<max&height<max){_this5.imgs=_this5.img;return;}if(width>max){height=height/width*max;width=max;}if(height>max){width=width/height*max;height=max;}_this5.checkOrientationImage(img,_this5.orientation,width,height);});};img.onerror=function(){_this5.$emit("img-load","error");};if(this.img.substr(0,4)!=="data"){img.crossOrigin="";}if(this.isIE){var xhr=new XMLHttpRequest();xhr.onload=function(){var url=URL.createObjectURL(this.response);img.src=url;};xhr.open("GET",this.img,true);xhr.responseType="blob";xhr.send();}else{img.src=this.img;}},startMove:function startMove(e){e.preventDefault();if(this.move&&!this.crop){if(!this.canMove){return false;}this.moveX=("clientX"in e?e.clientX:e.touches[0].clientX)-this.x;this.moveY=("clientY"in e?e.clientY:e.touches[0].clientY)-this.y;if(e.touches){window.addEventListener("touchmove",this.moveImg);window.addEventListener("touchend",this.leaveImg);if(e.touches.length==2){this.touches=e.touches;window.addEventListener("touchmove",this.touchScale);window.addEventListener("touchend",this.cancelTouchScale);}}else{window.addEventListener("mousemove",this.moveImg);window.addEventListener("mouseup",this.leaveImg);}this.$emit("imgMoving",{moving:true,axis:this.getImgAxis()});this.$emit("img-moving",{moving:true,axis:this.getImgAxis()});}else{this.cropping=true;window.addEventListener("mousemove",this.createCrop);window.addEventListener("mouseup",this.endCrop);window.addEventListener("touchmove",this.createCrop);window.addEventListener("touchend",this.endCrop);this.cropOffsertX=e.offsetX?e.offsetX:e.touches[0].pageX-this.$refs.cropper.offsetLeft;this.cropOffsertY=e.offsetY?e.offsetY:e.touches[0].pageY-this.$refs.cropper.offsetTop;this.cropX="clientX"in e?e.clientX:e.touches[0].clientX;this.cropY="clientY"in e?e.clientY:e.touches[0].clientY;this.cropChangeX=this.cropOffsertX;this.cropChangeY=this.cropOffsertY;this.cropW=0;this.cropH=0;}},touchScale:function touchScale(e){var _this6=this;e.preventDefault();var scale=this.scale;var oldTouch1={x:this.touches[0].clientX,y:this.touches[0].clientY};var newTouch1={x:e.touches[0].clientX,y:e.touches[0].clientY};var oldTouch2={x:this.touches[1].clientX,y:this.touches[1].clientY};var newTouch2={x:e.touches[1].clientX,y:e.touches[1].clientY};var oldL=Math.sqrt(Math.pow(oldTouch1.x-oldTouch2.x,2)+Math.pow(oldTouch1.y-oldTouch2.y,2));var newL=Math.sqrt(Math.pow(newTouch1.x-newTouch2.x,2)+Math.pow(newTouch1.y-newTouch2.y,2));var cha=newL-oldL;var coe=1;coe=coe/this.trueWidth>coe/this.trueHeight?coe/this.trueHeight:coe/this.trueWidth;coe=coe>0.1?0.1:coe;var num=coe*cha;if(!this.touchNow){this.touchNow=true;if(cha>0){scale+=Math.abs(num);}else if(cha<0){scale>Math.abs(num)?scale-=Math.abs(num):scale;}this.touches=e.touches;setTimeout(function(){_this6.touchNow=false;},8);if(!this.checkoutImgAxis(this.x,this.y,scale)){return false;}this.scale=scale;}},cancelTouchScale:function cancelTouchScale(e){window.removeEventListener("touchmove",this.touchScale);},moveImg:function moveImg(e){var _this7=this;e.preventDefault();if(e.touches&&e.touches.length===2){this.touches=e.touches;window.addEventListener("touchmove",this.touchScale);window.addEventListener("touchend",this.cancelTouchScale);window.removeEventListener("touchmove",this.moveImg);return false;}var nowX="clientX"in e?e.clientX:e.touches[0].clientX;var nowY="clientY"in e?e.clientY:e.touches[0].clientY;var changeX,changeY;changeX=nowX-this.moveX;changeY=nowY-this.moveY;this.$nextTick(function(){if(_this7.centerBox){var axis=_this7.getImgAxis(changeX,changeY,_this7.scale);var cropAxis=_this7.getCropAxis();var imgW=_this7.trueHeight*_this7.scale;var imgH=_this7.trueWidth*_this7.scale;var maxLeft,maxTop,maxRight,maxBottom;switch(_this7.rotate){case 1:case-1:case 3:case-3:maxLeft=_this7.cropOffsertX-_this7.trueWidth*(1-_this7.scale)/2+(imgW-imgH)/2;maxTop=_this7.cropOffsertY-_this7.trueHeight*(1-_this7.scale)/2+(imgH-imgW)/2;maxRight=maxLeft-imgW+_this7.cropW;maxBottom=maxTop-imgH+_this7.cropH;break;default:maxLeft=_this7.cropOffsertX-_this7.trueWidth*(1-_this7.scale)/2;maxTop=_this7.cropOffsertY-_this7.trueHeight*(1-_this7.scale)/2;maxRight=maxLeft-imgH+_this7.cropW;maxBottom=maxTop-imgW+_this7.cropH;break;}if(axis.x1>=cropAxis.x1){changeX=maxLeft;}if(axis.y1>=cropAxis.y1){changeY=maxTop;}if(axis.x2<=cropAxis.x2){changeX=maxRight;}if(axis.y2<=cropAxis.y2){changeY=maxBottom;}}_this7.x=changeX;_this7.y=changeY;_this7.$emit("imgMoving",{moving:true,axis:_this7.getImgAxis()});_this7.$emit("img-moving",{moving:true,axis:_this7.getImgAxis()});});},leaveImg:function leaveImg(e){window.removeEventListener("mousemove",this.moveImg);window.removeEventListener("touchmove",this.moveImg);window.removeEventListener("mouseup",this.leaveImg);window.removeEventListener("touchend",this.leaveImg);this.$emit("imgMoving",{moving:false,axis:this.getImgAxis()});this.$emit("img-moving",{moving:false,axis:this.getImgAxis()});},scaleImg:function scaleImg(){if(this.canScale){window.addEventListener(this.support,this.changeSize,this.passive);}},cancelScale:function cancelScale(){if(this.canScale){window.removeEventListener(this.support,this.changeSize);}},changeSize:function changeSize(e){var _this8=this;e.preventDefault();var scale=this.scale;var change=e.deltaY||e.wheelDelta;var isFirefox=navigator.userAgent.indexOf("Firefox");change=isFirefox>0?change*30:change;if(this.isIE){change=-change;}var coe=this.coe;coe=coe/this.trueWidth>coe/this.trueHeight?coe/this.trueHeight:coe/this.trueWidth;var num=coe*change;num<0?scale+=Math.abs(num):scale>Math.abs(num)?scale-=Math.abs(num):scale;var status=num<0?"add":"reduce";if(status!==this.coeStatus){this.coeStatus=status;this.coe=0.2;}if(!this.scaling){this.scalingSet=setTimeout(function(){_this8.scaling=false;_this8.coe=_this8.coe+=0.01;},50);}this.scaling=true;if(!this.checkoutImgAxis(this.x,this.y,scale)){return false;}this.scale=scale;},changeScale:function changeScale(num){var scale=this.scale;num=num||1;var coe=20;coe=coe/this.trueWidth>coe/this.trueHeight?coe/this.trueHeight:coe/this.trueWidth;num=num*coe;num>0?scale+=Math.abs(num):scale>Math.abs(num)?scale-=Math.abs(num):scale;if(!this.checkoutImgAxis(this.x,this.y,scale)){return false;}this.scale=scale;},createCrop:function createCrop(e){var _this9=this;e.preventDefault();var nowX="clientX"in e?e.clientX:e.touches?e.touches[0].clientX:0;var nowY="clientY"in e?e.clientY:e.touches?e.touches[0].clientY:0;this.$nextTick(function(){var fw=nowX-_this9.cropX;var fh=nowY-_this9.cropY;if(fw>0){_this9.cropW=fw+_this9.cropChangeX>_this9.w?_this9.w-_this9.cropChangeX:fw;_this9.cropOffsertX=_this9.cropChangeX;}else{_this9.cropW=_this9.w-_this9.cropChangeX+Math.abs(fw)>_this9.w?_this9.cropChangeX:Math.abs(fw);_this9.cropOffsertX=_this9.cropChangeX+fw>0?_this9.cropChangeX+fw:0;}if(!_this9.fixed){if(fh>0){_this9.cropH=fh+_this9.cropChangeY>_this9.h?_this9.h-_this9.cropChangeY:fh;_this9.cropOffsertY=_this9.cropChangeY;}else{_this9.cropH=_this9.h-_this9.cropChangeY+Math.abs(fh)>_this9.h?_this9.cropChangeY:Math.abs(fh);_this9.cropOffsertY=_this9.cropChangeY+fh>0?_this9.cropChangeY+fh:0;}}else{var fixedHeight=_this9.cropW/_this9.fixedNumber[0]*_this9.fixedNumber[1];if(fixedHeight+_this9.cropOffsertY>_this9.h){_this9.cropH=_this9.h-_this9.cropOffsertY;_this9.cropW=_this9.cropH/_this9.fixedNumber[1]*_this9.fixedNumber[0];if(fw>0){_this9.cropOffsertX=_this9.cropChangeX;}else{_this9.cropOffsertX=_this9.cropChangeX-_this9.cropW;}}else{_this9.cropH=fixedHeight;}_this9.cropOffsertY=_this9.cropOffsertY;}});},changeCropSize:function changeCropSize(e,w,h,typeW,typeH){e.preventDefault();window.addEventListener("mousemove",this.changeCropNow);window.addEventListener("mouseup",this.changeCropEnd);window.addEventListener("touchmove",this.changeCropNow);window.addEventListener("touchend",this.changeCropEnd);this.canChangeX=w;this.canChangeY=h;this.changeCropTypeX=typeW;this.changeCropTypeY=typeH;this.cropX="clientX"in e?e.clientX:e.touches[0].clientX;this.cropY="clientY"in e?e.clientY:e.touches[0].clientY;this.cropOldW=this.cropW;this.cropOldH=this.cropH;this.cropChangeX=this.cropOffsertX;this.cropChangeY=this.cropOffsertY;if(this.fixed){if(this.canChangeX&&this.canChangeY){this.canChangeY=0;}}this.$emit("change-crop-size",{width:this.cropW,height:this.cropH});},changeCropNow:function changeCropNow(e){var _this10=this;e.preventDefault();var nowX="clientX"in e?e.clientX:e.touches?e.touches[0].clientX:0;var nowY="clientY"in e?e.clientY:e.touches?e.touches[0].clientY:0;var wrapperW=this.w;var wrapperH=this.h;var minX=0;var minY=0;if(this.centerBox){var axis=this.getImgAxis();var imgW=axis.x2;var imgH=axis.y2;minX=axis.x1>0?axis.x1:0;minY=axis.y1>0?axis.y1:0;if(wrapperW>imgW){wrapperW=imgW;}if(wrapperH>imgH){wrapperH=imgH;}}this.$nextTick(function(){var fw=nowX-_this10.cropX;var fh=nowY-_this10.cropY;if(_this10.canChangeX){if(_this10.changeCropTypeX===1){if(_this10.cropOldW-fw>0){_this10.cropW=wrapperW-_this10.cropChangeX-fw<=wrapperW-minX?_this10.cropOldW-fw:_this10.cropOldW+_this10.cropChangeX-minX;_this10.cropOffsertX=wrapperW-_this10.cropChangeX-fw<=wrapperW-minX?_this10.cropChangeX+fw:minX;}else{_this10.cropW=Math.abs(fw)+_this10.cropChangeX<=wrapperW?Math.abs(fw)-_this10.cropOldW:wrapperW-_this10.cropOldW-_this10.cropChangeX;_this10.cropOffsertX=_this10.cropChangeX+_this10.cropOldW;}}else if(_this10.changeCropTypeX===2){if(_this10.cropOldW+fw>0){_this10.cropW=_this10.cropOldW+fw+_this10.cropOffsertX<=wrapperW?_this10.cropOldW+fw:wrapperW-_this10.cropOffsertX;_this10.cropOffsertX=_this10.cropChangeX;}else{_this10.cropW=wrapperW-_this10.cropChangeX+Math.abs(fw+_this10.cropOldW)<=wrapperW-minX?Math.abs(fw+_this10.cropOldW):_this10.cropChangeX-minX;_this10.cropOffsertX=wrapperW-_this10.cropChangeX+Math.abs(fw+_this10.cropOldW)<=wrapperW-minX?_this10.cropChangeX-Math.abs(fw+_this10.cropOldW):minX;}}}if(_this10.canChangeY){if(_this10.changeCropTypeY===1){if(_this10.cropOldH-fh>0){_this10.cropH=wrapperH-_this10.cropChangeY-fh<=wrapperH-minY?_this10.cropOldH-fh:_this10.cropOldH+_this10.cropChangeY-minY;_this10.cropOffsertY=wrapperH-_this10.cropChangeY-fh<=wrapperH-minY?_this10.cropChangeY+fh:minY;}else{_this10.cropH=Math.abs(fh)+_this10.cropChangeY<=wrapperH?Math.abs(fh)-_this10.cropOldH:wrapperH-_this10.cropOldH-_this10.cropChangeY;_this10.cropOffsertY=_this10.cropChangeY+_this10.cropOldH;}}else if(_this10.changeCropTypeY===2){if(_this10.cropOldH+fh>0){_this10.cropH=_this10.cropOldH+fh+_this10.cropOffsertY<=wrapperH?_this10.cropOldH+fh:wrapperH-_this10.cropOffsertY;_this10.cropOffsertY=_this10.cropChangeY;}else{_this10.cropH=wrapperH-_this10.cropChangeY+Math.abs(fh+_this10.cropOldH)<=wrapperH-minY?Math.abs(fh+_this10.cropOldH):_this10.cropChangeY-minY;_this10.cropOffsertY=wrapperH-_this10.cropChangeY+Math.abs(fh+_this10.cropOldH)<=wrapperH-minY?_this10.cropChangeY-Math.abs(fh+_this10.cropOldH):minY;}}}if(_this10.canChangeX&&_this10.fixed){var fixedHeight=_this10.cropW/_this10.fixedNumber[0]*_this10.fixedNumber[1];if(fixedHeight+_this10.cropOffsertY>wrapperH){_this10.cropH=wrapperH-_this10.cropOffsertY;_this10.cropW=_this10.cropH/_this10.fixedNumber[1]*_this10.fixedNumber[0];}else{_this10.cropH=fixedHeight;}}if(_this10.canChangeY&&_this10.fixed){var fixedWidth=_this10.cropH/_this10.fixedNumber[1]*_this10.fixedNumber[0];if(fixedWidth+_this10.cropOffsertX>wrapperW){_this10.cropW=wrapperW-_this10.cropOffsertX;_this10.cropH=_this10.cropW/_this10.fixedNumber[0]*_this10.fixedNumber[1];}else{_this10.cropW=fixedWidth;}}});},checkCropLimitSize:function checkCropLimitSize(){var cropW=this.cropW,cropH=this.cropH,limitMinSize=this.limitMinSize;var limitMinNum=new Array();if(!Array.isArray[limitMinSize]){limitMinNum=[limitMinSize,limitMinSize];}else{limitMinNum=limitMinSize;}cropW=parseFloat(limitMinNum[0]);cropH=parseFloat(limitMinNum[1]);return[cropW,cropH];},changeCropEnd:function changeCropEnd(e){window.removeEventListener("mousemove",this.changeCropNow);window.removeEventListener("mouseup",this.changeCropEnd);window.removeEventListener("touchmove",this.changeCropNow);window.removeEventListener("touchend",this.changeCropEnd);},endCrop:function endCrop(){if(this.cropW===0&&this.cropH===0){this.cropping=false;}window.removeEventListener("mousemove",this.createCrop);window.removeEventListener("mouseup",this.endCrop);window.removeEventListener("touchmove",this.createCrop);window.removeEventListener("touchend",this.endCrop);},startCrop:function startCrop(){this.crop=true;},stopCrop:function stopCrop(){this.crop=false;},clearCrop:function clearCrop(){this.cropping=false;this.cropW=0;this.cropH=0;},cropMove:function cropMove(e){e.preventDefault();if(!this.canMoveBox){this.crop=false;this.startMove(e);return false;}if(e.touches&&e.touches.length===2){this.crop=false;this.startMove(e);this.leaveCrop();return false;}window.addEventListener("mousemove",this.moveCrop);window.addEventListener("mouseup",this.leaveCrop);window.addEventListener("touchmove",this.moveCrop);window.addEventListener("touchend",this.leaveCrop);var x="clientX"in e?e.clientX:e.touches[0].clientX;var y="clientY"in e?e.clientY:e.touches[0].clientY;var newX,newY;newX=x-this.cropOffsertX;newY=y-this.cropOffsertY;this.cropX=newX;this.cropY=newY;this.$emit("cropMoving",{moving:true,axis:this.getCropAxis()});this.$emit("crop-moving",{moving:true,axis:this.getCropAxis()});},moveCrop:function moveCrop(e,isMove){var _this11=this;var nowX=0;var nowY=0;if(e){e.preventDefault();nowX="clientX"in e?e.clientX:e.touches[0].clientX;nowY="clientY"in e?e.clientY:e.touches[0].clientY;}this.$nextTick(function(){var cx,cy;var fw=nowX-_this11.cropX;var fh=nowY-_this11.cropY;if(isMove){fw=_this11.cropOffsertX;fh=_this11.cropOffsertY;}if(fw<=0){cx=0;}else if(fw+_this11.cropW>_this11.w){cx=_this11.w-_this11.cropW;}else{cx=fw;}if(fh<=0){cy=0;}else if(fh+_this11.cropH>_this11.h){cy=_this11.h-_this11.cropH;}else{cy=fh;}if(_this11.centerBox){var axis=_this11.getImgAxis();if(cx<=axis.x1){cx=axis.x1;}if(cx+_this11.cropW>axis.x2){cx=axis.x2-_this11.cropW;}if(cy<=axis.y1){cy=axis.y1;}if(cy+_this11.cropH>axis.y2){cy=axis.y2-_this11.cropH;}}_this11.cropOffsertX=cx;_this11.cropOffsertY=cy;_this11.$emit("cropMoving",{moving:true,axis:_this11.getCropAxis()});_this11.$emit("crop-moving",{moving:true,axis:_this11.getCropAxis()});});},getImgAxis:function getImgAxis(x,y,scale){x=x||this.x;y=y||this.y;scale=scale||this.scale;var obj={x1:0,x2:0,y1:0,y2:0};var imgW=this.trueWidth*scale;var imgH=this.trueHeight*scale;switch(this.rotate){case 0:obj.x1=x+this.trueWidth*(1-scale)/2;obj.x2=obj.x1+this.trueWidth*scale;obj.y1=y+this.trueHeight*(1-scale)/2;obj.y2=obj.y1+this.trueHeight*scale;break;case 1:case-1:case 3:case-3:obj.x1=x+this.trueWidth*(1-scale)/2+(imgW-imgH)/2;obj.x2=obj.x1+this.trueHeight*scale;obj.y1=y+this.trueHeight*(1-scale)/2+(imgH-imgW)/2;obj.y2=obj.y1+this.trueWidth*scale;break;default:obj.x1=x+this.trueWidth*(1-scale)/2;obj.x2=obj.x1+this.trueWidth*scale;obj.y1=y+this.trueHeight*(1-scale)/2;obj.y2=obj.y1+this.trueHeight*scale;break;}return obj;},getCropAxis:function getCropAxis(){var obj={x1:0,x2:0,y1:0,y2:0};obj.x1=this.cropOffsertX;obj.x2=obj.x1+this.cropW;obj.y1=this.cropOffsertY;obj.y2=obj.y1+this.cropH;return obj;},leaveCrop:function leaveCrop(e){window.removeEventListener("mousemove",this.moveCrop);window.removeEventListener("mouseup",this.leaveCrop);window.removeEventListener("touchmove",this.moveCrop);window.removeEventListener("touchend",this.leaveCrop);this.$emit("cropMoving",{moving:false,axis:this.getCropAxis()});this.$emit("crop-moving",{moving:false,axis:this.getCropAxis()});},getCropChecked:function getCropChecked(cb){var _this12=this;var canvas=document.createElement("canvas");var img=new Image();var rotate=this.rotate;var trueWidth=this.trueWidth;var trueHeight=this.trueHeight;var cropOffsertX=this.cropOffsertX;var cropOffsertY=this.cropOffsertY;img.onload=function(){if(_this12.cropW!==0){var ctx=canvas.getContext("2d");var dpr=1;if(_this12.high&!_this12.full){dpr=window.devicePixelRatio;}if(_this12.enlarge!==1&!_this12.full){dpr=Math.abs(Number(_this12.enlarge));}var width=_this12.cropW*dpr;var height=_this12.cropH*dpr;var imgW=trueWidth*_this12.scale*dpr;var imgH=trueHeight*_this12.scale*dpr;var dx=(_this12.x-cropOffsertX+_this12.trueWidth*(1-_this12.scale)/2)*dpr;var dy=(_this12.y-cropOffsertY+_this12.trueHeight*(1-_this12.scale)/2)*dpr;setCanvasSize(width,height);ctx.save();switch(rotate){case 0:if(!_this12.full){ctx.drawImage(img,dx,dy,imgW,imgH);}else{setCanvasSize(width/_this12.scale,height/_this12.scale);ctx.drawImage(img,dx/_this12.scale,dy/_this12.scale,imgW/_this12.scale,imgH/_this12.scale);}break;case 1:case-3:if(!_this12.full){dx=dx+(imgW-imgH)/2;dy=dy+(imgH-imgW)/2;ctx.rotate(rotate*90*Math.PI/180);ctx.drawImage(img,dy,-dx-imgH,imgW,imgH);}else{setCanvasSize(width/_this12.scale,height/_this12.scale);dx=dx/_this12.scale+(imgW/_this12.scale-imgH/_this12.scale)/2;dy=dy/_this12.scale+(imgH/_this12.scale-imgW/_this12.scale)/2;ctx.rotate(rotate*90*Math.PI/180);ctx.drawImage(img,dy,-dx-imgH/_this12.scale,imgW/_this12.scale,imgH/_this12.scale);}break;case 2:case-2:if(!_this12.full){ctx.rotate(rotate*90*Math.PI/180);ctx.drawImage(img,-dx-imgW,-dy-imgH,imgW,imgH);}else{setCanvasSize(width/_this12.scale,height/_this12.scale);ctx.rotate(rotate*90*Math.PI/180);dx=dx/_this12.scale;dy=dy/_this12.scale;ctx.drawImage(img,-dx-imgW/_this12.scale,-dy-imgH/_this12.scale,imgW/_this12.scale,imgH/_this12.scale);}break;case 3:case-1:if(!_this12.full){dx=dx+(imgW-imgH)/2;dy=dy+(imgH-imgW)/2;ctx.rotate(rotate*90*Math.PI/180);ctx.drawImage(img,-dy-imgW,dx,imgW,imgH);}else{setCanvasSize(width/_this12.scale,height/_this12.scale);dx=dx/_this12.scale+(imgW/_this12.scale-imgH/_this12.scale)/2;dy=dy/_this12.scale+(imgH/_this12.scale-imgW/_this12.scale)/2;ctx.rotate(rotate*90*Math.PI/180);ctx.drawImage(img,-dy-imgW/_this12.scale,dx,imgW/_this12.scale,imgH/_this12.scale);}break;default:if(!_this12.full){ctx.drawImage(img,dx,dy,imgW,imgH);}else{setCanvasSize(width/_this12.scale,height/_this12.scale);ctx.drawImage(img,dx/_this12.scale,dy/_this12.scale,imgW/_this12.scale,imgH/_this12.scale);}}ctx.restore();}else{var _width=trueWidth*_this12.scale;var _height=trueHeight*_this12.scale;var _ctx2=canvas.getContext("2d");_ctx2.save();switch(rotate){case 0:setCanvasSize(_width,_height);_ctx2.drawImage(img,0,0,_width,_height);break;case 1:case-3:setCanvasSize(_height,_width);_ctx2.rotate(rotate*90*Math.PI/180);_ctx2.drawImage(img,0,-_height,_width,_height);break;case 2:case-2:setCanvasSize(_width,_height);_ctx2.rotate(rotate*90*Math.PI/180);_ctx2.drawImage(img,-_width,-_height,_width,_height);break;case 3:case-1:setCanvasSize(_height,_width);_ctx2.rotate(rotate*90*Math.PI/180);_ctx2.drawImage(img,-_width,0,_width,_height);break;default:setCanvasSize(_width,_height);_ctx2.drawImage(img,0,0,_width,_height);}_ctx2.restore();}cb(canvas);};var s=this.img.substr(0,4);if(s!=="data"){img.crossOrigin="Anonymous";}img.src=this.imgs;function setCanvasSize(width,height){canvas.width=Math.round(width);canvas.height=Math.round(height);}},getCropData:function getCropData(cb){var _this13=this;this.getCropChecked(function(data){cb(data.toDataURL("image/"+_this13.outputType,_this13.outputSize));});},getCropBlob:function getCropBlob(cb){var _this14=this;this.getCropChecked(function(data){data.toBlob(function(blob){return cb(blob);},"image/"+_this14.outputType,_this14.outputSize);});},showPreview:function showPreview(){var _this15=this;if(this.isCanShow){this.isCanShow=false;setTimeout(function(){_this15.isCanShow=true;},16);}else{return false;}var w=this.cropW;var h=this.cropH;var scale=this.scale;var obj={};obj.div={width:"".concat(w,"px"),height:"".concat(h,"px")};var transformX=(this.x-this.cropOffsertX)/scale;var transformY=(this.y-this.cropOffsertY)/scale;var transformZ=0;obj.w=w;obj.h=h;obj.url=this.imgs;obj.img={width:"".concat(this.trueWidth,"px"),height:"".concat(this.trueHeight,"px"),transform:"scale(".concat(scale,")translate3d(").concat(transformX,"px, ").concat(transformY,"px, ").concat(transformZ,"px)rotateZ(").concat(this.rotate*90,"deg)")};obj.html="\n <div class=\"show-preview\" style=\"width: ".concat(obj.w,"px; height: ").concat(obj.h,"px,; overflow: hidden\">\n <div style=\"width: ").concat(w,"px; height: ").concat(h,"px\">\n <img src=").concat(obj.url," style=\"width: ").concat(this.trueWidth,"px; height: ").concat(this.trueHeight,"px; transform:\n scale(").concat(scale,")translate3d(").concat(transformX,"px, ").concat(transformY,"px, ").concat(transformZ,"px)rotateZ(").concat(this.rotate*90,"deg)\">\n </div>\n </div>");this.$emit("realTime",obj);this.$emit("real-time",obj);},reload:function reload(){var _this16=this;var img=new Image();img.onload=function(){_this16.w=parseFloat(window.getComputedStyle(_this16.$refs.cropper).width);_this16.h=parseFloat(window.getComputedStyle(_this16.$refs.cropper).height);_this16.trueWidth=img.width;_this16.trueHeight=img.height;if(!_this16.original){_this16.scale=_this16.checkedMode();}else{_this16.scale=1;}_this16.$nextTick(function(){_this16.x=-(_this16.trueWidth-_this16.trueWidth*_this16.scale)/2+(_this16.w-_this16.trueWidth*_this16.scale)/2;_this16.y=-(_this16.trueHeight-_this16.trueHeight*_this16.scale)/2+(_this16.h-_this16.trueHeight*_this16.scale)/2;_this16.loading=false;if(_this16.autoCrop){_this16.goAutoCrop();}_this16.$emit("img-load","success");_this16.$emit("imgLoad","success");setTimeout(function(){_this16.showPreview();},20);});};img.onerror=function(){_this16.$emit("imgLoad","error");_this16.$emit("img-load","error");};img.src=this.imgs;},checkedMode:function checkedMode(){var scale=1;var imgW=this.trueWidth;var imgH=this.trueHeight;var arr=this.mode.split(" ");switch(arr[0]){case"contain":if(this.trueWidth>this.w){scale=this.w/this.trueWidth;}if(this.trueHeight*scale>this.h){scale=this.h/this.trueHeight;}break;case"cover":imgW=this.w;scale=imgW/this.trueWidth;imgH=imgH*scale;if(imgH<this.h){imgH=this.h;scale=imgH/this.trueHeight;}break;default:try{var str=arr[0];if(str.search("px")!==-1){str=str.replace("px","");imgW=parseFloat(str);var scaleX=imgW/this.trueWidth;var scaleY=1;var strH=arr[1];if(strH.search("px")!==-1){strH=strH.replace("px","");imgH=parseFloat(strH);scaleY=imgH/this.trueHeight;}scale=Math.min(scaleX,scaleY);}if(str.search("%")!==-1){str=str.replace("%","");imgW=parseFloat(str)/100*this.w;scale=imgW/this.trueWidth;}if(arr.length===2&&str==="auto"){var str2=arr[1];if(str2.search("px")!==-1){str2=str2.replace("px","");imgH=parseFloat(str2);scale=imgH/this.trueHeight;}if(str2.search("%")!==-1){str2=str2.replace("%","");imgH=parseFloat(str2)/100*this.h;scale=imgH/this.trueHeight;}}}catch(error){scale=1;}}return scale;},goAutoCrop:function goAutoCrop(cw,ch){if(this.imgs===""||this.imgs===null)return;this.clearCrop();this.cropping=true;var maxWidth=this.w;var maxHeight=this.h;if(this.centerBox){var switchWH=Math.abs(this.rotate)%2>0;var imgW=(switchWH?this.trueHeight:this.trueWidth)*this.scale;var imgH=(switchWH?this.trueWidth:this.trueHeight)*this.scale;maxWidth=imgW<maxWidth?imgW:maxWidth;maxHeight=imgH<maxHeight?imgH:maxHeight;}var w=cw?cw:parseFloat(this.autoCropWidth);var h=ch?ch:parseFloat(this.autoCropHeight);if(w===0||h===0){w=maxWidth*0.8;h=maxHeight*0.8;}w=w>maxWidth?maxWidth:w;h=h>maxHeight?maxHeight:h;if(this.fixed){h=w/this.fixedNumber[0]*this.fixedNumber[1];}if(h>this.h){h=this.h;w=h/this.fixedNumber[1]*this.fixedNumber[0];}this.changeCrop(w,h);},changeCrop:function changeCrop(w,h){var _this17=this;if(this.centerBox){var axis=this.getImgAxis();if(w>axis.x2-axis.x1){w=axis.x2-axis.x1;h=w/this.fixedNumber[0]*this.fixedNumber[1];}if(h>axis.y2-axis.y1){h=axis.y2-axis.y1;w=h/this.fixedNumber[1]*this.fixedNumber[0];}}this.cropW=w;this.cropH=h;this.checkCropLimitSize();this.$nextTick(function(){_this17.cropOffsertX=(_this17.w-_this17.cropW)/2;_this17.cropOffsertY=(_this17.h-_this17.cropH)/2;if(_this17.centerBox){_this17.moveCrop(null,true);}});},refresh:function refresh(){var _this18=this;this.img;this.imgs="";this.scale=1;this.crop=false;this.rotate=0;this.w=0;this.h=0;this.trueWidth=0;this.trueHeight=0;this.clearCrop();this.$nextTick(function(){_this18.checkedImg();});},rotateLeft:function rotateLeft(){this.rotate=this.rotate<=-3?0:this.rotate-1;},rotateRight:function rotateRight(){this.rotate=this.rotate>=3?0:this.rotate+1;},rotateClear:function rotateClear(){this.rotate=0;},checkoutImgAxis:function checkoutImgAxis(x,y,scale){x=x||this.x;y=y||this.y;scale=scale||this.scale;var canGo=true;if(this.centerBox){var axis=this.getImgAxis(x,y,scale);var cropAxis=this.getCropAxis();if(axis.x1>=cropAxis.x1){canGo=false;}if(axis.x2<=cropAxis.x2){canGo=false;}if(axis.y1>=cropAxis.y1){canGo=false;}if(axis.y2<=cropAxis.y2){canGo=false;}}return canGo;}},mounted:function mounted(){this.support="onwheel"in document.createElement("div")?"wheel":document.onmousewheel!==void 0?"mousewheel":"DOMMouseScroll";var that=this;var u=navigator.userAgent;this.isIOS=!!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);if(!HTMLCanvasElement.prototype.toBlob){Object.defineProperty(HTMLCanvasElement.prototype,"toBlob",{value:function value(callback,type,quality){var binStr=atob(this.toDataURL(type,quality).split(",")[1]),len=binStr.length,arr=new Uint8Array(len);for(var i=0;i<len;i++){arr[i]=binStr.charCodeAt(i);}callback(new Blob([arr],{type:that.type||"image/png"}));}});}this.showPreview();this.checkedImg();},destroyed:function destroyed(){window.removeEventListener("mousemove",this.moveCrop);window.removeEventListener("mouseup",this.leaveCrop);window.removeEventListener("touchmove",this.moveCrop);window.removeEventListener("touchend",this.leaveCrop);this.cancelScale();}});var _hoisted_1={key:0,class:"cropper-box"};var _hoisted_2=["src"];var _hoisted_3={class:"cropper-view-box"};var _hoisted_4=["src"];var _hoisted_5={key:1};function _sfc_render(_ctx,_cache,$props,$setup,$data,$options){return openBlock(),createElementBlock("div",{class:"vue-cropper",ref:"cropper",onMouseover:_cache[28]||(_cache[28]=function(){return _ctx.scaleImg&&_ctx.scaleImg.apply(_ctx,arguments);}),onMouseout:_cache[29]||(_cache[29]=function(){return _ctx.cancelScale&&_ctx.cancelScale.apply(_ctx,arguments);})},[_ctx.imgs?(openBlock(),createElementBlock("div",_hoisted_1,[withDirectives(createBaseVNode("div",{class:"cropper-box-canvas",style:normalizeStyle({"width":_ctx.trueWidth+"px","height":_ctx.trueHeight+"px","transform":"scale("+_ctx.scale+","+_ctx.scale+") translate3d("+_ctx.x/_ctx.scale+"px,"+_ctx.y/_ctx.scale+"px,0)rotateZ("+_ctx.rotate*90+"deg)"})},[createBaseVNode("img",{src:_ctx.imgs,alt:"cropper-img",ref:"cropperImg"},null,8,_hoisted_2)],4),[[vShow,!_ctx.loading]])])):createCommentVNode("",true),createBaseVNode("div",{class:normalizeClass(["cropper-drag-box",{"cropper-move":_ctx.move&&!_ctx.crop,"cropper-crop":_ctx.crop,"cropper-modal":_ctx.cropping}]),onMousedown:_cache[0]||(_cache[0]=function(){return _ctx.startMove&&_ctx.startMove.apply(_ctx,arguments);}),onTouchstart:_cache[1]||(_cache[1]=function(){return _ctx.startMove&&_ctx.startMove.apply(_ctx,arguments);})},null,34),withDirectives(createBaseVNode("div",{class:"cropper-crop-box",style:normalizeStyle({"width":_ctx.cropW+"px","height":_ctx.cropH+"px","transform":"translate3d("+_ctx.cropOffsertX+"px,"+_ctx.cropOffsertY+"px,0)"})},[createBaseVNode("span",_hoisted_3,[createBaseVNode("img",{style:normalizeStyle({"width":_ctx.trueWidth+"px","height":_ctx.trueHeight+"px","transform":"scale("+_ctx.scale+","+_ctx.scale+") translate3d("+(_ctx.x-_ctx.cropOffsertX)/_ctx.scale+"px,"+(_ctx.y-_ctx.cropOffsertY)/_ctx.scale+"px,0)rotateZ("+_ctx.rotate*90+"deg)"}),src:_ctx.imgs,alt:"cropper-img"},null,12,_hoisted_4)]),createBaseVNode("span",{class:"cropper-face cropper-move",onMousedown:_cache[2]||(_cache[2]=function(){return _ctx.cropMove&&_ctx.cropMove.apply(_ctx,arguments);}),onTouchstart:_cache[3]||(_cache[3]=function(){return _ctx.cropMove&&_ctx.cropMove.apply(_ctx,arguments);})},null,32),_ctx.info?(openBlock(),createElementBlock("span",{key:0,class:"crop-info",style:normalizeStyle({"top":_ctx.cropInfo.top})},toDisplayString(_ctx.cropInfo.width)+" \xD7 "+toDisplayString(_ctx.cropInfo.height),5)):createCommentVNode("",true),!_ctx.fixedBox?(openBlock(),createElementBlock("span",_hoisted_5,[createBaseVNode("span",{class:"crop-line line-w",onMousedown:_cache[4]||(_cache[4]=function($event){return _ctx.changeCropSize($event,false,true,0,1);}),onTouchstart:_cache[5]||(_cache[5]=function($event){return _ctx.changeCropSize($event,false,true,0,1);})},null,32),createBaseVNode("span",{class:"crop-line line-a",onMousedown:_cache[6]||(_cache[6]=function($event){return _ctx.changeCropSize($event,true,false,1,0);}),onTouchstart:_cache[7]||(_cache[7]=function($event){return _ctx.changeCropSize($event,true,false,1,0);})},null,32),createBaseVNode("span",{class:"crop-line line-s",onMousedown:_cache[8]||(_cache[8]=function($event){return _ctx.changeCropSize($event,false,true,0,2);}),onTouchstart:_cache[9]||(_cache[9]=function($event){return _ctx.changeCropSize($event,false,true,0,2);})},null,32),createBaseVNode("span",{class:"crop-line line-d",onMousedown:_cache[10]||(_cache[10]=function($event){return _ctx.changeCropSize($event,true,false,2,0);}),onTouchstart:_cache[11]||(_cache[11]=function($event){return _ctx.changeCropSize($event,true,false,2,0);})},null,32),createBaseVNode("span",{class:"crop-point point1",onMousedown:_cache[12]||(_cache[12]=function($event){return _ctx.changeCropSize($event,true,true,1,1);}),onTouchstart:_cache[13]||(_cache[13]=function($event){return _ctx.changeCropSize($event,true,true,1,1);})},null,32),createBaseVNode("span",{class:"crop-point point2",onMousedown:_cache[14]||(_cache[14]=function($event){return _ctx.changeCropSize($event,false,true,0,1);}),onTouchstart:_cache[15]||(_cache[15]=function($event){return _ctx.changeCropSize($event,false,true,0,1);})},null,32),createBaseVNode("span",{class:"crop-point point3",onMousedown:_cache[16]||(_cache[16]=function($event){return _ctx.changeCropSize($event,true,true,2,1);}),onTouchstart:_cache[17]||(_cache[17]=function($event){return _ctx.changeCropSize($event,true,true,2,1);})},null,32),createBaseVNode("span",{class:"crop-point point4",onMousedown:_cache[18]||(_cache[18]=function($event){return _ctx.changeCropSize($event,true,false,1,0);}),onTouchstart:_cache[19]||(_cache[19]=function($event){return _ctx.changeCropSize($event,true,false,1,0);})},null,32),createBaseVNode("span",{class:"crop-point point5",onMousedown:_cache[20]||(_cache[20]=function($event){return _ctx.changeCropSize($event,true,false,2,0);}),onTouchstart:_cache[21]||(_cache[21]=function($event){return _ctx.changeCropSize($event,true,false,2,0);})},null,32),createBaseVNode("span",{class:"crop-point point6",onMousedown:_cache[22]||(_cache[22]=function($event){return _ctx.changeCropSize($event,true,true,1,2);}),onTouchstart:_cache[23]||(_cache[23]=function($event){return _ctx.changeCropSize($event,true,true,1,2);})},null,32),createBaseVNode("span",{class:"crop-point point7",onMousedown:_cache[24]||(_cache[24]=function($event){return _ctx.changeCropSize($event,false,true,0,2);}),onTouchstart:_cache[25]||(_cache[25]=function($event){return _ctx.changeCropSize($event,false,true,0,2);})},null,32),createBaseVNode("span",{class:"crop-point point8",onMousedown:_cache[26]||(_cache[26]=function($event){return _ctx.changeCropSize($event,true,true,2,2);}),onTouchstart:_cache[27]||(_cache[27]=function($event){return _ctx.changeCropSize($event,true,true,2,2);})},null,32)])):createCommentVNode("",true)],4),[[vShow,_ctx.cropping]])],544);}var VueCropper=/* @__PURE__ */_export_sfc(_sfc_main,[["render",_sfc_render],["__scopeId","data-v-be5e5ddc"]]);if(typeof window!=="undefined"&&window.Vue){window.Vue.createApp({}).component("VueCropper",VueCropper);}var upbtn="_upbtn_4fh9z_1";var uploadWarper="_uploadWarper_4fh9z_5";var bg="_bg_4fh9z_12";var btn="_btn_4fh9z_21";var btn1="_btn1_4fh9z_33";var img="_img_4fh9z_44";var btndiv="_btndiv_4fh9z_53";var wrapper="_wrapper_4fh9z_64";var styles={upbtn:upbtn,uploadWarper:uploadWarper,bg:bg,btn:btn,btn1:btn1,img:img,btndiv:btndiv,wrapper:wrapper};var ColCropper=defineComponent({name:"col-cropper",components:{VueCropper:VueCropper},props:{hideInput:{type:Boolean,default:false},option:{type:Object},onCancelTailor:{type:Function,default:function _default(){}},// 取消
- getBase64Data:{type:Function,default:function _default(){}},getBlob:{type:Function,default:function _default(){}},getFile:{type:Function,default:function _default(){}},imgOriginF:{type:Function,default:function _default(){}}},data:function data(){return{img:"",config:{ceilbutton:false,//顶部按钮,默认底部
- outputSize:1,//裁剪生成图片的质量
- outputType:"png",//裁剪生成图片的格式,默认png
- info:false,//裁剪框的大小信息
- canScale:true,//图片是否允许滚轮缩放
- autoCrop:false,//是否默认生成截图框
- autoCropWidth:0,//默认生成截图框宽度
- autoCropHeight:0,//默认生成截图框高度
- fixed:true,//是否开启截图框宽高固定比例
- fixedNumber:[1,1],//截图框的宽高比例
- full:false,//是否输出原图比例的截图
- fixedBox:true,//固定截图框大小 不允许改变
- canMove:true,//上传图片是否可以移动
- canMoveBox:false,//截图框能否拖动
- original:false,//上传图片按照原始比例渲染
- centerBox:true,//截图框是否被限制在图片里面
- high:true,//是否按照设备的dpr 输出等比例图片
- infoTrue:false,//true 为展示真实输出图片宽高 false 展示看到的截图框宽高
- maxImgSize:2000,//限制图片最大宽度和高度
- enlarge:1,//图片根据截图框输出比例倍数
- mode:"100%",//图片默认渲染方式
- cancelButtonText:"取消",//取消按钮文本
- confirmButtonText:"确定",//确定按钮文本
- cancelButtonBackgroundColor:"#606266",//取消按钮背景色
- confirmButtonBackgroundColor:"#ed594c",//确定按钮背景色
- cancelButtonTextColor:"#ffffff",//取消按钮字体色
- confirmButtonTextColor:"#ffffff"//确定按钮字体色
- }};},mounted:function mounted(){this.config=Object.assign(this.config,this.option);},methods:{//添加网格线
- addSlide:function addSlide(){if(document.getElementById("vertical")==null){var box=document.getElementsByClassName("cropper-crop-box")[0];//左网格线
- var verticalLeft=document.createElement("div");verticalLeft.id="vertical";verticalLeft.style.width="1px";verticalLeft.style.height="100%";verticalLeft.style.top="0px";verticalLeft.style.left="33%";verticalLeft.style.position="absolute";verticalLeft.style.backgroundColor="#fff";verticalLeft.style.zIndex="522";verticalLeft.style.opacity="0.5";//右网格线
- var verticalRight=document.createElement("div");verticalRight.style.width="1px";verticalRight.style.height="100%";verticalRight.style.top="0px";verticalRight.style.right="33%";verticalRight.style.position="absolute";verticalRight.style.backgroundColor="#fff";verticalRight.style.zIndex="522";verticalRight.style.opacity="0.5";//上网格线
- var verticalTop=document.createElement("div");verticalTop.style.width="100%";verticalTop.style.height="1px";verticalTop.style.top="33%";verticalTop.style.left="0px";verticalTop.style.position="absolute";verticalTop.style.backgroundColor="#fff";verticalTop.style.zIndex="522";verticalTop.style.opacity="0.5";//下网格线
- var verticalBottom=document.createElement("div");verticalBottom.style.width="100%";verticalBottom.style.height="1px";verticalBottom.style.bottom="33%";verticalBottom.style.left="0px";verticalBottom.style.position="absolute";verticalBottom.style.backgroundColor="#fff";verticalBottom.style.zIndex="522";verticalBottom.style.opacity="0.5";//左上边线
- var LeftTopSide=document.createElement("div");LeftTopSide.style.width="30px";LeftTopSide.style.height="4px";LeftTopSide.style.top="-4px";LeftTopSide.style.left="-4px";LeftTopSide.style.position="absolute";LeftTopSide.style.backgroundColor="#fff";LeftTopSide.style.zIndex="522";LeftTopSide.style.opacity="1";//上左边线
- var TopListSide=document.createElement("div");TopListSide.style.width="4px";TopListSide.style.height="30px";TopListSide.style.top="-4px";TopListSide.style.left="-4px";TopListSide.style.position="absolute";TopListSide.style.backgroundColor="#fff";TopListSide.style.zIndex="522";TopListSide.style.opacity="1";//右上边线
- var RightTopSide=document.createElement("div");RightTopSide.style.width="30px";RightTopSide.style.height="4px";RightTopSide.style.top="-4px";RightTopSide.style.right="-4px";RightTopSide.style.position="absolute";RightTopSide.style.backgroundColor="#fff";RightTopSide.style.zIndex="522";RightTopSide.style.opacity="1";//上右边线
- var TopRightSide=document.createElement("div");TopRightSide.style.width="4px";TopRightSide.style.height="30px";TopRightSide.style.top="-4px";TopRightSide.style.right="-4px";TopRightSide.style.position="absolute";TopRightSide.style.backgroundColor="#fff";TopRightSide.style.zIndex="522";TopRightSide.style.opacity="1";//左下边线
- var LeftBottomSide=document.createElement("div");LeftBottomSide.style.width="30px";LeftBottomSide.style.height="4px";LeftBottomSide.style.bottom="-4px";LeftBottomSide.style.left="-4px";LeftBottomSide.style.position="absolute";LeftBottomSide.style.backgroundColor="#fff";LeftBottomSide.style.zIndex="522";LeftBottomSide.style.opacity="1";//下左边线
- var BottomListSide=document.createElement("div");BottomListSide.style.width="4px";BottomListSide.style.height="30px";BottomListSide.style.bottom="-4px";BottomListSide.style.left="-4px";BottomListSide.style.position="absolute";BottomListSide.style.backgroundColor="#fff";BottomListSide.style.zIndex="522";BottomListSide.style.opacity="1";//右下边线
- var RightBottomSide=document.createElement("div");RightBottomSide.style.width="30px";RightBottomSide.style.height="4px";RightBottomSide.style.bottom="-4px";RightBottomSide.style.right="-4px";RightBottomSide.style.position="absolute";RightBottomSide.style.backgroundColor="#fff";RightBottomSide.style.zIndex="522";RightBottomSide.style.opacity="1";//下右边线
- var BottomRightSide=document.createElement("div");BottomRightSide.style.width="4px";BottomRightSide.style.height="30px";BottomRightSide.style.bottom="-4px";BottomRightSide.style.right="-4px";BottomRightSide.style.position="absolute";BottomRightSide.style.backgroundColor="#fff";BottomRightSide.style.zIndex="522";BottomRightSide.style.opacity="1";//一起生成
- box.appendChild(verticalLeft);box.appendChild(verticalRight);box.appendChild(verticalTop);box.appendChild(verticalBottom);box.appendChild(LeftTopSide);box.appendChild(TopListSide);box.appendChild(RightTopSide);box.appendChild(TopRightSide);box.appendChild(LeftBottomSide);box.appendChild(BottomListSide);box.appendChild(RightBottomSide);box.appendChild(BottomRightSide);}},//异步onload图片
- onLoadImg:function onLoadImg(photoUrl){return new Promise(function(resolve,reject){var reader=new FileReader();reader.readAsDataURL(photoUrl);reader.onload=function(e){resolve(e.target["result"]);};});},/**
- * 载入文件
- * template:
- * <h5-cropper hide-input ref="cropper">
- *
- * javascript:
- * this.$refs.cropper.loadFile()
- *
- * @param file
- */loadFile:function loadFile(file){var _this19=this;if(file instanceof File){this.onLoadImg(file).then(function(base64){_this19.img=base64;setTimeout(function(){_this19.config.autoCrop=true;_this19.addSlide();},10);});}else{throw new Error("Arguments file is not File");}},/**
- *
- * @param base64
- */loadBase64:function loadBase64(base64){var _this20=this;if(typeof base64!=="string"){throw new Error("Arguments base64 is not string");}var base=base64.split(",");if(!/^data:image\/(.*?);base64$/.test(base[0])){throw new Error("Arguments base64 MIME is not image/*");}// Base64 Regex @see https://learnku.com/articles/42295
- if(!/^[\/]?([\da-zA-Z]+[\/+]+)*[\da-zA-Z]+([+=]{1,2}|[\/])?$/.test(base[1])){throw new Error("Not standard base64");}this.img=base64;setTimeout(function(){_this20.config.autoCrop=true;_this20.addSlide();},10);},rotating:function rotating(e){this.$refs.cropper.rotateRight();// document.getElementsByClassName("cropper-modal")[0].style = "background-color: rgba(0,0,0,0.5);transition: 0.88s";
- },canceltailor:function canceltailor(){this.img="";this.onCancelTailor();},tailoring:function tailoring(){var _this21=this;// 获取截图的base64数据
- this.$refs.cropper.getCropData(function(data){_this21.getBase64Data(data);_this21.getBlob(data);_this21.img="";_this21.config.autoCrop=false;});// 获取截图的blob数据
- this.$refs.cropper.getCropBlob(function(data){_this21.getBase64Data(data);_this21.getBlob(data);// Blob 转 File
- var suffix={jpeg:"jpg",png:"png",webp:"webp"}[_this21.config.outputType];var time=new Date().getTime();var file=new File([data],"".concat(time,".").concat(suffix),{type:"image/".concat(_this21.config.outputType)});_this21.getFile(file);_this21.img="";_this21.config.autoCrop=false;});},upPhoto:function upPhoto(e){var _this22=this;return _asyncToGenerator(/*#__PURE__*/regeneratorRuntime.mark(function _callee2(){var photoUrl;return regeneratorRuntime.wrap(function _callee2$(_context2){while(1){switch(_context2.prev=_context2.next){case 0:photoUrl=e.target.files[0];_this22.$refs.headInput.value=null;if(!(photoUrl!=undefined)){_context2.next=9;break;}_this22.imgOriginF(photoUrl);_context2.next=6;return _this22.onLoadImg(photoUrl);case 6:_this22.img=_context2.sent;_this22.config.autoCrop=true;setTimeout(function(){_this22.addSlide();},20);case 9:case"end":return _context2.stop();}}},_callee2);}))();},onCropMoving:function onCropMoving(e){// console.log('onCropMoving')
- },onImgMoving:function onImgMoving(e){// console.log('onCropMoving')
- }},render:function render(){return createVNode("div",{"class":[styles.upbtn,styles.uploadWarper]},[this.hideInput,!this.hideInput?createVNode("input",{"style":"opacity: 0;","class":styles.upbtn,"type":"file","accept":"image/*","onChange":this.upPhoto,"ref":"headInput"},null):null,this.img!=''?createVNode("div",{"class":styles.bg},[this.config.ceilbutton?createVNode("div",{"class":styles.btndiv},[createVNode("div",{"class":styles.btn,"onClick":this.canceltailor,"style":{backgroundColor:this.config.cancelButtonBackgroundColor,color:this.config.cancelButtonTextColor}},[this.config.cancelButtonText]),createVNode("div",{"class":styles.img,"onClick":this.rotating},null),createVNode("div",{"class":styles.btn,"onClick":this.tailoring,"style":{backgroundColor:this.config.confirmButtonBackgroundColor,color:this.config.confirmButtonTextColor}},[this.config.confirmButtonText])]):null,createVNode("div",{"class":styles.wrapper},[createVNode(VueCropper,{"ref":"cropper","img":this.img,"outputSize":this.config.outputSize,"outputType":this.config.outputType,"info":this.config.info,"canScale":this.config.canScale,"autoCrop":this.config.autoCrop,"autoCropWidth":this.config.autoCropWidth,"autoCropHeight":this.config.autoCropHeight,"fixedBox":this.config.fixedBox,"fixed":this.config.fixed,"fixedNumber":this.config.fixedNumber,"full":this.config.full,"canMove":this.config.canMove,"canMoveBox":this.config.canMoveBox,"original":this.config.original,"centerBox":this.config.centerBox,"high":this.config.high,"infoTrue":this.config.infoTrue,"maxImgSize":this.config.maxImgSize,"enlarge":this.config.enlarge,"mode":this.config.mode,"onCropMoving":this.onCropMoving,"onImgMoving":this.onImgMoving},null)]),!this.config.ceilbutton?createVNode("div",{"class":styles.btndiv},[createVNode("div",{"class":styles.btn,"onClick":this.canceltailor,"style":{backgroundColor:this.config.cancelButtonBackgroundColor,color:this.config.cancelButtonTextColor}},[this.config.cancelButtonText]),createVNode("div",{"class":styles.img,"onClick":this.rotating},null),createVNode("div",{"class":styles.btn,"onClick":this.tailoring,"style":{backgroundColor:this.config.confirmButtonBackgroundColor,color:this.config.confirmButtonTextColor}},[this.config.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ABxQSr0ai34J4La1AIjobinlZ7HtXwAu2QiAUaWUvRNscdlCWoG5wDjT09OT6+3tPV8qlbJCiD9aRCp5CgCcXVpayg8MDPyttU4DOMHM25vEawAeVEp9EKeq0YobEQGr8aJSyt4XKJfLmVqttp+Z9zDzZUQ04TjOS/l8fuX4nZqauiKVStlD6/KNioC9w22vD7mue6yFKGz1V6vVTwHc3soOQFspqGtFzHywu7t7OJvNVpoXmJ6evsVxnLcAtOqSutt/Aqg72/ayrTYhhLAP0M3MvBPAnQkvNKvzL4Ckt+E6kU08fUgp9Xzd2j5ITgHIJXbv0JCIHpNS2lN1ZVAYhi8YYxpEHeqv5z6fyWQKfX19fzYAJicnuzOZzEcAdq3n3eH8OSHEfa7r2k5pjMarWGt9l30VE1H9Vdzheg13w8ynUqnUe7lcbqZZ9B/GxP8H1HlPxgAAAABJRU5ErkJggg==";var ColUpload=exports('c',defineComponent({name:'col-upload',props:{modelValue:String,tips:{type:String,default:'点击上传'},deletable:{type:Boolean,default:true},cropper:{// 是否进行裁切
- type:Boolean,default:false},options:{// 裁切需要参数
- type:Object,default:{}},onUploadChange:{type:Function,default:function _default(url){}}},methods:{beforeRead:function beforeRead(file){var isLt2M=file.size/1024/1024<5;if(!isLt2M){Toast('上传文件大小不能超过 5MB');return false;}return true;},beforeDelete:function beforeDelete(file,detail){// this.dataModel.splice(detail.index, 1)
- return true;},afterRead:function afterRead(file,detail){var _this23=this;return _asyncToGenerator(/*#__PURE__*/regeneratorRuntime.mark(function _callee3(){var formData,res;return regeneratorRuntime.wrap(function _callee3$(_context3){while(1){switch(_context3.prev=_context3.next){case 0:_context3.prev=0;file.status='uploading';file.message='上传中...';formData=new FormData();formData.append('file',file.file);_context3.next=7;return request.post('/api-teacher/uploadFile',{data:formData});case 7:res=_context3.sent;_this23.$emit('update:modelValue',res.data.url);_this23.onUploadChange(res.data.url);_context3.next=14;break;case 12:_context3.prev=12;_context3.t0=_context3["catch"](0);case 14:case"end":return _context3.stop();}}},_callee3,null,[[0,12]]);}))();},onClose:function onClose(e){this.$emit('update:modelValue',null);this.onUploadChange();e.stopPropagation();},getFile:function getFile(file){var _this24=this;return _asyncToGenerator(/*#__PURE__*/regeneratorRuntime.mark(function _callee4(){var formData,res;return regeneratorRuntime.wrap(function _callee4$(_context4){while(1){switch(_context4.prev=_context4.next){case 0:_context4.prev=0;formData=new FormData();formData.append('file',file);_context4.next=5;return request.post('/api-teacher/uploadFile',{data:formData});case 5:res=_context4.sent;_this24.$emit('update:modelValue',res.data.url);_this24.onUploadChange(res.data.url);_context4.next=12;break;case 10:_context4.prev=10;_context4.t0=_context4["catch"](0);case 12:case"end":return _context4.stop();}}},_callee4,null,[[0,10]]);}))();}},render:function render(){var _this25=this;useCustomFieldValue(function(){return _this25.modelValue;});return createVNode("div",{"class":styles$1['uploader-section']},[this.modelValue&&this.deletable?createVNode(Icon,{"name":"cross","onClick":this.onClose,"class":styles$1["img-close"]},null):null,this.cropper?createVNode("div",{"class":styles$1['col-uploader']},[this.modelValue?createVNode(Image$1,{"fit":"cover","position":"center","class":styles$1.uploadImg,"src":this.modelValue},null):createVNode("div",{"class":styles$1.uploader},[createVNode(Icon,{"name":iconUploader,"size":"32"},null),createVNode("p",{"class":styles$1.uploaderText},[this.tips])]),createVNode(ColCropper,{"option":this.options,"getFile":this.getFile},null)]):// @ts-ignore
- createVNode(Uploader,{"afterRead":this.afterRead,"beforeRead":this.beforeRead,"beforeDelete":this.beforeDelete},{default:function _default(){return _this25.modelValue?createVNode(Image$1,{"fit":"cover","position":"center","class":styles$1.uploadImg,"src":_this25.modelValue},null):createVNode("div",{"class":styles$1.uploader},[createVNode(Icon,{"name":iconUploader,"size":"32"},null),createVNode("p",{"class":styles$1.uploaderText},[_this25.tips])]);}})]);}}));}};});})();
|