1import{i as h}from"./site.Cm1WcvMr.js";import"./preload-helper-C4y4BAWr.js";const f=".admin-forum-node",m=":scope > .admin-forum-node__details > .admin-forum-node__children > .admin-forum-node",p=":scope > .admin-forum-node__details",l="wasOpen";function y(t){return Array.from(t.querySelectorAll(m))}function A(t){return t.querySelector(p)}function d(t,e,o){const s=(t.dataset.searchText??"").includes(e)||o;let n=!1;for(const u of y(t))n=d(u,e,s)||n;const a=s||n;t.hidden=!a;const i=A(t);return i&&a&&(l in i.dataset||(i.dataset[l]=i.open?"1":"0"),i.open=!0),a}function w(t){for(const e of Array.from(t.querySelectorAll(f)))e.hidden=!1;for(const e of Array.from(t.querySelectorAll("details")))l in e.dataset&&(e.open=e.dataset[l]==="1",delete e.dataset[l])}function c(t,e){for(const o of Array.from(t.querySelectorAll("details")))o.open=e,delete o.dataset[l]}function S(t){const e=window.location.hash;if(!/^#forum-\d+$/.test(e))return;const o=t.querySelector(e);if(!o)return;let r=o.parentElement?.closest("details")??null;for(;r;)r.open=!0,r=r.parentElement?.closest("details")??null;o.classList.add("is-highlighted"),!h()&&o.scrollIntoView({block:"center",behavior:"instant"})}function q(t){t.data("adminForumTree",()=>({filter:"",noMatch:!1,init(){const e=this;e.$watch("filter",()=>e.apply()),S(e.$el)},apply(){const e=this,o=e.$refs.list;if(!o)return;const r=e.filter.trim().toLowerCase();if(r.length===0){w(o),e.noMatch=!1;return}let s=!1;for(const n of Array.from(o.querySelectorAll(`:scope > ${f}`)))s=d(n,r,!1)||s;e.noMatch=!s},clear(){const e=this;e.filter="",e.$refs.filter?.focus()}
1,expandAll(){const e=this.$refs.list;e&&c(e,!0)},collapseAll(){const e=this.$refs.list;e&&c(e,!1)}}))}export{q as registerAdminForumTree};
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.