1"use strict";(self.webpackChunknodebb=self.webpackChunknodebb||[]).push([[49888,99127,34271,69185,86198,1091,49897,28310],{28310:(A,y,l)=>{var g,m;g=[l(65348),l(29930),l(91749)],m=function(C,v,E){const i={};let a,t;i.init=function(e,o,n){a||(i.tids=e,i.currentCid=o,i.onComplete=n,i.moveAll=!e,r())};function r(){app.parseAndTranslate("modals/move-topic",{},function(e){a=e,$("body").append(a),(i.moveAll||i.tids&&i.tids.length>1)&&a.find(".card-header").translateText("[[topic:move-topics]]"),C.init(a.find('[component="category-selector"]'),{onSelect:f,privilege:"moderate"}),a.find("#move_thread_commit").on("click",c),a.find("#move_topic_cancel").on("click",s)})}function f(e){t=e,a.find("#move_thread_commit").prop("disabled",!1)}function c(){const e=a.find("#move_thread_commit");if(!e.prop("disabled")&&t&&t.cid){e.prop("disabled",!0),s();let o="[[topic:topic-move-success, "+t.name+"]]";i.tids&&i.tids.length>1?o="[[topic:topic-move-multiple-success, "+t.name+"]]":i.tids||(o="[[topic:topic-move-all-success, "+t.name+"]]");const n={tids:i.tids?i.tids.slice():null,cid:t.cid,currentCid:i.currentCid,onComplete:i.onComplete};if(config.undoTimeout>0)return v.alert({alert_id:"tids_move_"+(i.tids?i.tids.join("-"):"all"),title:"[[topic:thread-tools.move]]",message:o,type:"success",timeout:config.undoTimeout,timeoutfn:function(){u(n)},clickfn:function(d,h){delete h.timeoutfn,v.success("[[topic:topic-move-undone]]")}});u(n)}}function u(e){E.fire("action:topic.move",e),socket.emit(e.tids?"topics.move":"topics.moveAll",e,function(o){if(o)return v.error(o);typeof e.onComplete=="function"&&e.onComplete()})}function s(){a&&(a.remove(),a=null)}return i}.apply(y,g),m!==void 0&&(A.exports=m)},49897:(A,y,l)=>{l.r(y),l.d(y,{del:()=>s,get:()=>t,head:()=>r,patch:()=>c,post:()=>f,put:()=>u});var g=l(91749),m=l.n(g),C=l(40027),v=l.n(C);const E=config.relative_path+"/api/v3";async function i(e,o){if(e.url=e.url.startsWith("/api")?config.relative_path+e.url:E+e.url,typeof o=="function"){a(e).then(n=>o(null,n),n=>o(n));return}try{return await a(e)}catch(n){if(n.message==="A valid login session was not found. Please log in and try again."){const{url:d}=await(0,g.fire)("filter:admin.reauth",{url:"login"});return(0,C.confirm)("[[error:api.reauth-required]]",h=>{h&&ajaxify.go(d)})}throw n}}async function a(e){const{url:o}=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,g.fire)("filter:api.options",{options:e}),e.data&&(e.body=e.data,delete e.data);const n=await fetch(o,e),{headers:d}=n,h=d.get("content-type"),w=h&&h.startsWith("application/json");let p;if(e.method!=="HEAD"&&(w?p=await n.json():p=await n.text()),!n.ok)throw p?new Error(w?p.status.message:p):new Error(n.statusText);return w&&p&&p.hasOwnProperty("status")&&p.hasOwnProperty("response")?p.response:p}function t(e,o,n){return i({url:e+(o&&Object.keys(o).length?"?"+$.param(o):"")},n)}function r(e,o,n){return i({url:e+(o&&Object.keys(o).length?"?"+$.param(o):""),method:"HEAD"},n)}function f(e,o,n){return i({url:e,method:"POST",data:o,headers:{"x-csrf-token":config.csrf_token}},n)}function c(e,o,n){return i({url:e,method:"PATCH",data:o,headers:{"x-csrf-token":config.csrf_token}},n)}function u(e,o,n){return i({url:e,method:"PUT",data:o,headers:{"x-csrf-token":config.csrf_token}},n)}function s(e,o,n){return i({url:e,method:"DELETE",data:o,headers:{"x-csrf-token":config.csrf_token}},n)}},96349:(A,y,l)=>{var g,m;g=[l(29930),l(89336),l(49897)],m=function(C,v,E){const i={};return i.init=function(a,t){let r=null;t=t||{},t.privilege=t.privilege||"topics:read",t.states=t.states||["watching","tracking","notwatching","ignoring"],t.cacheList=t.hasOwnProperty("cacheList")?t.cacheList:!0;let f=[];Array.isArray(t.localCategories)&&(f=t.localCategories.map(o=>({...o}))),t.selectedCids=t.selectedCids||ajaxify.data.selectedCids||[];const c=a.find('[component="category-selector-search"]');if(!c.length)return;const u=c.parent('[component="category/dropdown"]').length>0||c.parent('[component="category-selector"]').length>0;a.on("show.bs.dropdown",function(){u&&(a.find(".dropdown-toggle").
1css({visibility:"hidden"}),c.removeClass("hidden"),c.css({"z-index":a.find(".dropdown-toggle").css("z-index")+1}));function o(){const n=c.find("input").val();n.length>1||!n&&!r?s(n,function(d){r=t.cacheList&&(r||d),e(d)}):!n&&r&&e(r)}c.on("click",function(n){n.preventDefault(),n.stopPropagation()}),c.find("input").val("").on("keyup",utils.debounce(o,300)),o()}),a.on("shown.bs.dropdown",function(){["xs","sm"].includes(utils.findBootstrapEnvironment())||c.find("input").focus()}),a.on("hide.bs.dropdown",function(){u&&(a.find(".dropdown-toggle").css({visibility:"inherit"}),c.addClass("hidden")),c.off("click"),c.find("input").off("keyup")});function s(o,n){E.get("/search/categories",{search:o,query:utils.params(),parentCid:t.parentCid||0,selectedCids:t.selectedCids,privilege:t.privilege,states:t.states,showLinks:t.showLinks},function(d,{categories:h}){if(d)return C.error(d);n(f.concat(h))})}function e(o){const n=t.selectedCids.map(String);o.forEach(function(d){d.selected=n.includes(String(d.cid))}),app.parseAndTranslate(t.template,{categoryItems:o.slice(0,200),selectedCategory:ajaxify.data.selectedCategory,allCategoriesUrl:ajaxify.data.allCategoriesUrl},function(d){a.find('[component="category/list"]').html(d.find('[component="category/list"]').html()),a.find('[component="category/list"] [component="category/no-matches"]').toggleClass("hidden",!!o.length);const h=v.Dropdown.getInstance(a.find(".dropdown-toggle").get(0));h&&h.update()})}},i}.apply(y,g),m!==void 0&&(A.exports=m)},65348:(A,y,l)=>{var g,m;g=[l(96349),l(40027),l(91749),l(17459)],m=function(C,v,E,i){const a={};return a.init=function(t,r){if(!t||!t.length)return;r=r||{};const f=r.onSelect||function(){};r.states=r.states||["watching","tracking","notwatching","ignoring"],r.template=r.template||"partials/category/selector-dropdown-left",E.fire("action:category.selector.options",{el:t,options:r}),C.init(t,r);const c={el:t,selectedCategory:null};t.on("click","[data-cid]",function(){const s=$(this);return s.hasClass("disabled")?!1:(c.selectCategory(s.attr("data-cid")),f(c.selectedCategory))});let u=c.el.find('[component="category-selector-selected"]').html();return i.translate(u,s=>{u=s}),c.selectCategory=function(s){const e=c.el.find('[data-cid="'+s+'"]');c.selectedCategory={cid:s,name:e.attr("data-name")},e.length?c.el.find('[component="category-selector-selected"]').html(e.find('[component="category-markup"]').html()):c.el.find('[component="category-selector-selected"]').html(u)},c.getSelectedCategory=function(){return c.selectedCategory},c.getSelectedCid=function(){return c.selectedCategory?c.selectedCategory.cid:0},r.hasOwnProperty("selectedCategory")&&app.parseAndTranslate(r.template,{selectedCategory:r.selectedCategory},function(s){c.el.find('[component="category-selector-selected"]').html(s.find('[component="category-selector-selected"]').html())}),c},a.modal=function(t){t=t||{},t.onSelect=t.onSelect||function(){},t.onSubmit=t.onSubmit||function(){},app.parseAndTranslate("admin/partials/categories/select-category",{message:t.message},function(r){const f=v.dialog({title:t.title||"[[modules:composer.select-category]]",message:r,buttons:{save:{label:"[[global:select]]",className:"btn-primary",callback:u}}}),c=a.init(f.find('[component="category-selector"]'),t);function u(s){return s.preventDefault(),c.selectedCategory&&(t.onSubmit(c.selectedCategory),f.modal("hide")),!1}t.openOnLoad&&f.on("shown.bs.modal",function(){f.find(".dropdown-toggle").dropdown("toggle")}),f.find("form").on("submit",u)})},a}.apply(y,g),m!==void 0&&(A.exports=m)}}]);
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.