PageSourceSearch

https://mistarg.cn/assets/forum/chats-user-list.1e1e3d76bd8fdaecab6e.min.js

js mistarg.cn collected 2026-10-06 13:19:25 UTC 6,620 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunknodebb=self.webpackChunknodebb||[]).push([[1091,18314,22067,34271,43602,49897,56227,87212,99127],{72513(P,E,c){var u,m;u=[c(49897)],m=(function(o){const l={};let a=0;l.init=function(h,r){const g=r.find('[component="chat/user/list"]');if(!g.length)return;const t=r.find('[component="chat/messages/pinned/container"]');r.find('[component="chat/user/list/btn"]').on("click",()=>{g.toggleClass("hidden"),g.hasClass("hidden")?O():(t.addClass("hidden"),y(h,g))}),$(window).off("action:ajaxify.start",O).one("action:ajaxify.start",O),l.addInfiniteScrollHandler(h,g,async(n,f)=>{n.append(await app.parseAndTranslate("partials/chats/user-list","users",f))})};function y(h,r){a&&clearInterval(a),a=setInterval(()=>{D(h,r)},5e3)}function O(){a&&(clearInterval(a),a=0)}async function D(h,r){if(ajaxify.data.template.chats&&app.isFocused&&r.scrollTop()===0&&!r.hasClass("hidden")){const g=await o.get(`/chats/${h}/users`,{start:0});r.find('[data-bs-toggle="tooltip"]').tooltip("dispose"),r.html(await app.parseAndTranslate("partials/chats/user-list","users",g)),r.find('[data-bs-toggle="tooltip"]').tooltip()}}return l.addInfiniteScrollHandler=function(h,r,g){r.on("scroll",utils.debounce(async()=>{const t=(r[0].scrollHeight-r.height())*.85;if(r.scrollTop()>t){const n=r.find("[data-index]").last().attr("data-index"),f=await o.get(`/chats/${h}/users`,{start:parseInt(n,10)+1});f&&f.users.length&&g(r,f)}},200))},l.addSearchHandler=function(h,r,g){r.on("keyup",utils.debounce(async()=>{const t=r.val(),n=await o.get(`/search/chats/${h}/users`,{query:t});g(n)},200))},l}).apply(E,u),m!==void 0&&(P.exports=m)},49897(P,E,c){c.r(E),c.d(E,{del:()=>M,get:()=>g,head:()=>t,patch:()=>f,post:()=>n,put:()=>p});var u=c(91749),m=c.n(u),o=c(65303),l=c(17459),a=c.n(l),y=c(68636),O=c.n(y);const D=config.relative_path+"/api/v3";async function h(e,i){if(e.url=e.url.startsWith("/api")?config.relative_path+e.url:D+e.url,e.headers=e.headers||{},e.headers["x-return-to"]||(e.headers["x-return-to"]=`${window.location.pathname.slice(config.relative_path.length)}${window.location.search}`),typeof i=="function"){r(e).then(s=>i(null,s),s=>i(s));return}try{return await r(e)}catch(s){if(s.message===await l.translate("[[error:api.401]]",config.userLang)){const{url:d}=await(0,u.fire)("filter:admin.reauth",{url:"login"}),w=await l.translate("[[error:api.reauth-required]]",config.userLang);(0,o.confirm)(w,I=>{I&&(y.setItem("location-hash",window.location.hash),ajaxify.go(d))})}throw s}}async function r(e){const{url:i}=e;delete e.url,e.data&&!(e.data instanceof FormData)&&(e.data=JSON.stringify(e.data||{}),e.headers["content-type"]="application/json; charset=utf-8"),{options:e}=await(0,u.fire)("filter:api.options",{options:e}),e.data&&(e.body=e.data,delete e.data);const s=await fetch(i,e),{headers:d}=s;if(d.get("x-redirect"))return r({url:d.get("x-redirect"),...e});const w=d.get("content-type"),I=w&&w.startsWith("application/json");let _;if(e.method!=="HEAD"&&(I?_=await s.json():_=await s.text()),!s.ok){if(_){const A=I&&(_.status?.message||_.error||""),T=typeof _=="string"?_:s.statusText||`[[error:api.${s.status}]]`;throw new Error(I&&A?A:T)}throw new Error(s.statusText)}return I&&_&&_.hasOwnProperty("status")&&_.hasOwnProperty("response")?_.response:_}function g(e,i,s){return h({url:e+(i&&Object.keys(i).length?"?"+$.param(i):"")},s)}function t(e,i,s){return h({url:e+(i&&Object.keys(i).length?"?"+$.param(i):""),method:"HEAD"},s)}function n(e,i,s,d){return v("POST",e,i,s,d)}function f(e,i,s,d){return v("PATCH",e,i,s,d)}function p(e,i,s,d){return v("PUT",e,i,s,d)}function M(e,i,s,d){return v("DELETE",e,i,s,d)}function v(e,i,s,d,w){return typeof d=="function"&&(w=d,d={}),h({url:i,method:e,data:s,headers:{"x-csrf-token":config.csrf_token,...d}},w)}},65303(P,E,c){c.r(E),c.d(E,{alert:()=>y,confirm:()=>O,dialog:()=>a,prompt:()=>D,promptPassword:()=>h});var u=c(33530),m=c.n(u),o=c(17459),l=c.n(o);u.setDefaults({locale:config.userLang}),o.translateKeys(["modules:bootbox.ok","modules:bootbox.cancel","modules:bootbox.confirm"]).then(t=>{u.addLocale(config.userLang,{OK:t[0],CANCEL:t[1],CONFIRM:t[2]}),u.setLocale(config.userLang)});async function a(t){const[n,f,p]=await Promise.all([o.translate(t.title||""),r(t)||"",g(t.buttons)]);return u.dialog({...t,title:n,message:f,buttons:p})}async function y(t,n){const[f,p]=await Promise.all([t&&t.title?o.translate(t.title):null,r(t)]);return n=typeof n=="function"?n:t.callback,u.alert({...t,title:f,message:p,callback:n})}async function O(t,n){const[f,p]=await Promise.all([t&&t.title?o.translate(t.title):null,r(t)]);return n=typeof n=="function"?n:t.callback,u.confirm({...t,title:f,message:p,callback:n})}async function D(t,n){const[f,p]=await Promise.all([o.translate(typeof t=="string"?t:t.title),t&&t.message?r(t):null]);return n=typeof n=="function"?n:t.callback,u.prompt({...t,title:f,message:p,callback:n})}async function h(t){return typeof t=="string"&&(t={title:t}),t=t||{title:"[[user:current-password]]",message:"[[user:emailUpdate.password-challenge]]"},await new Promise(n=>{D({...t,inputType:"password",required:!0,value:"",callback:n})})}function r(t){const n=t&&t.message?t.message:t;return n instanceof jQuery?n:o.translate(n||"")}async function g(t){if(!Object.keys(t||{}).length)return;const n=Object.values(t);return await Promise.all(n.map(async f=>({...f,label:await o.translateKey(f.label)})))}},68636(P,E,c){var u;u=(function(){function m(){this._store={},this._keys=[]}m.prototype.isMock=!0,m.prototype.setItem=function(a,y){a=String(a),this._keys.indexOf(a)===-1&&this._keys.push(a),this._store[a]=y},m.prototype.getItem=function(a){return a=String(a),this._keys.indexOf(a)===-1?null:this._store[a]},m.prototype.removeItem=function(a){a=String(a),this._keys=this._keys.filter(function(y){return y!==a}),this._store[a]=null},m.prototype.clear=function(){this._keys=[],this._store={}},m.prototype.key=function(a){return a=parseInt(a,10)||0,this._keys[a]},Object.defineProperty&&Object.defineProperty(m.prototype,"length",{get:function(){return this._keys.length}});let o;const l=Date.now().toString();try{if(o=window.localStorage,o.setItem(l,l),o.getItem(l)!==l)throw Error("localStorage behaved unexpectedly");return o.removeItem(l),o}
1catch(a){console.warn(a),console.warn("localStorage failed, falling back on sessionStorage");try{if(o=window.sessionStorage,o.setItem(l,l),o.getItem(l)!==l)throw Error("sessionStorage behaved unexpectedly");return o.removeItem(l),o}catch(y){return console.warn(y),console.warn("sessionStorage failed, falling back on memory storage"),new m}}}).call(E,c,E,P),u!==void 0&&(P.exports=u)}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.