进行了一些小修复
This commit is contained in:
1 parent
dc14c29878
commit
065a5bc99c
16 files changed
+3655
-2508
No files matched your search
@@ -1,3 +1,123 @@
|
||||
/* source: assets/js/passive-events.js */
|
||||
/**
|
||||
* Passive event listener polyfill
|
||||
*
|
||||
* Patches addEventListener so scroll-blocking events (touchstart, touchmove,
|
||||
* wheel, mousewheel) default to { passive: true } unless explicitly set to
|
||||
* false. Eliminates Chrome Violation warnings from third-party libraries.
|
||||
*/
|
||||
(function () {
|
||||
'use strict';
|
||||
var opts = Object.defineProperty({}, 'passive', {
|
||||
get: function () { window.__passiveSupported = true; }
|
||||
});
|
||||
window.addEventListener('test', null, opts);
|
||||
if (!window.__passiveSupported) return;
|
||||
|
||||
var orig = EventTarget.prototype.addEventListener;
|
||||
var passiveEvents = { touchstart: 1, touchmove: 1, wheel: 1, mousewheel: 1 };
|
||||
|
||||
EventTarget.prototype.addEventListener = function (type, listener, options) {
|
||||
if (passiveEvents[type] && typeof options !== 'object') {
|
||||
options = { passive: true, capture: options };
|
||||
}
|
||||
orig.call(this, type, listener, options);
|
||||
};
|
||||
})();
|
||||
;
|
||||
|
||||
/* source: assets/js/runtime/libs/bootstrap.min.js */
|
||||
if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");!function(t){"use strict";var e=t.fn.jquery.split(" ")[0].split(".");if(e[0]<2&&e[1]<9||1==e[0]&&9==e[1]&&e[2]<1||e[0]>3)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4")}(jQuery),function(t){"use strict";function e(){var t=document.createElement("bootstrap"),e={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var i in e)if(void 0!==t.style[i])return{end:e[i]};return!1}t.fn.emulateTransitionEnd=function(e){var i=!1,o=this;t(this).one("bsTransitionEnd",function(){i=!0});var n=function(){i||t(o).trigger(t.support.transition.end)};return setTimeout(n,e),this},t(function(){t.support.transition=e(),t.support.transition&&(t.event.special.bsTransitionEnd={bindType:t.support.transition.end,delegateType:t.support.transition.end,handle:function(e){if(t(e.target).is(this))return e.handleObj.handler.apply(this,arguments)}})})}(jQuery),function(t){"use strict";function e(e){return this.each(function(){var i=t(this),n=i.data("bs.alert");n||i.data("bs.alert",n=new o(this)),"string"==typeof e&&n[e].call(i)})}var i='[data-dismiss="alert"]',o=function(e){t(e).on("click",i,this.close)};o.VERSION="3.4.1",o.TRANSITION_DURATION=150,o.prototype.close=function(e){function i(){a.detach().trigger("closed.bs.alert").remove()}var n=t(this),s=n.attr("data-target");s||(s=n.attr("href"),s=s&&s.replace(/.*(?=#[^\s]*$)/,"")),s="#"===s?[]:s;var a=t(document).find(s);e&&e.preventDefault(),a.length||(a=n.closest(".alert")),a.trigger(e=t.Event("close.bs.alert")),e.isDefaultPrevented()||(a.removeClass("in"),t.support.transition&&a.hasClass("fade")?a.one("bsTransitionEnd",i).emulateTransitionEnd(o.TRANSITION_DURATION):i())};var n=t.fn.alert;t.fn.alert=e,t.fn.alert.Constructor=o,t.fn.alert.noConflict=function(){return t.fn.alert=n,this},t(document).on("click.bs.alert.data-api",i,o.prototype.close)}(jQuery),function(t){"use strict";function e(e){return this.each(function(){var o=t(this),n=o.data("bs.button"),s="object"==typeof e&&e;n||o.data("bs.button",n=new i(this,s)),"toggle"==e?n.toggle():e&&n.setState(e)})}var i=function(e,o){this.$element=t(e),this.options=t.extend({},i.DEFAULTS,o),this.isLoading=!1};i.VERSION="3.4.1",i.DEFAULTS={loadingText:"loading..."},i.prototype.setState=function(e){var i="disabled",o=this.$element,n=o.is("input")?"val":"html",s=o.data();e+="Text",null==s.resetText&&o.data("resetText",o[n]()),setTimeout(t.proxy(function(){o[n](null==s[e]?this.options[e]:s[e]),"loadingText"==e?(this.isLoading=!0,o.addClass(i).attr(i,i).prop(i,!0)):this.isLoading&&(this.isLoading=!1,o.removeClass(i).removeAttr(i).prop(i,!1))},this),0)},i.prototype.toggle=function(){var t=!0,e=this.$element.closest('[data-toggle="buttons"]');if(e.length){var i=this.$element.find("input");"radio"==i.prop("type")?(i.prop("checked")&&(t=!1),e.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==i.prop("type")&&(i.prop("checked")!==this.$element.hasClass("active")&&(t=!1),this.$element.toggleClass("active")),i.prop("checked",this.$element.hasClass("active")),t&&i.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var o=t.fn.button;t.fn.button=e,t.fn.button.Constructor=i,t.fn.button.noConflict=function(){return t.fn.button=o,this},t(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(i){var o=t(i.target).closest(".btn");e.call(o,"toggle"),t(i.target).is('input[type="radio"], input[type="checkbox"]')||(i.preventDefault(),o.is("input,button")?o.trigger("focus"):o.find("input:visible,button:visible").first().trigger("focus"))}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(e){t(e.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(e.type))})}(jQuery),function(t){"use strict";function e(e){return this.each(function(){var o=t(this),n=o.data("bs.carousel"),s=t.extend({},i.DEFAULTS,o.data(),"object"==typeof e&&e),a="string"==typeof e?e:s.slide;n||o.data("bs.carousel",n=new i(this,s)),"number"==typeof e?n.to(e):a?n[a]():s.interval&&n.pause().cycle()})}var i=function(e,i){this.$element=t(e),this.$indicators=this.$element.find(".carousel-indicators"),this.options=i,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",t.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",t.proxy(this.pause,this)).on("mouseleave.bs.carousel",t.proxy(this.cycle,this))};i.VERSION="3.4.1",i.TRANSITION_DURATION=600,i.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},i.prototype.keydown=function(t){if(!/input|textarea/i.test(t.target.tagName)){switch(t.which){case 37:this.prev();Line truncated
|
||||
return i.DEFAULTS},i.prototype.setContent=function(){var t=this.tip(),e=this.getTitle(),i=this.getContent();if(this.options.html){var o=typeof i;this.options.sanitize&&(e=this.sanitizeHtml(e),"string"===o&&(i=this.sanitizeHtml(i))),t.find(".popover-title").html(e),t.find(".popover-content").children().detach().end()["string"===o?"html":"append"](i)}else t.find(".popover-title").text(e),t.find(".popover-content").children().detach().end().text(i);t.removeClass("fade top bottom left right in"),t.find(".popover-title").html()||t.find(".popover-title").hide()},i.prototype.hasContent=function(){return this.getTitle()||this.getContent()},i.prototype.getContent=function(){var t=this.$element,e=this.options;return t.attr("data-content")||("function"==typeof e.content?e.content.call(t[0]):e.content)},i.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var o=t.fn.popover;t.fn.popover=e,t.fn.popover.Constructor=i,t.fn.popover.noConflict=function(){return t.fn.popover=o,this}}(jQuery),function(t){"use strict";function e(i,o){this.$body=t(document.body),this.$scrollElement=t(i).is(document.body)?t(window):t(i),this.options=t.extend({},e.DEFAULTS,o),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",t.proxy(this.process,this)),this.refresh(),this.process()}function i(i){return this.each(function(){var o=t(this),n=o.data("bs.scrollspy"),s="object"==typeof i&&i;n||o.data("bs.scrollspy",n=new e(this,s)),"string"==typeof i&&n[i]()})}e.VERSION="3.4.1",e.DEFAULTS={offset:10},e.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},e.prototype.refresh=function(){var e=this,i="offset",o=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),t.isWindow(this.$scrollElement[0])||(i="position",o=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var e=t(this),n=e.data("target")||e.attr("href"),s=/^#./.test(n)&&t(n);return s&&s.length&&s.is(":visible")&&[[s[i]().top+o,n]]||null}).sort(function(t,e){return t[0]-e[0]}).each(function(){e.offsets.push(this[0]),e.targets.push(this[1])})},e.prototype.process=function(){var t,e=this.$scrollElement.scrollTop()+this.options.offset,i=this.getScrollHeight(),o=this.options.offset+i-this.$scrollElement.height(),n=this.offsets,s=this.targets,a=this.activeTarget;if(this.scrollHeight!=i&&this.refresh(),e>=o)return a!=(t=s[s.length-1])&&this.activate(t);if(a&&e<n[0])return this.activeTarget=null,this.clear();for(t=n.length;t--;)a!=s[t]&&e>=n[t]&&(void 0===n[t+1]||e<n[t+1])&&this.activate(s[t])},e.prototype.activate=function(e){this.activeTarget=e,this.clear();var i=this.selector+'[data-target="'+e+'"],'+this.selector+'[href="'+e+'"]',o=t(i).parents("li").addClass("active");o.parent(".dropdown-menu").length&&(o=o.closest("li.dropdown").addClass("active")),o.trigger("activate.bs.scrollspy")},e.prototype.clear=function(){t(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var o=t.fn.scrollspy;t.fn.scrollspy=i,t.fn.scrollspy.Constructor=e,t.fn.scrollspy.noConflict=function(){return t.fn.scrollspy=o,this},t(window).on("load.bs.scrollspy.data-api",function(){t('[data-spy="scroll"]').each(function(){var e=t(this);i.call(e,e.data())})})}(jQuery),function(t){"use strict";function e(e){return this.each(function(){var o=t(this),n=o.data("bs.tab");n||o.data("bs.tab",n=new i(this)),"string"==typeof e&&n[e]()})}var i=function(e){this.element=t(e)};i.VERSION="3.4.1",i.TRANSITION_DURATION=150,i.prototype.show=function(){var e=this.element,i=e.closest("ul:not(.dropdown-menu)"),o=e.data("target");if(o||(o=e.attr("href"),o=o&&o.replace(/.*(?=#[^\s]*$)/,"")),!e.parent("li").hasClass("active")){var n=i.find(".active:last a"),s=t.Event("hide.bs.tab",{relatedTarget:e[0]}),a=t.Event("show.bs.tab",{relatedTarget:n[0]});if(n.trigger(s),e.trigger(a),!a.isDefaultPrevented()&&!s.isDefaultPrevented()){var r=t(document).find(o);this.activate(e.closest("li"),i),this.activate(r,r.parent(),function(){n.trigger({type:"hidden.bs.tab",relatedTarget:e[0]}),e.trigger({type:"shown.bs.tab",relatedTarget:n[0]})})}}},i.prototype.activate=function(e,o,n){function s(){a.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),e.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),r?(e[0].offsetWidth,e.addClass("in")):e.removeClass("fade"),e.parent(".dropdown-menu").length&&e.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),n&&n()}var a=o.find("> .active"),r=n&&t.support.transition&&(a.length&&a.hasClass("fade")||!!o.find("> .fade").length);a.length&&r?a.one("bsTransitionEnd",s).emulateTransitionEnd(i.TRANSITION_DURATION):s(),a.removeClass("in")};var o=t.fn.taLine truncated
|
||||
;
|
||||
|
||||
/* source: assets/js/runtime/loader.js */
|
||||
/**
|
||||
* Legacy module loader (RequireJS 2.1.14 derivative, tbquire/tbfine).
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
/*
|
||||
RequireJS 2.1.14 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
|
||||
Available via the MIT or new BSD license.
|
||||
see: http://github.com/jrburke/tbquirejs for details
|
||||
*/
|
||||
var tbquirejs,tbquire,tbfine;
|
||||
(function(ba){function G(b){return"[object Function]"===K.call(b)}function H(b){return"[object Array]"===K.call(b)}function v(b,c){if(b){var d;for(d=0;d<b.length&&(!b[d]||!c(b[d],d,b));d+=1);}}function T(b,c){if(b){var d;for(d=b.length-1;-1<d&&(!b[d]||!c(b[d],d,b));d-=1);}}function t(b,c){return fa.call(b,c)}function m(b,c){return t(b,c)&&b[c]}function B(b,c){for(var d in b)if(t(b,d)&&c(b[d],d))break}function U(b,c,d,e){c&&B(c,function(c,g){if(d||!t(b,g))e&&"object"===typeof c&&c&&!H(c)&&!G(c)&&!(c instanceof
|
||||
RegExp)?(b[g]||(b[g]={}),U(b[g],c,d,e)):b[g]=c});return b}function u(b,c){return function(){return c.apply(b,arguments)}}function ca(b){throw b;}function da(b){if(!b)return b;var c=ba;v(b.split("."),function(b){c=c[b]});return c}function C(b,c,d,e){c=Error(c+"\ntbquire动态加载提醒#"+b);c.tbquireType=b;c.tbquireModules=e;d&&(c.originalError=d);return c}function ga(b){function c(a,k,b){var f,l,c,d,e,g,i,p,k=k&&k.split("/"),h=j.map,n=h&&h["*"];if(a){a=a.split("/");l=a.length-1;j.nodeIdCompat&&
|
||||
Q.test(a[l])&&(a[l]=a[l].replace(Q,""));"."===a[0].charAt(0)&&k&&(l=k.slice(0,k.length-1),a=l.concat(a));l=a;for(c=0;c<l.length;c++)if(d=l[c],"."===d)l.splice(c,1),c-=1;else if(".."===d&&!(0===c||1==c&&".."===l[2]||".."===l[c-1])&&0<c)l.splice(c-1,2),c-=2;a=a.join("/")}if(b&&h&&(k||n)){l=a.split("/");c=l.length;a:for(;0<c;c-=1){e=l.slice(0,c).join("/");if(k)for(d=k.length;0<d;d-=1)if(b=m(h,k.slice(0,d).join("/")))if(b=m(b,e)){f=b;g=c;break a}!i&&(n&&m(n,e))&&(i=m(n,e),p=c)}!f&&i&&(f=i,g=p);f&&(l.splice(0,
|
||||
g,f),a=l.join("/"))}return(f=m(j.pkgs,a))?f:a}function d(a){z&&v(document.getElementsByTagName("script"),function(k){if(k.getAttribute("data-tbquiremodule")===a&&k.getAttribute("data-tbquirecontext")===i.contextName)return k.parentNode.removeChild(k),!0})}function e(a){var k=m(j.paths,a);if(k&&H(k)&&1<k.length)return k.shift(),i.tbquire.undef(a),i.makeRequire(null,{skipMap:!0})([a]),!0}function n(a){var k,c=a?a.indexOf("!"):-1;-1<c&&(k=a.substring(0,c),a=a.substring(c+1,a.length));return[k,a]}function p(a,
|
||||
k,b,f){var l,d,e=null,g=k?k.name:null,j=a,p=!0,h="";a||(p=!1,a="_@r"+(K+=1));a=n(a);e=a[0];a=a[1];e&&(e=c(e,g,f),d=m(r,e));a&&(e?h=d&&d.normalize?d.normalize(a,function(a){return c(a,g,f)}):-1===a.indexOf("!")?c(a,g,f):a:(h=c(a,g,f),a=n(h),e=a[0],h=a[1],b=!0,l=i.nameToUrl(h)));b=e&&!d&&!b?"_unnormalized"+(O+=1):"";return{prefix:e,name:h,parentMap:k,unnormalized:!!b,url:l,originalName:j,isDefine:p,id:(e?e+"!"+h:h)+b}}function s(a){var k=a.id,b=m(h,k);b||(b=h[k]=new i.Module(a));return b}function q(a,
|
||||
k,b){var f=a.id,c=m(h,f);if(t(r,f)&&(!c||c.defineEmitComplete))"defined"===k&&b(r[f]);else if(c=s(a),c.error&&"error"===k)b(c.error);else c.on(k,b)}function w(a,b){var c=a.tbquireModules,f=!1;if(b)b(a);else if(v(c,function(b){if(b=m(h,b))b.error=a,b.events.error&&(f=!0,b.emit("error",a))}),!f)g.onError(a)}function x(){R.length&&(ha.apply(A,[A.length,0].concat(R)),R=[])}function y(a){delete h[a];delete V[a]}function F(a,b,c){var f=a.map.id;a.error?a.emit("error",a.error):(b[f]=!0,v(a.depMaps,function(f,
|
||||
d){var e=f.id,g=m(h,e);g&&(!a.depMatched[d]&&!c[e])&&(m(b,e)?(a.defineDep(d,r[e]),a.check()):F(g,b,c))}),c[f]=!0)}function D(){var a,b,c=(a=1E3*j.waitSeconds)&&i.startTime+a<(new Date).getTime(),f=[],l=[],g=!1,h=!0;if(!W){W=!0;B(V,function(a){var i=a.map,j=i.id;if(a.enabled&&(i.isDefine||l.push(a),!a.error))if(!a.inited&&c)e(j)?g=b=!0:(f.push(j),d(j));else if(!a.inited&&(a.fetched&&i.isDefine)&&(g=!0,!i.prefix))return h=!1});if(c&&f.length)return a=C("超时","动态加载超时: "+f,null,
|
||||
f),a.contextName=i.contextName,w(a);h&&v(l,function(a){F(a,{},{})});if((!c||b)&&g)if((z||ea)&&!X)X=setTimeout(function(){X=0;D()},50);W=!1}}function E(a){t(r,a[0])||s(p(a[0],null,!0)).init(a[1],a[2])}function I(a){var a=a.currentTarget||a.srcElement,b=i.onScriptLoad;a.detachEvent&&!Y?a.detachEvent("onreadystatechange",b):a.removeEventListener("load",b,!1);b=i.onScriptError;(!a.detachEvent||Y)&&a.removeEventListener("error",b,!1);return{node:a,id:a&&a.getAttribute("data-tbquiremodule")}}function J(){var a;
|
||||
for(x();A.length;){a=A.shift();if(null===a[0])return w(C("mismatch","Mismatched anonymous define() module: "+a[a.length-1]));E(a)}}var W,Z,i,L,X,j={waitSeconds:7,baseUrl:"./",paths:{},bundles:{},pkgs:{},shim:{},config:{}},h={},V={},$={},A=[],r={},S={},aa={},K=1,O=1;L={tbquire:function(a){return a.tbquire?a.tbquire:a.tbquire=i.makeRequire(a.map)},exports:function(a){a.usingExports=!0;if(a.map.isDefine)return a.exports?r[a.map.id]=a.exports:a.exports=r[a.map.id]={}},module:function(a){return a.module?
|
||||
a.module:a.module={id:a.map.id,uri:a.map.url,config:function(){return m(j.config,a.map.id)||{}},exports:a.exports||(a.exports={})}}};Z=function(a){this.events=m($,a.id)||{};this.map=a;this.shim=m(j.shim,a.id);this.depExports=[];this.depMaps=[];this.depMatched=[];this.pluginMaps={};this.depCount=0};Z.prototype={init:function(a,b,c,f){f=f||{};if(!this.inited){this.factory=b;if(c)this.on("error",c);else this.events.error&&(c=u(this,function(a){this.emit("error",a)}));this.depMaps=a&&a.slice(0);this.errback=
|
||||
c;this.inited=!0;this.ignore=f.ignore;f.enabled||this.enabled?this.enable():this.check()}},defineDep:function(a,b){this.depMatched[a]||(this.depMatched[a]=!0,this.depCount-=1,this.depExports[a]=b)},fetch:function(){if(!this.fetched){this.fetched=!0;i.startTime=(new Date).getTime();var a=this.map;if(this.shim)i.makeRequire(this.map,{enableBuildCallback:!0})(this.shim.deps||[],u(this,function(){return a.prefix?this.callPlugin():this.load()}));else return a.prefix?this.callPlugin():this.load()}},load:function(){var a=
|
||||
this.map.url;S[a]||(S[a]=!0,i.load(this.map.id,a))},check:function(){if(this.enabled&&!this.enabling){var a,b,c=this.map.id;b=this.depExports;var f=this.exports,l=this.factory;if(this.inited)if(this.error)this.emit("error",this.error);else{if(!this.defining){this.defining=!0;if(1>this.depCount&&!this.defined){if(G(l)){if(this.events.error&&this.map.isDefine||g.onError!==ca)try{f=i.execCb(c,l,b,f)}catch(d){a=d}else f=i.execCb(c,l,b,f);this.map.isDefine&&void 0===f&&((b=this.module)?f=b.exports:this.usingExports&&
|
||||
(f=this.exports));if(a)return a.tbquireMap=this.map,a.tbquireModules=this.map.isDefine?[this.map.id]:null,a.tbquireType=this.map.isDefine?"tbfine":"tbquire",w(this.error=a)}else f=l;this.exports=f;if(this.map.isDefine&&!this.ignore&&(r[c]=f,g.onResourceLoad))g.onResourceLoad(i,this.map,this.depMaps);y(c);this.defined=!0}this.defining=!1;this.defined&&!this.defineEmitted&&(this.defineEmitted=!0,this.emit("defined",this.exports),this.defineEmitComplete=!0)}}else this.fetch()}},callPlugin:function(){var a=
|
||||
this.map,b=a.id,d=p(a.prefix);this.depMaps.push(d);q(d,"defined",u(this,function(f){var l,d;d=m(aa,this.map.id);var e=this.map.name,P=this.map.parentMap?this.map.parentMap.name:null,n=i.makeRequire(a.parentMap,{enableBuildCallback:!0});if(this.map.unnormalized){if(f.normalize&&(e=f.normalize(e,function(a){return c(a,P,!0)})||""),f=p(a.prefix+"!"+e,this.map.parentMap),q(f,"defined",u(this,function(a){this.init([],function(){return a},null,{enabled:!0,ignore:!0})})),d=m(h,f.id)){this.depMaps.push(f);
|
||||
if(this.events.error)d.on("error",u(this,function(a){this.emit("error",a)}));d.enable()}}else d?(this.map.url=i.nameToUrl(d),this.load()):(l=u(this,function(a){this.init([],function(){return a},null,{enabled:!0})}),l.error=u(this,function(a){this.inited=!0;this.error=a;a.tbquireModules=[b];B(h,function(a){0===a.map.id.indexOf(b+"_unnormalized")&&y(a.map.id)});w(a)}),l.fromText=u(this,function(f,c){var d=a.name,e=p(d),P=M;c&&(f=c);P&&(M=!1);s(e);t(j.config,b)&&(j.config[d]=j.config[b]);try{g.exec(f)}catch(h){return w(C("fromtexteval",
|
||||
"fromText eval for "+b+" failed: "+h,h,[b]))}P&&(M=!0);this.depMaps.push(e);i.completeLoad(d);n([d],l)}),f.load(a.name,n,l,j))}));i.enable(d,this);this.pluginMaps[d.id]=d},enable:function(){V[this.map.id]=this;this.enabling=this.enabled=!0;v(this.depMaps,u(this,function(a,b){var c,f;if("string"===typeof a){a=p(a,this.map.isDefine?this.map:this.map.parentMap,!1,!this.skipMap);this.depMaps[b]=a;if(c=m(L,a.id)){this.depExports[b]=c(this);return}this.depCount+=1;q(a,"defined",u(this,function(a){this.defineDep(b,
|
||||
a);this.check()}));this.errback&&q(a,"error",u(this,this.errback))}c=a.id;f=h[c];!t(L,c)&&(f&&!f.enabled)&&i.enable(a,this)}));B(this.pluginMaps,u(this,function(a){var b=m(h,a.id);b&&!b.enabled&&i.enable(a,this)}));this.enabling=!1;this.check()},on:function(a,b){var c=this.events[a];c||(c=this.events[a]=[]);c.push(b)},emit:function(a,b){v(this.events[a],function(a){a(b)});"error"===a&&delete this.events[a]}};i={config:j,contextName:b,registry:h,defined:r,urlFetched:S,defQueue:A,Module:Z,makeModuleMap:p,
|
||||
nextTick:g.nextTick,onError:w,configure:function(a){a.baseUrl&&"/"!==a.baseUrl.charAt(a.baseUrl.length-1)&&(a.baseUrl+="/");var b=j.shim,c={paths:!0,bundles:!0,config:!0,map:!0};B(a,function(a,b){c[b]?(j[b]||(j[b]={}),U(j[b],a,!0,!0)):j[b]=a});a.bundles&&B(a.bundles,function(a,b){v(a,function(a){a!==b&&(aa[a]=b)})});a.shim&&(B(a.shim,function(a,c){H(a)&&(a={deps:a});if((a.exports||a.init)&&!a.exportsFn)a.exportsFn=i.makeShimExports(a);b[c]=a}),j.shim=b);a.packages&&v(a.packages,function(a){var b,
|
||||
a="string"===typeof a?{name:a}:a;b=a.name;a.location&&(j.paths[b]=a.location);j.pkgs[b]=a.name+"/"+(a.main||"main").replace(ia,"").replace(Q,"")});B(h,function(a,b){!a.inited&&!a.map.unnormalized&&(a.map=p(b))});if(a.deps||a.callback)i.tbquire(a.deps||[],a.callback)},makeShimExports:function(a){return function(){var b;a.init&&(b=a.init.apply(ba,arguments));return b||a.exports&&da(a.exports)}},makeRequire:function(a,e){function j(c,d,m){var n,q;e.enableBuildCallback&&(d&&G(d))&&(d.__tbquireJsBuild=
|
||||
!0);if("string"===typeof c){if(G(d))return w(C("tbquireargs","Invalid tbquire call"),m);if(a&&t(L,c))return L[c](h[a.id]);if(g.get)return g.get(i,c,a,j);n=p(c,a,!1,!0);n=n.id;return!t(r,n)?w(C("notloaded",'Module name "'+n+'" has not been loaded yet for context: '+b+(a?"":". Use tbquire([])"))):r[n]}J();i.nextTick(function(){J();q=s(p(null,a));q.skipMap=e.skipMap;q.init(c,d,m,{enabled:!0});D()});return j}e=e||{};U(j,{isBrowser:z,toUrl:function(b){var d,e=b.lastIndexOf("."),k=b.split("/")[0];if(-1!==
|
||||
e&&(!("."===k||".."===k)||1<e))d=b.substring(e,b.length),b=b.substring(0,e);return i.nameToUrl(c(b,a&&a.id,!0),d,!0)},defined:function(b){return t(r,p(b,a,!1,!0).id)},specified:function(b){b=p(b,a,!1,!0).id;return t(r,b)||t(h,b)}});a||(j.undef=function(b){x();var c=p(b,a,!0),e=m(h,b);d(b);delete r[b];delete S[c.url];delete $[b];T(A,function(a,c){a[0]===b&&A.splice(c,1)});e&&(e.events.defined&&($[b]=e.events),y(b))});return j},enable:function(a){m(h,a.id)&&s(a).enable()},completeLoad:function(a){var b,
|
||||
c,d=m(j.shim,a)||{},g=d.exports;for(x();A.length;){c=A.shift();if(null===c[0]){c[0]=a;if(b)break;b=!0}else c[0]===a&&(b=!0);E(c)}c=m(h,a);if(!b&&!t(r,a)&&c&&!c.inited){if(j.enforceDefine&&(!g||!da(g)))return e(a)?void 0:w(C("nodefine","No define call for "+a,null,[a]));E([a,d.deps||[],d.exportsFn])}D()},nameToUrl:function(a,b,c){var d,e,h;(d=m(j.pkgs,a))&&(a=d);if(d=m(aa,a))return i.nameToUrl(d,b,c);if(g.jsExtRegExp.test(a))d=a+(b||"");else{d=j.paths;a=a.split("/");for(e=a.length;0<e;e-=1)if(h=a.slice(0,
|
||||
e).join("/"),h=m(d,h)){H(h)&&(h=h[0]);a.splice(0,e,h);break}d=a.join("/");d+=b||(/^data\:|\?/.test(d)||c?"":".js");d=("/"===d.charAt(0)||d.match(/^[\w\+\.\-]+:/)?"":j.baseUrl)+d}return j.urlArgs?d+((-1===d.indexOf("?")?"?":"&")+j.urlArgs):d},load:function(a,b){g.load(i,a,b)},execCb:function(a,b,c,d){return b.apply(d,c)},onScriptLoad:function(a){if("load"===a.type||ja.test((a.currentTarget||a.srcElement).readyState))N=null,a=I(a),i.completeLoad(a.id)},onScriptError:function(a){var b=I(a);if(!e(b.id))return w(C("js 加载失败",
|
||||
"加载失败: "+b.id,a,[b.id]))}};i.tbquire=i.makeRequire();return i}var g,x,y,D,I,E,N,J,s,O,ka=/(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/mg,la=/[^.]\s*tbquire\s*\(\s*["']([^'"\s]+)["']\s*\)/g,Q=/\.js$/,ia=/^\.\//;x=Object.prototype;var K=x.toString,fa=x.hasOwnProperty,ha=Array.prototype.splice,z=!!("undefined"!==typeof window&&"undefined"!==typeof navigator&&window.document),ea=!z&&"undefined"!==typeof importScripts,ja=z&&"PLAYSTATION 3"===navigator.platform?/^complete$/:/^(complete|loaded)$/,
|
||||
Y="undefined"!==typeof opera&&"[object Opera]"===opera.toString(),F={},q={},R=[],M=!1;if("undefined"===typeof define){if("undefined"!==typeof tbquirejs){if(G(tbquirejs))return;q=tbquirejs;tbquirejs=void 0}"undefined"!==typeof tbquire&&!G(tbquire)&&(q=tbquire,tbquire=void 0);g=tbquirejs=function(b,c,d,e){var n,p="_";!H(b)&&"string"!==typeof b&&(n=b,H(c)?(b=c,c=d,d=e):b=[]);n&&n.context&&(p=n.context);(e=m(F,p))||(e=F[p]=g.s.newContext(p));n&&e.configure(n);return e.tbquire(b,c,d)};g.config=function(b){return g(b)};
|
||||
g.nextTick="undefined"!==typeof setTimeout?function(b){setTimeout(b,4)}:function(b){b()};tbquire||(tbquire=g);g.version="2.1.14";g.jsExtRegExp=/^\/|:|\?|\.js$/;g.isBrowser=z;x=g.s={contexts:F,newContext:ga};g({});v(["toUrl","undef","defined","specified"],function(b){g[b]=function(){var c=F._;return c.tbquire[b].apply(c,arguments)}});if(z&&(y=x.head=document.getElementsByTagName("head")[0],D=document.getElementsByTagName("base")[0]))y=x.head=D.parentNode;g.onError=ca;g.createNode=function(b){var c=
|
||||
b.xhtml?document.createElementNS("http://www.w3.org/1999/xhtml","html:script"):document.createElement("script");/*c.type=b.scriptType||"text/javascript";c.charset="utf-8";*/c.async=!0;return c};g.load=function(b,c,d){var e=b&&b.config||{};if(z)return e=g.createNode(e,c,d),e.setAttribute("data-tbquirecontext",b.contextName),e.setAttribute("data-tbquiremodule",c),e.attachEvent&&!(e.attachEvent.toString&&0>e.attachEvent.toString().indexOf("[native code"))&&!Y?(M=!0,e.attachEvent("onreadystatechange",b.onScriptLoad)):
|
||||
(e.addEventListener("load",b.onScriptLoad,!1),e.addEventListener("error",b.onScriptError,!1)),e.src=d,J=e,D?y.insertBefore(e,D):y.appendChild(e),J=null,e;if(ea)try{importScripts(d),b.completeLoad(c)}catch(m){b.onError(C("importscripts","importScripts failed for "+c+" at "+d,m,[c]))}};z&&!q.skipDataMain&&T(document.getElementsByTagName("script"),function(b){y||(y=b.parentNode);if(I=b.getAttribute("data-main"))return s=I,q.baseUrl||(E=s.split("/"),s=E.pop(),O=E.length?E.join("/")+"/":"./",q.baseUrl=
|
||||
O),s=s.replace(Q,""),g.jsExtRegExp.test(s)&&(s=I),q.deps=q.deps?q.deps.concat(s):[s],!0});tbfine=function(b,c,d){var e,g;"string"!==typeof b&&(d=c,c=b,b=null);H(c)||(d=c,c=null);!c&&G(d)&&(c=[],d.length&&(d.toString().replace(ka,"").replace(la,function(b,d){c.push(d)}),c=(1===d.length?["tbquire"]:["tbquire","exports","module"]).concat(c)));if(M){if(!(e=J))N&&"interactive"===N.readyState||T(document.getElementsByTagName("script"),function(b){if("interactive"===b.readyState)return N=b}),e=N;e&&(b||
|
||||
(b=e.getAttribute("data-tbquiremodule")),g=F[e.getAttribute("data-tbquirecontext")])}(g?g.defQueue:R).push([b,c,d])};tbfine.amd={jQuery:!0};g.exec=function(b){return eval(b)};g(q)}})(this);
|
||||
|
||||
tbquire.config({
|
||||
baseUrl: _win.uri + '/js/runtime',
|
||||
urlArgs: 'ver=' + _win.ver,
|
||||
paths: {
|
||||
'jquery.cookie' : 'libs/jquery.cookie.min',
|
||||
'lazysizes' : 'libs/lazysizes.min',
|
||||
'clipboard' : 'libs/clipboard.min',
|
||||
'swiper' : 'libs/swiper.min',
|
||||
'dplayer' : '../../widgets/third-party/DPlayer.min',
|
||||
'dash' : '../../widgets/third-party/dash.all.min',
|
||||
'hls' : '../../widgets/third-party/hls.min',
|
||||
'flv' : '../../widgets/third-party/flv.min',
|
||||
'grade' : 'libs/grade.min',
|
||||
'qrcode' : 'libs/jquery.qrcode.min',
|
||||
'sortablejs' : 'libs/Sortable.min',
|
||||
'spark-md5' : 'libs/spark-md5.min',
|
||||
'translate' : 'libs/translate.min',
|
||||
'waterfall' : 'waterfall.min',
|
||||
'enlighterjs' : 'enlighter/enlighterjs.min',
|
||||
'imgbox' : 'imgbox.min',
|
||||
'section-navs' : 'section-navs.min',
|
||||
'poster-share' : 'poster-share.min',
|
||||
'slidercaptcha' : 'slidercaptcha.min',
|
||||
'comment' : 'comment.min',
|
||||
'page-template' : 'page-template.min',
|
||||
'page-edit' : 'page-edit.min',
|
||||
'author' : 'author.min',
|
||||
'page-navs' : 'page-navs.min',
|
||||
'input-expand' : 'input-expand.min',
|
||||
'mini-touch' : 'mini-touch.min',
|
||||
'mini-upload' : 'mini-upload.min',
|
||||
'editextend' : 'editextend.min',
|
||||
'petite-vue' : 'libs/petite-vue.iife',
|
||||
'svg-icon' : 'svg-icon',
|
||||
'tcaptcha-sdk' : ['https://turing.captcha.qcloud.com/TJCaptcha'],
|
||||
'captcha' : 'captcha.min',
|
||||
'tilt' : '../../widgets/third-party/vanilla-tilt.min',
|
||||
'weixin-share' : 'weixin-share.min',
|
||||
'weixin-sdk' : ['//res.wx.qq.com/open/js/jweixin-1.6.0','//res2.wx.qq.com/open/js/jweixin-1.6.0'],
|
||||
'shop—main' : _win.uri+'/inc/functions/shop/assets/js/main.min',
|
||||
}
|
||||
})
|
||||
;
|
||||
|
||||
/* source: assets/js/lazy-image-attr.js */
|
||||
/**
|
||||
* Build lazy-image attributes for dynamically rendered AKSRT markup.
|
||||
@@ -5442,3 +5562,106 @@
|
||||
|
||||
})();
|
||||
;
|
||||
|
||||
/* source: assets/js/runtime/main.min.js */
|
||||
jQuery.cookie=function(e,o,t){if(o===void 0){var i=null;if(document.cookie&&document.cookie!="")for(var r=document.cookie.split(";"),n=0;n<r.length;n++){var c=jQuery.trim(r[n]);if(c.substring(0,e.length+1)==e+"="){i=decodeURIComponent(c.substring(e.length+1));break}}return i}t=t||{},o===null&&(o="",t.expires=-1);var a="";if(t.expires&&(typeof t.expires=="number"||t.expires.toUTCString)){var l2;typeof t.expires=="number"?(l2=new Date,l2.setTime(l2.getTime()+24*t.expires*60*60*1e3)):l2=t.expires,a="; expires="+l2.toUTCString()}var u=t.path?"; path="+t.path:"",s=t.domain?"; domain="+t.domain:"",m=t.secure?"; secure":"";document.cookie=[e,"=",encodeURIComponent(o),a,u,s,m].join("")};var lcs={get:function(e){return window.localStorage?localStorage.getItem(e):jQuery.cookie(e)},set:function(e,o){window.localStorage?localStorage[e]=o:jQuery.cookie(e,o)},remove:function(e){window.localStorage?localStorage.removeItem(e):jQuery.cookie(e,"")}};function aksrt__(key){var map=window._win&&window._win.i18n;return map&&Object.prototype.hasOwnProperty.call(map,key)?map[key]:key}function aksrt_is_fatal_error_response(text){return text&&(text.indexOf("Fatal error")>-1||text.indexOf("致命错误")>-1)}function aksrt_sprintf(key){var args=Array.prototype.slice.call(arguments,1),str=aksrt__(key),autoIndex=0;return str.replace(/%(\d+\$)?s/g,function(match,num){var idx=num?parseInt(num,10)-1:autoIndex++;return args[idx]!==void 0&&args[idx]!==null?args[idx]:match})}(function(window2,factory){var lazySizes=factory(window2,window2.document,Date);window2.lazySizes=lazySizes,typeof module=="object"&&module.exports&&(module.exports=lazySizes)})(typeof window!="undefined"?window:{},function(window2,document2,Date2){"use strict";var lazysizes,lazySizesCfg;if((function(){var prop,lazySizesDefaults={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",loadafterClass:"lazyloadafter",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:!0,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:!0,ricTimeout:0,throttleDelay:125};lazySizesCfg=window2.lazySizesConfig||window2.lazysizesConfig||{};for(prop in lazySizesDefaults)prop in lazySizesCfg||(lazySizesCfg[prop]=lazySizesDefaults[prop])})(),!document2||!document2.getElementsByClassName)return{init:function(){},cfg:lazySizesCfg,noSupport:!0};var docElem=document2.documentElement,supportPicture=window2.HTMLPictureElement,_addEventListener="addEventListener",_getAttribute="getAttribute",addEventListener=window2[_addEventListener].bind(window2),setTimeout2=window2.setTimeout,requestAnimationFrame2=window2.requestAnimationFrame||setTimeout2,requestIdleCallback=window2.requestIdleCallback,regPicture=/^picture$/i,loadEvents=["load","error","lazyincluded","_lazyloaded"],regClassCache={},forEach=Array.prototype.forEach,hasClass=function(ele,cls){return regClassCache[cls]||(regClassCache[cls]=new RegExp("(\\s|^)"+cls+"(\\s|$)")),regClassCache[cls].test(ele[_getAttribute]("class")||"")&®ClassCache[cls]},addClass=function(ele,cls){hasClass(ele,cls)||ele.setAttribute("class",(ele[_getAttribute]("class")||"").trim()+" "+cls)},removeClass=function(ele,cls){var reg2;(reg2=hasClass(ele,cls))&&ele.setAttribute("class",(ele[_getAttribute]("class")||"").replace(reg2," "))},addRemoveLoadEvents=function(dom,fn,add){var action=add?_addEventListener:"removeEventListener";add&&addRemoveLoadEvents(dom,fn),loadEvents.forEach(function(evt){dom[action](evt,fn)})},triggerEvent=function(elem,name,detail,noBubbles,noCancelable){var event=document2.createEvent("Event");return detail||(detail={}),detail.instance=lazysizes,event.initEvent(name,!noBubbles,!noCancelable),event.detail=detail,elem.dispatchEvent(event),event},updatePolyfill=function(el,full){var polyfill;!supportPicture&&(polyfill=window2.picturefill||lazySizesCfg.pf)?(full&&full.src&&!el[_getAttribute]("srcset")&&el.setAttribute("srcset",full.src),polyfill({reevaluate:!0,elements:[el]})):full&&full.src&&(el.src=full.src)},getCSS=function(elem,style){return(getComputedStyle(elem,null)||{})[style]},getWidth=function(elem,parent,width){for(width=width||elem.offsetWidth;width<lazySizesCfg.minSize&&parent&&!elem._lazysizesWidth;)width=parent.offsetWidth,parent=parent.parentNode;return width},rAF=(function(){var running,waiting,firstFns=[],secondFns=[],fns=firstFns,run=function(){var runFns=fns;for(fns=firstFns.length?secondFns:firstFns,running=!0,waiting=!1;runFns.length;)runFns.shift()();running=!1},rafBatch=function(fn,queue){running&&!queue?fn.apply(this,arguments):(fns.push(fn),waiting||(waiting=!0,(document2.hidden?setTimeout2:requestAnimationFrame2)(run)))};return rafBatch._lsFlush=run,rafBatch})(),rAFIt=function(fn,simple){return simple?function(){rAF(fn)}:function(){var that=this,args=arguments;rAF(function(){fn.apply(that,args)})}},throttle2=function(fn){var running,lastTime=0,gDelay=lazySizesCfg.throttleDelay,rICTimeout=laLine truncated
|
||||
;
|
||||
|
||||
/* source: assets/js/instant-page.js */
|
||||
/**
|
||||
* AKSRT Instant Page
|
||||
*
|
||||
* Lightweight page prefetch on hover/focus.
|
||||
* Preloads pages when the user hovers over a link, so navigation feels instant.
|
||||
* No external dependencies — pure vanilla JS.
|
||||
*
|
||||
* Based on the instant.page concept (MIT license).
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
|
||||
(function () {
|
||||
'use strict';
|
||||
|
||||
// Only prefetch on desktop (no touch-only devices) with good connection
|
||||
if ('connection' in navigator) {
|
||||
var conn = navigator.connection;
|
||||
if (conn.saveData || (conn.effectiveType && conn.effectiveType.indexOf('2g') !== -1)) return;
|
||||
}
|
||||
|
||||
// Don't run on touch-only devices (they don't benefit from hover prefetch)
|
||||
var hasHoverSupport = window.matchMedia('(hover: hover) and (pointer: fine)').matches;
|
||||
if (!hasHoverSupport) return;
|
||||
|
||||
var prefetcher = document.createElement('link');
|
||||
var isPrefetched = {};
|
||||
var timer = null;
|
||||
var DELAY = 65; // ms to wait before prefetching
|
||||
var MAX_PREFETCH = 3; // max concurrent prefetches
|
||||
var prefetchedCount = 0;
|
||||
|
||||
if (!prefetcher.relList || !prefetcher.relList.supports || !prefetcher.relList.supports('prefetch')) return;
|
||||
|
||||
function prefetch(url) {
|
||||
if (isPrefetched[url] || prefetchedCount >= MAX_PREFETCH) return;
|
||||
|
||||
// Don't prefetch URLs with hash (same page navigation)
|
||||
if (url.indexOf('#') !== -1) return;
|
||||
|
||||
// Only prefetch same-origin URLs
|
||||
try {
|
||||
var link = new URL(url, window.location.origin);
|
||||
if (link.origin !== window.location.origin) return;
|
||||
// Don't prefetch the current page
|
||||
if (link.pathname === window.location.pathname && link.search === window.location.search) return;
|
||||
} catch (e) { return; }
|
||||
|
||||
// Don't prefetch files/downloads
|
||||
if (/\.(pdf|zip|rar|7z|tar|gz|exe|dmg|apk|mp[34]|avi|mov|wmv|flv|webm|ogg|wav|bmp|gif|ico|svg|woff2?|ttf|eot)(\?|$)/i.test(url)) return;
|
||||
|
||||
isPrefetched[url] = true;
|
||||
prefetchedCount++;
|
||||
|
||||
var linkEl = document.createElement('link');
|
||||
linkEl.rel = 'prefetch';
|
||||
linkEl.href = url;
|
||||
linkEl.as = 'document';
|
||||
document.head.appendChild(linkEl);
|
||||
}
|
||||
|
||||
function onHoverStart(e) {
|
||||
var link = e.target.closest('a');
|
||||
if (!link || !link.href) return;
|
||||
if (link.target === '_blank') return;
|
||||
if (link.hasAttribute('download')) return;
|
||||
if (link.getAttribute('rel') === 'nofollow') return;
|
||||
if (link.closest('.no-prefetch,[data-no-prefetch]')) return;
|
||||
|
||||
clearTimeout(timer);
|
||||
timer = setTimeout(function () {
|
||||
prefetch(link.href);
|
||||
}, DELAY);
|
||||
}
|
||||
|
||||
function onHoverEnd() {
|
||||
clearTimeout(timer);
|
||||
}
|
||||
|
||||
document.addEventListener('mouseover', onHoverStart, { passive: true, capture: true });
|
||||
document.addEventListener('mouseout', onHoverEnd, { passive: true, capture: true });
|
||||
|
||||
// Also prefetch on focus for keyboard navigation
|
||||
document.addEventListener('focusin', function (e) {
|
||||
var link = e.target.closest('a');
|
||||
if (link && link.href) {
|
||||
prefetch(link.href);
|
||||
}
|
||||
}, { passive: true, capture: true });
|
||||
|
||||
// Cleanup after page hides (bfcache)
|
||||
window.addEventListener('pagehide', function () {
|
||||
isPrefetched = {};
|
||||
prefetchedCount = 0;
|
||||
});
|
||||
})();
|
||||
;
|
||||
@@ -61,7 +61,6 @@ tbquire.config({
|
||||
'enlighterjs' : 'enlighter/enlighterjs.min',
|
||||
'imgbox' : 'imgbox.min',
|
||||
'section-navs' : 'section-navs.min',
|
||||
'main' : 'main.min',
|
||||
'poster-share' : 'poster-share.min',
|
||||
'slidercaptcha' : 'slidercaptcha.min',
|
||||
'comment' : 'comment.min',
|
||||
@@ -83,5 +82,3 @@ tbquire.config({
|
||||
'shop—main' : _win.uri+'/inc/functions/shop/assets/js/main.min',
|
||||
}
|
||||
})
|
||||
|
||||
tbquire(['main']);
|
||||
@@ -1885,6 +1885,7 @@ _win.bd.on('click', '[remote-box]', function () {
|
||||
jQuery.post(remote, null, function (data) {
|
||||
_this.html(data).removeAttr('remote-box');
|
||||
auto_fun();
|
||||
_this.trigger('aksrt:remote-loaded');
|
||||
});
|
||||
}
|
||||
});
|
||||
@@ -3580,9 +3581,19 @@ _win.bd.on('submit', '.main-search form', function () {
|
||||
//搜索功能
|
||||
_win.bd.on('click', '.main-search-btn', function () {
|
||||
var _this = jQuery(this);
|
||||
var _search_form = jQuery('.main-search form');
|
||||
jQuery('.main-search').addClass('show');
|
||||
|
||||
var _remote_search = jQuery('.main-search [remote-box]').first();
|
||||
if (_remote_search.length) {
|
||||
_remote_search.one('aksrt:remote-loaded', function () {
|
||||
_this.trigger('click');
|
||||
});
|
||||
_remote_search.trigger('click');
|
||||
return;
|
||||
}
|
||||
|
||||
var _search_form = jQuery('.main-search form');
|
||||
|
||||
if (_search_form.length) {
|
||||
var attr_ = 'search-';
|
||||
var obj = {
|
||||
@@ -4470,6 +4481,11 @@ function tilt_cases_init() {
|
||||
return;
|
||||
}
|
||||
|
||||
var cases = jQuery('.vanilla-tilt:not(.is-initialized)');
|
||||
if (!cases.length) {
|
||||
return;
|
||||
}
|
||||
|
||||
function setTranslate3d(imgs, translate3d) {
|
||||
//先获取原有的transform
|
||||
var transform = imgs[0].style.transform;
|
||||
@@ -4483,7 +4499,7 @@ function tilt_cases_init() {
|
||||
}
|
||||
|
||||
tbquire(['tilt'], function () {
|
||||
jQuery('.vanilla-tilt:not(.is-initialized)').each(function () {
|
||||
cases.each(function () {
|
||||
var _this = jQuery(this);
|
||||
var imgs = _this.find('img');
|
||||
|
||||
@@ -4584,13 +4600,6 @@ jQuery(document).ready(function () {
|
||||
});
|
||||
}
|
||||
|
||||
setTimeout(function () {
|
||||
//获取登录用户数据,延迟2秒执行
|
||||
jQuery.post(_win.ajax_url, {
|
||||
action: 'get_current_user',
|
||||
});
|
||||
}, 1000);
|
||||
|
||||
//内容高度限制
|
||||
posts_limit_height();
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
jQuery.cookie=function(t,e,a){if(e===void 0){var i=null;if(document.cookie&&document.cookie!="")for(var n=document.cookie.split(";"),r=0;r<n.length;r++){var o=jQuery.trim(n[r]);if(o.substring(0,t.length+1)==t+"="){i=decodeURIComponent(o.substring(t.length+1));break}}return i}a=a||{},e===null&&(e="",a.expires=-1);var s="";if(a.expires&&(typeof a.expires=="number"||a.expires.toUTCString)){var d;typeof a.expires=="number"?(d=new Date,d.setTime(d.getTime()+24*a.expires*60*60*1e3)):d=a.expires,s="; expires="+d.toUTCString()}var c=a.path?"; path="+a.path:"",u=a.domain?"; domain="+a.domain:"",l=a.secure?"; secure":"";document.cookie=[t,"=",encodeURIComponent(e),s,c,u,l].join("")};var lcs={get:function(t){return window.localStorage?localStorage.getItem(t):jQuery.cookie(t)},set:function(t,e){window.localStorage?localStorage[t]=e:jQuery.cookie(t,e)},remove:function(t){window.localStorage?localStorage.removeItem(t):jQuery.cookie(t,"")}};function aksrt__(t){var e=window._win&&window._win.i18n;return e&&Object.prototype.hasOwnProperty.call(e,t)?e[t]:t}function aksrt_is_fatal_error_response(t){return t&&(t.indexOf("Fatal error")>-1||t.indexOf("\u81F4\u547D\u9519\u8BEF")>-1)}function aksrt_sprintf(t){var e=Array.prototype.slice.call(arguments,1),a=aksrt__(t),i=0;return a.replace(/%(\d+\$)?s/g,function(n,r){var o=r?parseInt(r,10)-1:i++;return e[o]!==void 0&&e[o]!==null?e[o]:n})}(function(t,e){var a=e(t,t.document,Date);t.lazySizes=a,typeof module=="object"&&module.exports&&(module.exports=a)})(typeof window<"u"?window:{},function(e,a,i){"use strict";var n,r;if((function(){var w,g={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",loadafterClass:"lazyloadafter",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:!0,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:!0,ricTimeout:0,throttleDelay:125};r=e.lazySizesConfig||e.lazysizesConfig||{};for(w in g)w in r||(r[w]=g[w])})(),!a||!a.getElementsByClassName)return{init:function(){},cfg:r,noSupport:!0};var o=a.documentElement,s=e.HTMLPictureElement,d="addEventListener",c="getAttribute",u=e[d].bind(e),l=e.setTimeout,f=e.requestAnimationFrame||l,h=e.requestIdleCallback,p=/^picture$/i,_=["load","error","lazyincluded","_lazyloaded"],v={},y=Array.prototype.forEach,b=function(w,g){return v[g]||(v[g]=new RegExp("(\\s|^)"+g+"(\\s|$)")),v[g].test(w[c]("class")||"")&&v[g]},C=function(w,g){b(w,g)||w.setAttribute("class",(w[c]("class")||"").trim()+" "+g)},k=function(w,g){var j;(j=b(w,g))&&w.setAttribute("class",(w[c]("class")||"").replace(j," "))},z=function(w,g,j){var L=j?d:"removeEventListener";j&&z(w,g),_.forEach(function(O){w[L](O,g)})},S=function(w,g,j,L,O){var T=a.createEvent("Event");return j||(j={}),j.instance=n,T.initEvent(g,!L,!O),T.detail=j,w.dispatchEvent(T),T},W=function(w,g){var j;!s&&(j=e.picturefill||r.pf)?(g&&g.src&&!w[c]("srcset")&&w.setAttribute("srcset",g.src),j({reevaluate:!0,elements:[w]})):g&&g.src&&(w.src=g.src)},G=function(w,g){return(getComputedStyle(w,null)||{})[g]},tt=function(w,g,j){for(j=j||w.offsetWidth;j<r.minSize&&g&&!w._lazysizesWidth;)j=g.offsetWidth,g=g.parentNode;return j},J=(function(){var w,g,j=[],L=[],O=j,T=function(){var E=O;for(O=j.length?L:j,w=!0,g=!1;E.length;)E.shift()();w=!1},M=function(E,q){w&&!q?E.apply(this,arguments):(O.push(E),g||(g=!0,(a.hidden?l:f)(T)))};return M._lsFlush=T,M})(),Q=function(w,g){return g?function(){J(w)}:function(){var j=this,L=arguments;J(function(){w.apply(j,L)})}},mt=function(w){var g,j=0,L=r.throttleDelay,O=r.ricTimeout,T=function(){g=!1,j=i.now(),w()},M=h&&O>49?function(){h(T,{timeout:O}),O!==r.ricTimeout&&(O=r.ricTimeout)}:Q(function(){l(T)},!0);return function(E){var q;(E=E===!0)&&(O=33),!g&&(g=!0,q=L-(i.now()-j),q<0&&(q=0),E||q<9?M():l(M,q))}},lt=function(w){var g,j,L=99,O=function(){g=null,w()},T=function(){var M=i.now()-j;M<L?l(T,L-M):(h||O)(O)};return function(){j=i.now(),g||(g=l(T,L))}},dt=(function(){var w,g,j,L,O,T,M,E,q,P,D,K,gt=/^img$/i,_t=/^iframe$/i,wt="onscroll"in e&&!/(gle|ing)bot/.test(navigator.userAgent),bt=0,it=0,B=0,at=-1,ct=function(m){B--,(!m||B<0||!m.target)&&(B=0)},ut=function(m){return K==null&&(K=G(a.body,"visibility")=="hidden"),K||!(G(m.parentNode,"visibility")=="hidden"&&G(m,"visibility")=="hidden")},yt=function(m,x){var A,H=m,I=ut(m);for(E-=x,D+=x,q-=x,P+=x;I&&(H=H.offsetParent)&&H!=a.body&&H!=o;)I=(G(H,"opacity")||1)>0,I&&G(H,"overflow")!="visible"&&(A=H.getBoundingClientRect(),I=P>A.left&&q<A.right&&D>A.top-1&&E<A.bottom+1);return I},ft=function(){var m,x,A,H,I,F,U,V,Y,X,Z,et,R=n.elements;if((L=r.loadMode)&&B<8&&(m=R.length)){for(x=0,at++;x<m;x++)if(!(!R[x]||R[x]._lazyRace)){if(!wt||n.prematureUnveil&&n.prematureUnveil(R[x])){rt(R[x]);continue}if((!(V=R[x][c]("data-expand"))||!(F=V*1))&&(F=it),X||(X=!r.expand||r.expand<1?o.clientHeight>500&&o.clientWidth>500?500:370:r.expand,n._defEx=X,Z=X*r.expFactor,et=r.hFac,K=null,it<Z&&B<1&&at>2&&L>2&&!aLine truncated
|
||||
jQuery.cookie=function(e,o,t){if(o===void 0){var i=null;if(document.cookie&&document.cookie!="")for(var r=document.cookie.split(";"),n=0;n<r.length;n++){var c=jQuery.trim(r[n]);if(c.substring(0,e.length+1)==e+"="){i=decodeURIComponent(c.substring(e.length+1));break}}return i}t=t||{},o===null&&(o="",t.expires=-1);var a="";if(t.expires&&(typeof t.expires=="number"||t.expires.toUTCString)){var l2;typeof t.expires=="number"?(l2=new Date,l2.setTime(l2.getTime()+24*t.expires*60*60*1e3)):l2=t.expires,a="; expires="+l2.toUTCString()}var u=t.path?"; path="+t.path:"",s=t.domain?"; domain="+t.domain:"",m=t.secure?"; secure":"";document.cookie=[e,"=",encodeURIComponent(o),a,u,s,m].join("")};var lcs={get:function(e){return window.localStorage?localStorage.getItem(e):jQuery.cookie(e)},set:function(e,o){window.localStorage?localStorage[e]=o:jQuery.cookie(e,o)},remove:function(e){window.localStorage?localStorage.removeItem(e):jQuery.cookie(e,"")}};function aksrt__(key){var map=window._win&&window._win.i18n;return map&&Object.prototype.hasOwnProperty.call(map,key)?map[key]:key}function aksrt_is_fatal_error_response(text){return text&&(text.indexOf("Fatal error")>-1||text.indexOf("致命错误")>-1)}function aksrt_sprintf(key){var args=Array.prototype.slice.call(arguments,1),str=aksrt__(key),autoIndex=0;return str.replace(/%(\d+\$)?s/g,function(match,num){var idx=num?parseInt(num,10)-1:autoIndex++;return args[idx]!==void 0&&args[idx]!==null?args[idx]:match})}(function(window2,factory){var lazySizes=factory(window2,window2.document,Date);window2.lazySizes=lazySizes,typeof module=="object"&&module.exports&&(module.exports=lazySizes)})(typeof window!="undefined"?window:{},function(window2,document2,Date2){"use strict";var lazysizes,lazySizesCfg;if((function(){var prop,lazySizesDefaults={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",loadafterClass:"lazyloadafter",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:!0,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:!0,ricTimeout:0,throttleDelay:125};lazySizesCfg=window2.lazySizesConfig||window2.lazysizesConfig||{};for(prop in lazySizesDefaults)prop in lazySizesCfg||(lazySizesCfg[prop]=lazySizesDefaults[prop])})(),!document2||!document2.getElementsByClassName)return{init:function(){},cfg:lazySizesCfg,noSupport:!0};var docElem=document2.documentElement,supportPicture=window2.HTMLPictureElement,_addEventListener="addEventListener",_getAttribute="getAttribute",addEventListener=window2[_addEventListener].bind(window2),setTimeout2=window2.setTimeout,requestAnimationFrame2=window2.requestAnimationFrame||setTimeout2,requestIdleCallback=window2.requestIdleCallback,regPicture=/^picture$/i,loadEvents=["load","error","lazyincluded","_lazyloaded"],regClassCache={},forEach=Array.prototype.forEach,hasClass=function(ele,cls){return regClassCache[cls]||(regClassCache[cls]=new RegExp("(\\s|^)"+cls+"(\\s|$)")),regClassCache[cls].test(ele[_getAttribute]("class")||"")&®ClassCache[cls]},addClass=function(ele,cls){hasClass(ele,cls)||ele.setAttribute("class",(ele[_getAttribute]("class")||"").trim()+" "+cls)},removeClass=function(ele,cls){var reg2;(reg2=hasClass(ele,cls))&&ele.setAttribute("class",(ele[_getAttribute]("class")||"").replace(reg2," "))},addRemoveLoadEvents=function(dom,fn,add){var action=add?_addEventListener:"removeEventListener";add&&addRemoveLoadEvents(dom,fn),loadEvents.forEach(function(evt){dom[action](evt,fn)})},triggerEvent=function(elem,name,detail,noBubbles,noCancelable){var event=document2.createEvent("Event");return detail||(detail={}),detail.instance=lazysizes,event.initEvent(name,!noBubbles,!noCancelable),event.detail=detail,elem.dispatchEvent(event),event},updatePolyfill=function(el,full){var polyfill;!supportPicture&&(polyfill=window2.picturefill||lazySizesCfg.pf)?(full&&full.src&&!el[_getAttribute]("srcset")&&el.setAttribute("srcset",full.src),polyfill({reevaluate:!0,elements:[el]})):full&&full.src&&(el.src=full.src)},getCSS=function(elem,style){return(getComputedStyle(elem,null)||{})[style]},getWidth=function(elem,parent,width){for(width=width||elem.offsetWidth;width<lazySizesCfg.minSize&&parent&&!elem._lazysizesWidth;)width=parent.offsetWidth,parent=parent.parentNode;return width},rAF=(function(){var running,waiting,firstFns=[],secondFns=[],fns=firstFns,run=function(){var runFns=fns;for(fns=firstFns.length?secondFns:firstFns,running=!0,waiting=!1;runFns.length;)runFns.shift()();running=!1},rafBatch=function(fn,queue){running&&!queue?fn.apply(this,arguments):(fns.push(fn),waiting||(waiting=!0,(document2.hidden?setTimeout2:requestAnimationFrame2)(run)))};return rafBatch._lsFlush=run,rafBatch})(),rAFIt=function(fn,simple){return simple?function(){rAF(fn)}:function(){var that=this,args=arguments;rAF(function(){fn.apply(that,args)})}},throttle2=function(fn){var running,lastTime=0,gDelay=lazySizesCfg.throttleDelay,rICTimeout=laLine truncated
|
||||
Reference in new issue
Block a user