@xysfe/actui
Version:
A fantastic mobile ui lib implement by Vue
1 lines • 29.2 kB
JavaScript
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("@xysfe/actui/es/assets/utils/create/index.js"),require("@xysfe/actui/es/assets/mixins/visible.js"),require("@xysfe/actui/es/assets/utils/helpers.js"),require("@xysfe/actui/es/assets/common/popup.js"),require("@xysfe/actui/es/assets/common/goldlayer.js"),require("@xysfe/actui/es/assets/common/scrollZoom/index.js")):"function"==typeof define&&define.amd?define(["@xysfe/actui/es/assets/utils/create/index.js","@xysfe/actui/es/assets/mixins/visible.js","@xysfe/actui/es/assets/utils/helpers.js","@xysfe/actui/es/assets/common/popup.js","@xysfe/actui/es/assets/common/goldlayer.js","@xysfe/actui/es/assets/common/scrollZoom/index.js"],e):"object"==typeof exports?exports.GoldProtocolLayer=e(require("@xysfe/actui/es/assets/utils/create/index.js"),require("@xysfe/actui/es/assets/mixins/visible.js"),require("@xysfe/actui/es/assets/utils/helpers.js"),require("@xysfe/actui/es/assets/common/popup.js"),require("@xysfe/actui/es/assets/common/goldlayer.js"),require("@xysfe/actui/es/assets/common/scrollZoom/index.js")):t.GoldProtocolLayer=e(t["@xysfe/actui/es/assets/utils/create/index.js"],t["@xysfe/actui/es/assets/mixins/visible.js"],t["@xysfe/actui/es/assets/utils/helpers.js"],t["@xysfe/actui/es/assets/common/popup.js"],t["@xysfe/actui/es/assets/common/goldlayer.js"],t["@xysfe/actui/es/assets/common/scrollZoom/index.js"])}("undefined"!=typeof self?self:this,function(t,e,n,r,o,i){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="../es",e(e.s=2312)}({0:function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},1:function(t,e,n){var r=n(32)("wks"),o=n(26),i=n(0).Symbol,s="function"==typeof i;(t.exports=function(t){return r[t]||(r[t]=s&&i[t]||(s?i:o)("Symbol."+t))}).store=r},10:function(t,e,n){var r=n(4),o=n(41),i=n(39),s=Object.defineProperty;e.f=n(3)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return s(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},11:function(t,e){t.exports={}},12:function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},126:function(t,e){t.exports=r},1293:function(t,e,n){"use strict";var r=n(956),o=n(38),i=n.n(o),s=n(126),c=n.n(s),a=n(960);e.a={name:"ActGoldProtocolLayer",mixins:[i.a],components:{ActGoldProtocol:r.a,ActPopup:c.a,ActGoldReadTerms:a.a},props:{title:{type:String,default:""},closable:{type:Boolean,default:!1},protocols:{type:Array,default:function(){return[]}},zIndex:{type:Number,default:99},cancelBtnText:{type:String,default:"取消"},comfirmBtnText:{type:String,default:"继续投保"},forceReadToPageEnd:{type:Boolean,default:!1},forceReadSeconds:{type:Number,default:0},brandColor:{type:String,default:"#8c7fee"},readTerms:{type:Array,default:function(){return[]}},beforeClose:{type:Function,default:null},needForceRead:{type:Boolean,default:!0},isCps:{type:Boolean,default:!1},beforePreOrNext:{type:Function,default:null},openInWindow:{type:Boolean,default:!1}},data:function(){return{protocolChecked:!1,hasForceRead:!1}},computed:{confirmBtnBg:function(){return this.isCps?this.protocolChecked?"linear-gradient( 270deg, #F05A4B 0%, #FC7468 100%)":"linear-gradient( 270deg, rgba(240,90,75,0.5) 0%, rgba(252,116,104,0.5) 100%)":this.protocolChecked?"linear-gradient( 90deg, #FF738D 0%, #FF465E 100%)":"linear-gradient( 90deg, rgba(255,115,141,0.5) 0%, rgba(255,70,94,0.5) 100%)"},backgroundClass:function(){return this.isCps?"bg-cps":"bg-main"}},methods:{toggle:function(t){this.protocolChecked=t},forceReadTerms:function(){this.readTerms&&this.readTerms.length&&this.needForceRead&&!this.hasForceRead?this.$refs.forceReadTermsRef&&this.$refs.forceReadTermsRef.show():this.$emit("confirm")},maskClick:function(){this.$emit("maskClick")},cancel:function(){this.$emit("cancel"),this.hide()},confirm:function(){this.protocolChecked&&this.forceReadTerms()},readTermsCompleted:function(){this.hasForceRead=!0,this.$emit("readTermsCompleted"),this.$emit("confirm")},readTermsCancel:function(){this.hasForceRead=!1,this.$emit("readTermsCancel")}}}},13:function(t,e,n){var r=n(34),o=n(15);t.exports=function(t){return r(o(t))}},14:function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},140:function(t,e,n){t.exports={default:n(142),__esModule:!0}},142:function(t,e,n){n(52),n(48),t.exports=n(143)},143:function(t,e,n){var r=n(4),o=n(57);t.exports=n(2).getIterator=function(t){var e=o(t);if("function"!=typeof e)throw TypeError(t+" is not iterable!");return r(e.call(t))}},15:function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},159:function(t,e){t.exports=o},16:function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},17:function(t,e,n){var r=n(19);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}},18:function(t,e){t.exports=!0},19:function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},2:function(t,e){var n=t.exports={version:"2.6.12"};"number"==typeof __e&&(__e=n)},20:function(t,e,n){var r=n(32)("keys"),o=n(26);t.exports=function(t){return r[t]||(r[t]=o(t))}},22:function(t,e,n){var r=n(6),o=n(0).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},2312:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(28),o=n.n(r),i=n(2313);i.a.install=function(t){t.component(i.a.name,i.a),t.prototype.$createGoldProtocolLayer=o()(i.a,t)},e.default=i.a},2313:function(t,e,n){"use strict";function r(t){c||n(2314)}var o=n(1293),i=n(2315),s=n(7),c=!1,a=r,u=Object(s.a)(o.a,i.a,i.b,!1,a,"data-v-0bf60312",null);u.options.__file="src\\components\\GoldProtocolLayer\\src\\index.vue",e.a=u.exports},2314:function(t,e){},2315:function(t,e,n){"use strict";n.d(e,"a",function(){return r}),n.d(e,"b",function(){return o});var r=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("transition",{attrs:{name:"act-picker-fade"}},[n("act-popup",{directives:[{name:"show",rawName:"v-show",value:t.isVisible,expression:"isVisible"}],attrs:{type:"picker",mask:!0,center:!1,topBorderRadius:!0,zIndex:t.zIndex},on:{touchmove:function(t){t.preventDefault()},"mask-click":t.maskClick}},[n("transition",{attrs:{name:"act-picker-move"}},[n("div",{staticClass:"act-picker-panel",on:{click:function(t){t.stopPropagation()}}},[n("div",{ref:"boxWrapper",staticClass:"act-picker-content",class:t.backgroundClass},[n("act-gold-protocol",{ref:"protocol",staticClass:"protocol",attrs:{protocols:t.protocols,openInWindow:t.openInWindow,brandColor:t.brandColor,checkState:t.protocolChecked},on:{toggle:t.toggle}})],1),t._v(" "),n("div",{staticClass:"ft-btn"},[n("div",{staticClass:"cancel-btn",on:{click:t.cancel}},[t._v(t._s(t.cancelBtnText))]),t._v(" "),n("div",{staticClass:"comfirm-btn",style:{background:t.confirmBtnBg},on:{click:t.confirm}},[t._v(t._s(t.comfirmBtnText))])]),t._v(" "),n("div",{staticClass:"footer iphonex_padding",staticStyle:{"background-color":"#fff"}})])])],1)],1),t._v(" "),n("act-gold-read-terms",{ref:"forceReadTermsRef",attrs:{confirmButtonText:"已完整阅读并确认",forceRead:t.forceReadToPageEnd,forceReadTime:t.forceReadSeconds,brandColor:t.brandColor,readTerms:t.readTerms,beforePreOrNext:t.beforePreOrNext,beforeClose:t.beforeClose},on:{confirm:t.readTermsCompleted,cancel:t.readTermsCancel}})],1)},o=[];r._withStripped=!0},25:function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},26:function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},28:function(e,n){e.exports=t},29:function(t,e,n){var r=n(10).f,o=n(8),i=n(1)("toStringTag");t.exports=function(t,e,n){t&&!o(t=n?t:t.prototype,i)&&r(t,i,{configurable:!0,value:e})}},3:function(t,e,n){t.exports=!n(12)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},30:function(t,e,n){var r=n(42),o=n(33);t.exports=Object.keys||function(t){return r(t,o)}},31:function(t,e,n){var r=n(15);t.exports=function(t){return Object(r(t))}},32:function(t,e,n){var r=n(2),o=n(0),i=o["__core-js_shared__"]||(o["__core-js_shared__"]={});(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:r.version,mode:n(18)?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},33:function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},34:function(t,e,n){var r=n(14);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},35:function(t,e,n){var r=n(16),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},37:function(t,e,n){"use strict";var r=n(18),o=n(9),i=n(55),s=n(5),c=n(11),a=n(60),u=n(29),l=n(62),f=n(1)("iterator"),d=!([].keys&&"next"in[].keys()),h=function(){return this};t.exports=function(t,e,n,p,m,v,x){a(n,e,p);var y,g,b,T=function(t){if(!d&&t in k)return k[t];switch(t){case"keys":case"values":return function(){return new n(this,t)}}return function(){return new n(this,t)}},_=e+" Iterator",C="values"==m,S=!1,k=t.prototype,I=k[f]||k["@@iterator"]||m&&k[m],w=I||T(m),R=m?C?T("entries"):w:void 0,P="Array"==e?k.entries||I:I;if(P&&(b=l(P.call(new t)))!==Object.prototype&&b.next&&(u(b,_,!0),r||"function"==typeof b[f]||s(b,f,h)),C&&I&&"values"!==I.name&&(S=!0,w=function(){return I.call(this)}),r&&!x||!d&&!S&&k[f]||s(k,f,w),c[e]=w,c[_]=h,m)if(y={values:C?w:T("values"),keys:v?w:T("keys"),entries:R},x)for(g in y)g in k||i(k,g,y[g]);else o(o.P+o.F*(d||S),e,y);return y}},38:function(t,n){t.exports=e},39:function(t,e,n){var r=n(6);t.exports=function(t,e){if(!r(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!r(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},4:function(t,e,n){var r=n(6);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},40:function(t,e){t.exports=n},41:function(t,e,n){t.exports=!n(3)&&!n(12)(function(){return 7!=Object.defineProperty(n(22)("div"),"a",{get:function(){return 7}}).a})},42:function(t,e,n){var r=n(8),o=n(13),i=n(46)(!1),s=n(20)("IE_PROTO");t.exports=function(t,e){var n,c=o(t),a=0,u=[];for(n in c)n!=s&&r(c,n)&&u.push(n);for(;e.length>a;)r(c,n=e[a++])&&(~i(u,n)||u.push(n));return u}},43:function(t,e,n){var r=n(0).document;t.exports=r&&r.documentElement},45:function(t,e,n){var r=n(14),o=n(1)("toStringTag"),i="Arguments"==r(function(){return arguments}()),s=function(t,e){try{return t[e]}catch(t){}};t.exports=function(t){var e,n,c;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=s(e=Object(t),o))?n:i?r(e):"Object"==(c=r(e))&&"function"==typeof e.callee?"Arguments":c}},46:function(t,e,n){var r=n(13),o=n(35),i=n(47);t.exports=function(t){return function(e,n,s){var c,a=r(e),u=o(a.length),l=i(s,u);if(t&&n!=n){for(;u>l;)if((c=a[l++])!=c)return!0}else for(;u>l;l++)if((t||l in a)&&a[l]===n)return t||l||0;return!t&&-1}}},47:function(t,e,n){var r=n(16),o=Math.max,i=Math.min;t.exports=function(t,e){return t=r(t),t<0?o(t+e,0):i(t,e)}},48:function(t,e,n){"use strict";var r=n(59)(!0);n(37)(String,"String",function(t){this._t=String(t),this._i=0},function(){var t,e=this._t,n=this._i;return n>=e.length?{value:void 0,done:!0}:(t=r(e,n),this._i+=t.length,{value:t,done:!1})})},5:function(t,e,n){var r=n(10),o=n(25);t.exports=n(3)?function(t,e,n){return r.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},52:function(t,e,n){n(68);for(var r=n(0),o=n(5),i=n(11),s=n(1)("toStringTag"),c="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),a=0;a<c.length;a++){var u=c[a],l=r[u],f=l&&l.prototype;f&&!f[s]&&o(f,s,u),i[u]=i.Array}},53:function(t,e,n){var r=n(4),o=n(61),i=n(33),s=n(20)("IE_PROTO"),c=function(){},a=function(){var t,e=n(22)("iframe"),r=i.length;for(e.style.display="none",n(43).appendChild(e),e.src="javascript:",t=e.contentWindow.document,t.open(),t.write("<script>document.F=Object<\/script>"),t.close(),a=t.F;r--;)delete a.prototype[i[r]];return a()};t.exports=Object.create||function(t,e){var n;return null!==t?(c.prototype=r(t),n=new c,c.prototype=null,n[s]=t):n=a(),void 0===e?n:o(n,e)}},55:function(t,e,n){t.exports=n(5)},57:function(t,e,n){var r=n(45),o=n(1)("iterator"),i=n(11);t.exports=n(2).getIteratorMethod=function(t){if(void 0!=t)return t[o]||t["@@iterator"]||i[r(t)]}},59:function(t,e,n){var r=n(16),o=n(15);t.exports=function(t){return function(e,n){var i,s,c=String(o(e)),a=r(n),u=c.length;return a<0||a>=u?t?"":void 0:(i=c.charCodeAt(a),i<55296||i>56319||a+1===u||(s=c.charCodeAt(a+1))<56320||s>57343?t?c.charAt(a):i:t?c.slice(a,a+2):s-56320+(i-55296<<10)+65536)}}},6:function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},60:function(t,e,n){"use strict";var r=n(53),o=n(25),i=n(29),s={};n(5)(s,n(1)("iterator"),function(){return this}),t.exports=function(t,e,n){t.prototype=r(s,{next:o(1,n)}),i(t,e+" Iterator")}},61:function(t,e,n){var r=n(10),o=n(4),i=n(30);t.exports=n(3)?Object.defineProperties:function(t,e){o(t);for(var n,s=i(e),c=s.length,a=0;c>a;)r.f(t,n=s[a++],e[n]);return t}},62:function(t,e,n){var r=n(8),o=n(31),i=n(20)("IE_PROTO"),s=Object.prototype;t.exports=Object.getPrototypeOf||function(t){return t=o(t),r(t,i)?t[i]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?s:null}},63:function(t,e){t.exports=function(t,e){return{value:e,done:!!t}}},68:function(t,e,n){"use strict";var r=n(69),o=n(63),i=n(11),s=n(13);t.exports=n(37)(Array,"Array",function(t,e){this._t=s(t),this._i=0,this._k=e},function(){var t=this._t,e=this._k,n=this._i++;return!t||n>=t.length?(this._t=void 0,o(1)):"keys"==e?o(0,n):"values"==e?o(0,t[n]):o(0,[n,t[n]])},"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},69:function(t,e){t.exports=function(){}},7:function(t,e,n){"use strict";function r(t,e,n,r,o,i,s,c){t=t||{};var a=typeof t.default;"object"!==a&&"function"!==a||(t=t.default);var u="function"==typeof t?t.options:t;e&&(u.render=e,u.staticRenderFns=n,u._compiled=!0),r&&(u.functional=!0),i&&(u._scopeId=i);var l;if(s?(l=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),o&&o.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(s)},u._ssrRegister=l):o&&(l=c?function(){o.call(this,this.$root.$options.shadowRoot)}:o),l)if(u.functional){u._injectStyles=l;var f=u.render;u.render=function(t,e){return l.call(e),f(t,e)}}else{var d=u.beforeCreate;u.beforeCreate=d?[].concat(d,l):[l]}return{exports:t,options:u}}e.a=r},790:function(t,e){t.exports=i},8:function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},874:function(t,e,n){"use strict";var r=n(40);n.n(r);e.a={name:"ActGoldProtocol",data:function(){return{protocolChecked:this.checkState}},props:{text:{type:String,default:"本人已阅读并同意"},tips:{type:String,default:""},protocols:{type:Array,default:function(){return[]}},checkState:{type:Boolean,default:!0},showCheckBox:{type:Boolean,default:!0},textColor:{type:String,default:"#666"},textFontSize:{type:[Number,String],default:13},openInWindow:{type:Boolean,default:!1},brandColor:{type:String,default:"#8c7fee"},zIndex:{type:[String,Number],default:999},disableChecked:{type:Boolean,default:!1}},computed:{fontSize:function(){return Object(r.formatFontSize)(this.textFontSize)}},methods:{getCheckBoxState:function(){return!!this.protocolChecked},onClick:function(t){var e=this,n=!1;if((n=t.openInWindow?t.openInWindow:!1!==t.openInWindow&&this.openInWindow)&&t.data){if(Object(r.isArray)(t.data)&&1===t.data.length&&t.data[0].src)return this.openUrl(t.data[0].src);if(!Object(r.isArray)(t.data)&&t.data.src)return this.openUrl(t.data.src)}this.docPop&&this.docPop.remove(),this.docPop=this.$createDocPop({zIndex:this.zIndex,title:t.title,docData:this.docData(t),brandColor:this.brandColor,openInWindow:n},function(t){return[t("template",{slot:"content"},[e.$slots.content])]}).show()},docData:function(t){return Object(r.isArray)(t.data)?t.data:[t.data]},protocolToggle:function(){this.disableChecked||(this.protocolChecked=!this.protocolChecked,this.$emit("toggle",this.protocolChecked))},openUrl:function(t){r.ua.isMobile||r.ua.isWx?location.href=t:window.open(t,"_blank")}},watch:{checkState:function(t){this.protocolChecked=t}}}},895:function(t,e,n){"use strict";var r=n(962),o=n.n(r),i=n(140),s=n.n(i),c=n(159),a=n.n(c),u=n(790),l=n.n(u),f=n(38),d=n.n(f);e.a={name:"ActGoldReadTerms",mixins:[d.a],components:{scrollZoom:l.a,ActGoldLayer:a.a},data:function(){return{curIndex:1,readState:[],termsInfo:[],readTimer:null,countdown:0,prevTime:void 0}},computed:{readTermsLength:function(){return this.readTerms.length},bookTitle:function(){var t=this.termsInfo[this.curIndex-1]&&this.termsInfo[this.curIndex-1].title;return t?"《"+t+"》":""},comfirmText:function(){var t=this.confirmButtonText||"已完整阅读并确认"+this.bookTitle,e=void 0;return this.readTimer&&(e=(this.confirmButtonText?this.confirmButtonText:"已完整阅读并确认")+"("+this.countdown+"s)"),e||t},curForceReadToPageEnd:function(){return this.termsInfo[this.curIndex-1].hasOwnProperty("forceReadToPageEnd")?this.termsInfo[this.curIndex-1].forceReadToPageEnd:this.forceRead||!1},curForceReadSeconds:function(){return this.termsInfo[this.curIndex-1].hasOwnProperty("forceReadSeconds")?this.termsInfo[this.curIndex-1].forceReadSeconds:this.forceReadTime||0}},props:{readTerms:{type:Array,default:function(){return[]}},forceRead:{type:Boolean,default:!0},forceReadTime:{type:Number,default:0},confirmButtonText:{type:String,default:""},cancelButtonText:{type:String,default:"暂不同意"},brandColor:{type:String,default:"#8c7fee"},beforeClose:{type:Function,default:null},beforePreOrNext:{type:Function,default:null}},methods:{getTerms:function(t){for(var e=[],n=t,r=Array.isArray(n),o=0,n=r?n:s()(n);;){var i;if(r){if(o>=n.length)break;i=n[o++]}else{if(o=n.next(),o.done)break;i=o.value}var c=i,a={type:Number(c.type),title:c.title,urls:c.urls,innerHTML:c.innerHTML||"",souceFile:c.src,init:!1,classObject:{"scroll-pdf":!1,"scroll-word":!1},myScroll:null,styleImg:{height:"auto"},freeScroll:!0,scrollbar:{fade:!0,interactive:!0},bounce:{bottom:!1,left:!1,right:!1,top:!1},zoom:!0,listenScrollInit:!0,listenScrollEnd:!0,listenZoomEnd:!1,listenScroll:!1,mouseWheel:!0,currentScale:1,scrollY:0,cWidth:0,cHeight:0,liTag:null,wordHtml:""};c.hasOwnProperty("forceReadToPageEnd")&&(a.forceReadToPageEnd=!!+c.forceReadToPageEnd),c.hasOwnProperty("forceReadSeconds")&&(a.forceReadSeconds=+c.forceReadSeconds),e.push(a)}this.termsInfo=e},showDoc:function(t){var e=this;this.$nextTick(function(){e.$refs.scrollZoom.showDoc(t)})},changeHeaderBtnsColor:function(t){var e=this,n=this.$refs,r=n.prevbtn,o=n.nextbtn,i=function(){e.readTimer?o.style.color="":o.style.color=e.brandColor};1==~~t&&~~t<this.readTermsLength?(r&&(r.style.color=""),o&&i()):~~t>1&&~~t<this.readTermsLength?(r&&(r.style.color=this.brandColor),o&&i()):~~t>1&&~~t===this.readTermsLength&&(r&&(r.style.color=this.brandColor),o&&(o.style.color=""))},handleActionBeforePreOrNext:function(t,e){function n(t){o.curIndex>1&&(o.curIndex=i-1)}function r(t){o.curIndex<o.readTermsLength&&o.next(t)}var o=this,i=~~this.curIndex,s=this.termsInfo[i-1];this.beforePreOrNext?this.beforePreOrNext({action:t,next:function(o){!1!==o&&("prevClick"===t&&n(e),"nextClick"===t&&r(e))},curTermsInfo:s,curIndex:o.curIndex,readTermsLength:o.readTermsLength,isLast:o.curIndex===o.readTermsLength,curIsReadEnd:o.readState[o.curIndex-1].readEnd}):("prevClick"===t&&n(e),"nextClick"===t&&r(e))},handlePrev:function(t){1!==this.curIndex&&(this.readTimer&&this.resetReadTimer(),this.handleActionBeforePreOrNext("prevClick",t))},handleNext:function(t){this.readTimer||this.handleActionBeforePreOrNext("nextClick",t)},beforeShowDoc:function(t){+this.curForceReadSeconds>0&&!this.readState[t-1].readEnough&&this.setReadTimer(),this.changeHeaderBtnsColor(t),this.getCurTermInfo({curIndex:t,isReadEnd:this.readState[t-1].readEnd,totalLegth:this.readTermsLength,curTerm:this.termsInfo[t-1]}),!this.curForceReadToPageEnd&&!this.curForceReadSeconds&&1==~~this.readTermsLength&&this.canINext(!0)},timerFn:function(t){if(this.prevTime){if(t-this.prevTime>1e3){if(!(this.countdown>0))return this.countdown=0,this.readState[this.curIndex-1].readEnough=!0,this.changeHeaderBtnsColor(this.curIndex),void this.resetReadTimer();this.prevTime=t,this.countdown=--this.countdown}}else this.prevTime=t;this.readTimer=requestAnimationFrame(this.timerFn)},setReadTimer:function(){this.readTimer&&this.resetReadTimer(),this.countdown=o()(this.curForceReadSeconds),this.readTimer=requestAnimationFrame(this.timerFn),this.changeHeaderBtnsColor()},resetReadTimer:function(){cancelAnimationFrame(this.readTimer),this.readTimer=null},next:function(t){var e=~~this.curIndex;!this.curForceReadToPageEnd&&this.canINext(!0),this.curForceReadToPageEnd&&this.readState[e-1].readEnd||!this.curForceReadToPageEnd?e<this.readTermsLength&&(this.curIndex=e+1,this.showDoc(e)):this.curForceReadToPageEnd&&!this.readState[e-1].readEnd&&this.showToast("请观看至页面底部,完整阅读全部内容")},getCurTermInfo:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.$emit("getCurTermInfo",t)},canINext:function(t){this.readTermsLength&&(this.readState[this.curIndex-1].readEnd=t,this.getCurTermInfo({curIndex:this.curIndex,isReadEnd:this.readState[this.curIndex-1].readEnd,totalLegth:this.readTermsLength,curTerm:this.termsInfo.length&&this.termsInfo[this.curIndex-1]}))},confirm:function(t){if(!this.readTimer){this.curForceReadToPageEnd&&!this.readState[this.readTermsLength-1].readEnd&&this.curIndex<=this.readTermsLength||!this.curForceReadToPageEnd&&this.curIndex<this.readTermsLength?this.next(t):this.handleAction("confirm",t)}},cancel:function(t){this.handleAction("cancel",t)},handleAction:function(t,e){var n=this,r=this.termsInfo[this.curIndex-1];this.beforeClose?this.beforeClose(t,function(r){!1!==r&&(n.hide(),n.$emit(t,e))},r):(this.hide(),this.$emit(t,e))},showToast:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3e3;this.hideToast(),this.toast||(this.toast=this.$createToast()),this.toast.show(t,e)},hideToast:function(){this.toast&&this.toast.hide()},preventMove:function(t){t._prevent=!0},reset:function(){this.curIndex=1,this.readState=new Array(this.readTermsLength).fill(void 0).map(function(t){return{readEnd:!1,readEnough:!1}})}},mounted:function(){this.changeHeaderBtnsColor(this.curIndex)},watch:{isVisible:function(t){t&&(this.reset(),this.getTerms(this.readTerms),this.beforeShowDoc(this.curIndex),this.showDoc(0)),!1==!!t&&this.resetReadTimer()},curIndex:function(t){this.beforeShowDoc(t)}}}},896:function(t,e){t.exports="\t\n\v\f\r \u2028\u2029\ufeff"},9:function(t,e,n){var r=n(0),o=n(2),i=n(17),s=n(5),c=n(8),a=function(t,e,n){var u,l,f,d=t&a.F,h=t&a.G,p=t&a.S,m=t&a.P,v=t&a.B,x=t&a.W,y=h?o:o[e]||(o[e]={}),g=y.prototype,b=h?r:p?r[e]:(r[e]||{}).prototype;h&&(n=e);for(u in n)(l=!d&&b&&void 0!==b[u])&&c(y,u)||(f=l?b[u]:n[u],y[u]=h&&"function"!=typeof b[u]?n[u]:v&&l?i(f,r):x&&b[u]==f?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e.prototype=t.prototype,e}(f):m&&"function"==typeof f?i(Function.call,f):f,m&&((y.virtual||(y.virtual={}))[u]=f,t&a.R&&g&&!g[u]&&s(g,u,f)))};a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,t.exports=a},956:function(t,e,n){"use strict";function r(t){c||n(957)}var o=n(874),i=n(958),s=n(7),c=!1,a=r,u=Object(s.a)(o.a,i.a,i.b,!1,a,"data-v-1da413b4",null);u.options.__file="src\\components\\GoldProtocol\\src\\index.vue",e.a=u.exports},957:function(t,e){},958:function(t,e,n){"use strict";n.d(e,"a",function(){return r}),n.d(e,"b",function(){return o});var r=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"act-gold-protocol"},[t.showCheckBox?n("div",{staticClass:"act-gold-protocol-check",on:{click:function(e){return e.stopPropagation(),t.protocolToggle.apply(null,arguments)}}},[n("i",{staticClass:"act-gold-protocol-icon",class:{checked:t.protocolChecked},style:{"background-color":t.protocolChecked?t.brandColor:""}})]):t._e(),t._v(" "),n("div",{staticClass:"act-gold-protocol-text",style:{color:t.textColor,"font-size":t.fontSize}},[n("span",{domProps:{innerHTML:t._s(t.text)}}),t._v(" "),t._l(t.protocols,function(e,r){return[r==t.protocols.length-1&&0!=r?n("span",{key:r+"span"},[t._v("和")]):0!=r?n("span",{key:r+"span"},[t._v("、")]):t._e(),t._v(" "),e.track?n("a",{key:r+"a",staticClass:"act-gold-protocol-item",style:{color:t.brandColor},attrs:{"data-track":e.track},on:{click:function(n){return t.onClick(e)}}},[t._v("《"+t._s(e.title)+"》")]):n("a",{key:r+"a",staticClass:"act-gold-protocol-item",style:{color:t.brandColor},attrs:{"data-track":e.track||""},on:{click:function(n){return t.onClick(e)}}},[t._v("《"+t._s(e.title)+"》")])]}),t._v(" "),n("span",{domProps:{innerHTML:t._s(t.tips)}})],2)])},o=[];r._withStripped=!0},960:function(t,e,n){"use strict";function r(t){c||n(961)}var o=n(895),i=n(967),s=n(7),c=!1,a=r,u=Object(s.a)(o.a,i.a,i.b,!1,a,"data-v-21ba486f",null);u.options.__file="src\\components\\GoldReadTerms\\src\\index.vue",e.a=u.exports},961:function(t,e){},962:function(t,e,n){t.exports={default:n(963),__esModule:!0}},963:function(t,e,n){n(964),t.exports=n(2).Number.parseInt},964:function(t,e,n){var r=n(9),o=n(965);r(r.S+r.F*(Number.parseInt!=o),"Number",{parseInt:o})},965:function(t,e,n){var r=n(0).parseInt,o=n(966).trim,i=n(896),s=/^[-+]?0[xX]/;t.exports=8!==r(i+"08")||22!==r(i+"0x16")?function(t,e){var n=o(String(t),3);return r(n,e>>>0||(s.test(n)?16:10))}:r},966:function(t,e,n){var r=n(9),o=n(15),i=n(12),s=n(896),c="["+s+"]",a="
",u=RegExp("^"+c+c+"*"),l=RegExp(c+c+"*$"),f=function(t,e,n){var o={},c=i(function(){return!!s[t]()||a[t]()!=a}),u=o[t]=c?e(d):s[t];n&&(o[n]=u),r(r.P+r.F*c,"String",o)},d=f.trim=function(t,e){return t=String(o(t)),1&e&&(t=t.replace(u,"")),2&e&&(t=t.replace(l,"")),t};t.exports=f},967:function(t,e,n){"use strict";n.d(e,"a",function(){return r}),n.d(e,"b",function(){return o});var r=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("act-gold-layer",{attrs:{visible:t.isVisible,center:!1}},[n("div",{staticClass:"readterms-title",attrs:{slot:"header"},slot:"header"},[t.$slots.myheader?[t._t("myheader")]:[t.readTermsLength>1?n("span",{ref:"prevbtn",staticClass:"prev h-btn",on:{click:t.handlePrev}},[t._v("上一页")]):t._e(),t._v(" "),n("span",[t._v("请阅读以下内容"),t.readTermsLength>1?n("span",[t._v("("+t._s(t.curIndex)+"/"+t._s(t.readTermsLength)+")")]):t._e()]),t._v(" "),t.readTermsLength>1?n("span",{ref:"nextbtn",staticClass:"next h-btn",on:{click:t.handleNext}},[t._v("下一页")]):t._e()]],2),t._v(" "),t.isVisible?n("scroll-zoom",{ref:"scrollZoom",staticClass:"scroll-zoom",attrs:{termsInfo:t.termsInfo,forceRead:t.curForceReadToPageEnd,docIndex:t.curIndex-1,brandColor:t.brandColor},on:{canINext:t.canINext}}):t._e(),t._v(" "),t.$slots.footer?n("div",[t._t("footer")],2):[n("div",{staticClass:"bottom-btn-placeholder"}),t._v(" "),n("div",{staticClass:"readterms-btns"},[n("div",{staticClass:"f-btn left",on:{click:t.cancel}},[n("p",[t._v(t._s(t.cancelButtonText))])]),t._v(" "),n("div",{staticClass:"f-btn right",class:{disabled:t.readTimer},style:{background:t.readTimer?"#f2f2f2":t.brandColor},on:{click:t.confirm}},[n("p",[t._v(t._s(t.comfirmText))]),t._v(" "),t.$slots.fIcon?t._t("fIcon"):t._e()],2)])]],2)},o=[];r._withStripped=!0}})});