SAMScript

更改 SAMS 网页出校时间

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name SAMScript
// @version 1.2.2
// @namespace https://greasyfork.org/users/995444
// @description 更改 SAMS 网页出校时间
// @author Kaby Lake
// @homepage https://github.com/Kaby-Lake/SAMScript
// @match https://appgateway.nottingham.edu.cn/*/*/zh/Students/stuaskforleave
// @match https://appgateway.nottingham.edu.cn/*/*/zh/Students/stuaskforleave/*
// @match https://sams.nottingham.edu.cn/zh/Students/stuaskforleave
// @match https://sams.nottingham.edu.cn/zh/Students/stuaskforleave/*
// @require https://cdn.jsdelivr.net/npm/[email protected]
// @require https://cdn.jsdelivr.net/npm/[email protected]
// ==/UserScript==
(()=>{var r=[function(t,e,r){"use strict";var n=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(1),o=r(2),a=r(3),s=r(6),u=r(7),c=r(5);var d,e=n(r(4)),l=n(r(8));const _=r(9),f=n(r(10));function h(t,e,r){let n=e.format("YYYY-MM-DD HH:mm");1==r&&(n=e.toDate().toLocaleString()),t&&(t.innerHTML=n)}e.default.extend(l.default);try{document.querySelector("body").style.visibility="hidden",(0,_.announceUpdates)();var S=location.href.includes("/details/"),E=new a.Record;if((0,s.hasLocalStorage)(i.SAMS_LOCAL_STORAGE_KEY))try{var T=JSON.parse(null!=(d=(0,s.getLocalStorage)(i.SAMS_LOCAL_STORAGE_KEY))?d:"");E.restoreRecord(T)}catch(t){localStorage.removeItem(i.SAMS_LOCAL_STORAGE_KEY),alert("LocalStorage 格式错误,请刷新页面后重试")}else{var p=(0,o.getIntegerFromPrompt)("开始时间(小时):","请输入正确的开始时间"),v=(0,o.getIntegerFromPrompt)("结束时间(小时):","请输入正确的结束时间"),O=window.prompt("请假原因(不填则不会修改)"),y=(E.startTime=E.startTime.set("hour",p),E.endTime=E.endTime.set("hour",v),E.reason=(0,f.default)(O)?void 0:O,(0,c.isWeekends)()&&(E.applyTime=(0,c.getEndOfWeekdays)(),E.approveTime=(0,c.getEndOfWeekdays)()),(0,u.getRandomInt)(5));E.applyTime=E.applyTime.set("hour",y+10).set("minute",(0,u.getRandomInt)(60)).set("minute",(0,u.getRandomInt)(60)),E.approveTime=E.approveTime.set("hour",y+11).set("minute",(0,u.getRandomInt)(60)).set("minute",(0,u.getRandomInt)(60)),(0,s.setLocalStorage)(i.SAMS_LOCAL_STORAGE_KEY,E.toMemorizedString())}var m=S?document.querySelector(i.DETAIL_PAGE_START_TIME_DOM_SELECTOR):document.querySelector(i.LIST_PAGE_START_TIME_DOM_SELECTOR),A=S?document.querySelector(i.DETAIL_PAGE_END_TIME_DOM_SELECTOR):document.querySelector(i.LIST_PAGE_END_TIME_DOM_SELECTOR),M=S?document.querySelector(i.DETAIL_PAGE_REASON_DOM_SELECTOR):document.querySelector(i.LIST_PAGE_REASON_DOM_SELECTOR),L=S?document.querySelector(i.DETAIL_PAGE_APPLY_TIME_DOM_SELECTOR):document.querySelector(i.LIST_PAGE_APPLY_TIME_DOM_SELECTOR),D=S?document.querySelector(i.DETAIL_PAGE_STATUS_DOM_SELECTOR):document.querySelector(i.LIST_PAGE_STATUS_DOM_SELECTOR),g=S?document.querySelector(i.DETAIL_PAGE_APPROVE_TIME_DOM_SELECTOR):void 0,b=S?document.querySelector(i.DETAIL_PAGE_APPROVE_STATUS_DOM_SELECTOR):void 0,R=(h(m,E.startTime,0),h(A,E.endTime,0),h(L,E.applyTime,0),g&&h(g,E.approveTime,1),E.reason&&(M.innerHTML=E.reason),D&&(D.innerHTML="通过",D.className="label label-success"),b&&(b.innerHTML="通过"),document.querySelector(i.AVATAR_DOM_SELECTOR));null!=R&&R.addEventListener("click",()=>{localStorage.removeItem(i.SAMS_LOCAL_STORAGE_KEY)}),document.querySelector("body").style.visibility="visible"}catch(t){console.log(t),document.querySelector("body").style.visibility="visible"}},(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AVATAR_DOM_SELECTOR=e.DETAIL_PAGE_APPROVE_STATUS_DOM_SELECTOR=e.DETAIL_PAGE_STATUS_DOM_SELECTOR=e.LIST_PAGE_STATUS_DOM_SELECTOR=e.DETAIL_PAGE_APPROVE_TIME_DOM_SELECTOR=e.LIST_PAGE_APPLY_TIME_DOM_SELECTOR=e.DETAIL_PAGE_REASON_DOM_SELECTOR=e.LIST_PAGE_REASON_DOM_SELECTOR=e.DETAIL_PAGE_APPLY_TIME_DOM_SELECTOR=e.LIST_PAGE_END_TIME_DOM_SELECTOR=e.DETAIL_PAGE_END_TIME_DOM_SELECTOR=e.LIST_PAGE_START_TIME_DOM_SELECTOR=e.DETAIL_PAGE_START_TIME_DOM_SELECTOR=e.SAMS_VERSION=e.SAMS_VERSION_LOCAL_STORAGE_KEY=e.SAMS_LOCAL_STORAGE_KEY=void 0,e.SAMS_LOCAL_STORAGE_KEY="sams_crack",e.SAMS_VERSION_LOCAL_STORAGE_KEY="sams_crack_version",e.SAMS_VERSION="1.2.2",e.DETAIL_PAGE_START_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(2) > div",e.LIST_PAGE_START_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.table-responsive > table > tbody > tr:nth-child(2) > td:nth-child(2)",e.DETAIL_PAGE_END_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(3) > div",e.LIST_PAGE_END_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.table-responsive > table > tbody > tr:nth-child(2) > td:nth-child(3)",e.DETAIL_PAGE_APPLY_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(7) > div",e.LIST_PAGE_REASON_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.table-responsive > table > tbody > tr:nth-child(2) > td:nth-child(4)",e.DETAIL_PAGE_REASON_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(4) > div",e.LIST_PAGE_APPLY_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.table-responsive > table > tbody > tr:nth-child(2) > td:nth-child(6)",e.DETAIL_PAGE_APPROVE_TIME_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(8) > div > table > tbody > tr > td:nth-child(2)",e.LIST_PAGE_STATUS_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.table-responsive > table > tbody > tr:nth-child(2) > td:nth-child(5) > label",e.DETAIL_PAGE_STATUS_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(6) > div > label",e.DETAIL_PAGE_APPROVE_STATUS_DOM_SELECTOR="body > div.wrapper > div.content-wrapper > section.content > div > div.form-horizontal > div:nth-child(8) > div > table > tbody > tr > td:nth-child(3)",e.AVATAR_DOM_SELECTOR="body > div.wrapper > header > nav > div.navbar-custom-menu > ul > li > ul > li.user-header > img"},(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getIntegerFromPrompt=void 0,e.getIntegerFromPrompt=function(t,e){if(t=parseInt(null!=(t=window.prompt(t))?t:""),isNaN(t))throw alert(e),new Error("Invalid input");return t}},function(t,e,r){"use strict";var n=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Record=void 0;const i=n(r(4)),o=r(5);e.Record=class{constructor(){this.startTime=(0,o.getStartOfDay)((0,i.default)()),this.endTime=(0,o.getStartOfDay)((0,i.default)()),this.applyTime=(0,o.getStartOfDay)((0,i.default)()),this.approveTime=(0,o.getStartOfDay)((0,i.default)()),this.reason=void 0}restoreRecord(t){return this.startTime=(0,i.default)(t.startTime),this.endTime=(0,i.default)(t.endTime),this.applyTime=(0,i.default)(t.applyTime),this.approveTime=(0,i.default)(t.approveTime),this.reason=t.reason,this}toMemorizedString(){return JSON.stringify({startTime:this.startTime.toString(),endTime:this.endTime.toString(),applyTime:this.applyTime.toString(),approveTime:this.approveTime.toString(),reason:this.reason})}}},function(t){t.exports=function(){"use strict";var c=1e3,d=6e4,l=36e5,u="millisecond",f="second",h="minute",S="hour",E="day",T="week",p="month",_="quarter",v="year",O="date",y="Invalid Date",a=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,t={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],r=t%100;return"["+t+(e[(r-20)%10]||e[r]||e[0])+"]"}},o=function(t,e,r){var n=String(t);return!n||n.length>=e?t:""+Array(e+1-n.length).join(r)+t},e={s:o,z:function(t){var e=-t.utcOffset(),r=Math.abs(e),n=Math.floor(r/60),i=r%60;return(e<=0?"+":"-")+o(n,2,"0")+":"+o(i,2,"0")},m:function t(e,r){if(e.date()<r.date())return-t(r,e);var n=12*(r.year()-e.year())+(r.month()-e.month()),i=e.clone().add(n,p),o=r-i<0,a=e.clone().add(n+(o?-1:1),p);return+(-(n+(r-i)/(o?i-a:a-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:p,y:v,w:T,d:E,D:O,h:S,m:h,s:f,ms:u,Q:_}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},A="en",M={},n=(M[A]=t,function(t){return t instanceof s}),i=function t(e,r,n){var i;if(!e)return A;if("string"==typeof e){var o=e.toLowerCase();M[o]&&(i=o),r&&(M[o]=r,i=o);var a=e.split("-");if(!i&&a.length>1)return t(a[0])}else{var s=e.name;M[s]=e,i=s}return!n&&i&&(A=i),i||!n&&A},L=function(t,e){if(n(t))return t.clone();var r="object"==typeof e?e:{};return r.date=t,r.args=arguments,new s(r)},D=e,s=(D.l=i,D.i=n,D.w=function(t,e){return L(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})},function(){function t(t){this.$L=i(t.locale,null,!0),this.parse(t)}var e=t.prototype;return e.parse=function(t){this.$d=function(t){var e=t.date,r=t.utc;if(null===e)return new Date(NaN);if(D.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var n=e.match(a);if(n){var i=n[2]-1||0,o=(n[7]||"0").substring(0,3);return r?new Date(Date.UTC(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)):new Date(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},e.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},e.$utils=function(){return D},e.isValid=function(){return!(this.$d.toString()===y)},e.isSame=function(t,e){var r=L(t);return this.startOf(e)<=r&&r<=this.endOf(e)},e.isAfter=function(t,e){return L(t)<this.startOf(e)},e.isBefore=function(t,e){return this.endOf(e)<L(t)},e.$g=function(t,e,r){return D.u(t)?this[e]:this.set(r,t)},e.unix=function(){return Math.floor(this.valueOf()/1e3)},e.valueOf=function(){return this.$d.getTime()},e.startOf=function(t,e){var n=this,i=!!D.u(e)||e,r=D.p(t),o=function(t,e){var r=D.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return i?r:r.endOf(E)},a=function(t,e){return D.w(n.toDate()[t].apply(n.toDate("s"),(i?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},s=this.$W,u=this.$M,c=this.$D,d="set"+(this.$u?"UTC":"");switch(r){case v:return i?o(1,0):o(31,11);case p:return i?o(1,u):o(0,u+1);case T:var l=this.$locale().weekStart||0,_=(s<l?s+7:s)-l;return o(i?c-_:c+(6-_),u);case E:case O:return a(d+"Hours",0);case S:return a(d+"Minutes",1);case h:return a(d+"Seconds",2);case f:return a(d+"Milliseconds",3);default:return this.clone()}},e.endOf=function(t){return this.startOf(t,!1)},e.$set=function(t,e){var r,n=D.p(t),i="set"+(this.$u?"UTC":""),o=(r={},r[E]=i+"Date",r[O]=i+"Date",r[p]=i+"Month",r[v]=i+"FullYear",r[S]=i+"Hours",r[h]=i+"Minutes",r[f]=i+"Seconds",r[u]=i+"Milliseconds",r)[n],a=n===E?this.$D+(e-this.$W):e;if(n===p||n===v){var s=this.clone().set(O,1);s.$d[o](a),s.init(),this.$d=s.set(O,Math.min(this.$D,s.daysInMonth())).$d}else o&&this.$d[o](a);return this.init(),this},e.set=function(t,e){return this.clone().$set(t,e)},e.get=function(t){return this[D.p(t)]()},e.add=function(r,t){var e,n=this;r=Number(r);var i=D.p(t),o=function(t){var e=L(n);return D.w(e.date(e.date()+Math.round(t*r)),n)};if(i===p)return this.set(p,this.$M+r);if(i===v)return this.set(v,this.$y+r);if(i===E)return o(1);if(i===T)return o(7);var a=(e={},e[h]=d,e[S]=l,e[f]=c,e)[i]||1,s=this.$d.getTime()+r*a;return D.w(s,this)},e.subtract=function(t,e){return this.add(-1*t,e)},e.format=function(t){var i=this,e=this.$locale();if(!this.isValid())return e.invalidDate||y;var o=t||"YYYY-MM-DDTHH:mm:ssZ",r=D.z(this),n=this.$H,a=this.$m,s=this.$M,u=e.weekdays,c=e.months,d=function(t,e,r,n){return t&&(t[e]||t(i,o))||r[e].slice(0,n)},l=function(t){return D.s(n%12||12,t,"0")},_=e.meridiem||function(t,e,r){var n=t<12?"AM":"PM";return r?n.toLowerCase():n},f={YY:String(this.$y).slice(-2),YYYY:this.$y,M:s+1,MM:D.s(s+1,2,"0"),MMM:d(e.monthsShort,s,c,3),MMMM:d(c,s),D:this.$D,DD:D.s(this.$D,2,"0"),d:String(this.$W),dd:d(e.weekdaysMin,this.$W,u,2),ddd:d(e.weekdaysShort,this.$W,u,3),dddd:u[this.$W],H:String(n),HH:D.s(n,2,"0"),h:l(1),hh:l(2),a:_(n,a,!0),A:_(n,a,!1),m:String(a),mm:D.s(a,2,"0"),s:String(this.$s),ss:D.s(this.$s,2,"0"),SSS:D.s(this.$ms,3,"0"),Z:r};return o.replace(m,function(t,e){return e||f[t]||r.replace(":","")})},e.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},e.diff=function(t,e,r){var n,i=D.p(e),o=L(t),a=(o.utcOffset()-this.utcOffset())*d,s=this-o,u=D.m(this,o);return u=(n={},n[v]=u/12,n[p]=u,n[_]=u/3,n[T]=(s-a)/6048e5,n[E]=(s-a)/864e5,n[S]=s/l,n[h]=s/d,n[f]=s/c,n)[i]||s,r?u:D.a(u)},e.daysInMonth=function(){return this.endOf(p).$D},e.$locale=function(){return M[this.$L]},e.locale=function(t,e){if(!t)return this.$L;var r=this.clone(),n=i(t,e,!0);return n&&(r.$L=n),r},e.clone=function(){return D.w(this.$d,this)},e.toDate=function(){return new Date(this.valueOf())},e.toJSON=function(){return this.isValid()?this.toISOString():null},e.toISOString=function(){return this.$d.toISOString()},e.toString=function(){return this.$d.toUTCString()},t}()),r=s.prototype;return L.prototype=r,[["$ms",u],["$s",f],["$m",h],["$H",S],["$W",E],["$M",p],["$y",v],["$D",O]].forEach(function(e){r[e[1]]=function(t){return this.$g(t,e[0],e[1])}}),L.extend=function(t,e){return t.$i||(t(e,s,L),t.$i=!0),L},L.locale=i,L.isDayjs=n,L.unix=function(t){return L(1e3*t)},L.en=M[A],L.Ls=M,L.p={},L}()},function(t,e,r){"use strict";var n=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.getEndOfWeekdays=e.isWeekends=e.getStartOfDay=void 0;const i=n(r(4));e.getStartOfDay=function(t){return t.set("hour",0).set("minute",0).set("second",0)},e.isWeekends=function(){return 6===(0,i.default)().weekday()||7===(0,i.default)().weekday()},e.getEndOfWeekdays=function(){return(0,i.default)().weekday(5)}},(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.setLocalStorage=e.getLocalStorage=e.hasLocalStorage=void 0;e.hasLocalStorage=t=>{try{return!!window.localStorage.getItem(t)}catch(t){return!1}},e.getLocalStorage=t=>window.localStorage.getItem(t);e.setLocalStorage=(t,e)=>{window.localStorage.setItem(t,e)}},(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getRandomInt=void 0,e.getRandomInt=function(t){return Math.floor(Math.random()*t)}},function(t){t.exports=function(t,e){e.prototype.weekday=function(t){var e=this.$locale().weekStart||0,r=this.$W,r=(r<e?r+7:r)-e;return this.$utils().u(t)?r:this.subtract(r,"day").add(t,"day")}}},(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.announceUpdates=void 0;const n=r(1),i=r(6);e.announceUpdates=function(){(0,i.getLocalStorage)(n.SAMS_VERSION_LOCAL_STORAGE_KEY)!==n.SAMS_VERSION&&(console.log("Announcing updates..."),alert(`
欢迎使用SAMScript,此次更新带来了一些错误修复和改进:

- 增加了出校原因更改,不填则不会更改原有出校原因;
- 请假列表首条记录 和 请假详情中的状态 将自动更改为 \`已通过\`

开发不易,如果可以,欢迎在GitHub给项目点Star,祝您红红火火,鸿运当头
`),localStorage.setItem(n.SAMS_VERSION_LOCAL_STORAGE_KEY,n.SAMS_VERSION))}},(t,e,r)=>{t=r.nmd(t);var n=9007199254740991,i="[object Arguments]",o="[object Function]",a="[object GeneratorFunction]",s="[object Map]",u="[object Promise]",c="[object Set]",d="[object WeakMap]",l="[object DataView]",_=/^\[object .+?Constructor\]$/,r="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g,f="object"==typeof self&&self&&self.Object===Object&&self,r=r||f||Function("return this")(),f=e&&!e.nodeType&&e,e=f&&t&&!t.nodeType&&t,e=e&&e.exports===f;var h,S,f=Function.prototype,E=Object.prototype,T=r["__core-js_shared__"],p=(T=/[^.]+$/.exec(T&&T.keys&&T.keys.IE_PROTO||""))?"Symbol(src)_1."+T:"",v=f.toString,O=E.hasOwnProperty,y=E.toString,m=RegExp("^"+v.call(O).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),T=e?r.Buffer:void 0,A=E.propertyIsEnumerable,f=T?T.isBuffer:void 0,M=(h=Object.keys,S=Object,function(t){return h(S(t))}),e=I(r,"DataView"),T=I(r,"Map"),L=I(r,"Promise"),D=I(r,"Set"),r=I(r,"WeakMap"),g=!A.call({valueOf:1},"valueOf"),b=w(e),R=w(T),j=w(L),Y=w(D),N=w(r);function k(t){var e;return G(t)&&(e=t,!(p&&p in e))&&(C(t)||function(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}(t)?m:_).test(w(t))}function I(t,e){e=e;t=null==(t=t)?void 0:t[e];return k(t)?t:void 0}var $=function(t){return y.call(t)};function w(t){if(null!=t){try{return v.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function V(t){return function(t){return t&&"object"==typeof t}(e=t)&&P(e)&&O.call(t,"callee")&&(!A.call(t,"callee")||y.call(t)==i);var e}(e&&$(new e(new ArrayBuffer(1)))!=l||T&&$(new T)!=s||L&&$(L.resolve())!=u||D&&$(new D)!=c||r&&$(new r)!=d)&&($=function(t){var e=y.call(t),t="[object Object]"==e?t.constructor:void 0,t=t?w(t):void 0;if(t)switch(t){case b:return l;case R:return s;case j:return u;case Y:return c;case N:return d}return e});var H=Array.isArray;function P(t){return null!=t&&"number"==typeof(e=t.length)&&-1<e&&e%1==0&&e<=n&&!C(t);var e}var W=f||function(){return!1};function C(t){t=G(t)?y.call(t):"";return t==o||t==a}function G(t){var e=typeof t;return t&&("object"==e||"function"==e)}t.exports=function(t){if(P(t)&&(H(t)||"string"==typeof t||"function"==typeof t.splice||W(t)||V(t)))return!t.length;var e,r,n=$(t);if(n==s||n==c)return!t.size;if(g||(e=(n=t)&&n.constructor,n===("function"==typeof e&&e.prototype||E)))return!M(t).length;for(r in t)if(O.call(t,r))return!1;return!0}}],n={};function i(t){var e=n[t];return void 0!==e||(e=n[t]={id:t,loaded:!1,exports:{}},r[t].call(e.exports,e,e.exports,i),e.loaded=!0),e.exports}i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),i.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);i(0)})();