@livenetworks/ashlar 2.0.6 → 2.0.8

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.
Files changed (221) hide show
  1. package/LICENSE +641 -641
  2. package/components/COMPONENTS.md +1116 -1116
  3. package/components/index.js +81 -81
  4. package/components/ln-accordion/ln-accordion-dev.scss +8 -8
  5. package/components/ln-accordion/ln-accordion.js +1 -1
  6. package/components/ln-accordion/ln-accordion.schema.json +30 -30
  7. package/components/ln-accordion/src/ln-accordion.js +1 -0
  8. package/components/ln-ajax/ln-ajax-dev.scss +8 -8
  9. package/components/ln-ajax/ln-ajax.js +1 -1
  10. package/components/ln-ajax/ln-ajax.schema.json +30 -30
  11. package/components/ln-api-connector/ln-api-connector.js +1 -1
  12. package/components/ln-api-connector/ln-api-connector.schema.json +96 -96
  13. package/components/ln-api-connector/src/ln-api-connector.js +1 -0
  14. package/components/ln-api-queue/ln-api-queue.js +1 -1
  15. package/components/ln-api-queue/ln-api-queue.schema.json +34 -34
  16. package/components/ln-api-queue/src/ln-api-queue.js +3 -13
  17. package/components/ln-autoresize/ln-autoresize-dev.scss +8 -8
  18. package/components/ln-autoresize/ln-autoresize.js +1 -1
  19. package/components/ln-autoresize/ln-autoresize.schema.json +22 -22
  20. package/components/ln-autosave/ln-autosave-dev.scss +13 -13
  21. package/components/ln-autosave/ln-autosave.js +1 -1
  22. package/components/ln-autosave/ln-autosave.schema.json +48 -48
  23. package/components/ln-autosave/src/autosave-model.js +34 -34
  24. package/components/ln-chart/ln-chart.js +1 -1
  25. package/components/ln-chart/ln-chart.schema.json +146 -146
  26. package/components/ln-chart/src/chart-model.js +154 -154
  27. package/components/ln-circular-progress/ln-circular-progress.js +1 -1
  28. package/components/ln-circular-progress/ln-circular-progress.schema.json +42 -42
  29. package/components/ln-confirm/ln-confirm-dev.scss +24 -24
  30. package/components/ln-confirm/ln-confirm.js +1 -1
  31. package/components/ln-confirm/ln-confirm.schema.json +66 -66
  32. package/components/ln-confirm/src/ln-confirm.js +178 -178
  33. package/components/ln-core/crypto.js +286 -265
  34. package/components/ln-core/dom.js +115 -115
  35. package/components/ln-core/form.js +136 -136
  36. package/components/ln-core/helpers.js +33 -33
  37. package/components/ln-core/http.js +48 -48
  38. package/components/ln-core/index.js +1 -1
  39. package/components/ln-core/ln-core.schema.json +109 -109
  40. package/components/ln-core/locale.js +55 -55
  41. package/components/ln-core/matching.js +78 -78
  42. package/components/ln-core/number.js +125 -125
  43. package/components/ln-core/template.js +206 -206
  44. package/components/ln-couchdb-connector/README.md +4 -0
  45. package/components/ln-couchdb-connector/ln-couchdb-connector.js +1 -1
  46. package/components/ln-couchdb-connector/ln-couchdb-connector.schema.json +50 -50
  47. package/components/ln-couchdb-connector/src/ln-couchdb-connector.js +19 -1
  48. package/components/ln-data-coordinator/README.md +9 -38
  49. package/components/ln-data-coordinator/ln-data-coordinator-dev.scss +8 -8
  50. package/components/ln-data-coordinator/ln-data-coordinator.js +1 -1
  51. package/components/ln-data-coordinator/ln-data-coordinator.schema.json +16 -16
  52. package/components/ln-data-coordinator/src/data-read-policy.js +0 -7
  53. package/components/ln-data-coordinator/src/ln-data-coordinator.js +428 -1299
  54. package/components/ln-data-store/README.md +3 -2
  55. package/components/ln-data-store/ln-data-store-dev.scss +13 -13
  56. package/components/ln-data-store/ln-data-store.js +1 -1
  57. package/components/ln-data-store/ln-data-store.schema.json +84 -84
  58. package/components/ln-data-store/src/data-store-model.js +184 -155
  59. package/components/ln-data-store/src/ln-data-store.js +58 -11
  60. package/components/ln-date/README.md +4 -0
  61. package/components/ln-date/ln-date.js +1 -1
  62. package/components/ln-date/ln-date.schema.json +92 -92
  63. package/components/ln-date/src/date-model.js +186 -186
  64. package/components/ln-date/src/ln-date.js +3 -3
  65. package/components/ln-debug/ln-debug.js +1 -1
  66. package/components/ln-debug/ln-debug.schema.json +28 -28
  67. package/components/ln-debug/src/console-sink.js +19 -19
  68. package/components/ln-debug/src/gate.js +95 -95
  69. package/components/ln-debug/src/generated-attributes.js +2 -2
  70. package/components/ln-dropdown/ln-dropdown-dev.scss +13 -13
  71. package/components/ln-dropdown/ln-dropdown.js +1 -1
  72. package/components/ln-dropdown/ln-dropdown.schema.json +90 -90
  73. package/components/ln-editor/ln-editor.js +1 -1
  74. package/components/ln-editor/ln-editor.schema.json +58 -58
  75. package/components/ln-external-links/ln-external-links.js +1 -1
  76. package/components/ln-external-links/ln-external-links.schema.json +18 -18
  77. package/components/ln-fill/ln-fill.js +1 -1
  78. package/components/ln-fill/ln-fill.schema.json +23 -23
  79. package/components/ln-filter/ln-filter.js +1 -1
  80. package/components/ln-filter/ln-filter.schema.json +153 -153
  81. package/components/ln-filter/src/filter-model.js +185 -185
  82. package/components/ln-form/ln-form-dev.scss +8 -8
  83. package/components/ln-form/ln-form.js +1 -1
  84. package/components/ln-form/ln-form.schema.json +45 -45
  85. package/components/ln-http/ln-http.js +1 -1
  86. package/components/ln-http/ln-http.schema.json +6 -6
  87. package/components/ln-icon/ln-icon.schema.json +6 -6
  88. package/components/ln-include/ln-include.js +1 -1
  89. package/components/ln-include/ln-include.schema.json +23 -23
  90. package/components/ln-key/ln-key-dev.scss +18 -18
  91. package/components/ln-key/ln-key.js +1 -1
  92. package/components/ln-key/ln-key.schema.json +56 -56
  93. package/components/ln-key/src/ln-key.js +10 -10
  94. package/components/ln-link/ln-link-dev.scss +8 -8
  95. package/components/ln-link/ln-link.js +1 -1
  96. package/components/ln-link/ln-link.schema.json +22 -22
  97. package/components/ln-list/README.md +152 -152
  98. package/components/ln-list/ln-list-dev.scss +8 -8
  99. package/components/ln-list/ln-list.js +1 -1
  100. package/components/ln-list/ln-list.schema.json +166 -166
  101. package/components/ln-list/src/ln-list.js +4 -4
  102. package/components/ln-modal/README.md +4 -6
  103. package/components/ln-modal/ln-modal.js +1 -1
  104. package/components/ln-modal/ln-modal.schema.json +65 -65
  105. package/components/ln-modal/src/ln-modal.js +28 -8
  106. package/components/ln-nav/ln-nav.js +1 -1
  107. package/components/ln-nav/ln-nav.schema.json +25 -25
  108. package/components/ln-number/ln-number.js +1 -1
  109. package/components/ln-number/ln-number.schema.json +63 -63
  110. package/components/ln-number/src/number-model.js +31 -31
  111. package/components/ln-obfuscator/README.md +60 -60
  112. package/components/ln-obfuscator/ln-obfuscator.js +1 -1
  113. package/components/ln-obfuscator/ln-obfuscator.schema.json +49 -49
  114. package/components/ln-obfuscator/src/ln-obfuscator.js +159 -159
  115. package/components/ln-obfuscator/src/obfuscator-model.js +250 -250
  116. package/components/ln-options/ln-options.js +1 -1
  117. package/components/ln-options/ln-options.schema.json +41 -41
  118. package/components/ln-options/src/ln-options.js +1 -0
  119. package/components/ln-persist/README.md +151 -151
  120. package/components/ln-persist/ln-persist.js +1 -1
  121. package/components/ln-persist/ln-persist.schema.json +28 -28
  122. package/components/ln-persist/src/ln-persist.js +83 -83
  123. package/components/ln-picklist/README.md +230 -230
  124. package/components/ln-picklist/ln-picklist-dev.scss +22 -22
  125. package/components/ln-picklist/ln-picklist.js +1 -1
  126. package/components/ln-picklist/ln-picklist.schema.json +49 -49
  127. package/components/ln-picklist/src/ln-picklist.js +228 -228
  128. package/components/ln-popover/README.md +4 -0
  129. package/components/ln-popover/ln-popover-dev.scss +13 -13
  130. package/components/ln-popover/ln-popover.js +1 -1
  131. package/components/ln-popover/ln-popover.schema.json +82 -82
  132. package/components/ln-popover/src/ln-popover.js +9 -0
  133. package/components/ln-progress/ln-progress-dev.scss +8 -8
  134. package/components/ln-progress/ln-progress.js +1 -1
  135. package/components/ln-progress/ln-progress.schema.json +40 -40
  136. package/components/ln-router/ln-router.js +1 -1
  137. package/components/ln-router/ln-router.schema.json +76 -76
  138. package/components/ln-scroll/README.md +45 -45
  139. package/components/ln-scroll/ln-scroll.js +1 -1
  140. package/components/ln-scroll/ln-scroll.schema.json +85 -85
  141. package/components/ln-scroll/src/ln-scroll.js +150 -150
  142. package/components/ln-search/README.md +188 -188
  143. package/components/ln-search/ln-search.js +1 -1
  144. package/components/ln-search/ln-search.schema.json +103 -103
  145. package/components/ln-slug/ln-slug.js +1 -1
  146. package/components/ln-slug/ln-slug.schema.json +23 -23
  147. package/components/ln-sort/ln-sort.js +1 -1
  148. package/components/ln-sort/ln-sort.schema.json +104 -104
  149. package/components/ln-sort/src/ln-sort.js +321 -321
  150. package/components/ln-sort/src/sort-model.js +117 -117
  151. package/components/ln-sortable/ln-sortable-dev.scss +13 -13
  152. package/components/ln-sortable/ln-sortable.js +1 -1
  153. package/components/ln-sortable/ln-sortable.schema.json +36 -36
  154. package/components/ln-stat/ln-stat-dev.scss +8 -8
  155. package/components/ln-stat/ln-stat.js +1 -1
  156. package/components/ln-stat/ln-stat.schema.json +32 -32
  157. package/components/ln-stat/src/stat-model.js +28 -28
  158. package/components/ln-table/ln-table.js +1 -1
  159. package/components/ln-table/ln-table.schema.json +211 -211
  160. package/components/ln-table/src/ln-table.js +2 -0
  161. package/components/ln-table/src/table-model.js +98 -98
  162. package/components/ln-table-coordinator/ln-table-coordinator.js +1 -1
  163. package/components/ln-table-coordinator/ln-table-coordinator.schema.json +93 -93
  164. package/components/ln-table-coordinator/src/ln-table-coordinator.js +3 -3
  165. package/components/ln-tabs/README.md +2 -2
  166. package/components/ln-tabs/ln-tabs.js +1 -1
  167. package/components/ln-tabs/ln-tabs.schema.json +75 -75
  168. package/components/ln-tabs/src/ln-tabs.js +208 -207
  169. package/components/ln-tabs/src/tabs-model.js +82 -82
  170. package/components/ln-time/ln-time-dev.scss +13 -13
  171. package/components/ln-time/ln-time.js +1 -1
  172. package/components/ln-time/ln-time.schema.json +38 -38
  173. package/components/ln-toast/ln-toast.js +1 -1
  174. package/components/ln-toast/ln-toast.schema.json +65 -65
  175. package/components/ln-toggle/ln-toggle.js +1 -1
  176. package/components/ln-toggle/ln-toggle.schema.json +52 -52
  177. package/components/ln-tooltip/ln-tooltip.js +1 -1
  178. package/components/ln-tooltip/ln-tooltip.schema.json +86 -86
  179. package/components/ln-translations/ln-translations.js +1 -1
  180. package/components/ln-translations/ln-translations.schema.json +120 -120
  181. package/components/ln-ui-coordinator/README.md +62 -62
  182. package/components/ln-ui-coordinator/ln-ui-coordinator.js +1 -1
  183. package/components/ln-ui-coordinator/ln-ui-coordinator.schema.json +28 -28
  184. package/components/ln-ui-coordinator/src/ln-ui-coordinator.js +140 -140
  185. package/components/ln-upload/ln-upload.js +1 -1
  186. package/components/ln-upload/ln-upload.schema.json +193 -193
  187. package/components/ln-upload/src/upload-model.js +78 -78
  188. package/components/ln-validate/ln-validate.js +1 -1
  189. package/components/ln-validate/ln-validate.schema.json +50 -50
  190. package/components/ln-validate/src/validate-model.js +64 -64
  191. package/components/ln-websocket-connector/README.md +166 -166
  192. package/components/ln-websocket-connector/ln-websocket-connector.js +1 -1
  193. package/components/ln-websocket-connector/ln-websocket-connector.schema.json +29 -29
  194. package/components/ln-websocket-connector/src/ln-websocket-connector.js +283 -279
  195. package/ln-ashlar.html-data.json +7 -8
  196. package/package.json +84 -84
  197. package/theme/brand.css +73 -73
  198. package/theme/components/_confirm.scss +6 -6
  199. package/theme/components/_picklist.scss +3 -3
  200. package/theme/config/_palette.scss +274 -274
  201. package/theme/config/_theme.scss +292 -292
  202. package/theme/config/_tokens.scss +285 -285
  203. package/theme/config/mixins/_index.scss +62 -62
  204. package/theme/config/mixins/_picklist.scss +66 -66
  205. package/theme/ln-ashlar-dev.scss +66 -66
  206. package/theme/ln-ashlar-landing.scss +56 -56
  207. package/theme/ln-ashlar-theme.scss +63 -63
  208. package/theme/presentation/_bento.scss +151 -151
  209. package/theme/presentation/_cta.scss +111 -111
  210. package/theme/presentation/_effects.scss +216 -216
  211. package/theme/presentation/_features.scss +108 -108
  212. package/theme/presentation/_footer.scss +129 -129
  213. package/theme/presentation/_hero.scss +158 -158
  214. package/theme/presentation/_layout.scss +170 -170
  215. package/theme/presentation/_navbar.scss +140 -140
  216. package/theme/presentation/_pricing.scss +262 -262
  217. package/theme/presentation/_stats.scss +87 -87
  218. package/theme/presentation/_testimonials.scss +124 -124
  219. package/theme/presentation/_tokens.scss +39 -39
  220. package/theme/presentation/_typography.scss +163 -163
  221. package/web-types.json +12 -12
@@ -1 +1 @@
1
- (function(){"use strict";function q(){return typeof window>"u"?!1:window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink?!0:typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null:!1}function M(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 o=null;for(let r=1;r<t.length;r++)if(t[r]&&t[r].nodeType===1){o=t[r];break}if(!M(o))return}e.apply(console,t)}}function J(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))}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()}const B={};function G(e,t){B[e]=t}function X(e){return B[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=G,window.lnCore.getDataMapper=X);function Z(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 W(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,k(function(){new MutationObserver(function(){J(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const j={};function ee(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];j[n]=t}function x(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return j[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=ee,window.lnCore.getLocaleFallback=x,window.lnCore.ensureLocaleObserver=W);const D={};function te(e,t){D[e]||(D[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=D[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function V(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let l=0;l<n.length;l++){const a=n[l],s=a.getAttribute("data-ln-field");t[s]!=null&&(a.textContent=t[s])}const o=e.querySelectorAll("[data-ln-attr]");for(let l=0;l<o.length;l++){const a=o[l],s=a.getAttribute("data-ln-attr").split(",");for(let c=0;c<s.length;c++){const h=s[c].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),b=h[1].trim();t[b]!=null&&a.setAttribute(w,t[b])}}const r=e.querySelectorAll("[data-ln-show]");for(let l=0;l<r.length;l++){const a=r[l],s=a.getAttribute("data-ln-show");s in t&&a.classList.toggle("hidden",!t[s])}const i=e.querySelectorAll("[data-ln-class]");for(let l=0;l<i.length;l++){const a=i[l],s=a.getAttribute("data-ln-class").split(",");for(let c=0;c<s.length;c++){const h=s[c].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),b=h[1].trim();b in t&&a.classList.toggle(w,!!t[b])}}return e}function ne(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 o=0;o<n.length;o++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[o],t??null),n[o].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)V(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 H(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const i=n.currentNode;i.textContent.indexOf("{{")!==-1&&(i.textContent=i.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(l,a){return t[a]!==void 0?t[a]:""}))}const o=function(i,l){return t[l]!==void 0?t[l]:""},r=Array.from(e.querySelectorAll("*"));e.nodeType===1&&r.push(e);for(let i=0;i<r.length;i++){const l=r[i],a=l.attributes;for(let s=0;s<a.length;s++){const c=a[s];c.value.indexOf("{{")!==-1&&l.setAttribute(c.name,c.value.replace(/\{\{\s*(\w+)\s*\}\}/g,o))}}return e}function oe(e,t,n,o,r,i){const l={};for(let s=0;s<e.children.length;s++){const c=e.children[s],h=c.getAttribute("data-ln-render-key");h&&(l[h]=c)}const a=document.createDocumentFragment();for(let s=0;s<t.length;s++){const c=t[s],h=String(o(c));let w=l[h];if(w)r(w,c,s);else{const b=te(n,i);if(!b||(H(b,c),w=b.firstElementChild,!w))continue;w.setAttribute("data-ln-render-key",h),r(w,c,s)}a.appendChild(w)}e.textContent="",e.appendChild(a)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=H,window.lnCore.fill=V,window.lnCore.lnFill=ne,window.lnCore.renderList=oe);function U(e,t,n,o,r){if(!e||t===null)return!0;const i=o||"ln-component",l=e.type;if(l==="trigger"||l==="marker"||l==="string"||l==="list"||!l||t===""&&e.fallback!==void 0)return!0;const a=s=>{r?console.warn(s,r):console.warn(s)};if(l==="boolean"){const s=t.trim().toLowerCase();return s!==""&&s!=="true"&&s!=="false"&&s!=="1"&&s!=="0"?(a(`[${i}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(l==="enum"){const s=e.values||[];return s.includes(t)?!0:(a(`[${i}] Invalid value "${t}" for attribute "${n}". Allowed: ${s.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(l==="integer"){if(!/^-?\d+$/.test(t))return a(`[${i}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const s=parseInt(t,10);return e.min!==void 0&&s<e.min?(a(`[${i}] Value ${s} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&s>e.max?(a(`[${i}] Value ${s} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(l==="float")return isNaN(Number(t))?(a(`[${i}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(l==="json")try{return JSON.parse(t),!0}catch(s){return a(`[${i}] Invalid JSON for attribute "${n}": ${s.message}. Fallback: ${e.fallback}.`),!1}return!0}function re(e){const t={};for(const n in e){const o=e[n];o&&o.effect&&(t[n]=o.effect)}return Object.keys(t).length?t:null}function ie(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}function $(e,t,n,o){if(e.nodeType!==1)return;const i=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",l=Array.from(e.querySelectorAll(i));e.matches&&e.matches(i)&&l.push(e);for(const a of l)if(!a[n]){window.lnCore._persistSink&&a.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(a,t);try{a[n]=new o(a)}catch(s){console.error("["+n+"] init failed",a,s)}}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function le(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function se(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 Q(){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 ue(e){const t=Q(),n=e.observed||[];for(let o=0;o<n.length;o++){const r=n[o];t.byAttr.has(r)||t.byAttr.set(r,[]),t.byAttr.get(r).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const o in e.attributes){t.byDeclaredAttr.has(o)||t.byDeclaredAttr.set(o,[]);const r=t.byDeclaredAttr.get(o);r.some(i=>i.componentTag===e.componentTag)||r.push({spec:e.attributes[o],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const o=ie(e);if(o===null)t.reactiveWildcard.push(e);else for(const r of o)t.byReactive.has(r)||t.byReactive.set(r,[]),t.byReactive.get(r).push(e)}e.persist&&t.persist.push(e)}function Y(e,t,n,o){for(let r=0;r<e.length;r++){const i=e[r];if(!t[i.attribute])continue;const l=i.effects&&i.effects[n];l?l(t,n,o):i.onAttrChange&&(!i.declared||i.declared.has(n))&&i.onAttrChange(t,n,o)}}function ae(e){const t=e.target,n=e.attributeName;if(e.oldValue===t.getAttribute(n))return;const o=Q(),r=o.byAttr.get(n);if(q()&&o.byDeclaredAttr&&o.byDeclaredAttr.has(n)&&M(t)){const i=o.byDeclaredAttr.get(n),l=t.getAttribute(n);for(let a=0;a<i.length;a++)U(i[a].spec,l,n,i[a].componentTag,t)}if(window.lnCore._debugSink&&(n.indexOf("data-ln-")===0||r)&&window.lnCore._debugSink("attr",n,t,{oldValue:e.oldValue,newValue:t.getAttribute(n)}),n.indexOf("data-ln-")===0){const i=o.byReactive.get(n);i&&Y(i,t,n,e.oldValue),o.reactiveWildcard.length&&Y(o.reactiveWildcard,t,n,e.oldValue)}if(r)for(let i=0;i<r.length;i++){const l=r[i];if(l.handler){l.handler(t,n,e.oldValue);continue}l.onAttributeChange&&t[l.attribute]?l.onAttributeChange(t,n):($(t,l.selector,l.attribute,l.ComponentFn),l.onInit&&l.onInit(t))}}function ce(){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{ae(t[n])}catch(o){console.error("[ln-core] mutation handler failed",t[n].target,o)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function K(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function de(e){const t=K();if(t.length){if(e.target)for(let n=0;n<t.length;n++){const o=t[n];if(o.onSubtreeChange){const r=o.query,i=e.target.nodeType===1?e.target.matches(r)?e.target:e.target.closest(r):e.target.parentElement?e.target.parentElement.closest(r):null;i&&o.onSubtreeChange(i,e)}}for(let n=0;n<e.addedNodes.length;n++){const o=e.addedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r];$(o,i.selector,i.attribute,i.ComponentFn),i.onInit&&i.onInit(o)}}for(let n=0;n<e.removedNodes.length;n++){const o=e.removedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r],l=i.query,a=Array.from(o.querySelectorAll(l));o.matches&&o.matches(l)&&a.push(o);for(let s=0;s<a.length;s++){const c=a[s];if(!document.contains(c)){const h=c[i.attribute];if(h&&typeof h.destroy=="function")try{h.destroy()}catch(w){console.error("["+i.attribute+"] destroy failed",c,w)}delete c[i.attribute]}}}}}}function fe(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,k(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++){const o=t[n];if(o.type==="childList")try{de(o)}catch(r){console.error("[ln-core] lifecycle handler failed",o.target,r)}}}).observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function we(e,t,n,o,r={}){const i=r.extraAttributes||[],l=r.onAttributeChange||null,a=r.onSubtreeChange||null,s=r.onInit||null,c=r.onAttrChange||null,h=r.effects||null,w=r.attributes||null,b=w?re(w):h,T=w?new Set(Object.keys(w)):null,L=r.persist||null;function A(v){const p=v||document.body;if($(p,e,t,n),w&&q())for(const u in w){const d=w[u],f=Array.from(p.querySelectorAll("["+u+"]"));p.matches&&p.matches("["+u+"]")&&f.push(p);for(let m=0;m<f.length;m++){const g=f[m];M(g)&&U(d,g.getAttribute(u),u,o,g)}}s&&s(p)}const S=[];if(e.indexOf("[")!==-1){const v=/\[([\w-]+)/g;let p;for(;(p=v.exec(e))!==null;)S.push(p[1])}else S.push(e);ue({selector:e,attribute:t,componentTag:o,attributes:w,ComponentFn:n,onInit:s,observed:S.concat(i),onAttributeChange:l,onAttrChange:c,effects:b,declared:T,persist:L}),ce();const y=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]";K().push({selector:e,attribute:t,ComponentFn:n,onInit:s,onSubtreeChange:a,query:y}),fe(),window[t]=A;function _(){le()>0?se(function(){A(document.body)}):A(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",_):_(),A}function P(e){return(e||"").replace(/^#/,"")}function E(e){const t=e===void 0?location.hash:e,n={},o=P(t);if(!o)return n;const r=o.split("&");for(let i=0;i<r.length;i++){const l=r[i];if(!l)continue;const a=l.indexOf(":"),s=a>-1?l.slice(0,a):l,c=a>-1?l.slice(a+1):"";if(s)try{n[s]=decodeURIComponent(c)}catch{n[s]=c}}return n}function he(e){if(!e)return null;const t=E();return e in t?t[e]:null}function ge(e,t){if(!e)return;const n=E();t==null?delete n[e]:n[e]=String(t);const r=Object.keys(n).map(function(i){const l=n[i];return l===""?i:i+":"+encodeURIComponent(l)}).join("&");P(location.hash)!==r&&(location.hash=r)}function be(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function me(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 o=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return o?t?o+"-"+t:o:t||null}function pe(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function Ce(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 ye(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function ve(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),o=e.slice(t+1),r=o?o.split(",").map(function(i){try{return decodeURIComponent(i)}catch{return i}}).filter(Boolean):[];return{key:n,values:r}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=E,window.lnCore.hashGet=he,window.lnCore.hashSet=ge,window.lnCore.hashLinkClick=be,window.lnCore.resolveHashNamespace=me,window.lnCore.hashSortEncode=pe,window.lnCore.hashSortDecode=Ce,window.lnCore.hashFilterEncode=ye,window.lnCore.hashFilterDecode=ve);function Ae(e){if(e==null||e==="")return null;if(e instanceof Date)return isNaN(e.getTime())?null:e;const t=Number(e);if(!isNaN(t)&&t>0){const n=t<1e11?t*1e3:t,o=new Date(n);return isNaN(o.getTime())?null:o}if(typeof e=="string"){const n=e.trim();if(!n)return null;const o=/^(\d{4})-(\d{2})-(\d{2})$/.exec(n);if(o){const i=+o[1],l=+o[2],a=+o[3],s=new Date(i,l-1,a);return s.getFullYear()!==i||s.getMonth()!==l-1||s.getDate()!==a?null:s}const r=new Date(n);return isNaN(r.getTime())?null:r}return null}function _e(e,t=Date.now()){if(!e)return{value:0,unit:"second",isOlderThanMonth:!1};const n=typeof t=="number"?t:t.getTime(),o=e.getTime(),r=Math.floor((o-n)/1e3),i=Math.abs(r);return i<10?{value:0,unit:"second",isOlderThanMonth:!1}:i<60?{value:r,unit:"second",isOlderThanMonth:!1}:i<3600?{value:Math.round(r/60),unit:"minute",isOlderThanMonth:!1}:i<86400?{value:Math.round(r/3600),unit:"hour",isOlderThanMonth:!1}:i<604800?{value:Math.round(r/86400),unit:"day",isOlderThanMonth:!1}:i<2592e3?{value:Math.round(r/604800),unit:"week",isOlderThanMonth:!1}:{value:Math.round(r/2592e3),unit:"month",isOlderThanMonth:!0}}function O(e,t,n=new Date){switch(e){case"full":return{dateStyle:"long",timeStyle:"short"};case"date":return{dateStyle:"medium"};case"time":return{timeStyle:"short"};case"short":default:{const o={month:"short",day:"numeric"};return t&&t.getFullYear()!==n.getFullYear()&&(o.year="numeric"),o}}}(function(){const e="data-ln-time",t="lnTime";if(window[t]!==void 0)return;const n={"data-ln-time":{type:"enum",values:["relative","short","medium","long","iso"],fallback:"relative",effect:v,description:"Time format style preset or activator"},"data-ln-time-locale":{type:"string",effect:v,description:"BCP 47 language tag override for time formatting"}},o={},r={};function i(u){return u.getAttribute("data-ln-time-locale")||Z(u)}function l(u,d){const f=(u||"")+"|"+JSON.stringify(d);return o[f]||(o[f]=new Intl.DateTimeFormat(u,d)),o[f]}function a(u){const d=u||"";return r[d]||(r[d]=new Intl.RelativeTimeFormat(u,{numeric:"auto",style:"narrow"})),r[d]}const s=new Set;let c=null;function h(){c||(c=setInterval(b,6e4))}function w(){c&&(clearInterval(c),c=null)}function b(){for(const u of s){if(!document.body.contains(u.dom)){s.delete(u);continue}y(u)}s.size===0&&w()}function T(u,d){const f=x(d),m=(d||"").toLowerCase().split("-")[0],g=l(d,O("full",u)),C=g.resolvedOptions().locale.toLowerCase().split("-")[0];if(f&&C!==m&&f.monthsLong){const I=f.monthsLong[u.getMonth()],F=u.getDate(),R=u.getFullYear(),N=String(u.getHours()).padStart(2,"0"),Se=String(u.getMinutes()).padStart(2,"0");return`${F} ${I} ${R}, ${N}:${Se}`}return g.format(u)}function L(u,d){const f=O("short",u),m=x(d),g=(d||"").toLowerCase().split("-")[0],C=l(d,f),I=C.resolvedOptions().locale.toLowerCase().split("-")[0];if(m&&I!==g&&m.monthsShort){const F=m.monthsShort[u.getMonth()],R=u.getDate(),N=f.year?" "+u.getFullYear():"";return`${R} ${F}${N}`}return C.format(u)}function A(u,d){return l(d,O("date",u)).format(u)}function S(u,d){return l(d,O("time",u)).format(u)}function z(u,d){const f=_e(u);return f.isOlderThanMonth?L(u,d):a(d).format(f.value,f.unit)}function y(u){const d=u.dom.getAttribute("datetime");if(!d)return;const f=Ae(d);if(!f)return;const m=u.dom.getAttribute(e)||"short",g=i(u.dom);let C;switch(m){case"relative":C=z(f,g);break;case"full":C=T(f,g);break;case"date":C=A(f,g);break;case"time":C=S(f,g);break;default:C=L(f,g);break}u.dom.textContent=C,m!=="full"&&(u.dom.title=T(f,g))}function _(u){this.dom=u;const d=this;return this._onLocaleChange=function(){y(d)},W(),document.addEventListener("ln-core:locale-change",this._onLocaleChange),y(this),u.getAttribute(e)==="relative"&&(s.add(this),h()),this}_.prototype.render=function(){y(this)},_.prototype.destroy=function(){this._onLocaleChange&&document.removeEventListener("ln-core:locale-change",this._onLocaleChange),s.delete(this),s.size===0&&w(),delete this.dom[t]};function v(u){const d=u[t];if(!d)return;u.getAttribute(e)==="relative"?(s.add(d),h()):(s.delete(d),s.size===0&&w()),y(d)}function p(u){u.nodeType===1&&u.hasAttribute&&u.hasAttribute(e)&&u[t]&&y(u[t])}we(e,t,_,"ln-time",{attributes:n,extraAttributes:["datetime","lang"],onAttributeChange:v,onInit:p})})()})();
1
+ (function(){"use strict";function q(){return typeof window>"u"?!1:window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink?!0:typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null:!1}function L(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 o=null;for(let r=1;r<t.length;r++)if(t[r]&&t[r].nodeType===1){o=t[r];break}if(!L(o))return}e.apply(console,t)}}function J(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))}function S(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){S(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}const B={};function G(e,t){B[e]=t}function X(e){return B[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=G,window.lnCore.getDataMapper=X);function Z(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 W(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,S(function(){new MutationObserver(function(){J(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const j={};function ee(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];j[n]=t}function D(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return j[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=ee,window.lnCore.getLocaleFallback=D,window.lnCore.ensureLocaleObserver=W);const M={};function te(e,t){M[e]||(M[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=M[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function U(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let l=0;l<n.length;l++){const a=n[l],s=a.getAttribute("data-ln-field");t[s]!=null&&(a.textContent=t[s])}const o=e.querySelectorAll("[data-ln-attr]");for(let l=0;l<o.length;l++){const a=o[l],s=a.getAttribute("data-ln-attr").split(",");for(let c=0;c<s.length;c++){const h=s[c].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),b=h[1].trim();t[b]!=null&&a.setAttribute(w,t[b])}}const r=e.querySelectorAll("[data-ln-show]");for(let l=0;l<r.length;l++){const a=r[l],s=a.getAttribute("data-ln-show");s in t&&a.classList.toggle("hidden",!t[s])}const i=e.querySelectorAll("[data-ln-class]");for(let l=0;l<i.length;l++){const a=i[l],s=a.getAttribute("data-ln-class").split(",");for(let c=0;c<s.length;c++){const h=s[c].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),b=h[1].trim();b in t&&a.classList.toggle(w,!!t[b])}}return e}function ne(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 o=0;o<n.length;o++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[o],t??null),n[o].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)U(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 V(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const i=n.currentNode;i.textContent.indexOf("{{")!==-1&&(i.textContent=i.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(l,a){return t[a]!==void 0?t[a]:""}))}const o=function(i,l){return t[l]!==void 0?t[l]:""},r=Array.from(e.querySelectorAll("*"));e.nodeType===1&&r.push(e);for(let i=0;i<r.length;i++){const l=r[i],a=l.attributes;for(let s=0;s<a.length;s++){const c=a[s];c.value.indexOf("{{")!==-1&&l.setAttribute(c.name,c.value.replace(/\{\{\s*(\w+)\s*\}\}/g,o))}}return e}function oe(e,t,n,o,r,i){const l={};for(let s=0;s<e.children.length;s++){const c=e.children[s],h=c.getAttribute("data-ln-render-key");h&&(l[h]=c)}const a=document.createDocumentFragment();for(let s=0;s<t.length;s++){const c=t[s],h=String(o(c));let w=l[h];if(w)r(w,c,s);else{const b=te(n,i);if(!b||(V(b,c),w=b.firstElementChild,!w))continue;w.setAttribute("data-ln-render-key",h),r(w,c,s)}a.appendChild(w)}e.textContent="",e.appendChild(a)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=V,window.lnCore.fill=U,window.lnCore.lnFill=ne,window.lnCore.renderList=oe);function H(e,t,n,o,r){if(!e||t===null)return!0;const i=o||"ln-component",l=e.type;if(l==="trigger"||l==="marker"||l==="string"||l==="list"||!l||t===""&&e.fallback!==void 0)return!0;const a=s=>{r?console.warn(s,r):console.warn(s)};if(l==="boolean"){const s=t.trim().toLowerCase();return s!==""&&s!=="true"&&s!=="false"&&s!=="1"&&s!=="0"?(a(`[${i}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(l==="enum"){const s=e.values||[];return s.includes(t)?!0:(a(`[${i}] Invalid value "${t}" for attribute "${n}". Allowed: ${s.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(l==="integer"){if(!/^-?\d+$/.test(t))return a(`[${i}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const s=parseInt(t,10);return e.min!==void 0&&s<e.min?(a(`[${i}] Value ${s} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&s>e.max?(a(`[${i}] Value ${s} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(l==="float")return isNaN(Number(t))?(a(`[${i}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(l==="json")try{return JSON.parse(t),!0}catch(s){return a(`[${i}] Invalid JSON for attribute "${n}": ${s.message}. Fallback: ${e.fallback}.`),!1}return!0}function re(e){const t={};for(const n in e){const o=e[n];o&&o.effect&&(t[n]=o.effect)}return Object.keys(t).length?t:null}function ie(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}function $(e,t,n,o){if(e.nodeType!==1)return;const i=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",l=Array.from(e.querySelectorAll(i));e.matches&&e.matches(i)&&l.push(e);for(const a of l)if(!a[n]){window.lnCore._persistSink&&a.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(a,t);try{a[n]=new o(a)}catch(s){console.error("["+n+"] init failed",a,s)}}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function le(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function se(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 Q(){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 ue(e){const t=Q(),n=e.observed||[];for(let o=0;o<n.length;o++){const r=n[o];t.byAttr.has(r)||t.byAttr.set(r,[]),t.byAttr.get(r).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const o in e.attributes){t.byDeclaredAttr.has(o)||t.byDeclaredAttr.set(o,[]);const r=t.byDeclaredAttr.get(o);r.some(i=>i.componentTag===e.componentTag)||r.push({spec:e.attributes[o],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const o=ie(e);if(o===null)t.reactiveWildcard.push(e);else for(const r of o)t.byReactive.has(r)||t.byReactive.set(r,[]),t.byReactive.get(r).push(e)}e.persist&&t.persist.push(e)}function Y(e,t,n,o){for(let r=0;r<e.length;r++){const i=e[r];if(!t[i.attribute])continue;const l=i.effects&&i.effects[n];l?l(t,n,o):i.onAttrChange&&(!i.declared||i.declared.has(n))&&i.onAttrChange(t,n,o)}}function ae(e){const t=e.target,n=e.attributeName;if(e.oldValue===t.getAttribute(n))return;const o=Q(),r=o.byAttr.get(n);if(q()&&o.byDeclaredAttr&&o.byDeclaredAttr.has(n)&&L(t)){const i=o.byDeclaredAttr.get(n),l=t.getAttribute(n);for(let a=0;a<i.length;a++)H(i[a].spec,l,n,i[a].componentTag,t)}if(window.lnCore._debugSink&&(n.indexOf("data-ln-")===0||r)&&window.lnCore._debugSink("attr",n,t,{oldValue:e.oldValue,newValue:t.getAttribute(n)}),n.indexOf("data-ln-")===0){const i=o.byReactive.get(n);i&&Y(i,t,n,e.oldValue),o.reactiveWildcard.length&&Y(o.reactiveWildcard,t,n,e.oldValue)}if(r)for(let i=0;i<r.length;i++){const l=r[i];if(l.handler){l.handler(t,n,e.oldValue);continue}l.onAttributeChange&&t[l.attribute]?l.onAttributeChange(t,n):($(t,l.selector,l.attribute,l.ComponentFn),l.onInit&&l.onInit(t))}}function ce(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,S(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{ae(t[n])}catch(o){console.error("[ln-core] mutation handler failed",t[n].target,o)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function K(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function de(e){const t=K();if(t.length){if(e.target)for(let n=0;n<t.length;n++){const o=t[n];if(o.onSubtreeChange){const r=o.query,i=e.target.nodeType===1?e.target.matches(r)?e.target:e.target.closest(r):e.target.parentElement?e.target.parentElement.closest(r):null;i&&o.onSubtreeChange(i,e)}}for(let n=0;n<e.addedNodes.length;n++){const o=e.addedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r];$(o,i.selector,i.attribute,i.ComponentFn),i.onInit&&i.onInit(o)}}for(let n=0;n<e.removedNodes.length;n++){const o=e.removedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r],l=i.query,a=Array.from(o.querySelectorAll(l));o.matches&&o.matches(l)&&a.push(o);for(let s=0;s<a.length;s++){const c=a[s];if(!document.contains(c)){const h=c[i.attribute];if(h&&typeof h.destroy=="function")try{h.destroy()}catch(w){console.error("["+i.attribute+"] destroy failed",c,w)}delete c[i.attribute]}}}}}}function fe(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,S(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++){const o=t[n];if(o.type==="childList")try{de(o)}catch(r){console.error("[ln-core] lifecycle handler failed",o.target,r)}}}).observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function we(e,t,n,o,r={}){const i=r.extraAttributes||[],l=r.onAttributeChange||null,a=r.onSubtreeChange||null,s=r.onInit||null,c=r.onAttrChange||null,h=r.effects||null,w=r.attributes||null,b=w?re(w):h,O=w?new Set(Object.keys(w)):null,T=r.persist||null;function A(v){const p=v||document.body;if($(p,e,t,n),w&&q())for(const u in w){const d=w[u],f=Array.from(p.querySelectorAll("["+u+"]"));p.matches&&p.matches("["+u+"]")&&f.push(p);for(let m=0;m<f.length;m++){const g=f[m];L(g)&&H(d,g.getAttribute(u),u,o,g)}}s&&s(p)}const x=[];if(e.indexOf("[")!==-1){const v=/\[([\w-]+)/g;let p;for(;(p=v.exec(e))!==null;)x.push(p[1])}else x.push(e);ue({selector:e,attribute:t,componentTag:o,attributes:w,ComponentFn:n,onInit:s,observed:x.concat(i),onAttributeChange:l,onAttrChange:c,effects:b,declared:O,persist:T}),ce();const y=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]";K().push({selector:e,attribute:t,ComponentFn:n,onInit:s,onSubtreeChange:a,query:y}),fe(),window[t]=A;function _(){le()>0?se(function(){A(document.body)}):A(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",_):_(),A}function P(e){return(e||"").replace(/^#/,"")}function I(e){const t=e===void 0?location.hash:e,n={},o=P(t);if(!o)return n;const r=o.split("&");for(let i=0;i<r.length;i++){const l=r[i];if(!l)continue;const a=l.indexOf(":"),s=a>-1?l.slice(0,a):l,c=a>-1?l.slice(a+1):"";if(s)try{n[s]=decodeURIComponent(c)}catch{n[s]=c}}return n}function he(e){if(!e)return null;const t=I();return e in t?t[e]:null}function ge(e,t){if(!e)return;const n=I();t==null?delete n[e]:n[e]=String(t);const r=Object.keys(n).map(function(i){const l=n[i];return l===""?i:i+":"+encodeURIComponent(l)}).join("&");P(location.hash)!==r&&(location.hash=r)}function be(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function me(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 o=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return o?t?o+"-"+t:o:t||null}function pe(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function Ce(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 ye(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function ve(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),o=e.slice(t+1),r=o?o.split(",").map(function(i){try{return decodeURIComponent(i)}catch{return i}}).filter(Boolean):[];return{key:n,values:r}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=I,window.lnCore.hashGet=he,window.lnCore.hashSet=ge,window.lnCore.hashLinkClick=be,window.lnCore.resolveHashNamespace=me,window.lnCore.hashSortEncode=pe,window.lnCore.hashSortDecode=Ce,window.lnCore.hashFilterEncode=ye,window.lnCore.hashFilterDecode=ve);function Ae(){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=Ae);function _e(e){if(e==null||e==="")return null;if(e instanceof Date)return isNaN(e.getTime())?null:e;const t=Number(e);if(!isNaN(t)&&t>0){const n=t<1e11?t*1e3:t,o=new Date(n);return isNaN(o.getTime())?null:o}if(typeof e=="string"){const n=e.trim();if(!n)return null;const o=/^(\d{4})-(\d{2})-(\d{2})$/.exec(n);if(o){const i=+o[1],l=+o[2],a=+o[3],s=new Date(i,l-1,a);return s.getFullYear()!==i||s.getMonth()!==l-1||s.getDate()!==a?null:s}const r=new Date(n);return isNaN(r.getTime())?null:r}return null}function xe(e,t=Date.now()){if(!e)return{value:0,unit:"second",isOlderThanMonth:!1};const n=typeof t=="number"?t:t.getTime(),o=e.getTime(),r=Math.floor((o-n)/1e3),i=Math.abs(r);return i<10?{value:0,unit:"second",isOlderThanMonth:!1}:i<60?{value:r,unit:"second",isOlderThanMonth:!1}:i<3600?{value:Math.round(r/60),unit:"minute",isOlderThanMonth:!1}:i<86400?{value:Math.round(r/3600),unit:"hour",isOlderThanMonth:!1}:i<604800?{value:Math.round(r/86400),unit:"day",isOlderThanMonth:!1}:i<2592e3?{value:Math.round(r/604800),unit:"week",isOlderThanMonth:!1}:{value:Math.round(r/2592e3),unit:"month",isOlderThanMonth:!0}}function k(e,t,n=new Date){switch(e){case"full":return{dateStyle:"long",timeStyle:"short"};case"date":return{dateStyle:"medium"};case"time":return{timeStyle:"short"};case"short":default:{const o={month:"short",day:"numeric"};return t&&t.getFullYear()!==n.getFullYear()&&(o.year="numeric"),o}}}(function(){const e="data-ln-time",t="lnTime";if(window[t]!==void 0)return;const n={"data-ln-time":{type:"enum",values:["relative","short","medium","long","iso"],fallback:"relative",effect:v,description:"Time format style preset or activator"},"data-ln-time-locale":{type:"string",effect:v,description:"BCP 47 language tag override for time formatting"}},o={},r={};function i(u){return u.getAttribute("data-ln-time-locale")||Z(u)}function l(u,d){const f=(u||"")+"|"+JSON.stringify(d);return o[f]||(o[f]=new Intl.DateTimeFormat(u,d)),o[f]}function a(u){const d=u||"";return r[d]||(r[d]=new Intl.RelativeTimeFormat(u,{numeric:"auto",style:"narrow"})),r[d]}const s=new Set;let c=null;function h(){c||(c=setInterval(b,6e4))}function w(){c&&(clearInterval(c),c=null)}function b(){for(const u of s){if(!document.body.contains(u.dom)){s.delete(u);continue}y(u)}s.size===0&&w()}function O(u,d){const f=D(d),m=(d||"").toLowerCase().split("-")[0],g=l(d,k("full",u)),C=g.resolvedOptions().locale.toLowerCase().split("-")[0];if(f&&C!==m&&f.monthsLong){const E=f.monthsLong[u.getMonth()],F=u.getDate(),R=u.getFullYear(),N=String(u.getHours()).padStart(2,"0"),Se=String(u.getMinutes()).padStart(2,"0");return`${F} ${E} ${R}, ${N}:${Se}`}return g.format(u)}function T(u,d){const f=k("short",u),m=D(d),g=(d||"").toLowerCase().split("-")[0],C=l(d,f),E=C.resolvedOptions().locale.toLowerCase().split("-")[0];if(m&&E!==g&&m.monthsShort){const F=m.monthsShort[u.getMonth()],R=u.getDate(),N=f.year?" "+u.getFullYear():"";return`${R} ${F}${N}`}return C.format(u)}function A(u,d){return l(d,k("date",u)).format(u)}function x(u,d){return l(d,k("time",u)).format(u)}function z(u,d){const f=xe(u);return f.isOlderThanMonth?T(u,d):a(d).format(f.value,f.unit)}function y(u){const d=u.dom.getAttribute("datetime");if(!d)return;const f=_e(d);if(!f)return;const m=u.dom.getAttribute(e)||"short",g=i(u.dom);let C;switch(m){case"relative":C=z(f,g);break;case"full":C=O(f,g);break;case"date":C=A(f,g);break;case"time":C=x(f,g);break;default:C=T(f,g);break}u.dom.textContent=C,m!=="full"&&(u.dom.title=O(f,g))}function _(u){this.dom=u;const d=this;return this._onLocaleChange=function(){y(d)},W(),document.addEventListener("ln-core:locale-change",this._onLocaleChange),y(this),u.getAttribute(e)==="relative"&&(s.add(this),h()),this}_.prototype.render=function(){y(this)},_.prototype.destroy=function(){this._onLocaleChange&&document.removeEventListener("ln-core:locale-change",this._onLocaleChange),s.delete(this),s.size===0&&w(),delete this.dom[t]};function v(u){const d=u[t];if(!d)return;u.getAttribute(e)==="relative"?(s.add(d),h()):(s.delete(d),s.size===0&&w()),y(d)}function p(u){u.nodeType===1&&u.hasAttribute&&u.hasAttribute(e)&&u[t]&&y(u[t])}we(e,t,_,"ln-time",{attributes:n,extraAttributes:["datetime","lang"],onAttributeChange:v,onInit:p})})()})();
@@ -1,38 +1,38 @@
1
- {
2
- "$comment": "This file is partly generated. The $comment, component, generator, and each attribute's direction, sources, type, values, fallback, and description keys are owned by the generator and synchronized from JS source code. All other keys are preserved and safe to hand-author. Regenerate with `npm run sync:ln-schemas`.",
3
- "component": "ln-time",
4
- "generator": "scripts/sync-ln-schemas.mjs",
5
- "attributes": {
6
- "data-ln-debug": {
7
- "direction": null,
8
- "sources": [
9
- "ln-time-dev.scss"
10
- ]
11
- },
12
- "data-ln-time": {
13
- "direction": "author",
14
- "sources": [
15
- "ln-time-dev.scss",
16
- "src/ln-time.js"
17
- ],
18
- "type": "enum",
19
- "values": [
20
- "relative",
21
- "short",
22
- "medium",
23
- "long",
24
- "iso"
25
- ],
26
- "fallback": "relative",
27
- "description": "Time format style preset or activator"
28
- },
29
- "data-ln-time-locale": {
30
- "direction": "author",
31
- "sources": [
32
- "src/ln-time.js"
33
- ],
34
- "type": "string",
35
- "description": "BCP 47 language tag override for time formatting"
36
- }
37
- }
38
- }
1
+ {
2
+ "$comment": "This file is partly generated. The $comment, component, generator, and each attribute's direction, sources, type, values, fallback, and description keys are owned by the generator and synchronized from JS source code. All other keys are preserved and safe to hand-author. Regenerate with `npm run sync:ln-schemas`.",
3
+ "component": "ln-time",
4
+ "generator": "scripts/sync-ln-schemas.mjs",
5
+ "attributes": {
6
+ "data-ln-debug": {
7
+ "direction": null,
8
+ "sources": [
9
+ "ln-time-dev.scss"
10
+ ]
11
+ },
12
+ "data-ln-time": {
13
+ "direction": "author",
14
+ "sources": [
15
+ "ln-time-dev.scss",
16
+ "src/ln-time.js"
17
+ ],
18
+ "type": "enum",
19
+ "values": [
20
+ "relative",
21
+ "short",
22
+ "medium",
23
+ "long",
24
+ "iso"
25
+ ],
26
+ "fallback": "relative",
27
+ "description": "Time format style preset or activator"
28
+ },
29
+ "data-ln-time-locale": {
30
+ "direction": "author",
31
+ "sources": [
32
+ "src/ln-time.js"
33
+ ],
34
+ "type": "string",
35
+ "description": "BCP 47 language tag override for time formatting"
36
+ }
37
+ }
38
+ }
@@ -1 +1 @@
1
- (function(){"use strict";function $(){return typeof window>"u"?!1:window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink?!0:typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null:!1}function _(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 o=null;for(let r=1;r<t.length;r++)if(t[r]&&t[r].nodeType===1){o=t[r];break}if(!_(o))return}e.apply(console,t)}}function U(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))}function A(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){A(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}const N={};function Q(e,t){N[e]=t}function J(e){return N[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=Q,window.lnCore.getDataMapper=J);function K(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,A(function(){new MutationObserver(function(){U(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const M={};function G(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];M[n]=t}function z(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return M[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=G,window.lnCore.getLocaleFallback=z,window.lnCore.ensureLocaleObserver=K);const v={};function B(e,t){v[e]||(v[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=v[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function X(e,t,n){if(e){const o=e.querySelector('[data-ln-template="'+t+'"]');if(o)return o.content.cloneNode(!0)}return B(t,n)}function S(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let l=0;l<n.length;l++){const a=n[l],c=a.getAttribute("data-ln-field");t[c]!=null&&(a.textContent=t[c])}const o=e.querySelectorAll("[data-ln-attr]");for(let l=0;l<o.length;l++){const a=o[l],c=a.getAttribute("data-ln-attr").split(",");for(let f=0;f<c.length;f++){const h=c[f].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),m=h[1].trim();t[m]!=null&&a.setAttribute(w,t[m])}}const r=e.querySelectorAll("[data-ln-show]");for(let l=0;l<r.length;l++){const a=r[l],c=a.getAttribute("data-ln-show");c in t&&a.classList.toggle("hidden",!t[c])}const i=e.querySelectorAll("[data-ln-class]");for(let l=0;l<i.length;l++){const a=i[l],c=a.getAttribute("data-ln-class").split(",");for(let f=0;f<c.length;f++){const h=c[f].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),m=h[1].trim();m in t&&a.classList.toggle(w,!!t[m])}}return e}function Y(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 o=0;o<n.length;o++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[o],t??null),n[o].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)S(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 F(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const i=n.currentNode;i.textContent.indexOf("{{")!==-1&&(i.textContent=i.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(l,a){return t[a]!==void 0?t[a]:""}))}const o=function(i,l){return t[l]!==void 0?t[l]:""},r=Array.from(e.querySelectorAll("*"));e.nodeType===1&&r.push(e);for(let i=0;i<r.length;i++){const l=r[i],a=l.attributes;for(let c=0;c<a.length;c++){const f=a[c];f.value.indexOf("{{")!==-1&&l.setAttribute(f.name,f.value.replace(/\{\{\s*(\w+)\s*\}\}/g,o))}}return e}function Z(e,t,n,o,r,i){const l={};for(let c=0;c<e.children.length;c++){const f=e.children[c],h=f.getAttribute("data-ln-render-key");h&&(l[h]=f)}const a=document.createDocumentFragment();for(let c=0;c<t.length;c++){const f=t[c],h=String(o(f));let w=l[h];if(w)r(w,f,c);else{const m=B(n,i);if(!m||(F(m,f),w=m.firstElementChild,!w))continue;w.setAttribute("data-ln-render-key",h),r(w,f,c)}a.appendChild(w)}e.textContent="",e.appendChild(a)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=F,window.lnCore.fill=S,window.lnCore.lnFill=Y,window.lnCore.renderList=Z);function R(e,t,n){const o=e.getAttribute(t);return o===null?n:o}function k(e,t,n){const o=parseInt(e.getAttribute(t),10);return isNaN(o)?n:o}function ee(e,t,n=!1){const o=e.getAttribute(t);if(o===null)return!!n;const r=o.trim().toLowerCase();return!(r==="false"||r==="0")}function te(e,t){return(e.getAttribute(t)||"").split(",").map(n=>n.trim()).filter(Boolean)}const E=new Map;function ne(e,t){const n=(e?e.join("|"):"")+"::"+t;if(E.has(n))return E.get(n);const o=new Set(e||[]),r=function(i,l){const a=i.getAttribute(l);return a!==null&&o.has(a)?a:t};return E.set(n,r),r}function oe(e,t,n){const o=parseFloat(e.getAttribute(t));return isNaN(o)?n:o}function re(e,t,n){const o=e.getAttribute(t);if(!o)return n;try{return JSON.parse(o)}catch{return n}}function j(e,t,n,o,r){if(!e||t===null)return!0;const i=o||"ln-component",l=e.type;if(l==="trigger"||l==="marker"||l==="string"||l==="list"||!l||t===""&&e.fallback!==void 0)return!0;const a=c=>{r?console.warn(c,r):console.warn(c)};if(l==="boolean"){const c=t.trim().toLowerCase();return c!==""&&c!=="true"&&c!=="false"&&c!=="1"&&c!=="0"?(a(`[${i}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(l==="enum"){const c=e.values||[];return c.includes(t)?!0:(a(`[${i}] Invalid value "${t}" for attribute "${n}". Allowed: ${c.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(l==="integer"){if(!/^-?\d+$/.test(t))return a(`[${i}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const c=parseInt(t,10);return e.min!==void 0&&c<e.min?(a(`[${i}] Value ${c} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&c>e.max?(a(`[${i}] Value ${c} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(l==="float")return isNaN(Number(t))?(a(`[${i}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(l==="json")try{return JSON.parse(t),!0}catch(c){return a(`[${i}] Invalid JSON for attribute "${n}": ${c.message}. Fallback: ${e.fallback}.`),!1}return!0}function ie(e,t,n){for(const o in n){const[r,i,l]=n[o];Object.defineProperty(e,o,{get:function(){return r(t,i,l)},enumerable:!0,configurable:!0})}return e}function le(e){const t={};for(const n in e){const o=e[n];if(!o||!o.prop)continue;let r=o.read;if(!r&&o.type)switch(o.type){case"enum":r=ne(o.values,o.fallback);break;case"integer":r=k;break;case"float":r=oe;break;case"boolean":r=ee;break;case"list":r=te;break;case"json":r=re;break;case"string":default:r=R;break}r||(r=R),t[o.prop]=[r,n,o.fallback]}return t}function se(e){const t={};for(const n in e){const o=e[n];o&&o.effect&&(t[n]=o.effect)}return Object.keys(t).length?t:null}function ae(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}function L(e,t,n,o){if(e.nodeType!==1)return;const i=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",l=Array.from(e.querySelectorAll(i));e.matches&&e.matches(i)&&l.push(e);for(const a of l)if(!a[n]){window.lnCore._persistSink&&a.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(a,t);try{a[n]=new o(a)}catch(c){console.error("["+n+"] init failed",a,c)}}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function ce(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function ue(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 W(){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 de(e){const t=W(),n=e.observed||[];for(let o=0;o<n.length;o++){const r=n[o];t.byAttr.has(r)||t.byAttr.set(r,[]),t.byAttr.get(r).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const o in e.attributes){t.byDeclaredAttr.has(o)||t.byDeclaredAttr.set(o,[]);const r=t.byDeclaredAttr.get(o);r.some(i=>i.componentTag===e.componentTag)||r.push({spec:e.attributes[o],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const o=ae(e);if(o===null)t.reactiveWildcard.push(e);else for(const r of o)t.byReactive.has(r)||t.byReactive.set(r,[]),t.byReactive.get(r).push(e)}e.persist&&t.persist.push(e)}function H(e,t,n,o){for(let r=0;r<e.length;r++){const i=e[r];if(!t[i.attribute])continue;const l=i.effects&&i.effects[n];l?l(t,n,o):i.onAttrChange&&(!i.declared||i.declared.has(n))&&i.onAttrChange(t,n,o)}}function fe(e){const t=e.target,n=e.attributeName;if(e.oldValue===t.getAttribute(n))return;const o=W(),r=o.byAttr.get(n);if($()&&o.byDeclaredAttr&&o.byDeclaredAttr.has(n)&&_(t)){const i=o.byDeclaredAttr.get(n),l=t.getAttribute(n);for(let a=0;a<i.length;a++)j(i[a].spec,l,n,i[a].componentTag,t)}if(window.lnCore._debugSink&&(n.indexOf("data-ln-")===0||r)&&window.lnCore._debugSink("attr",n,t,{oldValue:e.oldValue,newValue:t.getAttribute(n)}),n.indexOf("data-ln-")===0){const i=o.byReactive.get(n);i&&H(i,t,n,e.oldValue),o.reactiveWildcard.length&&H(o.reactiveWildcard,t,n,e.oldValue)}if(r)for(let i=0;i<r.length;i++){const l=r[i];if(l.handler){l.handler(t,n,e.oldValue);continue}l.onAttributeChange&&t[l.attribute]?l.onAttributeChange(t,n):(L(t,l.selector,l.attribute,l.ComponentFn),l.onInit&&l.onInit(t))}}function we(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,A(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{fe(t[n])}catch(o){console.error("[ln-core] mutation handler failed",t[n].target,o)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function V(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function he(e){const t=V();if(t.length){if(e.target)for(let n=0;n<t.length;n++){const o=t[n];if(o.onSubtreeChange){const r=o.query,i=e.target.nodeType===1?e.target.matches(r)?e.target:e.target.closest(r):e.target.parentElement?e.target.parentElement.closest(r):null;i&&o.onSubtreeChange(i,e)}}for(let n=0;n<e.addedNodes.length;n++){const o=e.addedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r];L(o,i.selector,i.attribute,i.ComponentFn),i.onInit&&i.onInit(o)}}for(let n=0;n<e.removedNodes.length;n++){const o=e.removedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r],l=i.query,a=Array.from(o.querySelectorAll(l));o.matches&&o.matches(l)&&a.push(o);for(let c=0;c<a.length;c++){const f=a[c];if(!document.contains(f)){const h=f[i.attribute];if(h&&typeof h.destroy=="function")try{h.destroy()}catch(w){console.error("["+i.attribute+"] destroy failed",f,w)}delete f[i.attribute]}}}}}}function pe(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,A(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++){const o=t[n];if(o.type==="childList")try{he(o)}catch(r){console.error("[ln-core] lifecycle handler failed",o.target,r)}}}).observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function be(e,t,n,o,r={}){const i=r.extraAttributes||[],l=r.onAttributeChange||null,a=r.onSubtreeChange||null,c=r.onInit||null,f=r.onAttrChange||null,h=r.effects||null,w=r.attributes||null,m=w?se(w):h,O=w?new Set(Object.keys(w)):null,x=r.persist||null;function C(b){const g=b||document.body;if(L(g,e,t,n),w&&$())for(const y in w){const ke=w[y],q=Array.from(g.querySelectorAll("["+y+"]"));g.matches&&g.matches("["+y+"]")&&q.push(g);for(let I=0;I<q.length;I++){const D=q[I];_(D)&&j(ke,D.getAttribute(y),y,o,D)}}c&&c(g)}const s=[];if(e.indexOf("[")!==-1){const b=/\[([\w-]+)/g;let g;for(;(g=b.exec(e))!==null;)s.push(g[1])}else s.push(e);de({selector:e,attribute:t,componentTag:o,attributes:w,ComponentFn:n,onInit:c,observed:s.concat(i),onAttributeChange:l,onAttrChange:f,effects:m,declared:O,persist:x}),we();const d=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]";V().push({selector:e,attribute:t,ComponentFn:n,onInit:c,onSubtreeChange:a,query:d}),pe(),window[t]=C;function p(){ce()>0?ue(function(){C(document.body)}):C(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",p):p(),C}function P(e){return(e||"").replace(/^#/,"")}function T(e){const t=e===void 0?location.hash:e,n={},o=P(t);if(!o)return n;const r=o.split("&");for(let i=0;i<r.length;i++){const l=r[i];if(!l)continue;const a=l.indexOf(":"),c=a>-1?l.slice(0,a):l,f=a>-1?l.slice(a+1):"";if(c)try{n[c]=decodeURIComponent(f)}catch{n[c]=f}}return n}function me(e){if(!e)return null;const t=T();return e in t?t[e]:null}function ge(e,t){if(!e)return;const n=T();t==null?delete n[e]:n[e]=String(t);const r=Object.keys(n).map(function(i){const l=n[i];return l===""?i:i+":"+encodeURIComponent(l)}).join("&");P(location.hash)!==r&&(location.hash=r)}function ye(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function Ce(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 o=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return o?t?o+"-"+t:o:t||null}function Ae(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function _e(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 ve(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function Se(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),o=e.slice(t+1),r=o?o.split(",").map(function(i){try{return decodeURIComponent(i)}catch{return i}}).filter(Boolean):[];return{key:n,values:r}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=T,window.lnCore.hashGet=me,window.lnCore.hashSet=ge,window.lnCore.hashLinkClick=ye,window.lnCore.resolveHashNamespace=Ce,window.lnCore.hashSortEncode=Ae,window.lnCore.hashSortDecode=_e,window.lnCore.hashFilterEncode=ve,window.lnCore.hashFilterDecode=Se),(function(){const e="data-ln-toast",t="lnToast",n="ln-toast-item";if(window[t]!==void 0)return;const o={"data-ln-toast":{type:"marker",description:"Initializes the toast notifications container"},"data-ln-toast-timeout":{prop:"timeoutDefault",type:"integer",read:k,fallback:6e3,min:500,description:"Default auto-dismiss timeout in ms"},"data-ln-toast-max":{prop:"max",type:"integer",read:k,fallback:5,min:1,description:"Maximum visible concurrent toast notifications"},"data-ln-toast-close":{type:"trigger",description:"Click dismiss trigger inside a toast item"},"data-ln-toast-item":{type:"marker",description:"Individual toast notification element"}},r=le(o);function i(s){if(!(!s||!(s instanceof HTMLElement))&&(s.hasAttribute("popover")||s.setAttribute("popover","manual"),typeof s.showPopover=="function")){if(s.matches(":popover-open"))try{s.hidePopover()}catch{}try{s.showPopover()}catch{}}}function l(s){if(!s||!(s instanceof HTMLElement))return;if(s.querySelectorAll("[data-ln-toast-item]").length===0&&typeof s.hidePopover=="function"&&s.matches(":popover-open"))try{s.hidePopover()}catch{}}function a(s){this.dom=s,ie(this,s,r);const u=Array.from(s.querySelectorAll("[data-ln-toast-item]"));for(;u.length>this.max;)s.removeChild(u.shift());for(const d of u)O(d,this);return u.length>0&&i(s),this}a.prototype.enqueue=function(s){if(!s)return;const u=c(s,this.dom);if(!u)return;const d=Number.isFinite(s.timeout)?s.timeout:this.timeoutDefault;h(this,u),d>0&&(u._timer=setTimeout(()=>w(u),d))},a.prototype.clear=function(){for(const s of Array.from(this.dom.querySelectorAll("[data-ln-toast-item]")))w(s)},a.prototype.destroy=function(){if(this.dom[t]){for(const s of Array.from(this.dom.querySelectorAll("[data-ln-toast-item]")))w(s);l(this.dom),delete this.dom[t]}};function c(s,u){const d=((s.type||"")+"").trim().toLowerCase(),p=X(u,n,"ln-toast");if(!p)return console.warn('[ln-toast] Template "'+n+'" not found'),null;S(p,{type:d,title:s.title,message:typeof s.message=="string"?s.message:void 0});const b=p.firstElementChild;if(!b)return null;b.hasAttribute("data-ln-toast-item")||b.setAttribute("data-ln-toast-item",""),b.classList.add("ln-enter");const g=b.querySelector(".body");g&&f(g,s);const y=b.querySelector("[data-ln-toast-close]");return y&&y.addEventListener("click",function(){w(b)}),b}function f(s,u){if(Array.isArray(u.message)){const d=document.createElement("ul");for(const p of u.message){const b=document.createElement("li");b.textContent=p,d.appendChild(b)}s.appendChild(d)}if(u.data&&u.data.errors){const d=document.createElement("ul");for(const p of Object.values(u.data.errors).flat()){const b=document.createElement("li");b.textContent=p,d.appendChild(b)}s.appendChild(d)}}function h(s,u){const d=Array.from(s.dom.querySelectorAll("[data-ln-toast-item]"));for(;d.length>=s.max&&d.length>0;)s.dom.removeChild(d.shift());s.dom.appendChild(u),i(s.dom),requestAnimationFrame(()=>u.classList.remove("ln-enter"))}function w(s){if(!s||!s.parentNode)return;const u=s.parentNode;clearTimeout(s._timer),s.classList.remove("ln-enter"),s.classList.add("ln-out"),setTimeout(()=>{s.parentNode&&(s.parentNode.removeChild(s),l(u))},200)}function m(s){let u=s&&s.container;return typeof u=="string"&&(u=document.querySelector(u)),u instanceof HTMLElement||(u=document.querySelector("["+e+"]")||document.getElementById("ln-toast-container")),u||null}function O(s,u){if(s._lnToastHydrated)return;s._lnToastHydrated=!0;const d=s.querySelector("[data-ln-toast-close]");d&&d.addEventListener("click",function(){w(s)});const p=+(s.getAttribute("data-ln-toast-timeout")??u.timeoutDefault);p>0&&(s._timer=setTimeout(function(){w(s)},p))}function x(s){const u=s.detail||{},d=m(u);if(!d){console.warn("[ln-toast] No toast container found");return}(d[t]||(d[t]=new a(d))).enqueue(u)}function C(s){const u=s&&s.detail||{};if(u.container){const d=m(u);d&&(d[t]||(d[t]=new a(d))).clear()}else{const d=document.querySelectorAll("["+e+"]");for(const p of Array.from(d))(p[t]||(p[t]=new a(p))).clear()}}A(function(){window.addEventListener("ln-toast:enqueue",x),window.addEventListener("ln-toast:clear",C),window.addEventListener("ln-modal:open",function(){const s=document.querySelectorAll("["+e+"], #ln-toast-container");for(const u of Array.from(s))u.querySelectorAll("[data-ln-toast-item]").length>0&&i(u)})},"ln-toast"),be(e,t,a,"ln-toast",{attributes:o})})()})();
1
+ (function(){"use strict";function $(){return typeof window>"u"?!1:window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink?!0:typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null:!1}function _(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 o=null;for(let r=1;r<t.length;r++)if(t[r]&&t[r].nodeType===1){o=t[r];break}if(!_(o))return}e.apply(console,t)}}function P(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))}function A(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){A(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}const N={};function Q(e,t){N[e]=t}function J(e){return N[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=Q,window.lnCore.getDataMapper=J);function K(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,A(function(){new MutationObserver(function(){P(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const M={};function G(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];M[n]=t}function z(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return M[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=G,window.lnCore.getLocaleFallback=z,window.lnCore.ensureLocaleObserver=K);const v={};function B(e,t){v[e]||(v[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=v[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function X(e,t,n){if(e){const o=e.querySelector('[data-ln-template="'+t+'"]');if(o)return o.content.cloneNode(!0)}return B(t,n)}function x(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let l=0;l<n.length;l++){const a=n[l],c=a.getAttribute("data-ln-field");t[c]!=null&&(a.textContent=t[c])}const o=e.querySelectorAll("[data-ln-attr]");for(let l=0;l<o.length;l++){const a=o[l],c=a.getAttribute("data-ln-attr").split(",");for(let f=0;f<c.length;f++){const h=c[f].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),m=h[1].trim();t[m]!=null&&a.setAttribute(w,t[m])}}const r=e.querySelectorAll("[data-ln-show]");for(let l=0;l<r.length;l++){const a=r[l],c=a.getAttribute("data-ln-show");c in t&&a.classList.toggle("hidden",!t[c])}const i=e.querySelectorAll("[data-ln-class]");for(let l=0;l<i.length;l++){const a=i[l],c=a.getAttribute("data-ln-class").split(",");for(let f=0;f<c.length;f++){const h=c[f].trim().split(":");if(h.length!==2)continue;const w=h[0].trim(),m=h[1].trim();m in t&&a.classList.toggle(w,!!t[m])}}return e}function Y(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 o=0;o<n.length;o++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[o],t??null),n[o].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)x(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 F(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const i=n.currentNode;i.textContent.indexOf("{{")!==-1&&(i.textContent=i.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(l,a){return t[a]!==void 0?t[a]:""}))}const o=function(i,l){return t[l]!==void 0?t[l]:""},r=Array.from(e.querySelectorAll("*"));e.nodeType===1&&r.push(e);for(let i=0;i<r.length;i++){const l=r[i],a=l.attributes;for(let c=0;c<a.length;c++){const f=a[c];f.value.indexOf("{{")!==-1&&l.setAttribute(f.name,f.value.replace(/\{\{\s*(\w+)\s*\}\}/g,o))}}return e}function Z(e,t,n,o,r,i){const l={};for(let c=0;c<e.children.length;c++){const f=e.children[c],h=f.getAttribute("data-ln-render-key");h&&(l[h]=f)}const a=document.createDocumentFragment();for(let c=0;c<t.length;c++){const f=t[c],h=String(o(f));let w=l[h];if(w)r(w,f,c);else{const m=B(n,i);if(!m||(F(m,f),w=m.firstElementChild,!w))continue;w.setAttribute("data-ln-render-key",h),r(w,f,c)}a.appendChild(w)}e.textContent="",e.appendChild(a)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=F,window.lnCore.fill=x,window.lnCore.lnFill=Y,window.lnCore.renderList=Z);function R(e,t,n){const o=e.getAttribute(t);return o===null?n:o}function S(e,t,n){const o=parseInt(e.getAttribute(t),10);return isNaN(o)?n:o}function ee(e,t,n=!1){const o=e.getAttribute(t);if(o===null)return!!n;const r=o.trim().toLowerCase();return!(r==="false"||r==="0")}function te(e,t){return(e.getAttribute(t)||"").split(",").map(n=>n.trim()).filter(Boolean)}const k=new Map;function ne(e,t){const n=(e?e.join("|"):"")+"::"+t;if(k.has(n))return k.get(n);const o=new Set(e||[]),r=function(i,l){const a=i.getAttribute(l);return a!==null&&o.has(a)?a:t};return k.set(n,r),r}function oe(e,t,n){const o=parseFloat(e.getAttribute(t));return isNaN(o)?n:o}function re(e,t,n){const o=e.getAttribute(t);if(!o)return n;try{return JSON.parse(o)}catch{return n}}function j(e,t,n,o,r){if(!e||t===null)return!0;const i=o||"ln-component",l=e.type;if(l==="trigger"||l==="marker"||l==="string"||l==="list"||!l||t===""&&e.fallback!==void 0)return!0;const a=c=>{r?console.warn(c,r):console.warn(c)};if(l==="boolean"){const c=t.trim().toLowerCase();return c!==""&&c!=="true"&&c!=="false"&&c!=="1"&&c!=="0"?(a(`[${i}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(l==="enum"){const c=e.values||[];return c.includes(t)?!0:(a(`[${i}] Invalid value "${t}" for attribute "${n}". Allowed: ${c.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(l==="integer"){if(!/^-?\d+$/.test(t))return a(`[${i}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const c=parseInt(t,10);return e.min!==void 0&&c<e.min?(a(`[${i}] Value ${c} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&c>e.max?(a(`[${i}] Value ${c} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(l==="float")return isNaN(Number(t))?(a(`[${i}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(l==="json")try{return JSON.parse(t),!0}catch(c){return a(`[${i}] Invalid JSON for attribute "${n}": ${c.message}. Fallback: ${e.fallback}.`),!1}return!0}function ie(e,t,n){for(const o in n){const[r,i,l]=n[o];Object.defineProperty(e,o,{get:function(){return r(t,i,l)},enumerable:!0,configurable:!0})}return e}function le(e){const t={};for(const n in e){const o=e[n];if(!o||!o.prop)continue;let r=o.read;if(!r&&o.type)switch(o.type){case"enum":r=ne(o.values,o.fallback);break;case"integer":r=S;break;case"float":r=oe;break;case"boolean":r=ee;break;case"list":r=te;break;case"json":r=re;break;case"string":default:r=R;break}r||(r=R),t[o.prop]=[r,n,o.fallback]}return t}function se(e){const t={};for(const n in e){const o=e[n];o&&o.effect&&(t[n]=o.effect)}return Object.keys(t).length?t:null}function ae(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}function E(e,t,n,o){if(e.nodeType!==1)return;const i=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",l=Array.from(e.querySelectorAll(i));e.matches&&e.matches(i)&&l.push(e);for(const a of l)if(!a[n]){window.lnCore._persistSink&&a.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(a,t);try{a[n]=new o(a)}catch(c){console.error("["+n+"] init failed",a,c)}}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function ce(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function ue(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 W(){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 de(e){const t=W(),n=e.observed||[];for(let o=0;o<n.length;o++){const r=n[o];t.byAttr.has(r)||t.byAttr.set(r,[]),t.byAttr.get(r).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const o in e.attributes){t.byDeclaredAttr.has(o)||t.byDeclaredAttr.set(o,[]);const r=t.byDeclaredAttr.get(o);r.some(i=>i.componentTag===e.componentTag)||r.push({spec:e.attributes[o],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const o=ae(e);if(o===null)t.reactiveWildcard.push(e);else for(const r of o)t.byReactive.has(r)||t.byReactive.set(r,[]),t.byReactive.get(r).push(e)}e.persist&&t.persist.push(e)}function H(e,t,n,o){for(let r=0;r<e.length;r++){const i=e[r];if(!t[i.attribute])continue;const l=i.effects&&i.effects[n];l?l(t,n,o):i.onAttrChange&&(!i.declared||i.declared.has(n))&&i.onAttrChange(t,n,o)}}function fe(e){const t=e.target,n=e.attributeName;if(e.oldValue===t.getAttribute(n))return;const o=W(),r=o.byAttr.get(n);if($()&&o.byDeclaredAttr&&o.byDeclaredAttr.has(n)&&_(t)){const i=o.byDeclaredAttr.get(n),l=t.getAttribute(n);for(let a=0;a<i.length;a++)j(i[a].spec,l,n,i[a].componentTag,t)}if(window.lnCore._debugSink&&(n.indexOf("data-ln-")===0||r)&&window.lnCore._debugSink("attr",n,t,{oldValue:e.oldValue,newValue:t.getAttribute(n)}),n.indexOf("data-ln-")===0){const i=o.byReactive.get(n);i&&H(i,t,n,e.oldValue),o.reactiveWildcard.length&&H(o.reactiveWildcard,t,n,e.oldValue)}if(r)for(let i=0;i<r.length;i++){const l=r[i];if(l.handler){l.handler(t,n,e.oldValue);continue}l.onAttributeChange&&t[l.attribute]?l.onAttributeChange(t,n):(E(t,l.selector,l.attribute,l.ComponentFn),l.onInit&&l.onInit(t))}}function we(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,A(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{fe(t[n])}catch(o){console.error("[ln-core] mutation handler failed",t[n].target,o)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function V(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function he(e){const t=V();if(t.length){if(e.target)for(let n=0;n<t.length;n++){const o=t[n];if(o.onSubtreeChange){const r=o.query,i=e.target.nodeType===1?e.target.matches(r)?e.target:e.target.closest(r):e.target.parentElement?e.target.parentElement.closest(r):null;i&&o.onSubtreeChange(i,e)}}for(let n=0;n<e.addedNodes.length;n++){const o=e.addedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r];E(o,i.selector,i.attribute,i.ComponentFn),i.onInit&&i.onInit(o)}}for(let n=0;n<e.removedNodes.length;n++){const o=e.removedNodes[n];if(o.nodeType===1)for(let r=0;r<t.length;r++){const i=t[r],l=i.query,a=Array.from(o.querySelectorAll(l));o.matches&&o.matches(l)&&a.push(o);for(let c=0;c<a.length;c++){const f=a[c];if(!document.contains(f)){const h=f[i.attribute];if(h&&typeof h.destroy=="function")try{h.destroy()}catch(w){console.error("["+i.attribute+"] destroy failed",f,w)}delete f[i.attribute]}}}}}}function pe(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,A(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++){const o=t[n];if(o.type==="childList")try{he(o)}catch(r){console.error("[ln-core] lifecycle handler failed",o.target,r)}}}).observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function be(e,t,n,o,r={}){const i=r.extraAttributes||[],l=r.onAttributeChange||null,a=r.onSubtreeChange||null,c=r.onInit||null,f=r.onAttrChange||null,h=r.effects||null,w=r.attributes||null,m=w?se(w):h,T=w?new Set(Object.keys(w)):null,O=r.persist||null;function C(b){const g=b||document.body;if(E(g,e,t,n),w&&$())for(const y in w){const ke=w[y],q=Array.from(g.querySelectorAll("["+y+"]"));g.matches&&g.matches("["+y+"]")&&q.push(g);for(let I=0;I<q.length;I++){const D=q[I];_(D)&&j(ke,D.getAttribute(y),y,o,D)}}c&&c(g)}const s=[];if(e.indexOf("[")!==-1){const b=/\[([\w-]+)/g;let g;for(;(g=b.exec(e))!==null;)s.push(g[1])}else s.push(e);de({selector:e,attribute:t,componentTag:o,attributes:w,ComponentFn:n,onInit:c,observed:s.concat(i),onAttributeChange:l,onAttrChange:f,effects:m,declared:T,persist:O}),we();const d=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]";V().push({selector:e,attribute:t,ComponentFn:n,onInit:c,onSubtreeChange:a,query:d}),pe(),window[t]=C;function p(){ce()>0?ue(function(){C(document.body)}):C(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",p):p(),C}function U(e){return(e||"").replace(/^#/,"")}function L(e){const t=e===void 0?location.hash:e,n={},o=U(t);if(!o)return n;const r=o.split("&");for(let i=0;i<r.length;i++){const l=r[i];if(!l)continue;const a=l.indexOf(":"),c=a>-1?l.slice(0,a):l,f=a>-1?l.slice(a+1):"";if(c)try{n[c]=decodeURIComponent(f)}catch{n[c]=f}}return n}function me(e){if(!e)return null;const t=L();return e in t?t[e]:null}function ge(e,t){if(!e)return;const n=L();t==null?delete n[e]:n[e]=String(t);const r=Object.keys(n).map(function(i){const l=n[i];return l===""?i:i+":"+encodeURIComponent(l)}).join("&");U(location.hash)!==r&&(location.hash=r)}function ye(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function Ce(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 o=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return o?t?o+"-"+t:o:t||null}function Ae(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function _e(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 ve(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function xe(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),o=e.slice(t+1),r=o?o.split(",").map(function(i){try{return decodeURIComponent(i)}catch{return i}}).filter(Boolean):[];return{key:n,values:r}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=L,window.lnCore.hashGet=me,window.lnCore.hashSet=ge,window.lnCore.hashLinkClick=ye,window.lnCore.resolveHashNamespace=Ce,window.lnCore.hashSortEncode=Ae,window.lnCore.hashSortDecode=_e,window.lnCore.hashFilterEncode=ve,window.lnCore.hashFilterDecode=xe);function Se(){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=Se),(function(){const e="data-ln-toast",t="lnToast",n="ln-toast-item";if(window[t]!==void 0)return;const o={"data-ln-toast":{type:"marker",description:"Initializes the toast notifications container"},"data-ln-toast-timeout":{prop:"timeoutDefault",type:"integer",read:S,fallback:6e3,min:500,description:"Default auto-dismiss timeout in ms"},"data-ln-toast-max":{prop:"max",type:"integer",read:S,fallback:5,min:1,description:"Maximum visible concurrent toast notifications"},"data-ln-toast-close":{type:"trigger",description:"Click dismiss trigger inside a toast item"},"data-ln-toast-item":{type:"marker",description:"Individual toast notification element"}},r=le(o);function i(s){if(!(!s||!(s instanceof HTMLElement))&&(s.hasAttribute("popover")||s.setAttribute("popover","manual"),typeof s.showPopover=="function")){if(s.matches(":popover-open"))try{s.hidePopover()}catch{}try{s.showPopover()}catch{}}}function l(s){if(!s||!(s instanceof HTMLElement))return;if(s.querySelectorAll("[data-ln-toast-item]").length===0&&typeof s.hidePopover=="function"&&s.matches(":popover-open"))try{s.hidePopover()}catch{}}function a(s){this.dom=s,ie(this,s,r);const u=Array.from(s.querySelectorAll("[data-ln-toast-item]"));for(;u.length>this.max;)s.removeChild(u.shift());for(const d of u)T(d,this);return u.length>0&&i(s),this}a.prototype.enqueue=function(s){if(!s)return;const u=c(s,this.dom);if(!u)return;const d=Number.isFinite(s.timeout)?s.timeout:this.timeoutDefault;h(this,u),d>0&&(u._timer=setTimeout(()=>w(u),d))},a.prototype.clear=function(){for(const s of Array.from(this.dom.querySelectorAll("[data-ln-toast-item]")))w(s)},a.prototype.destroy=function(){if(this.dom[t]){for(const s of Array.from(this.dom.querySelectorAll("[data-ln-toast-item]")))w(s);l(this.dom),delete this.dom[t]}};function c(s,u){const d=((s.type||"")+"").trim().toLowerCase(),p=X(u,n,"ln-toast");if(!p)return console.warn('[ln-toast] Template "'+n+'" not found'),null;x(p,{type:d,title:s.title,message:typeof s.message=="string"?s.message:void 0});const b=p.firstElementChild;if(!b)return null;b.hasAttribute("data-ln-toast-item")||b.setAttribute("data-ln-toast-item",""),b.classList.add("ln-enter");const g=b.querySelector(".body");g&&f(g,s);const y=b.querySelector("[data-ln-toast-close]");return y&&y.addEventListener("click",function(){w(b)}),b}function f(s,u){if(Array.isArray(u.message)){const d=document.createElement("ul");for(const p of u.message){const b=document.createElement("li");b.textContent=p,d.appendChild(b)}s.appendChild(d)}if(u.data&&u.data.errors){const d=document.createElement("ul");for(const p of Object.values(u.data.errors).flat()){const b=document.createElement("li");b.textContent=p,d.appendChild(b)}s.appendChild(d)}}function h(s,u){const d=Array.from(s.dom.querySelectorAll("[data-ln-toast-item]"));for(;d.length>=s.max&&d.length>0;)s.dom.removeChild(d.shift());s.dom.appendChild(u),i(s.dom),requestAnimationFrame(()=>u.classList.remove("ln-enter"))}function w(s){if(!s||!s.parentNode)return;const u=s.parentNode;clearTimeout(s._timer),s.classList.remove("ln-enter"),s.classList.add("ln-out"),setTimeout(()=>{s.parentNode&&(s.parentNode.removeChild(s),l(u))},200)}function m(s){let u=s&&s.container;return typeof u=="string"&&(u=document.querySelector(u)),u instanceof HTMLElement||(u=document.querySelector("["+e+"]")||document.getElementById("ln-toast-container")),u||null}function T(s,u){if(s._lnToastHydrated)return;s._lnToastHydrated=!0;const d=s.querySelector("[data-ln-toast-close]");d&&d.addEventListener("click",function(){w(s)});const p=+(s.getAttribute("data-ln-toast-timeout")??u.timeoutDefault);p>0&&(s._timer=setTimeout(function(){w(s)},p))}function O(s){const u=s.detail||{},d=m(u);if(!d){console.warn("[ln-toast] No toast container found");return}(d[t]||(d[t]=new a(d))).enqueue(u)}function C(s){const u=s&&s.detail||{};if(u.container){const d=m(u);d&&(d[t]||(d[t]=new a(d))).clear()}else{const d=document.querySelectorAll("["+e+"]");for(const p of Array.from(d))(p[t]||(p[t]=new a(p))).clear()}}A(function(){window.addEventListener("ln-toast:enqueue",O),window.addEventListener("ln-toast:clear",C),window.addEventListener("ln-modal:open",function(){const s=document.querySelectorAll("["+e+"], #ln-toast-container");for(const u of Array.from(s))u.querySelectorAll("[data-ln-toast-item]").length>0&&i(u)})},"ln-toast"),be(e,t,a,"ln-toast",{attributes:o})})()})();
@@ -1,65 +1,65 @@
1
- {
2
- "$comment": "This file is partly generated. The $comment, component, generator, and each attribute's direction, sources, type, values, fallback, and description keys are owned by the generator and synchronized from JS source code. All other keys are preserved and safe to hand-author. Regenerate with `npm run sync:ln-schemas`.",
3
- "component": "ln-toast",
4
- "generator": "scripts/sync-ln-schemas.mjs",
5
- "attributes": {
6
- "data-ln-debug": {
7
- "direction": null,
8
- "sources": [
9
- "ln-toast-dev.scss"
10
- ]
11
- },
12
- "data-ln-toast": {
13
- "direction": "author",
14
- "sources": [
15
- "ln-toast-dev.scss",
16
- "ln-toast.scss",
17
- "src/ln-toast.js"
18
- ],
19
- "type": "marker",
20
- "description": "Initializes the toast notifications container"
21
- },
22
- "data-ln-toast-close": {
23
- "direction": "author",
24
- "sources": [
25
- "src/ln-toast.js"
26
- ],
27
- "type": "trigger",
28
- "description": "Click dismiss trigger inside a toast item"
29
- },
30
- "data-ln-toast-item": {
31
- "direction": "both",
32
- "sources": [
33
- "src/ln-toast.js"
34
- ],
35
- "type": "marker",
36
- "description": "Individual toast notification element"
37
- },
38
- "data-ln-toast-max": {
39
- "direction": null,
40
- "sources": [
41
- "src/ln-toast.js"
42
- ],
43
- "type": "integer",
44
- "fallback": 5,
45
- "min": 1,
46
- "description": "Maximum visible concurrent toast notifications"
47
- },
48
- "data-ln-toast-timeout": {
49
- "direction": "author",
50
- "sources": [
51
- "src/ln-toast.js"
52
- ],
53
- "type": "integer",
54
- "fallback": 6000,
55
- "min": 500,
56
- "description": "Default auto-dismiss timeout in ms"
57
- },
58
- "data-ln-toast-when": {
59
- "direction": null,
60
- "sources": [
61
- "ln-toast.scss"
62
- ]
63
- }
64
- }
65
- }
1
+ {
2
+ "$comment": "This file is partly generated. The $comment, component, generator, and each attribute's direction, sources, type, values, fallback, and description keys are owned by the generator and synchronized from JS source code. All other keys are preserved and safe to hand-author. Regenerate with `npm run sync:ln-schemas`.",
3
+ "component": "ln-toast",
4
+ "generator": "scripts/sync-ln-schemas.mjs",
5
+ "attributes": {
6
+ "data-ln-debug": {
7
+ "direction": null,
8
+ "sources": [
9
+ "ln-toast-dev.scss"
10
+ ]
11
+ },
12
+ "data-ln-toast": {
13
+ "direction": "author",
14
+ "sources": [
15
+ "ln-toast-dev.scss",
16
+ "ln-toast.scss",
17
+ "src/ln-toast.js"
18
+ ],
19
+ "type": "marker",
20
+ "description": "Initializes the toast notifications container"
21
+ },
22
+ "data-ln-toast-close": {
23
+ "direction": "author",
24
+ "sources": [
25
+ "src/ln-toast.js"
26
+ ],
27
+ "type": "trigger",
28
+ "description": "Click dismiss trigger inside a toast item"
29
+ },
30
+ "data-ln-toast-item": {
31
+ "direction": "both",
32
+ "sources": [
33
+ "src/ln-toast.js"
34
+ ],
35
+ "type": "marker",
36
+ "description": "Individual toast notification element"
37
+ },
38
+ "data-ln-toast-max": {
39
+ "direction": null,
40
+ "sources": [
41
+ "src/ln-toast.js"
42
+ ],
43
+ "type": "integer",
44
+ "fallback": 5,
45
+ "min": 1,
46
+ "description": "Maximum visible concurrent toast notifications"
47
+ },
48
+ "data-ln-toast-timeout": {
49
+ "direction": "author",
50
+ "sources": [
51
+ "src/ln-toast.js"
52
+ ],
53
+ "type": "integer",
54
+ "fallback": 6000,
55
+ "min": 500,
56
+ "description": "Default auto-dismiss timeout in ms"
57
+ },
58
+ "data-ln-toast-when": {
59
+ "direction": null,
60
+ "sources": [
61
+ "ln-toast.scss"
62
+ ]
63
+ }
64
+ }
65
+ }
@@ -1 +1 @@
1
- (function(){"use strict";function x(){return typeof window>"u"?!1:window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink?!0:typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null:!1}function A(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 o=null;for(let l=1;l<t.length;l++)if(t[l]&&t[l].nodeType===1){o=t[l];break}if(!A(o))return}e.apply(console,t)}}function _(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))}function R(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o);const l=new CustomEvent(t,{bubbles:!0,cancelable:!0,detail:o});return e.dispatchEvent(l),l}function y(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){y(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}function H(e){return!!(!e||e.ctrlKey||e.metaKey||e.shiftKey||e.altKey||typeof e.button=="number"&&e.button!==0)}function K(e){return!!(!e||e.disabled||typeof e.getAttribute=="function"&&e.getAttribute("aria-disabled")==="true"||typeof e.closest=="function"&&e.closest("[inert]"))}const I={};function U(e,t){I[e]=t}function Q(e){return I[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=U,window.lnCore.getDataMapper=Q);function G(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,y(function(){new MutationObserver(function(){_(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const D={};function P(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];D[n]=t}function J(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return D[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=P,window.lnCore.getLocaleFallback=J,window.lnCore.ensureLocaleObserver=G);const v={};function z(e,t){v[e]||(v[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=v[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function $(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let r=0;r<n.length;r++){const u=n[r],s=u.getAttribute("data-ln-field");t[s]!=null&&(u.textContent=t[s])}const o=e.querySelectorAll("[data-ln-attr]");for(let r=0;r<o.length;r++){const u=o[r],s=u.getAttribute("data-ln-attr").split(",");for(let d=0;d<s.length;d++){const f=s[d].trim().split(":");if(f.length!==2)continue;const a=f[0].trim(),b=f[1].trim();t[b]!=null&&u.setAttribute(a,t[b])}}const l=e.querySelectorAll("[data-ln-show]");for(let r=0;r<l.length;r++){const u=l[r],s=u.getAttribute("data-ln-show");s in t&&u.classList.toggle("hidden",!t[s])}const i=e.querySelectorAll("[data-ln-class]");for(let r=0;r<i.length;r++){const u=i[r],s=u.getAttribute("data-ln-class").split(",");for(let d=0;d<s.length;d++){const f=s[d].trim().split(":");if(f.length!==2)continue;const a=f[0].trim(),b=f[1].trim();b in t&&u.classList.toggle(a,!!t[b])}}return e}function X(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 o=0;o<n.length;o++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[o],t??null),n[o].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)$(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 B(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const i=n.currentNode;i.textContent.indexOf("{{")!==-1&&(i.textContent=i.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(r,u){return t[u]!==void 0?t[u]:""}))}const o=function(i,r){return t[r]!==void 0?t[r]:""},l=Array.from(e.querySelectorAll("*"));e.nodeType===1&&l.push(e);for(let i=0;i<l.length;i++){const r=l[i],u=r.attributes;for(let s=0;s<u.length;s++){const d=u[s];d.value.indexOf("{{")!==-1&&r.setAttribute(d.name,d.value.replace(/\{\{\s*(\w+)\s*\}\}/g,o))}}return e}function Y(e,t,n,o,l,i){const r={};for(let s=0;s<e.children.length;s++){const d=e.children[s],f=d.getAttribute("data-ln-render-key");f&&(r[f]=d)}const u=document.createDocumentFragment();for(let s=0;s<t.length;s++){const d=t[s],f=String(o(d));let a=r[f];if(a)l(a,d,s);else{const b=z(n,i);if(!b||(B(b,d),a=b.firstElementChild,!a))continue;a.setAttribute("data-ln-render-key",f),l(a,d,s)}u.appendChild(a)}e.textContent="",e.appendChild(u)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=B,window.lnCore.fill=$,window.lnCore.lnFill=X,window.lnCore.renderList=Y);function F(e,t,n,o,l){if(!e||t===null)return!0;const i=o||"ln-component",r=e.type;if(r==="trigger"||r==="marker"||r==="string"||r==="list"||!r||t===""&&e.fallback!==void 0)return!0;const u=s=>{l?console.warn(s,l):console.warn(s)};if(r==="boolean"){const s=t.trim().toLowerCase();return s!==""&&s!=="true"&&s!=="false"&&s!=="1"&&s!=="0"?(u(`[${i}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(r==="enum"){const s=e.values||[];return s.includes(t)?!0:(u(`[${i}] Invalid value "${t}" for attribute "${n}". Allowed: ${s.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(r==="integer"){if(!/^-?\d+$/.test(t))return u(`[${i}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const s=parseInt(t,10);return e.min!==void 0&&s<e.min?(u(`[${i}] Value ${s} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&s>e.max?(u(`[${i}] Value ${s} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(r==="float")return isNaN(Number(t))?(u(`[${i}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(r==="json")try{return JSON.parse(t),!0}catch(s){return u(`[${i}] Invalid JSON for attribute "${n}": ${s.message}. Fallback: ${e.fallback}.`),!1}return!0}function Z(e){const t={};for(const n in e){const o=e[n];o&&o.effect&&(t[n]=o.effect)}return Object.keys(t).length?t:null}function ee(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}function k(e,t,n,o){if(e.nodeType!==1)return;const i=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",r=Array.from(e.querySelectorAll(i));e.matches&&e.matches(i)&&r.push(e);for(const u of r)if(!u[n]){window.lnCore._persistSink&&u.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(u,t);try{u[n]=new o(u)}catch(s){console.error("["+n+"] init failed",u,s)}}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function te(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function ne(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 M(){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 oe(e){const t=M(),n=e.observed||[];for(let o=0;o<n.length;o++){const l=n[o];t.byAttr.has(l)||t.byAttr.set(l,[]),t.byAttr.get(l).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const o in e.attributes){t.byDeclaredAttr.has(o)||t.byDeclaredAttr.set(o,[]);const l=t.byDeclaredAttr.get(o);l.some(i=>i.componentTag===e.componentTag)||l.push({spec:e.attributes[o],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const o=ee(e);if(o===null)t.reactiveWildcard.push(e);else for(const l of o)t.byReactive.has(l)||t.byReactive.set(l,[]),t.byReactive.get(l).push(e)}e.persist&&t.persist.push(e)}function W(e,t,n,o){for(let l=0;l<e.length;l++){const i=e[l];if(!t[i.attribute])continue;const r=i.effects&&i.effects[n];r?r(t,n,o):i.onAttrChange&&(!i.declared||i.declared.has(n))&&i.onAttrChange(t,n,o)}}function re(e){const t=e.target,n=e.attributeName;if(e.oldValue===t.getAttribute(n))return;const o=M(),l=o.byAttr.get(n);if(x()&&o.byDeclaredAttr&&o.byDeclaredAttr.has(n)&&A(t)){const i=o.byDeclaredAttr.get(n),r=t.getAttribute(n);for(let u=0;u<i.length;u++)F(i[u].spec,r,n,i[u].componentTag,t)}if(window.lnCore._debugSink&&(n.indexOf("data-ln-")===0||l)&&window.lnCore._debugSink("attr",n,t,{oldValue:e.oldValue,newValue:t.getAttribute(n)}),n.indexOf("data-ln-")===0){const i=o.byReactive.get(n);i&&W(i,t,n,e.oldValue),o.reactiveWildcard.length&&W(o.reactiveWildcard,t,n,e.oldValue)}if(l)for(let i=0;i<l.length;i++){const r=l[i];if(r.handler){r.handler(t,n,e.oldValue);continue}r.onAttributeChange&&t[r.attribute]?r.onAttributeChange(t,n):(k(t,r.selector,r.attribute,r.ComponentFn),r.onInit&&r.onInit(t))}}function ie(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,y(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{re(t[n])}catch(o){console.error("[ln-core] mutation handler failed",t[n].target,o)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function N(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function le(e){const t=N();if(t.length){if(e.target)for(let n=0;n<t.length;n++){const o=t[n];if(o.onSubtreeChange){const l=o.query,i=e.target.nodeType===1?e.target.matches(l)?e.target:e.target.closest(l):e.target.parentElement?e.target.parentElement.closest(l):null;i&&o.onSubtreeChange(i,e)}}for(let n=0;n<e.addedNodes.length;n++){const o=e.addedNodes[n];if(o.nodeType===1)for(let l=0;l<t.length;l++){const i=t[l];k(o,i.selector,i.attribute,i.ComponentFn),i.onInit&&i.onInit(o)}}for(let n=0;n<e.removedNodes.length;n++){const o=e.removedNodes[n];if(o.nodeType===1)for(let l=0;l<t.length;l++){const i=t[l],r=i.query,u=Array.from(o.querySelectorAll(r));o.matches&&o.matches(r)&&u.push(o);for(let s=0;s<u.length;s++){const d=u[s];if(!document.contains(d)){const f=d[i.attribute];if(f&&typeof f.destroy=="function")try{f.destroy()}catch(a){console.error("["+i.attribute+"] destroy failed",d,a)}delete d[i.attribute]}}}}}}function se(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,y(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++){const o=t[n];if(o.type==="childList")try{le(o)}catch(l){console.error("[ln-core] lifecycle handler failed",o.target,l)}}}).observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function ue(e,t,n,o,l={}){const i=l.extraAttributes||[],r=l.onAttributeChange||null,u=l.onSubtreeChange||null,s=l.onInit||null,d=l.onAttrChange||null,f=l.effects||null,a=l.attributes||null,b=a?Z(a):f,c=a?new Set(Object.keys(a)):null,g=l.persist||null;function h(L){const p=L||document.body;if(k(p,e,t,n),a&&x())for(const C in a){const pe=a[C],T=Array.from(p.querySelectorAll("["+C+"]"));p.matches&&p.matches("["+C+"]")&&T.push(p);for(let E=0;E<T.length;E++){const q=T[E];A(q)&&F(pe,q.getAttribute(C),C,o,q)}}s&&s(p)}const w=[];if(e.indexOf("[")!==-1){const L=/\[([\w-]+)/g;let p;for(;(p=L.exec(e))!==null;)w.push(p[1])}else w.push(e);oe({selector:e,attribute:t,componentTag:o,attributes:a,ComponentFn:n,onInit:s,observed:w.concat(i),onAttributeChange:r,onAttrChange:d,effects:b,declared:c,persist:g}),ie();const O=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]";N().push({selector:e,attribute:t,ComponentFn:n,onInit:s,onSubtreeChange:u,query:O}),se(),window[t]=h;function V(){te()>0?ne(function(){h(document.body)}):h(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",V):V(),h}function j(e){return(e||"").replace(/^#/,"")}function S(e){const t=e===void 0?location.hash:e,n={},o=j(t);if(!o)return n;const l=o.split("&");for(let i=0;i<l.length;i++){const r=l[i];if(!r)continue;const u=r.indexOf(":"),s=u>-1?r.slice(0,u):r,d=u>-1?r.slice(u+1):"";if(s)try{n[s]=decodeURIComponent(d)}catch{n[s]=d}}return n}function ce(e){if(!e)return null;const t=S();return e in t?t[e]:null}function de(e,t){if(!e)return;const n=S();t==null?delete n[e]:n[e]=String(t);const l=Object.keys(n).map(function(i){const r=n[i];return r===""?i:i+":"+encodeURIComponent(r)}).join("&");j(location.hash)!==l&&(location.hash=l)}function ae(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function fe(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 o=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return o?t?o+"-"+t:o:t||null}function ge(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function we(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 be(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function he(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),o=e.slice(t+1),l=o?o.split(",").map(function(i){try{return decodeURIComponent(i)}catch{return i}}).filter(Boolean):[];return{key:n,values:l}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=S,window.lnCore.hashGet=ce,window.lnCore.hashSet=de,window.lnCore.hashLinkClick=ae,window.lnCore.resolveHashNamespace=fe,window.lnCore.hashSortEncode=ge,window.lnCore.hashSortDecode=we,window.lnCore.hashFilterEncode=be,window.lnCore.hashFilterDecode=he),(function(){const e="data-ln-toggle",t="lnToggle",n="data-ln-toggle-for",o="data-ln-toggle-action";if(window[t]!==void 0)return;const l={"data-ln-toggle":{effect:b,type:"enum",values:["open","close"],fallback:"close",description:"Visibility state of toggleable element"},"data-ln-toggle-for":{type:"string",description:"Target element ID to toggle on trigger click"},"data-ln-toggle-action":{type:"enum",values:["open","close","toggle"],fallback:"toggle",description:"Action performed on target element when trigger is clicked"}},i=new Set;let r=null;function u(c,g){return g==="open"?"open":g==="close"||c==="open"?"close":"open"}function s(){r||(r=function(c){if(H(c))return;const g=c.target.closest("["+n+"]");if(!g||K(g))return;const h=g.getAttribute(n);if(!h)return;const w=document.getElementById(h);if(!w||!w[t])return;c.preventDefault();const m=g.getAttribute(o)||"toggle",O=w.getAttribute(e);w.setAttribute(e,u(O,m))},document.addEventListener("click",r))}function d(){i.size>0||!r||(document.removeEventListener("click",r),r=null)}function f(c,g){if(!c||!c.id)return;const h=document.querySelectorAll("["+n+'="'+c.id+'"]');for(let w=0;w<h.length;w++)h[w].setAttribute("aria-expanded",g?"true":"false")}function a(c){this.dom=c;const g=this;return this._onRequestOpen=function(){g.open()},this._onRequestClose=function(){g.close()},this._onRequestToggle=function(){g.toggle()},this.dom.addEventListener("ln-toggle:request-open",this._onRequestOpen),this.dom.addEventListener("ln-toggle:request-close",this._onRequestClose),this.dom.addEventListener("ln-toggle:request-toggle",this._onRequestToggle),this.isOpen=c.getAttribute(e)==="open",this.isOpen&&c.classList.add("open"),f(c,this.isOpen),i.add(this),s(),this}a.prototype.open=function(){this.dom.setAttribute(e,"open")},a.prototype.close=function(){this.dom.setAttribute(e,"close")},a.prototype.toggle=function(){const c=this.dom.getAttribute(e);this.dom.setAttribute(e,u(c,"toggle"))},a.prototype.destroy=function(){this.dom[t]&&(this.dom.removeEventListener("ln-toggle:request-open",this._onRequestOpen),this.dom.removeEventListener("ln-toggle:request-close",this._onRequestClose),this.dom.removeEventListener("ln-toggle:request-toggle",this._onRequestToggle),i.delete(this),delete this.dom[t],d())};function b(c){const g=c[t];if(!g)return;const w=c.getAttribute(e)==="open";if(w!==g.isOpen)if(w){if(R(c,"ln-toggle:before-open",{target:c}).defaultPrevented){c.setAttribute(e,"close");return}g.isOpen=!0,c.classList.add("open"),f(c,!0),_(c,"ln-toggle:open",{target:c})}else{if(R(c,"ln-toggle:before-close",{target:c}).defaultPrevented){c.setAttribute(e,"open");return}g.isOpen=!1,c.classList.remove("open"),f(c,!1),_(c,"ln-toggle:close",{target:c})}}ue(e,t,a,"ln-toggle",{attributes:l,persist:{attr:e,hashActive:null}})})()})();
1
+ (function(){"use strict";function q(){return typeof window>"u"?!1:window.lnDebug===!0||window.lnCore&&window.lnCore._debugSink?!0:typeof document<"u"&&document.body?document.body.hasAttribute("data-ln-debug")||document.body.querySelector("[data-ln-debug]")!==null:!1}function A(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 o=null;for(let l=1;l<t.length;l++)if(t[l]&&t[l].nodeType===1){o=t[l];break}if(!A(o))return}e.apply(console,t)}}function _(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o),e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))}function R(e,t,n){const o=n||{};window.lnCore._debugSink&&window.lnCore._debugSink("event",t,e,o);const l=new CustomEvent(t,{bubbles:!0,cancelable:!0,detail:o});return e.dispatchEvent(l),l}function y(e,t){if(!document.body){document.addEventListener("DOMContentLoaded",function(){y(e,t)}),console.warn("["+t+'] Script loaded before <body> — add "defer" to your <script> tag');return}e()}function V(e){return!!(!e||e.ctrlKey||e.metaKey||e.shiftKey||e.altKey||typeof e.button=="number"&&e.button!==0)}function H(e){return!!(!e||e.disabled||typeof e.getAttribute=="function"&&e.getAttribute("aria-disabled")==="true"||typeof e.closest=="function"&&e.closest("[inert]"))}const I={};function K(e,t){I[e]=t}function Q(e){return I[e]||{ingress:t=>t,egress:t=>t}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerDataMapper=K,window.lnCore.getDataMapper=Q);function G(){typeof window>"u"||(window.lnCore=window.lnCore||{},!window.lnCore._localeObserverBound&&(window.lnCore._localeObserverBound=!0,y(function(){new MutationObserver(function(){_(document,"ln-core:locale-change",{})}).observe(document.documentElement,{attributes:!0,attributeFilter:["lang"],subtree:!0})},"ln-core")))}const D={};function P(e,t){if(!e||typeof t!="object")return;const n=e.toLowerCase().split("-")[0];D[n]=t}function J(e){if(!e)return null;const t=e.toLowerCase().split("-")[0];return D[t]||null}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.registerLocaleFallback=P,window.lnCore.getLocaleFallback=J,window.lnCore.ensureLocaleObserver=G);const v={};function z(e,t){v[e]||(v[e]=document.querySelector('[data-ln-template="'+e+'"]'));const n=v[e];return n?n.content.cloneNode(!0):(console.warn("["+(t||"ln-core")+'] Template "'+e+'" not found'),null)}function $(e,t){if(!e||!t)return e;const n=e.querySelectorAll("[data-ln-field]");for(let r=0;r<n.length;r++){const u=n[r],s=u.getAttribute("data-ln-field");t[s]!=null&&(u.textContent=t[s])}const o=e.querySelectorAll("[data-ln-attr]");for(let r=0;r<o.length;r++){const u=o[r],s=u.getAttribute("data-ln-attr").split(",");for(let d=0;d<s.length;d++){const a=s[d].trim().split(":");if(a.length!==2)continue;const f=a[0].trim(),b=a[1].trim();t[b]!=null&&u.setAttribute(f,t[b])}}const l=e.querySelectorAll("[data-ln-show]");for(let r=0;r<l.length;r++){const u=l[r],s=u.getAttribute("data-ln-show");s in t&&u.classList.toggle("hidden",!t[s])}const i=e.querySelectorAll("[data-ln-class]");for(let r=0;r<i.length;r++){const u=i[r],s=u.getAttribute("data-ln-class").split(",");for(let d=0;d<s.length;d++){const a=s[d].trim().split(":");if(a.length!==2)continue;const f=a[0].trim(),b=a[1].trim();b in t&&u.classList.toggle(f,!!t[b])}}return e}function X(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 o=0;o<n.length;o++)window.lnCore._debugSink&&window.lnCore._debugSink("event","ln-fill",n[o],t??null),n[o].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)$(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 B(e,t){if(!e||!t)return e;const n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(;n.nextNode();){const i=n.currentNode;i.textContent.indexOf("{{")!==-1&&(i.textContent=i.textContent.replace(/\{\{\s*(\w+)\s*\}\}/g,function(r,u){return t[u]!==void 0?t[u]:""}))}const o=function(i,r){return t[r]!==void 0?t[r]:""},l=Array.from(e.querySelectorAll("*"));e.nodeType===1&&l.push(e);for(let i=0;i<l.length;i++){const r=l[i],u=r.attributes;for(let s=0;s<u.length;s++){const d=u[s];d.value.indexOf("{{")!==-1&&r.setAttribute(d.name,d.value.replace(/\{\{\s*(\w+)\s*\}\}/g,o))}}return e}function Y(e,t,n,o,l,i){const r={};for(let s=0;s<e.children.length;s++){const d=e.children[s],a=d.getAttribute("data-ln-render-key");a&&(r[a]=d)}const u=document.createDocumentFragment();for(let s=0;s<t.length;s++){const d=t[s],a=String(o(d));let f=r[a];if(f)l(f,d,s);else{const b=z(n,i);if(!b||(B(b,d),f=b.firstElementChild,!f))continue;f.setAttribute("data-ln-render-key",a),l(f,d,s)}u.appendChild(f)}e.textContent="",e.appendChild(u)}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.fillTemplate=B,window.lnCore.fill=$,window.lnCore.lnFill=X,window.lnCore.renderList=Y);function M(e,t,n,o,l){if(!e||t===null)return!0;const i=o||"ln-component",r=e.type;if(r==="trigger"||r==="marker"||r==="string"||r==="list"||!r||t===""&&e.fallback!==void 0)return!0;const u=s=>{l?console.warn(s,l):console.warn(s)};if(r==="boolean"){const s=t.trim().toLowerCase();return s!==""&&s!=="true"&&s!=="false"&&s!=="1"&&s!=="0"?(u(`[${i}] Invalid value "${t}" for boolean attribute "${n}". Allowed: "true", "false", or presence-only.`),!1):!0}if(r==="enum"){const s=e.values||[];return s.includes(t)?!0:(u(`[${i}] Invalid value "${t}" for attribute "${n}". Allowed: ${s.join(", ")}. Fallback: "${e.fallback}".`),!1)}if(r==="integer"){if(!/^-?\d+$/.test(t))return u(`[${i}] Invalid integer "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1;const s=parseInt(t,10);return e.min!==void 0&&s<e.min?(u(`[${i}] Value ${s} for attribute "${n}" is less than min (${e.min}).`),!1):e.max!==void 0&&s>e.max?(u(`[${i}] Value ${s} for attribute "${n}" is greater than max (${e.max}).`),!1):!0}if(r==="float")return isNaN(Number(t))?(u(`[${i}] Invalid float "${t}" for attribute "${n}". Fallback: ${e.fallback}.`),!1):!0;if(r==="json")try{return JSON.parse(t),!0}catch(s){return u(`[${i}] Invalid JSON for attribute "${n}": ${s.message}. Fallback: ${e.fallback}.`),!1}return!0}function Z(e){const t={};for(const n in e){const o=e[n];o&&o.effect&&(t[n]=o.effect)}return Object.keys(t).length?t:null}function ee(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}function x(e,t,n,o){if(e.nodeType!==1)return;const i=t.indexOf("[")!==-1||t.indexOf(".")!==-1||t.indexOf("#")!==-1?t:"["+t+"]",r=Array.from(e.querySelectorAll(i));e.matches&&e.matches(i)&&r.push(e);for(const u of r)if(!u[n]){window.lnCore._persistSink&&u.hasAttribute("data-ln-persist")&&window.lnCore._persistSink(u,t);try{u[n]=new o(u)}catch(s){console.error("["+n+"] init failed",u,s)}}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore._bootHolds=window.lnCore._bootHolds||0,window.lnCore._bootQueue=window.lnCore._bootQueue||[]);function te(){return typeof window<"u"&&window.lnCore&&window.lnCore._bootHolds||0}function ne(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 F(){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 oe(e){const t=F(),n=e.observed||[];for(let o=0;o<n.length;o++){const l=n[o];t.byAttr.has(l)||t.byAttr.set(l,[]),t.byAttr.get(l).push(e)}if(t.byDeclaredAttr=t.byDeclaredAttr||new Map,e.attributes)for(const o in e.attributes){t.byDeclaredAttr.has(o)||t.byDeclaredAttr.set(o,[]);const l=t.byDeclaredAttr.get(o);l.some(i=>i.componentTag===e.componentTag)||l.push({spec:e.attributes[o],componentTag:e.componentTag})}if(e.onAttrChange||e.effects){t.reactive.push(e);const o=ee(e);if(o===null)t.reactiveWildcard.push(e);else for(const l of o)t.byReactive.has(l)||t.byReactive.set(l,[]),t.byReactive.get(l).push(e)}e.persist&&t.persist.push(e)}function W(e,t,n,o){for(let l=0;l<e.length;l++){const i=e[l];if(!t[i.attribute])continue;const r=i.effects&&i.effects[n];r?r(t,n,o):i.onAttrChange&&(!i.declared||i.declared.has(n))&&i.onAttrChange(t,n,o)}}function re(e){const t=e.target,n=e.attributeName;if(e.oldValue===t.getAttribute(n))return;const o=F(),l=o.byAttr.get(n);if(q()&&o.byDeclaredAttr&&o.byDeclaredAttr.has(n)&&A(t)){const i=o.byDeclaredAttr.get(n),r=t.getAttribute(n);for(let u=0;u<i.length;u++)M(i[u].spec,r,n,i[u].componentTag,t)}if(window.lnCore._debugSink&&(n.indexOf("data-ln-")===0||l)&&window.lnCore._debugSink("attr",n,t,{oldValue:e.oldValue,newValue:t.getAttribute(n)}),n.indexOf("data-ln-")===0){const i=o.byReactive.get(n);i&&W(i,t,n,e.oldValue),o.reactiveWildcard.length&&W(o.reactiveWildcard,t,n,e.oldValue)}if(l)for(let i=0;i<l.length;i++){const r=l[i];if(r.handler){r.handler(t,n,e.oldValue);continue}r.onAttributeChange&&t[r.attribute]?r.onAttributeChange(t,n):(x(t,r.selector,r.attribute,r.ComponentFn),r.onInit&&r.onInit(t))}}function ie(){window.lnCore=window.lnCore||{},!window.lnCore._attrObserverBound&&(window.lnCore._attrObserverBound=!0,y(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++)try{re(t[n])}catch(o){console.error("[ln-core] mutation handler failed",t[n].target,o)}}).observe(document.body,{attributes:!0,subtree:!0,attributeOldValue:!0})},"ln-core"))}function N(){return window.lnCore=window.lnCore||{},window.lnCore._lifecycleRegistry=window.lnCore._lifecycleRegistry||[]}function le(e){const t=N();if(t.length){if(e.target)for(let n=0;n<t.length;n++){const o=t[n];if(o.onSubtreeChange){const l=o.query,i=e.target.nodeType===1?e.target.matches(l)?e.target:e.target.closest(l):e.target.parentElement?e.target.parentElement.closest(l):null;i&&o.onSubtreeChange(i,e)}}for(let n=0;n<e.addedNodes.length;n++){const o=e.addedNodes[n];if(o.nodeType===1)for(let l=0;l<t.length;l++){const i=t[l];x(o,i.selector,i.attribute,i.ComponentFn),i.onInit&&i.onInit(o)}}for(let n=0;n<e.removedNodes.length;n++){const o=e.removedNodes[n];if(o.nodeType===1)for(let l=0;l<t.length;l++){const i=t[l],r=i.query,u=Array.from(o.querySelectorAll(r));o.matches&&o.matches(r)&&u.push(o);for(let s=0;s<u.length;s++){const d=u[s];if(!document.contains(d)){const a=d[i.attribute];if(a&&typeof a.destroy=="function")try{a.destroy()}catch(f){console.error("["+i.attribute+"] destroy failed",d,f)}delete d[i.attribute]}}}}}}function se(){window.lnCore=window.lnCore||{},!window.lnCore._lifecycleObserverBound&&(window.lnCore._lifecycleObserverBound=!0,y(function(){new MutationObserver(function(t){for(let n=0;n<t.length;n++){const o=t[n];if(o.type==="childList")try{le(o)}catch(l){console.error("[ln-core] lifecycle handler failed",o.target,l)}}}).observe(document.body,{childList:!0,subtree:!0})},"ln-core"))}function ue(e,t,n,o,l={}){const i=l.extraAttributes||[],r=l.onAttributeChange||null,u=l.onSubtreeChange||null,s=l.onInit||null,d=l.onAttrChange||null,a=l.effects||null,f=l.attributes||null,b=f?Z(f):a,c=f?new Set(Object.keys(f)):null,w=l.persist||null;function h(O){const p=O||document.body;if(x(p,e,t,n),f&&q())for(const C in f){const Ce=f[C],L=Array.from(p.querySelectorAll("["+C+"]"));p.matches&&p.matches("["+C+"]")&&L.push(p);for(let T=0;T<L.length;T++){const E=L[T];A(E)&&M(Ce,E.getAttribute(C),C,o,E)}}s&&s(p)}const g=[];if(e.indexOf("[")!==-1){const O=/\[([\w-]+)/g;let p;for(;(p=O.exec(e))!==null;)g.push(p[1])}else g.push(e);oe({selector:e,attribute:t,componentTag:o,attributes:f,ComponentFn:n,onInit:s,observed:g.concat(i),onAttributeChange:r,onAttrChange:d,effects:b,declared:c,persist:w}),ie();const S=e.indexOf("[")!==-1||e.indexOf(".")!==-1||e.indexOf("#")!==-1?e:"["+e+"]";N().push({selector:e,attribute:t,ComponentFn:n,onInit:s,onSubtreeChange:u,query:S}),se(),window[t]=h;function U(){te()>0?ne(function(){h(document.body)}):h(document.body)}return document.readyState==="loading"?document.addEventListener("DOMContentLoaded",U):U(),h}function j(e){return(e||"").replace(/^#/,"")}function k(e){const t=e===void 0?location.hash:e,n={},o=j(t);if(!o)return n;const l=o.split("&");for(let i=0;i<l.length;i++){const r=l[i];if(!r)continue;const u=r.indexOf(":"),s=u>-1?r.slice(0,u):r,d=u>-1?r.slice(u+1):"";if(s)try{n[s]=decodeURIComponent(d)}catch{n[s]=d}}return n}function ce(e){if(!e)return null;const t=k();return e in t?t[e]:null}function de(e,t){if(!e)return;const n=k();t==null?delete n[e]:n[e]=String(t);const l=Object.keys(n).map(function(i){const r=n[i];return r===""?i:i+":"+encodeURIComponent(r)}).join("&");j(location.hash)!==l&&(location.hash=l)}function fe(e){return e.button===1||e.ctrlKey||e.metaKey||e.shiftKey?!1:(e.preventDefault(),!0)}function ae(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 o=e.getAttribute("data-ln-sort")||e.getAttribute("data-ln-search-for")||e.getAttribute("data-ln-search")||e.getAttribute("data-ln-filter")||e.id;return o?t?o+"-"+t:o:t||null}function we(e,t){return!t||t==="none"||e===null||e===void 0?null:String(e)+"."+t}function ge(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 be(e,t){return!e||!Array.isArray(t)||t.length===0?null:e+":"+t.map(encodeURIComponent).join(",")}function he(e){if(!e||typeof e!="string")return null;const t=e.indexOf(":");if(t===-1)return null;const n=e.slice(0,t),o=e.slice(t+1),l=o?o.split(",").map(function(i){try{return decodeURIComponent(i)}catch{return i}}).filter(Boolean):[];return{key:n,values:l}}typeof window<"u"&&(window.lnCore=window.lnCore||{},window.lnCore.hashParse=k,window.lnCore.hashGet=ce,window.lnCore.hashSet=de,window.lnCore.hashLinkClick=fe,window.lnCore.resolveHashNamespace=ae,window.lnCore.hashSortEncode=we,window.lnCore.hashSortDecode=ge,window.lnCore.hashFilterEncode=be,window.lnCore.hashFilterDecode=he);function pe(){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=pe),(function(){const e="data-ln-toggle",t="lnToggle",n="data-ln-toggle-for",o="data-ln-toggle-action";if(window[t]!==void 0)return;const l={"data-ln-toggle":{effect:b,type:"enum",values:["open","close"],fallback:"close",description:"Visibility state of toggleable element"},"data-ln-toggle-for":{type:"string",description:"Target element ID to toggle on trigger click"},"data-ln-toggle-action":{type:"enum",values:["open","close","toggle"],fallback:"toggle",description:"Action performed on target element when trigger is clicked"}},i=new Set;let r=null;function u(c,w){return w==="open"?"open":w==="close"||c==="open"?"close":"open"}function s(){r||(r=function(c){if(V(c))return;const w=c.target.closest("["+n+"]");if(!w||H(w))return;const h=w.getAttribute(n);if(!h)return;const g=document.getElementById(h);if(!g||!g[t])return;c.preventDefault();const m=w.getAttribute(o)||"toggle",S=g.getAttribute(e);g.setAttribute(e,u(S,m))},document.addEventListener("click",r))}function d(){i.size>0||!r||(document.removeEventListener("click",r),r=null)}function a(c,w){if(!c||!c.id)return;const h=document.querySelectorAll("["+n+'="'+c.id+'"]');for(let g=0;g<h.length;g++)h[g].setAttribute("aria-expanded",w?"true":"false")}function f(c){this.dom=c;const w=this;return this._onRequestOpen=function(){w.open()},this._onRequestClose=function(){w.close()},this._onRequestToggle=function(){w.toggle()},this.dom.addEventListener("ln-toggle:request-open",this._onRequestOpen),this.dom.addEventListener("ln-toggle:request-close",this._onRequestClose),this.dom.addEventListener("ln-toggle:request-toggle",this._onRequestToggle),this.isOpen=c.getAttribute(e)==="open",this.isOpen&&c.classList.add("open"),a(c,this.isOpen),i.add(this),s(),this}f.prototype.open=function(){this.dom.setAttribute(e,"open")},f.prototype.close=function(){this.dom.setAttribute(e,"close")},f.prototype.toggle=function(){const c=this.dom.getAttribute(e);this.dom.setAttribute(e,u(c,"toggle"))},f.prototype.destroy=function(){this.dom[t]&&(this.dom.removeEventListener("ln-toggle:request-open",this._onRequestOpen),this.dom.removeEventListener("ln-toggle:request-close",this._onRequestClose),this.dom.removeEventListener("ln-toggle:request-toggle",this._onRequestToggle),i.delete(this),delete this.dom[t],d())};function b(c){const w=c[t];if(!w)return;const g=c.getAttribute(e)==="open";if(g!==w.isOpen)if(g){if(R(c,"ln-toggle:before-open",{target:c}).defaultPrevented){c.setAttribute(e,"close");return}w.isOpen=!0,c.classList.add("open"),a(c,!0),_(c,"ln-toggle:open",{target:c})}else{if(R(c,"ln-toggle:before-close",{target:c}).defaultPrevented){c.setAttribute(e,"open");return}w.isOpen=!1,c.classList.remove("open"),a(c,!1),_(c,"ln-toggle:close",{target:c})}}ue(e,t,f,"ln-toggle",{attributes:l,persist:{attr:e,hashActive:null}})})()})();