8:const $ = (sel, root) => (root || document).querySelector(sel); 9:const $$ = (sel, root) => Array.from((root || document).querySelectorAll(sel)); 10:function el(tag, attrs = {}, ...children) { 24:function esc(s) { 27:function debounce(fn, ms = 300) { 30:function fmtBytes(n) { 36:function fmtDT(iso) { 41:function fmtMoney(n) { 45:function plural(n, w) { return `${n} ${w}${n === 1 ? "" : "s"}`; } 48:const CSRF = { 51:function getCookie(name) { 96:const GET = p => api(p); 97:const POST = (p, json) => api(p, { method: "POST", json }); 99:function b64Blob(b64, mime) { 105:function dlBlob(blob, filename) { 112:const PATCH = (p, json) => api(p, { method: "PATCH", json }); 113:const PUT = (p, json) => api(p, { method: "PUT", json }); 114:const DEL = p => api(p, { method: "DELETE" }); 117:function toast(msg, kind = "info", ms = 4200) { 130:function openModal(title, bodyNode, { buttons = [], wide = false, xw = false, onClose } = {}) { 148:function confirmDialog(message, { title = "Are you sure?", danger = true, confirmLabel = "Confirm", onConfirm } = {}) { 175:const NAV = [