/*! Amaze UI v3.0.0-alpha.beta | by Amaze UI Team | (c) 2017 AllMobilize, Inc. | Licensed under GPL | 2017-03-06T14:24:38+0800 */ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],e):"object"==typeof exports?exports.AMUI=e(require("jquery")):t.AMUI=e(t.jQuery)}(this,function(t){return function(t){function e(n){if(i[n])return i[n].exports;var s=i[n]={exports:{},id:n,loaded:!1};return t[n].call(s.exports,s,s.exports,e),s.loaded=!0,s.exports}var i={};return e.m=t,e.c=i,e.p="",e(0)}([function(t,e,i){"use strict";var n=i(1),s=i(2);i(3),i(4),i(5),i(6),i(7),i(8),i(9),i(10),i(11),i(12),i(13),i(14),i(15),i(16),i(17),i(18),i(19),i(21),i(22),i(20),i(23),i(24),i(25),i(26),i(27),i(28),i(29),i(30),i(31),t.exports=n.AMUI=s},function(e,i){e.exports=t},function(t,e,i){"use strict";var n=i(1);if("undefined"==typeof n)throw new Error("Amaze UI 3.x requires jQuery");var s=n.AMUI||{},o=n(window),a=window.document,r=n("html");s.VERSION="3.0.0-alpha.beta",s.support={},s.support.transition=function(){var t=function(){var t=a.body||a.documentElement,e={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var i in e)if(void 0!==t.style[i])return e[i]}();return t&&{end:t}}(),s.support.animation=function(){var t=function(){var t=a.body||a.documentElement,e={WebkitAnimation:"webkitAnimationEnd",MozAnimation:"animationend",OAnimation:"oAnimationEnd oanimationend",animation:"animationend"};for(var i in e)if(void 0!==t.style[i])return e[i]}();return t&&{end:t}}(),s.support.touch="ontouchstart"in window&&navigator.userAgent.toLowerCase().match(/mobile|tablet/)||window.DocumentTouch&&document instanceof window.DocumentTouch||window.navigator.msPointerEnabled&&window.navigator.msMaxTouchPoints>0||window.navigator.pointerEnabled&&window.navigator.maxTouchPoints>0||!1,s.support.mutationobserver=window.MutationObserver||window.WebKitMutationObserver||null,s.support.formValidation="function"==typeof document.createElement("form").checkValidity,s.utils={},s.utils.debounce=function(t,e,i){var n;return function(){var s=this,o=arguments,a=function(){n=null,i||t.apply(s,o)},r=i&&!n;clearTimeout(n),n=setTimeout(a,e),r&&t.apply(s,o)}},s.utils.isInView=function(t,e){var i=n(t),s=!(!i.width()&&!i.height())&&"none"!==i.css("display");if(!s)return!1;var a=o.scrollLeft(),r=o.scrollTop(),l=i.offset(),c=l.left,h=l.top;return e=n.extend({topOffset:0,leftOffset:0},e),h+i.height()>=r&&h-e.topOffset<=r+o.height()&&c+i.width()>=a&&c-e.leftOffset<=a+o.width()},s.utils.parseOptions=s.utils.options=function(t){if(n.isPlainObject(t))return t;var e=t?t.indexOf("{"):-1,i={};if(e!=-1)try{i=new Function("","var json = "+t.substr(e)+"; return JSON.parse(JSON.stringify(json));")()}catch(s){}return i},s.utils.generateGUID=function(t){var e=t+"-"||"am-";do e+=Math.random().toString(36).substring(2,7);while(document.getElementById(e));return e},s.utils.getAbsoluteUrl=function(){var t;return function(e){return t||(t=document.createElement("a")),t.href=e,t.href}}(),s.plugin=function(t,e,i){var o=n.fn[t];i=i||{},n.fn[t]=function(o){var a,r=Array.prototype.slice.call(arguments,0),l=r.slice(1),c=this.each(function(){var c=n(this),h="amui."+t,d=i.dataOptions||"data-am-"+t,u=c.data(h),p=n.extend({},s.utils.parseOptions(c.attr(d)),"object"==typeof o&&o);(u||"destroy"!==o)&&(u||c.data(h,u=new e(this,p)),i.methodCall?i.methodCall.call(c,r,u):(i.before&&i.before.call(c,r,u),"string"==typeof o&&(a="function"==typeof u[o]?u[o].apply(u,l):u[o]),i.after&&i.after.call(c,r,u)))});return void 0===a?c:a},n.fn[t].Constructor=e,n.fn[t].noConflict=function(){return n.fn[t]=o,this},s[t]=e},n.fn.emulateTransitionEnd=function(t){var e=!1,i=this;n(this).one(s.support.transition.end,function(){e=!0});var o=function(){e||n(i).trigger(s.support.transition.end),i.transitionEndTimmer=void 0};return this.transitionEndTimmer=setTimeout(o,t),this},n.fn.redraw=function(){return this.each(function(){this.offsetHeight})},n.fn.transitionEnd=function(t){function e(s){t.call(this,s),i&&n.off(i,e)}var i=s.support.transition.end,n=this;return t&&i&&n.on(i,e),this},n.fn.removeClassRegEx=function(){return this.each(function(t){var e=n(this).attr("class");if(!e||!t)return!1;var i=[];e=e.split(" ");for(var s=0,o=e.length;s=window.innerWidth)return 0;var t=n('
');n(document.body).append(t);var e=t[0].offsetWidth-t[0].clientWidth;return t.remove(),e},s.utils.imageLoader=function(t,e){function i(){e(t[0])}function n(){if(this.one("load",i),/MSIE (\d+\.\d+);/.test(navigator.userAgent)){var t=this.attr("src"),e=t.match(/\?/)?"&":"?";e+="random="+(new Date).getTime(),this.attr("src",t+e)}}return t.attr("src")?void(t[0].complete||4===t[0].readyState?i():n.call(t)):void i()},s.template=function(t,e){var i=s.template;return i.cache[t]||(i.cache[t]=function(){var e=t,n=/^[\w\-]+$/.test(t)?i.get(t):(e="template(string)",t),s=1,o=("try { "+(i.variable?"var "+i.variable+" = this.stash;":"with (this.stash) { ")+"this.ret += '"+n.replace(/<%/g,"\x11").replace(/%>/g,"\x13").replace(/'(?![^\x11\x13]+?\x13)/g,"\\x27").replace(/^\s*|\s*$/g,"").replace(/\n/g,function(){return"';\nthis.line = "+ ++s+"; this.ret += '\\n"}).replace(/\x11-(.+?)\x13/g,"' + ($1) + '").replace(/\x11=(.+?)\x13/g,"' + this.escapeHTML($1) + '").replace(/\x11(.+?)\x13/g,"'; $1; this.ret += '")+"'; "+(i.variable?"":"}")+"return this.ret;} catch (e) { throw 'TemplateError: ' + e + ' (on "+e+"' + ' line ' + this.line + ')'; } //# sourceURL="+e+"\n").replace(/this\.ret \+= '';/g,""),a=new Function(o),r={"&":"&","<":"<",">":">",'"':""","'":"'"},l=function(t){return(""+t).replace(/[&<>\'\"]/g,function(t){return r[t]})};return function(t){return a.call(i.context={escapeHTML:l,line:1,ret:"",stash:t})}}()),e?i.cache[t](e):i.cache[t]},s.template.cache={},s.template.get=function(t){if(t){var e=document.getElementById(t);return e&&e.innerHTML||""}},s.DOMWatchers=[],s.DOMReady=!1,s.ready=function(t){s.DOMWatchers.push(t),s.DOMReady&&t(document)},s.DOMObserve=function(t,e,i){var o=s.support.mutationobserver;o&&(e=n.isPlainObject(e)?e:{childList:!0,subtree:!0},i="function"==typeof i&&i||function(){},n(t).each(function(){var t=this,a=n(t);if(!a.data("am.observer"))try{var r=new o(s.utils.debounce(function(e,n){i.call(t,e,n),a.trigger("changed.dom.amui")},50));r.observe(t,e),a.data("am.observer",r)}catch(l){}}))},n.fn.DOMObserve=function(t,e){return this.each(function(){s.DOMObserve(this,t,e)})},s.support.touch&&r.addClass("am-touch"),n(document).on("changed.dom.amui",function(t){var e=t.target;n.each(s.DOMWatchers,function(t,i){i(e)})}),n(function(){var t=n(document.body);s.DOMReady=!0,n.each(s.DOMWatchers,function(t,e){e(document)}),s.DOMObserve("[data-am-observe]"),r.removeClass("no-js").addClass("js"),s.support.animation&&r.addClass("cssanimations"),window.navigator.standalone&&r.addClass("am-standalone"),n(".am-topbar-fixed-top").length&&t.addClass("am-with-topbar-fixed-top"),n(".am-topbar-fixed-bottom").length&&t.addClass("am-with-topbar-fixed-bottom");var e=n(".am-layout");e.find('[class*="md-block-grid"]').alterClass("md-block-grid-*"),e.find('[class*="lg-block-grid"]').alterClass("lg-block-grid"),n("[data-am-widget]").each(function(){var t=n(this);0===t.parents(".am-layout").length&&t.addClass("am-no-layout")})}),t.exports=s},function(t,e,i){"use strict";function n(t,e,i){return setTimeout(l(t,i),e)}function s(t,e,i){return!!Array.isArray(t)&&(o(t,i[e],i),!0)}function o(t,e,i){var n;if(t)if(t.forEach)t.forEach(e,i);else if(void 0!==t.length)for(n=0;n\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",s=window.console&&(window.console.warn||window.console.log);return s&&s.call(window.console,n,i),t.apply(this,arguments)}}function r(t,e,i){var n,s=e.prototype;n=t.prototype=Object.create(s),n.constructor=t,n._super=s,i&&ht(n,i)}function l(t,e){return function(){return t.apply(e,arguments)}}function c(t,e){return typeof t==ft?t.apply(e?e[0]||void 0:void 0,e):t}function h(t,e){return void 0===t?e:t}function d(t,e,i){o(f(e),function(e){t.addEventListener(e,i,!1)})}function u(t,e,i){o(f(e),function(e){t.removeEventListener(e,i,!1)})}function p(t,e){for(;t;){if(t==e)return!0;t=t.parentNode}return!1}function m(t,e){return t.indexOf(e)>-1}function f(t){return t.trim().split(/\s+/g)}function v(t,e,i){if(t.indexOf&&!i)return t.indexOf(e);for(var n=0;ni[e]}):n.sort()),n}function w(t,e){for(var i,n,s=e[0].toUpperCase()+e.slice(1),o=0;o1&&!i.firstMultiple?i.firstMultiple=E(e):1===s&&(i.firstMultiple=!1);var o=i.firstInput,a=i.firstMultiple,r=a?a.center:o.center,l=e.center=S(n);e.timeStamp=yt(),e.deltaTime=e.timeStamp-o.timeStamp,e.angle=O(r,l),e.distance=I(r,l),T(i,e),e.offsetDirection=M(e.deltaX,e.deltaY);var c=A(e.deltaTime,e.deltaX,e.deltaY);e.overallVelocityX=c.x,e.overallVelocityY=c.y,e.overallVelocity=gt(c.x)>gt(c.y)?c.x:c.y,e.scale=a?N(a.pointers,n):1,e.rotation=a?z(a.pointers,n):0,e.maxPointers=i.prevInput?e.pointers.length>i.prevInput.maxPointers?e.pointers.length:i.prevInput.maxPointers:e.pointers.length,D(i,e);var h=t.element;p(e.srcEvent.target,h)&&(h=e.srcEvent.target),e.target=h}function T(t,e){var i=e.center,n=t.offsetDelta||{},s=t.prevDelta||{},o=t.prevInput||{};e.eventType!==Mt&&o.eventType!==Ot||(s=t.prevDelta={x:o.deltaX||0,y:o.deltaY||0},n=t.offsetDelta={x:i.x,y:i.y}),e.deltaX=s.x+(i.x-n.x),e.deltaY=s.y+(i.y-n.y)}function D(t,e){var i,n,s,o,a=t.lastInterval||e,r=e.timeStamp-a.timeStamp;if(e.eventType!=zt&&(r>At||void 0===a.velocity)){var l=e.deltaX-a.deltaX,c=e.deltaY-a.deltaY,h=A(r,l,c);n=h.x,s=h.y,i=gt(h.x)>gt(h.y)?h.x:h.y,o=M(l,c),t.lastInterval=e}else i=a.velocity,n=a.velocityX,s=a.velocityY,o=a.direction;e.velocity=i,e.velocityX=n,e.velocityY=s,e.direction=o}function E(t){for(var e=[],i=0;i=gt(e)?t<0?Lt:Pt:e<0?Ut:_t}function I(t,e,i){i||(i=qt);var n=e[i[0]]-t[i[0]],s=e[i[1]]-t[i[1]];return Math.sqrt(n*n+s*s)}function O(t,e,i){i||(i=qt);var n=e[i[0]]-t[i[0]],s=e[i[1]]-t[i[1]];return 180*Math.atan2(s,n)/Math.PI}function z(t,e){return O(e[1],e[0],jt)+O(t[1],t[0],jt)}function N(t,e){return I(e[0],e[1],jt)/I(t[0],t[1],jt)}function L(){this.evEl=Zt,this.evWin=Ht,this.pressed=!1,$.apply(this,arguments)}function P(){this.evEl=Gt,this.evWin=Jt,$.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}function U(){this.evTarget=Qt,this.evWin=te,this.started=!1,$.apply(this,arguments)}function _(t,e){var i=g(t.touches),n=g(t.changedTouches);return e&(Ot|zt)&&(i=y(i.concat(n),"identifier",!0)),[i,n]}function V(){this.evTarget=ie,this.targetIds={},$.apply(this,arguments)}function R(t,e){var i=g(t.touches),n=this.targetIds;if(e&(Mt|It)&&1===i.length)return n[i[0].identifier]=!0,[i,i];var s,o,a=g(t.changedTouches),r=[],l=this.target;if(o=i.filter(function(t){return p(t.target,l)}),e===Mt)for(s=0;s-1&&n.splice(t,1)};setTimeout(s,ne)}}function Y(t){for(var e=t.srcEvent.clientX,i=t.srcEvent.clientY,n=0;n-1&&this.requireFail.splice(e,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(t){return!!this.simultaneous[t.id]},emit:function(t){function e(e){i.manager.emit(e,t)}var i=this,n=this.state;n=ge&&e(i.options.event+G(n))},tryEmit:function(t){return this.canEmit()?this.emit(t):void(this.state=be)},canEmit:function(){for(var t=0;te.threshold&&s&e.direction},attrTest:function(t){return Q.prototype.attrTest.call(this,t)&&(this.state&fe||!(this.state&fe)&&this.directionTest(t))},emit:function(t){this.pX=t.deltaX,this.pY=t.deltaY;var e=J(t.direction);e&&(t.additionalEvent=this.options.event+e),this._super.emit.call(this,t)}}),r(et,Q,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[he]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.scale-1)>this.options.threshold||this.state&fe)},emit:function(t){if(1!==t.scale){var e=t.scale<1?"in":"out";t.additionalEvent=this.options.event+e}this._super.emit.call(this,t)}}),r(it,B,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[le]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,s=t.distancee.time;if(this._input=t,!s||!i||t.eventType&(Ot|zt)&&!o)this.reset();else if(t.eventType&Mt)this.reset(),this._timer=n(function(){this.state=ye,this.tryEmit()},e.time,this);else if(t.eventType&Ot)return ye;return be},reset:function(){clearTimeout(this._timer)},emit:function(t){this.state===ye&&(t&&t.eventType&Ot?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=yt(),this.manager.emit(this.options.event,this._input)))}}),r(nt,Q,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[he]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.rotation)>this.options.threshold||this.state&fe)}}),r(st,Q,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Vt|Rt,pointers:1},getTouchAction:function(){return tt.prototype.getTouchAction.call(this)},attrTest:function(t){var e,i=this.options.direction;return i&(Vt|Rt)?e=t.overallVelocity:i&Vt?e=t.overallVelocityX:i&Rt&&(e=t.overallVelocityY),this._super.attrTest.call(this,t)&&i&t.offsetDirection&&t.distance>this.options.threshold&&t.maxPointers==this.options.pointers&>(e)>this.options.velocity&&t.eventType&Ot},emit:function(t){var e=J(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)}}),r(ot,B,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[ce]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,s=t.distance'+r.loadingText,this.hasSpinner=!0),e=e||(void 0===a[t]?r[t]:a[t]),i[l](e),setTimeout(n.proxy(function(){"loadingText"===t?(i.addClass(c).attr(o,o),this.isLoading=!0):this.isLoading&&(i.removeClass(c).removeAttr(o),this.isLoading=!1)},this),0)},o.prototype.toggle=function(){var t=!0,e=this.$element,i=this.$element.parent('[class*="am-btn-group"]'),n=o.DEFAULTS.activeClassName;if(i.length){var s=this.$element.find("input");"radio"==s.prop("type")&&(s.prop("checked")&&e.hasClass(n)?t=!1:i.find("."+n).removeClass(n)),t&&s.prop("checked",!e.hasClass(n)).trigger("change")}t&&(e.toggleClass(n),e.hasClass(n)||e.blur())},s.plugin("button",o,{dataOptions:"data-am-loading",methodCall:function(t,e){"toggle"===t[0]?e.toggle():"string"==typeof t[0]&&e.setState.apply(e,t)}}),n(document).on("click.button.amui.data-api","[data-am-button]",function(t){t.preventDefault();var e=n(t.target);e.hasClass("am-btn")||(e=e.closest(".am-btn")),e.button("toggle")}),s.ready(function(t){n("[data-am-loading]",t).button(),n("[data-am-button]",t).find("input:checked").each(function(){n(this).parent("label").addClass(o.DEFAULTS.activeClassName)})}),t.exports=s.button=o},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){this.options=n.extend({},o.DEFAULTS,e),this.$element=n(t),n.fn.selected&&this.options.selectStyle&&(this.isSelected=!0),this.init()};o.DEFAULTS={data:null,defaultValue:null,selectStyle:!0,selectOption:null},o.prototype.init=function(){var t=this.options,e=(this.$element,this.options.defaultValue);if(this.selectListDOM=[],this.selectIndex=[],this.selectValue=[],e){var i=this.arrayTreeIndex(t.data,e[0]);this.create(t.data,i), this.createDefault()}else this.create(t.data);this.selectEvent()},o.prototype.create=function(t,e){var i=this.$element,s=this.generateSelect(t),o=e||0;i.append(s),n.fn.selected&&(this.options.selectOption?s.selected(this.options.selectOption):s.selected(),e&&(s.find("option").eq(o).attr("selected",!0),s.trigger("changed.selected.amui"))),this.selectListDOM.push(s),this.selectValue.push(t[o].value),this.selectIndex.push(o)},o.prototype.createSelect=function(t,e){var i=this.getData(t);return!i||(this.create(i,e),void(i[0].children&&1===i[0].children.length&&this.create(i[0].children)))},o.prototype.createDefault=function(){var t=this,e=this.options.data.slice(),i=this.options.defaultValue,n=0,s=[],o=[];i.forEach(function(i){n=t.arrayTreeIndex(e,i),s.push(n),o.push(s.slice()),e=e[n].children}),o.pop(),o.forEach(function(e,i){t.createSelect(e,s[i+1])})},o.prototype.arrayTreeIndex=function(t,e){var i=0;return t.forEach(function(t,n){if(t.value===e)return void(i=n)}),i},o.prototype.generateSelect=function(t){var e=s.utils.generateGUID("am-cascader"),i="";t.forEach(function(t){i+=""});var o=n("");return o.append(i),o},o.prototype.getData=function(t){var e=null,i=this.options.data;return t.forEach(function(t){return(e||i)[t].children?void(e=(e||i)[t].children):void(e=!1)}),e},o.prototype.selectEvent=function(){var t=this;this.$element.on("change","select",function(){var e=this.selectedIndex,i=t.$element.find("select").index(this),s=t.selectListDOM.splice(i+1);t.selectIndex[i]=e,t.selectIndex.splice(i+1),t.selectValue[i]=n(this).val(),t.selectValue.splice(i+1),s.forEach(function(t){t.selected("destroy"),t.remove()}),t.createSelect(t.selectIndex),t.$element.trigger("change.cascader.amui")})},o.prototype.get=function(){return this.selectValue},s.plugin("cascader",o),s.ready(function(t){n("[data-am-cascader]",t).cascader()}),t.exports=o},function(t,e,i){"use strict";function n(t){return this.each(function(){var e=s(this),i=e.data("amui.collapse"),n=s.extend({},a.DEFAULTS,o.utils.options(e.attr("data-am-collapse")),"object"==typeof t&&t);!i&&n.toggle&&"open"===t&&(t=!t),i||e.data("amui.collapse",i=new a(this,n)),"string"==typeof t&&i[t]()})}var s=i(1),o=i(2),a=function(t,e){this.$element=s(t),this.$arrow=this.$element.prev().find('[class*="am-icon-"]'),this.options=s.extend({},a.DEFAULTS,e),this.transitioning=null,this.options.parent&&(this.$parent=s(this.options.parent)),this.options.toggle&&this.toggle()};a.DEFAULTS={toggle:!0},a.prototype.open=function(){if(!this.transitioning&&!this.$element.hasClass("am-in")){this.$arrow&&this.$arrow.addClass("am-panel-hd-arrow");var t=s.Event("open.collapse.amui");if(this.$element.trigger(t),!t.isDefaultPrevented()){var e=this.$parent&&this.$parent.find("> .am-panel > .am-in");if(e&&e.length){var i=e.data("amui.collapse");if(i&&i.transitioning)return;n.call(e,"close"),i||e.data("amui.collapse",null)}this.$element.removeClass("am-collapse").addClass("am-collapsing").height(0),this.transitioning=1;var a=function(){this.$element.removeClass("am-collapsing").addClass("am-collapse am-in").height("").trigger("opened.collapse.amui"),this.transitioning=0};if(!o.support.transition)return a.call(this);var r=this.$element[0].scrollHeight;this.$element.one(o.support.transition.end,s.proxy(a,this)).emulateTransitionEnd(300).css({height:r})}}},a.prototype.close=function(){if(!this.transitioning&&this.$element.hasClass("am-in")){this.$arrow&&this.$arrow.removeClass("am-panel-hd-arrow");var t=s.Event("close.collapse.amui");if(this.$element.trigger(t),!t.isDefaultPrevented()){this.$element.height(this.$element.height()).redraw(),this.$element.addClass("am-collapsing").removeClass("am-collapse am-in"),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.trigger("closed.collapse.amui").removeClass("am-collapsing").addClass("am-collapse")};return o.support.transition?void this.$element.height(0).one(o.support.transition.end,s.proxy(e,this)).emulateTransitionEnd(300):e.call(this)}}},a.prototype.toggle=function(){this[this.$element.hasClass("am-in")?"close":"open"]()},s.fn.collapse=n,s(document).on("click.collapse.amui.data-api","[data-am-collapse]",function(t){var e,i=s(this),a=o.utils.options(i.attr("data-am-collapse")),r=a.target||t.preventDefault()||(e=i.attr("href"))&&e.replace(/.*(?=#[^\s]+$)/,""),l=s(r),c=l.data("amui.collapse"),h=c?"toggle":a,d=a.parent,u=d&&s(d);c&&c.transitioning||(u&&u.find("[data-am-collapse]").not(i).addClass("am-collapsed"),i[l.hasClass("am-in")?"addClass":"removeClass"]("am-collapsed")),n.call(l,h)}),t.exports=o.collapse=a},function(t,e,i){"use strict";var n=i(1),s=i(2),o=n(document),a=function(t,e){if(this.$element=n(t),this.options=n.extend({},a.DEFAULTS,e),this.format=r.parseFormat(this.options.format),this.$element.data("date",this.options.date),this.language=this.getLocale(this.options.locale),this.theme=this.options.theme,this.$picker=n(r.template).appendTo("body").on({click:n.proxy(this.click,this)}),this.isInput=this.$element.is("input"),this.component=!!this.$element.is(".am-datepicker-date")&&this.$element.find(".am-datepicker-add-on"),this.isInput?this.$element.on({"click.datepicker.amui":n.proxy(this.open,this),"keyup.datepicker.amui":n.proxy(this.update,this)}):this.component?this.component.on("click.datepicker.amui",n.proxy(this.open,this)):this.$element.on("click.datepicker.amui",n.proxy(this.open,this)),this.minViewMode=this.options.minViewMode,"string"==typeof this.minViewMode)switch(this.minViewMode){case"months":this.minViewMode=1;break;case"years":this.minViewMode=2;break;default:this.minViewMode=0}if(this.viewMode=this.options.viewMode,"string"==typeof this.viewMode)switch(this.viewMode){case"months":this.viewMode=1;break;case"years":this.viewMode=2;break;default:this.viewMode=0}this.startViewMode=this.viewMode,this.weekStart=(this.options.weekStart||a.locales[this.language].weekStart||0)%7,this.weekEnd=(this.weekStart+6)%7,this.onRender=this.options.onRender,this.setTheme(),this.fillDow(),this.fillMonths(),this.update(),this.showMode()};a.DEFAULTS={locale:"zh_CN",format:"yyyy-mm-dd",weekStart:void 0,viewMode:0,minViewMode:0,date:"",theme:"",autoClose:1,onRender:function(t){return""}},a.prototype.open=function(t){this.$picker.show(),this.height=this.component?this.component.outerHeight():this.$element.outerHeight(),this.place(),n(window).on("resize.datepicker.amui",n.proxy(this.place,this)),t&&(t.stopPropagation(),t.preventDefault());var e=this;o.on("mousedown.datapicker.amui touchstart.datepicker.amui",function(t){0===n(t.target).closest(".am-datepicker").length&&e.close()}),this.$element.trigger({type:"open.datepicker.amui",date:this.date})},a.prototype.close=function(){this.$picker.hide(),n(window).off("resize.datepicker.amui",this.place),this.viewMode=this.startViewMode,this.showMode(),this.isInput||n(document).off("mousedown.datapicker.amui touchstart.datepicker.amui",this.close),this.$element.trigger({type:"close.datepicker.amui",date:this.date})},a.prototype.set=function(){var t,e=r.formatDate(this.date,this.format);this.isInput?t=this.$element.attr("value",e):(this.component&&(t=this.$element.find("input").attr("value",e)),this.$element.data("date",e)),t&&t.trigger("change")},a.prototype.setValue=function(t){"string"==typeof t?this.date=r.parseDate(t,this.format):this.date=new Date(t),this.set(),this.viewDate=new Date(this.date.getFullYear(),this.date.getMonth(),1,0,0,0,0),this.fill()},a.prototype.place=function(){var t=this.component?this.component.offset():this.$element.offset(),e=this.component?this.component.width():this.$element.width(),i=t.top+this.height,n=t.left,s=o.width()-t.left-e,a=this.isOutView();if(this.$picker.removeClass("am-datepicker-right"),this.$picker.removeClass("am-datepicker-up"),o.width()>640){if(a.outRight)return this.$picker.addClass("am-datepicker-right"),void this.$picker.css({top:i,left:"auto",right:s});a.outBottom&&(this.$picker.addClass("am-datepicker-up"),i=t.top-this.$picker.outerHeight(!0))}else n=0;this.$picker.css({top:i,left:n})},a.prototype.update=function(t){this.date=r.parseDate("string"==typeof t?t:this.isInput?this.$element.prop("value"):this.$element.data("date"),this.format),this.viewDate=new Date(this.date.getFullYear(),this.date.getMonth(),1,0,0,0,0),this.fill()},a.prototype.fillDow=function(){for(var t=this.weekStart,e="";t'+a.locales[this.language].daysMin[t++%7]+"";e+="",this.$picker.find(".am-datepicker-days thead").append(e)},a.prototype.fillMonths=function(){for(var t="",e=0;e<12;)t+=''+a.locales[this.language].monthsShort[e++]+"";this.$picker.find(".am-datepicker-months td").append(t)},a.prototype.fill=function(){var t=new Date(this.viewDate),e=t.getFullYear(),i=t.getMonth(),n=this.date.valueOf(),s=new Date(e,i-1,28,0,0,0,0),o=r.getDaysInMonth(s.getFullYear(),s.getMonth()),l=this.$picker.find(".am-datepicker-days .am-datepicker-select");"zh_CN"===this.language?l.text(e+a.locales[this.language].year[0]+" "+a.locales[this.language].months[i]):l.text(a.locales[this.language].months[i]+" "+e),s.setDate(o),s.setDate(o-(s.getDay()-this.weekStart+7)%7);var c=new Date(s);c.setDate(c.getDate()+42),c=c.valueOf();for(var h,d,u,p=[];s.valueOf()"),h=this.onRender(s,0),d=s.getFullYear(),u=s.getMonth(),ui&&d===e||d>e)&&(h+=" am-datepicker-new"),s.valueOf()===n&&(h+=" am-active"),p.push(''+s.getDate()+""),s.getDay()===this.weekEnd&&p.push(""),s.setDate(s.getDate()+1);this.$picker.find(".am-datepicker-days tbody").empty().append(p.join(""));var m=this.date.getFullYear(),f=this.$picker.find(".am-datepicker-months").find(".am-datepicker-select").text(e);f=f.end().find("span").removeClass("am-active").removeClass("am-disabled");for(var v=0;v<12;)this.onRender(t.setFullYear(e,v),1)&&f.eq(v).addClass("am-disabled"),v++;m===e&&f.eq(this.date.getMonth()).removeClass("am-disabled").addClass("am-active"),p="",e=10*parseInt(e/10,10);var g,y=this.$picker.find(".am-datepicker-years").find(".am-datepicker-select").text(e+"-"+(e+9)).end().find("td"),w=new Date(this.viewDate);e-=1;for(var b=-1;b<11;b++)g=this.onRender(w.setFullYear(e),2),p+=''+e+"",e+=1;y.html(p)},a.prototype.click=function(t){t.stopPropagation(),t.preventDefault();var e,i,s=this.$picker.find(".am-datepicker-days").find(".am-active"),o=this.$picker.find(".am-datepicker-months"),a=o.find(".am-active").index(),l=n(t.target).closest("span, td, th");if(1===l.length)switch(l[0].nodeName.toLowerCase()){case"th":switch(l[0].className){case"am-datepicker-switch":this.showMode(1);break;case"am-datepicker-prev":case"am-datepicker-next":this.viewDate["set"+r.modes[this.viewMode].navFnc].call(this.viewDate,this.viewDate["get"+r.modes[this.viewMode].navFnc].call(this.viewDate)+r.modes[this.viewMode].navStep*("am-datepicker-prev"===l[0].className?-1:1)),this.fill(),this.set()}break;case"span":if(l.is(".am-disabled"))return;l.is(".am-datepicker-month")?(e=l.parent().find("span").index(l),l.is(".am-active")?this.viewDate.setMonth(e,s.text()):this.viewDate.setMonth(e),this.chooseMonth=!0):(i=parseInt(l.text(),10)||0,l.is(".am-active")?this.viewDate.setFullYear(i,a,s.text()):this.viewDate.setFullYear(i),this.chooseYear=!0),0!==this.viewMode&&(this.date=new Date(this.viewDate),this.$element.trigger({type:"changeDate.datepicker.amui",date:this.date,viewMode:r.modes[this.viewMode].clsName})),this.showMode(-1),this.fill(),this.set();var c=this.format.parts;(2===c.length&&this.chooseMonth||""===c[1]&&this.chooseYear)&&this.options.autoClose&&(this.close(),this.chooseMonth=!1,this.chooseYear=!1);break;case"td":if(l.is(".am-datepicker-day")&&!l.is(".am-disabled")){var h=parseInt(l.text(),10)||1;e=this.viewDate.getMonth(),l.is(".am-datepicker-old")?e-=1:l.is(".am-datepicker-new")&&(e+=1),i=this.viewDate.getFullYear(),this.date=new Date(i,e,h,0,0,0,0),this.viewDate=new Date(i,e,Math.min(28,h),0,0,0,0),this.fill(),this.set(),this.$element.trigger({type:"changeDate.datepicker.amui",date:this.date,viewMode:r.modes[this.viewMode].clsName}),this.options.autoClose&&this.close()}}},a.prototype.mousedown=function(t){t.stopPropagation(),t.preventDefault()},a.prototype.showMode=function(t){t&&(this.viewMode=Math.max(this.minViewMode,Math.min(2,this.viewMode+t))),this.$picker.find(">div").hide().filter(".am-datepicker-"+r.modes[this.viewMode].clsName).show()},a.prototype.isOutView=function(){var t=this.component?this.component.offset():this.$element.offset(),e={outRight:!1,outBottom:!1},i=this.$picker,n=t.left+i.outerWidth(!0),s=t.top+i.outerHeight(!0)+this.$element.innerHeight();return n>o.width()&&(e.outRight=!0),s>o.height()&&(e.outBottom=!0),e},a.prototype.getLocale=function(t){return t||(t=navigator.language&&navigator.language.split("-"),t[1]=t[1].toUpperCase(),t=t.join("_")),a.locales[t]||(t="en_US"),t},a.prototype.setTheme=function(){this.theme&&this.$picker.addClass("am-datepicker-"+this.theme)},a.locales={en_US:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],weekStart:0},zh_CN:{days:["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"],daysShort:["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"],daysMin:["\u65e5","\u4e00","\u4e8c","\u4e09","\u56db","\u4e94","\u516d"],months:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],monthsShort:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],weekStart:1,year:["\u5e74"]}};var r={modes:[{clsName:"days",navFnc:"Month",navStep:1},{clsName:"months",navFnc:"FullYear",navStep:1},{clsName:"years",navFnc:"FullYear",navStep:10}],isLeapYear:function(t){return t%4===0&&t%100!==0||t%400===0},getDaysInMonth:function(t,e){return[31,r.isLeapYear(t)?29:28,31,30,31,30,31,31,30,31,30,31][e]},parseFormat:function(t){var e=t.match(/[.\/\-\s].*?/),i=t.split(/\W+/);if(!e||!i||0===i.length)throw new Error("Invalid date format.");return{separator:e,parts:i}},parseDate:function(t,e){var i,n=t.split(e.separator);if(t=new Date,t.setHours(0),t.setMinutes(0),t.setSeconds(0),t.setMilliseconds(0),n.length===e.parts.length){for(var s=t.getFullYear(),o=t.getDate(),a=t.getMonth(),r=0,l=e.parts.length;r
',contTemplate:''};r.template='
'+r.headTemplate+'
'+r.headTemplate+r.contTemplate+'
'+r.headTemplate+r.contTemplate+"
",s.plugin("datepicker",a),s.ready(function(t){n("[data-am-datepicker]").datepicker()}),t.exports=s.datepicker=a},function(t,e,i){"use strict";var n=i(1),s=i(2),o=n(document),a=s.support.transition,r=function(){this.id=s.utils.generateGUID("am-dimmer"),this.$element=n(r.DEFAULTS.tpl,{id:this.id}),this.inited=!1,this.scrollbarWidth=0,this.$used=n([])};r.DEFAULTS={tpl:'
'},r.prototype.init=function(){return this.inited||(n(document.body).append(this.$element),this.inited=!0,o.trigger("init.dimmer.amui"),this.$element.on("touchmove.dimmer.amui",function(t){t.preventDefault()})),this},r.prototype.open=function(t){this.inited||this.init();var e=this.$element;return t&&(this.$used=this.$used.add(n(t))),this.checkScrollbar().setScrollbar(),e.show().trigger("open.dimmer.amui"),a&&e.off(a.end),setTimeout(function(){e.addClass("am-active")},0),this},r.prototype.close=function(t,e){function i(){s.hide(),this.resetScrollbar()}if(this.$used=this.$used.not(n(t)),!e&&this.$used.length)return this;var s=this.$element;return s.removeClass("am-active").trigger("close.dimmer.amui"),a?s.one(a.end,n.proxy(i,this)).emulateTransitionEnd(1e3):i.call(this),this},r.prototype.checkScrollbar=function(){return this.scrollbarWidth=s.utils.measureScrollbar(),this},r.prototype.setScrollbar=function(){var t=n(document.body),e=parseInt(t.css("padding-right")||0,10);return this.scrollbarWidth&&t.css("padding-right",e+this.scrollbarWidth),t.addClass("am-dimmer-active"),this},r.prototype.resetScrollbar=function(){return n(document.body).css("padding-right","").removeClass("am-dimmer-active"),this},t.exports=s.dimmer=new r},function(t,e,i){"use strict";var n=i(1),s=i(2),o=s.support.animation,a=function(t,e){this.options=n.extend({},a.DEFAULTS,e),e=this.options,this.$element=n(t),this.$toggle=this.$element.find(e.selector.toggle),this.$dropdown=this.$element.find(e.selector.dropdown),this.$boundary=e.boundary===window?n(window):this.$element.closest(e.boundary),this.$justify=e.justify&&n(e.justify).length&&n(e.justify)||void 0,!this.$boundary.length&&(this.$boundary=n(window)),this.active=!!this.$element.hasClass("am-active"),this.animating=null,this.events()};a.DEFAULTS={animation:"am-animation-slide-top-fixed",boundary:window,justify:void 0,selector:{dropdown:".am-dropdown-content",toggle:".am-dropdown-toggle"},trigger:"click"},a.prototype.toggle=function(){this.clear(),this.animating||this[this.active?"close":"open"]()},a.prototype.open=function(t){var e=this.$toggle,i=this.$element,s=this.$dropdown;if(!e.is(".am-disabled, :disabled")&&!this.active){i.trigger("open.dropdown.amui").addClass("am-active"),e.trigger("focus"),this.checkDimensions(t);var a=n.proxy(function(){i.trigger("opened.dropdown.amui"),this.active=!0,this.animating=0},this);o?(this.animating=1,s.addClass(this.options.animation).on(o.end+".open.dropdown.amui",n.proxy(function(){a(),s.removeClass(this.options.animation)},this))):a()}},a.prototype.close=function(){if(this.active){var t="am-dropdown-animation",e=this.$element,i=this.$dropdown;e.trigger("close.dropdown.amui");var s=n.proxy(function(){e.removeClass("am-active").trigger("closed.dropdown.amui"),this.active=!1,this.animating=0,this.$toggle.blur()},this);o?(i.removeClass(this.options.animation),i.addClass(t),this.animating=1,i.one(o.end+".close.dropdown.amui",function(){i.removeClass(t),s()})):s()}},a.prototype.enable=function(){this.$toggle.prop("disabled",!1)},a.prototype.disable=function(){this.$toggle.prop("disabled",!0)},a.prototype.checkDimensions=function(t){if(this.$dropdown.length){var e=this.$dropdown;t&&t.offset&&e.offset(t.offset);var i=e.offset(),s=e.outerWidth(),o=this.$boundary.width(),a=n.isWindow(this.boundary)&&this.$boundary.offset()?this.$boundary.offset().left:0;this.$justify&&e.css({"min-width":this.$justify.css("width")}),s+(i.left-a)>o&&this.$element.addClass("am-dropdown-flip")}},a.prototype.clear=function(){n("[data-am-dropdown]").not(this.$element).each(function(){var t=n(this).data("amui.dropdown");t&&t.close()})},a.prototype.events=function(){var t="dropdown.amui",e=this.options.trigger.split(" "),i=this.$toggle;i.on("click."+t,n.proxy(function(t){t.preventDefault(),this.toggle()},this));for(var s=e.length;s--;){var o=e[s];if("click"===o&&i.on("click."+t,n.proxy(this.toggle,this)),"focus"===o||"hover"===o){var a="hover"==o?"mouseenter":"focusin",r="hover"==o?"mouseleave":"focusout";this.$element.on(a+"."+t,n.proxy(this.open,this)).on(r+"."+t,n.proxy(this.close,this))}}n(document).on("keydown.dropdown.amui",n.proxy(function(t){27===t.keyCode&&this.active&&this.close()},this)).on("click.outer.dropdown.amui",n.proxy(function(t){!this.active||this.$element[0]!==t.target&&this.$element.find(t.target).length||this.close()},this))},s.plugin("dropdown",a),s.ready(function(t){n("[data-am-dropdown]",t).dropdown()}),n(document).on("click.dropdown.amui.data-api",".am-dropdown form",function(t){t.stopPropagation()}),t.exports=s.dropdown=a},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){this.options=n.extend({},o.DEFAULTS,e),e=this.options,this.$element=n(t),this.init()};o.DEFAULTS={set:1,min:0,max:1/0,step:1,size:148,disabled:!1,controls:!0},o.prototype.init=function(){this.set(),this.$element.wrap('
'),this.$elementWrap=this.$element.parent(".am-inputnumber-wrap"),this.size(),this.increase(),this.decrease(),this.checkValue(),(this.options.disabled||this.$element.attr("disabled"))&&(this.$elementWrap.addClass("am-disabled"),this.$elementWrap.children().off(),this.$element.attr("disabled","disabled"))},o.prototype.get=function(){return this.$element.val()},o.prototype.set=function(t){var e=t||this.options.set;this.$element.val(e)},o.prototype.size=function(){var t=this;return!(t.options.size<0)&&void(148!=t.options.size&&this.$elementWrap.css("width",t.options.size))},o.prototype.increase=function(){var t=this;t.controls(),t.$elementWrap.prepend('').find(".am-inputnumber-increase").on("click",function(){var e=t.count("+");e<=t.options.max&&(t.$element.val(e),n(this).siblings().removeClass("am-disabled"),e+t.options.step>t.options.max&&n(this).addClass("am-disabled"))})},o.prototype.decrease=function(){var t=this;t.controls(),t.$elementWrap.prepend('').find(".am-inputnumber-decrease").on("click",function(){var e=t.count("-");e>=t.options.min&&(t.$element.val(e),n(this).siblings().removeClass("am-disabled"),e-t.options.stept.options.max&&t.set(t.options.max)})},o.prototype.count=function(t){var e=10*Number(this.$element.val()),i=10*this.options.step;return"+"==t?(e+i)/10:"-"==t?(e-i)/10:void 0},s.plugin("inputnumber",o),s.ready(function(t){n("[data-am-inputnumber]",t).inputnumber()})},function(t,e,i){"use strict";function n(t,e){return this.each(function(){var i=s(this),n=i.data("amui.modal"),o="object"==typeof t&&t;n||i.data("amui.modal",n=new c(this,o)),"string"==typeof t?n[t]&&n[t](e):n.toggle(t&&t.relatedTarget||void 0)})}var s=i(1),o=i(2),a=i(9),r=s(document),l=o.support.transition,c=function(t,e){this.options=s.extend({},c.DEFAULTS,e||{}),this.$element=s(t),this.$dialog=this.$element.find(".am-modal-dialog"),this.$element.attr("id")||this.$element.attr("id",o.utils.generateGUID("am-modal")),this.isPopup=this.$element.hasClass("am-popup"),this.isActions=this.$element.hasClass("am-modal-actions"),this.isPrompt=this.$element.hasClass("am-modal-prompt"),this.isLoading=this.$element.hasClass("am-modal-loading"),this.active=this.transitioning=this.relatedTarget=null,this.dimmer=this.options.dimmer?a:{open:function(){},close:function(){}},this.events()};c.DEFAULTS={className:{active:"am-modal-active",out:"am-modal-out"},selector:{modal:".am-modal",active:".am-modal-active"},closeViaDimmer:!0,cancelable:!0,onConfirm:function(){},onCancel:function(){},closeOnCancel:!0,closeOnConfirm:!0,dimmer:!0,height:void 0,width:void 0,duration:200,transitionEnd:l&&l.end+".modal.amui"},c.prototype.toggle=function(t){return this.active?this.close():this.open(t)},c.prototype.open=function(t){var e=this.$element,i=this.options,n=this.isPopup,o=i.width,a=i.height,r={};if(!this.active&&this.$element.length){t&&(this.relatedTarget=t),this.transitioning&&(clearTimeout(e.transitionEndTimmer),e.transitionEndTimmer=null,e.trigger(i.transitionEnd).off(i.transitionEnd)),n&&this.$element.show(),this.active=!0,e.trigger(s.Event("open.modal.amui",{relatedTarget:t})),this.dimmer.open(e),e.show().redraw(),n||this.isActions||(o&&(r.width=parseInt(o,10)+"px"),a&&(r.height=parseInt(a,10)+"px"),this.$dialog.css(r)),e.removeClass(i.className.out).addClass(i.className.active),this.transitioning=1;var c=function(){e.trigger(s.Event("opened.modal.amui",{relatedTarget:t})),this.transitioning=0,this.isPrompt&&this.$dialog.find("input").eq(0).focus()};return l?void e.one(i.transitionEnd,s.proxy(c,this)).emulateTransitionEnd(i.duration):c.call(this)}},c.prototype.close=function(t){if(this.active){var e=this.$element,i=this.options,n=this.isPopup;this.transitioning&&(clearTimeout(e.transitionEndTimmer),e.transitionEndTimmer=null,e.trigger(i.transitionEnd).off(i.transitionEnd),this.dimmer.close(e,!0)),this.$element.trigger(s.Event("close.modal.amui",{relatedTarget:t})),this.transitioning=1;var o=function(){e.trigger("closed.modal.amui"),n&&e.removeClass(i.className.out),e.hide(),this.transitioning=0,this.active=!1};return e.removeClass(i.className.active).addClass(i.className.out),this.dimmer.close(e,!1),l?void e.one(i.transitionEnd,s.proxy(o,this)).emulateTransitionEnd(i.duration):o.call(this)}},c.prototype.events=function(){var t=this,e=this.options,i=this.$element,n=this.dimmer.$element,o=i.find(".am-modal-prompt-input"),a=i.find("[data-am-modal-confirm]"),r=i.find("[data-am-modal-cancel]"),l=function(){var t=[];return o.each(function(){t.push(s(this).val())}),0===t.length?void 0:1===t.length?t[0]:t};this.options.cancelable&&i.on("keyup.modal.amui",function(e){t.active&&27===e.which&&(i.trigger("cancel.modal.amui"),t.close())}),this.options.dimmer&&this.options.closeViaDimmer&&!this.isLoading&&n.on("click.dimmer.modal.amui",function(){t.close()}),i.on("click.close.modal.amui","[data-am-modal-close], .am-modal-btn",function(i){i.preventDefault();var n=s(this);n.is(a)?e.closeOnConfirm&&t.close():n.is(r)?e.closeOnCancel&&t.close():t.close()}).on("click",function(t){s(t.target).is(i)&&n.trigger("click.dimmer.modal.amui")}),a.on("click.confirm.modal.amui",function(){i.trigger(s.Event("confirm.modal.amui",{trigger:this}))}),r.on("click.cancel.modal.amui",function(){i.trigger(s.Event("cancel.modal.amui",{trigger:this}))}),i.on("confirm.modal.amui",function(e){e.data=l(),t.options.onConfirm.call(t,e)}).on("cancel.modal.amui",function(e){e.data=l(),t.options.onCancel.call(t,e)})},s.fn.modal=n,r.on("click.modal.amui.data-api","[data-am-modal]",function(){var t=s(this),e=o.utils.parseOptions(t.attr("data-am-modal")),i=s(e.target||this.href&&this.href.replace(/.*(?=#[^\s]+$)/,"")),a=i.data("amui.modal")?"toggle":e;n.call(i,a,this)}),t.exports=o.modal=c},function(t,e,i){"use strict";function n(t,e){var i=Array.prototype.slice.call(arguments,1);return this.each(function(){var n=s(this),o=n.data("amui.offcanvas"),a=s.extend({},"object"==typeof t&&t);o||(n.data("amui.offcanvas",o=new c(this,a)),(!t||"object"==typeof t)&&o.open(e)),"string"==typeof t&&o[t]&&o[t].apply(o,i)})}var s=i(1),o=i(2);i(3);var a,r=s(window),l=s(document),c=function(t,e){this.$element=s(t),this.options=s.extend({},c.DEFAULTS,e),this.active=null,this.bindEvents()};c.DEFAULTS={duration:300,effect:"overlay"},c.prototype.open=function(t){var e=this,i=this.$element;if(i.length&&!i.hasClass("am-active")){var n=this.options.effect,o=s("html"),l=s("body"),c=i.find(".am-offcanvas-bar").first(),h=c.hasClass("am-offcanvas-bar-flip")?-1:1;c.addClass("am-offcanvas-bar-"+n),a={x:window.scrollX,y:window.scrollY},i.addClass("am-active"),l.css({width:window.innerWidth,height:r.height()}).addClass("am-offcanvas-page"),"overlay"!==n&&l.css({"margin-left":c.outerWidth()*h}).width(),o.css("margin-top",a.y*-1),setTimeout(function(){c.addClass("am-offcanvas-bar-active").width()},0),i.trigger("open.offcanvas.amui"),this.active=1,i.on("click.offcanvas.amui",function(t){var i=s(t.target);i.hasClass("am-offcanvas-bar")||i.parents(".am-offcanvas-bar").first().length||(t.stopImmediatePropagation(),e.close())}),o.on("keydown.offcanvas.amui",function(t){27===t.keyCode&&e.close()})}},c.prototype.close=function(t){function e(){r.removeClass("am-offcanvas-page").css({width:"",height:"","margin-left":"","margin-right":""}),l.removeClass("am-active"),c.removeClass("am-offcanvas-bar-active"),n.css("margin-top",""),window.scrollTo(a.x,a.y),l.trigger("closed.offcanvas.amui"),i.active=0}var i=this,n=s("html"),r=s("body"),l=this.$element,c=l.find(".am-offcanvas-bar").first();l.length&&this.active&&l.hasClass("am-active")&&(l.trigger("close.offcanvas.amui"),o.support.transition?(setTimeout(function(){c.removeClass("am-offcanvas-bar-active")},0),r.css("margin-left","").one(o.support.transition.end,function(){e()}).emulateTransitionEnd(this.options.duration)):e(),l.off("click.offcanvas.amui"),n.off(".offcanvas.amui"))},c.prototype.bindEvents=function(){var t=this;return l.on("click.offcanvas.amui",'[data-am-dismiss="offcanvas"]',function(e){e.preventDefault(),t.close()}),r.on("resize.offcanvas.amui orientationchange.offcanvas.amui",function(){t.active&&t.close()}),this.$element.hammer().on("swipeleft swipeleft",function(e){e.preventDefault(),t.close()}),this},s.fn.offCanvas=n,l.on("click.offcanvas.amui","[data-am-offcanvas]",function(t){t.preventDefault();var e=s(this),i=o.utils.parseOptions(e.data("amOffcanvas")),a=s(i.target||this.href&&this.href.replace(/.*(?=#[^\s]+$)/,"")),r=a.data("amui.offcanvas")?"open":i;n.call(a,r,this)}),t.exports=o.offcanvas=c},function(t,e,i){"use strict";var n=i(1),s=i(2),o=s.utils.rAF,a=function(t){var e=function(e,i){this.el=t(e),this.zoomFactor=1,this.lastScale=1,this.offset={x:0,y:0},this.options=t.extend({},this.defaults,i),this.setupMarkup(),this.bindEvents(),this.update(),this.enable()},i=function(t,e){return t+e},n=function(t,e){return t>e-.01&&t1){var e=this.getTouches(t)[0];this.drag(e,this.lastDragPosition),this.offset=this.sanitizeOffset(this.offset),this.lastDragPosition=e}},handleDragEnd:function(){this.el.trigger(this.options.dragEndEventName),this.end()},handleZoomStart:function(t){this.el.trigger(this.options.zoomStartEventName),this.stopAnimation(),this.lastScale=1,this.nthZoom=0,this.lastZoomCenter=!1,this.hasInteraction=!0},handleZoom:function(t,e){var i=this.getTouchCenter(this.getTouches(t)),n=e/this.lastScale;this.lastScale=e,this.nthZoom+=1,this.nthZoom>3&&(this.scale(n,i),this.drag(i,this.lastZoomCenter)),this.lastZoomCenter=i; },handleZoomEnd:function(){this.el.trigger(this.options.zoomEndEventName),this.end()},handleDoubleTap:function(t){var e=this.getTouches(t)[0],i=this.zoomFactor>1?1:this.options.tapZoomFactor,n=this.zoomFactor,s=function(t){this.scaleTo(n+t*(i-n),e)}.bind(this);this.hasInteraction||(n>i&&(e=this.getCurrentZoomCenter()),this.animate(this.options.animationDuration,s,this.swing),this.el.trigger(this.options.doubleTapEventName))},sanitizeOffset:function(t){var e=(this.zoomFactor-1)*this.getContainerX(),i=(this.zoomFactor-1)*this.getContainerY(),n=Math.max(e,0),s=Math.max(i,0),o=Math.min(e,0),a=Math.min(i,0);return{x:Math.min(Math.max(t.x,o),n),y:Math.min(Math.max(t.y,a),s)}},scaleTo:function(t,e){this.scale(t/this.zoomFactor,e)},scale:function(t,e){t=this.scaleZoomFactor(t),this.addOffset({x:(t-1)*(e.x+this.offset.x),y:(t-1)*(e.y+this.offset.y)})},scaleZoomFactor:function(t){var e=this.zoomFactor;return this.zoomFactor*=t,this.zoomFactor=Math.min(this.options.maxZoom,Math.max(this.zoomFactor,this.options.minZoom)),this.zoomFactor/e},drag:function(t,e){e&&(this.options.lockDragAxis?Math.abs(t.x-e.x)>Math.abs(t.y-e.y)?this.addOffset({x:-(t.x-e.x),y:0}):this.addOffset({y:-(t.y-e.y),x:0}):this.addOffset({y:-(t.y-e.y),x:-(t.x-e.x)}))},getTouchCenter:function(t){return this.getVectorAvg(t)},getVectorAvg:function(t){return{x:t.map(function(t){return t.x}).reduce(i)/t.length,y:t.map(function(t){return t.y}).reduce(i)/t.length}},addOffset:function(t){this.offset={x:this.offset.x+t.x,y:this.offset.y+t.y}},sanitize:function(){this.zoomFactor=t?(e(1),n&&n(),this.update(),this.stopAnimation(),this.update()):(i&&(l=i(l)),e(l),this.update(),o(a))}}.bind(this);this.inAnimation=!0,o(a)},stopAnimation:function(){this.inAnimation=!1},swing:function(t){return-Math.cos(t*Math.PI)/2+.5},getContainerX:function(){return this.container[0].offsetWidth},getContainerY:function(){return this.container[0].offsetHeight},setContainerY:function(t){return this.container.height(t)},setupMarkup:function(){this.container=t('
'),this.el.before(this.container),this.container.append(this.el),this.container.css({overflow:"hidden",position:"relative"}),this.el.css({"-webkit-transform-origin":"0% 0%","-moz-transform-origin":"0% 0%","-ms-transform-origin":"0% 0%","-o-transform-origin":"0% 0%","transform-origin":"0% 0%",position:"absolute"})},end:function(){this.hasInteraction=!1,this.sanitize(),this.update()},bindEvents:function(){s(this.container.get(0),this),t(window).on("resize",this.update.bind(this)),t(this.el).find("img").on("load",this.update.bind(this))},update:function(){this.updatePlaned||(this.updatePlaned=!0,setTimeout(function(){this.updatePlaned=!1,this.updateAspectRatio();var t=this.getInitialZoomFactor()*this.zoomFactor,e=-this.offset.x/t,i=-this.offset.y/t,n="scale3d("+t+", "+t+",1) translate3d("+e+"px,"+i+"px,0px)",s="scale("+t+", "+t+") translate("+e+"px,"+i+"px)",o=function(){this.clone&&(this.clone.remove(),delete this.clone)}.bind(this);!this.options.use2d||this.hasInteraction||this.inAnimation?(this.is3d=!0,o(),this.el.css({"-webkit-transform":n,"-o-transform":s,"-ms-transform":s,"-moz-transform":s,transform:n})):(this.is3d&&(this.clone=this.el.clone(),this.clone.css("pointer-events","none"),this.clone.appendTo(this.container),setTimeout(o,200)),this.el.css({"-webkit-transform":s,"-o-transform":s,"-ms-transform":s,"-moz-transform":s,transform:s}),this.is3d=!1)}.bind(this),0))},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1}};var s=function(t,e){var i=null,n=0,s=null,o=null,a=function(t,n){if(i!==t){if(i&&!t)switch(i){case"zoom":e.handleZoomEnd(n);break;case"drag":e.handleDragEnd(n)}switch(t){case"zoom":e.handleZoomStart(n);break;case"drag":e.handleDragStart(n)}}i=t},r=function(t){2===n?a("zoom"):1===n&&e.canDrag()?a("drag",t):a(null,t)},l=function(t){return Array.prototype.slice.call(t).map(function(t){return{x:t.pageX,y:t.pageY}})},c=function(t,e){var i,n;return i=t.x-e.x,n=t.y-e.y,Math.sqrt(i*i+n*n)},h=function(t,e){var i=c(t[0],t[1]),n=c(e[0],e[1]);return n/i},d=function(t){t.stopPropagation(),t.preventDefault()},u=function(t){var o=(new Date).getTime();if(n>1&&(s=null),o-s<300)switch(d(t),e.handleDoubleTap(t),i){case"zoom":e.handleZoomEnd(t);break;case"drag":e.handleDragEnd(t)}1===n&&(s=o)},p=!0;t.addEventListener("touchstart",function(t){e.enabled&&(p=!0,n=t.touches.length,u(t))}),t.addEventListener("touchmove",function(t){if(e.enabled){if(p)r(t),i&&d(t),o=l(t.touches);else{switch(i){case"zoom":e.handleZoom(t,h(o,l(t.touches)));break;case"drag":e.handleDrag(t)}i&&(d(t),e.update())}p=!1}}),t.addEventListener("touchend",function(t){e.enabled&&(n=t.touches.length,r(t))})};return e};t.exports=s.pichzoom=a(n)},function(t,e,i){"use strict";var n=i(1),s=i(2),o=n(window),a=function(t,e){this.options=n.extend({},a.DEFAULTS,e),this.$element=n(t),this.active=null,this.$popover=this.options.target&&n(this.options.target)||null,this.init(),this._bindEvents()};a.DEFAULTS={theme:null,trigger:"click",content:"",open:!1,target:null,position:"top",tpl:'
'},a.prototype.init=function(){function t(){i.sizePopover()}var e,i=this,o=this.$element;this.options.target||(this.$popover=this.getPopover(),this.setContent()),e=this.$popover,e.appendTo(n("body")),this.sizePopover(),o.on("open.popover.amui",function(){n(window).on("resize.popover.amui",s.utils.debounce(t,50))}),o.on("close.popover.amui",function(){n(window).off("resize.popover.amui",t)}),this.options.open&&this.open()},a.prototype.sizePopover=function(){var t=this.$element,e=this.$popover;if(e&&e.length){var i=e.outerWidth(),n=e.outerHeight(),s=e.find(".am-popover-caret"),a=s.outerWidth()/2||8,r=s.outerWidth()||8,l=n+8,c=t.outerWidth(),h=t.outerHeight(),d=t.offset(),u=t[0].getBoundingClientRect(),p=o.height(),m=o.width(),f=0,v=0,g=2,y="top";e.css({left:"",top:""}).removeClass("am-popover-left am-popover-right am-popover-top am-popover-bottom"),this.options.position&&(y=this.options.position),l>u.top&&"top"==y&&(y="bottom"),l>p-u.bottom&&"bottom"==y&&(y="top"),i+r>u.left-5&&"left"==y&&(y="right"),i+r>m-u.left-5&&"right"==y&&(y="left"),"top"==y&&(f=d.top-l-g,v=c/2+d.left-i/2,e.addClass("am-popover-top")),"bottom"==y&&(f=d.top+h+a+g,v=c/2+d.left-i/2,e.addClass("am-popover-bottom")),"left"==y&&(f=h/2+d.top-n/2,v=d.left-i-r,e.addClass("am-popover-left"),v+i>m&&(v=m-i-5,e.removeClass("am-popover-left").addClass("am-popover-right"))),"right"==y&&(f=h/2+d.top-n/2,v=d.left+c+r,e.addClass("am-popover-right")),e.css({top:f+"px",left:v+"px"})}},a.prototype.toggle=function(){return this[this.active?"close":"open"]()},a.prototype.open=function(){var t=this.$popover;this.$element.trigger("open.popover.amui"),this.sizePopover(),t.show().addClass("am-active"),this.active=!0},a.prototype.close=function(){var t=this.$popover;this.$element.trigger("close.popover.amui"),t.removeClass("am-active").trigger("closed.popover.amui").hide(),this.active=!1},a.prototype.getPopover=function(){var t=s.utils.generateGUID("am-popover"),e=[];return this.options.theme&&n.each(this.options.theme.split(" "),function(t,i){e.push("am-popover-"+n.trim(i))}),n(this.options.tpl).attr("id",t).addClass(e.join(" "))},a.prototype.setContent=function(t){t=t||this.options.content,this.$popover&&this.$popover.find(".am-popover-inner").empty().html(t)},a.prototype._bindEvents=function(){for(var t="popover.amui",e=this.options.trigger.split(" "),i=e.length;i--;){var s=e[i];if("click"===s)this.$element.on("click."+t,n.proxy(this.toggle,this));else{var o="hover"==s?"mouseenter":"focusin",a="hover"==s?"mouseleave":"focusout";this.$element.on(o+"."+t,n.proxy(this.open,this)),this.$element.on(a+"."+t,n.proxy(this.close,this))}}},a.prototype.destroy=function(){this.$element.off(".popover.amui").removeData("amui.popover"),this.$popover.remove()},s.plugin("popover",a),s.ready(function(t){n("[data-am-popover]",t).popover()}),t.exports=a},function(t,e,i){"use strict";var n=i(2),s=function(){function t(t,e,i){return ti?i:t}function e(t){return 100*(-1+t)}function i(t,i,n){var s;return s="translate3d"===c.positionUsing?{transform:"translate3d("+e(t)+"%,0,0)"}:"translate"===c.positionUsing?{transform:"translate("+e(t)+"%,0)"}:{"margin-left":e(t)+"%"},s.transition="all "+i+"ms "+n,s}function n(t,e){var i="string"==typeof t?t:a(t);return i.indexOf(" "+e+" ")>=0}function s(t,e){var i=a(t),s=i+e;n(i,e)||(t.className=s.substring(1))}function o(t,e){var i,s=a(t);n(t,e)&&(i=s.replace(" "+e+" "," "),t.className=i.substring(1,i.length-1))}function a(t){return(" "+(t.className||"")+" ").replace(/\s+/gi," ")}function r(t){t&&t.parentNode&&t.parentNode.removeChild(t)}var l={};l.version="0.2.0";var c=l.settings={minimum:.08,easing:"ease",positionUsing:"",speed:200,trickle:!0,trickleRate:.02,trickleSpeed:800,showSpinner:!0,parent:"body",barSelector:'[role="nprogress-bar"]',spinnerSelector:'[role="nprogress-spinner"]',template:'
'};l.configure=function(t){var e,i;for(e in t)i=t[e],void 0!==i&&t.hasOwnProperty(e)&&(c[e]=i);return this},l.status=null,l.set=function(e){var n=l.isStarted();e=t(e,c.minimum,1),l.status=1===e?null:e;var s=l.render(!n),o=s.querySelector(c.barSelector),a=c.speed,r=c.easing;return s.offsetWidth,h(function(t){""===c.positionUsing&&(c.positionUsing=l.getPositioningCSS()),d(o,i(e,a,r)),1===e?(d(s,{transition:"none",opacity:1}),s.offsetWidth,setTimeout(function(){d(s,{transition:"all "+a+"ms linear",opacity:0}),setTimeout(function(){l.remove(),t()},a)},a)):setTimeout(t,a)}),this},l.isStarted=function(){return"number"==typeof l.status},l.start=function(){l.status||l.set(0);var t=function(){setTimeout(function(){l.status&&(l.trickle(),t())},c.trickleSpeed)};return c.trickle&&t(),this},l.done=function(t){return t||l.status?l.inc(.3+.5*Math.random()).set(1):this},l.inc=function(e){var i=l.status;return i?("number"!=typeof e&&(e=(1-i)*t(Math.random()*i,.1,.95)),i=t(i+e,0,.994),l.set(i)):l.start()},l.trickle=function(){return l.inc(Math.random()*c.trickleRate)},function(){var t=0,e=0;l.promise=function(i){return i&&"resolved"!==i.state()?(0===e&&l.start(),t++,e++,i.always(function(){e--,0===e?(t=0,l.done()):l.set((t-e)/t)}),this):this}}(),l.render=function(t){if(l.isRendered())return document.getElementById("nprogress");s(document.documentElement,"nprogress-busy");var i=document.createElement("div");i.id="nprogress",i.innerHTML=c.template;var n,o=i.querySelector(c.barSelector),a=t?"-100":e(l.status||0),h=document.querySelector(c.parent);return d(o,{transition:"all 0 linear",transform:"translate3d("+a+"%,0,0)"}),c.showSpinner||(n=i.querySelector(c.spinnerSelector),n&&r(n)),h!=document.body&&s(h,"nprogress-custom-parent"),h.appendChild(i),i},l.remove=function(){o(document.documentElement,"nprogress-busy"),o(document.querySelector(c.parent),"nprogress-custom-parent");var t=document.getElementById("nprogress");t&&r(t)},l.isRendered=function(){return!!document.getElementById("nprogress")},l.getPositioningCSS=function(){var t=document.body.style,e="WebkitTransform"in t?"Webkit":"MozTransform"in t?"Moz":"msTransform"in t?"ms":"OTransform"in t?"O":"";return e+"Perspective"in t?"translate3d":e+"Transform"in t?"translate":"margin"};var h=function(){function t(){var i=e.shift();i&&i(t)}var e=[];return function(i){e.push(i),1==e.length&&t()}}(),d=function(){function t(t){return t.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,function(t,e){return e.toUpperCase()})}function e(t){var e=document.body.style;if(t in e)return t;for(var i,n=s.length,o=t.charAt(0).toUpperCase()+t.slice(1);n--;)if(i=s[n]+o,i in e)return i;return t}function i(i){return i=t(i),o[i]||(o[i]=e(i))}function n(t,e,n){e=i(e),t.style[e]=n}var s=["Webkit","O","Moz","ms"],o={};return function(t,e){var i,s,o=arguments;if(2==o.length)for(i in e)s=e[i],void 0!==s&&e.hasOwnProperty(i)&&n(t,i,s);else n(t,o[1],o[2])}}();return l}();t.exports=n.progress=s},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){this.options=n.extend({},o.DEFAULTS,e),this.$element=n(t),this.init()};o.DEFAULTS={width:"100%",size:null,type:"line",percentage:0,text:!0,textDes:"%",textInner:!1,status:null,iconDone:'',iconBreak:''},o.prototype.init=function(){var t=this.options;this.type=t.type;var e=this.$element,i=this.$outer=n('
');if("circle"===this.type)e.append(this.svg()),e.append(this.$text),e.addClass("am-progress-svg"),this.$svgPath=e.find(".am-progress-svg-path"),this.width=295;else{var r=i.append(s.append(o));e.append(r),e.addClass("am-progress"),this.width=s.width(),t.textInner?(o.append(a),i.addClass("am-progress-outer-disable"),e.addClass("am-progress")):e.append(a)}t.size&&e.addClass("am-progress-"+t.size),t.status&&e.addClass("am-progress-"+t.status),this.set(t.percentage)},o.prototype.reinit=function(){this.destory(),this.init()},o.prototype.set=function(t){if(t=+t>=100?100:+t,"circle"===this.type){var e=(100-t)/100*this.width;this.$svgPath.css("strokeDashoffset",e+"px")}else this.$bar.width(t+"%");this.$text.html(t+""+this.options.textDes),100==t?this.done():""},o.prototype.step=function(t){var e=null;if("circle"===this.type){var i=this.width,n=this.$svgPath.css("strokeDashoffset").slice(0,-2);e=Math.round((i-n)/i*100+t)}else e=Math.round(100*this.$bar.width()/this.width+(+t||2));this.set(e)},o.prototype.done=function(){this.$text.html(this.options.iconDone),this.$element.addClass("am-progress-success")},o.prototype["break"]=function(){this.$text.html(this.options.iconBreak),this.$element.addClass("am-progress-danger")},o.prototype.svg=function(){return this.$svg=n(''),this.$svg},o.prototype.destory=function(){this.$text.remove(),this.$svg&&this.$svg.remove(),this.$outer.remove(),this.$element.removeClass()},s.plugin("progressbar",o),s.ready(function(t){n("[data-am-progressbar]",t).progressbar()}),t.exports=o},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){if(s.support.animation){this.options=n.extend({},o.DEFAULTS,e),this.$element=n(t);var i=function(){s.utils.rAF.call(window,n.proxy(this.checkView,this))}.bind(this);this.$window=n(window).on("scroll.scrollspy.amui",i).on("resize.scrollspy.amui orientationchange.scrollspy.amui",s.utils.debounce(i,50)),this.timer=this.inViewState=this.initInView=null,i()}};o.DEFAULTS={animation:"fade",className:{inView:"am-scrollspy-inview",init:"am-scrollspy-init"},repeat:!0,delay:0,topOffset:0,leftOffset:0},o.prototype.checkView=function(){var t=this.$element,e=this.options,i=s.utils.isInView(t,e),n=e.animation?" am-animation-"+e.animation:"";i&&!this.inViewState&&(this.timer&&clearTimeout(this.timer),this.initInView||(t.addClass(e.className.init),this.offset=t.offset(),this.initInView=!0,t.trigger("init.scrollspy.amui")),this.timer=setTimeout(function(){i&&t.addClass(e.className.inView+n).width()},e.delay),this.inViewState=!0,t.trigger("inview.scrollspy.amui")),!i&&this.inViewState&&e.repeat&&(t.removeClass(e.className.inView+n),this.inViewState=!1,t.trigger("outview.scrollspy.amui"))},o.prototype.check=function(){s.utils.rAF.call(window,n.proxy(this.checkView,this))},s.plugin("scrollspy",o),s.ready(function(t){n("[data-am-scrollspy]",t).scrollspy()}),t.exports=o},function(t,e,i){"use strict";var n=i(1),s=i(2);i(20);var o=function(t,e){this.options=n.extend({},o.DEFAULTS,e),this.$element=n(t),this.anchors=[],this.$links=this.$element.find('a[href^="#"]').each(function(t,e){this.anchors.push(n(e).attr("href"))}.bind(this)),this.$targets=n(this.anchors.join(", "));var i=function(){s.utils.rAF.call(window,n.proxy(this.process,this))}.bind(this);this.$window=n(window).on("scroll.scrollspynav.amui",i).on("resize.scrollspynav.amui orientationchange.scrollspynav.amui",s.utils.debounce(i,50)),i(),this.scrollProcess()};o.DEFAULTS={className:{active:"am-active"},closest:!1,smooth:!0,offsetTop:0},o.prototype.process=function(){var t=this.$window.scrollTop(),e=this.options,i=[],o=this.$links,a=this.$targets;if(a.each(function(t,n){s.utils.isInView(n,e)&&i.push(n)}),i.length){var r;if(n.each(i,function(e,i){if(n(i).offset().top>=t)return r=n(i),!1}),!r)return;e.closest?(o.closest(e.closest).removeClass(e.className.active),o.filter('a[href="#'+r.attr("id")+'"]').closest(e.closest).addClass(e.className.active)):o.removeClass(e.className.active).filter('a[href="#'+r.attr("id")+'"]').addClass(e.className.active)}},o.prototype.scrollProcess=function(){var t=this.$links,e=this.options;e.smooth&&n.fn.smoothScroll&&t.on("click",function(t){t.preventDefault();var i=n(this),s=n(i.attr("href"));if(s){var o=e.offsetTop&&!isNaN(parseInt(e.offsetTop))&&parseInt(e.offsetTop)||0;n(window).smoothScroll({position:s.offset().top-o})}})},s.plugin("scrollspynav",o),s.ready(function(t){n("[data-am-scrollspynav]",t).scrollspynav()}),t.exports=o},function(t,e,i){"use strict";var n=i(1),s=i(2),o=s.utils.rAF,a=s.utils.cancelAF,r=!1,l=function(t,e){function i(t){return(t/=.5)<1?.5*Math.pow(t,5):.5*(Math.pow(t-2,5)+2)}function s(){p.off("touchstart.smoothscroll.amui",w),r=!1}function c(t){r&&(h||(h=t),d=Math.min(1,Math.max((t-h)/y,0)),u=Math.round(f+g*i(d)),g>0&&u>m&&(u=m),g<0&&u=0};var o=function(t,e){this.$element=n(t),this.options=n.extend({},o.DEFAULTS,{placeholder:t.getAttribute("placeholder")||o.DEFAULTS.placeholder},e),this.$originalOptions=this.$element.find("option"),this.multiple=t.multiple,this.$selector=null,this.initialized=!1,this.init()};o.DEFAULTS={btnWidth:null,btnSize:null,btnStyle:"default",dropUp:0,maxHeight:null,maxChecked:null,placeholder:"\u70b9\u51fb\u9009\u62e9...",selectedClass:"am-checked",disabledClass:"am-disabled",searchBox:!1,tpl:'

\u8fd4\u56de

<% if (searchBox) { %> <% } %>
    <% for (var i = 0; i < options.length; i++) { %> <% var option = options[i] %> <% if (option.header) { %>
  • <%= option.text %>
  • <% } else { %>
  • <%= option.text %>
  • <% } %> <% } %>
',listTpl:'<% for (var i = 0; i < options.length; i++) { %> <% var option = options[i] %> <% if (option.header) { %>
  • <%= option.text %>
  • <% } else { %>
  • <%= option.text %>
  • <% } %> <% } %>'},o.prototype.init=function(){var t=this,e=this.$element,i=this.options;e.hide();var o={id:s.utils.generateGUID("am-selected"),multiple:this.multiple,options:[],searchBox:i.searchBox,dropUp:i.dropUp,placeholder:i.placeholder};this.$selector=n(s.template(this.options.tpl,o)),this.$selector.css({width:this.options.btnWidth}),this.$list=this.$selector.find(".am-selected-list"),this.$searchField=this.$selector.find(".am-selected-search input"),this.$hint=this.$selector.find(".am-selected-hint");var a=this.$selector.find(".am-selected-btn"),r=[];i.btnSize&&r.push("am-btn-"+i.btnSize),i.btnStyle&&r.push("am-btn-"+i.btnStyle),a.addClass(r.join(" ")),this.$selector.dropdown({justify:a}),e[0].disabled&&this.disable(),i.maxHeight&&this.$selector.find(".am-selected-list").css({"max-height":i.maxHeight,"overflow-y":"scroll"});var l=[],c=e.attr("minchecked"),h=e.attr("maxchecked")||i.maxChecked;this.maxChecked=h||1/0,e[0].required&&l.push("\u5fc5\u9009"),(c||h)&&(c&&l.push("\u81f3\u5c11\u9009\u62e9 "+c+" \u9879"),h&&l.push("\u81f3\u591a\u9009\u62e9 "+h+" \u9879")),this.$hint.text(l.join("\uff0c")),this.renderOptions(),this.$element.after(this.$selector),this.dropdown=this.$selector.data("amui.dropdown"),this.$status=this.$selector.find(".am-selected-status"),setTimeout(function(){t.syncData(),t.initialized=!0},0),this.bindEvents()},o.prototype.renderOptions=function(){function t(t,e,s){if(""===e.value)return!0;var o="";e.disabled&&(o+=i.disabledClass),!e.disabled&&e.selected&&(o+=i.selectedClass),n.push({group:s,index:t,classNames:o,text:e.text,value:e.value})}var e=this.$element,i=this.options,n=[],o=e.find("optgroup");this.$originalOptions=this.$element.find("option"),this.multiple||null!==e.val()||this.$originalOptions.length&&(this.$originalOptions.get(0).selected=!0),o.length?o.each(function(e){n.push({header:!0,group:e+1,text:this.label}),o.eq(e).find("option").each(function(i,n){t(i,n,e)})}):this.$originalOptions.each(function(e,i){t(e,i,null)}),this.$list.html(s.template(i.listTpl,{options:n})),this.$shadowOptions=this.$list.find("> li").not(".am-selected-list-header")},o.prototype.setChecked=function(t){var e=this.options,i=n(t),s=i.hasClass(e.selectedClass);if(this.multiple){var o=this.$list.find("."+e.selectedClass).length;if(!s&&this.maxChecked<=o)return this.$element.trigger("checkedOverflow.selected.amui",{selected:this}),!1}else{if(this.dropdown.close(),s)return!1;this.$shadowOptions.not(i).removeClass(e.selectedClass)}i.toggleClass(e.selectedClass),this.syncData(t)},o.prototype.syncData=function(t){var e=this,i=this.options,s=[],o=n([]);if(this.$shadowOptions.filter("."+i.selectedClass).each(function(){var i=n(this);s.push(i.find(".am-selected-text").text()),t||(o=o.add(e.$originalOptions.filter('[value="'+i.data("value")+'"]').prop("selected",!0)))}),t){var a=n(t);this.$originalOptions.filter('[value="'+a.data("value")+'"]').prop("selected",a.hasClass(i.selectedClass))}else this.$originalOptions.not(o).prop("selected",!1);this.$element.val()||(s=[i.placeholder]),this.$status.text(s.join(", ")),this.initialized&&this.$element.trigger("change")},o.prototype.bindEvents=function(){var t=this,e="am-selected-list-header",i=s.utils.debounce(function(i){t.$shadowOptions.not("."+e).hide().filter(':containsNC("'+i.target.value+'")').show()},100);this.$list.on("click","> li",function(i){var s=n(this);!s.hasClass(t.options.disabledClass)&&!s.hasClass(e)&&t.setChecked(this)}),this.$searchField.on("keyup.selected.amui",i),this.$selector.on("closed.dropdown.amui",function(){t.$searchField.val(""),t.$shadowOptions.css({display:""})}),this.$element.on("validated.field.validator.amui",function(e){if(e.validity){var i=e.validity.valid,n="am-invalid";t.$selector[(i?"remove":"add")+"Class"](n)}}),s.support.mutationobserver&&(this.observer=new s.support.mutationobserver(function(){t.$element.trigger("changed.selected.amui")}),this.observer.observe(this.$element[0],{childList:!0,subtree:!0,characterData:!0})),this.$element.on("changed.selected.amui",function(){t.renderOptions(),t.syncData()})},o.prototype.select=function(t){var e;e="number"==typeof t?this.$list.find("> li").not(".am-selected-list-header").eq(t):"string"==typeof t?this.$list.find(t):n(t),e.trigger("click")},o.prototype.enable=function(){this.$element.prop("disable",!1),this.$selector.dropdown("enable")},o.prototype.disable=function(){this.$element.prop("disable",!0),this.$selector.dropdown("disable")},o.prototype.destroy=function(){this.$element.removeData("amui.selected").show(),this.$selector.remove()},s.plugin("selected",o),s.ready(function(t){n("[data-am-selected]",t).selected()}),t.exports=o},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){this.$element=n(t),this.options=n.extend({},o.DEFAULTS,e),this.status=!0,this.init()};o.DEFAULTS={width:"100%",height:"100%",speed:200,infiniteLoop:!0,autoplay:!1,autoplaySpeed:2e3,arrow:!0,arrowPre:'',arrowNext:'',dots:!0,dotClass:null,keyboard:!0,resize:null},o.prototype.init=function(){var t=this.$element,e=this.options,i=this.$wrapper=t.find(".am-slider-wrapper"),n=this.$child=t.find(".am-slider-item");t.addClass("am-slider"),t.css("width",e.width),this.width=t.width(),this.length=n.length,this.$allWidth=this.width*n.length,this.$fullWidth=this.width*(n.length+2),n.css("width",this.width),i.css("width",this.$fullWidth),i.append(i.children().first().clone()),i.prepend(i.children().eq(this.length-1).clone()),this.prefix()?this.wheel=this.transformMove:this.wheel=this.leftMove,this.wheel("-"+this.width),this.index=0,this.position=-this.width,this.prefix()&&(this.transitionDuration(this.options.speed),i.css("transition-timing-function","ease")),e.keyboard&&this.keyboard(),e.autoplay&&this.autoplay(),e.arrow&&this.arrow(),e.dots&&this.dots()},o.prototype.leftMove=function(t){this.$wrapper.css("marginLeft",t+"px")},o.prototype.transformMove=function(t){var e="translate3d("+t+"px,0,0)";this.$wrapper.css(this.prop,e),this.$wrapper.css("transform",e)},o.prototype.move=function(t,e){var i=this;if("next"===e){if(this.index+1>this.length)return!0;this.position=this.position-this.width,this.index=this.index+1}else if("prev"===e){if(this.index<0)return!0;this.position=this.position+this.width,this.index=this.index-1}return this.wheel(this.position),this.$element.trigger("change.slider.amui"),this.index!==-1&&this.index!==this.length||s.support.transition&&this.$wrapper.one(s.support.transition.end,function(){i.transitionDuration(0),i.index===i.length?(i.wheel(-i.width),i.index=0,i.position=-i.width):i.index===-1&&(i.wheel(-i.length*i.width),i.index=i.length-1,i.position=-i.length*i.width),i.dotActive(i.index)}).emulateTransitionEnd(i.options.speed+50),this.transitionDuration(this.options.speed),this.dotActive(),!0},o.prototype.transitionDuration=function(t){this.$wrapper.css("-"+this.pfx+"transition-duration",t+"ms"),this.$wrapper.css("transition-duration",t+"ms")},o.prototype.next=function(){return!this.options.infiniteLoop&&this.index===this.length-1||void this.move(this.position,"next")},o.prototype.prev=function(){return!this.options.infiniteLoop&&0===this.index||void this.move(this.position,"prev")},o.prototype.autoplay=function(){var t=this,e=window.setInterval(function(){t.next()},t.options.autoplaySpeed);this.$element.on("mouseover.slider.amui",function(){clearInterval(e)}).on("mouseout.slider.amui",function(){e=window.setInterval(function(){t.next()},t.options.autoplaySpeed)})},o.prototype.dots=function(){for(var t='
    ',e='',i=0;i",this.$element.append(t),this.dotActive(),this.dotMove()},o.prototype.dotActive=function(t){t=t||this.index,this.$element.find(".am-slider-dot").removeClass("active"),this.$element.find(".am-slider-dot").eq(t).addClass("active")},o.prototype.dotMove=function(){var t=this;this.$element.find(".am-slider-dot").on("click.slider.amui",function(){var e=t.index,i=t.$element.find(".am-slider-dot").index(this),n=(e-i)*t.width+t.position;t.index=i,t.position=n,t.move(n)})},o.prototype.arrow=function(){var t=this;this.$element.append(this.options.arrowPre,this.options.arrowNext),this.$element.find(".am-slider-arrow-prev").on("click.slider.amui",function(){t.prev()}),this.$element.find(".am-slider-arrow-next").on("click.slider.amui",function(){t.next()})},o.prototype.keyboard=function(){var t=this;n("body").on("keydown.slider.amui",function(e){var i=e.which;37===i||38===i?t.prev():39!==i&&40!==i||t.next()})},o.prototype.getIndex=function(){return this.index},o.prototype.prefix=function(){var t=document.createElement("div"),e=["perspectiveProperty","WebkitPerspective","MozPerspective","OPerspective","msPerspective"];for(var i in e)if(void 0!==t.style[e[i]])return this.pfx=e[i].replace("Perspective","").toLowerCase(),this.prop="-"+this.pfx+"-transform",!0;return!1},s.plugin("slider",o),s.ready(function(t){n("[data-am-slider]",t).slider()}),t.exports=o},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){var i=this;this.options=n.extend({},o.DEFAULTS,e),this.$element=n(t),this.sticked=null,this.inited=null,this.$holder=void 0,this.$window=n(window).on("scroll.sticky.amui",s.utils.debounce(n.proxy(this.checkPosition,this),10)).on("resize.sticky.amui orientationchange.sticky.amui",s.utils.debounce(function(){ i.reset(!0,function(){i.checkPosition()})},50)).on("load.sticky.amui",n.proxy(this.checkPosition,this)),this.offset=this.$element.offset(),this.init()};o.DEFAULTS={top:0,bottom:0,animation:"",className:{sticky:"am-sticky",resetting:"am-sticky-resetting",stickyBtm:"am-sticky-bottom",animationRev:"am-animation-reverse"}},o.prototype.init=function(){var t=this.check();if(!t)return!1;var e=this.$element,i="";n.each(e.css(["marginTop","marginRight","marginBottom","marginLeft"]),function(t,e){return i+=" "+e});var s=n('
    ').css({height:"absolute"!==e.css("position")?e.outerHeight():"","float":"none"!=e.css("float")?e.css("float"):"",margin:i});return this.$holder=e.css("margin",0).wrap(s).parent(),this.inited=1,!0},o.prototype.reset=function(t,e){var i=this.options,n=this.$element,o=i.animation?" am-animation-"+i.animation:"",a=function(){n.css({position:"",top:"",width:"",left:"",margin:0}),n.removeClass([o,i.className.animationRev,i.className.sticky,i.className.resetting].join(" ")),this.animating=!1,this.sticked=!1,this.offset=n.offset(),e&&e()}.bind(this);n.addClass(i.className.resetting),!t&&i.animation&&s.support.animation?(this.animating=!0,n.removeClass(o).one(s.support.animation.end,function(){a()}).width(),n.addClass(o+" "+i.className.animationRev)):a()},o.prototype.check=function(){if(!this.$element.is(":visible"))return!1;var t=this.options.media;if(t)switch(typeof t){case"number":if(window.innerWidththis.$holder.offset().top;!this.sticked&&l?o.addClass(r):this.sticked&&!l&&this.reset(),this.$holder.css({height:o.is(":visible")&&"absolute"!==o.css("position")?o.outerHeight():""}),l&&o.css({top:n,left:this.$holder.offset().left,width:this.$holder.width()}),this.sticked=l},s.plugin("sticky",o),n(window).on("load",function(){n("[data-am-sticky]").sticky()}),t.exports=o},function(t,e,i){"use strict";function n(t){var e,i=Array.prototype.slice.call(arguments,1);return this.each(function(){var n=s(this),a=n.is(".am-tabs")&&n||n.closest(".am-tabs"),r=a.data("amui.tabs"),l=s.extend({},o.utils.parseOptions(n.data("amTabs")),s.isPlainObject(t)&&t);r||a.data("amui.tabs",r=new c(a[0],l)),"string"==typeof t&&("open"===t&&n.is(".am-tabs-nav a")?r.open(n):e="function"==typeof r[t]?r[t].apply(r,i):r[t])}),void 0===e?this:e}var s=i(1),o=i(2),a=i(3),r=o.support.transition,l=o.support.animation,c=function(t,e){this.$element=s(t),this.options=s.extend({},c.DEFAULTS,e||{}),this.transitioning=this.activeIndex=null,this.refresh(),this.init()};c.DEFAULTS={selector:{nav:"> .am-tabs-nav",content:"> .am-tabs-bd",panel:"> .am-tab-panel"},activeClass:"am-active"},c.prototype.refresh=function(){var t=this.options.selector;this.$tabNav=this.$element.find(t.nav),this.$navs=this.$tabNav.find("a"),this.$content=this.$element.find(t.content),this.$tabPanels=this.$content.find(t.panel);var e=this.$tabNav.find("> ."+this.options.activeClass);1!==e.length?this.open(0):this.activeIndex=this.$navs.index(e.children("a"))},c.prototype.init=function(){var t=this,e=this.options;if(this.$element.on("click.tabs.amui",e.selector.nav+" a",function(e){e.preventDefault(),t.open(s(this))}),!e.noSwipe){if(!this.$content.length)return this;var i=new a.Manager(this.$content[0]),n=new a.Swipe({direction:a.DIRECTION_HORIZONTAL});i.add(n),i.on("swipeleft",o.utils.debounce(function(e){e.preventDefault(),t.goTo("next")},100)),i.on("swiperight",o.utils.debounce(function(e){e.preventDefault(),t.goTo("prev")},100)),this._hammer=i}},c.prototype.open=function(t){var e=this.options.activeClass,i="number"==typeof t?t:this.$navs.index(s(t));if(t="number"==typeof t?this.$navs.eq(i):s(t),t&&t.length&&!this.transitioning&&!t.parent("li").hasClass(e)){var n=this.$tabNav,o=t.attr("href"),a=/^#.+$/,r=a.test(o)&&this.$content.find(o)||this.$tabPanels.eq(i),l=n.find("."+e+" a")[0],c=s.Event("open.tabs.amui",{relatedTarget:l});t.trigger(c),c.isDefaultPrevented()||(this.activate(t.closest("li"),n),this.activate(r,this.$content,function(){t.trigger({type:"opened.tabs.amui",relatedTarget:l})}),this.activeIndex=i)}},c.prototype.activate=function(t,e,i){this.transitioning=!0;var n=this.options.activeClass,o=e.find("> ."+n),a=i&&r&&!!o.length;o.removeClass(n+" am-in"),t.addClass(n),a?(t.redraw(),t.addClass("am-in")):t.removeClass("am-fade");var l=s.proxy(function(){i&&i(),this.transitioning=!1},this);a&&!this.$content.is(".am-tabs-bd-ofv")?o.one(r.end,l):l()},c.prototype.goTo=function(t){var e=this.activeIndex,i="next"===t,n=i?"am-animation-right-spring":"am-animation-left-spring";if(i&&e+1>=this.$navs.length||!i&&0===e){var s=this.$tabPanels.eq(e);l&&s.addClass(n).on(l.end,function(){s.removeClass(n)})}else this.open(i?e+1:e-1)},c.prototype.destroy=function(){this.$element.off(".tabs.amui"),a.off(this.$content[0],"swipeleft swiperight"),this._hammer&&this._hammer.destroy(),s.removeData(this.$element,"amui.tabs")},s.fn.tabs=n,o.ready(function(t){s("[data-am-tabs]",t).tabs()}),s(document).on("click.tabs.amui.data-api","[data-am-tabs] .am-tabs-nav a",function(t){t.preventDefault(),n.call(s(this),"open")}),t.exports=o.tabs=c},function(t,e,i){"use strict";function n(t,e,i){e.addClass(t.classes.selected),"item"===e.data("type")&&i.hasClass(t.itemIcon)&&i.removeClass(t.itemIcon).addClass(t.itemSelectedIcon)}function s(t,e,i){e.removeClass(t.classes.selected),"item"===e.data("type")&&i.hasClass(t.itemSelectedIcon)&&i.removeClass(t.itemSelectedIcon).addClass(t.itemIcon)}function o(t,e,i){r.each(i.$elements,function(t,n){var s=r(n);s[0]!==e.$element[0]&&i.dataForEvent.push(r(s).data())}),e.$element.hasClass(t.classes.selected)?(s(t,e.$element,e.$icon),i.eventType="deselected"):(n(t,e.$element,e.$icon),i.eventType="selected",i.dataForEvent.push(e.elementData))}function a(t,e,i){if(i.$elements[0]!==e.$element[0]){t.deselectAll(t.$element);n(t,e.$element,e.$icon),i.eventType="selected",i.dataForEvent=[e.elementData]}else s(t,e.$element,e.$icon),i.eventType="deselected",i.dataForEvent=[]}var r=i(1),l=i(2),c=(r.fn.tree,function h(t,e){this.$element=r(t),this.options=r.extend({},h.DEFAULTS,e);var i=this.$element.data("itemIcon")||this.options.itemIcon,n=this.$element.data("itemSelectedIcon")||this.options.itemSelectedIcon;this.folderIcon=this._getIconClass(this.options.folderIcon),this.folderOpenIcon=this._getIconClass(this.options.folderOpenIcon),this.itemIcon=this._getIconClass(i),this.itemSelectedIcon=this._getIconClass(n),this.classes={},r.each(this.options.classes,r.proxy(function(t,e){this.classes[t]=this._getClass(e)},this)),this.options.itemSelect&&this.$element.on("click.tree.amui","."+this.classes.item,r.proxy(function(t){this.selectItem(t.currentTarget)},this)),this.$element.on("click.tree.amui","."+this.classes.branchName,r.proxy(function(t){this.toggleFolder(t.currentTarget)},this)),this.options.folderSelect&&(this.$element.addClass(this.options.classPrefix+"-folder-select"),this.$element.off("click.tree.amui","."+this.classes.branchName),this.$element.on("click.tree.amui","."+this.classes.iconCaret,r.proxy(function(t){this.toggleFolder(r(t.currentTarget).parent())},this)),this.$element.on("click.tree.amui","."+this.classes.branchName,r.proxy(function(t){this.selectFolder(r(t.currentTarget))},this))),this.render()});c.prototype={constructor:c,deselectAll:function(t){var e=this;t=t||this.$element;var i=r(t).find("."+this.classes.selected);return i.each(function(t,i){s(e,r(i),r(i).find("."+e.classes.icon))}),i},destroy:function(){return this.$element.find("li:not([data-template])").remove(),this.$element.remove(),this.$element[0].outerHTML},render:function(){this.populate(this.$element)},populate:function(t){var e=this,i=t.hasClass(this.options.classPrefix)?t:t.parent(),n=i.find("."+this.classes.loader).eq(0),s=i.data();n.removeClass(this.options.hiddenClass),this.options.dataSource(s,function(s){n.addClass(e.options.hiddenClass),r.each(s.data,function(n,s){var o;"folder"===s.type?(o=e.$element.find("[data-template=treebranch]").first().clone().removeClass(e.options.hiddenClass).removeData("template"),o.data(s),o.find("."+e.classes.iconFolder).addClass(e.folderIcon),o.find("."+e.classes.branchName+" > ."+e.classes.label).html(s.title)):"item"===s.type&&(o=e.$element.find("[data-template=treeitem]").first().clone().removeClass(e.options.hiddenClass).removeData("template"),o.find("."+e.classes.itemName+" > ."+e.classes.label).html(s.title),o.data(s),o.find("."+e.classes.iconItem).addClass(e.itemIcon));var a=s.attr||[];r.each(a,function(t,i){switch(t){case"classNames":o.addClass(i);break;case"icon":var n=[e.classes.icon,e.classes.iconItem,i].join(" ");o.find("."+e.classes.iconItem).removeClass().addClass(n),o.data(t,i);break;case"id":o.attr(t,i),o.attr("aria-labelledby",i+"-label"),o.find("."+e.classes.branchName+" > ."+e.classes.label).attr("id",i+"-label");break;default:o.attr(t,i)}}),t.hasClass(e.classes.branchHeader)?i.find("."+e.classes.branchChildren).eq(0).append(o):t.append(o)}),e.$element.trigger("loaded.tree.amui",i)})},selectTreeNode:function(t,e){var i={};i.$element=r(t);var n={};n.$elements=this.$element.find("."+this.classes.selected),n.dataForEvent=[],"folder"===e?(i.$element=i.$element.closest("."+this.classes.branch),i.$icon=i.$element.find("."+this.classes.iconFolder)):i.$icon=i.$element.find("."+this.classes.iconItem),i.elementData=i.$element.data(),this.options.multiSelect?o(this,i,n):a(this,i,n),this.$element.trigger(n.eventType+".tree.amui",{target:i.elementData,selected:n.dataForEvent}),i.$element.trigger("updated.tree.amui",{selected:n.dataForEvent,item:i.$element,eventType:n.eventType})},discloseFolder:function(t){var e=r(t),i=e.closest("."+this.classes.branch),n=i.find("."+this.classes.branchChildren),s=n.eq(0);i.addClass(this.classes.open),i.attr("aria-expanded","true"),s.removeClass(this.options.hiddenClass),i.find("> ."+this.classes.branchHeader+" ."+this.classes.iconFolder).eq(0).removeClass(this.folderIcon).addClass(this.folderOpenIcon),n.children().length||this.populate(n),this.$element.trigger("disclosedFolder.tree.amui",i.data())},closeFolder:function(t){var e=r(t),i=e.closest("."+this.classes.branch),n=i.find("."+this.classes.branchChildren),s=n.eq(0);i.removeClass(this.classes.open),i.attr("aria-expanded","false"),s.addClass(this.options.hiddenClass),i.find("> ."+this.classes.branchHeader+" ."+this.classes.iconFolder).eq(0).removeClass(this.folderOpenIcon).addClass(this.folderIcon),this.options.cacheItems||s.empty(),this.$element.trigger("closed.tree.amui",i.data())},toggleFolder:function(t){var e=r(t);e.find("."+this.folderIcon).length?this.discloseFolder(t):e.find("."+this.folderOpenIcon).length&&this.closeFolder(t)},selectFolder:function(t){this.options.folderSelect&&this.selectTreeNode(t,"folder")},selectItem:function(t){this.options.itemSelect&&this.selectTreeNode(t,"item")},selectedItems:function(){var t=this.$element.find("."+this.classes.selected),e=[];return r.each(t,function(t,i){e.push(r(i).data())}),e},closeAll:function(){var t=this,e=[],i=function n(i,s){e.push(s),0===t.$element.find("."+t.classes.branch+"."+t.classes.open+':not(".am-hide")').length&&(t.$element.trigger("closedAll.tree.amui",{tree:t.$element,reportedClosed:e}),t.$element.off("loaded.tree.amui",t.$element,n))};t.$element.on("closed.tree.amui",i),t.$element.find("."+t.classes.branch+"."+t.classes.open+':not(".am-hide")').each(function(){t.closeFolder(this)})},discloseVisible:function(){var t=this,e=t.$element.find("."+this.classes.branch+':not(".'+this.classes.open+', .am-hide")'),i=[],n=function s(n,o){i.push(o),i.length===e.length&&(t.$element.trigger("disclosedVisible.tree.amui",{tree:t.$element,reportedOpened:i}),t.$element.off("loaded.tree.amui",t.$element,s))};t.$element.on("loaded.tree.amui",n),t.$element.find("."+this.classes.branch+':not(".'+this.classes.open+', .am-hide")').each(function(){t.discloseFolder(r(this).find("."+t.classes.branchHeader))})},discloseAll:function(){var t=this;"undefined"==typeof t.$element.data("disclosures")&&t.$element.data("disclosures",0);var e=t.options.disclosuresUpperLimit>=1&&t.$element.data("disclosures")>=t.options.disclosuresUpperLimit,i=0===t.$element.find("."+this.classes.branch+':not(".'+this.classes.open+', .am-hide")').length;if(i)t.$element.trigger("disclosedAll.tree.amui",{tree:t.$element,disclosures:t.$element.data("disclosures")}),t.options.cacheItems||t.$element.one("closeAll.tree.amui",function(){t.$element.data("disclosures",0)});else{if(e&&(t.$element.trigger("exceededDisclosuresLimit.tree.amui",{tree:t.$element,disclosures:t.$element.data("disclosures")}),!t.$element.data("ignore-disclosures-limit")))return;t.$element.data("disclosures",t.$element.data("disclosures")+1),t.$element.one("disclosedVisible.tree.amui",function(){t.discloseAll()}),t.discloseVisible()}},_getIconClass:function(t,e){return(e?".":"")+"am-icon-"+t},_getClass:function(t,e){return(e?".":"")+this.options.classPrefix+"-"+t}},c.prototype.openFolder=c.prototype.discloseFolder,c.DEFAULTS={dataSource:function(t,e){},multiSelect:!1,cacheItems:!0,folderSelect:!0,itemSelect:!0,disclosuresUpperLimit:0,folderIcon:"plus-square-o",folderOpenIcon:"minus-square-o",itemIcon:"angle-right",itemSelectedIcon:"check",hiddenClass:"am-hide",classPrefix:"am-tree",classes:{branch:"branch",branchName:"branch-name",branchChildren:"branch-children",branchHeader:"branch-header",item:"item",itemName:"item-name",label:"label",icon:"icon",iconFolder:"icon-folder",iconItem:"icon-item",iconCaret:"icon-caret",loader:"loader",selected:"selected",open:"open"}},l.plugin("tree",c),t.exports=c},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){this.options=n.extend({},o.DEFAULTS,e),this.$element=n(t),this.init()};o.DEFAULTS={checkboxClass:"am-ucheck-checkbox",radioClass:"am-ucheck-radio",checkboxTpl:'',radioTpl:''},o.prototype.init=function(){var t=this.$element,e=t[0],i=this.options;"checkbox"===e.type?t.addClass(i.checkboxClass).after(i.checkboxTpl):"radio"===e.type&&t.addClass(i.radioClass).after(i.radioTpl)},o.prototype.check=function(){this.$element.prop("checked",!0).trigger("change.ucheck.amui").trigger("checked.ucheck.amui")},o.prototype.uncheck=function(){this.$element.prop("checked",!1).trigger("change").trigger("unchecked.ucheck.amui")},o.prototype.toggle=function(){this.$element.prop("checked",function(t,e){return!e}).trigger("change.ucheck.amui").trigger("toggled.ucheck.amui")},o.prototype.disable=function(){this.$element.prop("disabled",!0).trigger("change.ucheck.amui").trigger("disabled.ucheck.amui")},o.prototype.enable=function(){this.$element.prop("disabled",!1),this.$element.trigger("change.ucheck.amui").trigger("enabled.ucheck.amui")},o.prototype.destroy=function(){this.$element.removeData("amui.ucheck").removeClass(this.options.checkboxClass+" "+this.options.radioClass).next(".am-ucheck-icons").remove().end().trigger("destroyed.ucheck.amui")},s.plugin("uCheck",o,{after:function(){s.support.touch&&this.parent().hover(function(){n(this).addClass("am-nohover")},function(){n(this).removeClass("am-nohover")})}}),s.ready(function(t){n("[data-am-ucheck]",t).uCheck()}),t.exports=o},function(t,e,i){"use strict";function n(t,e,i,n){var o={url:"",type:"POST",cache:!1,data:t,timeout:0,processData:!1,contentType:!1,xhr:function(){var t=s.ajaxSettings.xhr();return t.upload&&t.upload.addEventListener("progress",function(t){if(t.lengthComputable){var o=t.loaded/t.total*100;i.isPB&&(s(n).progressbar("set",o),100===o&&i.options.hideTime&&window.setTimeout(function(){s(n).progressbar("destory")},i.options.hideTime)),100===o&&(i.updateFiles(e),i.$element.trigger("complete.upload.amui"))}},!1),t}};s.extend(o,i.options.header),s.ajax(o)}var s=i(1),o=i(2),a=function(t,e){this.options=s.extend({},a.DEFAULTS,e),this.$element=s(t),this.init(),this.eventBind()};a.DEFAULTS={type:["image/png","image/jpg","image/gif","image/jpeg"],size:null,hideTime:2e3,header:null,data:null,tpl:'
    '},a.prototype.init=function(){var t=this.$element;t.addClass("am-upload"),t.append(this.options.tpl),this.$input=t.find(".am-upload-input"),this.$button=t.find(".am-upload-btn"),this.$list=s('
      '),t.append(this.$list),this.fileList=[],this.test(),this.start()},a.prototype.test=function(){s.fn.progressbar&&(this.isPB=!0)},a.prototype.eventBind=function(){this["delete"]()},a.prototype.start=function(){var t=this;this.$input.on("change",function(){s.each(this.files,function(){function e(t,e){var i=!1;return console.log(e),t.forEach(function(t){if(t===e)return void(i=!0)}),!i}var i=o.utils.generateGUID("am-upload"),n=t.options.size;if(n&&1024*n>this.size)return alert("\u6587\u4ef6\u5927\u5c0f\u6700\u5927\u4e3a"+n),!1;if(e(t.options.type,this.type))return alert("\u4e0d\u652f\u6301\u7684\u7c7b\u578b -- unsupported file type"),!1;this.uuid=i;var s=t.tpl(this,i);t.formdata(this,s)})})},a.prototype.formdata=function(t,e){var i=new FormData,o=this.options.data;if(i.append("file",t),"object"===s.type(o))for(var a in o)i.append(a,o[a]);n(i,t,this,e)},a.prototype.beforeUpload=function(){},a.prototype.tpl=function(t,e){var i=s('
    • '+t.name+"
    • "),n=s('\u5220\u9664'),o=s("
      ");return i.attr("uuid",e),i.append(n),i.append(o),this.$list.append(i),this.isPB&&s(o).progressbar({size:"xs"}),o},a.prototype["delete"]=function(){var t=this;this.$element.on("click.upload.amui",".am-upload-remove",function(){var e=s(this).parent(),i=e.attr("uuid");e.remove(),t.deleteFiles(i),t.$element.trigger("delete.upload.amui")})},a.prototype.getFileList=function(){return this.fileList},a.prototype.deleteFiles=function(t){var e=this;this.fileList.forEach(function(i,n){i.uuid===t&&e.fileList.splice(n,1)})},a.prototype.updateFiles=function(t){this.fileList.push(t)},a.prototype.preview=function(){},o.plugin("upload",a),o.ready(function(t){s("[data-am-upload]",t).upload()}),t.exports=a},function(t,e,i){"use strict";var n=i(1),s=i(2),o=function(t,e){this.options=n.extend({},o.DEFAULTS,e),this.options.patterns=n.extend({},o.patterns,this.options.patterns);var i=this.options.locales;!o.validationMessages[i]&&(this.options.locales="zh_CN"),this.$element=n(t),this.init()};o.DEFAULTS={debug:!1,locales:"zh_CN",H5validation:!1,H5inputType:["email","url","number"],patterns:{},patternClassPrefix:"js-pattern-",activeClass:"am-active",inValidClass:"am-field-error",validClass:"am-field-valid",validateOnSubmit:!0,alwaysRevalidate:!1,allFields:":input:not(:submit, :button, :disabled, .am-novalidate)",ignore:":hidden:not([data-am-selected], .am-validate)",customEvents:"validate",keyboardFields:":input:not(:submit, :button, :disabled, .am-novalidate)",keyboardEvents:"focusout, change",activeKeyup:!1,textareaMaxlenthKeyup:!0,pointerFields:'input[type="range"]:not(:disabled, .am-novalidate), input[type="radio"]:not(:disabled, .am-novalidate), input[type="checkbox"]:not(:disabled, .am-novalidate), select:not(:disabled, .am-novalidate), option:not(:disabled, .am-novalidate)',pointerEvents:"click",onValid:function(t){},onInValid:function(t){},markValid:function(t){var e=this.options,i=n(t.field),s=i.closest(".am-form-group");i.addClass(e.validClass).removeClass(e.inValidClass),s.addClass("am-form-success").removeClass("am-form-error"),e.onValid.call(this,t)},markInValid:function(t){var e=this.options,i=n(t.field),s=i.closest(".am-form-group");i.addClass(e.inValidClass+" "+e.activeClass).removeClass(e.validClass),s.addClass("am-form-error").removeClass("am-form-success"),e.onInValid.call(this,t)},validate:function(t){},submit:null},o.VERSION="3.0.0-alpha.beta",o.patterns={email:/^((([a-zA-Z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-zA-Z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/,url:/^(https?|ftp):\/\/(((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/,number:/^-?(?:\d+|\d{1,3}(?:,\d{3})+)?(?:\.\d+)?$/,dateISO:/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/,integer:/^-?\d+$/},o.validationMessages={zh_CN:{valueMissing:"\u8bf7\u586b\u5199\uff08\u9009\u62e9\uff09\u6b64\u5b57\u6bb5",customError:{tooShort:"\u81f3\u5c11\u586b\u5199 %s \u4e2a\u5b57\u7b26",checkedOverflow:"\u81f3\u591a\u9009\u62e9 %s \u9879",checkedUnderflow:"\u81f3\u5c11\u9009\u62e9 %s \u9879"},patternMismatch:"\u8bf7\u6309\u7167\u8981\u6c42\u7684\u683c\u5f0f\u586b\u5199",rangeOverflow:"\u8bf7\u586b\u5199\u5c0f\u4e8e\u7b49\u4e8e %s \u7684\u503c",rangeUnderflow:"\u8bf7\u586b\u5199\u5927\u4e8e\u7b49\u4e8e %s \u7684\u503c",stepMismatch:"",tooLong:"\u81f3\u591a\u586b\u5199 %s \u4e2a\u5b57\u7b26",typeMismatch:"\u8bf7\u6309\u7167\u8981\u6c42\u7684\u7c7b\u578b\u586b\u5199"}},o.ERROR_MAP={tooShort:"minlength",checkedOverflow:"maxchecked",checkedUnderflow:"minchecked",rangeOverflow:"max",rangeUnderflow:"min",tooLong:"maxlength"},o.prototype.init=function(){function t(t){var e=t.toString();return e.substring(1,e.length-1)}function e(t,e,a){var r=e.split(","),l=function(t){i.validate(this)};a&&(l=s.utils.debounce(l,a)),n.each(r,function(e,i){o.on(i+".validator.amui",t,l)})}var i=this,o=this.$element,a=this.options;return(!a.H5validation||!s.support.formValidation)&&(o.attr("novalidate","novalidate"),n.each(a.H5inputType,function(e,i){var n=o.find("input[type="+i+"]");n.attr("pattern")||n.is("[class*="+a.patternClassPrefix+"]")||n.attr("pattern",t(a.patterns[i]))}),n.each(a.patterns,function(e,i){var n=o.find("."+a.patternClassPrefix+e);!n.attr("pattern")&&n.attr("pattern",t(i))}),o.on("submit.validator.amui",function(t){if("function"==typeof a.submit)return a.submit.call(i,t);if(a.validateOnSubmit){var e=i.isFormValid();return"boolean"===n.type(e)?e:!!o.data("amui.checked")||(n.when(e).then(function(){o.data("amui.checked",!0).submit()},function(){o.data("amui.checked",!1).find("."+a.inValidClass).eq(0).focus()}),!1)}}),e(":input",a.customEvents),e(a.keyboardFields,a.keyboardEvents),e(a.pointerFields,a.pointerEvents),a.textareaMaxlenthKeyup&&e("textarea[maxlength]","keyup",50),void(a.activeKeyup&&e(".am-active","keyup",50)))},o.prototype.isValid=function(t){var e=n(t),i=this.options;return(void 0===e.data("validity")||i.alwaysRevalidate)&&this.validate(t),e.data("validity")&&e.data("validity").valid},o.prototype.validate=function(t){var e=this,i=this.$element,s=this.options,o=n(t),a=o.data("equalTo");a&&o.attr("pattern","^"+i.find(a).val()+"$");var r=o.attr("pattern")||!1,l=new RegExp(r),c=null,h=null,d=o.is("[type=checkbox]")?(h=i.find('input[name="'+t.name+'"]')).filter(":checked").length:o.is("[type=radio]")?(c=this.$element.find('input[name="'+t.name+'"]')).filter(":checked").length>0:o.val();o=h&&h.length?h.first():o;var u=void 0!==o.attr("required")&&"false"!==o.attr("required"),p=parseInt(o.attr("maxlength"),10),m=parseInt(o.attr("minlength"),10),f=Number(o.attr("min")),v=Number(o.attr("max")),g=this.createValidity({field:o[0],valid:!0});if(s.debug&&window.console&&(console.log("Validate: value -> ["+d+", regex -> ["+l+"], required -> "+u),console.log("Regex test: "+l.test(d)+", Pattern: "+r)),!isNaN(p)&&d.length>p&&(g.valid=!1,g.tooLong=!0),!isNaN(m)&&d.lengthv&&(g.valid=!1,g.rangeOverflow=!0),u&&!d)g.valid=!1,g.valueMissing=!0;else if((h||o.is('select[multiple="multiple"]'))&&d){d=h?d:d.length;var y=parseInt(o.attr("minchecked"),10),w=parseInt(o.attr("maxchecked"),10);!isNaN(y)&&dw&&(g.valid=!1,g.customError="checkedOverflow")}else r&&!l.test(d)&&d&&(g.valid=!1,g.patternMismatch=!0);var b,F=function(t){this.markField(t);var i=n.Event("validated.field.validator.amui");i.validity=t,o.trigger(i).data("validity",t);var s=c||h;return s&&s.not(o).data("validity",t).each(function(){t.field=this,e.markField(t)}),t};if("function"==typeof s.validate&&(b=s.validate.call(this,g)),b){var $=new n.Deferred;return o.data("amui.dfdValidity",$.promise()),n.when(b).always(function(t){$[t.valid?"resolve":"reject"](t),F.call(e,t)})}F.call(this,g)},o.prototype.markField=function(t){var e=this.options,i="mark"+(t.valid?"":"In")+"Valid";e[i]&&e[i].call(this,t)},o.prototype.validateForm=function(){var t=this,e=this.$element,i=this.options,s=e.find(i.allFields).not(i.ignore),o=[],a=!0,r=[],l=n([]),c=[],h=!1;e.trigger("validate.form.validator.amui");var d=s.filter(function(t){var e;if("INPUT"===this.tagName&&"radio"===this.type){if(e=this.name,o[e]===!0)return!1;o[e]=!0}return!0});d.each(function(){var i=n(this),s=t.isValid(this),o=i.data("validity");a=!!s&&a,r.push(o),s||(l=l.add(n(this),e));var d=i.data("amui.dfdValidity");if(d)c.push(d),h=!0;else{var u=new n.Deferred;c.push(u.promise()),u[s?"resolve":"reject"](o)}});var u={valid:a,$invalidFields:l,validity:r,promises:c,async:h};return e.trigger("validated.form.validator.amui",u),u},o.prototype.isFormValid=function(){var t=this,e=this.validateForm(),i=function(e){t.$element.trigger(e+".validator.amui")};if(e.async){var s=new n.Deferred;return n.when.apply(null,e.promises).then(function(){s.resolve(),i("valid")},function(){s.reject(),i("invalid")}),s.promise()}if(!e.valid){var o=e.$invalidFields.first();return o.is("[data-am-selected]")&&(o=o.next(".am-selected").find(".am-selected-btn")),o.focus(),i("invalid"),!1}return i("valid"),!0},o.prototype.createValidity=function(t){return n.extend({customError:t.customError||!1,patternMismatch:t.patternMismatch||!1,rangeOverflow:t.rangeOverflow||!1,rangeUnderflow:t.rangeUnderflow||!1,stepMismatch:t.stepMismatch||!1,tooLong:t.tooLong||!1,typeMismatch:t.typeMismatch||!1,valid:t.valid||!0,valueMissing:t.valueMissing||!1},t)},o.prototype.getValidationMessage=function(t){var e,i,s=o.validationMessages[this.options.locales],a="%s",r=n(t.field);return(r.is('[type="checkbox"]')||r.is('[type="radio"]'))&&(r=this.$element.find("[name="+r.attr("name")+"]").first()),n.each(t,function(t,i){return"field"===t||"valid"===t?t:"customError"===t&&i?(e=i,s=s.customError,!1):i===!0?(e=t,!1):void 0}),i=s[e]||void 0,i&&o.ERROR_MAP[e]&&(i=i.replace(a,r.attr(o.ERROR_MAP[e])||"\u89c4\u5b9a\u7684")),i},o.prototype.removeMark=function(){this.$element.find(".am-form-success, .am-form-error, ."+this.options.inValidClass+", ."+this.options.validClass).removeClass(["am-form-success","am-form-error",this.options.inValidClass,this.options.validClass].join(" "))},o.prototype.destroy=function(){this.removeMark(),this.$element.removeData("amui.validator amui.checked").off(".validator.amui").find(this.options.allFields).removeData("validity amui.dfdValidity")},s.plugin("validator",o),s.ready(function(t){n("[data-am-validator]",t).validator()}),t.exports=o},function(t,e,i){"use strict";var n=i(2),s={get:function(t){var e,i=encodeURIComponent(t)+"=",n=document.cookie.indexOf(i),s=null;return n>-1&&(e=document.cookie.indexOf(";",n),e==-1&&(e=document.cookie.length),s=decodeURIComponent(document.cookie.substring(n+i.length,e))),s},set:function(t,e,i,n,s,o){var a=encodeURIComponent(t)+"="+encodeURIComponent(e);i instanceof Date&&(a+="; expires="+i.toUTCString()),n&&(a+="; path="+n),s&&(a+="; domain="+s),o&&(a+="; secure"),document.cookie=a},unset:function(t,e,i,n){this.set(t,"",new Date(0),e,i,n)}};n.utils=n.utils||{},t.exports=n.utils.cookie=s},function(t,e,i){"use strict";var n=i(2),s=function(){var t="undefined"!=typeof Element&&"ALLOW_KEYBOARD_INPUT"in Element,e=function(){for(var t,e,i=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],n=0,s=i.length,o={};n