加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
main.b8fa34.js 61.75 KB
一键复制 编辑 原始数据 按行查看 历史
ProudRabbit 提交于 2020-08-02 19:41 . Site updated: 2020-08-02 19:40:50
!function(e){function t(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="./",t(0)}({0:function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}n(418);var i=n(207),r=o(i),a=n(206),l=o(a),u=n(203),s=o(u),c=n(135);(0,c.addLoadEvent)(function(){l.default.init(),r.default.init(),s.default.init()})},6:function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},9:function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},12:function(e,t,n){e.exports=!n(20)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},13:function(e,t,n){var o=n(14),i=n(24);e.exports=n(12)?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},14:function(e,t,n){var o=n(22),i=n(60),r=n(42),a=Object.defineProperty;t.f=n(12)?Object.defineProperty:function(e,t,n){if(o(e),t=r(t,!0),o(n),i)try{return a(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},15:function(e,t,n){var o=n(96),i=n(34);e.exports=function(e){return o(i(e))}},16:function(e,t,n){var o=n(40)("wks"),i=n(25),r=n(6).Symbol,a="function"==typeof r,l=e.exports=function(e){return o[e]||(o[e]=a&&r[e]||(a?r:i)("Symbol."+e))};l.store=o},18:function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},19:function(e,t){var n=e.exports={version:"2.6.9"};"number"==typeof __e&&(__e=n)},20:function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},22:function(e,t,n){var o=n(18);e.exports=function(e){if(!o(e))throw TypeError(e+" is not an object!");return e}},23:function(e,t){e.exports=!0},24:function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},25:function(e,t){var n=0,o=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+o).toString(36))}},29:function(e,t,n){var o=n(65),i=n(35);e.exports=Object.keys||function(e){return o(e,i)}},34:function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},35:function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},36:function(e,t){e.exports={}},37:function(e,t){t.f={}.propertyIsEnumerable},38:function(e,t,n){var o=n(14).f,i=n(9),r=n(16)("toStringTag");e.exports=function(e,t,n){e&&!i(e=n?e:e.prototype,r)&&o(e,r,{configurable:!0,value:t})}},39:function(e,t,n){var o=n(40)("keys"),i=n(25);e.exports=function(e){return o[e]||(o[e]=i(e))}},40:function(e,t,n){var o=n(19),i=n(6),r="__core-js_shared__",a=i[r]||(i[r]={});(e.exports=function(e,t){return a[e]||(a[e]=void 0!==t?t:{})})("versions",[]).push({version:o.version,mode:n(23)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},41:function(e,t){var n=Math.ceil,o=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?o:n)(e)}},42:function(e,t,n){var o=n(18);e.exports=function(e,t){if(!o(e))return e;var n,i;if(t&&"function"==typeof(n=e.toString)&&!o(i=n.call(e)))return i;if("function"==typeof(n=e.valueOf)&&!o(i=n.call(e)))return i;if(!t&&"function"==typeof(n=e.toString)&&!o(i=n.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},43:function(e,t,n){var o=n(6),i=n(19),r=n(23),a=n(44),l=n(14).f;e.exports=function(e){var t=i.Symbol||(i.Symbol=r?{}:o.Symbol||{});"_"==e.charAt(0)||e in t||l(t,e,{value:a.f(e)})}},44:function(e,t,n){t.f=n(16)},54:function(e,t,n){var o=n(6),i=n(19),r=n(93),a=n(13),l=n(9),u="prototype",s=function(e,t,n){var c,f,d,p=e&s.F,m=e&s.G,h=e&s.S,v=e&s.P,y=e&s.B,g=e&s.W,w=m?i:i[t]||(i[t]={}),x=w[u],b=m?o:h?o[t]:(o[t]||{})[u];m&&(n=t);for(c in n)f=!p&&b&&void 0!==b[c],f&&l(w,c)||(d=f?b[c]:n[c],w[c]=m&&"function"!=typeof b[c]?n[c]:y&&f?r(d,o):g&&b[c]==d?function(e){var t=function(t,n,o){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,n)}return new e(t,n,o)}return e.apply(this,arguments)};return t[u]=e[u],t}(d):v&&"function"==typeof d?r(Function.call,d):d,v&&((w.virtual||(w.virtual={}))[c]=d,e&s.R&&x&&!x[c]&&a(x,c,d)))};s.F=1,s.G=2,s.S=4,s.P=8,s.B=16,s.W=32,s.U=64,s.R=128,e.exports=s},55:function(e,t,n){var o=n(34);e.exports=function(e){return Object(o(e))}},58:function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},59:function(e,t,n){var o=n(18),i=n(6).document,r=o(i)&&o(i.createElement);e.exports=function(e){return r?i.createElement(e):{}}},60:function(e,t,n){e.exports=!n(12)&&!n(20)(function(){return 7!=Object.defineProperty(n(59)("div"),"a",{get:function(){return 7}}).a})},61:function(e,t,n){"use strict";var o=n(23),i=n(54),r=n(66),a=n(13),l=n(36),u=n(98),s=n(38),c=n(104),f=n(16)("iterator"),d=!([].keys&&"next"in[].keys()),p="@@iterator",m="keys",h="values",v=function(){return this};e.exports=function(e,t,n,y,g,w,x){u(n,t,y);var b,T,S,C=function(e){if(!d&&e in O)return O[e];switch(e){case m:return function(){return new n(this,e)};case h:return function(){return new n(this,e)}}return function(){return new n(this,e)}},I=t+" Iterator",E=g==h,_=!1,O=e.prototype,M=O[f]||O[p]||g&&O[g],D=M||C(g),k=g?E?C("entries"):D:void 0,A="Array"==t?O.entries||M:M;if(A&&(S=c(A.call(new e)),S!==Object.prototype&&S.next&&(s(S,I,!0),o||"function"==typeof S[f]||a(S,f,v))),E&&M&&M.name!==h&&(_=!0,D=function(){return M.call(this)}),o&&!x||!d&&!_&&O[f]||a(O,f,D),l[t]=D,l[I]=v,g)if(b={values:E?D:C(h),keys:w?D:C(m),entries:k},x)for(T in b)T in O||r(O,T,b[T]);else i(i.P+i.F*(d||_),t,b);return b}},62:function(e,t,n){var o=n(22),i=n(101),r=n(35),a=n(39)("IE_PROTO"),l=function(){},u="prototype",s=function(){var e,t=n(59)("iframe"),o=r.length,i="<",a=">";for(t.style.display="none",n(95).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write(i+"script"+a+"document.F=Object"+i+"/script"+a),e.close(),s=e.F;o--;)delete s[u][r[o]];return s()};e.exports=Object.create||function(e,t){var n;return null!==e?(l[u]=o(e),n=new l,l[u]=null,n[a]=e):n=s(),void 0===t?n:i(n,t)}},63:function(e,t,n){var o=n(65),i=n(35).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return o(e,i)}},64:function(e,t){t.f=Object.getOwnPropertySymbols},65:function(e,t,n){var o=n(9),i=n(15),r=n(92)(!1),a=n(39)("IE_PROTO");e.exports=function(e,t){var n,l=i(e),u=0,s=[];for(n in l)n!=a&&o(l,n)&&s.push(n);for(;t.length>u;)o(l,n=t[u++])&&(~r(s,n)||s.push(n));return s}},66:function(e,t,n){e.exports=n(13)},85:function(e,t,n){e.exports={default:n(88),__esModule:!0}},86:function(e,t,n){e.exports={default:n(89),__esModule:!0}},87:function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var i=n(86),r=o(i),a=n(85),l=o(a),u="function"==typeof l.default&&"symbol"==typeof r.default?function(e){return typeof e}:function(e){return e&&"function"==typeof l.default&&e.constructor===l.default&&e!==l.default.prototype?"symbol":typeof e};t.default="function"==typeof l.default&&"symbol"===u(r.default)?function(e){return"undefined"==typeof e?"undefined":u(e)}:function(e){return e&&"function"==typeof l.default&&e.constructor===l.default&&e!==l.default.prototype?"symbol":"undefined"==typeof e?"undefined":u(e)}},88:function(e,t,n){n(111),n(109),n(112),n(113),e.exports=n(19).Symbol},89:function(e,t,n){n(110),n(114),e.exports=n(44).f("iterator")},90:function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},91:function(e,t){e.exports=function(){}},92:function(e,t,n){var o=n(15),i=n(107),r=n(106);e.exports=function(e){return function(t,n,a){var l,u=o(t),s=i(u.length),c=r(a,s);if(e&&n!=n){for(;s>c;)if(l=u[c++],l!=l)return!0}else for(;s>c;c++)if((e||c in u)&&u[c]===n)return e||c||0;return!e&&-1}}},93:function(e,t,n){var o=n(90);e.exports=function(e,t,n){if(o(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,o){return e.call(t,n,o)};case 3:return function(n,o,i){return e.call(t,n,o,i)}}return function(){return e.apply(t,arguments)}}},94:function(e,t,n){var o=n(29),i=n(64),r=n(37);e.exports=function(e){var t=o(e),n=i.f;if(n)for(var a,l=n(e),u=r.f,s=0;l.length>s;)u.call(e,a=l[s++])&&t.push(a);return t}},95:function(e,t,n){var o=n(6).document;e.exports=o&&o.documentElement},96:function(e,t,n){var o=n(58);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==o(e)?e.split(""):Object(e)}},97:function(e,t,n){var o=n(58);e.exports=Array.isArray||function(e){return"Array"==o(e)}},98:function(e,t,n){"use strict";var o=n(62),i=n(24),r=n(38),a={};n(13)(a,n(16)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=o(a,{next:i(1,n)}),r(e,t+" Iterator")}},99:function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},100:function(e,t,n){var o=n(25)("meta"),i=n(18),r=n(9),a=n(14).f,l=0,u=Object.isExtensible||function(){return!0},s=!n(20)(function(){return u(Object.preventExtensions({}))}),c=function(e){a(e,o,{value:{i:"O"+ ++l,w:{}}})},f=function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!r(e,o)){if(!u(e))return"F";if(!t)return"E";c(e)}return e[o].i},d=function(e,t){if(!r(e,o)){if(!u(e))return!0;if(!t)return!1;c(e)}return e[o].w},p=function(e){return s&&m.NEED&&u(e)&&!r(e,o)&&c(e),e},m=e.exports={KEY:o,NEED:!1,fastKey:f,getWeak:d,onFreeze:p}},101:function(e,t,n){var o=n(14),i=n(22),r=n(29);e.exports=n(12)?Object.defineProperties:function(e,t){i(e);for(var n,a=r(t),l=a.length,u=0;l>u;)o.f(e,n=a[u++],t[n]);return e}},102:function(e,t,n){var o=n(37),i=n(24),r=n(15),a=n(42),l=n(9),u=n(60),s=Object.getOwnPropertyDescriptor;t.f=n(12)?s:function(e,t){if(e=r(e),t=a(t,!0),u)try{return s(e,t)}catch(e){}if(l(e,t))return i(!o.f.call(e,t),e[t])}},103:function(e,t,n){var o=n(15),i=n(63).f,r={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],l=function(e){try{return i(e)}catch(e){return a.slice()}};e.exports.f=function(e){return a&&"[object Window]"==r.call(e)?l(e):i(o(e))}},104:function(e,t,n){var o=n(9),i=n(55),r=n(39)("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=i(e),o(e,r)?e[r]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},105:function(e,t,n){var o=n(41),i=n(34);e.exports=function(e){return function(t,n){var r,a,l=String(i(t)),u=o(n),s=l.length;return u<0||u>=s?e?"":void 0:(r=l.charCodeAt(u),r<55296||r>56319||u+1===s||(a=l.charCodeAt(u+1))<56320||a>57343?e?l.charAt(u):r:e?l.slice(u,u+2):(r-55296<<10)+(a-56320)+65536)}}},106:function(e,t,n){var o=n(41),i=Math.max,r=Math.min;e.exports=function(e,t){return e=o(e),e<0?i(e+t,0):r(e,t)}},107:function(e,t,n){var o=n(41),i=Math.min;e.exports=function(e){return e>0?i(o(e),9007199254740991):0}},108:function(e,t,n){"use strict";var o=n(91),i=n(99),r=n(36),a=n(15);e.exports=n(61)(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,i(1)):"keys"==t?i(0,n):"values"==t?i(0,e[n]):i(0,[n,e[n]])},"values"),r.Arguments=r.Array,o("keys"),o("values"),o("entries")},109:function(e,t){},110:function(e,t,n){"use strict";var o=n(105)(!0);n(61)(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=o(t,n),this._i+=e.length,{value:e,done:!1})})},111:function(e,t,n){"use strict";var o=n(6),i=n(9),r=n(12),a=n(54),l=n(66),u=n(100).KEY,s=n(20),c=n(40),f=n(38),d=n(25),p=n(16),m=n(44),h=n(43),v=n(94),y=n(97),g=n(22),w=n(18),x=n(55),b=n(15),T=n(42),S=n(24),C=n(62),I=n(103),E=n(102),_=n(64),O=n(14),M=n(29),D=E.f,k=O.f,A=I.f,F=o.Symbol,P=o.JSON,L=P&&P.stringify,R="prototype",Z=p("_hidden"),N=p("toPrimitive"),z={}.propertyIsEnumerable,U=c("symbol-registry"),j=c("symbols"),q=c("op-symbols"),K=Object[R],B="function"==typeof F&&!!_.f,H=o.QObject,W=!H||!H[R]||!H[R].findChild,G=r&&s(function(){return 7!=C(k({},"a",{get:function(){return k(this,"a",{value:7}).a}})).a})?function(e,t,n){var o=D(K,t);o&&delete K[t],k(e,t,n),o&&e!==K&&k(K,t,o)}:k,Y=function(e){var t=j[e]=C(F[R]);return t._k=e,t},V=B&&"symbol"==typeof F.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof F},X=function(e,t,n){return e===K&&X(q,t,n),g(e),t=T(t,!0),g(n),i(j,t)?(n.enumerable?(i(e,Z)&&e[Z][t]&&(e[Z][t]=!1),n=C(n,{enumerable:S(0,!1)})):(i(e,Z)||k(e,Z,S(1,{})),e[Z][t]=!0),G(e,t,n)):k(e,t,n)},J=function(e,t){g(e);for(var n,o=v(t=b(t)),i=0,r=o.length;r>i;)X(e,n=o[i++],t[n]);return e},$=function(e,t){return void 0===t?C(e):J(C(e),t)},Q=function(e){var t=z.call(this,e=T(e,!0));return!(this===K&&i(j,e)&&!i(q,e))&&(!(t||!i(this,e)||!i(j,e)||i(this,Z)&&this[Z][e])||t)},ee=function(e,t){if(e=b(e),t=T(t,!0),e!==K||!i(j,t)||i(q,t)){var n=D(e,t);return!n||!i(j,t)||i(e,Z)&&e[Z][t]||(n.enumerable=!0),n}},te=function(e){for(var t,n=A(b(e)),o=[],r=0;n.length>r;)i(j,t=n[r++])||t==Z||t==u||o.push(t);return o},ne=function(e){for(var t,n=e===K,o=A(n?q:b(e)),r=[],a=0;o.length>a;)!i(j,t=o[a++])||n&&!i(K,t)||r.push(j[t]);return r};B||(F=function(){if(this instanceof F)throw TypeError("Symbol is not a constructor!");var e=d(arguments.length>0?arguments[0]:void 0),t=function(n){this===K&&t.call(q,n),i(this,Z)&&i(this[Z],e)&&(this[Z][e]=!1),G(this,e,S(1,n))};return r&&W&&G(K,e,{configurable:!0,set:t}),Y(e)},l(F[R],"toString",function(){return this._k}),E.f=ee,O.f=X,n(63).f=I.f=te,n(37).f=Q,_.f=ne,r&&!n(23)&&l(K,"propertyIsEnumerable",Q,!0),m.f=function(e){return Y(p(e))}),a(a.G+a.W+a.F*!B,{Symbol:F});for(var oe="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ie=0;oe.length>ie;)p(oe[ie++]);for(var re=M(p.store),ae=0;re.length>ae;)h(re[ae++]);a(a.S+a.F*!B,"Symbol",{for:function(e){return i(U,e+="")?U[e]:U[e]=F(e)},keyFor:function(e){if(!V(e))throw TypeError(e+" is not a symbol!");for(var t in U)if(U[t]===e)return t},useSetter:function(){W=!0},useSimple:function(){W=!1}}),a(a.S+a.F*!B,"Object",{create:$,defineProperty:X,defineProperties:J,getOwnPropertyDescriptor:ee,getOwnPropertyNames:te,getOwnPropertySymbols:ne});var le=s(function(){_.f(1)});a(a.S+a.F*le,"Object",{getOwnPropertySymbols:function(e){return _.f(x(e))}}),P&&a(a.S+a.F*(!B||s(function(){var e=F();return"[null]"!=L([e])||"{}"!=L({a:e})||"{}"!=L(Object(e))})),"JSON",{stringify:function(e){for(var t,n,o=[e],i=1;arguments.length>i;)o.push(arguments[i++]);if(n=t=o[1],(w(t)||void 0!==e)&&!V(e))return y(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!V(t))return t}),o[1]=t,L.apply(P,o)}}),F[R][N]||n(13)(F[R],N,F[R].valueOf),f(F,"Symbol"),f(Math,"Math",!0),f(o.JSON,"JSON",!0)},112:function(e,t,n){n(43)("asyncIterator")},113:function(e,t,n){n(43)("observable")},114:function(e,t,n){n(108);for(var o=n(6),i=n(13),r=n(36),a=n(16)("toStringTag"),l="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(","),u=0;u<l.length;u++){var s=l[u],c=o[s],f=c&&c.prototype;f&&!f[a]&&i(f,a,s),r[s]=r.Array}},135:function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}var i=n(87),r=o(i),a=function(){function e(e,t,n){return t||n?String.fromCharCode(t||n):i[e]||e}function t(e){return f[e]}var n=/&quot;|&lt;|&gt;|&amp;|&nbsp;|&apos;|&#(\d+);|&#(\d+)/g,o=/['<> "&]/g,i={"&quot;":'"',"&lt;":"<","&gt;":">","&amp;":"&","&nbsp;":" "},l=/\u00a0/g,u=/<br\s*\/?>/gi,s=/\r?\n/g,c=/\s/g,f={};for(var d in i)f[i[d]]=d;return i["&apos;"]="'",f["'"]="&#39;",{encode:function(e){return e?(""+e).replace(o,t).replace(s,"<br/>").replace(c,"&nbsp;"):""},decode:function(t){return t?(""+t).replace(u,"\n").replace(n,e).replace(l," "):""},encodeBase16:function(e){if(!e)return e;e+="";for(var t=[],n=0,o=e.length;o>n;n++)t.push(e.charCodeAt(n).toString(16).toUpperCase());return t.join("")},encodeBase16forJSON:function(e){if(!e)return e;e=e.replace(/[\u4E00-\u9FBF]/gi,function(e){return escape(e).replace("%u","\\u")});for(var t=[],n=0,o=e.length;o>n;n++)t.push(e.charCodeAt(n).toString(16).toUpperCase());return t.join("")},decodeBase16:function(e){if(!e)return e;e+="";for(var t=[],n=0,o=e.length;o>n;n+=2)t.push(String.fromCharCode("0x"+e.slice(n,n+2)));return t.join("")},encodeObject:function(e){if(e instanceof Array)for(var t=0,n=e.length;n>t;t++)e[t]=a.encodeObject(e[t]);else if("object"==("undefined"==typeof e?"undefined":(0,r.default)(e)))for(var o in e)e[o]=a.encodeObject(e[o]);else if("string"==typeof e)return a.encode(e);return e},loadScript:function(e){var t=document.createElement("script");document.getElementsByTagName("body")[0].appendChild(t),t.setAttribute("src",e)},addLoadEvent:function(e){var t=window.onload;"function"!=typeof window.onload?window.onload=e:window.onload=function(){t(),e()}}}}();e.exports=a},163:function(e,t){function n(e,t){e.classList?e.classList.add(t):e.className+=" "+t}e.exports=n},164:function(e,t){function n(e,t){if(e.classList)e.classList.remove(t);else{var n=new RegExp("(^|\\b)"+t.split(" ").join("|")+"(\\b|$)","gi");e.className=e.className.replace(n," ")}}e.exports=n},203:function(e,t){"use strict";function n(){o(document.getElementById("js-jump-container"),document.getElementById("container"),80)}var o=function(e,t,n){function o(){e.style.display=(t.scrollTop||document.documentElement.scrollTop||document.body.scrollTop)>=(n||500)?"block":"none"}function i(e,t){var n=null;return function(){var o=this,i=arguments;n&&clearTimeout(n),n=setTimeout(function(){return"function"==typeof e&&e.apply(o,i)},t)}}if(e){var r=null,a=window.onscroll,l=e.onclick;(t||window).onscroll=i(function(){"function"==typeof a&&a.apply(this,arguments),o()},100),e.onclick=function(){"function"==typeof l&&l.apply(this,arguments);t.scrollTop||document.documentElement.scrollTop||document.body.scrollTop;r=setInterval(function(){var e=t.scrollTop||document.documentElement.scrollTop||document.body.scrollTop,n=Math.max(10,e/6);e-=n,e>0?(t.scrollTop=t.scrollTop-n,window.scrollTo(0,e)):(t.scrollTop=0,window.scrollTo(0,0),clearInterval(r))},10)}}};e.exports={init:n}},206:function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var e=e.replace(/<%-sUrl%>/g,encodeURIComponent(t.sUrl)).replace(/<%-sTitle%>/g,t.sTitle).replace(/<%-sDesc%>/g,t.sDesc).replace(/<%-sPic%>/g,encodeURIComponent(t.sPic));window.open(e)}function r(){var e=document.querySelector(".js-wx-box"),t=document.querySelector(".mask");(0,s.default)(e,"in"),(0,s.default)(e,"ready"),(0,s.default)(t,"in")}function a(){var e=document.querySelector(".js-wx-box"),t=document.querySelector(".mask");(0,f.default)(e,"in"),(0,f.default)(e,"ready"),(0,f.default)(t,"in")}function l(e,t){"weibo"===e?i("http://service.weibo.com/share/share.php?url=<%-sUrl%>&title=<%-sTitle%>&pic=<%-sPic%>",t):"qq"===e?i("http://connect.qq.com/widget/shareqq/index.html?url=<%-sUrl%>&title=<%-sTitle%>&source=<%-sDesc%>",t):"douban"===e?i("https://www.douban.com/share/service?image=<%-sPic%>&href=<%-sUrl%>&name=<%-sTitle%>&text=<%-sDesc%>",t):"qzone"===e?i("http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=<%-sUrl%>&title=<%-sTitle%>&pics=<%-sPic%>&summary=<%-sDesc%>",t):"facebook"===e?i("https://www.facebook.com/sharer/sharer.php?u=<%-sUrl%>",t):"twitter"===e?i("https://twitter.com/intent/tweet?text=<%-sTitle%>&url=<%-sUrl%>&via=<%-config.url%>",t):"google"===e?i("https://plus.google.com/share?url=<%-sUrl%>",t):"weixin"===e&&r()}var u=n(163),s=o(u),c=n(164),f=o(c),d=function(){var e=document.querySelectorAll(".share-sns");if(e&&0!==e.length){var t=window.location.href,n=document.querySelector("title").innerHTML,o=document.querySelectorAll(".article-entry img"),i=o.length?document.querySelector(".article-entry img").getAttribute("src"):"";""===i||/^(http:|https:)?\/\//.test(i)||(i=window.location.origin+i),e.forEach(function(e){e.onclick=function(o){var r=e.getAttribute("data-type");l(r,{sUrl:t,sPic:i,sTitle:n,sDesc:n})}}),document.querySelector(".mask").onclick=a,document.querySelector(".js-modal-close").onclick=a}};e.exports={init:d}},207:function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function i(){var e=document.querySelectorAll(".pswp")[0],t=document.querySelectorAll(".article-entry img:not(.reward-img)");t.forEach(function(n,o){n.onclick=function(){if(!document.querySelector(".left-col.show")){var n=[];t.forEach(function(e,t){var o=(e.getAttribute("data-idx",t),e.getAttribute("data-target")||e.getAttribute("src")),i=e.getAttribute("alt"),r=new Image;r.src=o,n.push({src:o,w:r.width||e.width,h:r.height||e.height,title:i})});var i=new a.default(e,u.default,n,{index:parseInt(o)});i.init()}}})}var r=n(421),a=o(r),l=n(420),u=o(l);n(416),n(417),window.PhotoSwipe=a.default,window.PhotoSwipeUI_Default=u.default,e.exports={init:i}},416:function(e,t){},417:function(e,t){},418:function(e,t){},420:function(e,t,n){var o,i;/*! PhotoSwipe Default UI - 4.1.3 - 2019-01-08
* http://photoswipe.com
* Copyright (c) 2019 Dmitry Semenov; */
!function(r,a){o=a,i="function"==typeof o?o.call(t,n,t,e):o,!(void 0!==i&&(e.exports=i))}(this,function(){"use strict";var e=function(e,t){var n,o,i,r,a,l,u,s,c,f,d,p,m,h,v,y,g,w,x,b=this,T=!1,S=!0,C=!0,I={barsSize:{top:44,bottom:"auto"},closeElClasses:["item","caption","zoom-wrap","ui","top-bar"],timeToIdle:4e3,timeToIdleOutside:1e3,loadingIndicatorDelay:1e3,addCaptionHTMLFn:function(e,t){return e.title?(t.children[0].innerHTML=e.title,!0):(t.children[0].innerHTML="",!1)},closeEl:!0,captionEl:!0,fullscreenEl:!0,zoomEl:!0,shareEl:!0,counterEl:!0,arrowEl:!0,preloaderEl:!0,tapToClose:!1,tapToToggleControls:!0,clickToCloseNonZoomable:!0,shareButtons:[{id:"facebook",label:"Share on Facebook",url:"https://www.facebook.com/sharer/sharer.php?u={{url}}"},{id:"twitter",label:"Tweet",url:"https://twitter.com/intent/tweet?text={{text}}&url={{url}}"},{id:"pinterest",label:"Pin it",url:"http://www.pinterest.com/pin/create/button/?url={{url}}&media={{image_url}}&description={{text}}"},{id:"download",label:"Download image",url:"{{raw_image_url}}",download:!0}],getImageURLForShare:function(){return e.currItem.src||""},getPageURLForShare:function(){return window.location.href},getTextForShare:function(){return e.currItem.title||""},indexIndicatorSep:" / ",fitControlsWidth:1200},E=function(e){if(y)return!0;e=e||window.event,v.timeToIdle&&v.mouseUsed&&!c&&R();for(var n,o,i=e.target||e.srcElement,r=i.getAttribute("class")||"",a=0;a<B.length;a++)n=B[a],n.onTap&&r.indexOf("pswp__"+n.name)>-1&&(n.onTap(),o=!0);if(o){e.stopPropagation&&e.stopPropagation(),y=!0;var l=t.features.isOldAndroid?600:30;g=setTimeout(function(){y=!1},l)}},_=function(){return!e.likelyTouchDevice||v.mouseUsed||screen.width>v.fitControlsWidth},O=function(e,n,o){t[(o?"add":"remove")+"Class"](e,"pswp__"+n)},M=function(){var e=1===v.getNumItemsFn();e!==h&&(O(o,"ui--one-slide",e),h=e)},D=function(){O(u,"share-modal--hidden",C)},k=function(){return C=!C,C?(t.removeClass(u,"pswp__share-modal--fade-in"),setTimeout(function(){C&&D()},300)):(D(),setTimeout(function(){C||t.addClass(u,"pswp__share-modal--fade-in")},30)),C||F(),!1},A=function(t){t=t||window.event;var n=t.target||t.srcElement;return e.shout("shareLinkClick",t,n),!!n.href&&(!!n.hasAttribute("download")||(window.open(n.href,"pswp_share","scrollbars=yes,resizable=yes,toolbar=no,location=yes,width=550,height=420,top=100,left="+(window.screen?Math.round(screen.width/2-275):100)),C||k(),!1))},F=function(){for(var e,t,n,o,i,r="",a=0;a<v.shareButtons.length;a++)e=v.shareButtons[a],n=v.getImageURLForShare(e),o=v.getPageURLForShare(e),i=v.getTextForShare(e),t=e.url.replace("{{url}}",encodeURIComponent(o)).replace("{{image_url}}",encodeURIComponent(n)).replace("{{raw_image_url}}",n).replace("{{text}}",encodeURIComponent(i)),r+='<a href="'+t+'" target="_blank" class="pswp__share--'+e.id+'"'+(e.download?"download":"")+">"+e.label+"</a>",v.parseShareButtonOut&&(r=v.parseShareButtonOut(e,r));u.children[0].innerHTML=r,u.children[0].onclick=A},P=function(e){for(var n=0;n<v.closeElClasses.length;n++)if(t.hasClass(e,"pswp__"+v.closeElClasses[n]))return!0},L=0,R=function(){clearTimeout(x),L=0,c&&b.setIdle(!1)},Z=function(e){e=e?e:window.event;var t=e.relatedTarget||e.toElement;t&&"HTML"!==t.nodeName||(clearTimeout(x),x=setTimeout(function(){b.setIdle(!0)},v.timeToIdleOutside))},N=function(){v.fullscreenEl&&!t.features.isOldAndroid&&(n||(n=b.getFullscreenAPI()),n?(t.bind(document,n.eventK,b.updateFullscreen),b.updateFullscreen(),t.addClass(e.template,"pswp--supports-fs")):t.removeClass(e.template,"pswp--supports-fs"))},z=function(){v.preloaderEl&&(U(!0),f("beforeChange",function(){clearTimeout(m),m=setTimeout(function(){e.currItem&&e.currItem.loading?(!e.allowProgressiveImg()||e.currItem.img&&!e.currItem.img.naturalWidth)&&U(!1):U(!0)},v.loadingIndicatorDelay)}),f("imageLoadComplete",function(t,n){e.currItem===n&&U(!0)}))},U=function(e){p!==e&&(O(d,"preloader--active",!e),p=e)},j=function(e){var n=e.vGap;if(_()){var a=v.barsSize;if(v.captionEl&&"auto"===a.bottom)if(r||(r=t.createEl("pswp__caption pswp__caption--fake"),r.appendChild(t.createEl("pswp__caption__center")),o.insertBefore(r,i),t.addClass(o,"pswp__ui--fit")),v.addCaptionHTMLFn(e,r,!0)){var l=r.clientHeight;n.bottom=parseInt(l,10)||44}else n.bottom=a.top;else n.bottom="auto"===a.bottom?0:a.bottom;n.top=a.top}else n.top=n.bottom=0},q=function(){v.timeToIdle&&f("mouseUsed",function(){t.bind(document,"mousemove",R),t.bind(document,"mouseout",Z),w=setInterval(function(){L++,2===L&&b.setIdle(!0)},v.timeToIdle/2)})},K=function(){f("onVerticalDrag",function(e){S&&e<.95?b.hideControls():!S&&e>=.95&&b.showControls()});var e;f("onPinchClose",function(t){S&&t<.9?(b.hideControls(),e=!0):e&&!S&&t>.9&&b.showControls()}),f("zoomGestureEnded",function(){e=!1,e&&!S&&b.showControls()})},B=[{name:"caption",option:"captionEl",onInit:function(e){i=e}},{name:"share-modal",option:"shareEl",onInit:function(e){u=e},onTap:function(){k()}},{name:"button--share",option:"shareEl",onInit:function(e){l=e},onTap:function(){k()}},{name:"button--zoom",option:"zoomEl",onTap:e.toggleDesktopZoom},{name:"counter",option:"counterEl",onInit:function(e){a=e}},{name:"button--close",option:"closeEl",onTap:e.close},{name:"button--arrow--left",option:"arrowEl",onTap:e.prev},{name:"button--arrow--right",option:"arrowEl",onTap:e.next},{name:"button--fs",option:"fullscreenEl",onTap:function(){n.isFullscreen()?n.exit():n.enter()}},{name:"preloader",option:"preloaderEl",onInit:function(e){d=e}}],H=function(){var e,n,i,r=function(o){if(o)for(var r=o.length,a=0;a<r;a++){e=o[a],n=e.className;for(var l=0;l<B.length;l++)i=B[l],n.indexOf("pswp__"+i.name)>-1&&(v[i.option]?(t.removeClass(e,"pswp__element--disabled"),i.onInit&&i.onInit(e)):t.addClass(e,"pswp__element--disabled"))}};r(o.children);var a=t.getChildByClass(o,"pswp__top-bar");a&&r(a.children)};b.init=function(){t.extend(e.options,I,!0),v=e.options,o=t.getChildByClass(e.scrollWrap,"pswp__ui"),f=e.listen,K(),f("beforeChange",b.update),f("doubleTap",function(t){var n=e.currItem.initialZoomLevel;e.getZoomLevel()!==n?e.zoomTo(n,t,333):e.zoomTo(v.getDoubleTapZoom(!1,e.currItem),t,333)}),f("preventDragEvent",function(e,t,n){var o=e.target||e.srcElement;o&&o.getAttribute("class")&&e.type.indexOf("mouse")>-1&&(o.getAttribute("class").indexOf("__caption")>0||/(SMALL|STRONG|EM)/i.test(o.tagName))&&(n.prevent=!1)}),f("bindEvents",function(){t.bind(o,"pswpTap click",E),t.bind(e.scrollWrap,"pswpTap",b.onGlobalTap),e.likelyTouchDevice||t.bind(e.scrollWrap,"mouseover",b.onMouseOver)}),f("unbindEvents",function(){C||k(),w&&clearInterval(w),t.unbind(document,"mouseout",Z),t.unbind(document,"mousemove",R),t.unbind(o,"pswpTap click",E),t.unbind(e.scrollWrap,"pswpTap",b.onGlobalTap),t.unbind(e.scrollWrap,"mouseover",b.onMouseOver),n&&(t.unbind(document,n.eventK,b.updateFullscreen),n.isFullscreen()&&(v.hideAnimationDuration=0,n.exit()),n=null)}),f("destroy",function(){v.captionEl&&(r&&o.removeChild(r),t.removeClass(i,"pswp__caption--empty")),u&&(u.children[0].onclick=null),t.removeClass(o,"pswp__ui--over-close"),t.addClass(o,"pswp__ui--hidden"),b.setIdle(!1)}),v.showAnimationDuration||t.removeClass(o,"pswp__ui--hidden"),f("initialZoomIn",function(){v.showAnimationDuration&&t.removeClass(o,"pswp__ui--hidden")}),f("initialZoomOut",function(){t.addClass(o,"pswp__ui--hidden")}),f("parseVerticalMargin",j),H(),v.shareEl&&l&&u&&(C=!0),M(),q(),N(),z()},b.setIdle=function(e){c=e,O(o,"ui--idle",e)},b.update=function(){S&&e.currItem?(b.updateIndexIndicator(),v.captionEl&&(v.addCaptionHTMLFn(e.currItem,i),O(i,"caption--empty",!e.currItem.title)),T=!0):T=!1,C||k(),M()},b.updateFullscreen=function(o){o&&setTimeout(function(){e.setScrollOffset(0,t.getScrollY())},50),t[(n.isFullscreen()?"add":"remove")+"Class"](e.template,"pswp--fs")},b.updateIndexIndicator=function(){v.counterEl&&(a.innerHTML=e.getCurrentIndex()+1+v.indexIndicatorSep+v.getNumItemsFn())},b.onGlobalTap=function(n){n=n||window.event;var o=n.target||n.srcElement;if(!y)if(n.detail&&"mouse"===n.detail.pointerType){if(P(o))return void e.close();t.hasClass(o,"pswp__img")&&(1===e.getZoomLevel()&&e.getZoomLevel()<=e.currItem.fitRatio?v.clickToCloseNonZoomable&&e.close():e.toggleDesktopZoom(n.detail.releasePoint))}else if(v.tapToToggleControls&&(S?b.hideControls():b.showControls()),v.tapToClose&&(t.hasClass(o,"pswp__img")||P(o)))return void e.close()},b.onMouseOver=function(e){e=e||window.event;var t=e.target||e.srcElement;O(o,"ui--over-close",P(t))},b.hideControls=function(){t.addClass(o,"pswp__ui--hidden"),S=!1},b.showControls=function(){S=!0,T||b.update(),t.removeClass(o,"pswp__ui--hidden")},b.supportsFullscreen=function(){var e=document;return!!(e.exitFullscreen||e.mozCancelFullScreen||e.webkitExitFullscreen||e.msExitFullscreen)},b.getFullscreenAPI=function(){var t,n=document.documentElement,o="fullscreenchange";return n.requestFullscreen?t={enterK:"requestFullscreen",exitK:"exitFullscreen",elementK:"fullscreenElement",eventK:o}:n.mozRequestFullScreen?t={enterK:"mozRequestFullScreen",exitK:"mozCancelFullScreen",elementK:"mozFullScreenElement",eventK:"moz"+o}:n.webkitRequestFullscreen?t={enterK:"webkitRequestFullscreen",exitK:"webkitExitFullscreen",elementK:"webkitFullscreenElement",eventK:"webkit"+o}:n.msRequestFullscreen&&(t={enterK:"msRequestFullscreen",exitK:"msExitFullscreen",elementK:"msFullscreenElement",eventK:"MSFullscreenChange"}),t&&(t.enter=function(){return s=v.closeOnScroll,v.closeOnScroll=!1,"webkitRequestFullscreen"!==this.enterK?e.template[this.enterK]():void e.template[this.enterK](Element.ALLOW_KEYBOARD_INPUT)},t.exit=function(){return v.closeOnScroll=s,document[this.exitK]()},t.isFullscreen=function(){return document[this.elementK]}),t}};return e})},421:function(e,t,n){var o,i;/*! PhotoSwipe - v4.1.3 - 2019-01-08
* http://photoswipe.com
* Copyright (c) 2019 Dmitry Semenov; */
!function(r,a){o=a,i="function"==typeof o?o.call(t,n,t,e):o,!(void 0!==i&&(e.exports=i))}(this,function(){"use strict";var e=function(e,t,n,o){var i={features:null,bind:function(e,t,n,o){var i=(o?"remove":"add")+"EventListener";t=t.split(" ");for(var r=0;r<t.length;r++)t[r]&&e[i](t[r],n,!1)},isArray:function(e){return e instanceof Array},createEl:function(e,t){var n=document.createElement(t||"div");return e&&(n.className=e),n},getScrollY:function(){var e=window.pageYOffset;return void 0!==e?e:document.documentElement.scrollTop},unbind:function(e,t,n){i.bind(e,t,n,!0)},removeClass:function(e,t){var n=new RegExp("(\\s|^)"+t+"(\\s|$)");e.className=e.className.replace(n," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")},addClass:function(e,t){i.hasClass(e,t)||(e.className+=(e.className?" ":"")+t)},hasClass:function(e,t){return e.className&&new RegExp("(^|\\s)"+t+"(\\s|$)").test(e.className)},getChildByClass:function(e,t){for(var n=e.firstChild;n;){if(i.hasClass(n,t))return n;n=n.nextSibling}},arraySearch:function(e,t,n){for(var o=e.length;o--;)if(e[o][n]===t)return o;return-1},extend:function(e,t,n){for(var o in t)if(t.hasOwnProperty(o)){if(n&&e.hasOwnProperty(o))continue;e[o]=t[o]}},easing:{sine:{out:function(e){return Math.sin(e*(Math.PI/2))},inOut:function(e){return-(Math.cos(Math.PI*e)-1)/2}},cubic:{out:function(e){return--e*e*e+1}}},detectFeatures:function(){if(i.features)return i.features;var e=i.createEl(),t=e.style,n="",o={};if(o.oldIE=document.all&&!document.addEventListener,o.touch="ontouchstart"in window,window.requestAnimationFrame&&(o.raf=window.requestAnimationFrame,o.caf=window.cancelAnimationFrame),o.pointerEvent=!!window.PointerEvent||navigator.msPointerEnabled,!o.pointerEvent){var r=navigator.userAgent;if(/iP(hone|od)/.test(navigator.platform)){var a=navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/);a&&a.length>0&&(a=parseInt(a[1],10),a>=1&&a<8&&(o.isOldIOSPhone=!0))}var l=r.match(/Android\s([0-9\.]*)/),u=l?l[1]:0;u=parseFloat(u),u>=1&&(u<4.4&&(o.isOldAndroid=!0),o.androidVersion=u),o.isMobileOpera=/opera mini|opera mobi/i.test(r)}for(var s,c,f=["transform","perspective","animationName"],d=["","webkit","Moz","ms","O"],p=0;p<4;p++){n=d[p];for(var m=0;m<3;m++)s=f[m],c=n+(n?s.charAt(0).toUpperCase()+s.slice(1):s),!o[s]&&c in t&&(o[s]=c);n&&!o.raf&&(n=n.toLowerCase(),o.raf=window[n+"RequestAnimationFrame"],o.raf&&(o.caf=window[n+"CancelAnimationFrame"]||window[n+"CancelRequestAnimationFrame"]))}if(!o.raf){var h=0;o.raf=function(e){var t=(new Date).getTime(),n=Math.max(0,16-(t-h)),o=window.setTimeout(function(){e(t+n)},n);return h=t+n,o},o.caf=function(e){clearTimeout(e)}}return o.svg=!!document.createElementNS&&!!document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,i.features=o,o}};i.detectFeatures(),i.features.oldIE&&(i.bind=function(e,t,n,o){t=t.split(" ");for(var i,r=(o?"detach":"attach")+"Event",a=function(){n.handleEvent.call(n)},l=0;l<t.length;l++)if(i=t[l])if("object"==typeof n&&n.handleEvent){if(o){if(!n["oldIE"+i])return!1}else n["oldIE"+i]=a;e[r]("on"+i,n["oldIE"+i])}else e[r]("on"+i,n)});var r=this,a=25,l=3,u={allowPanToNext:!0,spacing:.12,bgOpacity:1,mouseUsed:!1,loop:!0,pinchToClose:!0,closeOnScroll:!0,closeOnVerticalDrag:!0,verticalDragRange:.75,hideAnimationDuration:333,showAnimationDuration:333,showHideOpacity:!1,focus:!0,escKey:!0,arrowKeys:!0,mainScrollEndFriction:.35,panEndFriction:.35,isClickableElement:function(e){return"A"===e.tagName},getDoubleTapZoom:function(e,t){return e?1:t.initialZoomLevel<.7?1:1.33},maxSpreadZoom:1.33,modal:!0,scaleMode:"fit"};i.extend(u,o);var s,c,f,d,p,m,h,v,y,g,w,x,b,T,S,C,I,E,_,O,M,D,k,A,F,P,L,R,Z,N,z,U,j,q,K,B,H,W,G,Y,V,X,J,$,Q,ee,te,ne,oe,ie,re,ae,le,ue,se,ce,fe,de=function(){return{x:0,y:0}},pe=de(),me=de(),he=de(),ve={},ye=0,ge={},we=de(),xe=0,be=!0,Te=[],Se={},Ce=!1,Ie=function(e,t){i.extend(r,t.publicMethods),Te.push(e)},Ee=function(e){var t=en();return e>t-1?e-t:e<0?t+e:e},_e={},Oe=function(e,t){return _e[e]||(_e[e]=[]),_e[e].push(t)},Me=function(e){var t=_e[e];if(t){var n=Array.prototype.slice.call(arguments);n.shift();for(var o=0;o<t.length;o++)t[o].apply(r,n)}},De=function(){return(new Date).getTime()},ke=function(e){se=e,r.bg.style.opacity=e*u.bgOpacity},Ae=function(e,t,n,o,i){(!Ce||i&&i!==r.currItem)&&(o/=i?i.fitRatio:r.currItem.fitRatio),e[D]=x+t+"px, "+n+"px"+b+" scale("+o+")"},Fe=function(e){ie&&(e&&(g>r.currItem.fitRatio?Ce||(pn(r.currItem,!1,!0),Ce=!0):Ce&&(pn(r.currItem),Ce=!1)),Ae(ie,he.x,he.y,g))},Pe=function(e){e.container&&Ae(e.container.style,e.initialPosition.x,e.initialPosition.y,e.initialZoomLevel,e)},Le=function(e,t){t[D]=x+e+"px, 0px"+b},Re=function(e,t){if(!u.loop&&t){var n=d+(we.x*ye-e)/we.x,o=Math.round(e-wt.x);(n<0&&o>0||n>=en()-1&&o<0)&&(e=wt.x+o*u.mainScrollEndFriction)}wt.x=e,Le(e,p)},Ze=function(e,t){var n=xt[e]-ge[e];return me[e]+pe[e]+n-n*(t/w)},Ne=function(e,t){e.x=t.x,e.y=t.y,t.id&&(e.id=t.id)},ze=function(e){e.x=Math.round(e.x),e.y=Math.round(e.y)},Ue=null,je=function(){Ue&&(i.unbind(document,"mousemove",je),i.addClass(e,"pswp--has_mouse"),u.mouseUsed=!0,Me("mouseUsed")),Ue=setTimeout(function(){Ue=null},100)},qe=function(){i.bind(document,"keydown",r),z.transform&&i.bind(r.scrollWrap,"click",r),u.mouseUsed||i.bind(document,"mousemove",je),i.bind(window,"resize scroll orientationchange",r),Me("bindEvents")},Ke=function(){i.unbind(window,"resize scroll orientationchange",r),i.unbind(window,"scroll",y.scroll),i.unbind(document,"keydown",r),i.unbind(document,"mousemove",je),z.transform&&i.unbind(r.scrollWrap,"click",r),G&&i.unbind(window,h,r),clearTimeout(U),Me("unbindEvents")},Be=function(e,t){var n=sn(r.currItem,ve,e);return t&&(oe=n),n},He=function(e){return e||(e=r.currItem),e.initialZoomLevel},We=function(e){return e||(e=r.currItem),e.w>0?u.maxSpreadZoom:1},Ge=function(e,t,n,o){return o===r.currItem.initialZoomLevel?(n[e]=r.currItem.initialPosition[e],!0):(n[e]=Ze(e,o),n[e]>t.min[e]?(n[e]=t.min[e],!0):n[e]<t.max[e]&&(n[e]=t.max[e],!0))},Ye=function(){if(D){var t=z.perspective&&!A;return x="translate"+(t?"3d(":"("),void(b=z.perspective?", 0px)":")")}D="left",i.addClass(e,"pswp--ie"),Le=function(e,t){t.left=e+"px"},Pe=function(e){var t=e.fitRatio>1?1:e.fitRatio,n=e.container.style,o=t*e.w,i=t*e.h;n.width=o+"px",n.height=i+"px",n.left=e.initialPosition.x+"px",n.top=e.initialPosition.y+"px"},Fe=function(){if(ie){var e=ie,t=r.currItem,n=t.fitRatio>1?1:t.fitRatio,o=n*t.w,i=n*t.h;e.width=o+"px",e.height=i+"px",e.left=he.x+"px",e.top=he.y+"px"}}},Ve=function(e){var t="";u.escKey&&27===e.keyCode?t="close":u.arrowKeys&&(37===e.keyCode?t="prev":39===e.keyCode&&(t="next")),t&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey||(e.preventDefault?e.preventDefault():e.returnValue=!1,r[t]()))},Xe=function(e){e&&(X||V||re||H)&&(e.preventDefault(),e.stopPropagation())},Je=function(){r.setScrollOffset(0,i.getScrollY())},$e={},Qe=0,et=function(e){$e[e]&&($e[e].raf&&P($e[e].raf),Qe--,delete $e[e])},tt=function(e){$e[e]&&et(e),$e[e]||(Qe++,$e[e]={})},nt=function(){for(var e in $e)$e.hasOwnProperty(e)&&et(e)},ot=function(e,t,n,o,i,r,a){var l,u=De();tt(e);var s=function(){if($e[e]){if(l=De()-u,l>=o)return et(e),r(n),void(a&&a());r((n-t)*i(l/o)+t),$e[e].raf=F(s)}};s()},it={shout:Me,listen:Oe,viewportSize:ve,options:u,isMainScrollAnimating:function(){return re},getZoomLevel:function(){return g},getCurrentIndex:function(){return d},isDragging:function(){return G},isZooming:function(){return ee},setScrollOffset:function(e,t){ge.x=e,N=ge.y=t,Me("updateScrollOffset",ge)},applyZoomPan:function(e,t,n,o){he.x=t,he.y=n,g=e,Fe(o)},init:function(){if(!s&&!c){var n;r.framework=i,r.template=e,r.bg=i.getChildByClass(e,"pswp__bg"),L=e.className,s=!0,z=i.detectFeatures(),F=z.raf,P=z.caf,D=z.transform,Z=z.oldIE,r.scrollWrap=i.getChildByClass(e,"pswp__scroll-wrap"),r.container=i.getChildByClass(r.scrollWrap,"pswp__container"),p=r.container.style,r.itemHolders=C=[{el:r.container.children[0],wrap:0,index:-1},{el:r.container.children[1],wrap:0,index:-1},{el:r.container.children[2],wrap:0,index:-1}],C[0].el.style.display=C[2].el.style.display="none",Ye(),y={resize:r.updateSize,orientationchange:function(){clearTimeout(U),U=setTimeout(function(){ve.x!==r.scrollWrap.clientWidth&&r.updateSize()},500)},scroll:Je,keydown:Ve,click:Xe};var o=z.isOldIOSPhone||z.isOldAndroid||z.isMobileOpera;for(z.animationName&&z.transform&&!o||(u.showAnimationDuration=u.hideAnimationDuration=0),n=0;n<Te.length;n++)r["init"+Te[n]]();if(t){var a=r.ui=new t(r,i);a.init()}Me("firstUpdate"),d=d||u.index||0,(isNaN(d)||d<0||d>=en())&&(d=0),r.currItem=Qt(d),(z.isOldIOSPhone||z.isOldAndroid)&&(be=!1),e.setAttribute("aria-hidden","false"),u.modal&&(be?e.style.position="fixed":(e.style.position="absolute",e.style.top=i.getScrollY()+"px")),void 0===N&&(Me("initialLayout"),N=R=i.getScrollY());var f="pswp--open ";for(u.mainClass&&(f+=u.mainClass+" "),u.showHideOpacity&&(f+="pswp--animate_opacity "),f+=A?"pswp--touch":"pswp--notouch",f+=z.animationName?" pswp--css_animation":"",f+=z.svg?" pswp--svg":"",i.addClass(e,f),r.updateSize(),m=-1,xe=null,n=0;n<l;n++)Le((n+m)*we.x,C[n].el.style);Z||i.bind(r.scrollWrap,v,r),Oe("initialZoomInEnd",function(){r.setContent(C[0],d-1),r.setContent(C[2],d+1),C[0].el.style.display=C[2].el.style.display="block",u.focus&&e.focus(),qe()}),r.setContent(C[1],d),r.updateCurrItem(),Me("afterInit"),be||(T=setInterval(function(){Qe||G||ee||g!==r.currItem.initialZoomLevel||r.updateSize()},1e3)),i.addClass(e,"pswp--visible")}},close:function(){s&&(s=!1,c=!0,Me("close"),Ke(),nn(r.currItem,null,!0,r.destroy))},destroy:function(){Me("destroy"),Vt&&clearTimeout(Vt),e.setAttribute("aria-hidden","true"),e.className=L,T&&clearInterval(T),i.unbind(r.scrollWrap,v,r),i.unbind(window,"scroll",r),It(),nt(),_e=null},panTo:function(e,t,n){n||(e>oe.min.x?e=oe.min.x:e<oe.max.x&&(e=oe.max.x),t>oe.min.y?t=oe.min.y:t<oe.max.y&&(t=oe.max.y)),he.x=e,he.y=t,Fe()},handleEvent:function(e){e=e||window.event,y[e.type]&&y[e.type](e)},goTo:function(e){e=Ee(e);var t=e-d;xe=t,d=e,r.currItem=Qt(d),ye-=t,Re(we.x*ye),nt(),re=!1,r.updateCurrItem()},next:function(){r.goTo(d+1)},prev:function(){r.goTo(d-1)},updateCurrZoomItem:function(e){if(e&&Me("beforeChange",0),C[1].el.children.length){var t=C[1].el.children[0];ie=i.hasClass(t,"pswp__zoom-wrap")?t.style:null}else ie=null;oe=r.currItem.bounds,w=g=r.currItem.initialZoomLevel,he.x=oe.center.x,he.y=oe.center.y,e&&Me("afterChange")},invalidateCurrItems:function(){S=!0;for(var e=0;e<l;e++)C[e].item&&(C[e].item.needsUpdate=!0)},updateCurrItem:function(e){if(0!==xe){var t,n=Math.abs(xe);if(!(e&&n<2)){r.currItem=Qt(d),Ce=!1,Me("beforeChange",xe),n>=l&&(m+=xe+(xe>0?-l:l),n=l);for(var o=0;o<n;o++)xe>0?(t=C.shift(),C[l-1]=t,m++,Le((m+2)*we.x,t.el.style),r.setContent(t,d-n+o+1+1)):(t=C.pop(),C.unshift(t),m--,Le(m*we.x,t.el.style),r.setContent(t,d+n-o-1-1));if(ie&&1===Math.abs(xe)){var i=Qt(I);i.initialZoomLevel!==g&&(sn(i,ve),pn(i),Pe(i))}xe=0,r.updateCurrZoomItem(),I=d,Me("afterChange")}}},updateSize:function(t){if(!be&&u.modal){var n=i.getScrollY();if(N!==n&&(e.style.top=n+"px",N=n),!t&&Se.x===window.innerWidth&&Se.y===window.innerHeight)return;Se.x=window.innerWidth,Se.y=window.innerHeight,e.style.height=Se.y+"px"}if(ve.x=r.scrollWrap.clientWidth,ve.y=r.scrollWrap.clientHeight,Je(),we.x=ve.x+Math.round(ve.x*u.spacing),we.y=ve.y,Re(we.x*ye),Me("beforeResize"),void 0!==m){for(var o,a,s,c=0;c<l;c++)o=C[c],Le((c+m)*we.x,o.el.style),s=d+c-1,u.loop&&en()>2&&(s=Ee(s)),a=Qt(s),a&&(S||a.needsUpdate||!a.bounds)?(r.cleanSlide(a),r.setContent(o,s),1===c&&(r.currItem=a,r.updateCurrZoomItem(!0)),a.needsUpdate=!1):o.index===-1&&s>=0&&r.setContent(o,s),a&&a.container&&(sn(a,ve),pn(a),Pe(a));S=!1}w=g=r.currItem.initialZoomLevel,oe=r.currItem.bounds,oe&&(he.x=oe.center.x,he.y=oe.center.y,Fe(!0)),Me("resize")},zoomTo:function(e,t,n,o,r){t&&(w=g,xt.x=Math.abs(t.x)-he.x,xt.y=Math.abs(t.y)-he.y,Ne(me,he));var a=Be(e,!1),l={};Ge("x",a,l,e),Ge("y",a,l,e);var u=g,s={x:he.x,y:he.y};ze(l);var c=function(t){1===t?(g=e,he.x=l.x,he.y=l.y):(g=(e-u)*t+u,he.x=(l.x-s.x)*t+s.x,he.y=(l.y-s.y)*t+s.y),r&&r(t),Fe(1===t)};n?ot("customZoomTo",0,1,n,o||i.easing.sine.inOut,c):c(1)}},rt=30,at=10,lt={},ut={},st={},ct={},ft={},dt=[],pt={},mt=[],ht={},vt=0,yt=de(),gt=0,wt=de(),xt=de(),bt=de(),Tt=function(e,t){return e.x===t.x&&e.y===t.y},St=function(e,t){return Math.abs(e.x-t.x)<a&&Math.abs(e.y-t.y)<a},Ct=function(e,t){return ht.x=Math.abs(e.x-t.x),ht.y=Math.abs(e.y-t.y),Math.sqrt(ht.x*ht.x+ht.y*ht.y)},It=function(){J&&(P(J),J=null)},Et=function(){G&&(J=F(Et),qt())},_t=function(){return!("fit"===u.scaleMode&&g===r.currItem.initialZoomLevel)},Ot=function(e,t){return!(!e||e===document)&&(!(e.getAttribute("class")&&e.getAttribute("class").indexOf("pswp__scroll-wrap")>-1)&&(t(e)?e:Ot(e.parentNode,t)))},Mt={},Dt=function(e,t){return Mt.prevent=!Ot(e.target,u.isClickableElement),Me("preventDragEvent",e,t,Mt),Mt.prevent},kt=function(e,t){return t.x=e.pageX,t.y=e.pageY,t.id=e.identifier,t},At=function(e,t,n){n.x=.5*(e.x+t.x),n.y=.5*(e.y+t.y)},Ft=function(e,t,n){if(e-q>50){var o=mt.length>2?mt.shift():{};o.x=t,o.y=n,mt.push(o),q=e}},Pt=function(){var e=he.y-r.currItem.initialPosition.y;return 1-Math.abs(e/(ve.y/2))},Lt={},Rt={},Zt=[],Nt=function(e){for(;Zt.length>0;)Zt.pop();return k?(fe=0,dt.forEach(function(e){0===fe?Zt[0]=e:1===fe&&(Zt[1]=e),fe++})):e.type.indexOf("touch")>-1?e.touches&&e.touches.length>0&&(Zt[0]=kt(e.touches[0],Lt),e.touches.length>1&&(Zt[1]=kt(e.touches[1],Rt))):(Lt.x=e.pageX,Lt.y=e.pageY,Lt.id="",Zt[0]=Lt),Zt},zt=function(e,t){var n,o,i,a,l=0,s=he[e]+t[e],c=t[e]>0,f=wt.x+t.x,d=wt.x-pt.x;return n=s>oe.min[e]||s<oe.max[e]?u.panEndFriction:1,s=he[e]+t[e]*n,!u.allowPanToNext&&g!==r.currItem.initialZoomLevel||(ie?"h"!==ae||"x"!==e||V||(c?(s>oe.min[e]&&(n=u.panEndFriction,l=oe.min[e]-s,o=oe.min[e]-me[e]),(o<=0||d<0)&&en()>1?(a=f,d<0&&f>pt.x&&(a=pt.x)):oe.min.x!==oe.max.x&&(i=s)):(s<oe.max[e]&&(n=u.panEndFriction,l=s-oe.max[e],o=me[e]-oe.max[e]),(o<=0||d>0)&&en()>1?(a=f,d>0&&f<pt.x&&(a=pt.x)):oe.min.x!==oe.max.x&&(i=s))):a=f,"x"!==e)?void(re||$||g>r.currItem.fitRatio&&(he[e]+=t[e]*n)):(void 0!==a&&(Re(a,!0),$=a!==pt.x),oe.min.x!==oe.max.x&&(void 0!==i?he.x=i:$||(he.x+=t.x*n)),void 0!==a)},Ut=function(e){if(!("mousedown"===e.type&&e.button>0)){if($t)return void e.preventDefault();if(!W||"mousedown"!==e.type){if(Dt(e,!0)&&e.preventDefault(),Me("pointerDown"),k){var t=i.arraySearch(dt,e.pointerId,"id");t<0&&(t=dt.length),dt[t]={x:e.pageX,y:e.pageY,id:e.pointerId}}var n=Nt(e),o=n.length;Q=null,nt(),G&&1!==o||(G=le=!0,i.bind(window,h,r),B=ce=ue=H=$=X=Y=V=!1,ae=null,Me("firstTouchStart",n),Ne(me,he),pe.x=pe.y=0,Ne(ct,n[0]),Ne(ft,ct),pt.x=we.x*ye,mt=[{x:ct.x,y:ct.y}],q=j=De(),Be(g,!0),It(),Et()),!ee&&o>1&&!re&&!$&&(w=g,V=!1,ee=Y=!0,pe.y=pe.x=0,Ne(me,he),Ne(lt,n[0]),Ne(ut,n[1]),At(lt,ut,bt),xt.x=Math.abs(bt.x)-he.x,xt.y=Math.abs(bt.y)-he.y,te=ne=Ct(lt,ut))}}},jt=function(e){if(e.preventDefault(),k){var t=i.arraySearch(dt,e.pointerId,"id");if(t>-1){var n=dt[t];n.x=e.pageX,n.y=e.pageY}}if(G){var o=Nt(e);if(ae||X||ee)Q=o;else if(wt.x!==we.x*ye)ae="h";else{var r=Math.abs(o[0].x-ct.x)-Math.abs(o[0].y-ct.y);Math.abs(r)>=at&&(ae=r>0?"h":"v",Q=o)}}},qt=function(){if(Q){var e=Q.length;if(0!==e)if(Ne(lt,Q[0]),st.x=lt.x-ct.x,st.y=lt.y-ct.y,ee&&e>1){if(ct.x=lt.x,ct.y=lt.y,!st.x&&!st.y&&Tt(Q[1],ut))return;Ne(ut,Q[1]),V||(V=!0,Me("zoomGestureStarted"));var t=Ct(lt,ut),n=Gt(t);n>r.currItem.initialZoomLevel+r.currItem.initialZoomLevel/15&&(ce=!0);var o=1,i=He(),a=We();if(n<i)if(u.pinchToClose&&!ce&&w<=r.currItem.initialZoomLevel){var l=i-n,s=1-l/(i/1.2);ke(s),Me("onPinchClose",s),ue=!0}else o=(i-n)/i,o>1&&(o=1),n=i-o*(i/3);else n>a&&(o=(n-a)/(6*i),o>1&&(o=1),n=a+o*i);o<0&&(o=0),te=t,At(lt,ut,yt),pe.x+=yt.x-bt.x,pe.y+=yt.y-bt.y,Ne(bt,yt),he.x=Ze("x",n),he.y=Ze("y",n),B=n>g,g=n,Fe()}else{if(!ae)return;if(le&&(le=!1,Math.abs(st.x)>=at&&(st.x-=Q[0].x-ft.x),Math.abs(st.y)>=at&&(st.y-=Q[0].y-ft.y)),ct.x=lt.x,ct.y=lt.y,0===st.x&&0===st.y)return;if("v"===ae&&u.closeOnVerticalDrag&&!_t()){pe.y+=st.y,he.y+=st.y;var c=Pt();return H=!0,Me("onVerticalDrag",c),ke(c),void Fe()}Ft(De(),lt.x,lt.y),X=!0,oe=r.currItem.bounds;var f=zt("x",st);f||(zt("y",st),ze(he),Fe())}}},Kt=function(e){if(z.isOldAndroid){if(W&&"mouseup"===e.type)return;e.type.indexOf("touch")>-1&&(clearTimeout(W),W=setTimeout(function(){W=0},600))}Me("pointerUp"),Dt(e,!1)&&e.preventDefault();var t;if(k){var n=i.arraySearch(dt,e.pointerId,"id");if(n>-1)if(t=dt.splice(n,1)[0],navigator.msPointerEnabled){var o={4:"mouse",2:"touch",3:"pen"};t.type=o[e.pointerType],t.type||(t.type=e.pointerType||"mouse")}else t.type=e.pointerType||"mouse"}var a,l=Nt(e),s=l.length;if("mouseup"===e.type&&(s=0),2===s)return Q=null,!0;1===s&&Ne(ft,l[0]),0!==s||ae||re||(t||("mouseup"===e.type?t={x:e.pageX,y:e.pageY,type:"mouse"}:e.changedTouches&&e.changedTouches[0]&&(t={x:e.changedTouches[0].pageX,y:e.changedTouches[0].pageY,type:"touch"})),Me("touchRelease",e,t));var c=-1;if(0===s&&(G=!1,i.unbind(window,h,r),It(),ee?c=0:gt!==-1&&(c=De()-gt)),gt=1===s?De():-1,a=c!==-1&&c<150?"zoom":"swipe",ee&&s<2&&(ee=!1,1===s&&(a="zoomPointerUp"),Me("zoomGestureEnded")),Q=null,X||V||re||H)if(nt(),K||(K=Bt()),K.calculateSwipeSpeed("x"),H){var f=Pt();if(f<u.verticalDragRange)r.close();else{var d=he.y,p=se;ot("verticalDrag",0,1,300,i.easing.cubic.out,function(e){he.y=(r.currItem.initialPosition.y-d)*e+d,ke((1-p)*e+p),Fe()}),Me("onVerticalDrag",1)}}else{if(($||re)&&0===s){var m=Wt(a,K);if(m)return;a="zoomPointerUp"}if(!re)return"swipe"!==a?void Yt():void(!$&&g>r.currItem.fitRatio&&Ht(K))}},Bt=function(){var e,t,n={lastFlickOffset:{},lastFlickDist:{},lastFlickSpeed:{},slowDownRatio:{},slowDownRatioReverse:{},speedDecelerationRatio:{},speedDecelerationRatioAbs:{},distanceOffset:{},backAnimDestination:{},backAnimStarted:{},calculateSwipeSpeed:function(o){mt.length>1?(e=De()-q+50,t=mt[mt.length-2][o]):(e=De()-j,t=ft[o]),n.lastFlickOffset[o]=ct[o]-t,n.lastFlickDist[o]=Math.abs(n.lastFlickOffset[o]),n.lastFlickDist[o]>20?n.lastFlickSpeed[o]=n.lastFlickOffset[o]/e:n.lastFlickSpeed[o]=0,Math.abs(n.lastFlickSpeed[o])<.1&&(n.lastFlickSpeed[o]=0),n.slowDownRatio[o]=.95,n.slowDownRatioReverse[o]=1-n.slowDownRatio[o],n.speedDecelerationRatio[o]=1},calculateOverBoundsAnimOffset:function(e,t){n.backAnimStarted[e]||(he[e]>oe.min[e]?n.backAnimDestination[e]=oe.min[e]:he[e]<oe.max[e]&&(n.backAnimDestination[e]=oe.max[e]),void 0!==n.backAnimDestination[e]&&(n.slowDownRatio[e]=.7,n.slowDownRatioReverse[e]=1-n.slowDownRatio[e],n.speedDecelerationRatioAbs[e]<.05&&(n.lastFlickSpeed[e]=0,n.backAnimStarted[e]=!0,ot("bounceZoomPan"+e,he[e],n.backAnimDestination[e],t||300,i.easing.sine.out,function(t){he[e]=t,Fe()}))))},calculateAnimOffset:function(e){n.backAnimStarted[e]||(n.speedDecelerationRatio[e]=n.speedDecelerationRatio[e]*(n.slowDownRatio[e]+n.slowDownRatioReverse[e]-n.slowDownRatioReverse[e]*n.timeDiff/10),n.speedDecelerationRatioAbs[e]=Math.abs(n.lastFlickSpeed[e]*n.speedDecelerationRatio[e]),n.distanceOffset[e]=n.lastFlickSpeed[e]*n.speedDecelerationRatio[e]*n.timeDiff,he[e]+=n.distanceOffset[e])},panAnimLoop:function(){if($e.zoomPan&&($e.zoomPan.raf=F(n.panAnimLoop),n.now=De(),n.timeDiff=n.now-n.lastNow,n.lastNow=n.now,n.calculateAnimOffset("x"),n.calculateAnimOffset("y"),Fe(),n.calculateOverBoundsAnimOffset("x"),n.calculateOverBoundsAnimOffset("y"),n.speedDecelerationRatioAbs.x<.05&&n.speedDecelerationRatioAbs.y<.05))return he.x=Math.round(he.x),he.y=Math.round(he.y),Fe(),void et("zoomPan")}};return n},Ht=function(e){return e.calculateSwipeSpeed("y"),oe=r.currItem.bounds,e.backAnimDestination={},e.backAnimStarted={},Math.abs(e.lastFlickSpeed.x)<=.05&&Math.abs(e.lastFlickSpeed.y)<=.05?(e.speedDecelerationRatioAbs.x=e.speedDecelerationRatioAbs.y=0,e.calculateOverBoundsAnimOffset("x"),e.calculateOverBoundsAnimOffset("y"),!0):(tt("zoomPan"),e.lastNow=De(),void e.panAnimLoop())},Wt=function(e,t){var n;re||(vt=d);var o;if("swipe"===e){var a=ct.x-ft.x,l=t.lastFlickDist.x<10;a>rt&&(l||t.lastFlickOffset.x>20)?o=-1:a<-rt&&(l||t.lastFlickOffset.x<-20)&&(o=1)}var s;o&&(d+=o,d<0?(d=u.loop?en()-1:0,s=!0):d>=en()&&(d=u.loop?0:en()-1,s=!0),s&&!u.loop||(xe+=o,ye-=o,n=!0));var c,f=we.x*ye,p=Math.abs(f-wt.x);return n||f>wt.x==t.lastFlickSpeed.x>0?(c=Math.abs(t.lastFlickSpeed.x)>0?p/Math.abs(t.lastFlickSpeed.x):333,c=Math.min(c,400),c=Math.max(c,250)):c=333,vt===d&&(n=!1),re=!0,Me("mainScrollAnimStart"),ot("mainScroll",wt.x,f,c,i.easing.cubic.out,Re,function(){nt(),re=!1,vt=-1,(n||vt!==d)&&r.updateCurrItem(),Me("mainScrollAnimComplete")}),n&&r.updateCurrItem(!0),n},Gt=function(e){return 1/ne*e*w},Yt=function(){var e=g,t=He(),n=We();g<t?e=t:g>n&&(e=n);var o,a=1,l=se;return ue&&!B&&!ce&&g<t?(r.close(),!0):(ue&&(o=function(e){ke((a-l)*e+l)}),r.zoomTo(e,0,200,i.easing.cubic.out,o),!0)};Ie("Gestures",{publicMethods:{initGestures:function(){var e=function(e,t,n,o,i){E=e+t,_=e+n,O=e+o,M=i?e+i:""};k=z.pointerEvent,k&&z.touch&&(z.touch=!1),k?navigator.msPointerEnabled?e("MSPointer","Down","Move","Up","Cancel"):e("pointer","down","move","up","cancel"):z.touch?(e("touch","start","move","end","cancel"),A=!0):e("mouse","down","move","up"),h=_+" "+O+" "+M,v=E,k&&!A&&(A=navigator.maxTouchPoints>1||navigator.msMaxTouchPoints>1),r.likelyTouchDevice=A,y[E]=Ut,y[_]=jt,y[O]=Kt,M&&(y[M]=y[O]),z.touch&&(v+=" mousedown",h+=" mousemove mouseup",y.mousedown=y[E],y.mousemove=y[_],y.mouseup=y[O]),A||(u.allowPanToNext=!1)}}});var Vt,Xt,Jt,$t,Qt,en,tn,nn=function(t,n,o,a){Vt&&clearTimeout(Vt),$t=!0,Jt=!0;var l;t.initialLayout?(l=t.initialLayout,t.initialLayout=null):l=u.getThumbBoundsFn&&u.getThumbBoundsFn(d);var s=o?u.hideAnimationDuration:u.showAnimationDuration,c=function(){et("initialZoom"),o?(r.template.removeAttribute("style"),r.bg.removeAttribute("style")):(ke(1),n&&(n.style.display="block"),i.addClass(e,"pswp--animated-in"),Me("initialZoom"+(o?"OutEnd":"InEnd"))),a&&a(),$t=!1};if(!s||!l||void 0===l.x)return Me("initialZoom"+(o?"Out":"In")),g=t.initialZoomLevel,Ne(he,t.initialPosition),Fe(),e.style.opacity=o?0:1,ke(1),void(s?setTimeout(function(){c()},s):c());var p=function(){var n=f,a=!r.currItem.src||r.currItem.loadError||u.showHideOpacity;t.miniImg&&(t.miniImg.style.webkitBackfaceVisibility="hidden"),o||(g=l.w/t.w,he.x=l.x,he.y=l.y-R,r[a?"template":"bg"].style.opacity=.001,Fe()),tt("initialZoom"),o&&!n&&i.removeClass(e,"pswp--animated-in"),a&&(o?i[(n?"remove":"add")+"Class"](e,"pswp--animate_opacity"):setTimeout(function(){i.addClass(e,"pswp--animate_opacity")},30)),Vt=setTimeout(function(){if(Me("initialZoom"+(o?"Out":"In")),o){var r=l.w/t.w,u={x:he.x,y:he.y},f=g,d=se,p=function(t){1===t?(g=r,he.x=l.x,he.y=l.y-N):(g=(r-f)*t+f,he.x=(l.x-u.x)*t+u.x,he.y=(l.y-N-u.y)*t+u.y),Fe(),a?e.style.opacity=1-t:ke(d-t*d)};n?ot("initialZoom",0,1,s,i.easing.cubic.out,p,c):(p(1),Vt=setTimeout(c,s+20))}else g=t.initialZoomLevel,Ne(he,t.initialPosition),Fe(),ke(1),a?e.style.opacity=1:ke(1),Vt=setTimeout(c,s+20)},o?25:90)};p()},on={},rn=[],an={index:0,errorMsg:'<div class="pswp__error-msg"><a href="%url%" target="_blank">The image</a> could not be loaded.</div>',forceProgressiveLoading:!1,preload:[1,1],getNumItemsFn:function(){return Xt.length}},ln=function(){return{center:{x:0,y:0},max:{x:0,y:0},min:{x:0,y:0}}},un=function(e,t,n){var o=e.bounds;o.center.x=Math.round((on.x-t)/2),o.center.y=Math.round((on.y-n)/2)+e.vGap.top,o.max.x=t>on.x?Math.round(on.x-t):o.center.x,o.max.y=n>on.y?Math.round(on.y-n)+e.vGap.top:o.center.y,o.min.x=t>on.x?0:o.center.x,o.min.y=n>on.y?e.vGap.top:o.center.y},sn=function(e,t,n){if(e.src&&!e.loadError){var o=!n;if(o&&(e.vGap||(e.vGap={top:0,bottom:0}),Me("parseVerticalMargin",e)),on.x=t.x,on.y=t.y-e.vGap.top-e.vGap.bottom,o){var i=on.x/e.w,r=on.y/e.h;e.fitRatio=i<r?i:r;var a=u.scaleMode;"orig"===a?n=1:"fit"===a&&(n=e.fitRatio),n>1&&(n=1),e.initialZoomLevel=n,e.bounds||(e.bounds=ln())}if(!n)return;return un(e,e.w*n,e.h*n),o&&n===e.initialZoomLevel&&(e.initialPosition=e.bounds.center),e.bounds}return e.w=e.h=0,e.initialZoomLevel=e.fitRatio=1,e.bounds=ln(),e.initialPosition=e.bounds.center,e.bounds},cn=function(e,t,n,o,i,a){t.loadError||o&&(t.imageAppended=!0,pn(t,o,t===r.currItem&&Ce),n.appendChild(o),a&&setTimeout(function(){t&&t.loaded&&t.placeholder&&(t.placeholder.style.display="none",t.placeholder=null)},500))},fn=function(e){e.loading=!0,e.loaded=!1;var t=e.img=i.createEl("pswp__img","img"),n=function(){e.loading=!1,e.loaded=!0,e.loadComplete?e.loadComplete(e):e.img=null,t.onload=t.onerror=null,t=null};return t.onload=n,t.onerror=function(){e.loadError=!0,n()},t.src=e.src,t},dn=function(e,t){if(e.src&&e.loadError&&e.container)return t&&(e.container.innerHTML=""),e.container.innerHTML=u.errorMsg.replace("%url%",e.src),!0},pn=function(e,t,n){if(e.src){t||(t=e.container.lastChild);var o=n?e.w:Math.round(e.w*e.fitRatio),i=n?e.h:Math.round(e.h*e.fitRatio);e.placeholder&&!e.loaded&&(e.placeholder.style.width=o+"px",e.placeholder.style.height=i+"px"),t.style.width=o+"px",t.style.height=i+"px"}},mn=function(){if(rn.length){for(var e,t=0;t<rn.length;t++)e=rn[t],e.holder.index===e.index&&cn(e.index,e.item,e.baseDiv,e.img,!1,e.clearPlaceholder);rn=[]}};Ie("Controller",{publicMethods:{lazyLoadItem:function(e){e=Ee(e);var t=Qt(e);t&&(!t.loaded&&!t.loading||S)&&(Me("gettingData",e,t),t.src&&fn(t))},initController:function(){i.extend(u,an,!0),r.items=Xt=n,Qt=r.getItemAt,en=u.getNumItemsFn,tn=u.loop,en()<3&&(u.loop=!1),Oe("beforeChange",function(e){var t,n=u.preload,o=null===e||e>=0,i=Math.min(n[0],en()),a=Math.min(n[1],en());for(t=1;t<=(o?a:i);t++)r.lazyLoadItem(d+t);for(t=1;t<=(o?i:a);t++)r.lazyLoadItem(d-t)}),Oe("initialLayout",function(){r.currItem.initialLayout=u.getThumbBoundsFn&&u.getThumbBoundsFn(d)}),Oe("mainScrollAnimComplete",mn),Oe("initialZoomInEnd",mn),Oe("destroy",function(){for(var e,t=0;t<Xt.length;t++)e=Xt[t],e.container&&(e.container=null),e.placeholder&&(e.placeholder=null),e.img&&(e.img=null),e.preloader&&(e.preloader=null),e.loadError&&(e.loaded=e.loadError=!1);rn=null})},getItemAt:function(e){return e>=0&&(void 0!==Xt[e]&&Xt[e])},allowProgressiveImg:function(){return u.forceProgressiveLoading||!A||u.mouseUsed||screen.width>1200},setContent:function(e,t){u.loop&&(t=Ee(t));var n=r.getItemAt(e.index);n&&(n.container=null);var o,a=r.getItemAt(t);if(!a)return void(e.el.innerHTML="");Me("gettingData",t,a),e.index=t,e.item=a;var l=a.container=i.createEl("pswp__zoom-wrap");if(!a.src&&a.html&&(a.html.tagName?l.appendChild(a.html):l.innerHTML=a.html),dn(a),sn(a,ve),!a.src||a.loadError||a.loaded)a.src&&!a.loadError&&(o=i.createEl("pswp__img","img"),o.style.opacity=1,o.src=a.src,pn(a,o),cn(t,a,l,o,!0));else{if(a.loadComplete=function(n){if(s){if(e&&e.index===t){if(dn(n,!0))return n.loadComplete=n.img=null,sn(n,ve),Pe(n),void(e.index===d&&r.updateCurrZoomItem());n.imageAppended?!$t&&n.placeholder&&(n.placeholder.style.display="none",n.placeholder=null):z.transform&&(re||$t)?rn.push({item:n,baseDiv:l,img:n.img,index:t,holder:e,clearPlaceholder:!0}):cn(t,n,l,n.img,re||$t,!0)}n.loadComplete=null,n.img=null,Me("imageLoadComplete",t,n)}},i.features.transform){var c="pswp__img pswp__img--placeholder";c+=a.msrc?"":" pswp__img--placeholder--blank";var f=i.createEl(c,a.msrc?"img":"");a.msrc&&(f.src=a.msrc),pn(a,f),l.appendChild(f),a.placeholder=f}a.loading||fn(a),r.allowProgressiveImg()&&(!Jt&&z.transform?rn.push({item:a,baseDiv:l,img:a.img,index:t,holder:e}):cn(t,a,l,a.img,!0,!0))}Jt||t!==d?Pe(a):(ie=l.style,nn(a,o||a.img)),e.el.innerHTML="",e.el.appendChild(l)},cleanSlide:function(e){e.img&&(e.img.onload=e.img.onerror=null),e.loaded=e.loading=e.img=e.imageAppended=!1}}});var hn,vn={},yn=function(e,t,n){var o=document.createEvent("CustomEvent"),i={origEvent:e,target:e.target,releasePoint:t,pointerType:n||"touch"};o.initCustomEvent("pswpTap",!0,!0,i),e.target.dispatchEvent(o)};Ie("Tap",{publicMethods:{initTap:function(){Oe("firstTouchStart",r.onTapStart),Oe("touchRelease",r.onTapRelease),Oe("destroy",function(){vn={},hn=null})},onTapStart:function(e){e.length>1&&(clearTimeout(hn),hn=null)},onTapRelease:function(e,t){if(t&&!X&&!Y&&!Qe){var n=t;if(hn&&(clearTimeout(hn),hn=null,St(n,vn)))return void Me("doubleTap",n);if("mouse"===t.type)return void yn(e,t,"mouse");var o=e.target.tagName.toUpperCase();if("BUTTON"===o||i.hasClass(e.target,"pswp__single-tap"))return void yn(e,t);Ne(vn,n),hn=setTimeout(function(){yn(e,t),hn=null},300)}}}});var gn;Ie("DesktopZoom",{publicMethods:{initDesktopZoom:function(){Z||(A?Oe("mouseUsed",function(){r.setupDesktopZoom()}):r.setupDesktopZoom(!0))},setupDesktopZoom:function(t){gn={};var n="wheel mousewheel DOMMouseScroll";Oe("bindEvents",function(){i.bind(e,n,r.handleMouseWheel)}),Oe("unbindEvents",function(){gn&&i.unbind(e,n,r.handleMouseWheel)}),r.mouseZoomedIn=!1;var o,a=function(){r.mouseZoomedIn&&(i.removeClass(e,"pswp--zoomed-in"),r.mouseZoomedIn=!1),g<1?i.addClass(e,"pswp--zoom-allowed"):i.removeClass(e,"pswp--zoom-allowed"),l()},l=function(){o&&(i.removeClass(e,"pswp--dragging"),o=!1)};Oe("resize",a),Oe("afterChange",a),Oe("pointerDown",function(){r.mouseZoomedIn&&(o=!0,i.addClass(e,"pswp--dragging"))}),Oe("pointerUp",l),t||a()},handleMouseWheel:function(e){if(g<=r.currItem.fitRatio)return u.modal&&(!u.closeOnScroll||Qe||G?e.preventDefault():D&&Math.abs(e.deltaY)>2&&(f=!0,r.close())),!0;if(e.stopPropagation(),gn.x=0,"deltaX"in e)1===e.deltaMode?(gn.x=18*e.deltaX,gn.y=18*e.deltaY):(gn.x=e.deltaX,gn.y=e.deltaY);else if("wheelDelta"in e)e.wheelDeltaX&&(gn.x=-.16*e.wheelDeltaX),e.wheelDeltaY?gn.y=-.16*e.wheelDeltaY:gn.y=-.16*e.wheelDelta;else{if(!("detail"in e))return;gn.y=e.detail}Be(g,!0);var t=he.x-gn.x,n=he.y-gn.y;(u.modal||t<=oe.min.x&&t>=oe.max.x&&n<=oe.min.y&&n>=oe.max.y)&&e.preventDefault(),r.panTo(t,n)},toggleDesktopZoom:function(t){t=t||{x:ve.x/2+ge.x,y:ve.y/2+ge.y};var n=u.getDoubleTapZoom(!0,r.currItem),o=g===n;r.mouseZoomedIn=!o,r.zoomTo(o?r.currItem.initialZoomLevel:n,t,333),i[(o?"remove":"add")+"Class"](e,"pswp--zoomed-in")}}});var wn,xn,bn,Tn,Sn,Cn,In,En,_n,On,Mn,Dn,kn={history:!0,galleryUID:1},An=function(){return Mn.hash.substring(1)},Fn=function(){wn&&clearTimeout(wn),bn&&clearTimeout(bn)},Pn=function(){var e=An(),t={};if(e.length<5)return t;var n,o=e.split("&");for(n=0;n<o.length;n++)if(o[n]){var i=o[n].split("=");i.length<2||(t[i[0]]=i[1])}if(u.galleryPIDs){var r=t.pid;for(t.pid=0,n=0;n<Xt.length;n++)if(Xt[n].pid===r){t.pid=n;break}}else t.pid=parseInt(t.pid,10)-1;return t.pid<0&&(t.pid=0),t},Ln=function(){if(bn&&clearTimeout(bn),Qe||G)return void(bn=setTimeout(Ln,500));Tn?clearTimeout(xn):Tn=!0;var e=d+1,t=Qt(d);t.hasOwnProperty("pid")&&(e=t.pid);var n=In+"&gid="+u.galleryUID+"&pid="+e;En||Mn.hash.indexOf(n)===-1&&(On=!0);var o=Mn.href.split("#")[0]+"#"+n;Dn?"#"+n!==window.location.hash&&history[En?"replaceState":"pushState"]("",document.title,o):En?Mn.replace(o):Mn.hash=n,En=!0,xn=setTimeout(function(){Tn=!1},60)};Ie("History",{publicMethods:{initHistory:function(){if(i.extend(u,kn,!0),u.history){Mn=window.location,On=!1,_n=!1,En=!1,In=An(),Dn="pushState"in history,In.indexOf("gid=")>-1&&(In=In.split("&gid=")[0],In=In.split("?gid=")[0]),Oe("afterChange",r.updateURL),Oe("unbindEvents",function(){i.unbind(window,"hashchange",r.onHashChange)});var e=function(){Cn=!0,_n||(On?history.back():In?Mn.hash=In:Dn?history.pushState("",document.title,Mn.pathname+Mn.search):Mn.hash=""),Fn()};Oe("unbindEvents",function(){f&&e()}),Oe("destroy",function(){Cn||e()}),Oe("firstUpdate",function(){d=Pn().pid});var t=In.indexOf("pid=");t>-1&&(In=In.substring(0,t),"&"===In.slice(-1)&&(In=In.slice(0,-1))),setTimeout(function(){s&&i.bind(window,"hashchange",r.onHashChange)},40)}},onHashChange:function(){return An()===In?(_n=!0,void r.close()):void(Tn||(Sn=!0,r.goTo(Pn().pid),Sn=!1))},updateURL:function(){Fn(),Sn||(En?wn=setTimeout(Ln,800):Ln())}}}),i.extend(r,it)};return e})}});
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化