@livenetworks/ashlar 2.2.0 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/brand/android-chrome-192x192.png +0 -0
- package/assets/brand/android-chrome-512x512.png +0 -0
- package/assets/brand/apple-touch-icon.png +0 -0
- package/assets/brand/favicon-16x16.png +0 -0
- package/assets/brand/favicon-32x32.png +0 -0
- package/assets/brand/favicon-48x48.png +0 -0
- package/assets/brand/favicon-dark-128x128.png +0 -0
- package/assets/brand/favicon-dark-16x16.png +0 -0
- package/assets/brand/favicon-dark-180x180.png +0 -0
- package/assets/brand/favicon-dark-192x192.png +0 -0
- package/assets/brand/favicon-dark-256x256.png +0 -0
- package/assets/brand/favicon-dark-32x32.png +0 -0
- package/assets/brand/favicon-dark-48x48.png +0 -0
- package/assets/brand/favicon-dark-512x512.png +0 -0
- package/assets/brand/favicon-dark-64x64.png +0 -0
- package/assets/brand/favicon-dark.ico +0 -0
- package/assets/brand/favicon-dark.png +0 -0
- package/assets/brand/favicon-light-128x128.png +0 -0
- package/assets/brand/favicon-light-16x16.png +0 -0
- package/assets/brand/favicon-light-180x180.png +0 -0
- package/assets/brand/favicon-light-192x192.png +0 -0
- package/assets/brand/favicon-light-256x256.png +0 -0
- package/assets/brand/favicon-light-32x32.png +0 -0
- package/assets/brand/favicon-light-48x48.png +0 -0
- package/assets/brand/favicon-light-512x512.png +0 -0
- package/assets/brand/favicon-light-64x64.png +0 -0
- package/assets/brand/favicon-light.ico +0 -0
- package/assets/brand/favicon-light.png +0 -0
- package/assets/brand/favicon.ico +0 -0
- package/assets/brand/favicon.png +0 -0
- package/assets/brand/favicon.svg +12 -0
- package/assets/brand/ln-ashlar-emblem-dark-128.png +0 -0
- package/assets/brand/ln-ashlar-emblem-dark-16.png +0 -0
- package/assets/brand/ln-ashlar-emblem-dark-256.png +0 -0
- package/assets/brand/ln-ashlar-emblem-dark-32.png +0 -0
- package/assets/brand/ln-ashlar-emblem-dark-64.png +0 -0
- package/assets/brand/ln-ashlar-emblem-dark.png +0 -0
- package/assets/brand/ln-ashlar-emblem-light-128.png +0 -0
- package/assets/brand/ln-ashlar-emblem-light-16.png +0 -0
- package/assets/brand/ln-ashlar-emblem-light-256.png +0 -0
- package/assets/brand/ln-ashlar-emblem-light-32.png +0 -0
- package/assets/brand/ln-ashlar-emblem-light-64.png +0 -0
- package/assets/brand/ln-ashlar-emblem-light.png +0 -0
- package/assets/brand/ln-ashlar-logo-dark-128.png +0 -0
- package/assets/brand/ln-ashlar-logo-dark-256.png +0 -0
- package/assets/brand/ln-ashlar-logo-dark-512.png +0 -0
- package/assets/brand/ln-ashlar-logo-dark.png +0 -0
- package/assets/brand/ln-ashlar-logo-light-128.png +0 -0
- package/assets/brand/ln-ashlar-logo-light-256.png +0 -0
- package/assets/brand/ln-ashlar-logo-light-512.png +0 -0
- package/assets/brand/ln-ashlar-logo-light.png +0 -0
- package/assets/brand/site.webmanifest +41 -0
- package/assets/brand/source/ln-ashlar-icon-dark-1024.png +0 -0
- package/assets/brand/source/ln-ashlar-icon-dark-uncropped-1024.png +0 -0
- package/assets/brand/source/ln-ashlar-icon-light-1024.png +0 -0
- package/assets/brand/source/ln-ashlar-icon-light-uncropped-1024.png +0 -0
- package/assets/flags/ad.svg +150 -0
- package/assets/flags/ae.svg +6 -0
- package/assets/flags/af.svg +81 -0
- package/assets/flags/ag.svg +14 -0
- package/assets/flags/ai.svg +29 -0
- package/assets/flags/al.svg +5 -0
- package/assets/flags/am.svg +5 -0
- package/assets/flags/ao.svg +13 -0
- package/assets/flags/aq.svg +5 -0
- package/assets/flags/ar.svg +32 -0
- package/assets/flags/arab.svg +109 -0
- package/assets/flags/as.svg +72 -0
- package/assets/flags/asean.svg +13 -0
- package/assets/flags/at.svg +4 -0
- package/assets/flags/au.svg +8 -0
- package/assets/flags/aw.svg +186 -0
- package/assets/flags/ax.svg +18 -0
- package/assets/flags/az.svg +8 -0
- package/assets/flags/ba.svg +12 -0
- package/assets/flags/bb.svg +6 -0
- package/assets/flags/bd.svg +4 -0
- package/assets/flags/be.svg +7 -0
- package/assets/flags/bf.svg +7 -0
- package/assets/flags/bg.svg +5 -0
- package/assets/flags/bh.svg +4 -0
- package/assets/flags/bi.svg +15 -0
- package/assets/flags/bj.svg +14 -0
- package/assets/flags/bl.svg +5 -0
- package/assets/flags/bm.svg +97 -0
- package/assets/flags/bn.svg +36 -0
- package/assets/flags/bo.svg +673 -0
- package/assets/flags/bq.svg +5 -0
- package/assets/flags/br.svg +45 -0
- package/assets/flags/bs.svg +13 -0
- package/assets/flags/bt.svg +89 -0
- package/assets/flags/bv.svg +13 -0
- package/assets/flags/bw.svg +7 -0
- package/assets/flags/by.svg +18 -0
- package/assets/flags/bz.svg +145 -0
- package/assets/flags/ca.svg +4 -0
- package/assets/flags/cc.svg +19 -0
- package/assets/flags/cd.svg +5 -0
- package/assets/flags/cefta.svg +13 -0
- package/assets/flags/cf.svg +15 -0
- package/assets/flags/cg.svg +12 -0
- package/assets/flags/ch.svg +9 -0
- package/assets/flags/ci.svg +7 -0
- package/assets/flags/ck.svg +9 -0
- package/assets/flags/cl.svg +13 -0
- package/assets/flags/cm.svg +15 -0
- package/assets/flags/cn.svg +11 -0
- package/assets/flags/co.svg +7 -0
- package/assets/flags/cp.svg +7 -0
- package/assets/flags/cr.svg +7 -0
- package/assets/flags/cu.svg +13 -0
- package/assets/flags/cv.svg +13 -0
- package/assets/flags/cw.svg +14 -0
- package/assets/flags/cx.svg +15 -0
- package/assets/flags/cy.svg +6 -0
- package/assets/flags/cz.svg +5 -0
- package/assets/flags/de.svg +5 -0
- package/assets/flags/dg.svg +130 -0
- package/assets/flags/dj.svg +13 -0
- package/assets/flags/dk.svg +5 -0
- package/assets/flags/dm.svg +152 -0
- package/assets/flags/do.svg +121 -0
- package/assets/flags/dz.svg +5 -0
- package/assets/flags/eac.svg +48 -0
- package/assets/flags/ec.svg +138 -0
- package/assets/flags/ee.svg +5 -0
- package/assets/flags/eg.svg +38 -0
- package/assets/flags/eh.svg +16 -0
- package/assets/flags/er.svg +8 -0
- package/assets/flags/es-ct.svg +4 -0
- package/assets/flags/es-ga.svg +187 -0
- package/assets/flags/es-pv.svg +5 -0
- package/assets/flags/es.svg +544 -0
- package/assets/flags/et.svg +14 -0
- package/assets/flags/eu.svg +28 -0
- package/assets/flags/fi.svg +5 -0
- package/assets/flags/fj.svg +120 -0
- package/assets/flags/fk.svg +90 -0
- package/assets/flags/fm.svg +11 -0
- package/assets/flags/fo.svg +12 -0
- package/assets/flags/fr.svg +5 -0
- package/assets/flags/ga.svg +7 -0
- package/assets/flags/gb-eng.svg +5 -0
- package/assets/flags/gb-nir.svg +132 -0
- package/assets/flags/gb-sct.svg +4 -0
- package/assets/flags/gb-wls.svg +9 -0
- package/assets/flags/gb.svg +7 -0
- package/assets/flags/gd.svg +27 -0
- package/assets/flags/ge.svg +6 -0
- package/assets/flags/gf.svg +5 -0
- package/assets/flags/gg.svg +9 -0
- package/assets/flags/gh.svg +6 -0
- package/assets/flags/gi.svg +32 -0
- package/assets/flags/gl.svg +4 -0
- package/assets/flags/gm.svg +14 -0
- package/assets/flags/gn.svg +7 -0
- package/assets/flags/gp.svg +5 -0
- package/assets/flags/gq.svg +23 -0
- package/assets/flags/gr.svg +16 -0
- package/assets/flags/gs.svg +133 -0
- package/assets/flags/gt.svg +204 -0
- package/assets/flags/gu.svg +19 -0
- package/assets/flags/gw.svg +13 -0
- package/assets/flags/gy.svg +9 -0
- package/assets/flags/hk.svg +8 -0
- package/assets/flags/hm.svg +8 -0
- package/assets/flags/hn.svg +18 -0
- package/assets/flags/hr.svg +58 -0
- package/assets/flags/ht.svg +116 -0
- package/assets/flags/hu.svg +7 -0
- package/assets/flags/ic.svg +7 -0
- package/assets/flags/id.svg +4 -0
- package/assets/flags/ie.svg +7 -0
- package/assets/flags/il.svg +14 -0
- package/assets/flags/im.svg +36 -0
- package/assets/flags/in.svg +25 -0
- package/assets/flags/io.svg +130 -0
- package/assets/flags/iq.svg +10 -0
- package/assets/flags/ir.svg +219 -0
- package/assets/flags/is.svg +12 -0
- package/assets/flags/it.svg +7 -0
- package/assets/flags/je.svg +62 -0
- package/assets/flags/jm.svg +8 -0
- package/assets/flags/jo.svg +16 -0
- package/assets/flags/jp.svg +11 -0
- package/assets/flags/ke.svg +23 -0
- package/assets/flags/kg.svg +4 -0
- package/assets/flags/kh.svg +61 -0
- package/assets/flags/ki.svg +36 -0
- package/assets/flags/km.svg +16 -0
- package/assets/flags/kn.svg +14 -0
- package/assets/flags/kp.svg +15 -0
- package/assets/flags/kr.svg +24 -0
- package/assets/flags/kw.svg +13 -0
- package/assets/flags/ky.svg +103 -0
- package/assets/flags/kz.svg +36 -0
- package/assets/flags/la.svg +12 -0
- package/assets/flags/lb.svg +15 -0
- package/assets/flags/lc.svg +8 -0
- package/assets/flags/li.svg +43 -0
- package/assets/flags/lk.svg +22 -0
- package/assets/flags/lr.svg +14 -0
- package/assets/flags/ls.svg +8 -0
- package/assets/flags/lt.svg +7 -0
- package/assets/flags/lu.svg +5 -0
- package/assets/flags/lv.svg +6 -0
- package/assets/flags/ly.svg +13 -0
- package/assets/flags/ma.svg +4 -0
- package/assets/flags/mc.svg +6 -0
- package/assets/flags/md.svg +70 -0
- package/assets/flags/me.svg +116 -0
- package/assets/flags/mf.svg +5 -0
- package/assets/flags/mg.svg +7 -0
- package/assets/flags/mh.svg +7 -0
- package/assets/flags/mk.svg +5 -0
- package/assets/flags/ml.svg +7 -0
- package/assets/flags/mm.svg +12 -0
- package/assets/flags/mn.svg +14 -0
- package/assets/flags/mo.svg +9 -0
- package/assets/flags/mp.svg +86 -0
- package/assets/flags/mq.svg +5 -0
- package/assets/flags/mr.svg +6 -0
- package/assets/flags/ms.svg +29 -0
- package/assets/flags/mt.svg +58 -0
- package/assets/flags/mu.svg +8 -0
- package/assets/flags/mv.svg +6 -0
- package/assets/flags/mw.svg +10 -0
- package/assets/flags/mx.svg +382 -0
- package/assets/flags/my.svg +26 -0
- package/assets/flags/mz.svg +21 -0
- package/assets/flags/na.svg +16 -0
- package/assets/flags/nc.svg +13 -0
- package/assets/flags/ne.svg +6 -0
- package/assets/flags/nf.svg +9 -0
- package/assets/flags/ng.svg +6 -0
- package/assets/flags/ni.svg +129 -0
- package/assets/flags/nl.svg +5 -0
- package/assets/flags/no.svg +7 -0
- package/assets/flags/np.svg +13 -0
- package/assets/flags/nr.svg +12 -0
- package/assets/flags/nu.svg +10 -0
- package/assets/flags/nz.svg +36 -0
- package/assets/flags/om.svg +115 -0
- package/assets/flags/pa.svg +14 -0
- package/assets/flags/pc.svg +33 -0
- package/assets/flags/pe.svg +4 -0
- package/assets/flags/pf.svg +19 -0
- package/assets/flags/pg.svg +9 -0
- package/assets/flags/ph.svg +6 -0
- package/assets/flags/pk.svg +15 -0
- package/assets/flags/pl.svg +6 -0
- package/assets/flags/pm.svg +5 -0
- package/assets/flags/pn.svg +53 -0
- package/assets/flags/pr.svg +13 -0
- package/assets/flags/ps.svg +6 -0
- package/assets/flags/pt.svg +57 -0
- package/assets/flags/pw.svg +11 -0
- package/assets/flags/py.svg +157 -0
- package/assets/flags/qa.svg +4 -0
- package/assets/flags/re.svg +5 -0
- package/assets/flags/ro.svg +7 -0
- package/assets/flags/rs.svg +292 -0
- package/assets/flags/ru.svg +5 -0
- package/assets/flags/rw.svg +13 -0
- package/assets/flags/sa.svg +25 -0
- package/assets/flags/sb.svg +13 -0
- package/assets/flags/sc.svg +7 -0
- package/assets/flags/sd.svg +13 -0
- package/assets/flags/se.svg +4 -0
- package/assets/flags/sg.svg +13 -0
- package/assets/flags/sh-ac.svg +689 -0
- package/assets/flags/sh-hl.svg +164 -0
- package/assets/flags/sh-ta.svg +76 -0
- package/assets/flags/sh.svg +7 -0
- package/assets/flags/si.svg +18 -0
- package/assets/flags/sj.svg +7 -0
- package/assets/flags/sk.svg +9 -0
- package/assets/flags/sl.svg +7 -0
- package/assets/flags/sm.svg +75 -0
- package/assets/flags/sn.svg +8 -0
- package/assets/flags/so.svg +11 -0
- package/assets/flags/sr.svg +6 -0
- package/assets/flags/ss.svg +8 -0
- package/assets/flags/st.svg +16 -0
- package/assets/flags/sv.svg +593 -0
- package/assets/flags/sx.svg +56 -0
- package/assets/flags/sy.svg +6 -0
- package/assets/flags/sz.svg +34 -0
- package/assets/flags/tc.svg +50 -0
- package/assets/flags/td.svg +7 -0
- package/assets/flags/tf.svg +15 -0
- package/assets/flags/tg.svg +14 -0
- package/assets/flags/th.svg +7 -0
- package/assets/flags/tj.svg +22 -0
- package/assets/flags/tk.svg +5 -0
- package/assets/flags/tl.svg +13 -0
- package/assets/flags/tm.svg +204 -0
- package/assets/flags/tn.svg +4 -0
- package/assets/flags/to.svg +10 -0
- package/assets/flags/tr.svg +8 -0
- package/assets/flags/tt.svg +5 -0
- package/assets/flags/tv.svg +9 -0
- package/assets/flags/tw.svg +34 -0
- package/assets/flags/tz.svg +13 -0
- package/assets/flags/ua.svg +6 -0
- package/assets/flags/ug.svg +30 -0
- package/assets/flags/um.svg +9 -0
- package/assets/flags/un.svg +16 -0
- package/assets/flags/us.svg +9 -0
- package/assets/flags/uy.svg +28 -0
- package/assets/flags/uz.svg +30 -0
- package/assets/flags/va.svg +190 -0
- package/assets/flags/vc.svg +8 -0
- package/assets/flags/ve.svg +26 -0
- package/assets/flags/vg.svg +59 -0
- package/assets/flags/vi.svg +28 -0
- package/assets/flags/vn.svg +11 -0
- package/assets/flags/vu.svg +21 -0
- package/assets/flags/wf.svg +5 -0
- package/assets/flags/ws.svg +7 -0
- package/assets/flags/xk.svg +5 -0
- package/assets/flags/xx.svg +4 -0
- package/assets/flags/ye.svg +7 -0
- package/assets/flags/yt.svg +5 -0
- package/assets/flags/za.svg +17 -0
- package/assets/flags/zm.svg +27 -0
- package/assets/flags/zw.svg +21 -0
- package/components/ln-data-coordinator/ln-data-coordinator.js +1 -1
- package/components/ln-date/ln-date.js +1 -1
- package/components/ln-debug/ln-debug.js +1 -1
- package/components/ln-debug/src/generated-attributes.js +306 -304
- package/components/ln-external-links/ln-external-links.js +1 -1
- package/components/ln-filter/ln-filter.js +1 -1
- package/components/ln-obfuscator/ln-obfuscator.js +1 -1
- package/components/ln-sort/ln-sort.js +1 -1
- package/components/ln-table/ln-table.js +1 -1
- package/components/ln-table-coordinator/ln-table-coordinator.js +1 -1
- package/components/ln-toast/ln-toast.js +1 -1
- package/components/ln-translations/README.md +202 -120
- package/components/ln-translations/ln-translations.js +1 -1
- package/components/ln-translations/ln-translations.schema.json +136 -120
- package/components/ln-translations/src/ln-translations.js +354 -295
- package/components/ln-translations/src/translations-model.js +221 -0
- package/components/ln-validate/ln-validate.js +1 -1
- package/ln-ashlar.html-data.json +1832 -1824
- package/package.json +96 -95
- package/theme/components/_translations.scss +118 -111
- package/theme/config/mixins/_app-shell.scss +14 -0
- package/theme/config/mixins/_count.scss +48 -0
- package/theme/config/mixins/_index.scss +1 -0
- package/theme/config/mixins/_nav.scss +3 -11
- package/theme/config/mixins/_translations.scss +126 -124
- package/web-types.json +2365 -2351
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(){"use strict";function J(){if(typeof window>"u")return!1;if(window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink)return!0;if(typeof document<"u"){if(document.documentElement&&document.documentElement.hasAttribute("data-ln-debug"))return!0;if(document.body)return document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null}return!1}function D(e){if(typeof window>"u")return!1;if(window.lnDebug===!0)return!0;if(window.lnCore&&window.lnCore._debugIsContained)return e?window.lnCore._debugIsContained(e):window.lnCore._debugSink!==null;if(e&&e.closest){const t=e.closest("[data-ln-debug]");return!(!t||typeof document<"u"&&t===document.documentElement)}return typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug"):!1}if(typeof window<"u"&&(window.lnCore=window.lnCore||{},!window.lnCore._warnBound)){window.lnCore._warnBound=!0;const e=console.warn;console.warn=function(...t){if(typeof t[0]=="string"&&(t[0].startsWith("[ln-")||t[0].startsWith("[lnCore"))){let r=null;for(let i=1;i<t.length;i++)if(t[i]&&t[i].nodeType===1){r=t[i];break}if(!D(r))return}e.apply(console,t)}}function _e(e,t,n){const r=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,r),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:r}))}function R(e,t,n){const r=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,r);const i=new CustomEvent(t,{bubbles:!0,cancelable:!0,detail:r});return e.dispatchEvent(i),i}function k(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){k(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}function F(e){return e.hasAttribute("value")?e.getAttribute("value"):e.hasAttribute("data-ln-value")?e.getAttribute("data-ln-value"):e.tagName==="TIME"&&e.hasAttribute("datetime")?e.getAttribute("datetime"):e.textContent.trim()}function Se(e){const t=e.querySelector('input[name="_method"]');return((t&&t.value!==""?t.value:e.method)||"").toUpperCase()}function ve(e,t){const n=!!(t&&t.typed),r=t&&t.exclude,i={},c=e.elements,l={};if(n)for(let u=0;u<c.length;u++){const o=c[u];o.name&&o.type==="checkbox"&&!o.disabled&&(l[o.name]=(l[o.name]||0)+1)}for(let u=0;u<c.length;u++){const o=c[u];if(!(!o.name||o.disabled||o.type==="file"||o.type==="submit"||o.type==="button")&&!(r&&o.matches&&o.matches(r)))if(o.type==="checkbox")n&&l[o.name]===1?i[o.name]=o.checked:(i[o.name]||(i[o.name]=[]),o.checked&&i[o.name].push(o.value));else if(o.type==="radio")o.checked&&(i[o.name]=o.value);else if(o.type==="select-multiple"){i[o.name]=[];for(let a=0;a<o.options.length;a++)o.options[a].selected&&i[o.name].push(o.options[a].value)}else if(n&&o.type==="hidden")i[o.name]=o.value;else if(n&&(o.type==="number"||o.type==="range")){const a=Number(o.value);i[o.name]=o.value===""||isNaN(a)?null:a}else i[o.name]=o.value}return i}function Ee(e){if(typeof e!="string")return!!e;const t=e.trim().toLowerCase();return t!=="false"&&t!=="0"&&t!==""&&t!=="off"&&t!=="no"}function xe(e,t){const n=e.elements,r=[],i={};for(let c=0;c<n.length;c++){const l=n[c];l.name&&l.type==="checkbox"&&(i[l.name]=(i[l.name]||0)+1)}for(let c=0;c<n.length;c++){const l=n[c];if(l.type==="file"||l.type==="submit"||l.type==="button")continue;const u=l.getAttribute("data-ln-fill-as")||l.name;if(!u||!(u in t))continue;const o=t[u];if(l.type==="checkbox"){if(Array.isArray(o))l.checked=o.indexOf(l.value)!==-1;else if(i[l.name]>1){const a=String(o).split(",").map(function(h){return h.trim()});l.checked=a.indexOf(l.value)!==-1}else l.checked=Ee(o);r.push(l)}else if(l.type==="radio")l.checked=l.value===String(o),r.push(l);else if(l.type==="select-multiple"){if(Array.isArray(o))for(let a=0;a<l.options.length;a++)l.options[a].selected=o.indexOf(l.options[a].value)!==-1;r.push(l)}else l.value=o,l.tagName==="SELECT"&&o!=null&&l.setAttribute("data-ln-value",o),r.push(l)}return r}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.populateForm=xe,window.lnCore.serializeForm=ve,window.lnCore.resolveFormMethod=Se);const G={};function ke(e,t){G[e]=t}function qe(e){return G[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=ke,window.lnCore.getDataMapper=qe);function Le(e){const t=e?e.closest("[lang]"):null,n=(t?t.getAttribute("lang")||t.lang:null)||(typeof document<"u"&&document.documentElement?document.documentElement.getAttribute("lang")||document.documentElement.lang:null)||(typeof navigator<"u"?navigator.language:null);return n?n.trim():"en-US"}function Ie(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,k(function(){new MutationObserver(function(){_e(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const X={};function Te(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];X[n]=t}function Oe(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return X[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=Te,window.lnCore.getLocaleFallback=Oe,window.lnCore.ensureLocaleObserver=Ie);const N={};function De(e,t){N[e]||(N[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=N[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function Y(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let l=0;l<n.length;l++){const u=n[l],o=u.getAttribute("data-ln-field");t[o]!=null&&(u.textContent=t[o])}const r=e.querySelectorAll("[data-ln-attr]");for(let l=0;l<r.length;l++){const u=r[l],o=u.getAttribute("data-ln-attr").split(",");for(let a=0;a<o.length;a++){const h=o[a].trim().split(":");if(h.length!==2)continue;const p=h[0].trim(),A=h[1].trim();t[A]!=null&&u.setAttribute(p,t[A])}}const i=e.querySelectorAll("[data-ln-show]");for(let l=0;l<i.length;l++){const u=i[l],o=u.getAttribute("data-ln-show");o in t&&u.classList.toggle("hidden",!t[o])}const c=e.querySelectorAll("[data-ln-class]");for(let l=0;l<c.length;l++){const u=c[l],o=u.getAttribute("data-ln-class").split(",");for(let a=0;a<o.length;a++){const h=o[a].trim().split(":");if(h.length!==2)continue;const p=h[0].trim(),A=h[1].trim();A in t&&u.classList.toggle(p,!!t[A])}}return e}function Re(e,t){e.matches&&e.matches("[data-ln-form], [data-ln-fillable]")&&(window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",e,t??null),e.dispatchEvent(new CustomEvent("ln-fill",{detail:t??null,bubbles:!0})));const n=e.querySelectorAll("[data-ln-form], [data-ln-fillable]");for(let r=0;r<n.length;r++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[r],t??null),n[r].dispatchEvent(new CustomEvent("ln-fill",{detail:t??null,bubbles:!0}));return e}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._fillBound||(window.lnCore._fillBound=!0,document.addEventListener("ln-fill",function(e){if(!(!e.target.matches||!e.target.matches("[data-ln-fillable]")))if(e.detail)Y(e.target,e.detail);else{const t=e.target.querySelectorAll("[data-ln-field]");for(let n=0;n<t.length;n++)t[n].textContent=""}})));function Z(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const c=n.currentNode;c.textContent.indexOf("{{")!==-1&&(c.textContent=c.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(l,u){return t[u]!==void 0?t[u]:""}))}const r=function(c,l){return t[l]!==void 0?t[l]:""},i=Array.from(e.querySelectorAll("*"));e.nodeType===1&&i.push(e);for(let c=0;c<i.length;c++){const l=i[c],u=l.attributes;for(let o=0;o<u.length;o++){const a=u[o];a.value.indexOf("{{")!==-1&&l.setAttribute(a.name,a.value.replace(/\{\{\s*(\w+)\s*\}\}/g,r))}}return e}function Fe(e,t,n,r,i,c){const l={};for(let o=0;o<e.children.length;o++){const a=e.children[o],h=a.getAttribute("data-ln-render-key");h&&(l[h]=a)}const u=document.createDocumentFragment();for(let o=0;o<t.length;o++){const a=t[o],h=String(r(a));let p=l[h];if(p)i(p,a,o);else{const A=De(n,c);if(!A||(Z(A,a),p=A.firstElementChild,!p))continue;p.setAttribute("data-ln-render-key",h),i(p,a,o)}u.appendChild(p)}e.textContent="",e.appendChild(u)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=Z,window.lnCore.fill=Y,window.lnCore.lnFill=Re,window.lnCore.renderList=Fe);function q(e,t,n){const r=e.getAttribute(t);return r===null?n:r}function ee(e,t,n){const r=parseInt(e.getAttribute(t),10);return isNaN(r)?n:r}function te(e,t,n=!1){const r=e.getAttribute(t);if(r===null)return!!n;const i=r.trim().toLowerCase();return!(i==="false"||i==="0")}function ne(e,t){return(e.getAttribute(t)||"").split(",").map(n=>n.trim()).filter(Boolean)}const $=new Map;function re(e,t){const n=(e?e.join("|"):"")+"::"+t;if($.has(n))return $.get(n);const r=new Set(e||[]),i=function(c,l){const u=c.getAttribute(l);return u!==null&&r.has(u)?u:t};return $.set(n,i),i}function oe(e,t,n){const r=parseFloat(e.getAttribute(t));return isNaN(r)?n:r}function ie(e,t,n){const r=e.getAttribute(t);if(!r)return n;try{return JSON.parse(r)}catch{return n}}function le(e,t,n,r,i){if(!e||t===null)return!0;const c=r||"ln-component",l=e.type;if(l==="trigger"||l==="marker"||l==="string"||l==="list"||!l||t===""&&e.fallback!==void 0)return!0;const u=o=>{i?console.warn(o,i):console.warn(o)};if(l==="boolean"){const o=t.trim().toLowerCase();return o!==""&&o!=="true"&&o!=="false"&&o!=="1"&&o!=="0"?(u(`[${c}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(l==="enum"){const o=e.values||[];return o.includes(t)?!0:(u(`[${c}] Invalid value "${t}" for attribute "${n}". Allowed: ${o.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(l==="integer"){if(!/^-?\d+$/.test(t))return u(`[${c}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const o=parseInt(t,10);return e.min!==void 0&&o<e.min?(u(`[${c}] Value ${o} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&o>e.max?(u(`[${c}] Value ${o} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(l==="float")return isNaN(Number(t))?(u(`[${c}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(l==="json")try{return JSON.parse(t),!0}catch(o){return u(`[${c}] Invalid JSON for attribute "${n}": ${o.message}. Fallback: ${e.fallback}.`),!1}return!0}function se(e,t,n){for(const r in n){const[i,c,l]=n[r];Object.defineProperty(e,r,{get:function(){return i(t,c,l)},enumerable:!0,configurable:!0})}return e}function ce(e){const t={};for(const n in e){const r=e[n];if(!r||!r.prop)continue;let i=r.read;if(!i&&r.type)switch(r.type){case"enum":i=re(r.values,r.fallback);break;case"integer":i=ee;break;case"float":i=oe;break;case"boolean":i=te;break;case"list":i=ne;break;case"json":i=ie;break;case"string":default:i=q;break}i||(i=q),t[r.prop]=[i,n,r.fallback]}return t}function Ne(e){const t={};for(const n in e){const r=e[n];r&&r.effect&&(t[n]=r.effect)}return Object.keys(t).length?t:null}function $e(e){if(e.onAttrChange&&!e.declared)return null;const t=new Set;if(e.effects)for(const n in e.effects)t.add(n);if(e.onAttrChange&&e.declared)for(const n of e.declared)t.add(n);return t}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.defineAttrs=se,window.lnCore.attrSpec=ce,window.lnCore.attrStr=q,window.lnCore.attrInt=ee,window.lnCore.attrBool=te,window.lnCore.attrList=ne,window.lnCore.attrEnum=re,window.lnCore.attrFloat=oe,window.lnCore.attrJson=ie);function L(e,t){if(!e[t.attribute]){window.lnCore._persistSink&&e.hasAttribute&&e.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(e,t.selector);try{e[t.attribute]=new t.ComponentFn(e)}catch(n){console.error("["+t.attribute+"] init failed",e,n)}}}function ue(e,t,n,r){if(e.nodeType!==1)return;const c=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",l={selector:t,attribute:n,ComponentFn:r};if(e.matches&&e.matches(c)&&L(e,l),e.querySelectorAll){const u=e.querySelectorAll(c);for(let o=0;o<u.length;o++)L(u[o],l)}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function Be(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function I(e){typeof window<"u"?(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[],window.lnCore._bootHolds>0?window.lnCore._bootQueue.push(e):setTimeout(e,0)):e()}function ae(){window.lnCore=window.lnCore||{};const e=window.lnCore._attrRegistry=window.lnCore._attrRegistry||{byAttr:new Map,reactive:[],persist:[]};return e.byReactive=e.byReactive||new Map,e.reactiveWildcard=e.reactiveWildcard||[],e}function Pe(e){const t=ae(),n=e.observed||[];for(let r=0;r<n.length;r++){const i=n[r];t.byAttr.has(i)||t.byAttr.set(i,[]),t.byAttr.get(i).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const r in e.attributes){t.byDeclaredAttr.has(r)||t.byDeclaredAttr.set(r,[]);const i=t.byDeclaredAttr.get(r);i.some(c=>c.componentTag===e.componentTag)||i.push({spec:e.attributes[r],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const r=$e(e);if(r===null)t.reactiveWildcard.push(e);else for(const i of r)t.byReactive.has(i)||t.byReactive.set(i,[]),t.byReactive.get(i).push(e)}e.persist&&t.persist.push(e)}function de(e,t,n,r){for(let i=0;i<e.length;i++){const c=e[i];if(!t[c.attribute])continue;const l=c.effects&&c.effects[n];l?l(t,n,r):c.onAttrChange&&(!c.declared||c.declared.has(n))&&c.onAttrChange(t,n,r)}}function Me(e){const t=e.attributeName,n=t.indexOf("data-ln-")===0,r=ae(),i=r.byAttr.get(t),c=J()&&r.byDeclaredAttr&&r.byDeclaredAttr.has(t);if(!n&&!i&&!c)return;const l=e.target;if(e.oldValue!==l.getAttribute(t)){if(c&&D(l)){const u=r.byDeclaredAttr.get(t),o=l.getAttribute(t);for(let a=0;a<u.length;a++)le(u[a].spec,o,t,u[a].componentTag,l)}if(window.lnCore._debugSink&&(n||i)&&window.lnCore._debugSink("attr",t,l,{oldValue:e.oldValue,newValue:l.getAttribute(t)}),n){const u=r.byReactive.get(t);u&&de(u,l,t,e.oldValue),r.reactiveWildcard.length&&de(r.reactiveWildcard,l,t,e.oldValue)}if(i)for(let u=0;u<i.length;u++){const o=i[u];if(o.handler){o.handler(l,t,e.oldValue);continue}o.onAttributeChange&&l[o.attribute]?o.onAttributeChange(l,t):(ue(l,o.selector,o.attribute,o.ComponentFn),o.onInit&&o.onInit(l))}}}function je(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,k(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{Me(t[n])}catch(r){console.error("[ln-core] mutation handler failed",t[n].target,r)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function B(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function P(){return window.lnCore=window.lnCore||{},window.lnCore._subtreeRegistry=window.lnCore._subtreeRegistry||[]}function fe(e,t){if(!document.contains(e))if(t.attribute){const n=e[t.attribute];if(n&&typeof n.destroy=="function")try{n.destroy()}catch(r){console.error("["+t.attribute+"] destroy failed",e,r)}delete e[t.attribute]}else t.onDestroy&&t.onDestroy(e)}function he(e){const t=B();if(!t.length)return;const n=e.target;if(n){const i=n.nodeType===1?n:n.parentElement;if(i&&(i.isContentEditable||i.closest&&i.closest('[contenteditable]:not([contenteditable="false"])')))return}const r=P();if(e.target&&r.length)for(let i=0;i<r.length;i++){const c=r[i],l=c.query,u=e.target.nodeType===1?e.target.matches&&e.target.matches(l)?e.target:e.target.closest?e.target.closest(l):null:e.target.parentElement&&e.target.parentElement.closest?e.target.parentElement.closest(l):null;u&&c.onSubtreeChange(u,e)}for(let i=0;i<e.addedNodes.length;i++){const c=e.addedNodes[i];if(c.nodeType!==1)continue;const l=!!(c.firstElementChild||c.children&&c.children.length);for(let u=0;u<t.length;u++){const o=t[u],a=o.query;if(a&&(c.matches&&c.matches(a)&&(o.ComponentFn&&L(c,o),o.onInit&&o.onInit(c)),l&&c.querySelectorAll)){const h=c.querySelectorAll(a);for(let p=0;p<h.length;p++)o.ComponentFn&&L(h[p],o),o.onInit&&o.onInit(h[p])}}}for(let i=0;i<e.removedNodes.length;i++){const c=e.removedNodes[i];if(c.nodeType!==1||document.contains(c))continue;const l=!!(c.firstElementChild||c.children&&c.children.length);for(let u=0;u<t.length;u++){const o=t[u],a=o.query;if(a&&(c.matches&&c.matches(a)&&fe(c,o),l&&c.querySelectorAll)){const h=c.querySelectorAll(a);for(let p=0;p<h.length;p++)fe(h[p],o)}}}}function we(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,k(function(){const e=new MutationObserver(function(t){for(let n=0;n<t.length;n++){const r=t[n];if(r.type==="childList")try{he(r)}catch(i){console.error("[ln-core] lifecycle handler failed",r.target,i)}}});window.lnCore._lifecycleObserver=e,e.observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function pe(e){if(typeof window>"u")return e();window.lnCore=window.lnCore||{};const t=window.lnCore._lifecycleObserver;if(!t)return e();const n=t.takeRecords();for(let r=0;r<n.length;r++){const i=n[r];if(i.type==="childList")try{he(i)}catch(c){console.error("[ln-core] lifecycle handler failed",i.target,c)}}t.disconnect();try{return e()}finally{t.observe(document.body,{childList:!0,subtree:!0})}}function Ue(e){B().push(e),e.onSubtreeChange&&e.query&&P().push(e),we()}function be(e,t,n,r,i={}){const c=i.extraAttributes||[],l=i.onAttributeChange||null,u=i.onSubtreeChange||null,o=i.onInit||null,a=i.onAttrChange||null,h=i.effects||null,p=i.attributes||null,A=p?Ne(p):h,E=p?new Set(Object.keys(p)):null,d=i.persist||null;function g(C){const m=C||document.body;if(ue(m,e,t,n),p&&J())for(const S in p){const Q=p[S],x=Array.from(m.querySelectorAll("["+S+"]"));m.matches&&m.matches("["+S+"]")&&x.push(m);for(let _=0;_<x.length;_++){const z=x[_];D(z)&&le(Q,z.getAttribute(S),S,r,z)}}o&&o(m)}const s=[];if(e.indexOf("[")!==-1){const C=/\[([\w-]+)/g;let m;for(;(m=C.exec(e))!==null;)s.push(m[1])}else s.push(e);Pe({selector:e,attribute:t,componentTag:r,attributes:p,ComponentFn:n,onInit:o,observed:s.concat(c),onAttributeChange:l,onAttrChange:a,effects:A,declared:E,persist:d}),je();const y=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1,w=i.subtreeQuery||(y?e:"["+e+"]"),b={selector:e,attribute:t,ComponentFn:n,onInit:o,onSubtreeChange:u,query:w};B().push(b),u&&w&&P().push(b),we(),window[t]=g,typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerComponent=be,window.lnCore.observeLifecycle=Ue,window.lnCore.withoutLifecycle=pe);function f(){Be()>0?I(function(){g(document.body)}):g(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",f):f(),g}function Ve(e){let t=!1;for(let n=0;n<e.length;n++){const r=e[n];if(!(r===""||r==null)&&(t=!0,!Number.isFinite(Number(r))))return"string"}return t?"number":"string"}function He(e,t,n,r){if(n==="number"){const l=parseFloat(e),u=parseFloat(t);return(isNaN(l)?0:l)-(isNaN(u)?0:u)}const i=e!=null?String(e):"",c=t!=null?String(t):"";return r?r.compare(i,c):i<c?-1:i>c?1:0}function ge(e){return(e||"").replace(/^#/,"")}function M(e){const t=e===void 0?location.hash:e,n={},r=ge(t);if(!r)return n;const i=r.split("&");for(let c=0;c<i.length;c++){const l=i[c];if(!l)continue;const u=l.indexOf(":"),o=u>-1?l.slice(0,u):l,a=u>-1?l.slice(u+1):"";if(o)try{n[o]=decodeURIComponent(a)}catch{n[o]=a}}return n}function j(e){if(!e)return null;const t=M();return e in t?t[e]:null}function me(e,t){if(!e)return;const n=M();t==null?delete n[e]:n[e]=String(t);const i=Object.keys(n).map(function(c){const l=n[c];return l===""?c:c+":"+encodeURIComponent(l)}).join("&");ge(location.hash)!==i&&(location.hash=i)}function We(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function T(e,t){if(!e||!e.hasAttribute("data-ln-hash"))return null;const n=e.getAttribute("data-ln-hash");if(n&&n.trim()!=="")return n.trim();const r=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return r?t?r+"-"+t:r:t||null}function ye(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function U(e){return!e||typeof e!="string"?null:e.endsWith(".asc")?{fieldOrColumn:e.slice(0,-4),direction:"asc"}:e.endsWith(".desc")?{fieldOrColumn:e.slice(0,-5),direction:"desc"}:null}function Ke(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function Qe(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),r=e.slice(t+1),i=r?r.split(",").map(function(c){try{return decodeURIComponent(c)}catch{return c}}).filter(Boolean):[];return{key:n,values:i}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=M,window.lnCore.hashGet=j,window.lnCore.hashSet=me,window.lnCore.hashLinkClick=We,window.lnCore.resolveHashNamespace=T,window.lnCore.hashSortEncode=ye,window.lnCore.hashSortDecode=U,window.lnCore.hashFilterEncode=Ke,window.lnCore.hashFilterDecode=Qe);function ze(e){return(e||"").replace(/^\?/,"")}function V(e){const t=e===void 0?typeof window<"u"?window.location.search:"":e,n={},r=ze(t);if(!r)return n;const i=new URLSearchParams(r);for(const[c,l]of i.entries())n[c]=l;return n}function H(e){if(!e||typeof window>"u")return null;const t=new URLSearchParams(window.location.search);return t.has(e)?t.get(e):null}function Ce(e,t){if(!e||typeof window>"u")return;const n=new URL(window.location.href);if(t==null||t===""?n.searchParams.delete(e):n.searchParams.set(e,String(t)),n.search===window.location.search)return;const r=n.pathname+n.search+n.hash;window.history.replaceState(window.history.state,"",r)}function O(e,t){if(!e||!e.hasAttribute("data-ln-query"))return null;const n=e.getAttribute("data-ln-query");if(n&&n.trim()!=="")return n.trim();const r=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return r?t?r+"_"+t:r:t||null}function Ae(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function W(e,t){if(e&&typeof e=="string"){if(e.endsWith(".asc"))return{fieldOrColumn:e.slice(0,-4),direction:"asc"};if(e.endsWith(".desc"))return{fieldOrColumn:e.slice(0,-5),direction:"desc"}}if(t&&typeof t=="object"){const n=t.sort_field||t.sort_by;if(n){const r=t.sort_dir&&String(t.sort_dir).toLowerCase()==="desc"?"desc":"asc";return{fieldOrColumn:n,direction:r}}}return null}function Je(e){return!Array.isArray(e)||e.length===0?null:e.map(encodeURIComponent).join(",")}function Ge(e){return!e||typeof e!="string"?[]:e.split(",").map(function(t){try{return decodeURIComponent(t.trim())}catch{return t.trim()}}).filter(Boolean)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.queryParse=V,window.lnCore.queryGet=H,window.lnCore.querySet=Ce,window.lnCore.resolveQueryParam=O,window.lnCore.querySortEncode=Ae,window.lnCore.querySortDecode=W,window.lnCore.queryFilterEncode=Je,window.lnCore.queryFilterDecode=Ge);function Xe(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,e=>{const t=Math.random()*16|0;return(e==="x"?t:t&3|8).toString(16)})}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.uuid=Xe);function v(e){const t=String(e||"").trim().toLowerCase();return t==="asc"||t==="ascending"?"asc":t==="desc"||t==="descending"?"desc":"none"}function Ye(e){const t=v(e);return t==="asc"?"ascending":t==="desc"?"descending":"none"}function Ze(e,t){return!e||!t?!1:e.field!==null&&e.field!==void 0&&t.field!==null&&t.field!==void 0?e.field===t.field:e.column!==null&&e.column!==void 0&&t.column!==null&&t.column!==void 0?String(e.column)===String(t.column):!1}function et(e,t,n,r){const i=v(e);if(i==="none")return()=>0;const c=i==="desc"?-1:1,l=typeof r=="function"?r:u=>u;return function(u,o){const a=l(u),h=l(o);return He(a,h,t,n)*c}}function K(e){return!!(!e||typeof e!="object"||e.nodeType!==1||e.tagName==="TEMPLATE"||typeof e.hasAttribute=="function"&&(e.hasAttribute("data-ln-sort-exclude")||e.hasAttribute("data-ln-table-empty")||e.hasAttribute("hidden"))||e.classList&&e.classList.contains("hidden")||e.style&&e.style.display==="none")}function tt(e,t){if(!e||typeof e!="object"||e.nodeType!==1)return[];const n=t||(typeof e.getAttribute=="function"?e.getAttribute("data-ln-sort-items"):null)||null;if(n&&typeof e.querySelectorAll=="function")return Array.from(e.querySelectorAll(n));if(e.tagName==="TABLE"){const r=e.tBodies&&e.tBodies.length?e.tBodies[0]:typeof e.querySelector=="function"?e.querySelector("tbody"):null;if(r)return Array.from(r.children||[]);if(typeof e.querySelectorAll=="function")return Array.from(e.querySelectorAll("tbody tr, tr"))}return Array.from(e.children||[])}(function(){const e="data-ln-sort",t="lnSort",n="data-ln-sort-field",r="data-ln-sort-state",i="data-ln-sort-dir",c="data-ln-hash",l="data-ln-query";if(window[t]!==void 0)return;function u(d,g){return d.getAttribute(g)||null}const o={"data-ln-sort":{prop:"targetId",type:"string",read:q,fallback:null,description:"Target table or list element ID to sort"},"data-ln-sort-field":{prop:"field",type:"string",read:u,effect:E,description:"Field name or column key to sort by"},"data-ln-sort-dir":{type:"enum",values:["asc","desc"],fallback:"asc",description:"Default or requested sort direction"},"data-ln-sort-items":{prop:"itemsSelector",type:"string",read:u,description:"CSS selector matching sortable child items"},"data-ln-sort-state":{type:"enum",values:["asc","desc","none"],fallback:"none",effect:E,description:"Active sort state applied to column or control"},"data-ln-hash":{type:"string",effect:E,description:"URL hash routing key for sort state persistence"},"data-ln-query":{type:"string",effect:E,description:"URL query parameter name for sort state persistence"}},a=ce(o),h=new WeakMap;function p(d,g,s){if(g){const y=d.querySelector('[data-ln-field="'+g+'"]');return y?F(y):""}return s!=null&&d.cells&&d.cells[s]?F(d.cells[s]):F(d)}function A(d){this.dom=d,se(this,d,a);const g=d.closest("th");this.column=!this.field&&g?g.cellIndex:null,this._state=v(d.getAttribute(r)),d.hasAttribute(r)||d.setAttribute(r,this._state),this._destroyed=!1,this.nsKey=T(d,"sort"),this.hashEnabled=!!this.nsKey,this.queryParam=O(d,"sort"),this.queryEnabled=!!this.queryParam;const s=this;this._onClick=function(w){const b=w.target.closest("["+i+"]");if(!b)return;const f=v(b.getAttribute(i));s._apply(f)},d.addEventListener("click",this._onClick),this._onSortChange=function(w){if(s._destroyed||!w.detail)return;const b=s._resolveTarget();if(!(b&&(w.target===b||b.contains(w.target))||w.detail.targetId&&w.detail.targetId===s.targetId))return;if(Ze({field:s.field,column:s.column},{field:w.detail.field,column:w.detail.column})){const m=v(w.detail.direction);m&&d.getAttribute(r)!==m&&(s._state=m,d.setAttribute(r,m),s._updateAriaSort(m));return}d.getAttribute(r)!=="none"&&(s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none"))},document.addEventListener("ln-sort:change",this._onSortChange),this._onHashChange=function(){if(s._destroyed||!s.hashEnabled)return;const w=j(s.nsKey),b=U(w);if(b)s.field!==null&&b.fieldOrColumn===s.field||s.column!==null&&String(s.column)===b.fieldOrColumn?s._state!==b.direction&&s._apply(b.direction,!0):s._state!=="none"&&(s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none"));else if(s._state!=="none"){s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none");const f=s._resolveTarget();f&&(R(f,"ln-sort:change",{field:s.field,column:s.column,direction:"none",targetId:s.targetId}).defaultPrevented||s._defaultSort(f,"none"))}},this._onPopState=function(){if(s._destroyed||!s.queryEnabled)return;const w=H(s.queryParam),b=V(),f=W(w,b);if(f)s.field!==null&&f.fieldOrColumn===s.field||s.column!==null&&String(s.column)===f.fieldOrColumn?s._state!==f.direction&&s._apply(f.direction,!0):s._state!=="none"&&(s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none"));else if(s._state!=="none"){s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none");const C=s._resolveTarget();C&&(R(C,"ln-sort:change",{field:s.field,column:s.column,direction:"none",targetId:s.targetId}).defaultPrevented||s._defaultSort(C,"none"))}},this.hashEnabled&&window.addEventListener("hashchange",this._onHashChange),this.queryEnabled&&window.addEventListener("popstate",this._onPopState);let y=!1;if(this.hashEnabled){const w=j(this.nsKey),b=U(w);b&&((s.field!==null&&b.fieldOrColumn===s.field||s.column!==null&&String(s.column)===b.fieldOrColumn)&&I(function(){s._destroyed||s._apply(b.direction,!0)}),y=!0)}else if(this.queryEnabled){const w=H(this.queryParam),b=V(),f=W(w,b);f&&((s.field!==null&&f.fieldOrColumn===s.field||s.column!==null&&String(s.column)===f.fieldOrColumn)&&I(function(){s._destroyed||s._apply(f.direction,!0)}),y=!0)}if(!y){const w=v(d.getAttribute(r));w&&w!=="none"&&I(function(){s._destroyed||s._apply(w,!0)})}return this}A.prototype._resolveTarget=function(){return document.getElementById(this.targetId)},A.prototype._updateAriaSort=function(d){const g=this.dom.closest("th");g&&g.setAttribute("aria-sort",Ye(d))},A.prototype._apply=function(d,g){if(this._destroyed)return;if(!this.field&&this.column===null){const f=this.dom.closest("th");f&&f.cellIndex!==void 0&&(this.column=f.cellIndex)}const s=v(d);this._state=s,this.dom.getAttribute(r)!==s&&this.dom.setAttribute(r,s),this._updateAriaSort(s);const y=this._resolveTarget();if(!y)return;const w={field:this.field,column:this.column,direction:s,targetId:this.targetId};if(!g){if(this.hashEnabled){const f=ye(this.field!==null?this.field:this.column,s);me(this.nsKey,f)}else if(this.queryEnabled){const f=Ae(this.field!==null?this.field:this.column,s);Ce(this.queryParam,f)}}R(y,"ln-sort:change",w).defaultPrevented||this._defaultSort(y,s)},A.prototype._defaultSort=function(d,g){const s=tt(d,this.itemsSelector);if(!s.length)return;const y=s[0].parentNode,w=s.filter(function(f){return!K(f)});if(!w.length)return;h.has(d)||h.set(d,w.slice());let b;if(g==="none"){const f=h.get(d)||w;h.delete(d),b=f.filter(function(C){return C.parentNode===y&&!K(C)})}else{const f=this.field,C=this.column,m=w.map(function(_){return{el:_,val:p(_,f,C)}}),S=Ve(m.map(function(_){return _.val})),Q=typeof Intl<"u"?new Intl.Collator(Le(this.dom),{sensitivity:"base",numeric:!0}):null,x=et(g,S,Q,function(_){return _.val});m.sort(x),b=m.map(function(_){return _.el})}pe(function(){const f=document.createDocumentFragment();let C=0;for(let m=0;m<s.length;m++){const S=s[m];K(S)?f.appendChild(S):C<b.length&&f.appendChild(b[C++])}y.appendChild(f)})},A.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.dom.removeEventListener("click",this._onClick),document.removeEventListener("ln-sort:change",this._onSortChange),this.hashEnabled&&this._onHashChange&&window.removeEventListener("hashchange",this._onHashChange),this.queryEnabled&&this._onPopState&&window.removeEventListener("popstate",this._onPopState),delete this.dom[t])};function E(d,g){const s=d[t];if(!(!s||s._destroyed))if(g===n){const y=d.closest("th");s.column=!s.field&&y?y.cellIndex:null}else if(g===r){const y=v(d.getAttribute(r));y!==s._state&&s._apply(y)}else g===c?(s.hashEnabled&&s._onHashChange&&window.removeEventListener("hashchange",s._onHashChange),s.nsKey=T(d,"sort"),s.hashEnabled=!!s.nsKey,s.hashEnabled&&window.addEventListener("hashchange",s._onHashChange)):g===l&&(s.queryEnabled&&s._onPopState&&window.removeEventListener("popstate",s._onPopState),s.queryParam=O(d,"sort"),s.queryEnabled=!!s.queryParam,s.queryEnabled&&window.addEventListener("popstate",s._onPopState))}be(e,t,A,"ln-sort",{attributes:o,persist:{attr:r,hashActive:function(d){return!!T(d,"sort")||!!O(d,"sort")}}})})()})();
|
|
1
|
+
(function(){"use strict";function J(){if(typeof window>"u")return!1;if(window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink)return!0;if(typeof document<"u"){if(document.documentElement&&document.documentElement.hasAttribute("data-ln-debug"))return!0;if(document.body)return document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null}return!1}function D(e){if(typeof window>"u")return!1;if(window.lnDebug===!0)return!0;if(window.lnCore&&window.lnCore._debugIsContained)return e?window.lnCore._debugIsContained(e):window.lnCore._debugSink!==null;if(e&&e.closest){const t=e.closest("[data-ln-debug]");return!(!t||typeof document<"u"&&t===document.documentElement)}return typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug"):!1}if(typeof window<"u"&&(window.lnCore=window.lnCore||{},!window.lnCore._warnBound)){window.lnCore._warnBound=!0;const e=console.warn;console.warn=function(...t){if(typeof t[0]=="string"&&(t[0].startsWith("[ln-")||t[0].startsWith("[lnCore"))){let r=null;for(let i=1;i<t.length;i++)if(t[i]&&t[i].nodeType===1){r=t[i];break}if(!D(r))return}e.apply(console,t)}}function _e(e,t,n){const r=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,r),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:r}))}function R(e,t,n){const r=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,r);const i=new CustomEvent(t,{bubbles:!0,cancelable:!0,detail:r});return e.dispatchEvent(i),i}function k(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){k(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}function F(e){return e.hasAttribute("value")?e.getAttribute("value"):e.hasAttribute("data-ln-value")?e.getAttribute("data-ln-value"):e.tagName==="TIME"&&e.hasAttribute("datetime")?e.getAttribute("datetime"):e.textContent.trim()}function Se(e){const t=e.querySelector('input[name="_method"]');return((t&&t.value!==""?t.value:e.method)||"").toUpperCase()}function ve(e,t){const n=!!(t&&t.typed),r=t&&t.exclude,i={},c=e.elements,l={};if(n)for(let u=0;u<c.length;u++){const o=c[u];o.name&&o.type==="checkbox"&&!o.disabled&&(l[o.name]=(l[o.name]||0)+1)}for(let u=0;u<c.length;u++){const o=c[u];if(!(!o.name||o.disabled||o.type==="file"||o.type==="submit"||o.type==="button")&&!(r&&o.matches&&o.matches(r)))if(o.type==="checkbox")n&&l[o.name]===1?i[o.name]=o.checked:(i[o.name]||(i[o.name]=[]),o.checked&&i[o.name].push(o.value));else if(o.type==="radio")o.checked&&(i[o.name]=o.value);else if(o.type==="select-multiple"){i[o.name]=[];for(let a=0;a<o.options.length;a++)o.options[a].selected&&i[o.name].push(o.options[a].value)}else if(n&&o.type==="hidden")i[o.name]=o.value;else if(n&&(o.type==="number"||o.type==="range")){const a=Number(o.value);i[o.name]=o.value===""||isNaN(a)?null:a}else i[o.name]=o.value}return i}function Ee(e){if(typeof e!="string")return!!e;const t=e.trim().toLowerCase();return t!=="false"&&t!=="0"&&t!==""&&t!=="off"&&t!=="no"}function xe(e,t){const n=e.elements,r=[],i={};for(let c=0;c<n.length;c++){const l=n[c];l.name&&l.type==="checkbox"&&(i[l.name]=(i[l.name]||0)+1)}for(let c=0;c<n.length;c++){const l=n[c];if(l.type==="file"||l.type==="submit"||l.type==="button")continue;const u=l.getAttribute("data-ln-fill-as")||l.name;if(!u||!(u in t))continue;const o=t[u];if(l.type==="checkbox"){if(Array.isArray(o))l.checked=o.indexOf(l.value)!==-1;else if(i[l.name]>1){const a=String(o).split(",").map(function(h){return h.trim()});l.checked=a.indexOf(l.value)!==-1}else l.checked=Ee(o);r.push(l)}else if(l.type==="radio")l.checked=l.value===String(o),r.push(l);else if(l.type==="select-multiple"){if(Array.isArray(o))for(let a=0;a<l.options.length;a++)l.options[a].selected=o.indexOf(l.options[a].value)!==-1;r.push(l)}else l.value=o,l.tagName==="SELECT"&&o!=null&&l.setAttribute("data-ln-value",o),r.push(l)}return r}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.populateForm=xe,window.lnCore.serializeForm=ve,window.lnCore.resolveFormMethod=Se);const G={};function ke(e,t){G[e]=t}function qe(e){return G[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=ke,window.lnCore.getDataMapper=qe);function Le(e){const t=e?e.closest("[lang]"):null,n=(t?t.getAttribute("lang")||t.lang:null)||(typeof document<"u"&&document.documentElement?document.documentElement.getAttribute("lang")||document.documentElement.lang:null)||(typeof navigator<"u"?navigator.language:null);return n?n.trim():"en-US"}function Ie(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,k(function(){new MutationObserver(function(){_e(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const X={};function Te(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];X[n]=t}function Oe(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return X[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=Te,window.lnCore.getLocaleFallback=Oe,window.lnCore.ensureLocaleObserver=Ie);const N={};function De(e,t){N[e]||(N[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=N[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function Y(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let l=0;l<n.length;l++){const u=n[l],o=u.getAttribute("data-ln-field");t[o]!=null&&(u.textContent=t[o])}const r=e.querySelectorAll("[data-ln-attr]");for(let l=0;l<r.length;l++){const u=r[l],o=u.getAttribute("data-ln-attr").split(",");for(let a=0;a<o.length;a++){const h=o[a].trim().split(":");if(h.length!==2)continue;const p=h[0].trim(),A=h[1].trim();t[A]!=null&&u.setAttribute(p,t[A])}}const i=e.querySelectorAll("[data-ln-show]");for(let l=0;l<i.length;l++){const u=i[l],o=u.getAttribute("data-ln-show");o in t&&u.classList.toggle("hidden",!t[o])}const c=e.querySelectorAll("[data-ln-class]");for(let l=0;l<c.length;l++){const u=c[l],o=u.getAttribute("data-ln-class").split(",");for(let a=0;a<o.length;a++){const h=o[a].trim().split(":");if(h.length!==2)continue;const p=h[0].trim(),A=h[1].trim();A in t&&u.classList.toggle(p,!!t[A])}}return e}function Re(e,t){e.matches&&e.matches("[data-ln-form], [data-ln-fillable]")&&(window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",e,t??null),e.dispatchEvent(new CustomEvent("ln-fill",{detail:t??null,bubbles:!0})));const n=e.querySelectorAll("[data-ln-form], [data-ln-fillable]");for(let r=0;r<n.length;r++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[r],t??null),n[r].dispatchEvent(new CustomEvent("ln-fill",{detail:t??null,bubbles:!0}));return e}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._fillBound||(window.lnCore._fillBound=!0,document.addEventListener("ln-fill",function(e){if(!(!e.target.matches||!e.target.matches("[data-ln-fillable]")))if(e.detail)Y(e.target,e.detail);else{const t=e.target.querySelectorAll("[data-ln-field]");for(let n=0;n<t.length;n++)t[n].textContent=""}})));function Z(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const c=n.currentNode;c.textContent.indexOf("{{")!==-1&&(c.textContent=c.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(l,u){return t[u]!==void 0?t[u]:""}))}const r=function(c,l){return t[l]!==void 0?t[l]:""},i=Array.from(e.querySelectorAll("*"));e.nodeType===1&&i.push(e);for(let c=0;c<i.length;c++){const l=i[c],u=l.attributes;for(let o=0;o<u.length;o++){const a=u[o];a.value.indexOf("{{")!==-1&&l.setAttribute(a.name,a.value.replace(/\{\{\s*(\w+)\s*\}\}/g,r))}}return e}function Fe(e,t,n,r,i,c){const l={};for(let o=0;o<e.children.length;o++){const a=e.children[o],h=a.getAttribute("data-ln-render-key");h&&(l[h]=a)}const u=document.createDocumentFragment();for(let o=0;o<t.length;o++){const a=t[o],h=String(r(a));let p=l[h];if(p)i(p,a,o);else{const A=De(n,c);if(!A||(Z(A,a),p=A.firstElementChild,!p))continue;p.setAttribute("data-ln-render-key",h),i(p,a,o)}u.appendChild(p)}e.textContent="",e.appendChild(u)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=Z,window.lnCore.fill=Y,window.lnCore.lnFill=Re,window.lnCore.renderList=Fe);function q(e,t,n){const r=e.getAttribute(t);return r===null?n:r}function ee(e,t,n){const r=parseInt(e.getAttribute(t),10);return isNaN(r)?n:r}function te(e,t,n=!1){const r=e.getAttribute(t);if(r===null)return!!n;const i=r.trim().toLowerCase();return!(i==="false"||i==="0")}function ne(e,t){return(e.getAttribute(t)||"").split(",").map(n=>n.trim()).filter(Boolean)}const $=new Map;function re(e,t){const n=(e?e.join("|"):"")+"::"+t;if($.has(n))return $.get(n);const r=new Set(e||[]),i=function(c,l){const u=c.getAttribute(l);return u!==null&&r.has(u)?u:t};return $.set(n,i),i}function oe(e,t,n){const r=parseFloat(e.getAttribute(t));return isNaN(r)?n:r}function ie(e,t,n){const r=e.getAttribute(t);if(!r)return n;try{return JSON.parse(r)}catch{return n}}function le(e,t,n,r,i){if(!e||t===null)return!0;const c=r||"ln-component",l=e.type;if(l==="trigger"||l==="marker"||l==="string"||l==="list"||!l||t===""&&e.fallback!==void 0)return!0;const u=o=>{i?console.warn(o,i):console.warn(o)};if(l==="boolean"){const o=t.trim().toLowerCase();return o!==""&&o!=="true"&&o!=="false"&&o!=="1"&&o!=="0"?(u(`[${c}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(l==="enum"){const o=e.values||[];return o.includes(t)?!0:(u(`[${c}] Invalid value "${t}" for attribute "${n}". Allowed: ${o.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(l==="integer"){if(!/^-?\d+$/.test(t))return u(`[${c}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const o=parseInt(t,10);return e.min!==void 0&&o<e.min?(u(`[${c}] Value ${o} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&o>e.max?(u(`[${c}] Value ${o} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(l==="float")return isNaN(Number(t))?(u(`[${c}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(l==="json")try{return JSON.parse(t),!0}catch(o){return u(`[${c}] Invalid JSON for attribute "${n}": ${o.message}. Fallback: ${e.fallback}.`),!1}return!0}function se(e,t,n){for(const r in n){const[i,c,l]=n[r];Object.defineProperty(e,r,{get:function(){return i(t,c,l)},enumerable:!0,configurable:!0})}return e}function ce(e){const t={};for(const n in e){const r=e[n];if(!r||!r.prop)continue;let i=r.read;if(!i&&r.type)switch(r.type){case"enum":i=re(r.values,r.fallback);break;case"integer":i=ee;break;case"float":i=oe;break;case"boolean":i=te;break;case"list":i=ne;break;case"json":i=ie;break;case"string":default:i=q;break}i||(i=q),t[r.prop]=[i,n,r.fallback]}return t}function Ne(e){const t={};for(const n in e){const r=e[n];r&&r.effect&&(t[n]=r.effect)}return Object.keys(t).length?t:null}function $e(e){if(e.onAttrChange&&!e.declared)return null;const t=new Set;if(e.effects)for(const n in e.effects)t.add(n);if(e.onAttrChange&&e.declared)for(const n of e.declared)t.add(n);return t}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.defineAttrs=se,window.lnCore.attrSpec=ce,window.lnCore.attrStr=q,window.lnCore.attrInt=ee,window.lnCore.attrBool=te,window.lnCore.attrList=ne,window.lnCore.attrEnum=re,window.lnCore.attrFloat=oe,window.lnCore.attrJson=ie);function L(e,t){if(!e[t.attribute]){window.lnCore._persistSink&&e.hasAttribute&&e.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(e,t.selector);try{e[t.attribute]=new t.ComponentFn(e)}catch(n){console.error("["+t.attribute+"] init failed",e,n)}}}function ue(e,t,n,r){if(e.nodeType!==1)return;const c=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",l={selector:t,attribute:n,ComponentFn:r};if(e.matches&&e.matches(c)&&L(e,l),e.querySelectorAll){const u=e.querySelectorAll(c);for(let o=0;o<u.length;o++)L(u[o],l)}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function Be(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function I(e){typeof window<"u"?(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[],window.lnCore._bootHolds>0?window.lnCore._bootQueue.push(e):setTimeout(e,0)):e()}function ae(){window.lnCore=window.lnCore||{};const e=window.lnCore._attrRegistry=window.lnCore._attrRegistry||{byAttr:new Map,reactive:[],persist:[]};return e.byReactive=e.byReactive||new Map,e.reactiveWildcard=e.reactiveWildcard||[],e}function Pe(e){const t=ae(),n=e.observed||[];for(let r=0;r<n.length;r++){const i=n[r];t.byAttr.has(i)||t.byAttr.set(i,[]),t.byAttr.get(i).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const r in e.attributes){t.byDeclaredAttr.has(r)||t.byDeclaredAttr.set(r,[]);const i=t.byDeclaredAttr.get(r);i.some(c=>c.componentTag===e.componentTag)||i.push({spec:e.attributes[r],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const r=$e(e);if(r===null)t.reactiveWildcard.push(e);else for(const i of r)t.byReactive.has(i)||t.byReactive.set(i,[]),t.byReactive.get(i).push(e)}e.persist&&t.persist.push(e)}function de(e,t,n,r){for(let i=0;i<e.length;i++){const c=e[i];if(!t[c.attribute])continue;const l=c.effects&&c.effects[n];l?l(t,n,r):c.onAttrChange&&(!c.declared||c.declared.has(n))&&c.onAttrChange(t,n,r)}}function Me(e){const t=e.attributeName,n=t.indexOf("data-ln-")===0,r=ae(),i=r.byAttr.get(t),c=J()&&r.byDeclaredAttr&&r.byDeclaredAttr.has(t);if(!n&&!i&&!c)return;const l=e.target;if(e.oldValue!==l.getAttribute(t)){if(c&&D(l)){const u=r.byDeclaredAttr.get(t),o=l.getAttribute(t);for(let a=0;a<u.length;a++)le(u[a].spec,o,t,u[a].componentTag,l)}if(window.lnCore._debugSink&&(n||i)&&window.lnCore._debugSink("attr",t,l,{oldValue:e.oldValue,newValue:l.getAttribute(t)}),n){const u=r.byReactive.get(t);u&&de(u,l,t,e.oldValue),r.reactiveWildcard.length&&de(r.reactiveWildcard,l,t,e.oldValue)}if(i)for(let u=0;u<i.length;u++){const o=i[u];if(o.handler){o.handler(l,t,e.oldValue);continue}o.onAttributeChange&&l[o.attribute]?o.onAttributeChange(l,t):(ue(l,o.selector,o.attribute,o.ComponentFn),o.onInit&&o.onInit(l))}}}function je(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,k(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{Me(t[n])}catch(r){console.error("[ln-core] mutation handler failed",t[n].target,r)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function B(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function P(){return window.lnCore=window.lnCore||{},window.lnCore._subtreeRegistry=window.lnCore._subtreeRegistry||[]}function fe(e,t){if(!document.contains(e))if(t.attribute){const n=e[t.attribute];if(n&&typeof n.destroy=="function")try{n.destroy()}catch(r){console.error("["+t.attribute+"] destroy failed",e,r)}delete e[t.attribute]}else t.onDestroy&&t.onDestroy(e)}function he(e){const t=B();if(!t.length)return;const n=e.target;if(n){const i=n.nodeType===1?n:n.parentElement;if(i&&(i.isContentEditable||i.closest&&i.closest('[contenteditable]:not([contenteditable="false"])')))return}const r=P();if(e.target&&r.length)for(let i=0;i<r.length;i++){const c=r[i],l=c.query,u=e.target.nodeType===1?e.target.matches&&e.target.matches(l)?e.target:e.target.closest?e.target.closest(l):null:e.target.parentElement&&e.target.parentElement.closest?e.target.parentElement.closest(l):null;u&&c.onSubtreeChange(u,e)}for(let i=0;i<e.addedNodes.length;i++){const c=e.addedNodes[i];if(c.nodeType!==1)continue;const l=!!(c.firstElementChild||c.children&&c.children.length);for(let u=0;u<t.length;u++){const o=t[u],a=o.query;if(a&&(c.matches&&c.matches(a)&&(o.ComponentFn&&L(c,o),o.onInit&&o.onInit(c)),l&&c.querySelectorAll)){const h=c.querySelectorAll(a);for(let p=0;p<h.length;p++)o.ComponentFn&&L(h[p],o),o.onInit&&o.onInit(h[p])}}}for(let i=0;i<e.removedNodes.length;i++){const c=e.removedNodes[i];if(c.nodeType!==1||document.contains(c))continue;const l=!!(c.firstElementChild||c.children&&c.children.length);for(let u=0;u<t.length;u++){const o=t[u],a=o.query;if(a&&(c.matches&&c.matches(a)&&fe(c,o),l&&c.querySelectorAll)){const h=c.querySelectorAll(a);for(let p=0;p<h.length;p++)fe(h[p],o)}}}}function we(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,k(function(){const e=new MutationObserver(function(t){for(let n=0;n<t.length;n++){const r=t[n];if(r.type==="childList")try{he(r)}catch(i){console.error("[ln-core] lifecycle handler failed",r.target,i)}}});window.lnCore._lifecycleObserver=e,e.observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function pe(e){if(typeof window>"u")return e();window.lnCore=window.lnCore||{};const t=window.lnCore._lifecycleObserver;if(!t)return e();const n=t.takeRecords();for(let r=0;r<n.length;r++){const i=n[r];if(i.type==="childList")try{he(i)}catch(c){console.error("[ln-core] lifecycle handler failed",i.target,c)}}t.disconnect();try{return e()}finally{t.observe(document.body,{childList:!0,subtree:!0})}}function Ue(e){B().push(e),e.onSubtreeChange&&e.query&&P().push(e),we()}function be(e,t,n,r,i={}){const c=i.extraAttributes||[],l=i.onAttributeChange||null,u=i.onSubtreeChange||null,o=i.onInit||null,a=i.onAttrChange||null,h=i.effects||null,p=i.attributes||null,A=p?Ne(p):h,E=p?new Set(Object.keys(p)):null,d=i.persist||null;function g(C){const m=C||document.body;if(ue(m,e,t,n),p&&J())for(const S in p){const Q=p[S],x=Array.from(m.querySelectorAll("["+S+"]"));m.matches&&m.matches("["+S+"]")&&x.push(m);for(let _=0;_<x.length;_++){const z=x[_];D(z)&&le(Q,z.getAttribute(S),S,r,z)}}o&&o(m)}const s=[];if(e.indexOf("[")!==-1){const C=/\[([\w-]+)/g;let m;for(;(m=C.exec(e))!==null;)s.push(m[1])}else s.push(e);Pe({selector:e,attribute:t,componentTag:r,attributes:p,ComponentFn:n,onInit:o,observed:s.concat(c),onAttributeChange:l,onAttrChange:a,effects:A,declared:E,persist:d}),je();const y=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1,w=i.subtreeQuery||(y?e:"["+e+"]"),b={selector:e,attribute:t,ComponentFn:n,onInit:o,onSubtreeChange:u,query:w};B().push(b),u&&w&&P().push(b),we(),window[t]=g,typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerComponent=be,window.lnCore.observeLifecycle=Ue,window.lnCore.withoutLifecycle=pe);function f(){Be()>0?I(function(){g(document.body)}):g(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",f):f(),g}function Ve(e){let t=!1;for(let n=0;n<e.length;n++){const r=e[n];if(!(r===""||r==null)&&(t=!0,!Number.isFinite(Number(r))))return"string"}return t?"number":"string"}function He(e,t,n,r){if(n==="number"){const l=parseFloat(e),u=parseFloat(t);return(isNaN(l)?0:l)-(isNaN(u)?0:u)}const i=e!=null?String(e):"",c=t!=null?String(t):"";return r?r.compare(i,c):i<c?-1:i>c?1:0}function ge(e){return(e||"").replace(/^#/,"")}function M(e){const t=e===void 0?location.hash:e,n={},r=ge(t);if(!r)return n;const i=r.split("&");for(let c=0;c<i.length;c++){const l=i[c];if(!l)continue;const u=l.indexOf(":"),o=u>-1?l.slice(0,u):l,a=u>-1?l.slice(u+1):"";if(o)try{n[o]=decodeURIComponent(a)}catch{n[o]=a}}return n}function j(e){if(!e)return null;const t=M();return e in t?t[e]:null}function me(e,t){if(!e)return;const n=M();t==null?delete n[e]:n[e]=String(t);const i=Object.keys(n).map(function(c){const l=n[c];return l===""?c:c+":"+encodeURIComponent(l)}).join("&");ge(location.hash)!==i&&(location.hash=i)}function We(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function T(e,t){if(!e||!e.hasAttribute("data-ln-hash"))return null;const n=e.getAttribute("data-ln-hash");if(n&&n.trim()!=="")return n.trim();const r=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return r?t?r+"-"+t:r:t||null}function ye(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function U(e){return!e||typeof e!="string"?null:e.endsWith(".asc")?{fieldOrColumn:e.slice(0,-4),direction:"asc"}:e.endsWith(".desc")?{fieldOrColumn:e.slice(0,-5),direction:"desc"}:null}function Ke(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function Qe(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),r=e.slice(t+1),i=r?r.split(",").map(function(c){try{return decodeURIComponent(c)}catch{return c}}).filter(Boolean):[];return{key:n,values:i}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=M,window.lnCore.hashGet=j,window.lnCore.hashSet=me,window.lnCore.hashLinkClick=We,window.lnCore.resolveHashNamespace=T,window.lnCore.hashSortEncode=ye,window.lnCore.hashSortDecode=U,window.lnCore.hashFilterEncode=Ke,window.lnCore.hashFilterDecode=Qe);function ze(e){return(e||"").replace(/^\?/,"")}function V(e){const t=e===void 0?typeof window<"u"?window.location.search:"":e,n={},r=ze(t);if(!r)return n;const i=new URLSearchParams(r);for(const[c,l]of i.entries())n[c]=l;return n}function H(e){if(!e||typeof window>"u")return null;const t=new URLSearchParams(window.location.search);return t.has(e)?t.get(e):null}function Ce(e,t){if(!e||typeof window>"u")return;const n=new URL(window.location.href);if(t==null||t===""?n.searchParams.delete(e):n.searchParams.set(e,String(t)),n.search===window.location.search)return;const r=n.pathname+n.search+n.hash;window.history.replaceState(window.history.state,"",r)}function O(e,t){if(!e||!e.hasAttribute("data-ln-query"))return null;const n=e.getAttribute("data-ln-query");if(n&&n.trim()!=="")return n.trim();const r=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return r?t?r+"_"+t:r:t||null}function Ae(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function W(e,t){if(e&&typeof e=="string"){if(e.endsWith(".asc"))return{fieldOrColumn:e.slice(0,-4),direction:"asc"};if(e.endsWith(".desc"))return{fieldOrColumn:e.slice(0,-5),direction:"desc"}}if(t&&typeof t=="object"){const n=t.sort_field||t.sort_by;if(n){const r=t.sort_dir&&String(t.sort_dir).toLowerCase()==="desc"?"desc":"asc";return{fieldOrColumn:n,direction:r}}}return null}function Je(e){return!Array.isArray(e)||e.length===0?null:e.map(encodeURIComponent).join(",")}function Ge(e){return!e||typeof e!="string"?[]:e.split(",").map(function(t){try{return decodeURIComponent(t.trim())}catch{return t.trim()}}).filter(Boolean)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.queryParse=V,window.lnCore.queryGet=H,window.lnCore.querySet=Ce,window.lnCore.resolveQueryParam=O,window.lnCore.querySortEncode=Ae,window.lnCore.querySortDecode=W,window.lnCore.queryFilterEncode=Je,window.lnCore.queryFilterDecode=Ge);function Xe(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,e=>{const t=Math.random()*16|0;return(e==="x"?t:t&3|8).toString(16)})}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.uuid=Xe);function v(e){const t=String(e||"").trim().toLowerCase();return t==="asc"||t==="ascending"?"asc":t==="desc"||t==="descending"?"desc":"none"}function Ye(e){const t=v(e);return t==="asc"?"ascending":t==="desc"?"descending":"none"}function Ze(e,t){return!e||!t?!1:e.field!==null&&e.field!==void 0&&t.field!==null&&t.field!==void 0?e.field===t.field:e.column!==null&&e.column!==void 0&&t.column!==null&&t.column!==void 0?String(e.column)===String(t.column):!1}function et(e,t,n,r){const i=v(e);if(i==="none")return()=>0;const c=i==="desc"?-1:1,l=typeof r=="function"?r:u=>u;return function(u,o){const a=l(u),h=l(o);return He(a,h,t,n)*c}}function K(e){return!!(!e||typeof e!="object"||e.nodeType!==1||e.tagName==="TEMPLATE"||typeof e.hasAttribute=="function"&&(e.hasAttribute("data-ln-sort-exclude")||e.hasAttribute("data-ln-table-empty")||e.hasAttribute("hidden"))||e.classList&&e.classList.contains("hidden")||e.style&&e.style.display==="none")}function tt(e,t){if(!e||typeof e!="object"||e.nodeType!==1)return[];const n=t||(typeof e.getAttribute=="function"?e.getAttribute("data-ln-sort-items"):null)||null;if(n&&typeof e.querySelectorAll=="function")return Array.from(e.querySelectorAll(n));if(e.tagName==="TABLE"){const r=e.tBodies&&e.tBodies.length?e.tBodies[0]:typeof e.querySelector=="function"?e.querySelector("tbody"):null;if(r)return Array.from(r.children||[]);if(typeof e.querySelectorAll=="function")return Array.from(e.querySelectorAll("tbody tr, tr"))}return Array.from(e.children||[])}(function(){const e="data-ln-sort",t="lnSort",n="data-ln-sort-field",r="data-ln-sort-state",i="data-ln-sort-dir",c="data-ln-hash",l="data-ln-query";if(window[t]!==void 0)return;function u(d,g){return d.getAttribute(g)||null}const o={"data-ln-sort":{prop:"targetId",type:"string",read:q,fallback:null,description:"Target table or list element ID to sort"},"data-ln-sort-field":{prop:"field",type:"string",read:u,effect:E,description:"Field name or column key to sort by"},"data-ln-sort-dir":{type:"enum",values:["asc","desc"],fallback:"asc",description:"Default or requested sort direction"},"data-ln-sort-items":{prop:"itemsSelector",type:"string",read:u,description:"CSS selector matching sortable child items"},"data-ln-sort-state":{type:"enum",values:["asc","desc","none"],fallback:"none",effect:E,description:"Active sort state applied to column or control"},"data-ln-hash":{type:"string",effect:E,description:"URL hash routing key for sort state persistence"},"data-ln-query":{type:"string",effect:E,description:"URL query parameter name for sort state persistence"}},a=ce(o),h=new WeakMap;function p(d,g,s){if(g){const y=d.querySelector('[data-ln-field="'+g+'"]');return y?F(y):""}return s!=null&&d.cells&&d.cells[s]?F(d.cells[s]):F(d)}function A(d){this.dom=d,se(this,d,a);const g=d.closest("th");this.column=!this.field&&g?g.cellIndex:null,this._state=v(d.getAttribute(r)),d.hasAttribute(r)||d.setAttribute(r,this._state),this._destroyed=!1,this.nsKey=T(d,"sort"),this.hashEnabled=!!this.nsKey,this.queryParam=O(d,"sort"),this.queryEnabled=!!this.queryParam;const s=this;this._onClick=function(w){const b=w.target.closest("["+i+"]");if(!b)return;const f=v(b.getAttribute(i));s._apply(f)},d.addEventListener("click",this._onClick),this._onSortChange=function(w){if(s._destroyed||!w.detail)return;const b=s._resolveTarget();if(!(b&&(w.target===b||b.contains(w.target))||w.detail.targetId&&w.detail.targetId===s.targetId))return;if(Ze({field:s.field,column:s.column},{field:w.detail.field,column:w.detail.column})){const m=v(w.detail.direction);m&&d.getAttribute(r)!==m&&(s._state=m,d.setAttribute(r,m),s._updateAriaSort(m));return}d.getAttribute(r)!=="none"&&(s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none"))},document.addEventListener("ln-sort:change",this._onSortChange),this._onHashChange=function(){if(s._destroyed||!s.hashEnabled)return;const w=j(s.nsKey),b=U(w);if(b)s.field!==null&&b.fieldOrColumn===s.field||s.column!==null&&String(s.column)===b.fieldOrColumn?s._state!==b.direction&&s._apply(b.direction,!0):s._state!=="none"&&(s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none"));else if(s._state!=="none"){s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none");const f=s._resolveTarget();f&&(R(f,"ln-sort:change",{field:s.field,column:s.column,direction:"none",targetId:s.targetId}).defaultPrevented||s._defaultSort(f,"none"))}},this._onPopState=function(){if(s._destroyed||!s.queryEnabled)return;const w=H(s.queryParam),b=V(),f=W(w,b);if(f)s.field!==null&&f.fieldOrColumn===s.field||s.column!==null&&String(s.column)===f.fieldOrColumn?s._state!==f.direction&&s._apply(f.direction,!0):s._state!=="none"&&(s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none"));else if(s._state!=="none"){s._state="none",d.setAttribute(r,"none"),s._updateAriaSort("none");const C=s._resolveTarget();C&&(R(C,"ln-sort:change",{field:s.field,column:s.column,direction:"none",targetId:s.targetId}).defaultPrevented||s._defaultSort(C,"none"))}},this.hashEnabled&&window.addEventListener("hashchange",this._onHashChange),this.queryEnabled&&window.addEventListener("popstate",this._onPopState);let y=!1;if(this.hashEnabled){const w=j(this.nsKey),b=U(w);b&&((s.field!==null&&b.fieldOrColumn===s.field||s.column!==null&&String(s.column)===b.fieldOrColumn)&&I(function(){s._destroyed||s._apply(b.direction,!0)}),y=!0)}else if(this.queryEnabled){const w=H(this.queryParam),b=V(),f=W(w,b);f&&((s.field!==null&&f.fieldOrColumn===s.field||s.column!==null&&String(s.column)===f.fieldOrColumn)&&I(function(){s._destroyed||s._apply(f.direction,!0)}),y=!0)}if(!y){const w=v(d.getAttribute(r));w&&w!=="none"&&I(function(){s._destroyed||s._apply(w,!0)})}return this}A.prototype._resolveTarget=function(){return document.getElementById(this.targetId)},A.prototype._updateAriaSort=function(d){const g=this.dom.closest("th");g&&g.setAttribute("aria-sort",Ye(d))},A.prototype._apply=function(d,g){if(this._destroyed)return;if(!this.field&&this.column===null){const f=this.dom.closest("th");f&&f.cellIndex!==void 0&&(this.column=f.cellIndex)}const s=v(d);this._state=s,this.dom.getAttribute(r)!==s&&this.dom.setAttribute(r,s),this._updateAriaSort(s);const y=this._resolveTarget();if(!y)return;const w={field:this.field,column:this.column,direction:s,targetId:this.targetId};if(!g){if(this.hashEnabled){const f=ye(this.field!==null?this.field:this.column,s);me(this.nsKey,f)}else if(this.queryEnabled){const f=Ae(this.field!==null?this.field:this.column,s);Ce(this.queryParam,f)}}R(y,"ln-sort:change",w).defaultPrevented||this._defaultSort(y,s)},A.prototype._defaultSort=function(d,g){const s=tt(d,this.itemsSelector);if(!s.length)return;const y=s[0].parentNode,w=s.filter(function(f){return!K(f)});if(!w.length)return;h.has(d)||h.set(d,w.slice());let b;if(g==="none"){const f=h.get(d)||w;h.delete(d),b=f.filter(function(C){return C.parentNode===y&&!K(C)})}else{const f=this.field,C=this.column,m=w.map(function(_){return{el:_,val:p(_,f,C)}}),S=Ve(m.map(function(_){return _.val})),Q=typeof Intl<"u"?new Intl.Collator(Le(this.dom),{sensitivity:"base",numeric:!0}):null,x=et(g,S,Q,function(_){return _.val});m.sort(x),b=m.map(function(_){return _.el})}pe(function(){const f=document.createDocumentFragment();let C=0;for(let m=0;m<s.length;m++){const S=s[m];K(S)?f.appendChild(S):C<b.length&&f.appendChild(b[C++])}y.appendChild(f)})},A.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.dom.removeEventListener("click",this._onClick),document.removeEventListener("ln-sort:change",this._onSortChange),this.hashEnabled&&this._onHashChange&&window.removeEventListener("hashchange",this._onHashChange),this.queryEnabled&&this._onPopState&&window.removeEventListener("popstate",this._onPopState),delete this.dom[t])};function E(d,g){const s=d[t];if(!(!s||s._destroyed))if(g===n){const y=d.closest("th");s.column=!s.field&&y?y.cellIndex:null}else if(g===r){const y=v(d.getAttribute(r));y!==s._state&&s._apply(y)}else g===c?(s.hashEnabled&&s._onHashChange&&window.removeEventListener("hashchange",s._onHashChange),s.nsKey=T(d,"sort"),s.hashEnabled=!!s.nsKey,s.hashEnabled&&window.addEventListener("hashchange",s._onHashChange)):g===l&&(s.queryEnabled&&s._onPopState&&window.removeEventListener("popstate",s._onPopState),s.queryParam=O(d,"sort"),s.queryEnabled=!!s.queryParam,s.queryEnabled&&window.addEventListener("popstate",s._onPopState))}be(e,t,A,"ln-sort",{attributes:o,persist:{attr:r,hashActive:function(d){return!!T(d,"sort")||!!O(d,"sort")}}})})()})();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(){"use strict";function V(){if(typeof window>"u")return!1;if(window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink)return!0;if(typeof document<"u"){if(document.documentElement&&document.documentElement.hasAttribute("data-ln-debug"))return!0;if(document.body)return document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null}return!1}function F(t){if(typeof window>"u")return!1;if(window.lnDebug===!0)return!0;if(window.lnCore&&window.lnCore._debugIsContained)return t?window.lnCore._debugIsContained(t):window.lnCore._debugSink!==null;if(t&&t.closest){const e=t.closest("[data-ln-debug]");return!(!e||typeof document<"u"&&e===document.documentElement)}return typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug"):!1}if(typeof window<"u"&&(window.lnCore=window.lnCore||{},!window.lnCore._warnBound)){window.lnCore._warnBound=!0;const t=console.warn;console.warn=function(...e){if(typeof e[0]=="string"&&(e[0].startsWith("[ln-")||e[0].startsWith("[lnCore"))){let r=null;for(let a=1;a<e.length;a++)if(e[a]&&e[a].nodeType===1){r=e[a];break}if(!F(r))return}t.apply(console,e)}}function C(t,e,l){const r=l||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",e,t,r),t.dispatchEvent(new CustomEvent(e,{bubbles:!0,detail:r}))}function ut(t,e,l){t._applyFilterAndSort(),t._vStart=-1,t._vEnd=-1,t._render(),t._updateFooter();const r={sort:t.currentSort,filters:t.currentFilters,search:t.currentSearch};r[l]=t.name,C(t.dom,e,r)}function R(t,e){if(!document.body){document.addEventListener("DOMContentLoaded",function(){R(t,e)}),console.warn("["+e+'] Script loaded before <body> — add "defer" to your <script> tag');return}t()}function W(t){return t.hasAttribute("value")?t.getAttribute("value"):t.hasAttribute("data-ln-value")?t.getAttribute("data-ln-value"):t.tagName==="TIME"&&t.hasAttribute("datetime")?t.getAttribute("datetime"):t.textContent.trim()}function ht(t){const e=t.querySelector('input[name="_method"]');return((e&&e.value!==""?e.value:t.method)||"").toUpperCase()}function ft(t,e){const l=!!(e&&e.typed),r=e&&e.exclude,a={},u=t.elements,d={};if(l)for(let h=0;h<u.length;h++){const o=u[h];o.name&&o.type==="checkbox"&&!o.disabled&&(d[o.name]=(d[o.name]||0)+1)}for(let h=0;h<u.length;h++){const o=u[h];if(!(!o.name||o.disabled||o.type==="file"||o.type==="submit"||o.type==="button")&&!(r&&o.matches&&o.matches(r)))if(o.type==="checkbox")l&&d[o.name]===1?a[o.name]=o.checked:(a[o.name]||(a[o.name]=[]),o.checked&&a[o.name].push(o.value));else if(o.type==="radio")o.checked&&(a[o.name]=o.value);else if(o.type==="select-multiple"){a[o.name]=[];for(let i=0;i<o.options.length;i++)o.options[i].selected&&a[o.name].push(o.options[i].value)}else if(l&&o.type==="hidden")a[o.name]=o.value;else if(l&&(o.type==="number"||o.type==="range")){const i=Number(o.value);a[o.name]=o.value===""||isNaN(i)?null:i}else a[o.name]=o.value}return a}function bt(t){if(typeof t!="string")return!!t;const e=t.trim().toLowerCase();return e!=="false"&&e!=="0"&&e!==""&&e!=="off"&&e!=="no"}function pt(t,e){const l=t.elements,r=[],a={};for(let u=0;u<l.length;u++){const d=l[u];d.name&&d.type==="checkbox"&&(a[d.name]=(a[d.name]||0)+1)}for(let u=0;u<l.length;u++){const d=l[u];if(d.type==="file"||d.type==="submit"||d.type==="button")continue;const h=d.getAttribute("data-ln-fill-as")||d.name;if(!h||!(h in e))continue;const o=e[h];if(d.type==="checkbox"){if(Array.isArray(o))d.checked=o.indexOf(d.value)!==-1;else if(a[d.name]>1){const i=String(o).split(",").map(function(s){return s.trim()});d.checked=i.indexOf(d.value)!==-1}else d.checked=bt(o);r.push(d)}else if(d.type==="radio")d.checked=d.value===String(o),r.push(d);else if(d.type==="select-multiple"){if(Array.isArray(o))for(let i=0;i<d.options.length;i++)d.options[i].selected=o.indexOf(d.options[i].value)!==-1;r.push(d)}else d.value=o,d.tagName==="SELECT"&&o!=null&&d.setAttribute("data-ln-value",o),r.push(d)}return r}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.populateForm=pt,window.lnCore.serializeForm=ft,window.lnCore.resolveFormMethod=ht);const $={};function wt(t,e){$[t]=e}function _t(t){return $[t]||{ingress:e=>e,egress:e=>e}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=wt,window.lnCore.getDataMapper=_t);function gt(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,R(function(){new MutationObserver(function(){C(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const j={};function mt(t,e){if(!t||typeof e!="object")return;const l=t.toLowerCase().split("-")[0];j[l]=e}function yt(t){if(!t)return null;const e=t.toLowerCase().split("-")[0];return j[e]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=mt,window.lnCore.getLocaleFallback=yt,window.lnCore.ensureLocaleObserver=gt);const I={};function U(t,e){I[t]||(I[t]=document.querySelector('[data-ln-template="'+t+'"]'));const l=I[t];return l?l.content.cloneNode(!0):(console.warn("["+(e||"ln-core")+'] Template "'+t+'" not found'),null)}function T(t,e,l){if(t){const r=t.querySelector('[data-ln-template="'+e+'"]');if(r)return r.content.cloneNode(!0)}return U(e,l)}function z(t,e){if(!t||!e)return t;const l=t.querySelectorAll("[data-ln-field]");for(let d=0;d<l.length;d++){const h=l[d],o=h.getAttribute("data-ln-field");e[o]!=null&&(h.textContent=e[o])}const r=t.querySelectorAll("[data-ln-attr]");for(let d=0;d<r.length;d++){const h=r[d],o=h.getAttribute("data-ln-attr").split(",");for(let i=0;i<o.length;i++){const s=o[i].trim().split(":");if(s.length!==2)continue;const n=s[0].trim(),c=s[1].trim();e[c]!=null&&h.setAttribute(n,e[c])}}const a=t.querySelectorAll("[data-ln-show]");for(let d=0;d<a.length;d++){const h=a[d],o=h.getAttribute("data-ln-show");o in e&&h.classList.toggle("hidden",!e[o])}const u=t.querySelectorAll("[data-ln-class]");for(let d=0;d<u.length;d++){const h=u[d],o=h.getAttribute("data-ln-class").split(",");for(let i=0;i<o.length;i++){const s=o[i].trim().split(":");if(s.length!==2)continue;const n=s[0].trim(),c=s[1].trim();c in e&&h.classList.toggle(n,!!e[c])}}return t}function Ct(t,e){t.matches&&t.matches("[data-ln-form], [data-ln-fillable]")&&(window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",t,e??null),t.dispatchEvent(new CustomEvent("ln-fill",{detail:e??null,bubbles:!0})));const l=t.querySelectorAll("[data-ln-form], [data-ln-fillable]");for(let r=0;r<l.length;r++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",l[r],e??null),l[r].dispatchEvent(new CustomEvent("ln-fill",{detail:e??null,bubbles:!0}));return t}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._fillBound||(window.lnCore._fillBound=!0,document.addEventListener("ln-fill",function(t){if(!(!t.target.matches||!t.target.matches("[data-ln-fillable]")))if(t.detail)z(t.target,t.detail);else{const e=t.target.querySelectorAll("[data-ln-field]");for(let l=0;l<e.length;l++)e[l].textContent=""}})));function O(t,e){if(!t||!e)return t;const l=document.createTreeWalker(t,NodeFilter.SHOW_TEXT);for(;l.nextNode();){const u=l.currentNode;u.textContent.indexOf("{{")!==-1&&(u.textContent=u.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(d,h){return e[h]!==void 0?e[h]:""}))}const r=function(u,d){return e[d]!==void 0?e[d]:""},a=Array.from(t.querySelectorAll("*"));t.nodeType===1&&a.push(t);for(let u=0;u<a.length;u++){const d=a[u],h=d.attributes;for(let o=0;o<h.length;o++){const i=h[o];i.value.indexOf("{{")!==-1&&d.setAttribute(i.name,i.value.replace(/\{\{\s*(\w+)\s*\}\}/g,r))}}return t}function St(t,e,l,r,a,u){const d={};for(let o=0;o<t.children.length;o++){const i=t.children[o],s=i.getAttribute("data-ln-render-key");s&&(d[s]=i)}const h=document.createDocumentFragment();for(let o=0;o<e.length;o++){const i=e[o],s=String(r(i));let n=d[s];if(n)a(n,i,o);else{const c=U(l,u);if(!c||(O(c,i),n=c.firstElementChild,!n))continue;n.setAttribute("data-ln-render-key",s),a(n,i,o)}h.appendChild(n)}t.textContent="",t.appendChild(h)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=O,window.lnCore.fill=z,window.lnCore.lnFill=Ct,window.lnCore.renderList=St);function D(t,e,l){const r=t.getAttribute(e);return r===null?l:r}function Q(t,e,l){const r=parseInt(t.getAttribute(e),10);return isNaN(r)?l:r}function N(t,e,l=!1){const r=t.getAttribute(e);if(r===null)return!!l;const a=r.trim().toLowerCase();return!(a==="false"||a==="0")}function K(t,e){return(t.getAttribute(e)||"").split(",").map(l=>l.trim()).filter(Boolean)}const H=new Map;function J(t,e){const l=(t?t.join("|"):"")+"::"+e;if(H.has(l))return H.get(l);const r=new Set(t||[]),a=function(u,d){const h=u.getAttribute(d);return h!==null&&r.has(h)?h:e};return H.set(l,a),a}function G(t,e,l){const r=parseFloat(t.getAttribute(e));return isNaN(r)?l:r}function Y(t,e,l){const r=t.getAttribute(e);if(!r)return l;try{return JSON.parse(r)}catch{return l}}function X(t,e,l,r,a){if(!t||e===null)return!0;const u=r||"ln-component",d=t.type;if(d==="trigger"||d==="marker"||d==="string"||d==="list"||!d||e===""&&t.fallback!==void 0)return!0;const h=o=>{a?console.warn(o,a):console.warn(o)};if(d==="boolean"){const o=e.trim().toLowerCase();return o!==""&&o!=="true"&&o!=="false"&&o!=="1"&&o!=="0"?(h(`[${u}] Invalid value "${e}" for boolean attribute "${l}". Allowed: "true", "false", or presence-only.`),!1):!0}if(d==="enum"){const o=t.values||[];return o.includes(e)?!0:(h(`[${u}] Invalid value "${e}" for attribute "${l}". Allowed: ${o.join(", ")}. Fallback: "${t.fallback}".`),!1)}if(d==="integer"){if(!/^-?\d+$/.test(e))return h(`[${u}] Invalid integer "${e}" for attribute "${l}". Fallback: ${t.fallback}.`),!1;const o=parseInt(e,10);return t.min!==void 0&&o<t.min?(h(`[${u}] Value ${o} for attribute "${l}" is less than min (${t.min}).`),!1):t.max!==void 0&&o>t.max?(h(`[${u}] Value ${o} for attribute "${l}" is greater than max (${t.max}).`),!1):!0}if(d==="float")return isNaN(Number(e))?(h(`[${u}] Invalid float "${e}" for attribute "${l}". Fallback: ${t.fallback}.`),!1):!0;if(d==="json")try{return JSON.parse(e),!0}catch(o){return h(`[${u}] Invalid JSON for attribute "${l}": ${o.message}. Fallback: ${t.fallback}.`),!1}return!0}function Z(t,e,l){for(const r in l){const[a,u,d]=l[r];Object.defineProperty(t,r,{get:function(){return a(e,u,d)},enumerable:!0,configurable:!0})}return t}function tt(t){const e={};for(const l in t){const r=t[l];if(!r||!r.prop)continue;let a=r.read;if(!a&&r.type)switch(r.type){case"enum":a=J(r.values,r.fallback);break;case"integer":a=Q;break;case"float":a=G;break;case"boolean":a=N;break;case"list":a=K;break;case"json":a=Y;break;case"string":default:a=D;break}a||(a=D),e[r.prop]=[a,l,r.fallback]}return e}function At(t){const e={};for(const l in t){const r=t[l];r&&r.effect&&(e[l]=r.effect)}return Object.keys(e).length?e:null}function vt(t){if(t.onAttrChange&&!t.declared)return null;const e=new Set;if(t.effects)for(const l in t.effects)e.add(l);if(t.onAttrChange&&t.declared)for(const l of t.declared)e.add(l);return e}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.defineAttrs=Z,window.lnCore.attrSpec=tt,window.lnCore.attrStr=D,window.lnCore.attrInt=Q,window.lnCore.attrBool=N,window.lnCore.attrList=K,window.lnCore.attrEnum=J,window.lnCore.attrFloat=G,window.lnCore.attrJson=Y);function q(t,e){if(!t[e.attribute]){window.lnCore._persistSink&&t.hasAttribute&&t.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(t,e.selector);try{t[e.attribute]=new e.ComponentFn(t)}catch(l){console.error("["+e.attribute+"] init failed",t,l)}}}function et(t,e,l,r){if(t.nodeType!==1)return;const u=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]",d={selector:e,attribute:l,ComponentFn:r};if(t.matches&&t.matches(u)&&q(t,d),t.querySelectorAll){const h=t.querySelectorAll(u);for(let o=0;o<h.length;o++)q(h[o],d)}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function Tt(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function xt(t){typeof window<"u"?(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[],window.lnCore._bootHolds>0?window.lnCore._bootQueue.push(t):setTimeout(t,0)):t()}function nt(){window.lnCore=window.lnCore||{};const t=window.lnCore._attrRegistry=window.lnCore._attrRegistry||{byAttr:new Map,reactive:[],persist:[]};return t.byReactive=t.byReactive||new Map,t.reactiveWildcard=t.reactiveWildcard||[],t}function Et(t){const e=nt(),l=t.observed||[];for(let r=0;r<l.length;r++){const a=l[r];e.byAttr.has(a)||e.byAttr.set(a,[]),e.byAttr.get(a).push(t)}if(e.byDeclaredAttr=e.byDeclaredAttr||new Map,t.attributes)for(const r in t.attributes){e.byDeclaredAttr.has(r)||e.byDeclaredAttr.set(r,[]);const a=e.byDeclaredAttr.get(r);a.some(u=>u.componentTag===t.componentTag)||a.push({spec:t.attributes[r],componentTag:t.componentTag})}if(t.onAttrChange||t.effects){e.reactive.push(t);const r=vt(t);if(r===null)e.reactiveWildcard.push(t);else for(const a of r)e.byReactive.has(a)||e.byReactive.set(a,[]),e.byReactive.get(a).push(t)}t.persist&&e.persist.push(t)}function it(t,e,l,r){for(let a=0;a<t.length;a++){const u=t[a];if(!e[u.attribute])continue;const d=u.effects&&u.effects[l];d?d(e,l,r):u.onAttrChange&&(!u.declared||u.declared.has(l))&&u.onAttrChange(e,l,r)}}function Lt(t){const e=t.attributeName,l=e.indexOf("data-ln-")===0,r=nt(),a=r.byAttr.get(e),u=V()&&r.byDeclaredAttr&&r.byDeclaredAttr.has(e);if(!l&&!a&&!u)return;const d=t.target;if(t.oldValue!==d.getAttribute(e)){if(u&&F(d)){const h=r.byDeclaredAttr.get(e),o=d.getAttribute(e);for(let i=0;i<h.length;i++)X(h[i].spec,o,e,h[i].componentTag,d)}if(window.lnCore._debugSink&&(l||a)&&window.lnCore._debugSink("attr",e,d,{oldValue:t.oldValue,newValue:d.getAttribute(e)}),l){const h=r.byReactive.get(e);h&&it(h,d,e,t.oldValue),r.reactiveWildcard.length&&it(r.reactiveWildcard,d,e,t.oldValue)}if(a)for(let h=0;h<a.length;h++){const o=a[h];if(o.handler){o.handler(d,e,t.oldValue);continue}o.onAttributeChange&&d[o.attribute]?o.onAttributeChange(d,e):(et(d,o.selector,o.attribute,o.ComponentFn),o.onInit&&o.onInit(d))}}}function kt(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,R(function(){new MutationObserver(function(e){for(let l=0;l<e.length;l++)try{Lt(e[l])}catch(r){console.error("[ln-core] mutation handler failed",e[l].target,r)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function M(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function B(){return window.lnCore=window.lnCore||{},window.lnCore._subtreeRegistry=window.lnCore._subtreeRegistry||[]}function lt(t,e){if(!document.contains(t))if(e.attribute){const l=t[e.attribute];if(l&&typeof l.destroy=="function")try{l.destroy()}catch(r){console.error("["+e.attribute+"] destroy failed",t,r)}delete t[e.attribute]}else e.onDestroy&&e.onDestroy(t)}function ot(t){const e=M();if(!e.length)return;const l=t.target;if(l){const a=l.nodeType===1?l:l.parentElement;if(a&&(a.isContentEditable||a.closest&&a.closest('[contenteditable]:not([contenteditable="false"])')))return}const r=B();if(t.target&&r.length)for(let a=0;a<r.length;a++){const u=r[a],d=u.query,h=t.target.nodeType===1?t.target.matches&&t.target.matches(d)?t.target:t.target.closest?t.target.closest(d):null:t.target.parentElement&&t.target.parentElement.closest?t.target.parentElement.closest(d):null;h&&u.onSubtreeChange(h,t)}for(let a=0;a<t.addedNodes.length;a++){const u=t.addedNodes[a];if(u.nodeType!==1)continue;const d=!!(u.firstElementChild||u.children&&u.children.length);for(let h=0;h<e.length;h++){const o=e[h],i=o.query;if(i&&(u.matches&&u.matches(i)&&(o.ComponentFn&&q(u,o),o.onInit&&o.onInit(u)),d&&u.querySelectorAll)){const s=u.querySelectorAll(i);for(let n=0;n<s.length;n++)o.ComponentFn&&q(s[n],o),o.onInit&&o.onInit(s[n])}}}for(let a=0;a<t.removedNodes.length;a++){const u=t.removedNodes[a];if(u.nodeType!==1||document.contains(u))continue;const d=!!(u.firstElementChild||u.children&&u.children.length);for(let h=0;h<e.length;h++){const o=e[h],i=o.query;if(i&&(u.matches&&u.matches(i)&<(u,o),d&&u.querySelectorAll)){const s=u.querySelectorAll(i);for(let n=0;n<s.length;n++)lt(s[n],o)}}}}function rt(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,R(function(){const t=new MutationObserver(function(e){for(let l=0;l<e.length;l++){const r=e[l];if(r.type==="childList")try{ot(r)}catch(a){console.error("[ln-core] lifecycle handler failed",r.target,a)}}});window.lnCore._lifecycleObserver=t,t.observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function Dt(t){if(typeof window>"u")return t();window.lnCore=window.lnCore||{};const e=window.lnCore._lifecycleObserver;if(!e)return t();const l=e.takeRecords();for(let r=0;r<l.length;r++){const a=l[r];if(a.type==="childList")try{ot(a)}catch(u){console.error("[ln-core] lifecycle handler failed",a.target,u)}}e.disconnect();try{return t()}finally{e.observe(document.body,{childList:!0,subtree:!0})}}function Rt(t){M().push(t),t.onSubtreeChange&&t.query&&B().push(t),rt()}function st(t,e,l,r,a={}){const u=a.extraAttributes||[],d=a.onAttributeChange||null,h=a.onSubtreeChange||null,o=a.onInit||null,i=a.onAttrChange||null,s=a.effects||null,n=a.attributes||null,c=n?At(n):s,f=n?new Set(Object.keys(n)):null,w=a.persist||null;function p(x){const m=x||document.body;if(et(m,t,e,l),n&&V())for(const y in n){const A=n[y],v=Array.from(m.querySelectorAll("["+y+"]"));m.matches&&m.matches("["+y+"]")&&v.push(m);for(let k=0;k<v.length;k++){const L=v[k];F(L)&&X(A,L.getAttribute(y),y,r,L)}}o&&o(m)}const b=[];if(t.indexOf("[")!==-1){const x=/\[([\w-]+)/g;let m;for(;(m=x.exec(t))!==null;)b.push(m[1])}else b.push(t);Et({selector:t,attribute:e,componentTag:r,attributes:n,ComponentFn:l,onInit:o,observed:b.concat(u),onAttributeChange:d,onAttrChange:i,effects:c,declared:f,persist:w}),kt();const _=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1,g=a.subtreeQuery||(_?t:"["+t+"]"),S={selector:t,attribute:e,ComponentFn:l,onInit:o,onSubtreeChange:h,query:g};M().push(S),h&&g&&B().push(S),rt(),window[e]=p,typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerComponent=st,window.lnCore.observeLifecycle=Rt,window.lnCore.withoutLifecycle=Dt);function E(){Tt()>0?xt(function(){p(document.body)}):p(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",E):E(),p}function at(t){return(t||"").replace(/^#/,"")}function P(t){const e=t===void 0?location.hash:t,l={},r=at(e);if(!r)return l;const a=r.split("&");for(let u=0;u<a.length;u++){const d=a[u];if(!d)continue;const h=d.indexOf(":"),o=h>-1?d.slice(0,h):d,i=h>-1?d.slice(h+1):"";if(o)try{l[o]=decodeURIComponent(i)}catch{l[o]=i}}return l}function qt(t){if(!t)return null;const e=P();return t in e?e[t]:null}function Ft(t,e){if(!t)return;const l=P();e==null?delete l[t]:l[t]=String(e);const a=Object.keys(l).map(function(u){const d=l[u];return d===""?u:u+":"+encodeURIComponent(d)}).join("&");at(location.hash)!==a&&(location.hash=a)}function It(t){return t.button===1||t.ctrlKey||t.metaKey||t.shiftKey?!1:(t.preventDefault(),!0)}function Ot(t,e){if(!t||!t.hasAttribute("data-ln-hash"))return null;const l=t.getAttribute("data-ln-hash");if(l&&l.trim()!=="")return l.trim();const r=t.getAttribute("data-ln-sort")||t.getAttribute("data-ln-search-for")||t.getAttribute("data-ln-search")||t.getAttribute("data-ln-filter")||t.id;return r?e?r+"-"+e:r:e||null}function Nt(t,e){return!e||e==="none"||t===null||t===void 0?null:String(t)+"."+e}function Ht(t){return!t||typeof t!="string"?null:t.endsWith(".asc")?{fieldOrColumn:t.slice(0,-4),direction:"asc"}:t.endsWith(".desc")?{fieldOrColumn:t.slice(0,-5),direction:"desc"}:null}function Mt(t,e){return!t||!Array.isArray(e)||e.length===0?null:t+":"+e.map(encodeURIComponent).join(",")}function Bt(t){if(!t||typeof t!="string")return null;const e=t.indexOf(":");if(e===-1)return null;const l=t.slice(0,e),r=t.slice(e+1),a=r?r.split(",").map(function(u){try{return decodeURIComponent(u)}catch{return u}}).filter(Boolean):[];return{key:l,values:a}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=P,window.lnCore.hashGet=qt,window.lnCore.hashSet=Ft,window.lnCore.hashLinkClick=It,window.lnCore.resolveHashNamespace=Ot,window.lnCore.hashSortEncode=Nt,window.lnCore.hashSortDecode=Ht,window.lnCore.hashFilterEncode=Mt,window.lnCore.hashFilterDecode=Bt);function Pt(t){return(t||"").replace(/^\?/,"")}function Vt(t){const e=t===void 0?typeof window<"u"?window.location.search:"":t,l={},r=Pt(e);if(!r)return l;const a=new URLSearchParams(r);for(const[u,d]of a.entries())l[u]=d;return l}function Wt(t){if(!t||typeof window>"u")return null;const e=new URLSearchParams(window.location.search);return e.has(t)?e.get(t):null}function $t(t,e){if(!t||typeof window>"u")return;const l=new URL(window.location.href);if(e==null||e===""?l.searchParams.delete(t):l.searchParams.set(t,String(e)),l.search===window.location.search)return;const r=l.pathname+l.search+l.hash;window.history.replaceState(window.history.state,"",r)}function jt(t,e){if(!t||!t.hasAttribute("data-ln-query"))return null;const l=t.getAttribute("data-ln-query");if(l&&l.trim()!=="")return l.trim();const r=t.getAttribute("data-ln-sort")||t.getAttribute("data-ln-search-for")||t.getAttribute("data-ln-search")||t.getAttribute("data-ln-filter")||t.id;return r?e?r+"_"+e:r:e||null}function Ut(t,e){return!e||e==="none"||t===null||t===void 0?null:String(t)+"."+e}function zt(t,e){if(t&&typeof t=="string"){if(t.endsWith(".asc"))return{fieldOrColumn:t.slice(0,-4),direction:"asc"};if(t.endsWith(".desc"))return{fieldOrColumn:t.slice(0,-5),direction:"desc"}}if(e&&typeof e=="object"){const l=e.sort_field||e.sort_by;if(l){const r=e.sort_dir&&String(e.sort_dir).toLowerCase()==="desc"?"desc":"asc";return{fieldOrColumn:l,direction:r}}}return null}function Qt(t){return!Array.isArray(t)||t.length===0?null:t.map(encodeURIComponent).join(",")}function Kt(t){return!t||typeof t!="string"?[]:t.split(",").map(function(e){try{return decodeURIComponent(e.trim())}catch{return e.trim()}}).filter(Boolean)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.queryParse=Vt,window.lnCore.queryGet=Wt,window.lnCore.querySet=$t,window.lnCore.resolveQueryParam=jt,window.lnCore.querySortEncode=Ut,window.lnCore.querySortDecode=zt,window.lnCore.queryFilterEncode=Qt,window.lnCore.queryFilterDecode=Kt);function Jt(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{const e=Math.random()*16|0;return(t==="x"?e:e&3|8).toString(16)})}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.uuid=Jt);function Gt(t,e,l,r,a=15){if(r<=0||l<=0)return{start:0,end:0,topPadding:0,bottomPadding:0};const u=Math.max(0,t||0),d=Math.max(0,e||0),h=Math.floor(u/l),o=Math.ceil(d/l),i=Math.max(0,h-a),s=Math.min(r,h+o+a),n=i*l,c=Math.max(0,(r-s)*l);return{start:i,end:s,topPadding:n,bottomPadding:c}}function Yt(t,e){const l=Array.isArray(t)?t.length:0,r=e instanceof Set?e:new Set(e||[]);let a=0;if(Array.isArray(t))for(let h=0;h<t.length;h++)r.has(t[h])&&a++;else a=r.size;const u=l>0&&a===l,d=a>0&&a<l;return{totalCount:l,selectedCount:a,isAllSelected:u,isIndeterminate:d}}function ct(t,e,l){const r=new Set(t);return e==null||((l!==void 0?l:!r.has(e))?r.add(e):r.delete(e)),r}function dt(t,e,l){const r=new Set(t);if(!Array.isArray(e))return r;if(l)for(let a=0;a<e.length;a++)e[a]!=null&&r.add(e[a]);else for(let a=0;a<e.length;a++)r.delete(e[a]);return r}(function(){const t="data-ln-table",e="lnTable";if(window[e]!==void 0)return;const a={"data-ln-table":{prop:"name",type:"string",read:D,fallback:"",description:"Table instance name or identifier"},"data-ln-table-source":{prop:"source",type:"string",read:D,fallback:"",description:"Source store or coordinator addressing"},"data-ln-table-selectable":{prop:"_selectable",type:"boolean",read:N,description:"Enables row selection check controls"},"data-ln-table-row":{type:"marker",description:"Table row template element"},"data-ln-table-row-id":{type:"string",description:"Record identifier on row element"},"data-ln-table-row-action":{type:"trigger",description:"Action trigger inside a table row"},"data-ln-table-row-select":{type:"trigger",description:"Row selection checkbox trigger"},"data-ln-table-col":{type:"string",description:"Column header identifier or field mapping"},"data-ln-table-col-select":{type:"trigger",description:"Header select-all checkbox trigger"},"data-ln-table-cell-attr":{type:"string",description:"Cell attribute template mapping"},"data-ln-table-select-all-label":{type:"string",description:"Accessibility label for select-all header trigger"}},u=tt(a);typeof Intl<"u"&&new Intl.Collator(document.documentElement.lang||void 0,{sensitivity:"base"});function d(i,s){if(!i)return;if(s==null||isNaN(s)){i.removeAttribute("data-ln-value"),"value"in i&&i.tagName==="DATA"&&(i.value=""),i.lnNumber?i.lnNumber.value=NaN:i.textContent="";return}const n=String(s);i.setAttribute("data-ln-value",n),"value"in i&&i.tagName==="DATA"&&(i.value=n),i.lnNumber?i.lnNumber.value=s:i.textContent=n}function h(i,s){let n=s?s.parentElement:i;for(;n&&n!==document.body&&n!==document.documentElement;){const f=getComputedStyle(n).overflowY;if(f==="auto"||f==="scroll")return n;n=n.parentElement}return null}function o(i){this.dom=i,Z(this,i,u),this.table=i.querySelector("table"),this.tbody=i.querySelector("[data-ln-table-body]")||i.querySelector("tbody"),this.thead=i.querySelector("thead");const s=this.thead?this.thead.querySelector("tr:last-child"):null;this.ths=s?Array.from(s.querySelectorAll("th")):[],this._totalSpan=i.querySelector("[data-ln-table-total]"),this._filteredSpan=i.querySelector("[data-ln-table-filtered]"),this._filteredSpan&&(this._filteredWrap=this._filteredSpan.parentElement!==i?this._filteredSpan.parentElement:null),this._selectedSpan=i.querySelector("[data-ln-table-selected]"),this._selectedSpan&&(this._selectedWrap=this._selectedSpan.parentElement!==i?this._selectedSpan.parentElement:null),this._loadingIndicator=i.querySelector("[data-ln-table-loading]"),this._loadingIndicator&&this._loadingIndicator.classList.add("hidden"),this.isDataDriven=i.hasAttribute("data-ln-table-source"),this._data=[],this._filteredData=[],this._searchTerm="",this._sortCol=-1,this._sortDir=null,this._columnFilters={},this.selectedIds=new Set,this._virtual=!1,this._rowHeight=0,this._vStart=-1,this._vEnd=-1,this._rafId=null,this._scrollHandler=null,this._resizeHandler=null,this._vResized=!1,this._vTop=0,this._scrollContainer=null,this._colgroup=null,this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const n=this;return this._onSetSearch=function(c){const f=(c.detail&&c.detail.query!=null?c.detail.query:c.detail&&c.detail.term!=null?c.detail.term:"").trim();n.isDataDriven?(n.currentSearch=f,C(i,"ln-table:search",{table:n.name,query:n.currentSearch}),n._requestData()):(n._searchTerm=f.toLowerCase(),n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),n._updateFooter(),C(i,"ln-table:filter",{term:n._searchTerm,matched:n._filteredData.length,total:n._data.length}))},i.addEventListener("ln-table:set-search",this._onSetSearch),this._onSearchChange=function(c){c.preventDefault(),n._onSetSearch(c)},i.addEventListener("ln-search:change",this._onSearchChange),this._onRequestClearFilters=function(){n.isDataDriven?(n.currentFilters={},n.currentSearch="",C(i,"ln-table:clear-filters",{table:n.name}),n._requestData()):(n._searchTerm="",n._columnFilters={},n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),n._updateFooter(),C(i,"ln-table:filter",{term:"",matched:n._filteredData.length,total:n._data.length}))},i.addEventListener("ln-table:request-clear-filters",this._onRequestClearFilters),this._selectableActive=!1,this._selectable&&this._enableSelection(),this.isDataDriven?(this.isLoaded=!1,this._initialLoaded=!1,this.totalCount=0,this.visibleCount=0,this.currentSort=null,this.currentFilters={},this.currentSearch="",this._lastTotal=0,this._lastFiltered=0,this._hasInitialSeed=!1,this._onSetData=function(c){const f=c.detail||{},w=f.data||[],p=f.total!=null?f.total:w.length;n._hasInitialSeed&&!n.isLoaded&&w.length===0&&p===0||(n._data=w,n._lastTotal=p,n._lastFiltered=f.filtered!=null?f.filtered:n._data.length,n.totalCount=n._lastTotal,n.visibleCount=n._lastFiltered,n.isLoaded=!0,n._initialLoaded=!0,n._hasInitialSeed=!1,i.classList.remove("ln-table--loading"),i.setAttribute("aria-busy","false"),n._loadingIndicator&&n._loadingIndicator.classList.add("hidden"),n._vStart=-1,n._vEnd=-1,n._applyFilterAndSort(),n._render(),n._updateFooter(),C(i,"ln-table:rendered",{table:n.name,total:n.totalCount,visible:n.visibleCount}))},i.addEventListener("ln-table:set-data",this._onSetData),this._onSetLoading=function(c){const f=!!(c.detail&&c.detail.loading);i.classList.toggle("ln-table--loading",f),i.setAttribute("aria-busy",f?"true":"false"),f&&!n._initialLoaded&&(n.isLoaded=!1,n._showLoadingState()),n._loadingIndicator&&n._loadingIndicator.classList.toggle("hidden",!(f&&n._initialLoaded))},i.addEventListener("ln-table:set-loading",this._onSetLoading),this._onSort=function(c){!c.detail||c.detail.field==null||(c.preventDefault(),n.currentSort=c.detail.direction==="none"?null:{field:c.detail.field,direction:c.detail.direction},n._requestData())},i.addEventListener("ln-sort:change",this._onSort),this._onRowClick=function(c){if(c.target.closest("[data-ln-table-row-select]")||c.target.closest("[data-ln-table-row-action]")||c.target.closest("a")||c.target.closest("button")||c.ctrlKey||c.metaKey||c.button===1)return;const f=c.target.closest("[data-ln-table-row]");if(!f)return;const w=f.getAttribute("data-ln-table-row-id"),p=f._lnRecord||{};C(i,"ln-table:row-click",{table:n.name,id:w,record:p})},this.tbody&&this.tbody.addEventListener("click",this._onRowClick),this._onRowAction=function(c){const f=c.target.closest("[data-ln-table-row-action]");if(!f)return;const w=f.closest("[data-ln-table-row]");if(!w)return;const p=f.getAttribute("data-ln-table-row-action"),b=w.getAttribute("data-ln-table-row-id"),_=w._lnRecord||{};C(i,"ln-table:row-action",{table:n.name,id:b,action:p,record:_})},this.tbody&&this.tbody.addEventListener("click",this._onRowAction),this.tbody&&this.tbody.rows.length>0?this._parseRows():(this._showLoadingState(),i.setAttribute("aria-busy","true")),setTimeout(function(){!n.dom||!document.contains(n.dom)||C(i,"ln-table:request-data",{table:n.name,sort:n.currentSort,filters:n.currentFilters,search:n.currentSearch})},0)):(this._emptyTbodyObserver=null,this.tbody&&this.tbody.rows.length>0?this._parseRows():this.tbody&&(this._emptyTbodyObserver=new MutationObserver(function(){n.tbody.rows.length>0&&(n._emptyTbodyObserver.disconnect(),n._emptyTbodyObserver=null,n._parseRows())}),this._emptyTbodyObserver.observe(this.tbody,{childList:!0})),this._onSort=function(c){if(!c.detail||c.detail.column==null)return;c.preventDefault();const f=c.detail.direction==="none"?null:c.detail.direction;n._sortCol=f===null?-1:c.detail.column,n._sortDir=f,n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),C(i,"ln-table:sorted",{column:c.detail.column,direction:c.detail.direction,matched:n._filteredData.length,total:n._data.length})},i.addEventListener("ln-sort:change",this._onSort),this._onFilterChange=function(c){if(c.preventDefault(),!c.detail)return;const f=c.detail.key,w=c.detail.values||[];if(f){if(w.length===0)delete n._columnFilters[f];else{const p=[];for(let b=0;b<w.length;b++)p.push(w[b].toLowerCase());n._columnFilters[f]=p}n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),n._updateFooter(),C(i,"ln-table:filter",{term:n._searchTerm,matched:n._filteredData.length,total:n._data.length})}},i.addEventListener("ln-filter:change",this._onFilterChange)),this}o.prototype._parseRows=function(){const i=this.tbody.rows,s=this.ths;this._data=[],i.length>0&&(this._rowHeight=i[0].offsetHeight||40),this._lockColumnWidths();for(let n=0;n<i.length;n++){const c=i[n],f=[],w=[],p=[];for(let _=0;_<c.cells.length;_++){const g=c.cells[_],S=g.textContent.trim();f[_]=W(g),w[_]=S.toLowerCase(),g.querySelector("[data-ln-table-row-action]")||p.push(S.toLowerCase())}let b=null;if(this.isDataDriven){b={};const _=c.getAttribute("data-ln-table-row-id");_!=null&&(b.id=_);for(let g=0;g<s.length;g++){const S=s[g].getAttribute("data-ln-table-col");if(S){const E=g;if(E<c.cells.length){const x=c.cells[E];b[S]=W(x)}}}}this._data.push({values:f,rawTexts:w,html:c.outerHTML,searchText:p.join(" "),id:this.isDataDriven&&b?b.id:void 0,...b})}this._filteredData=this._data.slice(),this._data.length>0&&(this._hasInitialSeed=!0),this.isDataDriven&&(this._lastTotal=this._data.length,this._lastFiltered=this._data.length,this.totalCount=this._data.length,this.visibleCount=this._data.length,this._updateFooter()),this._render(),C(this.dom,"ln-table:ready",{total:this._data.length})},o.prototype._applyFilterAndSort=function(){this._filteredData=this._data?this._data.slice():[],this.visibleCount=this.isDataDriven&&this._lastFiltered!=null?this._lastFiltered:this._filteredData.length},o.prototype._lockColumnWidths=function(){if(!this.table||!this.thead||this._colgroup||this.ths.length&&!this.ths[0].offsetWidth)return;const i=document.createElement("colgroup");this.ths.forEach(function(s){const n=document.createElement("col");n.style.width=s.offsetWidth+"px",i.appendChild(n)}),this.table.insertBefore(i,this.table.firstChild),this.table.style.tableLayout="fixed",this._colgroup=i},o.prototype._render=function(){if(this.tbody)if(this.isDataDriven){const i=this._lastTotal,s=this.visibleCount;if(i===0){if(this._disableVirtualScroll(),!this.isLoaded){this._showLoadingState();return}this._showEmptyState();return}if(this._filteredData.length===0||s===0){if(this._disableVirtualScroll(),!this.isLoaded){this._showLoadingState();return}this._showEmptyState();return}this._filteredData.length>200?(this._enableVirtualScroll(),this._renderVirtual()):(this._disableVirtualScroll(),this._renderAll())}else{const i=this._filteredData.length;i===0&&(this._searchTerm||Object.keys(this._columnFilters).length>0)?(this._disableVirtualScroll(),this._showEmptyState()):i>200?(this._enableVirtualScroll(),this._renderVirtual()):(this._disableVirtualScroll(),this._renderAll())}},o.prototype._renderAll=function(){this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const i=this._filteredData;if(this.isDataDriven||i.length>0&&!i[0].html){const s=document.createDocumentFragment();for(let n=0;n<i.length;n++){const c=this._buildRow(i[n]);if(!c)break;s.appendChild(c)}this.tbody.replaceChildren(s),this._selectable&&this._updateSelectAll()}else{const s=[];for(let n=0;n<i.length;n++)s.push(i[n].html);this.tbody.innerHTML=s.join(""),this._selectable&&this._restoreSelection()}},o.prototype._enableVirtualScroll=function(){if(this._virtual)return;this._virtual=!0,this._vStart=-1,this._vEnd=-1;const i=this;if(!this._rowHeight)if(this.tbody&&this.tbody.rows.length>0)this._rowHeight=this.tbody.rows[0].offsetHeight||40;else{let n=null;this.isDataDriven&&this._data.length>0&&(n=this._buildRow(this._data[0])),n&&this.tbody&&(this.tbody.appendChild(n),this._rowHeight=n.offsetHeight||40,n.remove())}this._scrollContainer=h(this.dom,this.table);const s=this._scrollContainer||window;this.dom&&(this.dom.style.overflowAnchor="none"),this.table&&(this.table.style.overflowAnchor="none"),this.tbody&&(this.tbody.style.overflowAnchor="none"),this._scrollContainer&&(this._scrollContainer.style.overflowAnchor="none"),this._scrollHandler=function(){i._rafId||(i._rafId=requestAnimationFrame(function(){i._rafId=null,i._renderVirtual()}))},this._resizeHandler=function(){i._lockColumnWidths(),i._vResized=!0,i._scrollHandler()},s.addEventListener("scroll",this._scrollHandler,{passive:!0}),window.addEventListener("resize",this._resizeHandler,{passive:!0})},o.prototype._disableVirtualScroll=function(){this._virtual&&(this._virtual=!1,this._scrollHandler&&((this._scrollContainer||window).removeEventListener("scroll",this._scrollHandler),window.removeEventListener("resize",this._resizeHandler),this._scrollHandler=null,this._resizeHandler=null),this._scrollContainer=null,this._rafId&&(cancelAnimationFrame(this._rafId),this._rafId=null),this._vStart=-1,this._vEnd=-1,this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null)},o.prototype._compileRowBindings=function(i){const s={textNodes:[],attrs:[],cellAttrs:[]},n=document.createTreeWalker(i,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const f=n.currentNode;if(f.textContent.indexOf("{{")!==-1){const w=f.parentElement;s.textNodes.push({node:f,raw:f.textContent,el:w,isLeaf:!!(w&&w.children.length===0)})}}const c=Array.from(i.querySelectorAll("*"));i.nodeType===1&&c.push(i);for(let f=0;f<c.length;f++){const w=c[f];if(w.hasAttribute("data-ln-table-cell-attr")){const b=w.getAttribute("data-ln-table-cell-attr").split(",");for(let _=0;_<b.length;_++){const g=b[_].trim().split(":");g.length===2&&s.cellAttrs.push({el:w,field:g[0].trim(),attr:g[1].trim()})}}const p=w.attributes;for(let b=0;b<p.length;b++){const _=p[b];_.value.indexOf("{{")!==-1&&s.attrs.push({el:w,name:_.name,raw:_.value})}}return i._lnBindings=s,s},o.prototype._createTemplateRow=function(){let i=T(this.dom,this.name+"-row","ln-table");if(!i){const n=this.dom.querySelector("template[data-ln-table-row]");n&&(i=document.importNode(n.content,!0))}let s=i?i.querySelector("[data-ln-table-row]")||i.firstElementChild:null;return s?(this._compileRowBindings(s),s):((window.lnDebug||typeof document<"u"&&document.body&&document.body.hasAttribute("data-ln-debug"))&&console.warn(`[ln-table] Missing row template: <template data-ln-template="${this.name}-row">`),null)},o.prototype._updateRow=function(i,s){if(!s)return;i._lnRecord=s,s.id!=null&&i.setAttribute("data-ln-table-row-id",s.id);const n=i._lnBindings||this._compileRowBindings(i),c=n.textNodes;for(let p=0;p<c.length;p++){const b=c[p],_=b.raw.replace(/\{\{\s*(\w+)\s*\}\}/g,function(g,S){return s[S]!==void 0&&s[S]!==null?s[S]:""});b.isLeaf&&b.el?b.el.textContent=_:b.node&&b.node.parentNode?b.node.textContent=_:b.el&&(b.el.textContent=_)}const f=n.attrs;for(let p=0;p<f.length;p++){const b=f[p];b.el.setAttribute(b.name,b.raw.replace(/\{\{\s*(\w+)\s*\}\}/g,function(_,g){return s[g]!==void 0&&s[g]!==null?s[g]:""}))}const w=n.cellAttrs;for(let p=0;p<w.length;p++){const b=w[p],_=s[b.field];_!=null&&b.el.setAttribute(b.attr,_)}if(n.textNodes.length===0&&n.attrs.length===0&&this.ths.length>0)for(let p=0;p<this.ths.length;p++){const b=this.ths[p].getAttribute("data-ln-table-col");b&&p<i.cells.length&&s[b]!=null&&(i.cells[p].textContent=String(s[b]))}if(this._selectable){const p=s.id!=null?String(s.id):null,b=p!=null&&this.selectedIds.has(p);i.classList.toggle("ln-row-selected",b);const _=i.querySelector("[data-ln-table-row-select]");_&&(_.checked=b)}},o.prototype._ensureRowPool=function(i,s){for(this._rowPool?this._topTd&&this._topTd.getAttribute("colspan")!==String(s)&&(this._topTd.setAttribute("colspan",s),this._bottomTd.setAttribute("colspan",s)):(this._rowPool=[],this._topSpacer=document.createElement("tr"),this._topSpacer.className="ln-table__spacer",this._topSpacer.setAttribute("aria-hidden","true"),this._topSpacer.style.overflowAnchor="none",this._topTd=document.createElement("td"),this._topTd.setAttribute("colspan",s),this._topTd.style.padding="0",this._topTd.style.border="none",this._topTd.style.overflowAnchor="none",this._topSpacer.appendChild(this._topTd),this._bottomSpacer=document.createElement("tr"),this._bottomSpacer.className="ln-table__spacer",this._bottomSpacer.setAttribute("aria-hidden","true"),this._bottomSpacer.style.overflowAnchor="none",this._bottomTd=document.createElement("td"),this._bottomTd.setAttribute("colspan",s),this._bottomTd.style.padding="0",this._bottomTd.style.border="none",this._bottomTd.style.overflowAnchor="none",this._bottomSpacer.appendChild(this._bottomTd),this.tbody.replaceChildren(this._topSpacer,this._bottomSpacer));this._rowPool.length<i;){const n=this._createTemplateRow();if(!n)break;this._rowPool.push(n),this.tbody.insertBefore(n,this._bottomSpacer)}},o.prototype._renderVirtual=function(){const i=this._filteredData,s=i.length;if(!this._rowHeight||!s)return;const n=this.thead?this.thead.offsetHeight:0,c=this._scrollContainer;let f,w;if(c){const m=this.table.getBoundingClientRect(),y=c.getBoundingClientRect(),A=m.top-y.top+c.scrollTop+n;f=c.scrollTop-A,w=c.clientHeight}else{const A=this.table.getBoundingClientRect().top+window.scrollY+n;f=window.scrollY-A,w=window.innerHeight}let p=f;if(this._vResized){this._vResized=!1;const m=this._vEnd-this._vStart,y=this._rowPool&&this._rowPool[m-1],A=y?(y.getBoundingClientRect().bottom-this._rowPool[0].getBoundingClientRect().top)/m:0;A&&A!==this._rowHeight&&(this._rowHeight=A,this._vStart=-1,this._vTop>0&&(p=this._vTop*A))}const b=this._rowHeight;this._vTop=p/b;const _=Gt(p,w,b,s,15),g=_.start,S=_.end;if(g===this._vStart&&S===this._vEnd)return;this._vStart=g,this._vEnd=S;const E=this.ths.length||1,x=S-g;this._ensureRowPool(x,E),_.topPadding>0?(this._topTd.style.height=_.topPadding+"px",this._topSpacer.style.display=""):(this._topTd.style.height="0px",this._topSpacer.style.display="none"),_.bottomPadding>0?(this._bottomTd.style.height=_.bottomPadding+"px",this._bottomSpacer.style.display=""):(this._bottomTd.style.height="0px",this._bottomSpacer.style.display="none");for(let m=0;m<this._rowPool.length;m++){const y=this._rowPool[m],A=g+m;if(m<x&&A<s){y.style.display="";const v=i[A];if(v&&v.html){const k=document.createElement("tbody");k.innerHTML=v.html;const L=k.firstElementChild;L&&(y.innerHTML=L.innerHTML,y.className=L.className,y._lnRecord=v,v.id!=null&&y.setAttribute("data-ln-table-row-id",v.id))}else this._updateRow(y,v)}else y.style.display="none"}this._selectable&&this._updateSelectAll(),p!==f&&(c?c.scrollTop+=p-f:window.scrollTo(window.scrollX,window.scrollY+p-f))},o.prototype._showLoadingState=function(){this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const i=this.ths.length||1;let s=null,n=T(this.dom,this.name+"-loading","ln-table")||T(this.dom,"table-loading","ln-table");if(!n){const c=this.dom.querySelector("template[data-ln-table-loading]");c&&(n=document.importNode(c.content,!0))}if(n)if(n.tagName==="TR")s=n;else{const c=document.createElement("td");c.setAttribute("colspan",String(i)),c.appendChild(n);const f=document.createElement("tr");f.appendChild(c),s=f}s?(s.setAttribute("data-ln-table-empty",""),this.tbody.replaceChildren(s)):this.tbody.replaceChildren()},o.prototype._showEmptyState=function(){this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const i=this.ths.length||1;let s=null,n=null;if(this.isDataDriven){const c=this._lastTotal!=null?this._lastTotal:this._data.length,w=this.visibleCount===0&&c>0,p=w?this.name+"-empty-filtered":this.name+"-empty";if(n=T(this.dom,p,"ln-table")||T(this.dom,w?"table-empty-filtered":"table-empty","ln-table"),!n){const b=this.dom.querySelector("template[data-ln-table-empty]");if(b){const _=w?"search":"initial",g=b.content.querySelector('[data-ln-table-empty-when="'+_+'"]')||b.content.firstElementChild;g&&(n=document.importNode(g,!0))}}}else if(n=T(this.dom,this.name+"-empty","ln-table")||T(this.dom,"table-empty","ln-table"),!n){const c=this.dom.querySelector("template[data-ln-table-empty]");c&&(n=document.importNode(c.content,!0))}if(n)if(n.tagName==="TR")s=n;else{const c=document.createElement("td");c.setAttribute("colspan",String(i)),c.appendChild(n);const f=document.createElement("tr");f.appendChild(c),s=f}s?(s.setAttribute("data-ln-table-empty",""),this.tbody.replaceChildren(s)):this.tbody.replaceChildren(),C(this.dom,"ln-table:empty",{term:this.isDataDriven?this.currentSearch||"":this._searchTerm,total:this.isDataDriven?this._lastTotal!=null?this._lastTotal:this._data.length:this._data.length})},o.prototype._fillRow=function(i,s){O(i,s);const n=i.querySelectorAll("[data-ln-table-cell-attr]");for(let c=0;c<n.length;c++){const f=n[c],w=f.getAttribute("data-ln-table-cell-attr").split(",");for(let p=0;p<w.length;p++){const b=w[p].trim().split(":");if(b.length!==2)continue;const _=b[0].trim(),g=b[1].trim();s[_]!=null&&f.setAttribute(g,s[_])}}},o.prototype._buildRow=function(i){let s=T(this.dom,this.name+"-row","ln-table");if(!s){const c=this.dom.querySelector("template[data-ln-table-row]");c&&(s=document.importNode(c.content,!0))}let n=s?s.querySelector("[data-ln-table-row]")||s.firstElementChild:null;if(n)this._fillRow(n,i);else if(i&&i.html){const c=document.createElement("tbody");c.innerHTML=i.html,n=c.firstElementChild}else return(window.lnDebug||typeof document<"u"&&document.body&&document.body.hasAttribute("data-ln-debug"))&&console.warn(`[ln-table] Missing row template: <template data-ln-template="${this.name}-row">`),null;if(n._lnRecord=i,i.id!=null&&n.setAttribute("data-ln-table-row-id",i.id),this._selectable&&i.id!=null&&this.selectedIds.has(String(i.id))){n.classList.add("ln-row-selected");const c=n.querySelector("[data-ln-table-row-select]");c&&(c.checked=!0)}return n},o.prototype._requestData=function(){ut(this,"ln-table:request-data","table")},o.prototype._updateSelectAll=function(){if(!this._selectAllCheckbox||!this.tbody)return;const i=this.tbody.querySelectorAll("[data-ln-table-row]"),s=[];for(let c=0;c<i.length;c++){const f=i[c].getAttribute("data-ln-table-row-id");f!=null&&s.push(f)}const n=Yt(s,this.selectedIds);this._selectAllCheckbox.checked=n.isAllSelected,this._selectAllCheckbox.indeterminate=n.isIndeterminate},o.prototype._restoreSelection=function(){if(!this.tbody)return;const i=this.tbody.querySelectorAll("[data-ln-table-row]");for(let s=0;s<i.length;s++){const n=i[s].getAttribute("data-ln-table-row-id"),c=n!=null&&this.selectedIds.has(n);i[s].classList.toggle("ln-row-selected",c);const f=i[s].querySelector("[data-ln-table-row-select]");f&&(f.checked=c)}this._updateSelectAll()},Object.defineProperty(o.prototype,"selectedCount",{get:function(){return this.selectedIds.size},set:function(){}}),o.prototype._enableSelection=function(){if(this._selectableActive)return;this._selectableActive=!0;const i=this;if(this._onSelectionChange=function(s){const n=s.target.closest("[data-ln-table-row-select]");if(!n)return;const c=n.closest("[data-ln-table-row]");if(!c)return;const f=c.getAttribute("data-ln-table-row-id");f!=null&&(i.selectedIds=ct(i.selectedIds,f,n.checked),c.classList.toggle("ln-row-selected",n.checked),i.selectedCount=i.selectedIds.size,i._updateSelectAll(),i._updateFooter(),C(i.dom,"ln-table:select",{table:i.name,selectedIds:i.selectedIds,count:i.selectedCount}))},this.tbody&&this.tbody.addEventListener("change",this._onSelectionChange),this._selectAllCheckbox=this.dom.querySelector('[data-ln-table-col-select] input[type="checkbox"]')||this.dom.querySelector("[data-ln-table-col-select]"),this._selectAllCheckbox&&this._selectAllCheckbox.tagName==="TH"){const s=document.createElement("input");s.type="checkbox";const n=i.dom.querySelector('[data-ln-table-dict="select-all"]'),c=i.dom.getAttribute("data-ln-table-select-all-label")||(n?n.textContent.trim():null)||"Select all";s.setAttribute("aria-label",c),this._selectAllCheckbox.appendChild(s),this._selectAllCheckbox=s}if(this._selectAllCheckbox&&(this._onSelectAll=function(){const s=i._selectAllCheckbox.checked,n=i.tbody?i.tbody.querySelectorAll("[data-ln-table-row]"):[],c=[];for(let f=0;f<n.length;f++){const w=n[f].getAttribute("data-ln-table-row-id"),p=n[f].querySelector("[data-ln-table-row-select]");w!=null&&(c.push(w),n[f].classList.toggle("ln-row-selected",s),p&&(p.checked=s))}i.selectedIds=dt(i.selectedIds,c,s),i.selectedCount=i.selectedIds.size,C(i.dom,"ln-table:select-all",{table:i.name,selected:s}),C(i.dom,"ln-table:select",{table:i.name,selectedIds:i.selectedIds,count:i.selectedCount}),i._updateFooter()},this._selectAllCheckbox.addEventListener("change",this._onSelectAll)),this.tbody){const s=this.tbody.querySelectorAll("[data-ln-table-row]");for(let n=0;n<s.length;n++){const c=s[n].querySelector("[data-ln-table-row-select]"),f=s[n].getAttribute("data-ln-table-row-id");c&&c.checked&&f!=null&&(i.selectedIds=ct(i.selectedIds,f,!0),s[n].classList.add("ln-row-selected"))}this.selectedCount=this.selectedIds.size,this.selectedCount>0&&this._updateSelectAll()}},o.prototype._disableSelection=function(){if(!this._selectableActive)return;this._selectableActive=!1,this.tbody&&this._onSelectionChange&&this.tbody.removeEventListener("change",this._onSelectionChange),this._selectAllCheckbox&&this._onSelectAll&&this._selectAllCheckbox.removeEventListener("change",this._onSelectAll);const i=this.dom.querySelector("[data-ln-table-col-select]");if(i){const s=i.querySelector('input[type="checkbox"]');s&&s.remove()}if(this._selectAllCheckbox=null,this.selectedIds=dt(this.selectedIds,Array.from(this.selectedIds),!1),this.selectedCount=0,this.tbody){const s=this.tbody.querySelectorAll("[data-ln-table-row]");for(let n=0;n<s.length;n++){s[n].classList.remove("ln-row-selected");const c=s[n].querySelector("[data-ln-table-row-select]");c&&(c.checked=!1)}}this._updateFooter()},o.prototype._updateFooter=function(){let i=0,s=0;this.isDataDriven?(i=this._lastTotal!=null?this._lastTotal:this._data.length,s=this.visibleCount):(i=this._data.length,s=this._filteredData.length);const n=s<i;if(this._totalSpan&&d(this._totalSpan,i),this._filteredSpan&&d(this._filteredSpan,n?s:null),this._filteredWrap&&this._filteredWrap.classList.toggle("hidden",!n),this._selectedSpan){const c=this.selectedIds?this.selectedIds.size:0;d(this._selectedSpan,c>0?c:null),this._selectedWrap&&this._selectedWrap.classList.toggle("hidden",c===0)}},o.prototype.destroy=function(){this.dom[e]&&(this._disableVirtualScroll(),this.dom.removeEventListener("ln-table:set-search",this._onSetSearch),this.dom.removeEventListener("ln-table:request-clear-filters",this._onRequestClearFilters),this.isDataDriven?(this.dom.removeEventListener("ln-table:set-data",this._onSetData),this.dom.removeEventListener("ln-table:set-loading",this._onSetLoading),this.dom.removeEventListener("ln-sort:change",this._onSort),this.tbody&&(this.tbody.removeEventListener("click",this._onRowClick),this.tbody.removeEventListener("click",this._onRowAction))):(this._emptyTbodyObserver&&(this._emptyTbodyObserver.disconnect(),this._emptyTbodyObserver=null),this.dom.removeEventListener("ln-sort:change",this._onSort),this.dom.removeEventListener("ln-search:change",this._onSearchChange),this.dom.removeEventListener("ln-filter:change",this._onFilterChange)),this._onSelectionChange&&this.tbody&&this.tbody.removeEventListener("change",this._onSelectionChange),this._selectAllCheckbox&&this._onSelectAll&&this._selectAllCheckbox.removeEventListener("change",this._onSelectAll),this._colgroup&&(this._colgroup.remove(),this._colgroup=null),this.table&&(this.table.style.tableLayout=""),this._loadingIndicator=null,this._data=[],this._filteredData=[],delete this.dom[e])},st(t,e,o,"ln-table",{attributes:a})})()})();
|
|
1
|
+
(function(){"use strict";function V(){if(typeof window>"u")return!1;if(window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink)return!0;if(typeof document<"u"){if(document.documentElement&&document.documentElement.hasAttribute("data-ln-debug"))return!0;if(document.body)return document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null}return!1}function F(t){if(typeof window>"u")return!1;if(window.lnDebug===!0)return!0;if(window.lnCore&&window.lnCore._debugIsContained)return t?window.lnCore._debugIsContained(t):window.lnCore._debugSink!==null;if(t&&t.closest){const e=t.closest("[data-ln-debug]");return!(!e||typeof document<"u"&&e===document.documentElement)}return typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug"):!1}if(typeof window<"u"&&(window.lnCore=window.lnCore||{},!window.lnCore._warnBound)){window.lnCore._warnBound=!0;const t=console.warn;console.warn=function(...e){if(typeof e[0]=="string"&&(e[0].startsWith("[ln-")||e[0].startsWith("[lnCore"))){let r=null;for(let a=1;a<e.length;a++)if(e[a]&&e[a].nodeType===1){r=e[a];break}if(!F(r))return}t.apply(console,e)}}function C(t,e,l){const r=l||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",e,t,r),t.dispatchEvent(new CustomEvent(e,{bubbles:!0,detail:r}))}function ut(t,e,l){t._applyFilterAndSort(),t._vStart=-1,t._vEnd=-1,t._render(),t._updateFooter();const r={sort:t.currentSort,filters:t.currentFilters,search:t.currentSearch};r[l]=t.name,C(t.dom,e,r)}function R(t,e){if(!document.body){document.addEventListener("DOMContentLoaded",function(){R(t,e)}),console.warn("["+e+'] Script loaded before <body> — add "defer" to your <script> tag');return}t()}function W(t){return t.hasAttribute("value")?t.getAttribute("value"):t.hasAttribute("data-ln-value")?t.getAttribute("data-ln-value"):t.tagName==="TIME"&&t.hasAttribute("datetime")?t.getAttribute("datetime"):t.textContent.trim()}function ht(t){const e=t.querySelector('input[name="_method"]');return((e&&e.value!==""?e.value:t.method)||"").toUpperCase()}function ft(t,e){const l=!!(e&&e.typed),r=e&&e.exclude,a={},u=t.elements,d={};if(l)for(let h=0;h<u.length;h++){const o=u[h];o.name&&o.type==="checkbox"&&!o.disabled&&(d[o.name]=(d[o.name]||0)+1)}for(let h=0;h<u.length;h++){const o=u[h];if(!(!o.name||o.disabled||o.type==="file"||o.type==="submit"||o.type==="button")&&!(r&&o.matches&&o.matches(r)))if(o.type==="checkbox")l&&d[o.name]===1?a[o.name]=o.checked:(a[o.name]||(a[o.name]=[]),o.checked&&a[o.name].push(o.value));else if(o.type==="radio")o.checked&&(a[o.name]=o.value);else if(o.type==="select-multiple"){a[o.name]=[];for(let i=0;i<o.options.length;i++)o.options[i].selected&&a[o.name].push(o.options[i].value)}else if(l&&o.type==="hidden")a[o.name]=o.value;else if(l&&(o.type==="number"||o.type==="range")){const i=Number(o.value);a[o.name]=o.value===""||isNaN(i)?null:i}else a[o.name]=o.value}return a}function bt(t){if(typeof t!="string")return!!t;const e=t.trim().toLowerCase();return e!=="false"&&e!=="0"&&e!==""&&e!=="off"&&e!=="no"}function pt(t,e){const l=t.elements,r=[],a={};for(let u=0;u<l.length;u++){const d=l[u];d.name&&d.type==="checkbox"&&(a[d.name]=(a[d.name]||0)+1)}for(let u=0;u<l.length;u++){const d=l[u];if(d.type==="file"||d.type==="submit"||d.type==="button")continue;const h=d.getAttribute("data-ln-fill-as")||d.name;if(!h||!(h in e))continue;const o=e[h];if(d.type==="checkbox"){if(Array.isArray(o))d.checked=o.indexOf(d.value)!==-1;else if(a[d.name]>1){const i=String(o).split(",").map(function(s){return s.trim()});d.checked=i.indexOf(d.value)!==-1}else d.checked=bt(o);r.push(d)}else if(d.type==="radio")d.checked=d.value===String(o),r.push(d);else if(d.type==="select-multiple"){if(Array.isArray(o))for(let i=0;i<d.options.length;i++)d.options[i].selected=o.indexOf(d.options[i].value)!==-1;r.push(d)}else d.value=o,d.tagName==="SELECT"&&o!=null&&d.setAttribute("data-ln-value",o),r.push(d)}return r}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.populateForm=pt,window.lnCore.serializeForm=ft,window.lnCore.resolveFormMethod=ht);const $={};function wt(t,e){$[t]=e}function _t(t){return $[t]||{ingress:e=>e,egress:e=>e}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=wt,window.lnCore.getDataMapper=_t);function gt(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,R(function(){new MutationObserver(function(){C(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const j={};function mt(t,e){if(!t||typeof e!="object")return;const l=t.toLowerCase().split("-")[0];j[l]=e}function yt(t){if(!t)return null;const e=t.toLowerCase().split("-")[0];return j[e]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=mt,window.lnCore.getLocaleFallback=yt,window.lnCore.ensureLocaleObserver=gt);const I={};function U(t,e){I[t]||(I[t]=document.querySelector('[data-ln-template="'+t+'"]'));const l=I[t];return l?l.content.cloneNode(!0):(console.warn("["+(e||"ln-core")+'] Template "'+t+'" not found'),null)}function T(t,e,l){if(t){const r=t.querySelector('[data-ln-template="'+e+'"]');if(r)return r.content.cloneNode(!0)}return U(e,l)}function z(t,e){if(!t||!e)return t;const l=t.querySelectorAll("[data-ln-field]");for(let d=0;d<l.length;d++){const h=l[d],o=h.getAttribute("data-ln-field");e[o]!=null&&(h.textContent=e[o])}const r=t.querySelectorAll("[data-ln-attr]");for(let d=0;d<r.length;d++){const h=r[d],o=h.getAttribute("data-ln-attr").split(",");for(let i=0;i<o.length;i++){const s=o[i].trim().split(":");if(s.length!==2)continue;const n=s[0].trim(),c=s[1].trim();e[c]!=null&&h.setAttribute(n,e[c])}}const a=t.querySelectorAll("[data-ln-show]");for(let d=0;d<a.length;d++){const h=a[d],o=h.getAttribute("data-ln-show");o in e&&h.classList.toggle("hidden",!e[o])}const u=t.querySelectorAll("[data-ln-class]");for(let d=0;d<u.length;d++){const h=u[d],o=h.getAttribute("data-ln-class").split(",");for(let i=0;i<o.length;i++){const s=o[i].trim().split(":");if(s.length!==2)continue;const n=s[0].trim(),c=s[1].trim();c in e&&h.classList.toggle(n,!!e[c])}}return t}function Ct(t,e){t.matches&&t.matches("[data-ln-form], [data-ln-fillable]")&&(window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",t,e??null),t.dispatchEvent(new CustomEvent("ln-fill",{detail:e??null,bubbles:!0})));const l=t.querySelectorAll("[data-ln-form], [data-ln-fillable]");for(let r=0;r<l.length;r++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",l[r],e??null),l[r].dispatchEvent(new CustomEvent("ln-fill",{detail:e??null,bubbles:!0}));return t}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._fillBound||(window.lnCore._fillBound=!0,document.addEventListener("ln-fill",function(t){if(!(!t.target.matches||!t.target.matches("[data-ln-fillable]")))if(t.detail)z(t.target,t.detail);else{const e=t.target.querySelectorAll("[data-ln-field]");for(let l=0;l<e.length;l++)e[l].textContent=""}})));function O(t,e){if(!t||!e)return t;const l=document.createTreeWalker(t,NodeFilter.SHOW_TEXT);for(;l.nextNode();){const u=l.currentNode;u.textContent.indexOf("{{")!==-1&&(u.textContent=u.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(d,h){return e[h]!==void 0?e[h]:""}))}const r=function(u,d){return e[d]!==void 0?e[d]:""},a=Array.from(t.querySelectorAll("*"));t.nodeType===1&&a.push(t);for(let u=0;u<a.length;u++){const d=a[u],h=d.attributes;for(let o=0;o<h.length;o++){const i=h[o];i.value.indexOf("{{")!==-1&&d.setAttribute(i.name,i.value.replace(/\{\{\s*(\w+)\s*\}\}/g,r))}}return t}function St(t,e,l,r,a,u){const d={};for(let o=0;o<t.children.length;o++){const i=t.children[o],s=i.getAttribute("data-ln-render-key");s&&(d[s]=i)}const h=document.createDocumentFragment();for(let o=0;o<e.length;o++){const i=e[o],s=String(r(i));let n=d[s];if(n)a(n,i,o);else{const c=U(l,u);if(!c||(O(c,i),n=c.firstElementChild,!n))continue;n.setAttribute("data-ln-render-key",s),a(n,i,o)}h.appendChild(n)}t.textContent="",t.appendChild(h)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=O,window.lnCore.fill=z,window.lnCore.lnFill=Ct,window.lnCore.renderList=St);function D(t,e,l){const r=t.getAttribute(e);return r===null?l:r}function Q(t,e,l){const r=parseInt(t.getAttribute(e),10);return isNaN(r)?l:r}function N(t,e,l=!1){const r=t.getAttribute(e);if(r===null)return!!l;const a=r.trim().toLowerCase();return!(a==="false"||a==="0")}function K(t,e){return(t.getAttribute(e)||"").split(",").map(l=>l.trim()).filter(Boolean)}const H=new Map;function J(t,e){const l=(t?t.join("|"):"")+"::"+e;if(H.has(l))return H.get(l);const r=new Set(t||[]),a=function(u,d){const h=u.getAttribute(d);return h!==null&&r.has(h)?h:e};return H.set(l,a),a}function G(t,e,l){const r=parseFloat(t.getAttribute(e));return isNaN(r)?l:r}function Y(t,e,l){const r=t.getAttribute(e);if(!r)return l;try{return JSON.parse(r)}catch{return l}}function X(t,e,l,r,a){if(!t||e===null)return!0;const u=r||"ln-component",d=t.type;if(d==="trigger"||d==="marker"||d==="string"||d==="list"||!d||e===""&&t.fallback!==void 0)return!0;const h=o=>{a?console.warn(o,a):console.warn(o)};if(d==="boolean"){const o=e.trim().toLowerCase();return o!==""&&o!=="true"&&o!=="false"&&o!=="1"&&o!=="0"?(h(`[${u}] Invalid value "${e}" for boolean attribute "${l}". Allowed: "true", "false", or presence-only.`),!1):!0}if(d==="enum"){const o=t.values||[];return o.includes(e)?!0:(h(`[${u}] Invalid value "${e}" for attribute "${l}". Allowed: ${o.join(", ")}. Fallback: "${t.fallback}".`),!1)}if(d==="integer"){if(!/^-?\d+$/.test(e))return h(`[${u}] Invalid integer "${e}" for attribute "${l}". Fallback: ${t.fallback}.`),!1;const o=parseInt(e,10);return t.min!==void 0&&o<t.min?(h(`[${u}] Value ${o} for attribute "${l}" is less than min (${t.min}).`),!1):t.max!==void 0&&o>t.max?(h(`[${u}] Value ${o} for attribute "${l}" is greater than max (${t.max}).`),!1):!0}if(d==="float")return isNaN(Number(e))?(h(`[${u}] Invalid float "${e}" for attribute "${l}". Fallback: ${t.fallback}.`),!1):!0;if(d==="json")try{return JSON.parse(e),!0}catch(o){return h(`[${u}] Invalid JSON for attribute "${l}": ${o.message}. Fallback: ${t.fallback}.`),!1}return!0}function Z(t,e,l){for(const r in l){const[a,u,d]=l[r];Object.defineProperty(t,r,{get:function(){return a(e,u,d)},enumerable:!0,configurable:!0})}return t}function tt(t){const e={};for(const l in t){const r=t[l];if(!r||!r.prop)continue;let a=r.read;if(!a&&r.type)switch(r.type){case"enum":a=J(r.values,r.fallback);break;case"integer":a=Q;break;case"float":a=G;break;case"boolean":a=N;break;case"list":a=K;break;case"json":a=Y;break;case"string":default:a=D;break}a||(a=D),e[r.prop]=[a,l,r.fallback]}return e}function At(t){const e={};for(const l in t){const r=t[l];r&&r.effect&&(e[l]=r.effect)}return Object.keys(e).length?e:null}function vt(t){if(t.onAttrChange&&!t.declared)return null;const e=new Set;if(t.effects)for(const l in t.effects)e.add(l);if(t.onAttrChange&&t.declared)for(const l of t.declared)e.add(l);return e}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.defineAttrs=Z,window.lnCore.attrSpec=tt,window.lnCore.attrStr=D,window.lnCore.attrInt=Q,window.lnCore.attrBool=N,window.lnCore.attrList=K,window.lnCore.attrEnum=J,window.lnCore.attrFloat=G,window.lnCore.attrJson=Y);function q(t,e){if(!t[e.attribute]){window.lnCore._persistSink&&t.hasAttribute&&t.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(t,e.selector);try{t[e.attribute]=new e.ComponentFn(t)}catch(l){console.error("["+e.attribute+"] init failed",t,l)}}}function et(t,e,l,r){if(t.nodeType!==1)return;const u=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]",d={selector:e,attribute:l,ComponentFn:r};if(t.matches&&t.matches(u)&&q(t,d),t.querySelectorAll){const h=t.querySelectorAll(u);for(let o=0;o<h.length;o++)q(h[o],d)}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function Tt(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function xt(t){typeof window<"u"?(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[],window.lnCore._bootHolds>0?window.lnCore._bootQueue.push(t):setTimeout(t,0)):t()}function nt(){window.lnCore=window.lnCore||{};const t=window.lnCore._attrRegistry=window.lnCore._attrRegistry||{byAttr:new Map,reactive:[],persist:[]};return t.byReactive=t.byReactive||new Map,t.reactiveWildcard=t.reactiveWildcard||[],t}function Et(t){const e=nt(),l=t.observed||[];for(let r=0;r<l.length;r++){const a=l[r];e.byAttr.has(a)||e.byAttr.set(a,[]),e.byAttr.get(a).push(t)}if(e.byDeclaredAttr=e.byDeclaredAttr||new Map,t.attributes)for(const r in t.attributes){e.byDeclaredAttr.has(r)||e.byDeclaredAttr.set(r,[]);const a=e.byDeclaredAttr.get(r);a.some(u=>u.componentTag===t.componentTag)||a.push({spec:t.attributes[r],componentTag:t.componentTag})}if(t.onAttrChange||t.effects){e.reactive.push(t);const r=vt(t);if(r===null)e.reactiveWildcard.push(t);else for(const a of r)e.byReactive.has(a)||e.byReactive.set(a,[]),e.byReactive.get(a).push(t)}t.persist&&e.persist.push(t)}function it(t,e,l,r){for(let a=0;a<t.length;a++){const u=t[a];if(!e[u.attribute])continue;const d=u.effects&&u.effects[l];d?d(e,l,r):u.onAttrChange&&(!u.declared||u.declared.has(l))&&u.onAttrChange(e,l,r)}}function Lt(t){const e=t.attributeName,l=e.indexOf("data-ln-")===0,r=nt(),a=r.byAttr.get(e),u=V()&&r.byDeclaredAttr&&r.byDeclaredAttr.has(e);if(!l&&!a&&!u)return;const d=t.target;if(t.oldValue!==d.getAttribute(e)){if(u&&F(d)){const h=r.byDeclaredAttr.get(e),o=d.getAttribute(e);for(let i=0;i<h.length;i++)X(h[i].spec,o,e,h[i].componentTag,d)}if(window.lnCore._debugSink&&(l||a)&&window.lnCore._debugSink("attr",e,d,{oldValue:t.oldValue,newValue:d.getAttribute(e)}),l){const h=r.byReactive.get(e);h&&it(h,d,e,t.oldValue),r.reactiveWildcard.length&&it(r.reactiveWildcard,d,e,t.oldValue)}if(a)for(let h=0;h<a.length;h++){const o=a[h];if(o.handler){o.handler(d,e,t.oldValue);continue}o.onAttributeChange&&d[o.attribute]?o.onAttributeChange(d,e):(et(d,o.selector,o.attribute,o.ComponentFn),o.onInit&&o.onInit(d))}}}function kt(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,R(function(){new MutationObserver(function(e){for(let l=0;l<e.length;l++)try{Lt(e[l])}catch(r){console.error("[ln-core] mutation handler failed",e[l].target,r)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function M(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function B(){return window.lnCore=window.lnCore||{},window.lnCore._subtreeRegistry=window.lnCore._subtreeRegistry||[]}function lt(t,e){if(!document.contains(t))if(e.attribute){const l=t[e.attribute];if(l&&typeof l.destroy=="function")try{l.destroy()}catch(r){console.error("["+e.attribute+"] destroy failed",t,r)}delete t[e.attribute]}else e.onDestroy&&e.onDestroy(t)}function ot(t){const e=M();if(!e.length)return;const l=t.target;if(l){const a=l.nodeType===1?l:l.parentElement;if(a&&(a.isContentEditable||a.closest&&a.closest('[contenteditable]:not([contenteditable="false"])')))return}const r=B();if(t.target&&r.length)for(let a=0;a<r.length;a++){const u=r[a],d=u.query,h=t.target.nodeType===1?t.target.matches&&t.target.matches(d)?t.target:t.target.closest?t.target.closest(d):null:t.target.parentElement&&t.target.parentElement.closest?t.target.parentElement.closest(d):null;h&&u.onSubtreeChange(h,t)}for(let a=0;a<t.addedNodes.length;a++){const u=t.addedNodes[a];if(u.nodeType!==1)continue;const d=!!(u.firstElementChild||u.children&&u.children.length);for(let h=0;h<e.length;h++){const o=e[h],i=o.query;if(i&&(u.matches&&u.matches(i)&&(o.ComponentFn&&q(u,o),o.onInit&&o.onInit(u)),d&&u.querySelectorAll)){const s=u.querySelectorAll(i);for(let n=0;n<s.length;n++)o.ComponentFn&&q(s[n],o),o.onInit&&o.onInit(s[n])}}}for(let a=0;a<t.removedNodes.length;a++){const u=t.removedNodes[a];if(u.nodeType!==1||document.contains(u))continue;const d=!!(u.firstElementChild||u.children&&u.children.length);for(let h=0;h<e.length;h++){const o=e[h],i=o.query;if(i&&(u.matches&&u.matches(i)&<(u,o),d&&u.querySelectorAll)){const s=u.querySelectorAll(i);for(let n=0;n<s.length;n++)lt(s[n],o)}}}}function rt(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,R(function(){const t=new MutationObserver(function(e){for(let l=0;l<e.length;l++){const r=e[l];if(r.type==="childList")try{ot(r)}catch(a){console.error("[ln-core] lifecycle handler failed",r.target,a)}}});window.lnCore._lifecycleObserver=t,t.observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function Dt(t){if(typeof window>"u")return t();window.lnCore=window.lnCore||{};const e=window.lnCore._lifecycleObserver;if(!e)return t();const l=e.takeRecords();for(let r=0;r<l.length;r++){const a=l[r];if(a.type==="childList")try{ot(a)}catch(u){console.error("[ln-core] lifecycle handler failed",a.target,u)}}e.disconnect();try{return t()}finally{e.observe(document.body,{childList:!0,subtree:!0})}}function Rt(t){M().push(t),t.onSubtreeChange&&t.query&&B().push(t),rt()}function st(t,e,l,r,a={}){const u=a.extraAttributes||[],d=a.onAttributeChange||null,h=a.onSubtreeChange||null,o=a.onInit||null,i=a.onAttrChange||null,s=a.effects||null,n=a.attributes||null,c=n?At(n):s,f=n?new Set(Object.keys(n)):null,w=a.persist||null;function p(x){const m=x||document.body;if(et(m,t,e,l),n&&V())for(const y in n){const A=n[y],v=Array.from(m.querySelectorAll("["+y+"]"));m.matches&&m.matches("["+y+"]")&&v.push(m);for(let k=0;k<v.length;k++){const L=v[k];F(L)&&X(A,L.getAttribute(y),y,r,L)}}o&&o(m)}const b=[];if(t.indexOf("[")!==-1){const x=/\[([\w-]+)/g;let m;for(;(m=x.exec(t))!==null;)b.push(m[1])}else b.push(t);Et({selector:t,attribute:e,componentTag:r,attributes:n,ComponentFn:l,onInit:o,observed:b.concat(u),onAttributeChange:d,onAttrChange:i,effects:c,declared:f,persist:w}),kt();const _=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1,g=a.subtreeQuery||(_?t:"["+t+"]"),S={selector:t,attribute:e,ComponentFn:l,onInit:o,onSubtreeChange:h,query:g};M().push(S),h&&g&&B().push(S),rt(),window[e]=p,typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerComponent=st,window.lnCore.observeLifecycle=Rt,window.lnCore.withoutLifecycle=Dt);function E(){Tt()>0?xt(function(){p(document.body)}):p(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",E):E(),p}function at(t){return(t||"").replace(/^#/,"")}function P(t){const e=t===void 0?location.hash:t,l={},r=at(e);if(!r)return l;const a=r.split("&");for(let u=0;u<a.length;u++){const d=a[u];if(!d)continue;const h=d.indexOf(":"),o=h>-1?d.slice(0,h):d,i=h>-1?d.slice(h+1):"";if(o)try{l[o]=decodeURIComponent(i)}catch{l[o]=i}}return l}function qt(t){if(!t)return null;const e=P();return t in e?e[t]:null}function Ft(t,e){if(!t)return;const l=P();e==null?delete l[t]:l[t]=String(e);const a=Object.keys(l).map(function(u){const d=l[u];return d===""?u:u+":"+encodeURIComponent(d)}).join("&");at(location.hash)!==a&&(location.hash=a)}function It(t){return t.button===1||t.ctrlKey||t.metaKey||t.shiftKey?!1:(t.preventDefault(),!0)}function Ot(t,e){if(!t||!t.hasAttribute("data-ln-hash"))return null;const l=t.getAttribute("data-ln-hash");if(l&&l.trim()!=="")return l.trim();const r=t.getAttribute("data-ln-sort")||t.getAttribute("data-ln-search-for")||t.getAttribute("data-ln-search")||t.getAttribute("data-ln-filter")||t.id;return r?e?r+"-"+e:r:e||null}function Nt(t,e){return!e||e==="none"||t===null||t===void 0?null:String(t)+"."+e}function Ht(t){return!t||typeof t!="string"?null:t.endsWith(".asc")?{fieldOrColumn:t.slice(0,-4),direction:"asc"}:t.endsWith(".desc")?{fieldOrColumn:t.slice(0,-5),direction:"desc"}:null}function Mt(t,e){return!t||!Array.isArray(e)||e.length===0?null:t+":"+e.map(encodeURIComponent).join(",")}function Bt(t){if(!t||typeof t!="string")return null;const e=t.indexOf(":");if(e===-1)return null;const l=t.slice(0,e),r=t.slice(e+1),a=r?r.split(",").map(function(u){try{return decodeURIComponent(u)}catch{return u}}).filter(Boolean):[];return{key:l,values:a}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=P,window.lnCore.hashGet=qt,window.lnCore.hashSet=Ft,window.lnCore.hashLinkClick=It,window.lnCore.resolveHashNamespace=Ot,window.lnCore.hashSortEncode=Nt,window.lnCore.hashSortDecode=Ht,window.lnCore.hashFilterEncode=Mt,window.lnCore.hashFilterDecode=Bt);function Pt(t){return(t||"").replace(/^\?/,"")}function Vt(t){const e=t===void 0?typeof window<"u"?window.location.search:"":t,l={},r=Pt(e);if(!r)return l;const a=new URLSearchParams(r);for(const[u,d]of a.entries())l[u]=d;return l}function Wt(t){if(!t||typeof window>"u")return null;const e=new URLSearchParams(window.location.search);return e.has(t)?e.get(t):null}function $t(t,e){if(!t||typeof window>"u")return;const l=new URL(window.location.href);if(e==null||e===""?l.searchParams.delete(t):l.searchParams.set(t,String(e)),l.search===window.location.search)return;const r=l.pathname+l.search+l.hash;window.history.replaceState(window.history.state,"",r)}function jt(t,e){if(!t||!t.hasAttribute("data-ln-query"))return null;const l=t.getAttribute("data-ln-query");if(l&&l.trim()!=="")return l.trim();const r=t.getAttribute("data-ln-sort")||t.getAttribute("data-ln-search-for")||t.getAttribute("data-ln-search")||t.getAttribute("data-ln-filter")||t.id;return r?e?r+"_"+e:r:e||null}function Ut(t,e){return!e||e==="none"||t===null||t===void 0?null:String(t)+"."+e}function zt(t,e){if(t&&typeof t=="string"){if(t.endsWith(".asc"))return{fieldOrColumn:t.slice(0,-4),direction:"asc"};if(t.endsWith(".desc"))return{fieldOrColumn:t.slice(0,-5),direction:"desc"}}if(e&&typeof e=="object"){const l=e.sort_field||e.sort_by;if(l){const r=e.sort_dir&&String(e.sort_dir).toLowerCase()==="desc"?"desc":"asc";return{fieldOrColumn:l,direction:r}}}return null}function Qt(t){return!Array.isArray(t)||t.length===0?null:t.map(encodeURIComponent).join(",")}function Kt(t){return!t||typeof t!="string"?[]:t.split(",").map(function(e){try{return decodeURIComponent(e.trim())}catch{return e.trim()}}).filter(Boolean)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.queryParse=Vt,window.lnCore.queryGet=Wt,window.lnCore.querySet=$t,window.lnCore.resolveQueryParam=jt,window.lnCore.querySortEncode=Ut,window.lnCore.querySortDecode=zt,window.lnCore.queryFilterEncode=Qt,window.lnCore.queryFilterDecode=Kt);function Jt(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{const e=Math.random()*16|0;return(t==="x"?e:e&3|8).toString(16)})}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.uuid=Jt);function Gt(t,e,l,r,a=15){if(r<=0||l<=0)return{start:0,end:0,topPadding:0,bottomPadding:0};const u=Math.max(0,t||0),d=Math.max(0,e||0),h=Math.floor(u/l),o=Math.ceil(d/l),i=Math.max(0,h-a),s=Math.min(r,h+o+a),n=i*l,c=Math.max(0,(r-s)*l);return{start:i,end:s,topPadding:n,bottomPadding:c}}function Yt(t,e){const l=Array.isArray(t)?t.length:0,r=e instanceof Set?e:new Set(e||[]);let a=0;if(Array.isArray(t))for(let h=0;h<t.length;h++)r.has(t[h])&&a++;else a=r.size;const u=l>0&&a===l,d=a>0&&a<l;return{totalCount:l,selectedCount:a,isAllSelected:u,isIndeterminate:d}}function ct(t,e,l){const r=new Set(t);return e==null||((l!==void 0?l:!r.has(e))?r.add(e):r.delete(e)),r}function dt(t,e,l){const r=new Set(t);if(!Array.isArray(e))return r;if(l)for(let a=0;a<e.length;a++)e[a]!=null&&r.add(e[a]);else for(let a=0;a<e.length;a++)r.delete(e[a]);return r}(function(){const t="data-ln-table",e="lnTable";if(window[e]!==void 0)return;const a={"data-ln-table":{prop:"name",type:"string",read:D,fallback:"",description:"Table instance name or identifier"},"data-ln-table-source":{prop:"source",type:"string",read:D,fallback:"",description:"Source store or coordinator addressing"},"data-ln-table-selectable":{prop:"_selectable",type:"boolean",read:N,description:"Enables row selection check controls"},"data-ln-table-row":{type:"marker",description:"Table row template element"},"data-ln-table-row-id":{type:"string",description:"Record identifier on row element"},"data-ln-table-row-action":{type:"trigger",description:"Action trigger inside a table row"},"data-ln-table-row-select":{type:"trigger",description:"Row selection checkbox trigger"},"data-ln-table-col":{type:"string",description:"Column header identifier or field mapping"},"data-ln-table-col-select":{type:"trigger",description:"Header select-all checkbox trigger"},"data-ln-table-cell-attr":{type:"string",description:"Cell attribute template mapping"},"data-ln-table-select-all-label":{type:"string",description:"Accessibility label for select-all header trigger"}},u=tt(a);typeof Intl<"u"&&new Intl.Collator(document.documentElement.lang||void 0,{sensitivity:"base"});function d(i,s){if(!i)return;if(s==null||isNaN(s)){i.removeAttribute("data-ln-value"),"value"in i&&i.tagName==="DATA"&&(i.value=""),i.lnNumber?i.lnNumber.value=NaN:i.textContent="";return}const n=String(s);i.setAttribute("data-ln-value",n),"value"in i&&i.tagName==="DATA"&&(i.value=n),i.lnNumber?i.lnNumber.value=s:i.textContent=n}function h(i,s){let n=s?s.parentElement:i;for(;n&&n!==document.body&&n!==document.documentElement;){const f=getComputedStyle(n).overflowY;if(f==="auto"||f==="scroll")return n;n=n.parentElement}return null}function o(i){this.dom=i,Z(this,i,u),this.table=i.querySelector("table"),this.tbody=i.querySelector("[data-ln-table-body]")||i.querySelector("tbody"),this.thead=i.querySelector("thead");const s=this.thead?this.thead.querySelector("tr:last-child"):null;this.ths=s?Array.from(s.querySelectorAll("th")):[],this._totalSpan=i.querySelector("[data-ln-table-total]"),this._filteredSpan=i.querySelector("[data-ln-table-filtered]"),this._filteredSpan&&(this._filteredWrap=this._filteredSpan.parentElement!==i?this._filteredSpan.parentElement:null),this._selectedSpan=i.querySelector("[data-ln-table-selected]"),this._selectedSpan&&(this._selectedWrap=this._selectedSpan.parentElement!==i?this._selectedSpan.parentElement:null),this._loadingIndicator=i.querySelector("[data-ln-table-loading]"),this._loadingIndicator&&this._loadingIndicator.classList.add("hidden"),this.isDataDriven=i.hasAttribute("data-ln-table-source"),this._data=[],this._filteredData=[],this._searchTerm="",this._sortCol=-1,this._sortDir=null,this._columnFilters={},this.selectedIds=new Set,this._virtual=!1,this._rowHeight=0,this._vStart=-1,this._vEnd=-1,this._rafId=null,this._scrollHandler=null,this._resizeHandler=null,this._vResized=!1,this._vTop=0,this._scrollContainer=null,this._colgroup=null,this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const n=this;return this._onSetSearch=function(c){const f=(c.detail&&c.detail.query!=null?c.detail.query:c.detail&&c.detail.term!=null?c.detail.term:"").trim();n.isDataDriven?(n.currentSearch=f,C(i,"ln-table:search",{table:n.name,query:n.currentSearch}),n._requestData()):(n._searchTerm=f.toLowerCase(),n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),n._updateFooter(),C(i,"ln-table:filter",{term:n._searchTerm,matched:n._filteredData.length,total:n._data.length}))},i.addEventListener("ln-table:set-search",this._onSetSearch),this._onSearchChange=function(c){c.preventDefault(),n._onSetSearch(c)},i.addEventListener("ln-search:change",this._onSearchChange),this._onRequestClearFilters=function(){n.isDataDriven?(n.currentFilters={},n.currentSearch="",C(i,"ln-table:clear-filters",{table:n.name}),n._requestData()):(n._searchTerm="",n._columnFilters={},n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),n._updateFooter(),C(i,"ln-table:filter",{term:"",matched:n._filteredData.length,total:n._data.length}))},i.addEventListener("ln-table:request-clear-filters",this._onRequestClearFilters),this._selectableActive=!1,this._selectable&&this._enableSelection(),this.isDataDriven?(this.isLoaded=!1,this._initialLoaded=!1,this.totalCount=0,this.visibleCount=0,this.currentSort=null,this.currentFilters={},this.currentSearch="",this._lastTotal=0,this._lastFiltered=0,this._hasInitialSeed=!1,this._onSetData=function(c){const f=c.detail||{},w=f.data||[],p=f.total!=null?f.total:w.length;n._hasInitialSeed&&!n.isLoaded&&w.length===0&&p===0||(n._data=w,n._lastTotal=p,n._lastFiltered=f.filtered!=null?f.filtered:n._data.length,n.totalCount=n._lastTotal,n.visibleCount=n._lastFiltered,n.isLoaded=!0,n._initialLoaded=!0,n._hasInitialSeed=!1,i.classList.remove("ln-table--loading"),i.setAttribute("aria-busy","false"),n._loadingIndicator&&n._loadingIndicator.classList.add("hidden"),n._vStart=-1,n._vEnd=-1,n._applyFilterAndSort(),n._render(),n._updateFooter(),C(i,"ln-table:rendered",{table:n.name,total:n.totalCount,visible:n.visibleCount}))},i.addEventListener("ln-table:set-data",this._onSetData),this._onSetLoading=function(c){const f=!!(c.detail&&c.detail.loading);i.classList.toggle("ln-table--loading",f),i.setAttribute("aria-busy",f?"true":"false"),f&&!n._initialLoaded&&(n.isLoaded=!1,n._showLoadingState()),n._loadingIndicator&&n._loadingIndicator.classList.toggle("hidden",!(f&&n._initialLoaded))},i.addEventListener("ln-table:set-loading",this._onSetLoading),this._onSort=function(c){!c.detail||c.detail.field==null||(c.preventDefault(),n.currentSort=c.detail.direction==="none"?null:{field:c.detail.field,direction:c.detail.direction},n._requestData())},i.addEventListener("ln-sort:change",this._onSort),this._onRowClick=function(c){if(c.target.closest("[data-ln-table-row-select]")||c.target.closest("[data-ln-table-row-action]")||c.target.closest("a")||c.target.closest("button")||c.ctrlKey||c.metaKey||c.button===1)return;const f=c.target.closest("[data-ln-table-row]");if(!f)return;const w=f.getAttribute("data-ln-table-row-id"),p=f._lnRecord||{};C(i,"ln-table:row-click",{table:n.name,id:w,record:p})},this.tbody&&this.tbody.addEventListener("click",this._onRowClick),this._onRowAction=function(c){const f=c.target.closest("[data-ln-table-row-action]");if(!f)return;const w=f.closest("[data-ln-table-row]");if(!w)return;const p=f.getAttribute("data-ln-table-row-action"),b=w.getAttribute("data-ln-table-row-id"),_=w._lnRecord||{};C(i,"ln-table:row-action",{table:n.name,id:b,action:p,record:_})},this.tbody&&this.tbody.addEventListener("click",this._onRowAction),this.tbody&&this.tbody.rows.length>0?this._parseRows():(this._showLoadingState(),i.setAttribute("aria-busy","true")),setTimeout(function(){!n.dom||!document.contains(n.dom)||C(i,"ln-table:request-data",{table:n.name,sort:n.currentSort,filters:n.currentFilters,search:n.currentSearch})},0)):(this._emptyTbodyObserver=null,this.tbody&&this.tbody.rows.length>0?this._parseRows():this.tbody&&(this._emptyTbodyObserver=new MutationObserver(function(){n.tbody.rows.length>0&&(n._emptyTbodyObserver.disconnect(),n._emptyTbodyObserver=null,n._parseRows())}),this._emptyTbodyObserver.observe(this.tbody,{childList:!0})),this._onSort=function(c){if(!c.detail||c.detail.column==null)return;c.preventDefault();const f=c.detail.direction==="none"?null:c.detail.direction;n._sortCol=f===null?-1:c.detail.column,n._sortDir=f,n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),C(i,"ln-table:sorted",{column:c.detail.column,direction:c.detail.direction,matched:n._filteredData.length,total:n._data.length})},i.addEventListener("ln-sort:change",this._onSort),this._onFilterChange=function(c){if(c.preventDefault(),!c.detail)return;const f=c.detail.key,w=c.detail.values||[];if(f){if(w.length===0)delete n._columnFilters[f];else{const p=[];for(let b=0;b<w.length;b++)p.push(w[b].toLowerCase());n._columnFilters[f]=p}n._applyFilterAndSort(),n._vStart=-1,n._vEnd=-1,n._render(),n._updateFooter(),C(i,"ln-table:filter",{term:n._searchTerm,matched:n._filteredData.length,total:n._data.length})}},i.addEventListener("ln-filter:change",this._onFilterChange)),this}o.prototype._parseRows=function(){const i=this.tbody.rows,s=this.ths;this._data=[],i.length>0&&(this._rowHeight=i[0].offsetHeight||40),this._lockColumnWidths();for(let n=0;n<i.length;n++){const c=i[n],f=[],w=[],p=[];for(let _=0;_<c.cells.length;_++){const g=c.cells[_],S=g.textContent.trim();f[_]=W(g),w[_]=S.toLowerCase(),g.querySelector("[data-ln-table-row-action]")||p.push(S.toLowerCase())}let b=null;if(this.isDataDriven){b={};const _=c.getAttribute("data-ln-table-row-id");_!=null&&(b.id=_);for(let g=0;g<s.length;g++){const S=s[g].getAttribute("data-ln-table-col");if(S){const E=g;if(E<c.cells.length){const x=c.cells[E];b[S]=W(x)}}}}this._data.push({values:f,rawTexts:w,html:c.outerHTML,searchText:p.join(" "),id:this.isDataDriven&&b?b.id:void 0,...b})}this._filteredData=this._data.slice(),this._data.length>0&&(this._hasInitialSeed=!0),this.isDataDriven&&(this._lastTotal=this._data.length,this._lastFiltered=this._data.length,this.totalCount=this._data.length,this.visibleCount=this._data.length,this._updateFooter()),this._render(),C(this.dom,"ln-table:ready",{total:this._data.length})},o.prototype._applyFilterAndSort=function(){this._filteredData=this._data?this._data.slice():[],this.visibleCount=this.isDataDriven&&this._lastFiltered!=null?this._lastFiltered:this._filteredData.length},o.prototype._lockColumnWidths=function(){if(!this.table||!this.thead||this._colgroup||this.ths.length&&!this.ths[0].offsetWidth)return;const i=document.createElement("colgroup");this.ths.forEach(function(s){const n=document.createElement("col");n.style.width=s.offsetWidth+"px",i.appendChild(n)}),this.table.insertBefore(i,this.table.firstChild),this.table.style.tableLayout="fixed",this._colgroup=i},o.prototype._render=function(){if(this.tbody)if(this.isDataDriven){const i=this._lastTotal,s=this.visibleCount;if(i===0){if(this._disableVirtualScroll(),!this.isLoaded){this._showLoadingState();return}this._showEmptyState();return}if(this._filteredData.length===0||s===0){if(this._disableVirtualScroll(),!this.isLoaded){this._showLoadingState();return}this._showEmptyState();return}this._filteredData.length>200?(this._enableVirtualScroll(),this._renderVirtual()):(this._disableVirtualScroll(),this._renderAll())}else{const i=this._filteredData.length;i===0&&(this._searchTerm||Object.keys(this._columnFilters).length>0)?(this._disableVirtualScroll(),this._showEmptyState()):i>200?(this._enableVirtualScroll(),this._renderVirtual()):(this._disableVirtualScroll(),this._renderAll())}},o.prototype._renderAll=function(){this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const i=this._filteredData;if(this.isDataDriven||i.length>0&&!i[0].html){const s=document.createDocumentFragment();for(let n=0;n<i.length;n++){const c=this._buildRow(i[n]);if(!c)break;s.appendChild(c)}this.tbody.replaceChildren(s),this._selectable&&this._updateSelectAll()}else{const s=[];for(let n=0;n<i.length;n++)s.push(i[n].html);this.tbody.innerHTML=s.join(""),this._selectable&&this._restoreSelection()}},o.prototype._enableVirtualScroll=function(){if(this._virtual)return;this._virtual=!0,this._vStart=-1,this._vEnd=-1;const i=this;if(!this._rowHeight)if(this.tbody&&this.tbody.rows.length>0)this._rowHeight=this.tbody.rows[0].offsetHeight||40;else{let n=null;this.isDataDriven&&this._data.length>0&&(n=this._buildRow(this._data[0])),n&&this.tbody&&(this.tbody.appendChild(n),this._rowHeight=n.offsetHeight||40,n.remove())}this._scrollContainer=h(this.dom,this.table);const s=this._scrollContainer||window;this.dom&&(this.dom.style.overflowAnchor="none"),this.table&&(this.table.style.overflowAnchor="none"),this.tbody&&(this.tbody.style.overflowAnchor="none"),this._scrollContainer&&(this._scrollContainer.style.overflowAnchor="none"),this._scrollHandler=function(){i._rafId||(i._rafId=requestAnimationFrame(function(){i._rafId=null,i._renderVirtual()}))},this._resizeHandler=function(){i._lockColumnWidths(),i._vResized=!0,i._scrollHandler()},s.addEventListener("scroll",this._scrollHandler,{passive:!0}),window.addEventListener("resize",this._resizeHandler,{passive:!0})},o.prototype._disableVirtualScroll=function(){this._virtual&&(this._virtual=!1,this._scrollHandler&&((this._scrollContainer||window).removeEventListener("scroll",this._scrollHandler),window.removeEventListener("resize",this._resizeHandler),this._scrollHandler=null,this._resizeHandler=null),this._scrollContainer=null,this._rafId&&(cancelAnimationFrame(this._rafId),this._rafId=null),this._vStart=-1,this._vEnd=-1,this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null)},o.prototype._compileRowBindings=function(i){const s={textNodes:[],attrs:[],cellAttrs:[]},n=document.createTreeWalker(i,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const f=n.currentNode;if(f.textContent.indexOf("{{")!==-1){const w=f.parentElement;s.textNodes.push({node:f,raw:f.textContent,el:w,isLeaf:!!(w&&w.children.length===0)})}}const c=Array.from(i.querySelectorAll("*"));i.nodeType===1&&c.push(i);for(let f=0;f<c.length;f++){const w=c[f];if(w.hasAttribute("data-ln-table-cell-attr")){const b=w.getAttribute("data-ln-table-cell-attr").split(",");for(let _=0;_<b.length;_++){const g=b[_].trim().split(":");g.length===2&&s.cellAttrs.push({el:w,field:g[0].trim(),attr:g[1].trim()})}}const p=w.attributes;for(let b=0;b<p.length;b++){const _=p[b];_.value.indexOf("{{")!==-1&&s.attrs.push({el:w,name:_.name,raw:_.value})}}return i._lnBindings=s,s},o.prototype._createTemplateRow=function(){let i=T(this.dom,this.name+"-row","ln-table");if(!i){const n=this.dom.querySelector("template[data-ln-table-row]");n&&(i=document.importNode(n.content,!0))}let s=i?i.querySelector("[data-ln-table-row]")||i.firstElementChild:null;return s?(this._compileRowBindings(s),s):((window.lnDebug||typeof document<"u"&&document.body&&document.body.hasAttribute("data-ln-debug"))&&console.warn(`[ln-table] Missing row template: <template data-ln-template="${this.name}-row">`),null)},o.prototype._updateRow=function(i,s){if(!s)return;i._lnRecord=s,s.id!=null&&i.setAttribute("data-ln-table-row-id",s.id);const n=i._lnBindings||this._compileRowBindings(i),c=n.textNodes;for(let p=0;p<c.length;p++){const b=c[p],_=b.raw.replace(/\{\{\s*(\w+)\s*\}\}/g,function(g,S){return s[S]!==void 0&&s[S]!==null?s[S]:""});b.isLeaf&&b.el?b.el.textContent=_:b.node&&b.node.parentNode?b.node.textContent=_:b.el&&(b.el.textContent=_)}const f=n.attrs;for(let p=0;p<f.length;p++){const b=f[p];b.el.setAttribute(b.name,b.raw.replace(/\{\{\s*(\w+)\s*\}\}/g,function(_,g){return s[g]!==void 0&&s[g]!==null?s[g]:""}))}const w=n.cellAttrs;for(let p=0;p<w.length;p++){const b=w[p],_=s[b.field];_!=null&&b.el.setAttribute(b.attr,_)}if(n.textNodes.length===0&&n.attrs.length===0&&this.ths.length>0)for(let p=0;p<this.ths.length;p++){const b=this.ths[p].getAttribute("data-ln-table-col");b&&p<i.cells.length&&s[b]!=null&&(i.cells[p].textContent=String(s[b]))}if(this._selectable){const p=s.id!=null?String(s.id):null,b=p!=null&&this.selectedIds.has(p);i.classList.toggle("ln-row-selected",b);const _=i.querySelector("[data-ln-table-row-select]");_&&(_.checked=b)}},o.prototype._ensureRowPool=function(i,s){for(this._rowPool?this._topTd&&this._topTd.getAttribute("colspan")!==String(s)&&(this._topTd.setAttribute("colspan",s),this._bottomTd.setAttribute("colspan",s)):(this._rowPool=[],this._topSpacer=document.createElement("tr"),this._topSpacer.className="ln-table__spacer",this._topSpacer.setAttribute("aria-hidden","true"),this._topSpacer.style.overflowAnchor="none",this._topTd=document.createElement("td"),this._topTd.setAttribute("colspan",s),this._topTd.style.padding="0",this._topTd.style.border="none",this._topTd.style.overflowAnchor="none",this._topSpacer.appendChild(this._topTd),this._bottomSpacer=document.createElement("tr"),this._bottomSpacer.className="ln-table__spacer",this._bottomSpacer.setAttribute("aria-hidden","true"),this._bottomSpacer.style.overflowAnchor="none",this._bottomTd=document.createElement("td"),this._bottomTd.setAttribute("colspan",s),this._bottomTd.style.padding="0",this._bottomTd.style.border="none",this._bottomTd.style.overflowAnchor="none",this._bottomSpacer.appendChild(this._bottomTd),this.tbody.replaceChildren(this._topSpacer,this._bottomSpacer));this._rowPool.length<i;){const n=this._createTemplateRow();if(!n)break;this._rowPool.push(n),this.tbody.insertBefore(n,this._bottomSpacer)}},o.prototype._renderVirtual=function(){const i=this._filteredData,s=i.length;if(!this._rowHeight||!s)return;const n=this.thead?this.thead.offsetHeight:0,c=this._scrollContainer;let f,w;if(c){const m=this.table.getBoundingClientRect(),y=c.getBoundingClientRect(),A=m.top-y.top+c.scrollTop+n;f=c.scrollTop-A,w=c.clientHeight}else{const A=this.table.getBoundingClientRect().top+window.scrollY+n;f=window.scrollY-A,w=window.innerHeight}let p=f;if(this._vResized){this._vResized=!1;const m=this._vEnd-this._vStart,y=this._rowPool&&this._rowPool[m-1],A=y?(y.getBoundingClientRect().bottom-this._rowPool[0].getBoundingClientRect().top)/m:0;A&&A!==this._rowHeight&&(this._rowHeight=A,this._vStart=-1,this._vTop>0&&(p=this._vTop*A))}const b=this._rowHeight;this._vTop=p/b;const _=Gt(p,w,b,s,15),g=_.start,S=_.end;if(g===this._vStart&&S===this._vEnd)return;this._vStart=g,this._vEnd=S;const E=this.ths.length||1,x=S-g;this._ensureRowPool(x,E),_.topPadding>0?(this._topTd.style.height=_.topPadding+"px",this._topSpacer.style.display=""):(this._topTd.style.height="0px",this._topSpacer.style.display="none"),_.bottomPadding>0?(this._bottomTd.style.height=_.bottomPadding+"px",this._bottomSpacer.style.display=""):(this._bottomTd.style.height="0px",this._bottomSpacer.style.display="none");for(let m=0;m<this._rowPool.length;m++){const y=this._rowPool[m],A=g+m;if(m<x&&A<s){y.style.display="";const v=i[A];if(v&&v.html){const k=document.createElement("tbody");k.innerHTML=v.html;const L=k.firstElementChild;L&&(y.innerHTML=L.innerHTML,y.className=L.className,y._lnRecord=v,v.id!=null&&y.setAttribute("data-ln-table-row-id",v.id))}else this._updateRow(y,v)}else y.style.display="none"}this._selectable&&this._updateSelectAll(),p!==f&&(c?c.scrollTop+=p-f:window.scrollTo(window.scrollX,window.scrollY+p-f))},o.prototype._showLoadingState=function(){this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const i=this.ths.length||1;let s=null,n=T(this.dom,this.name+"-loading","ln-table")||T(this.dom,"table-loading","ln-table");if(!n){const c=this.dom.querySelector("template[data-ln-table-loading]");c&&(n=document.importNode(c.content,!0))}if(n)if(n.tagName==="TR")s=n;else{const c=document.createElement("td");c.setAttribute("colspan",String(i)),c.appendChild(n);const f=document.createElement("tr");f.appendChild(c),s=f}s?(s.setAttribute("data-ln-table-empty",""),this.tbody.replaceChildren(s)):this.tbody.replaceChildren()},o.prototype._showEmptyState=function(){this._rowPool=null,this._topSpacer=null,this._topTd=null,this._bottomSpacer=null,this._bottomTd=null;const i=this.ths.length||1;let s=null,n=null;if(this.isDataDriven){const c=this._lastTotal!=null?this._lastTotal:this._data.length,w=this.visibleCount===0&&c>0,p=w?this.name+"-empty-filtered":this.name+"-empty";if(n=T(this.dom,p,"ln-table")||T(this.dom,w?"table-empty-filtered":"table-empty","ln-table"),!n){const b=this.dom.querySelector("template[data-ln-table-empty]");if(b){const _=w?"search":"initial",g=b.content.querySelector('[data-ln-table-empty-when="'+_+'"]')||b.content.firstElementChild;g&&(n=document.importNode(g,!0))}}}else if(n=T(this.dom,this.name+"-empty","ln-table")||T(this.dom,"table-empty","ln-table"),!n){const c=this.dom.querySelector("template[data-ln-table-empty]");c&&(n=document.importNode(c.content,!0))}if(n)if(n.tagName==="TR")s=n;else{const c=document.createElement("td");c.setAttribute("colspan",String(i)),c.appendChild(n);const f=document.createElement("tr");f.appendChild(c),s=f}s?(s.setAttribute("data-ln-table-empty",""),this.tbody.replaceChildren(s)):this.tbody.replaceChildren(),C(this.dom,"ln-table:empty",{term:this.isDataDriven?this.currentSearch||"":this._searchTerm,total:this.isDataDriven?this._lastTotal!=null?this._lastTotal:this._data.length:this._data.length})},o.prototype._fillRow=function(i,s){O(i,s);const n=i.querySelectorAll("[data-ln-table-cell-attr]");for(let c=0;c<n.length;c++){const f=n[c],w=f.getAttribute("data-ln-table-cell-attr").split(",");for(let p=0;p<w.length;p++){const b=w[p].trim().split(":");if(b.length!==2)continue;const _=b[0].trim(),g=b[1].trim();s[_]!=null&&f.setAttribute(g,s[_])}}},o.prototype._buildRow=function(i){let s=T(this.dom,this.name+"-row","ln-table");if(!s){const c=this.dom.querySelector("template[data-ln-table-row]");c&&(s=document.importNode(c.content,!0))}let n=s?s.querySelector("[data-ln-table-row]")||s.firstElementChild:null;if(n)this._fillRow(n,i);else if(i&&i.html){const c=document.createElement("tbody");c.innerHTML=i.html,n=c.firstElementChild}else return(window.lnDebug||typeof document<"u"&&document.body&&document.body.hasAttribute("data-ln-debug"))&&console.warn(`[ln-table] Missing row template: <template data-ln-template="${this.name}-row">`),null;if(n._lnRecord=i,i.id!=null&&n.setAttribute("data-ln-table-row-id",i.id),this._selectable&&i.id!=null&&this.selectedIds.has(String(i.id))){n.classList.add("ln-row-selected");const c=n.querySelector("[data-ln-table-row-select]");c&&(c.checked=!0)}return n},o.prototype._requestData=function(){ut(this,"ln-table:request-data","table")},o.prototype._updateSelectAll=function(){if(!this._selectAllCheckbox||!this.tbody)return;const i=this.tbody.querySelectorAll("[data-ln-table-row]"),s=[];for(let c=0;c<i.length;c++){const f=i[c].getAttribute("data-ln-table-row-id");f!=null&&s.push(f)}const n=Yt(s,this.selectedIds);this._selectAllCheckbox.checked=n.isAllSelected,this._selectAllCheckbox.indeterminate=n.isIndeterminate},o.prototype._restoreSelection=function(){if(!this.tbody)return;const i=this.tbody.querySelectorAll("[data-ln-table-row]");for(let s=0;s<i.length;s++){const n=i[s].getAttribute("data-ln-table-row-id"),c=n!=null&&this.selectedIds.has(n);i[s].classList.toggle("ln-row-selected",c);const f=i[s].querySelector("[data-ln-table-row-select]");f&&(f.checked=c)}this._updateSelectAll()},Object.defineProperty(o.prototype,"selectedCount",{get:function(){return this.selectedIds.size},set:function(){}}),o.prototype._enableSelection=function(){if(this._selectableActive)return;this._selectableActive=!0;const i=this;if(this._onSelectionChange=function(s){const n=s.target.closest("[data-ln-table-row-select]");if(!n)return;const c=n.closest("[data-ln-table-row]");if(!c)return;const f=c.getAttribute("data-ln-table-row-id");f!=null&&(i.selectedIds=ct(i.selectedIds,f,n.checked),c.classList.toggle("ln-row-selected",n.checked),i.selectedCount=i.selectedIds.size,i._updateSelectAll(),i._updateFooter(),C(i.dom,"ln-table:select",{table:i.name,selectedIds:i.selectedIds,count:i.selectedCount}))},this.tbody&&this.tbody.addEventListener("change",this._onSelectionChange),this._selectAllCheckbox=this.dom.querySelector('[data-ln-table-col-select] input[type="checkbox"]')||this.dom.querySelector("[data-ln-table-col-select]"),this._selectAllCheckbox&&this._selectAllCheckbox.tagName==="TH"){const s=document.createElement("input");s.type="checkbox";const n=i.dom.querySelector('[data-ln-table-dict="select-all"]'),c=i.dom.getAttribute("data-ln-table-select-all-label")||(n?n.textContent.trim():null)||"Select all";s.setAttribute("aria-label",c),this._selectAllCheckbox.appendChild(s),this._selectAllCheckbox=s}if(this._selectAllCheckbox&&(this._onSelectAll=function(){const s=i._selectAllCheckbox.checked,n=i.tbody?i.tbody.querySelectorAll("[data-ln-table-row]"):[],c=[];for(let f=0;f<n.length;f++){const w=n[f].getAttribute("data-ln-table-row-id"),p=n[f].querySelector("[data-ln-table-row-select]");w!=null&&(c.push(w),n[f].classList.toggle("ln-row-selected",s),p&&(p.checked=s))}i.selectedIds=dt(i.selectedIds,c,s),i.selectedCount=i.selectedIds.size,C(i.dom,"ln-table:select-all",{table:i.name,selected:s}),C(i.dom,"ln-table:select",{table:i.name,selectedIds:i.selectedIds,count:i.selectedCount}),i._updateFooter()},this._selectAllCheckbox.addEventListener("change",this._onSelectAll)),this.tbody){const s=this.tbody.querySelectorAll("[data-ln-table-row]");for(let n=0;n<s.length;n++){const c=s[n].querySelector("[data-ln-table-row-select]"),f=s[n].getAttribute("data-ln-table-row-id");c&&c.checked&&f!=null&&(i.selectedIds=ct(i.selectedIds,f,!0),s[n].classList.add("ln-row-selected"))}this.selectedCount=this.selectedIds.size,this.selectedCount>0&&this._updateSelectAll()}},o.prototype._disableSelection=function(){if(!this._selectableActive)return;this._selectableActive=!1,this.tbody&&this._onSelectionChange&&this.tbody.removeEventListener("change",this._onSelectionChange),this._selectAllCheckbox&&this._onSelectAll&&this._selectAllCheckbox.removeEventListener("change",this._onSelectAll);const i=this.dom.querySelector("[data-ln-table-col-select]");if(i){const s=i.querySelector('input[type="checkbox"]');s&&s.remove()}if(this._selectAllCheckbox=null,this.selectedIds=dt(this.selectedIds,Array.from(this.selectedIds),!1),this.selectedCount=0,this.tbody){const s=this.tbody.querySelectorAll("[data-ln-table-row]");for(let n=0;n<s.length;n++){s[n].classList.remove("ln-row-selected");const c=s[n].querySelector("[data-ln-table-row-select]");c&&(c.checked=!1)}}this._updateFooter()},o.prototype._updateFooter=function(){let i=0,s=0;this.isDataDriven?(i=this._lastTotal!=null?this._lastTotal:this._data.length,s=this.visibleCount):(i=this._data.length,s=this._filteredData.length);const n=s<i;if(this._totalSpan&&d(this._totalSpan,i),this._filteredSpan&&d(this._filteredSpan,n?s:null),this._filteredWrap&&this._filteredWrap.classList.toggle("hidden",!n),this._selectedSpan){const c=this.selectedIds?this.selectedIds.size:0;d(this._selectedSpan,c>0?c:null),this._selectedWrap&&this._selectedWrap.classList.toggle("hidden",c===0)}},o.prototype.destroy=function(){this.dom[e]&&(this._disableVirtualScroll(),this.dom.removeEventListener("ln-table:set-search",this._onSetSearch),this.dom.removeEventListener("ln-table:request-clear-filters",this._onRequestClearFilters),this.isDataDriven?(this.dom.removeEventListener("ln-table:set-data",this._onSetData),this.dom.removeEventListener("ln-table:set-loading",this._onSetLoading),this.dom.removeEventListener("ln-sort:change",this._onSort),this.tbody&&(this.tbody.removeEventListener("click",this._onRowClick),this.tbody.removeEventListener("click",this._onRowAction))):(this._emptyTbodyObserver&&(this._emptyTbodyObserver.disconnect(),this._emptyTbodyObserver=null),this.dom.removeEventListener("ln-sort:change",this._onSort),this.dom.removeEventListener("ln-search:change",this._onSearchChange),this.dom.removeEventListener("ln-filter:change",this._onFilterChange)),this._onSelectionChange&&this.tbody&&this.tbody.removeEventListener("change",this._onSelectionChange),this._selectAllCheckbox&&this._onSelectAll&&this._selectAllCheckbox.removeEventListener("change",this._onSelectAll),this._colgroup&&(this._colgroup.remove(),this._colgroup=null),this.table&&(this.table.style.tableLayout=""),this._loadingIndicator=null,this._data=[],this._filteredData=[],delete this.dom[e])},st(t,e,o,"ln-table",{attributes:a})})()})();
|