mnfst 0.5.327 → 0.5.329

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.
@@ -2,7 +2,7 @@
2
2
  "manifest.accordion.css": "sha384-XA/UMMX/m2c8/rtvH3LeUez5j/jjNq+sTvihfja4fT2r47bWdpLH/wRpR+4PGdRN",
3
3
  "manifest.appwrite.auth.js": "sha384-n+Fohtui5o2h3HpM7ifnop9YsAdlTj0uHYfzljQMghLJeDkODC6OXop6ds6OTZha",
4
4
  "manifest.appwrite.auth.min.js": "sha384-qN5XF96RpRVTzBeOBoxwh6ziq2+eZ2rS0cLUtlwp4CFcbyuMCaf6kHFJKoWEGNvp",
5
- "manifest.appwrite.data.js": "sha384-tyZJ4XQqqPOOwUS0HyOLjUr4T85GP3qvBWuNa9pzhMVRzs6tXsyrWjANVc1FOGAk",
5
+ "manifest.appwrite.data.js": "sha384-93IR3wa3zWYVLzJXPuo9OHEhj0IsYvpJ9QMz4V2qFfmWmdF2lTWhoEnrAmfDO9Bq",
6
6
  "manifest.appwrite.data.min.js": "sha384-0fTVQE2rvA0T/qiXgSxe9YZDezipYFzrsSqnDcN8Xh6Vij1Pt/b3M6xySEqUtTjK",
7
7
  "manifest.appwrite.presences.js": "sha384-O3EedwV2QTzd4YotjvGPsDHbxaGbtRaZuNopC7/Cfoo5uYPo8ZHYkCPCWurXpA2/",
8
8
  "manifest.appwrite.presences.min.js": "sha384-7AHt7baL29VI3S1Nbkkyq34j2eJ2ysGpDnllmpXXSlc4GHvTk5hdCrXra2R3mSfH",
@@ -35,8 +35,8 @@
35
35
  "manifest.computed.js": "sha384-GYML/e81gQfN+iDbqhPUgny8bINCyL+SrbTofoGk4hlCnLLjv51mCv42JMqq+ku5",
36
36
  "manifest.computed.min.js": "sha384-90LbCcEOhrjhxi0GWBRb3DJyOkKWLRwzK7Z2nkbc1uaZ5B9EGmNKqx+mstTLWFGJ",
37
37
  "manifest.css": "sha384-WvntWYbbzn/qhMLloLI/aTaw1TIuYuPuISMLLBaC2ELhmFPYu1rix/WNzyDeG/Z+",
38
- "manifest.data.js": "sha384-qRbt94zUi2wZsTIQ3T6oBdNHPwdRXuyzs/MTIRYl/r1Z6ONHR8+WSaSujyr+Qajj",
39
- "manifest.data.min.js": "sha384-lc7GskUBOg82gIIiF71rKNtLo/ZTeT3VYXR5PQyqPwg8dFjNl/EV2L4+UAqdzxO1",
38
+ "manifest.data.js": "sha384-XdO51MPXw9g+p6jrwoXgY4U3TURz3ByFGKwismr8u43zWnWiCVUCB+e8oBeUgxMT",
39
+ "manifest.data.min.js": "sha384-VAPYQz1mA1owNeK3rh7VfAstLEa9bgE2NuDpkxopPQn3kKsa/1PXFCMeZ1rmRpGs",
40
40
  "manifest.datepicker.css": "sha384-lW6PLZxKr2GjR/O16oPq+5wrBZjQ1UCQUo2PTQZaj0FW8hCh6dydjzCF1qcp9up4",
41
41
  "manifest.datepicker.js": "sha384-pZUQhUK6u5cl6g0myBXND/Wtrs1RTovYmy/ETQLUV0JujvTvUdRNc/XjPpVhtK16",
42
42
  "manifest.datepicker.min.js": "sha384-e6xN1xQW3LLFvmSWrh3INMCgfUwD+gJca6n9fJfUFArA/OSm2KY0MDeN0pHVsYiw",
@@ -58,14 +58,14 @@
58
58
  "manifest.icons.js": "sha384-gLb9vW0MRJTQi6M1HFUylSLGNohkaCyUaCfhcoRPPzJOIxVrQzMeQuFUMqRMj2Yy",
59
59
  "manifest.icons.min.js": "sha384-TZpazdx9K8xe3e7jmYoCzg7YD/7kBp1u8ScByfigopAvGJOzR4K10zpmGovwA0nv",
60
60
  "manifest.input.css": "sha384-6+ErMsR67xE2xQWUS6QPhYH89pqf4wY4GEIDPq6jcQrHDqZMthyX4I93N4DttG7c",
61
- "manifest.js": "sha384-M+vIrgxGxFBhebyU2t1a2Lju4q8FHuEwtDE+WhFZz2yWyGTtHMDSD8/BlJ80sDWG",
61
+ "manifest.js": "sha384-OcOflvO/fXokhe0swG4kYRdTGwMlp3plPjCu92pM8mt4Jy58yFrqlFpMlTTBOSk2",
62
62
  "manifest.localization.js": "sha384-9EDAqnI7MNCZp4Vas0RMZgceCuz9EJUi/OARm8iI+Hi4S8HF//yyVOhhhhQ+XcLq",
63
63
  "manifest.localization.min.js": "sha384-5EkwrlpE29wmsy0JBq7UwWy8rVzEsu8tTprnsiNThVddFWsbFd63C/il4JjnWLmP",
64
64
  "manifest.markdown.js": "sha384-/LLa87KJ6YlTj/JutsklolHDnOulqlzZaNgM+q8msbQvyMiVILUd6nlxmU9Nk7xP",
65
65
  "manifest.markdown.min.js": "sha384-YLOiUmD2LX8t8wi1mYyhC8MbjN4tFrbSqC0iWX0uVsM797cMnN75urExn1mE/TpO",
66
66
  "manifest.min.css": "sha384-ZLXKtchybe6D6nmOkd2CYR9LzplunAqxpUkvf8yfrn8BLT/M2jNo83Tb95mdx98L",
67
- "manifest.min.js": "sha384-+XXRA+FBP/wie6tIxUBJk8DlFexD4OlR70wdlpRM2/fQNkVYK9oaaffC1dv/7BN7",
68
- "manifest.modules.integrity.json": "sha384-sv3psmy86c9Ic8pAWVegj9cA16a1bImwlfxLXzn30n7Myw60TiLQGX3DgPBzSiHp",
67
+ "manifest.min.js": "sha384-N/7T3FM82pG3Qdmqiwx0ghQeJD1xCXml7RN0yxk+u1A5VXdpescOzgI87LJ095BX",
68
+ "manifest.modules.integrity.json": "sha384-7BFrrPv4hAz22nnh6WAq2gQQN75EFMHZc5x0W352e8pubbJuXlbCPiYPR2se2mTe",
69
69
  "manifest.native.js": "sha384-YeQaS56L8IILqrQNBSeAOLwIh5DuAOrE60cYLK1+46qJtUrXlAvqGe2j5mbV4Vq7",
70
70
  "manifest.native.min.js": "sha384-3xZep6D5icnCvKbzPxQ6QxqvJMfWI0GiADQrGkiFJEhe8sXg6P6vfIAjLUykFi+2",
71
71
  "manifest.payments.js": "sha384-3Db2i47QA5I/Id5XMkwJThxSe8wZFiEEcJaKuuIjE5yBjGBxPMWFwhE4wgdvWgOo",
@@ -88,8 +88,8 @@
88
88
  "manifest.submissions.min.js": "sha384-p/5Ekd6u/cTsyVQbRgGzEi3h1hJU9zD7+hjdR+upcwt++26sfrLXMjFI2YjS8zWt",
89
89
  "manifest.svg.js": "sha384-D1jF3a0pXIuzm7T2sltyzblF8BTZ8sv1CkfJyQ33q21G6QlYyjdPv8DJi80eCISD",
90
90
  "manifest.svg.min.js": "sha384-rsvQ50FgVpTxX2Wvba3hed2TQvZR+CHHfgS4Cg7V1Dyjx6rxkS1s6rG6UMWDIMez",
91
- "manifest.sw.js": "sha384-rKrWSbZ7HvKN49qGQEfMpKyaOd07REJOyRD4QAxFpDzGu6MHl2AAahWY6G728hEG",
92
- "manifest.sw.min.js": "sha384-eaGkrideMEFFSbZbnda19F9HgTVBaIxzNTPfUcFEUIs1yOBhQ88UWLiWETUI+IT2",
91
+ "manifest.sw.js": "sha384-bjawIp80uwwNA0SJRS/s69cy/2N2m7+sMBmuWmFACKCJI9f+f/V44f3zetLWfgIY",
92
+ "manifest.sw.min.js": "sha384-3iU7BbyIG3os06PZtX9l/US2yP4ibPF3ESpiMWxhF3RynQ1YCdEmZNMi8gIBLHto",
93
93
  "manifest.switch.css": "sha384-s3+th9ojcLpRGhxxS9u4VR+AVRUqK6sNI62h4TAuZG7G1r1bNqXo1z/UMhTon00x",
94
94
  "manifest.table.css": "sha384-1XqR9mQSrxogf6fGcbVEbQ/cObABBAlMNfpW6T0vibXYwHv6l9kF3AVTXg/FknpM",
95
95
  "manifest.tabs.js": "sha384-LoPOo8mCAzyil9BLFV1BsDNBVyKmijKieKl7mbVAHEH/Nd7Ye0E6fM6yOgdBKcHZ",
@@ -110,6 +110,6 @@
110
110
  "manifest.utilities.js": "sha384-G1Tg8KsB7z7ANHiYZCzqijjOCtogvdEM+dYb8P/h0a1XafTThQOkp1gHlvNsjtPm",
111
111
  "manifest.utilities.min.js": "sha384-WilK2hRJ6X1wKLv8RaXDxKllqqGWbux83+yL1Tdv/VoYP0T2YxRH2YXT2bZkxUh1",
112
112
  "manifest.vendor.integrity.json": "sha384-xMKQh8gEBZhtaYhv09XUs3amAIT3Oh7aKrsGN0ABsnlIpbgxr5OHi5FxQTQhqz3E",
113
- "manifest.virtual.js": "sha384-wloH8yOvFNWWQ4LGLy00gBWy5xXg+VRJQnM56Kc9Iew7lgFUWSnf+bE0+Q76ju2l",
114
- "manifest.virtual.min.js": "sha384-9//BZjm3dEzh2gTKvZ3J012FtOTuTWruH0BCOKcYC4qITNfouz+1i1tNowllhbjL"
113
+ "manifest.virtual.js": "sha384-qsDbOyaNclitvdN6Cz03ZGnmr7wghH4Bo4RQQj9Wl1vNfMLy+UjcSPdI45AMd3p/",
114
+ "manifest.virtual.min.js": "sha384-Mx9NygIxGdBzSPo5b0Oc+EIN4bKsFg03b5EprHP69lhfCaSFqHszqEAgwvjlBjap"
115
115
  }
package/lib/manifest.js CHANGED
@@ -353,8 +353,8 @@
353
353
  const DEFAULT_VERSION = 'latest';
354
354
 
355
355
  // Stamped at build
356
- const LOADER_VERSION = '0.5.327';
357
- const MODULES_INTEGRITY = 'sha384-sv3psmy86c9Ic8pAWVegj9cA16a1bImwlfxLXzn30n7Myw60TiLQGX3DgPBzSiHp';
356
+ const LOADER_VERSION = '0.5.329';
357
+ const MODULES_INTEGRITY = 'sha384-7BFrrPv4hAz22nnh6WAq2gQQN75EFMHZc5x0W352e8pubbJuXlbCPiYPR2se2mTe';
358
358
  const INTEGRITY_FILE = 'manifest.modules.integrity.json';
359
359
  const VENDOR_FILE = 'manifest.vendor.integrity.json';
360
360
  // 'strict' | 'warn' while checks are requested; map promise while they apply
@@ -1,2 +1,2 @@
1
- !function(){"use strict";const e=document.currentScript;if(!window.ManifestPending){const he=new Map;let ye=0;window.ManifestPending={hold(e="work"){const t=++ye;return he.set(t,e),()=>{he.delete(t)}},get count(){return he.size+(window.__manifestMarkdownPending||0)+(window.__manifestUtilitiesPending||0)},labels(){const e=[...he.values()];return window.__manifestMarkdownPending>0&&e.push("markdown"),window.__manifestUtilitiesPending>0&&e.push("utilities"),e},background:e=>("function"==typeof e&&(e.__manifestBackground=!0),e)}}const t=new Set,n=new WeakSet;let i=!1;function o(){for(const e of[...t])e.settle()}function r(){i||(i=!0,queueMicrotask(()=>{i=!1,o()}))}function a(e){for(let t=e.parentNode;t;t=t.parentNode)if(t._x_ignore)return!0;return!1}function s(e,i){const s=window.Alpine,c=e.getAttribute("x-if");let d=!e.closest("[x-data],[x-init]"),l=!1,u=null;const f=()=>!!s.evaluate(e,c),m=()=>{u&&(u(),u=null)},p=()=>{t.delete(y),m()},w=()=>{d=!1,l=!1,m(),i._x_ignore=!0,t.add(y)},g=()=>{p(),s.mutateDom(()=>{s.destroyTree(i),i.remove()}),delete e._x_currentIfEl,delete e._x_lastRenderedEl,r()},h=()=>{d||e._x_currentIfEl!==i||!i.isConnected||a(e)||(d=!0,l=!1,p(),delete i._x_ignore,s.initTree(i),o())},y={settle(){if(!d&&!l)return e._x_currentIfEl!==i?p():void(i.isConnected?e._x_marker&&!a(e)&&f()&&h():i.getRootNode()instanceof DocumentFragment||p())}},v=()=>window.__manifestReady||!window.__manifestReadyCoordinator?g():(queueMicrotask(()=>{e._x_currentIfEl===i&&(e._x_undoIf=v,(()=>{if(u||!l||e._x_currentIfEl!==i||a(e))return;const t=s.evaluateLater(e,c),n=s.effect(()=>t(e=>{e&&queueMicrotask(()=>{l&&f()&&h()})}));u=()=>s.release(n)})())}),a(e)?w():(d&&(d=!1,i._x_ignore=!0,s.destroyTree(i),t.add(y)),void(l||(l=!0,window.addEventListener("manifest:ready",()=>{if(l&&e._x_currentIfEl===i){if(e.isConnected&&a(e))return w();if(e.isConnected&&f())return h();g(),delete e._x_undoIf}},{once:!0})))));e._x_currentIfEl=i,e._x_lastRenderedEl=i,e._x_undoIf=v,n.add(e),d||(i._x_ignore=!0,t.add(y))}function c(e,t){e.querySelectorAll("template").forEach(e=>{const n=t||e.matches("[x-if],[x-for]");n&&e.content.querySelectorAll("[data-pre-rendered]").forEach(e=>{e.tagName.startsWith("X-")&&e.removeAttribute("data-pre-rendered")}),c(e.content,n)})}function d(){try{!function(){if("undefined"==typeof document||!document.querySelector)return;const e=document.querySelector('meta[name="manifest:prerendered"]');if(!e||"0"===e.getAttribute("content"))return;const t=document.getElementById("__manifest_hydrate__");if(!t)return;let n;try{n=JSON.parse(t.textContent||"[]")}catch(e){n=[]}if(!Array.isArray(n)||0===n.length)return void t.remove();const i=e=>String(null==e?"":e).replace(/&/g,"&amp;").replace(/"/g,"&quot;"),o=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),r=[];for(const e of n){const t=document.querySelector('[data-hydrate-id="'+e.id+'"]');if(!t)continue;let n=0;for(let e=t.parentNode;e;e=e.parentNode)n++;r.push({entry:e,el:t,depth:n})}r.sort((e,t)=>t.depth-e.depth);for(const{entry:e,el:t}of r){const n=document.querySelector('[data-hydrate-id="'+e.id+'"]')||t;if(!n||!n.parentNode)continue;if("string"==typeof e.html){const t=n.tagName.toLowerCase(),r={},a=n.attributes;for(let e=0;e<a.length;e++)"data-hydrate-id"!==a[e].name&&(r[a[e].name]=a[e].value);if(e.attrs)for(const t in e.attrs){const n=e.attrs[t];null===n?delete r[t]:r[t]=n}const s=Object.keys(r).map(e=>e+'="'+i(r[e])+'"').join(" "),c=o.has(t)?"<"+t+" "+s+">":"<"+t+" "+s+">"+e.html+"</"+t+">",d=document.createElement("div");d.innerHTML=c;const l=d.firstElementChild;if(l)try{n.parentNode.replaceChild(l,n)}catch(e){}continue}if(!e.attrs)continue;const r=n.tagName.toLowerCase(),a={},s=n.attributes;for(let e=0;e<s.length;e++)"data-hydrate-id"!==s[e].name&&(a[s[e].name]=s[e].value);for(const t in e.attrs){const n=e.attrs[t];null===n?delete a[t]:a[t]=n}const c=Object.keys(a).map(e=>e+'="'+i(a[e])+'"').join(" "),d=o.has(r),l=d?"":n.innerHTML,u=d?"<"+r+" "+c+">":"<"+r+" "+c+">"+l+"</"+r+">",f=document.createElement("div");f.innerHTML=u;const m=f.firstElementChild;if(m)try{n.parentNode.replaceChild(m,n)}catch(e){}}t.remove()}()}catch(e){}}if("undefined"!=typeof document&&document.addEventListener("alpine:init",function(){if("undefined"==typeof document||!document.querySelectorAll)return;c(document);let e=0;if(document.querySelectorAll("[data-mnfst-prerender-clone]").forEach(t=>{if(t.closest&&t.closest("[data-hydrate]"))return;t.removeAttribute("data-mnfst-prerender-clone");const n=t.previousElementSibling;n&&"TEMPLATE"===n.tagName&&n.hasAttribute("x-if")?(s(n,t),e++):t.remove()}),!e)return;const i=window.Alpine;"function"==typeof i.interceptInit&&i.interceptInit(e=>{n.has(e)&&t.size&&r()}),document.addEventListener("alpine:initialized",o,{once:!0})},{once:!0}),"undefined"!=typeof document)if("loading"===document.readyState){let ve=!1;document.addEventListener("readystatechange",()=>{ve||"loading"===document.readyState||(ve=!0,d())})}else d();if("undefined"!=typeof window&&"undefined"!=typeof document){let _e=null;window.addEventListener("resize",()=>{document.documentElement.classList.add("window-resizing"),_e&&clearTimeout(_e),_e=setTimeout(()=>{document.documentElement.classList.remove("window-resizing"),_e=null},200)},{passive:!0})}const l="latest",u="0.5.327",f="sha384-sv3psmy86c9Ic8pAWVegj9cA16a1bImwlfxLXzn30n7Myw60TiLQGX3DgPBzSiHp",m="manifest.modules.integrity.json",p="manifest.vendor.integrity.json";let w=null,g=null,h=!1,y=null,v=l,_=["https://cdn.manifestx.dev/npm","https://cdn.jsdelivr.net/npm","https://unpkg.com"];function b(e,t){return e.includes("unpkg.com")?t.replace(/\.min\.js$/,".js"):t}function $(e=l,t=_[0]){return`${t}/mnfst@${e}/lib`}const E=["components","router","utilities","data","icons","localization","markdown","svg","code","color","toasts","tooltips","dropdowns","combobox","computed","tabs","slides","colorpicker","datepicker","charts","url-parameters","virtual","export","status"],L=["defer","bindings"],k=["edit"],S=["appwrite-auth","appwrite-data","appwrite-presences"],A=["rich-text","submissions"],M={"appwrite-data":["data"],"appwrite-presences":["data","appwrite-auth"],device:["utilities"],edit:["rich-text"]};let j=null;let x=[];function P(e,t=v){const n=e.replace(/-/g,".");if(j){return[`${j.replace(/\/$/,"")}/manifest.${n}.js`]}return _.map(e=>`${$(t,e)}/${b(e,`manifest.${n}.min.js`)}`)}function C(e,t=v){return P(e,t)[0]}function I(e){if(e&&(e.startsWith("http")||e.startsWith("/")))return[e];const t=e||"3.17.5";return _.map(e=>`${e}/alpinejs@${t}/dist/cdn.min.js`)}function N(e){if(function(){if("complete"===document.readyState)return!0;if("loading"===document.readyState)return!1;try{const e=performance.getEntriesByType("navigation")[0];if(e)return e.domContentLoadedEventEnd>0}catch(e){}return!1}())return void e();let t=!1;const n=()=>{t||(t=!0,e())};document.addEventListener("DOMContentLoaded",n,{once:!0}),window.addEventListener("load",n,{once:!0})}function R(t){if(t.hasAttribute("data-mnfst-loaded"))return!0;if(t.hasAttribute("data-mnfst-loading"))return!1;if("complete"===document.readyState)return!0;if(!t.async&&!t.defer&&e&&e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_PRECEDING)return!0;try{if(t.src&&performance.getEntriesByName(t.src).length)return!0}catch(e){}return!1}function T(e,t,n=!0,i=null){return new Promise((o,r)=>{const a=document.querySelector(`script[src="${e}"]`);if(a){if(R(a))return o();let t=!1;const n=()=>{t||(t=!0,o())};a.addEventListener("load",n),a.addEventListener("error",()=>{t||(t=!0,r(new Error(`Failed to load ${e}`)))});const i=setInterval(()=>{R(a)&&(clearInterval(i),n())},50);return void setTimeout(()=>{clearInterval(i),n()},4e3)}const s=document.createElement("script");t&&(s.integrity=t,s.crossOrigin="anonymous"),i&&s.setAttribute("fetchpriority",i),s.src=e,s.async=!n,s.setAttribute("data-mnfst-loading",""),s.onload=()=>{s.removeAttribute("data-mnfst-loading"),s.setAttribute("data-mnfst-loaded",""),o()},s.onerror=()=>{s.removeAttribute("data-mnfst-loading"),s.remove(),r(new Error(`Failed to load ${e}`))},document.head.appendChild(s)})}function q(e){return e.split(/[?#]/)[0].split("/").pop()}function O(e){const t=e.match(/(alpinejs@[^/]+\/dist\/cdn\.min\.js)(?:[?#]|$)/);return t?t[1]:null}function W(e){try{const t=performance.getEntriesByName(new URL(e,location.href).href).pop();return!!t&&200===t.responseStatus}catch(e){return!1}}function z(e,t){if("warn"!==w)throw console.error(`[Manifest Loader] ${e} ${t} data-integrity="warn" loads it unchecked instead.`),Object.assign(new Error(e),{logged:!0});console.warn(`[Manifest Loader] ${e} Loading unchecked (data-integrity="warn").`)}async function U(e,t,n){for(const i of e){try{const e=await fetch(i,t?{integrity:t,mode:"cors",credentials:"omit"}:{mode:"cors",credentials:"omit"});if(e.ok)return e}catch(e){}console.error(`[Manifest Loader] ${n} failed to load${t?" or failed its integrity check":""} from ${i}`)}throw new Error(`${n} could not be ${t?"verified":"loaded"} from any CDN${t?` (expected ${t})`:""}.`)}let D=null;const B=/^sha(256|384|512)-[A-Za-z0-9+/=]+$/;function F(e,t){const n=e&&Object.prototype.hasOwnProperty.call(e,t)?e[t]:null;return"string"==typeof n&&B.test(n)?n:null}async function H(e,t){const n=F(e,t);if(n)return n;const i=F(e,p);return i&&/\/(languages|langs)\//.test(t)?(D||(D=U(_.map(e=>`${$(u,e)}/${p}`),i,p).then(e=>e.json()).catch(e=>{throw D=null,e})),F(await D,t)):null}async function V(e,{key:t=null,hash:n=null,alpine:i=!1,unchecked:o=!1,ordered:r=!0,priority:a=null}={}){const s=g&&!o?await g:null,c=t||q(e[0]||"");let d=null;for(const o of e){let c=n;if(s){const e=t||(i?O(o):q(o));c=e&&await H(s,e)||(i?y:null),c||(i?z(`No integrity hash is known for Alpine at ${o}. Add data-alpine-integrity="sha384-…" for it, or remove data-alpine to use the default.`,"Alpine was not loaded."):z(`${e||o} has no integrity hash in this release.`,"Not loaded."))}try{return await T(o,c,r,a)}catch(t){d=t,c?console.error(`[Manifest Loader] ${q(o)} ${W(o)?"failed its integrity check":"failed to load or failed its integrity check"} from ${o}${e.length>1?" — trying next CDN":""}`):e.length>1&&console.warn(`[Manifest Loader] ${o} failed — trying fallback CDN`)}}throw s&&console.error(`[Manifest Loader] ${c} did not match its integrity hash on any CDN — not loaded.`),d||new Error(`Failed to load ${c}`)}const X=new Map;async function Z(e,t=v){const n=X.get(e);if(n)return n.version!==t&&console.warn(`[Manifest Loader] ${e} already loaded at ${n.version} — ignoring request for ${t}`),n.promise;const i=async function(e,t){let n=!1;h&&t!==u&&(z(`Integrity checks cover this loader's own version (${u}); ${e} was requested at ${t}.`,"Not loaded."),n=!0);const i=["components","data","localization"].includes(e)?"high":null;return V(P(e,t),{unchecked:n,priority:i})}(e,t);return X.set(e,{version:t,promise:i}),i.catch(()=>X.delete(e)),i}function G(e){const t=[],n=new Set,i={native:"device",import:"export"};function o(e){if(e=i[e]||e,n.has(e))return;const r=M[e];if(r)for(const e of r)n.has(e)||o(e);t.push(e),n.add(e)}for(const t of e)o(t);return t}const J=[{magic:"$chat",plugin:"chat"},{magic:"$presence",plugin:"appwrite-presences"},{magic:"$rich",plugin:"rich-text",attr:"x-rich-text"},{plugin:"submissions",attr:"x-submit"},...["$share","$secure","$links","$push","$app","$haptics","$biometric","$camera"].map(e=>({magic:e,plugin:"device"}))].map(e=>({...e,re:e.magic?new RegExp("\\"+e.magic+"\\b"):null}));let Q=!1;!function(){if("undefined"==typeof window||"undefined"==typeof document||Q)return;Q=!0;const e=()=>{const e=window.Alpine;if(window.ManifestRichText||!e||!e.magic||!e.reactive||window.__manifestRichStub)return;const t=window.__manifestRichStub=e.reactive({v:0}),n=window.__manifestRichStubWrites=[],i=new WeakMap,o=e=>e&&"function"==typeof e.deref?e.deref():e,r={value:"",link:"",selection:null,all:{},active:()=>!1,can:()=>!1,markdown:()=>"",html:()=>""};e.magic("rich",(e,a)=>(t.v,window.__manifestRichMagic?window.__manifestRichMagic(e,a):(e=>(i.has(e)||i.set(e,new Proxy(r,{get:(t,i)=>{const r=n.find(t=>o(t[0])===e&&t[1]===i);return r?r[2]:i in t?t[i]:"string"==typeof i?()=>{}:void 0},set:(t,i,r)=>{for(let t=n.length-1;t>=0;t--){const r=o(n[t][0]);r&&r.isConnected&&(r!==e||n[t][1]!==i)||n.splice(t,1)}return n.push(["function"==typeof WeakRef?new WeakRef(e):e,i,r]),!0}})),i.get(e)))(e)))};document.addEventListener("alpine:init",e,{once:!0}),window.Alpine&&window.Alpine.magic&&e()}();let K=!1;!function(){if("undefined"==typeof window||"undefined"==typeof document||K)return;K=!0;const e=()=>{const e=window.Alpine;if(window.__manifestEditMagic||!e||!e.magic||!e.reactive||window.__manifestEditStub)return;const t=window.__manifestEditStub=e.reactive({v:0}),n=()=>!1,i=window.__manifestEditStubWrites={},o=new Proxy({active:!1,canUndo:!1,canRedo:!1,version:0,stale:[],conflicts:[],onPublish:null,target:null,can:n,scope:()=>null,block:()=>null,patches:()=>[],export:()=>({log:[],cursor:0}),publish:()=>Promise.resolve({results:[]}),undo:()=>Promise.resolve(!1),redo:()=>Promise.resolve(!1),classes:new Proxy({},{get:()=>n})},{get:(e,t)=>t in i?i[t]:t in e?e[t]:"string"==typeof t?n:void 0,set:(e,t,n)=>(i[t]=n,!0)});e.magic("edit",(e,n)=>(t.v,window.__manifestEditMagic?window.__manifestEditMagic(e,n):o))};document.addEventListener("alpine:init",e,{once:!0}),window.Alpine&&window.Alpine.magic&&e()}(),"undefined"!=typeof document&&document.addEventListener("alpine:initialized",()=>{window.__manifestAlpineStarted=!0},{once:!0});const Y=/^x-(code|code-group)$/,ee=new RegExp("\\$("+J.filter(e=>e.magic).map(e=>e.magic.slice(1)).join("|")+")\\b"),te=new Set;function ne(e,t=("undefined"==typeof document?null:document)){const n=J.filter(t=>!e.includes(t.plugin)),i=!e.includes("components");if(0===n.length&&!i||!t)return[];const o=new Set,r=new Set(n.map(e=>e.plugin)).size+(i?1:0),a=()=>o.size===r;for(const e of t.querySelectorAll("script:not([src])")){const t=e.textContent||"";for(const e of n)e.re&&!o.has(e.plugin)&&e.re.test(t)&&o.add(e.plugin);if(a())return[...o]}const s=e=>{if(i&&!o.has("components")){const t=e.tagName.toLowerCase();t.startsWith("x-")&&!Y.test(t)&&o.add("components")}for(const t of e.attributes||[]){for(const e of n)e.attr&&!o.has(e.plugin)&&(t.name===e.attr||t.name.startsWith(e.attr+"-")||t.name.startsWith(e.attr+"."))&&o.add(e.plugin);const e=t.value;if(e&&-1!==e.indexOf("$")&&!te.has(e))if(ee.test(e))for(const t of n)t.re&&!o.has(t.plugin)&&t.re.test(e)&&o.add(t.plugin);else te.size>2e4&&te.clear(),te.add(e)}},c=e=>{for(const t of e.querySelectorAll("*")){if(s(t),a())return;if("TEMPLATE"===t.tagName&&t.content&&(c(t.content),a()))return}};return 1===t.nodeType&&(s(t),"TEMPLATE"===t.tagName&&t.content&&c(t.content)),a()||c(t),[...o]}let ie=!1;const oe=new Set,re=e=>X.has(e)||oe.has(e);function ae(e,t=v){if(!ie||!e||"undefined"==typeof document)return Promise.resolve([]);let n=e;if("string"==typeof e){if(-1===e.indexOf("x-")&&-1===e.indexOf("$"))return Promise.resolve([]);n=document.createElement("template"),n.innerHTML=e,n=n.content}const i=ne([...new Set(J.map(e=>e.plugin))].filter(re).concat("components",x),n);if(!i.length)return Promise.resolve([]);const o=G(i).filter(e=>!re(e));return Promise.all(o.map(e=>Z(e,t).catch(t=>{oe.has(e)||(oe.add(e),console.warn(`[Manifest Loader] Failed to load plugin ${e}:`,t))}))).then(()=>o)}function se(e){if("undefined"==typeof MutationObserver)return;const t=new Set;let n=!1;const i=new MutationObserver(o=>{for(const e of o)for(const n of e.addedNodes)1===n.nodeType&&t.add(n);!n&&t.size&&(n=!0,setTimeout(()=>{n=!1;const o=[...t].filter(e=>e.isConnected);t.clear(),o.forEach(t=>ae(t,e)),J.every(e=>re(e.plugin)||x.includes(e.plugin))&&i.disconnect()},0))});i.observe(document.documentElement,{childList:!0,subtree:!0})}const ce={"text-edit":"rich-text"};function de(e){return e.filter(e=>{const t=e.replace(/^\+/,"");return!ce[t]||(console.warn(`[Manifest Loader] ${t} was renamed to ${ce[t]}`),!1)})}async function le(e=v){const t=_.map(t=>`${$(e,t)}/${b(t,"manifest.tailwind.min.js")}`);let n=null;try{return await V(t)}catch(e){n=e}throw console.warn('[Manifest Loader] Tailwind plugin not available from any CDN. Load it directly: <script src="/scripts/tailwind.v4.3.1.js"><\/script>'),n||new Error("Tailwind plugin not available from CDN.")}window.Manifest={loadPlugin:function(e,t=v){if(![...E,...A,...S,...k,"payments","chat","device","native","import","tailwind"].includes(e))return ce[e]?de([e]):console.warn(`[Manifest Loader] Unknown module: ${e}`),Promise.reject(new Error(`Unknown module: ${e}`));const n=G([e]);return Promise.all(n.map(e=>Z(e,t)))},loadTailwind:le,loadVendor:function(e,t){return V(_.map(t=>`${t}/${e}`),{key:e,hash:t,ordered:!1})},fetchVendor:async function(e,t){const n=g?await g:null;let i=t||null;return n&&(i=await H(n,e),i||z(`${e} has no integrity hash in this release.`,"Not loaded.")),U(_.map(t=>`${t}/${e}`),i,e)},get integrity(){return h},getPluginUrl:C,getModuleUrl:C,loadUsed:ae},window.Manifest.loadModule=window.Manifest.loadPlugin;const ue="/sw.js";const fe={registered:!1,version:null,kill:()=>me(null)};async function me(e){fe.registered=!1;try{const t=e||await navigator.serviceWorker.getRegistration(ue);if(t){const e=t.active||t.waiting||t.installing;try{e&&e.postMessage({type:"manifest:sw",action:"kill"})}catch(e){}await t.unregister()}}catch(e){}try{if(window.caches){const e=await caches.keys();await Promise.all(e.filter(e=>e.startsWith("mnfst-sw:")).map(e=>caches.delete(e)))}}catch(e){}}async function pe(e){const t=e.sw,n="on"===t,i=n?(...e)=>console.info("[Manifest SW]",...e):()=>{};if(!navigator.serviceWorker)return i("skip: unsupported");const o=window.location,r=!!window.__mnfstRun,a=function(e){const t=String(e||"").toLowerCase();return"localhost"===t||"127.0.0.1"===t||"[::1]"===t||"::1"===t||"0.0.0.0"===t||t.endsWith(".localhost")||t.endsWith(".local")}(o.hostname);let s=window.__manifestLoaded||null;if(!s&&window.__manifestPromise&&(s=await window.__manifestPromise.catch(()=>null)),!s){const e=document.querySelector('link[rel="manifest"]')?.getAttribute("href")||"/manifest.json";s=await fetch(e).then(e=>e.ok?e.json():null).catch(()=>null)}const c="off"===t||s&&!1===s.sw,d=await navigator.serviceWorker.getRegistration(ue).catch(()=>null);if(c||r||a&&!n)return i("skip:",c?"kill switch":r?"mnfst-run":"dev origin",d?"(unregistering)":""),void await me(d);if(!("https:"===o.protocol||n&&window.isSecureContext))return i("skip: not https");let l=null;try{l=sessionStorage.getItem("manifest:sw-probe")}catch(e){}const u="strict"===w;if("ok"!==l||u){const e=await fetch(ue,{cache:"no-store"}).catch(()=>null),t=e&&e.headers.get("content-type")||"";if(!e||!e.ok||!/javascript|ecmascript/i.test(t))return i("skip: no stub",e&&e.status,t);if(u&&(f=await e.text().catch(()=>""),(String(f).match(/importScripts\s*\(([^)]*)\)/g)||[]).some(e=>(e.match(/https?:\/\/[^'"`\s)]+/g)||[]).some(e=>{try{return new URL(e).origin!==location.origin}catch(e){return!0}}))))return console.warn(`[Manifest Loader] ${ue} imports its worker module from another origin, which integrity checks can't cover, so the service worker stays off. Serve the module from this origin (copy lib/manifest.sw.min.js into ${ue}), set data-sw="off", or set data-integrity="warn" to register it anyway.`),void await me(d);try{sessionStorage.setItem("manifest:sw-probe","ok")}catch(e){}}var f;const m=s&&"string"==typeof s.deployment?s.deployment:"",p=`${ue}?v=${encodeURIComponent(e.version)}&d=${encodeURIComponent(m)}`,g=await navigator.serviceWorker.register(p,{scope:"/"});fe.registered=!0,fe.version=e.version,i("registered",p,g.active?"active":g.installing?"installing":"waiting")}window.Manifest.swStub=function(e=l){const t=`mnfst@${String(e||l).replace(/[^\w.+-]/g,"")}/lib/manifest.sw.min.js`;return`try { importScripts('https://cdn.manifestx.dev/npm/${t}'); } catch (e) { importScripts('https://cdn.jsdelivr.net/npm/${t}'); }\nif (!self.__mnfstSw) self.addEventListener('activate', function () { self.registration.unregister(); });\n`},window.Manifest.sw=fe;const we=function(){let e=document.currentScript;if(e||(e=document.querySelector('script[src*="manifest.js"]')),!e)return null;const t=e.getAttribute("data-modules")??e.getAttribute("data-plugins"),n=e.getAttribute("data-omit"),i=null!==e.getAttribute("data-tailwind"),o=e.getAttribute("data-version")||l,r=!!e.getAttribute("data-version"),a=e.getAttribute("data-alpine"),s=(e.getAttribute("data-integrity")??"").trim().toLowerCase(),c=/^(off|false)$/.test(s)?null:"warn"===s?"warn":e.hasAttribute("data-integrity")||e.getAttribute("integrity")?"strict":null,d=e.getAttribute("data-module-base")??e.getAttribute("data-plugin-base"),u=e.getAttribute("data-cdn"),f=e.getAttribute("data-sw");let m=[],p=[],w=!t;if(t){const e=de(t.split(",").map(e=>e.trim()).filter(e=>e));p=e.filter(e=>e.startsWith("+")).map(e=>e.slice(1));const n=e.filter(e=>!e.startsWith("+"));n.length>0?m=[...n,...p]:(w=!0,m=E.slice())}else m=E.slice();const g={native:"device","text-edit":"rich-text"},h=n?n.split(",").map(e=>e.trim().toLowerCase()).map(e=>g[e]||e).filter(e=>e&&!L.includes(e)):[];return h.length>0&&m.length>0&&(m=m.filter(e=>!h.includes(e))),m=G(m),{plugins:m,extraPlugins:p,omitted:h,deriveFromManifest:w,tailwind:i,version:o,versionSet:r,alpine:a,alpineIntegrity:e.getAttribute("data-alpine-integrity"),integrity:c,pluginBase:d,cdn:u,sw:f}}();var ge;if(we&&we.version&&(v=we.version),we&&we.pluginBase&&(ge=we.pluginBase,j=ge||null),we&&we.omitted&&(x=we.omitted),we&&we.cdn&&function(e){if(!e)return;const t=e.split(",").map(e=>e.trim().replace(/\/$/,"")).filter(Boolean);t.length&&(_=t)}(we.cdn),we&&we.integrity&&(w=we.integrity,!we.versionSet&&f&&(v=we.version=u),h=we.version===u,y=we.alpineIntegrity&&B.test(we.alpineIntegrity.trim())?we.alpineIntegrity.trim():null,g=async function(e){if(e.version!==u)return z(`Integrity checks cover this loader's own version (${u}), but data-version is "${e.version}". Set data-version="${u}" or remove it.`,"No modules were loaded."),null;const t=j?[`${j.replace(/\/$/,"")}/${m}`]:_.map(e=>`${$(u,e)}/${m}`);try{return await(await U(t,f,m)).json()}catch(e){throw new Error(`${e.message} No modules were loaded.`)}}(we),g.catch(()=>{})),function(e){if(!e||window.__manifestSwArmed)return;const t=window.__manifestSwArmed={};let n=!1;const i=()=>{if(!n&&window.__manifestSwArmed===t){n=!0;try{pe(e).catch(()=>{})}catch(e){}}};setTimeout(()=>{if(window.__manifestReady)return i();window.addEventListener("manifest:ready",i,{once:!0}),window.__manifestLoaderStarted||("complete"===document.readyState?setTimeout(i,0):window.addEventListener("load",i,{once:!0}))},0)}(we),we&&we.plugins.length>0){if(window.__manifestLoaderStarted)return;window.__manifestLoaderStarted=!0;const be=["data","localization","components","appwrite-auth","appwrite-data","appwrite-presences","payments","chat"],$e=document.querySelector('link[rel="manifest"]')?.getAttribute("href")||"/manifest.json",Ee=new Set,Le=e=>{if(null===e||"object"!=typeof e)return;const t=e=>e.replace(/\$\{([^}]+)\}/g,(e,t)=>"undefined"!=typeof window&&window.env&&void 0!==window.env[t]?window.env[t]:(Ee.has(t)||(Ee.add(t),t.startsWith("PUBLIC_")?console.warn(`[Manifest] manifest.json references \${${t}}, but it is not present in window.env. Add ${t}=… to .env (read by mnfst-run) or set it via <script>window.env = {…}<\/script>. Leaving placeholder literal.`):console.warn(`[Manifest] manifest.json references \${${t}}, but only PUBLIC_-prefixed env vars are injected into window.env by mnfst-run. Rename to PUBLIC_${t}, hardcode the value, or supply it via <script>window.env = {…}<\/script>. Leaving placeholder literal.`)),e)),n=e=>{if(Array.isArray(e))for(let i=0;i<e.length;i++){const o=e[i];"string"==typeof o?e[i]=t(o):o&&"object"==typeof o&&n(o)}else for(const i of Object.keys(e)){const o=e[i];"string"==typeof o?e[i]=t(o):o&&"object"==typeof o&&n(o)}};n(e)},ke=()=>window.__manifestLoaded?Promise.resolve(window.__manifestLoaded):(window.__manifestPromise||(window.__manifestPromise=fetch($e).then(e=>e.ok?e.json():null).then(e=>(e&&!e.__interpolated&&(Le(e),Object.defineProperty(e,"__interpolated",{value:!0,enumerable:!1})),e)).catch(()=>null)),window.__manifestPromise),Se=async()=>{if(g){(we.deriveFromManifest||we.plugins.some(e=>be.includes(e)))&&ke();try{await g}catch(e){return void(e.logged||console.error(`[Manifest Loader] ${e.message}`))}}let e=null,t=we.plugins,n=null;if(we.deriveFromManifest){e=await ke();const n=function(e){if(!e||"object"!=typeof e)return E.slice();const t=e.data&&"object"==typeof e.data&&Object.keys(e.data).length>0,n=e.components?.length>0||e.preloadedComponents?.length>0,i=(()=>{if(!e.data||"object"!=typeof e.data)return!1;for(const t of Object.values(e.data))if(t&&"object"==typeof t){if("string"==typeof t.locales)return!0;for(const e of Object.keys(t))if(!["url","headers","params","transform","defaultValue","locales"].includes(e)&&/^[a-zA-Z]{2}(-[a-zA-Z]{2})?$/.test(e))return!0}return!1})(),o=e.status&&"object"==typeof e.status&&Object.keys(e.status).length>0;return E.filter(e=>"data"===e?t:"localization"===e?i:"components"===e?n:"status"!==e||o)}(e),o=function(e){if(!e||"object"!=typeof e)return[];if(!(e.appwrite||e.data&&Object.values(e.data).some(e=>e&&"object"==typeof e&&(e.appwriteTableId||e.appwriteDatabaseId||e.appwriteBucketId))))return[];const t=[];return e.appwrite?.auth&&t.push("appwrite-auth"),(e.appwrite||e.data&&Object.values(e.data).some(e=>e&&"object"==typeof e&&e.appwriteTableId))&&t.push("appwrite-data"),(e.appwrite?.presence||e.appwrite?.presences)&&t.push("appwrite-presences"),t}(e),r=function(e){return e&&"object"==typeof e&&e.payments&&"object"==typeof e.payments?["payments"]:[]}(e),a=function(e){return e&&"object"==typeof e&&(e.ai||e.chat)?["chat"]:[]}(e),s=function(e){if("undefined"!=typeof window&&window.Capacitor)return["device"];const t=e&&"object"==typeof e?e.device??e.native:null;return t&&"object"==typeof t?["device"]:[]}(e);t=G([...L,...(i=[...n,...o,...r,...a,...s,...we.extraPlugins||[]],x.length?i.filter(e=>!x.includes(e)):i)])}else{t=G([...L,...t.filter(e=>!L.includes(e))]);we.plugins.some(e=>be.includes(e))&&(n=ke()),"undefined"!=typeof window&&window.Capacitor&&!t.includes("device")&&(t=G([...t,"device"]))}var i;const o=t.map(e=>Z(e,we.version).catch(t=>{console.warn(`[Manifest Loader] Failed to load plugin ${e}:`,t)}));we.tailwind&&!function(){try{return!!document.querySelector("style[data-mnfst-utilities][data-mnfst-utilities-complete]")}catch(e){return!1}}()&&o.push(le(we.version).catch(()=>{})),await Promise.all(o),n&&(e=await n),e&&"undefined"!=typeof window&&(window.__manifestLoaded=e,window.ManifestComponentsRegistry&&(window.ManifestComponentsRegistry.manifest=e)),N(async()=>{if(we.deriveFromManifest){try{const e=x.length?ne(t).filter(e=>x.includes(e)):[];e.length&&console.warn(`[Manifest Loader] data-omit lists ${e.join(", ")}, but this page uses ${e.length>1?"them":"it"}. Not loaded: remove ${e.length>1?"them":"it"} from data-omit to load.`);const n=ne([...t,...x]);if(n.length>0){const e=G(n).filter(e=>!t.includes(e));await Promise.all(e.map(e=>Z(e,we.version).catch(t=>{oe.add(e),console.warn(`[Manifest Loader] Failed to load plugin ${e}:`,t)})))}}catch(e){}ie=!0,se(we.version)}var e;Ae(t,we.tailwind),e=I(we.alpine),N(()=>{window.Alpine||document.querySelector('script[src*="alpinejs"]')||V(e,{alpine:!0}).catch(e=>{e.logged||console.error("[Manifest Loader] Alpine.js failed to load from all CDNs.")})})})};function Ae(e,t){if(window.__manifestReadyCoordinator)return;window.__manifestReadyCoordinator=!0;const n=window.ManifestPending.hold("ready"),i=!!t,o={data:!e.some(e=>"data"===e||"appwrite-data"===e)||!!window.__manifestRenderReady,utilities:!i||!!window.__manifestUtilitiesReady};let r=!1,a=null;const s=()=>!(window.__manifestMarkdownPending>0),c=()=>!(window.__manifestUtilitiesPending>0),d=()=>{r||(r=!0,n(),window.__manifestReady=!0,window.dispatchEvent(new CustomEvent("manifest:ready")))},l=()=>{r||o.data&&o.utilities&&s()&&c()&&(clearTimeout(a),a=setTimeout(()=>{o.data&&o.utilities&&s()&&c()&&d()},300))};window.addEventListener("manifest:render-ready",()=>{o.data=!0,l()}),window.addEventListener("manifest:utilities-ready",()=>{o.utilities=!0,l()}),window.addEventListener("manifest:utilities-idle",l),window.addEventListener("manifest:markdown-idle",l),setTimeout(d,15e3),l()}(()=>{if(g||!document.head||!0===window.__manifestRender)return;const e=new Set,t=(t,n,i)=>{if(!n||e.has(t+n))return;e.add(t+n);const o=document.createElement("link");o.rel=t,i&&(o.as=i,o.setAttribute("fetchpriority","low")),o.href=n,o.setAttribute("data-mnfst-hint",""),document.head.appendChild(o)};document.addEventListener("alpine:init",()=>{document.head.querySelectorAll("link[data-mnfst-hint]").forEach(e=>e.remove())},{once:!0});try{(we.deriveFromManifest||we.plugins.some(e=>be.includes(e)))&&ke();const e=j?null:_[0];if(e&&new URL(e,location.href).origin!==location.origin&&t("preconnect",new URL(e,location.href).origin),we.deriveFromManifest){const e=["data","localization","components","status"];for(const n of[...L,...we.plugins])e.includes(n)||t("preload",C(n,we.version),"script")}N(()=>{try{window.Alpine||document.querySelector('script[src*="alpinejs"]')||t("preload",I(we.alpine)[0],"script")}catch(e){}})}catch(e){}})(),Se()}}();
1
+ !function(){"use strict";const e=document.currentScript;if(!window.ManifestPending){const he=new Map;let ye=0;window.ManifestPending={hold(e="work"){const t=++ye;return he.set(t,e),()=>{he.delete(t)}},get count(){return he.size+(window.__manifestMarkdownPending||0)+(window.__manifestUtilitiesPending||0)},labels(){const e=[...he.values()];return window.__manifestMarkdownPending>0&&e.push("markdown"),window.__manifestUtilitiesPending>0&&e.push("utilities"),e},background:e=>("function"==typeof e&&(e.__manifestBackground=!0),e)}}const t=new Set,n=new WeakSet;let i=!1;function o(){for(const e of[...t])e.settle()}function r(){i||(i=!0,queueMicrotask(()=>{i=!1,o()}))}function a(e){for(let t=e.parentNode;t;t=t.parentNode)if(t._x_ignore)return!0;return!1}function s(e,i){const s=window.Alpine,c=e.getAttribute("x-if");let d=!e.closest("[x-data],[x-init]"),l=!1,u=null;const f=()=>!!s.evaluate(e,c),m=()=>{u&&(u(),u=null)},p=()=>{t.delete(y),m()},w=()=>{d=!1,l=!1,m(),i._x_ignore=!0,t.add(y)},g=()=>{p(),s.mutateDom(()=>{s.destroyTree(i),i.remove()}),delete e._x_currentIfEl,delete e._x_lastRenderedEl,r()},h=()=>{d||e._x_currentIfEl!==i||!i.isConnected||a(e)||(d=!0,l=!1,p(),delete i._x_ignore,s.initTree(i),o())},y={settle(){if(!d&&!l)return e._x_currentIfEl!==i?p():void(i.isConnected?e._x_marker&&!a(e)&&f()&&h():i.getRootNode()instanceof DocumentFragment||p())}},v=()=>window.__manifestReady||!window.__manifestReadyCoordinator?g():(queueMicrotask(()=>{e._x_currentIfEl===i&&(e._x_undoIf=v,(()=>{if(u||!l||e._x_currentIfEl!==i||a(e))return;const t=s.evaluateLater(e,c),n=s.effect(()=>t(e=>{e&&queueMicrotask(()=>{l&&f()&&h()})}));u=()=>s.release(n)})())}),a(e)?w():(d&&(d=!1,i._x_ignore=!0,s.destroyTree(i),t.add(y)),void(l||(l=!0,window.addEventListener("manifest:ready",()=>{if(l&&e._x_currentIfEl===i){if(e.isConnected&&a(e))return w();if(e.isConnected&&f())return h();g(),delete e._x_undoIf}},{once:!0})))));e._x_currentIfEl=i,e._x_lastRenderedEl=i,e._x_undoIf=v,n.add(e),d||(i._x_ignore=!0,t.add(y))}function c(e,t){e.querySelectorAll("template").forEach(e=>{const n=t||e.matches("[x-if],[x-for]");n&&e.content.querySelectorAll("[data-pre-rendered]").forEach(e=>{e.tagName.startsWith("X-")&&e.removeAttribute("data-pre-rendered")}),c(e.content,n)})}function d(){try{!function(){if("undefined"==typeof document||!document.querySelector)return;const e=document.querySelector('meta[name="manifest:prerendered"]');if(!e||"0"===e.getAttribute("content"))return;const t=document.getElementById("__manifest_hydrate__");if(!t)return;let n;try{n=JSON.parse(t.textContent||"[]")}catch(e){n=[]}if(!Array.isArray(n)||0===n.length)return void t.remove();const i=e=>String(null==e?"":e).replace(/&/g,"&amp;").replace(/"/g,"&quot;"),o=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),r=[];for(const e of n){const t=document.querySelector('[data-hydrate-id="'+e.id+'"]');if(!t)continue;let n=0;for(let e=t.parentNode;e;e=e.parentNode)n++;r.push({entry:e,el:t,depth:n})}r.sort((e,t)=>t.depth-e.depth);for(const{entry:e,el:t}of r){const n=document.querySelector('[data-hydrate-id="'+e.id+'"]')||t;if(!n||!n.parentNode)continue;if("string"==typeof e.html){const t=n.tagName.toLowerCase(),r={},a=n.attributes;for(let e=0;e<a.length;e++)"data-hydrate-id"!==a[e].name&&(r[a[e].name]=a[e].value);if(e.attrs)for(const t in e.attrs){const n=e.attrs[t];null===n?delete r[t]:r[t]=n}const s=Object.keys(r).map(e=>e+'="'+i(r[e])+'"').join(" "),c=o.has(t)?"<"+t+" "+s+">":"<"+t+" "+s+">"+e.html+"</"+t+">",d=document.createElement("div");d.innerHTML=c;const l=d.firstElementChild;if(l)try{n.parentNode.replaceChild(l,n)}catch(e){}continue}if(!e.attrs)continue;const r=n.tagName.toLowerCase(),a={},s=n.attributes;for(let e=0;e<s.length;e++)"data-hydrate-id"!==s[e].name&&(a[s[e].name]=s[e].value);for(const t in e.attrs){const n=e.attrs[t];null===n?delete a[t]:a[t]=n}const c=Object.keys(a).map(e=>e+'="'+i(a[e])+'"').join(" "),d=o.has(r),l=d?"":n.innerHTML,u=d?"<"+r+" "+c+">":"<"+r+" "+c+">"+l+"</"+r+">",f=document.createElement("div");f.innerHTML=u;const m=f.firstElementChild;if(m)try{n.parentNode.replaceChild(m,n)}catch(e){}}t.remove()}()}catch(e){}}if("undefined"!=typeof document&&document.addEventListener("alpine:init",function(){if("undefined"==typeof document||!document.querySelectorAll)return;c(document);let e=0;if(document.querySelectorAll("[data-mnfst-prerender-clone]").forEach(t=>{if(t.closest&&t.closest("[data-hydrate]"))return;t.removeAttribute("data-mnfst-prerender-clone");const n=t.previousElementSibling;n&&"TEMPLATE"===n.tagName&&n.hasAttribute("x-if")?(s(n,t),e++):t.remove()}),!e)return;const i=window.Alpine;"function"==typeof i.interceptInit&&i.interceptInit(e=>{n.has(e)&&t.size&&r()}),document.addEventListener("alpine:initialized",o,{once:!0})},{once:!0}),"undefined"!=typeof document)if("loading"===document.readyState){let ve=!1;document.addEventListener("readystatechange",()=>{ve||"loading"===document.readyState||(ve=!0,d())})}else d();if("undefined"!=typeof window&&"undefined"!=typeof document){let _e=null;window.addEventListener("resize",()=>{document.documentElement.classList.add("window-resizing"),_e&&clearTimeout(_e),_e=setTimeout(()=>{document.documentElement.classList.remove("window-resizing"),_e=null},200)},{passive:!0})}const l="latest",u="0.5.329",f="sha384-7BFrrPv4hAz22nnh6WAq2gQQN75EFMHZc5x0W352e8pubbJuXlbCPiYPR2se2mTe",m="manifest.modules.integrity.json",p="manifest.vendor.integrity.json";let w=null,g=null,h=!1,y=null,v=l,_=["https://cdn.manifestx.dev/npm","https://cdn.jsdelivr.net/npm","https://unpkg.com"];function b(e,t){return e.includes("unpkg.com")?t.replace(/\.min\.js$/,".js"):t}function $(e=l,t=_[0]){return`${t}/mnfst@${e}/lib`}const E=["components","router","utilities","data","icons","localization","markdown","svg","code","color","toasts","tooltips","dropdowns","combobox","computed","tabs","slides","colorpicker","datepicker","charts","url-parameters","virtual","export","status"],k=["defer","bindings"],L=["edit"],S=["appwrite-auth","appwrite-data","appwrite-presences"],A=["rich-text","submissions"],M={"appwrite-data":["data"],"appwrite-presences":["data","appwrite-auth"],device:["utilities"],edit:["rich-text"]};let j=null;let x=[];function P(e,t=v){const n=e.replace(/-/g,".");if(j){return[`${j.replace(/\/$/,"")}/manifest.${n}.js`]}return _.map(e=>`${$(t,e)}/${b(e,`manifest.${n}.min.js`)}`)}function C(e,t=v){return P(e,t)[0]}function N(e){if(e&&(e.startsWith("http")||e.startsWith("/")))return[e];const t=e||"3.17.5";return _.map(e=>`${e}/alpinejs@${t}/dist/cdn.min.js`)}function R(e){if(function(){if("complete"===document.readyState)return!0;if("loading"===document.readyState)return!1;try{const e=performance.getEntriesByType("navigation")[0];if(e)return e.domContentLoadedEventEnd>0}catch(e){}return!1}())return void e();let t=!1;const n=()=>{t||(t=!0,e())};document.addEventListener("DOMContentLoaded",n,{once:!0}),window.addEventListener("load",n,{once:!0})}function I(t){if(t.hasAttribute("data-mnfst-loaded"))return!0;if(t.hasAttribute("data-mnfst-loading"))return!1;if("complete"===document.readyState)return!0;if(!t.async&&!t.defer&&e&&e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_PRECEDING)return!0;try{if(t.src&&performance.getEntriesByName(t.src).length)return!0}catch(e){}return!1}function T(e,t,n=!0,i=null){return new Promise((o,r)=>{const a=document.querySelector(`script[src="${e}"]`);if(a){if(I(a))return o();let t=!1;const n=()=>{t||(t=!0,o())};a.addEventListener("load",n),a.addEventListener("error",()=>{t||(t=!0,r(new Error(`Failed to load ${e}`)))});const i=setInterval(()=>{I(a)&&(clearInterval(i),n())},50);return void setTimeout(()=>{clearInterval(i),n()},4e3)}const s=document.createElement("script");t&&(s.integrity=t,s.crossOrigin="anonymous"),i&&s.setAttribute("fetchpriority",i),s.src=e,s.async=!n,s.setAttribute("data-mnfst-loading",""),s.onload=()=>{s.removeAttribute("data-mnfst-loading"),s.setAttribute("data-mnfst-loaded",""),o()},s.onerror=()=>{s.removeAttribute("data-mnfst-loading"),s.remove(),r(new Error(`Failed to load ${e}`))},document.head.appendChild(s)})}function q(e){return e.split(/[?#]/)[0].split("/").pop()}function W(e){const t=e.match(/(alpinejs@[^/]+\/dist\/cdn\.min\.js)(?:[?#]|$)/);return t?t[1]:null}function O(e){try{const t=performance.getEntriesByName(new URL(e,location.href).href).pop();return!!t&&200===t.responseStatus}catch(e){return!1}}function z(e,t){if("warn"!==w)throw console.error(`[Manifest Loader] ${e} ${t} data-integrity="warn" loads it unchecked instead.`),Object.assign(new Error(e),{logged:!0});console.warn(`[Manifest Loader] ${e} Loading unchecked (data-integrity="warn").`)}async function U(e,t,n){for(const i of e){try{const e=await fetch(i,t?{integrity:t,mode:"cors",credentials:"omit"}:{mode:"cors",credentials:"omit"});if(e.ok)return e}catch(e){}console.error(`[Manifest Loader] ${n} failed to load${t?" or failed its integrity check":""} from ${i}`)}throw new Error(`${n} could not be ${t?"verified":"loaded"} from any CDN${t?` (expected ${t})`:""}.`)}let F=null;const B=/^sha(256|384|512)-[A-Za-z0-9+/=]+$/;function D(e,t){const n=e&&Object.prototype.hasOwnProperty.call(e,t)?e[t]:null;return"string"==typeof n&&B.test(n)?n:null}async function H(e,t){const n=D(e,t);if(n)return n;const i=D(e,p);return i&&/\/(languages|langs)\//.test(t)?(F||(F=U(_.map(e=>`${$(u,e)}/${p}`),i,p).then(e=>e.json()).catch(e=>{throw F=null,e})),D(await F,t)):null}async function Z(e,{key:t=null,hash:n=null,alpine:i=!1,unchecked:o=!1,ordered:r=!0,priority:a=null}={}){const s=g&&!o?await g:null,c=t||q(e[0]||"");let d=null;for(const o of e){let c=n;if(s){const e=t||(i?W(o):q(o));c=e&&await H(s,e)||(i?y:null),c||(i?z(`No integrity hash is known for Alpine at ${o}. Add data-alpine-integrity="sha384-…" for it, or remove data-alpine to use the default.`,"Alpine was not loaded."):z(`${e||o} has no integrity hash in this release.`,"Not loaded."))}try{return await T(o,c,r,a)}catch(t){d=t,c?console.error(`[Manifest Loader] ${q(o)} ${O(o)?"failed its integrity check":"failed to load or failed its integrity check"} from ${o}${e.length>1?" — trying next CDN":""}`):e.length>1&&console.warn(`[Manifest Loader] ${o} failed — trying fallback CDN`)}}throw s&&console.error(`[Manifest Loader] ${c} did not match its integrity hash on any CDN — not loaded.`),d||new Error(`Failed to load ${c}`)}const V=new Map;async function J(e,t=v){const n=V.get(e);if(n)return n.version!==t&&console.warn(`[Manifest Loader] ${e} already loaded at ${n.version} — ignoring request for ${t}`),n.promise;const i=async function(e,t){let n=!1;h&&t!==u&&(z(`Integrity checks cover this loader's own version (${u}); ${e} was requested at ${t}.`,"Not loaded."),n=!0);const i=["components","data","localization"].includes(e)?"high":null;return Z(P(e,t),{unchecked:n,priority:i})}(e,t);return V.set(e,{version:t,promise:i}),i.catch(()=>V.delete(e)),i}function Q(e){const t=[],n=new Set,i={native:"device",import:"export"};function o(e){if(e=i[e]||e,n.has(e))return;const r=M[e];if(r)for(const e of r)n.has(e)||o(e);t.push(e),n.add(e)}for(const t of e)o(t);return t}const X=[{magic:"$chat",plugin:"chat"},{magic:"$presence",plugin:"appwrite-presences"},{magic:"$rich",plugin:"rich-text",attr:"x-rich-text"},{plugin:"submissions",attr:"x-submit"},...["$share","$secure","$links","$push","$app","$haptics","$biometric","$camera"].map(e=>({magic:e,plugin:"device"}))].map(e=>({...e,re:e.magic?new RegExp("\\"+e.magic+"\\b"):null}));let G=!1;!function(){if("undefined"==typeof window||"undefined"==typeof document||G)return;G=!0;const e=()=>{const e=window.Alpine;if(window.ManifestRichText||!e||!e.magic||!e.reactive||window.__manifestRichStub)return;const t=window.__manifestRichStub=e.reactive({v:0}),n=window.__manifestRichStubWrites=[],i=new WeakMap,o=e=>e&&"function"==typeof e.deref?e.deref():e,r={value:"",link:"",selection:null,all:{},active:()=>!1,can:()=>!1,markdown:()=>"",html:()=>""};e.magic("rich",(e,a)=>(t.v,window.__manifestRichMagic?window.__manifestRichMagic(e,a):(e=>(i.has(e)||i.set(e,new Proxy(r,{get:(t,i)=>{const r=n.find(t=>o(t[0])===e&&t[1]===i);return r?r[2]:i in t?t[i]:"string"==typeof i?()=>{}:void 0},set:(t,i,r)=>{for(let t=n.length-1;t>=0;t--){const r=o(n[t][0]);r&&r.isConnected&&(r!==e||n[t][1]!==i)||n.splice(t,1)}return n.push(["function"==typeof WeakRef?new WeakRef(e):e,i,r]),!0}})),i.get(e)))(e)))};document.addEventListener("alpine:init",e,{once:!0}),window.Alpine&&window.Alpine.magic&&e()}();let Y=!1;!function(){if("undefined"==typeof window||"undefined"==typeof document||Y)return;Y=!0;const e=()=>{const e=window.Alpine;if(window.__manifestEditMagic||!e||!e.magic||!e.reactive||window.__manifestEditStub)return;const t=window.__manifestEditStub=e.reactive({v:0}),n=()=>!1,i=window.__manifestEditStubWrites={},o=new Proxy({active:!1,canUndo:!1,canRedo:!1,version:0,stale:[],conflicts:[],onPublish:null,target:null,can:n,scope:()=>null,block:()=>null,patches:()=>[],export:()=>({log:[],cursor:0}),publish:()=>Promise.resolve({results:[]}),undo:()=>Promise.resolve(!1),redo:()=>Promise.resolve(!1),classes:new Proxy({},{get:()=>n})},{get:(e,t)=>t in i?i[t]:t in e?e[t]:"string"==typeof t?n:void 0,set:(e,t,n)=>(i[t]=n,!0)});e.magic("edit",(e,n)=>(t.v,window.__manifestEditMagic?window.__manifestEditMagic(e,n):o))};document.addEventListener("alpine:init",e,{once:!0}),window.Alpine&&window.Alpine.magic&&e()}(),"undefined"!=typeof document&&document.addEventListener("alpine:initialized",()=>{window.__manifestAlpineStarted=!0},{once:!0});const K=/^x-(code|code-group)$/,ee=new RegExp("\\$("+X.filter(e=>e.magic).map(e=>e.magic.slice(1)).join("|")+")\\b"),te=new Set;function ne(e,t=("undefined"==typeof document?null:document)){const n=X.filter(t=>!e.includes(t.plugin)),i=!e.includes("components");if(0===n.length&&!i||!t)return[];const o=new Set,r=new Set(n.map(e=>e.plugin)).size+(i?1:0),a=()=>o.size===r;for(const e of t.querySelectorAll("script:not([src])")){const t=e.textContent||"";for(const e of n)e.re&&!o.has(e.plugin)&&e.re.test(t)&&o.add(e.plugin);if(a())return[...o]}const s=e=>{if(i&&!o.has("components")){const t=e.tagName.toLowerCase();t.startsWith("x-")&&!K.test(t)&&o.add("components")}for(const t of e.attributes||[]){for(const e of n)e.attr&&!o.has(e.plugin)&&(t.name===e.attr||t.name.startsWith(e.attr+"-")||t.name.startsWith(e.attr+"."))&&o.add(e.plugin);const e=t.value;if(e&&-1!==e.indexOf("$")&&!te.has(e))if(ee.test(e))for(const t of n)t.re&&!o.has(t.plugin)&&t.re.test(e)&&o.add(t.plugin);else te.size>2e4&&te.clear(),te.add(e)}},c=e=>{for(const t of e.querySelectorAll("*")){if(s(t),a())return;if("TEMPLATE"===t.tagName&&t.content&&(c(t.content),a()))return}};return 1===t.nodeType&&(s(t),"TEMPLATE"===t.tagName&&t.content&&c(t.content)),a()||c(t),[...o]}let ie=!1;const oe=new Set,re=e=>V.has(e)||oe.has(e);function ae(e,t=v){if(!ie||!e||"undefined"==typeof document)return Promise.resolve([]);let n=e;if("string"==typeof e){if(-1===e.indexOf("x-")&&-1===e.indexOf("$"))return Promise.resolve([]);n=document.createElement("template"),n.innerHTML=e,n=n.content}const i=ne([...new Set(X.map(e=>e.plugin))].filter(re).concat("components",x),n);if(!i.length)return Promise.resolve([]);const o=Q(i).filter(e=>!re(e));return Promise.all(o.map(e=>J(e,t).catch(t=>{oe.has(e)||(oe.add(e),console.warn(`[Manifest Loader] Failed to load plugin ${e}:`,t))}))).then(()=>o)}function se(e){if("undefined"==typeof MutationObserver)return;const t=new Set;let n=!1;const i=new MutationObserver(o=>{for(const e of o)for(const n of e.addedNodes)1===n.nodeType&&t.add(n);!n&&t.size&&(n=!0,setTimeout(()=>{n=!1;const o=[...t].filter(e=>e.isConnected);t.clear(),o.forEach(t=>ae(t,e)),X.every(e=>re(e.plugin)||x.includes(e.plugin))&&i.disconnect()},0))});i.observe(document.documentElement,{childList:!0,subtree:!0})}const ce={"text-edit":"rich-text"};function de(e){return e.filter(e=>{const t=e.replace(/^\+/,"");return!ce[t]||(console.warn(`[Manifest Loader] ${t} was renamed to ${ce[t]}`),!1)})}async function le(e=v){const t=_.map(t=>`${$(e,t)}/${b(t,"manifest.tailwind.min.js")}`);let n=null;try{return await Z(t)}catch(e){n=e}throw console.warn('[Manifest Loader] Tailwind plugin not available from any CDN. Load it directly: <script src="/scripts/tailwind.v4.3.1.js"><\/script>'),n||new Error("Tailwind plugin not available from CDN.")}window.Manifest={loadPlugin:function(e,t=v){if(![...E,...A,...S,...L,"payments","chat","device","native","import","tailwind"].includes(e))return ce[e]?de([e]):console.warn(`[Manifest Loader] Unknown module: ${e}`),Promise.reject(new Error(`Unknown module: ${e}`));const n=Q([e]);return Promise.all(n.map(e=>J(e,t)))},loadTailwind:le,loadVendor:function(e,t){return Z(_.map(t=>`${t}/${e}`),{key:e,hash:t,ordered:!1})},fetchVendor:async function(e,t){const n=g?await g:null;let i=t||null;return n&&(i=await H(n,e),i||z(`${e} has no integrity hash in this release.`,"Not loaded.")),U(_.map(t=>`${t}/${e}`),i,e)},get integrity(){return h},getPluginUrl:C,getModuleUrl:C,loadUsed:ae},window.Manifest.loadModule=window.Manifest.loadPlugin;const ue="/sw.js";const fe={registered:!1,version:null,kill:()=>me(null)};async function me(e){fe.registered=!1;try{const t=e||await navigator.serviceWorker.getRegistration(ue);if(t){const e=t.active||t.waiting||t.installing;try{e&&e.postMessage({type:"manifest:sw",action:"kill"})}catch(e){}await t.unregister()}}catch(e){}try{if(window.caches){const e=await caches.keys();await Promise.all(e.filter(e=>e.startsWith("mnfst-sw:")).map(e=>caches.delete(e)))}}catch(e){}}async function pe(e){const t=e.sw,n="on"===t,i=n?(...e)=>console.info("[Manifest SW]",...e):()=>{};if(!navigator.serviceWorker)return i("skip: unsupported");const o=window.location,r=!!window.__mnfstRun,a=function(e){const t=String(e||"").toLowerCase();return"localhost"===t||"127.0.0.1"===t||"[::1]"===t||"::1"===t||"0.0.0.0"===t||t.endsWith(".localhost")||t.endsWith(".local")}(o.hostname);let s=window.__manifestLoaded||null;if(!s&&window.__manifestPromise&&(s=await window.__manifestPromise.catch(()=>null)),!s){const e=document.querySelector('link[rel="manifest"]')?.getAttribute("href")||"/manifest.json";s=await fetch(e).then(e=>e.ok?e.json():null).catch(()=>null)}const c="off"===t||s&&!1===s.sw,d=await navigator.serviceWorker.getRegistration(ue).catch(()=>null);if(c||r||a&&!n)return i("skip:",c?"kill switch":r?"mnfst-run":"dev origin",d?"(unregistering)":""),void await me(d);if(!("https:"===o.protocol||n&&window.isSecureContext))return i("skip: not https");let l=null;try{l=sessionStorage.getItem("manifest:sw-probe")}catch(e){}const u="strict"===w;if("ok"!==l||u){const e=await fetch(ue,{cache:"no-store"}).catch(()=>null),t=e&&e.headers.get("content-type")||"";if(!e||!e.ok||!/javascript|ecmascript/i.test(t))return i("skip: no stub",e&&e.status,t);if(u&&(f=await e.text().catch(()=>""),(String(f).match(/importScripts\s*\(([^)]*)\)/g)||[]).some(e=>(e.match(/https?:\/\/[^'"`\s)]+/g)||[]).some(e=>{try{return new URL(e).origin!==location.origin}catch(e){return!0}}))))return console.warn(`[Manifest Loader] ${ue} imports its worker module from another origin, which integrity checks can't cover, so the service worker stays off. Serve the module from this origin (copy lib/manifest.sw.min.js into ${ue}), set data-sw="off", or set data-integrity="warn" to register it anyway.`),void await me(d);try{sessionStorage.setItem("manifest:sw-probe","ok")}catch(e){}}var f;const m=s&&"string"==typeof s.deployment?s.deployment:"",p=`${ue}?v=${encodeURIComponent(e.version)}&d=${encodeURIComponent(m)}`,g=await navigator.serviceWorker.register(p,{scope:"/"});fe.registered=!0,fe.version=e.version,i("registered",p,g.active?"active":g.installing?"installing":"waiting")}window.Manifest.swStub=function(e=l){const t=`mnfst@${String(e||l).replace(/[^\w.+-]/g,"")}/lib/manifest.sw.min.js`;return`try { importScripts('https://cdn.manifestx.dev/npm/${t}'); } catch (e) { importScripts('https://cdn.jsdelivr.net/npm/${t}'); }\nif (!self.__mnfstSw) self.addEventListener('activate', function () { self.registration.unregister(); });\n`},window.Manifest.sw=fe;const we=function(){let e=document.currentScript;if(e||(e=document.querySelector('script[src*="manifest.js"]')),!e)return null;const t=e.getAttribute("data-modules")??e.getAttribute("data-plugins"),n=e.getAttribute("data-omit"),i=null!==e.getAttribute("data-tailwind"),o=e.getAttribute("data-version")||l,r=!!e.getAttribute("data-version"),a=e.getAttribute("data-alpine"),s=(e.getAttribute("data-integrity")??"").trim().toLowerCase(),c=/^(off|false)$/.test(s)?null:"warn"===s?"warn":e.hasAttribute("data-integrity")||e.getAttribute("integrity")?"strict":null,d=e.getAttribute("data-module-base")??e.getAttribute("data-plugin-base"),u=e.getAttribute("data-cdn"),f=e.getAttribute("data-sw");let m=[],p=[],w=!t;if(t){const e=de(t.split(",").map(e=>e.trim()).filter(e=>e));p=e.filter(e=>e.startsWith("+")).map(e=>e.slice(1));const n=e.filter(e=>!e.startsWith("+"));n.length>0?m=[...n,...p]:(w=!0,m=E.slice())}else m=E.slice();const g={native:"device","text-edit":"rich-text"},h=n?n.split(",").map(e=>e.trim().toLowerCase()).map(e=>g[e]||e).filter(e=>e&&!k.includes(e)):[];return h.length>0&&m.length>0&&(m=m.filter(e=>!h.includes(e))),m=Q(m),{plugins:m,extraPlugins:p,omitted:h,deriveFromManifest:w,tailwind:i,version:o,versionSet:r,alpine:a,alpineIntegrity:e.getAttribute("data-alpine-integrity"),integrity:c,pluginBase:d,cdn:u,sw:f}}();var ge;if(we&&we.version&&(v=we.version),we&&we.pluginBase&&(ge=we.pluginBase,j=ge||null),we&&we.omitted&&(x=we.omitted),we&&we.cdn&&function(e){if(!e)return;const t=e.split(",").map(e=>e.trim().replace(/\/$/,"")).filter(Boolean);t.length&&(_=t)}(we.cdn),we&&we.integrity&&(w=we.integrity,!we.versionSet&&f&&(v=we.version=u),h=we.version===u,y=we.alpineIntegrity&&B.test(we.alpineIntegrity.trim())?we.alpineIntegrity.trim():null,g=async function(e){if(e.version!==u)return z(`Integrity checks cover this loader's own version (${u}), but data-version is "${e.version}". Set data-version="${u}" or remove it.`,"No modules were loaded."),null;const t=j?[`${j.replace(/\/$/,"")}/${m}`]:_.map(e=>`${$(u,e)}/${m}`);try{return await(await U(t,f,m)).json()}catch(e){throw new Error(`${e.message} No modules were loaded.`)}}(we),g.catch(()=>{})),function(e){if(!e||window.__manifestSwArmed)return;const t=window.__manifestSwArmed={};let n=!1;const i=()=>{if(!n&&window.__manifestSwArmed===t){n=!0;try{pe(e).catch(()=>{})}catch(e){}}};setTimeout(()=>{if(window.__manifestReady)return i();window.addEventListener("manifest:ready",i,{once:!0}),window.__manifestLoaderStarted||("complete"===document.readyState?setTimeout(i,0):window.addEventListener("load",i,{once:!0}))},0)}(we),we&&we.plugins.length>0){if(window.__manifestLoaderStarted)return;window.__manifestLoaderStarted=!0;const be=["data","localization","components","appwrite-auth","appwrite-data","appwrite-presences","payments","chat"],$e=document.querySelector('link[rel="manifest"]')?.getAttribute("href")||"/manifest.json",Ee=new Set,ke=e=>{if(null===e||"object"!=typeof e)return;const t=e=>e.replace(/\$\{([^}]+)\}/g,(e,t)=>"undefined"!=typeof window&&window.env&&void 0!==window.env[t]?window.env[t]:(Ee.has(t)||(Ee.add(t),t.startsWith("PUBLIC_")?console.warn(`[Manifest] manifest.json references \${${t}}, but it is not present in window.env. Add ${t}=… to .env (read by mnfst-run) or set it via <script>window.env = {…}<\/script>. Leaving placeholder literal.`):console.warn(`[Manifest] manifest.json references \${${t}}, but only PUBLIC_-prefixed env vars are injected into window.env by mnfst-run. Rename to PUBLIC_${t}, hardcode the value, or supply it via <script>window.env = {…}<\/script>. Leaving placeholder literal.`)),e)),n=e=>{if(Array.isArray(e))for(let i=0;i<e.length;i++){const o=e[i];"string"==typeof o?e[i]=t(o):o&&"object"==typeof o&&n(o)}else for(const i of Object.keys(e)){const o=e[i];"string"==typeof o?e[i]=t(o):o&&"object"==typeof o&&n(o)}};n(e)},Le=()=>window.__manifestLoaded?Promise.resolve(window.__manifestLoaded):(window.__manifestPromise||(window.__manifestPromise=fetch($e).then(e=>e.ok?e.json():null).then(e=>(e&&!e.__interpolated&&(ke(e),Object.defineProperty(e,"__interpolated",{value:!0,enumerable:!1})),e)).catch(()=>null)),window.__manifestPromise),Se=async()=>{if(g){(we.deriveFromManifest||we.plugins.some(e=>be.includes(e)))&&Le();try{await g}catch(e){return void(e.logged||console.error(`[Manifest Loader] ${e.message}`))}}let e=null,t=we.plugins,n=null;if(we.deriveFromManifest){e=await Le();const n=function(e){if(!e||"object"!=typeof e)return E.slice();const t=e.data&&"object"==typeof e.data&&Object.keys(e.data).length>0,n=e.components?.length>0||e.preloadedComponents?.length>0,i=(()=>{if(!e.data||"object"!=typeof e.data)return!1;for(const t of Object.values(e.data))if(t&&"object"==typeof t){if("string"==typeof t.locales)return!0;for(const e of Object.keys(t))if(!["url","headers","params","transform","defaultValue","locales"].includes(e)&&/^[a-zA-Z]{2}(-[a-zA-Z]{2})?$/.test(e))return!0}return!1})(),o=e.status&&"object"==typeof e.status&&Object.keys(e.status).length>0;return E.filter(e=>"data"===e?t:"localization"===e?i:"components"===e?n:"status"!==e||o)}(e),o=function(e){if(!e||"object"!=typeof e)return[];if(!(e.appwrite||e.data&&Object.values(e.data).some(e=>e&&"object"==typeof e&&(e.appwriteTableId||e.appwriteDatabaseId||e.appwriteBucketId))))return[];const t=[];return e.appwrite?.auth&&t.push("appwrite-auth"),(e.appwrite||e.data&&Object.values(e.data).some(e=>e&&"object"==typeof e&&e.appwriteTableId))&&t.push("appwrite-data"),(e.appwrite?.presence||e.appwrite?.presences)&&t.push("appwrite-presences"),t}(e),r=function(e){return e&&"object"==typeof e&&e.payments&&"object"==typeof e.payments?["payments"]:[]}(e),a=function(e){return e&&"object"==typeof e&&(e.ai||e.chat)?["chat"]:[]}(e),s=function(e){if("undefined"!=typeof window&&window.Capacitor)return["device"];const t=e&&"object"==typeof e?e.device??e.native:null;return t&&"object"==typeof t?["device"]:[]}(e);t=Q([...k,...(i=[...n,...o,...r,...a,...s,...we.extraPlugins||[]],x.length?i.filter(e=>!x.includes(e)):i)])}else{t=Q([...k,...t.filter(e=>!k.includes(e))]);we.plugins.some(e=>be.includes(e))&&(n=Le()),"undefined"!=typeof window&&window.Capacitor&&!t.includes("device")&&(t=Q([...t,"device"]))}var i;const o=t.map(e=>J(e,we.version).catch(t=>{console.warn(`[Manifest Loader] Failed to load plugin ${e}:`,t)}));we.tailwind&&!function(){try{return!!document.querySelector("style[data-mnfst-utilities][data-mnfst-utilities-complete]")}catch(e){return!1}}()&&o.push(le(we.version).catch(()=>{})),await Promise.all(o),n&&(e=await n),e&&"undefined"!=typeof window&&(window.__manifestLoaded=e,window.ManifestComponentsRegistry&&(window.ManifestComponentsRegistry.manifest=e)),R(async()=>{if(we.deriveFromManifest){try{const e=x.length?ne(t).filter(e=>x.includes(e)):[];e.length&&console.warn(`[Manifest Loader] data-omit lists ${e.join(", ")}, but this page uses ${e.length>1?"them":"it"}. Not loaded: remove ${e.length>1?"them":"it"} from data-omit to load.`);const n=ne([...t,...x]);if(n.length>0){const e=Q(n).filter(e=>!t.includes(e));await Promise.all(e.map(e=>J(e,we.version).catch(t=>{oe.add(e),console.warn(`[Manifest Loader] Failed to load plugin ${e}:`,t)})))}}catch(e){}ie=!0,se(we.version)}var e;Ae(t,we.tailwind),e=N(we.alpine),R(()=>{window.Alpine||document.querySelector('script[src*="alpinejs"]')||Z(e,{alpine:!0}).catch(e=>{e.logged||console.error("[Manifest Loader] Alpine.js failed to load from all CDNs.")})})})};function Ae(e,t){if(window.__manifestReadyCoordinator)return;window.__manifestReadyCoordinator=!0;const n=window.ManifestPending.hold("ready"),i=!!t,o={data:!e.some(e=>"data"===e||"appwrite-data"===e)||!!window.__manifestRenderReady,utilities:!i||!!window.__manifestUtilitiesReady};let r=!1,a=null;const s=()=>!(window.__manifestMarkdownPending>0),c=()=>!(window.__manifestUtilitiesPending>0),d=()=>{r||(r=!0,n(),window.__manifestReady=!0,window.dispatchEvent(new CustomEvent("manifest:ready")))},l=()=>{r||o.data&&o.utilities&&s()&&c()&&(clearTimeout(a),a=setTimeout(()=>{o.data&&o.utilities&&s()&&c()&&d()},300))};window.addEventListener("manifest:render-ready",()=>{o.data=!0,l()}),window.addEventListener("manifest:utilities-ready",()=>{o.utilities=!0,l()}),window.addEventListener("manifest:utilities-idle",l),window.addEventListener("manifest:markdown-idle",l),setTimeout(d,15e3),l()}(()=>{if(g||!document.head||!0===window.__manifestRender)return;const e=new Set,t=(t,n,i)=>{if(!n||e.has(t+n))return;e.add(t+n);const o=document.createElement("link");o.rel=t,i&&(o.as=i,o.setAttribute("fetchpriority","low")),o.href=n,o.setAttribute("data-mnfst-hint",""),document.head.appendChild(o)};document.addEventListener("alpine:init",()=>{document.head.querySelectorAll("link[data-mnfst-hint]").forEach(e=>e.remove())},{once:!0});try{(we.deriveFromManifest||we.plugins.some(e=>be.includes(e)))&&Le();const e=j?null:_[0];if(e&&new URL(e,location.href).origin!==location.origin&&t("preconnect",new URL(e,location.href).origin),we.deriveFromManifest){const e=["data","localization","components","status"];for(const n of[...k,...we.plugins])e.includes(n)||t("preload",C(n,we.version),"script")}R(()=>{try{window.Alpine||document.querySelector('script[src*="alpinejs"]')||t("preload",N(we.alpine)[0],"script")}catch(e){}})}catch(e){}})(),Se()}}();
2
2
  //# sourceMappingURL=manifest.min.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "manifest.appwrite.auth.js": "sha384-n+Fohtui5o2h3HpM7ifnop9YsAdlTj0uHYfzljQMghLJeDkODC6OXop6ds6OTZha",
3
3
  "manifest.appwrite.auth.min.js": "sha384-qN5XF96RpRVTzBeOBoxwh6ziq2+eZ2rS0cLUtlwp4CFcbyuMCaf6kHFJKoWEGNvp",
4
- "manifest.appwrite.data.js": "sha384-tyZJ4XQqqPOOwUS0HyOLjUr4T85GP3qvBWuNa9pzhMVRzs6tXsyrWjANVc1FOGAk",
4
+ "manifest.appwrite.data.js": "sha384-93IR3wa3zWYVLzJXPuo9OHEhj0IsYvpJ9QMz4V2qFfmWmdF2lTWhoEnrAmfDO9Bq",
5
5
  "manifest.appwrite.data.min.js": "sha384-0fTVQE2rvA0T/qiXgSxe9YZDezipYFzrsSqnDcN8Xh6Vij1Pt/b3M6xySEqUtTjK",
6
6
  "manifest.appwrite.presences.js": "sha384-O3EedwV2QTzd4YotjvGPsDHbxaGbtRaZuNopC7/Cfoo5uYPo8ZHYkCPCWurXpA2/",
7
7
  "manifest.appwrite.presences.min.js": "sha384-7AHt7baL29VI3S1Nbkkyq34j2eJ2ysGpDnllmpXXSlc4GHvTk5hdCrXra2R3mSfH",
@@ -23,8 +23,8 @@
23
23
  "manifest.components.min.js": "sha384-zX13laxJhE6FJbbuV9Cm5n7RgZdEdFDG7rE6O+6hBnCvfeadL3a+vXaSHDH0EXxU",
24
24
  "manifest.computed.js": "sha384-GYML/e81gQfN+iDbqhPUgny8bINCyL+SrbTofoGk4hlCnLLjv51mCv42JMqq+ku5",
25
25
  "manifest.computed.min.js": "sha384-90LbCcEOhrjhxi0GWBRb3DJyOkKWLRwzK7Z2nkbc1uaZ5B9EGmNKqx+mstTLWFGJ",
26
- "manifest.data.js": "sha384-qRbt94zUi2wZsTIQ3T6oBdNHPwdRXuyzs/MTIRYl/r1Z6ONHR8+WSaSujyr+Qajj",
27
- "manifest.data.min.js": "sha384-lc7GskUBOg82gIIiF71rKNtLo/ZTeT3VYXR5PQyqPwg8dFjNl/EV2L4+UAqdzxO1",
26
+ "manifest.data.js": "sha384-XdO51MPXw9g+p6jrwoXgY4U3TURz3ByFGKwismr8u43zWnWiCVUCB+e8oBeUgxMT",
27
+ "manifest.data.min.js": "sha384-VAPYQz1mA1owNeK3rh7VfAstLEa9bgE2NuDpkxopPQn3kKsa/1PXFCMeZ1rmRpGs",
28
28
  "manifest.datepicker.js": "sha384-pZUQhUK6u5cl6g0myBXND/Wtrs1RTovYmy/ETQLUV0JujvTvUdRNc/XjPpVhtK16",
29
29
  "manifest.datepicker.min.js": "sha384-e6xN1xQW3LLFvmSWrh3INMCgfUwD+gJca6n9fJfUFArA/OSm2KY0MDeN0pHVsYiw",
30
30
  "manifest.defer.js": "sha384-W8aR5uCnUlmet/NscIgAoGijW064iSLASszQH3RKoLF19klJCyLdVrdz796QqSgD",
@@ -59,8 +59,8 @@
59
59
  "manifest.submissions.min.js": "sha384-p/5Ekd6u/cTsyVQbRgGzEi3h1hJU9zD7+hjdR+upcwt++26sfrLXMjFI2YjS8zWt",
60
60
  "manifest.svg.js": "sha384-D1jF3a0pXIuzm7T2sltyzblF8BTZ8sv1CkfJyQ33q21G6QlYyjdPv8DJi80eCISD",
61
61
  "manifest.svg.min.js": "sha384-rsvQ50FgVpTxX2Wvba3hed2TQvZR+CHHfgS4Cg7V1Dyjx6rxkS1s6rG6UMWDIMez",
62
- "manifest.sw.js": "sha384-rKrWSbZ7HvKN49qGQEfMpKyaOd07REJOyRD4QAxFpDzGu6MHl2AAahWY6G728hEG",
63
- "manifest.sw.min.js": "sha384-eaGkrideMEFFSbZbnda19F9HgTVBaIxzNTPfUcFEUIs1yOBhQ88UWLiWETUI+IT2",
62
+ "manifest.sw.js": "sha384-bjawIp80uwwNA0SJRS/s69cy/2N2m7+sMBmuWmFACKCJI9f+f/V44f3zetLWfgIY",
63
+ "manifest.sw.min.js": "sha384-3iU7BbyIG3os06PZtX9l/US2yP4ibPF3ESpiMWxhF3RynQ1YCdEmZNMi8gIBLHto",
64
64
  "manifest.tabs.js": "sha384-LoPOo8mCAzyil9BLFV1BsDNBVyKmijKieKl7mbVAHEH/Nd7Ye0E6fM6yOgdBKcHZ",
65
65
  "manifest.tabs.min.js": "sha384-7FTbGS9Mj0xe3X/w3j5HNi8411JHnLEaiLpgfX50rLID1Yz9m4DmM4dIeh8fmr8S",
66
66
  "manifest.tailwind.js": "sha384-yuP3LEvWU+QVjxjkZ0YhErtC9RrGmhOmHjjFjhS9obqZbp5/KTIEnSR0CXDvHE0B",
@@ -73,8 +73,8 @@
73
73
  "manifest.url.parameters.min.js": "sha384-0C6e6FIjB9TKVGy5W0LH0TDQ3Eg4mRAokM4MANHUuwoG0IzUZV7HaYUQd2AnkB7a",
74
74
  "manifest.utilities.js": "sha384-G1Tg8KsB7z7ANHiYZCzqijjOCtogvdEM+dYb8P/h0a1XafTThQOkp1gHlvNsjtPm",
75
75
  "manifest.utilities.min.js": "sha384-WilK2hRJ6X1wKLv8RaXDxKllqqGWbux83+yL1Tdv/VoYP0T2YxRH2YXT2bZkxUh1",
76
- "manifest.virtual.js": "sha384-wloH8yOvFNWWQ4LGLy00gBWy5xXg+VRJQnM56Kc9Iew7lgFUWSnf+bE0+Q76ju2l",
77
- "manifest.virtual.min.js": "sha384-9//BZjm3dEzh2gTKvZ3J012FtOTuTWruH0BCOKcYC4qITNfouz+1i1tNowllhbjL",
76
+ "manifest.virtual.js": "sha384-qsDbOyaNclitvdN6Cz03ZGnmr7wghH4Bo4RQQj9Wl1vNfMLy+UjcSPdI45AMd3p/",
77
+ "manifest.virtual.min.js": "sha384-Mx9NygIxGdBzSPo5b0Oc+EIN4bKsFg03b5EprHP69lhfCaSFqHszqEAgwvjlBjap",
78
78
  "@highlightjs/cdn-assets@11.11.1/highlight.min.js": "sha384-RH2xi4eIQ/gjtbs9fUXM68sLSi99C7ZWBRX1vDrVv6GQXRibxXLbwO2NGZB74MbU",
79
79
  "@polar-sh/checkout@0.3.0/dist/embed.global.js": "sha384-VVse2cWVt+cit0Mxg2AgY85JuM53jg9WGvx5apSPxqsenuH7fZLX+qtDSvEomoP8",
80
80
  "alpinejs@3.17.5/dist/cdn.min.js": "sha384-FYLKjwG3aohNhNZoVG8sY/5ntunm+MqylL90Q+rT3OM7AwV9/BKFjk/RjoIpIgsI",
@@ -348,6 +348,11 @@
348
348
  "includeVelocity": {
349
349
  "type": "boolean"
350
350
  },
351
+ "granular": {
352
+ "description": "Opt in to field-level updates for a row source. A change to the fields of existing rows (a realtime update, a local $update) then re-runs what reads those fields and $search/$query/$route results, instead of every reader of the source; readers of the list itself re-run when rows are added, removed, reordered or reloaded, and once more after the next load settles following a local $update. $x.<source> keeps the same array identity across field-only changes, so do not memoize on that identity for values derived from row fields: use x-computed.",
353
+ "type": "boolean",
354
+ "default": false
355
+ },
351
356
  "persist": {
352
357
  "description": "Persist this source's rows in IndexedDB and hydrate them before the network on the next visit (stale until the first fresh landing). `true` = boot tier with defaults.",
353
358
  "oneOf": [
@@ -16,7 +16,7 @@
16
16
 
17
17
  // Build stamps the published version here; unstamped (dev) falls back to the
18
18
  // registration URL's `v`, then 'dev'.
19
- const BUILD_VERSION = '0.5.327';
19
+ const BUILD_VERSION = '0.5.329';
20
20
  const CACHE_PREFIX = 'mnfst-sw:';
21
21
  const META_CACHE = CACHE_PREFIX + 'meta';
22
22
  // Sized to hold a full precache.json warm-up (PRECACHE_MAX_ENTRIES server-side)
@@ -1,2 +1,2 @@
1
- !function(){"use strict";const t="0.5.327",e="mnfst-sw:",n=e+"meta",a=/\.(css|js|mjs|json|csv|tsv|ya?ml|md|txt|xml|svg|png|jpe?g|gif|webp|avif|ico|bmp|woff2?|ttf|otf|eot|mp3|mp4|webm|ogg|wav|flac|m4a|wasm|webmanifest|map)$/i,s=/^\/(sw\.js$|precache\.json$|v1\/|_appwrite\/|_ai\/|__mnfst|__edit)/,i=/^(cdn\.manifestx\.dev|cdn\.jsdelivr\.net|unpkg\.com|esm\.run)$/,c="https://cdn.manifestx.dev/npm/",r=/^api\.(iconify\.design|simplesvg\.com|unisvg\.com)$/,o=/@\d+\.\d+\.\d+[^/]*(\/|$)/,l=/@[^/]+(\/|$)/;let f=null,u=!1;function m(t){try{return new URL(self.location.href).searchParams.get(t)||""}catch(t){return""}}function h(){return{version:-1===t.indexOf("-dev")?t:m("v")||"dev",deployment:m("d")}}function w(t){return e+t.version+":"+(t.deployment||"-")+":"}async function d(){const t=h();try{const e=await fetch("/manifest.json",{cache:"no-store"});if(e.ok){const n=await e.json();n&&"string"==typeof n.deployment&&n.deployment&&(t.deployment=n.deployment)}}catch(t){}try{const e=await caches.open(n);await e.put("/__meta",new Response(JSON.stringify(t),{headers:{"content-type":"application/json"}}))}catch(t){}return t}function p(){return f||(f=(async()=>{try{const t=await caches.open(n),e=await t.match("/__meta");if(e){const t=await e.json();if(t&&t.version)return t}}catch(t){}return d()})().catch(()=>h())),f}async function y(t){if(u)throw new Error("killed");const e=await p();return caches.open(w(e)+t)}function g(t){return t.url.replace(/([?&])t=\d+(?=&|$)/,"$1").replace(/[?&]$/,"").replace(/\?&/,"?")}function v(t){if("GET"!==t.method)return null;if(t.headers.has("range"))return null;if(-1!==(t.headers.get("accept")||"").indexOf("text/event-stream"))return null;const e=new URL(g(t));if("http:"!==e.protocol&&"https:"!==e.protocol)return null;const n=e.origin===self.location.origin,c=e.pathname;return"navigate"===t.mode||"document"===t.destination?n?"document":null:n?s.test(c)?null:/(^|\/)manifest\.json$/.test(c)?"manifest":e.searchParams.get("v")?"immutable":/\.html?$/i.test(c)?"document":a.test(c)?"swr":null:r.test(e.host)?/\.json$/.test(c)?"immutable":null:i.test(e.host)?o.test(c)||/\/alpinejs@/.test(c)?"immutable":l.test(c)?"swr":null:null}function j(t){return!!t&&t.ok&&!t.redirected&&("basic"===t.type||"cors"===t.type||"default"===t.type)}function _(t){const e=new URL(t.url).origin===self.location.origin||"cors"===t.mode?fetch(t):fetch(new Request(t.url,{mode:"cors",credentials:"omit",redirect:"follow",integrity:t.integrity||""}));if(0!==t.url.indexOf(c))return e;const n=()=>fetch(new Request("https://cdn.jsdelivr.net/npm/"+t.url.slice(30),{mode:"cors",credentials:"omit",redirect:"follow",integrity:t.integrity||""}));return e.then(t=>t.ok?t:n().then(e=>e.ok?e:t).catch(()=>t),()=>n())}async function k(t,e){const n=await y("pages"),a=g(t);try{const e=await fetch(t);return j(e)&&await n.put(a,e.clone()),e}catch(s){const i=await n.match(a,{ignoreSearch:e});if(i)return i;if(e&&"navigate"===t.mode){const t=await n.match("/index.html")||await n.match("/");if(t)return t}throw s}}function $(t,e){const n=t.request;switch(e){case"immutable":return async function(t){const e=await y("assets"),n=g(t),a=await e.match(n);if(a)return a;const s=await _(t);return j(s)&&await e.put(n,s.clone()),s}(n);case"swr":return async function(t,e){const n=await y("swr"),a=g(t),s=await n.match(a),i=(async()=>{const e=await _(t);return j(e)&&(await n.put(a,e.clone()),await async function(t){const e=await t.keys(),n=e.length-500;for(let a=0;a<n;a++)await t.delete(e[a])}(n)),e})();return s?(e.waitUntil(i.catch(()=>{})),s):i}(n,t);case"document":return k(n,!0);case"manifest":return k(n,!1);default:return fetch(n)}}const x={version:h().version,ready:!0};self.__mnfstSw=x,self.addEventListener("install",t=>{try{f=null,t.waitUntil(d().then(t=>{f=Promise.resolve(t)}).catch(()=>{}))}catch(t){}}),self.addEventListener("activate",t=>{try{t.waitUntil((async()=>{if(!self.registration||"undefined"==typeof caches||"function"!=typeof fetch||self.__mnfstSw!==x)return void await self.registration.unregister();const t=await p();await async function(t){const a=w(t),s=await caches.keys();await Promise.all(s.filter(t=>0===t.indexOf(e)&&t!==n&&0!==t.indexOf(a)).map(t=>caches.delete(t)))}(t).catch(()=>{}),async function(t){let e;try{const t=await fetch("/precache.json",{cache:"no-store"});if(!t.ok)return;e=await t.json()}catch(t){return}if(!e||!Array.isArray(e.files))return;if(e.deployment&&t.deployment&&e.deployment!==t.deployment)return;const n=e.files.filter(t=>"string"==typeof t),a=async t=>{try{const e=new Request(new URL(t,self.location.origin).href),n=v(e);if(!n)return;const a="immutable"===n?"assets":"swr"===n?"swr":"pages",s=await y(a),i=g(e);if(await s.match(i))return;const c=await _(e);j(c)&&await s.put(i,c)}catch(t){}};let s=0;await Promise.all(Array.from({length:4},async()=>{for(;s<n.length;)await a(n[s++])}))}(t).catch(()=>{})})().catch(()=>{}))}catch(t){}}),self.addEventListener("fetch",t=>{if(u)return;let e=null;try{e=v(t.request)}catch(t){return}if(e)try{t.respondWith($(t,e).catch(()=>fetch(t.request)))}catch(t){}}),self.addEventListener("message",t=>{try{const n=t.data;if(!n||"manifest:sw"!==n.type)return;const a=e=>{try{const n=t.ports&&t.ports[0];n?n.postMessage(e):t.source&&t.source.postMessage&&t.source.postMessage(e)}catch(t){}};if("ping"===n.action)return void a({type:"manifest:sw",action:"pong"});if("version"===n.action)return void t.waitUntil(p().then(t=>a({type:"manifest:sw",action:"version",version:t.version,deployment:t.deployment,key:w(t)})).catch(()=>{}));"kill"===n.action&&(u=!0,t.waitUntil((async()=>{await async function(){const t=await caches.keys();await Promise.all(t.filter(t=>0===t.indexOf(e)).map(t=>caches.delete(t)))}().catch(()=>{}),await self.registration.unregister().catch(()=>{}),a({type:"manifest:sw",action:"killed"})})().catch(()=>{})))}catch(t){}})}();
1
+ !function(){"use strict";const t="0.5.329",e="mnfst-sw:",n=e+"meta",a=/\.(css|js|mjs|json|csv|tsv|ya?ml|md|txt|xml|svg|png|jpe?g|gif|webp|avif|ico|bmp|woff2?|ttf|otf|eot|mp3|mp4|webm|ogg|wav|flac|m4a|wasm|webmanifest|map)$/i,s=/^\/(sw\.js$|precache\.json$|v1\/|_appwrite\/|_ai\/|__mnfst|__edit)/,i=/^(cdn\.manifestx\.dev|cdn\.jsdelivr\.net|unpkg\.com|esm\.run)$/,c="https://cdn.manifestx.dev/npm/",r=/^api\.(iconify\.design|simplesvg\.com|unisvg\.com)$/,o=/@\d+\.\d+\.\d+[^/]*(\/|$)/,l=/@[^/]+(\/|$)/;let f=null,u=!1;function m(t){try{return new URL(self.location.href).searchParams.get(t)||""}catch(t){return""}}function h(){return{version:-1===t.indexOf("-dev")?t:m("v")||"dev",deployment:m("d")}}function w(t){return e+t.version+":"+(t.deployment||"-")+":"}async function d(){const t=h();try{const e=await fetch("/manifest.json",{cache:"no-store"});if(e.ok){const n=await e.json();n&&"string"==typeof n.deployment&&n.deployment&&(t.deployment=n.deployment)}}catch(t){}try{const e=await caches.open(n);await e.put("/__meta",new Response(JSON.stringify(t),{headers:{"content-type":"application/json"}}))}catch(t){}return t}function p(){return f||(f=(async()=>{try{const t=await caches.open(n),e=await t.match("/__meta");if(e){const t=await e.json();if(t&&t.version)return t}}catch(t){}return d()})().catch(()=>h())),f}async function y(t){if(u)throw new Error("killed");const e=await p();return caches.open(w(e)+t)}function g(t){return t.url.replace(/([?&])t=\d+(?=&|$)/,"$1").replace(/[?&]$/,"").replace(/\?&/,"?")}function v(t){if("GET"!==t.method)return null;if(t.headers.has("range"))return null;if(-1!==(t.headers.get("accept")||"").indexOf("text/event-stream"))return null;const e=new URL(g(t));if("http:"!==e.protocol&&"https:"!==e.protocol)return null;const n=e.origin===self.location.origin,c=e.pathname;return"navigate"===t.mode||"document"===t.destination?n?"document":null:n?s.test(c)?null:/(^|\/)manifest\.json$/.test(c)?"manifest":e.searchParams.get("v")?"immutable":/\.html?$/i.test(c)?"document":a.test(c)?"swr":null:r.test(e.host)?/\.json$/.test(c)?"immutable":null:i.test(e.host)?o.test(c)||/\/alpinejs@/.test(c)?"immutable":l.test(c)?"swr":null:null}function j(t){return!!t&&t.ok&&!t.redirected&&("basic"===t.type||"cors"===t.type||"default"===t.type)}function _(t){const e=new URL(t.url).origin===self.location.origin||"cors"===t.mode?fetch(t):fetch(new Request(t.url,{mode:"cors",credentials:"omit",redirect:"follow",integrity:t.integrity||""}));if(0!==t.url.indexOf(c))return e;const n=()=>fetch(new Request("https://cdn.jsdelivr.net/npm/"+t.url.slice(30),{mode:"cors",credentials:"omit",redirect:"follow",integrity:t.integrity||""}));return e.then(t=>t.ok?t:n().then(e=>e.ok?e:t).catch(()=>t),()=>n())}async function k(t,e){const n=await y("pages"),a=g(t);try{const e=await fetch(t);return j(e)&&await n.put(a,e.clone()),e}catch(s){const i=await n.match(a,{ignoreSearch:e});if(i)return i;if(e&&"navigate"===t.mode){const t=await n.match("/index.html")||await n.match("/");if(t)return t}throw s}}function $(t,e){const n=t.request;switch(e){case"immutable":return async function(t){const e=await y("assets"),n=g(t),a=await e.match(n);if(a)return a;const s=await _(t);return j(s)&&await e.put(n,s.clone()),s}(n);case"swr":return async function(t,e){const n=await y("swr"),a=g(t),s=await n.match(a),i=(async()=>{const e=await _(t);return j(e)&&(await n.put(a,e.clone()),await async function(t){const e=await t.keys(),n=e.length-500;for(let a=0;a<n;a++)await t.delete(e[a])}(n)),e})();return s?(e.waitUntil(i.catch(()=>{})),s):i}(n,t);case"document":return k(n,!0);case"manifest":return k(n,!1);default:return fetch(n)}}const x={version:h().version,ready:!0};self.__mnfstSw=x,self.addEventListener("install",t=>{try{f=null,t.waitUntil(d().then(t=>{f=Promise.resolve(t)}).catch(()=>{}))}catch(t){}}),self.addEventListener("activate",t=>{try{t.waitUntil((async()=>{if(!self.registration||"undefined"==typeof caches||"function"!=typeof fetch||self.__mnfstSw!==x)return void await self.registration.unregister();const t=await p();await async function(t){const a=w(t),s=await caches.keys();await Promise.all(s.filter(t=>0===t.indexOf(e)&&t!==n&&0!==t.indexOf(a)).map(t=>caches.delete(t)))}(t).catch(()=>{}),async function(t){let e;try{const t=await fetch("/precache.json",{cache:"no-store"});if(!t.ok)return;e=await t.json()}catch(t){return}if(!e||!Array.isArray(e.files))return;if(e.deployment&&t.deployment&&e.deployment!==t.deployment)return;const n=e.files.filter(t=>"string"==typeof t),a=async t=>{try{const e=new Request(new URL(t,self.location.origin).href),n=v(e);if(!n)return;const a="immutable"===n?"assets":"swr"===n?"swr":"pages",s=await y(a),i=g(e);if(await s.match(i))return;const c=await _(e);j(c)&&await s.put(i,c)}catch(t){}};let s=0;await Promise.all(Array.from({length:4},async()=>{for(;s<n.length;)await a(n[s++])}))}(t).catch(()=>{})})().catch(()=>{}))}catch(t){}}),self.addEventListener("fetch",t=>{if(u)return;let e=null;try{e=v(t.request)}catch(t){return}if(e)try{t.respondWith($(t,e).catch(()=>fetch(t.request)))}catch(t){}}),self.addEventListener("message",t=>{try{const n=t.data;if(!n||"manifest:sw"!==n.type)return;const a=e=>{try{const n=t.ports&&t.ports[0];n?n.postMessage(e):t.source&&t.source.postMessage&&t.source.postMessage(e)}catch(t){}};if("ping"===n.action)return void a({type:"manifest:sw",action:"pong"});if("version"===n.action)return void t.waitUntil(p().then(t=>a({type:"manifest:sw",action:"version",version:t.version,deployment:t.deployment,key:w(t)})).catch(()=>{}));"kill"===n.action&&(u=!0,t.waitUntil((async()=>{await async function(){const t=await caches.keys();await Promise.all(t.filter(t=>0===t.indexOf(e)).map(t=>caches.delete(t)))}().catch(()=>{}),await self.registration.unregister().catch(()=>{}),a({type:"manifest:sw",action:"killed"})})().catch(()=>{})))}catch(t){}})}();
2
2
  //# sourceMappingURL=manifest.sw.min.js.map
@@ -11,35 +11,76 @@
11
11
 
12
12
  (function () {
13
13
 
14
+ // `item in src` or `(item, index) in src`, parentheses optional (as x-for)
15
+ const FOR_RE = /^\s*\(?\s*([A-Za-z_$][\w$]*)\s*(?:,\s*([A-Za-z_$][\w$]*)\s*)?\)?\s+(?:in|of)\s+(.+?)\s*$/;
16
+
17
+ function hasVirtual(el) {
18
+ if (el.hasAttribute('x-virtual')) return true;
19
+ for (const attr of el.attributes) if (attr.name.startsWith('x-virtual.')) return true;
20
+ return false;
21
+ }
22
+
23
+ // x-for and :key move to data attributes Alpine ignores. Only a form x-virtual can run:
24
+ // any other stays on the template for Alpine's own x-for
25
+ function stashFor(template) {
26
+ const forExpr = template.getAttribute('x-for');
27
+ if (forExpr === null || !FOR_RE.test(forExpr)) return;
28
+ template.setAttribute('data-virtual-for', forExpr);
29
+ const key = template.getAttribute(':key') ?? template.getAttribute('x-bind:key');
30
+ if (key !== null) template.setAttribute('data-virtual-key', key);
31
+ template.removeAttribute('x-for');
32
+ template.removeAttribute(':key');
33
+ template.removeAttribute('x-bind:key');
34
+ }
35
+
14
36
  function initializeVirtualPlugin() {
15
37
 
38
+ // Alpine queues a tree's directives before running any: x-for comes off as the container is visited
39
+ if (typeof Alpine.interceptInit === 'function') {
40
+ Alpine.interceptInit((el) => {
41
+ if (el.nodeType !== 1 || !hasVirtual(el) || el.hasAttribute('x-ignore')) return;
42
+ const template = el.querySelector('template[x-for]');
43
+ if (template) stashFor(template);
44
+ });
45
+ }
46
+
47
+ // One dependency for "any index or length change" where array iteration is instrumented; else a read per index
48
+ const cheapIterate = Alpine.reactive([]).some !== Array.prototype.some;
49
+ const anyItem = () => true;
50
+ function trackList(list) {
51
+ if (!Array.isArray(list)) return; // an iterator would be consumed
52
+ void list.length;
53
+ if (cheapIterate) { list.some(anyItem); return; }
54
+ for (let i = 0; i < list.length; i++) void list[i];
55
+ }
56
+
16
57
  Alpine.directive('virtual', (el, { expression }, { evaluate, evaluateLater, effect, cleanup }) => {
17
58
 
18
59
  // --- Find the template (may be nested, e.g. table > tbody > template) ---
19
- const template = el.querySelector('template[x-for]') || el.querySelector(':scope template');
20
- if (!template || !template.getAttribute('x-for')) {
21
- // Quiet on re-init of an already-virtualized container (x-for stripped first pass).
60
+ const template = el.querySelector('template[x-for], template[data-virtual-for]') || el.querySelector(':scope template');
61
+ if (template) stashFor(template);
62
+ const forExpr = template && (template.getAttribute('data-virtual-for') ?? template.getAttribute('x-for'));
63
+ if (!forExpr) {
64
+ // Quiet on re-init of an already-virtualized container
22
65
  if (!el.querySelector('[data-virtual-spacer]')) {
23
66
  console.warn('[x-virtual] expects a descendant <template> with x-for, e.g. <template x-for="row in $x.items" :key="row.id">…');
24
67
  }
25
68
  return;
26
69
  }
27
- const forExpr = template.getAttribute('x-for');
28
- // `item in src` or `(item, index) in src`, parentheses optional (as x-for)
29
- const m = /^\s*\(?\s*([A-Za-z_$][\w$]*)\s*(?:,\s*([A-Za-z_$][\w$]*)\s*)?\)?\s+(?:in|of)\s+(.+?)\s*$/.exec(forExpr);
70
+ const m = FOR_RE.exec(forExpr);
30
71
  if (!m) {
72
+ // x-for is still on the template: Alpine renders the list unvirtualized
31
73
  console.warn('[x-virtual] could not parse x-for expression: ' + forExpr);
32
74
  return;
33
75
  }
34
76
  const itemName = m[1];
35
77
  const indexName = m[2] || null;
36
78
  const sourceExpr = m[3].trim();
37
- const keyExpr = template.getAttribute(':key') || template.getAttribute('x-bind:key') || `${itemName}.id`;
79
+ const keyExpr = template.getAttribute('data-virtual-key') || `${itemName}.id`;
38
80
 
39
- // Strip x-for/:key so Alpine won't render the full list; keep the template as clone source.
40
- template.removeAttribute('x-for');
41
- template.removeAttribute(':key');
42
- template.removeAttribute('x-bind:key');
81
+ // The template stays as the clone source, with nothing left for Alpine to render
82
+ template.removeAttribute('data-virtual-for');
83
+ template.removeAttribute('data-virtual-key');
43
84
 
44
85
  // --- Options ---
45
86
  const options = expression ? (evaluate(expression) || {}) : {};
@@ -109,6 +150,7 @@ function initializeVirtualPlugin() {
109
150
  let measuredSum = 0, measuredCount = 0;
110
151
  const rendered = new Map(); // key -> { node, scope, removeScope }
111
152
  let data = [];
153
+ let raw = []; // the same list unwrapped: full scans read this, rows get data[i]
112
154
  let cumulative = new Float64Array(1); // line-top offsets; last = total
113
155
  let endNotifiedAt = -1; // data length `virtual-end` last fired for
114
156
  let endHead; // first item's key then: a replaced list fires again
@@ -145,8 +187,9 @@ function initializeVirtualPlugin() {
145
187
  const n = data.length;
146
188
  pos = new Array(n);
147
189
  maxItemH = 0;
190
+ const authored = !!(spanFn || heightFn); // author functions read live items: a changed field repacks
148
191
  for (let i = 0; i < n; i++) {
149
- const item = data[i];
192
+ const item = authored ? data[i] : raw[i];
150
193
  let span = spanFn ? (spanFn(item) | 0) : 1;
151
194
  if (span < 1) span = 1; else if (span > cols) span = cols;
152
195
  const h = heightForItem(item, i);
@@ -174,7 +217,7 @@ function initializeVirtualPlugin() {
174
217
  let y = 0;
175
218
  for (let i = 0; i < n; i++) {
176
219
  cumulative[i] = y;
177
- y += heightFor(keyFn(data[i], i));
220
+ y += heightFor(keyFn(raw[i], i));
178
221
  }
179
222
  cumulative[n] = y;
180
223
  }
@@ -189,7 +232,7 @@ function initializeVirtualPlugin() {
189
232
  const start = i;
190
233
  let lineW = 0, h = 0;
191
234
  while (i < n) {
192
- const k = keyFn(data[i], i);
235
+ const k = keyFn(raw[i], i);
193
236
  const w = widthFor(k);
194
237
  const add = lineW === 0 ? w : gx + w;
195
238
  if (lineW > 0 && lineW + add > cw) break; // wrap
@@ -236,7 +279,7 @@ function initializeVirtualPlugin() {
236
279
  if (isMasonry) return renderMasonry();
237
280
  if (!data.length) { clearRows(); setHeight(topSpacer, 0); setHeight(botSpacer, 0); return; }
238
281
  const vh = scrollEl.clientHeight;
239
- if (!vh || !resolveKind()) return; // defer until sized
282
+ if (!vh || !resolveKind()) return false; // defer until sized
240
283
  ready = true;
241
284
  const total = isGallery ? lines.length : data.length; // after resolveKind (may enable gallery)
242
285
 
@@ -304,7 +347,7 @@ function initializeVirtualPlugin() {
304
347
  function renderMasonry() {
305
348
  if (!data.length) { clearRows(); sizer.style.height = '0px'; return; }
306
349
  const vh = scrollEl.clientHeight;
307
- if (!vh) return; // defer until sized
350
+ if (!vh) return false; // defer until sized
308
351
  ready = true;
309
352
  sizer.style.height = totalHeight + 'px';
310
353
 
@@ -370,6 +413,13 @@ function initializeVirtualPlugin() {
370
413
  rendered.delete(key);
371
414
  }
372
415
 
416
+ // Rows whose item left the list (only needed while render() is deferred)
417
+ function dropStaleRows() {
418
+ const valid = new Set();
419
+ for (let i = 0; i < raw.length; i++) if (raw[i] != null) valid.add(keyFn(raw[i], i));
420
+ for (const [key, entry] of rendered) if (!valid.has(key)) removeRow(key, entry);
421
+ }
422
+
373
423
  function clearRows() {
374
424
  for (const [key, entry] of rendered) removeRow(key, entry);
375
425
  }
@@ -455,13 +505,12 @@ function initializeVirtualPlugin() {
455
505
  const getSource = evaluateLater(sourceExpr);
456
506
  effect(() => {
457
507
  getSource((value) => {
508
+ trackList(value);
458
509
  data = Array.isArray(value) ? value : (value ? Array.from(value) : []);
459
- // Drop rendered rows whose key no longer exists.
460
- const valid = new Set();
461
- for (let i = 0; i < data.length; i++) if (data[i] != null) valid.add(keyFn(data[i], i));
462
- for (const [key, entry] of rendered) if (!valid.has(key)) removeRow(key, entry);
510
+ raw = Alpine.raw ? Alpine.raw(data) : data;
463
511
  rebuild();
464
- render();
512
+ // render() drops rows that left the window or the list; unsized (hidden), it cannot
513
+ if (render() === false && rendered.size) dropStaleRows();
465
514
  });
466
515
  });
467
516
 
@@ -568,11 +617,13 @@ function setHeight(spacer, px) {
568
617
 
569
618
  // keyFn(item, index) returns the row's key. Falls back to identity on failure.
570
619
  function buildKeyFn(itemName, indexName, keyExpr) {
620
+ // Keys read the unwrapped item (a derived list holds proxies), and an item used as its own key is one key either way
621
+ const plain = (key) => (key && typeof key === 'object' && window.Alpine && Alpine.raw ? Alpine.raw(key) : key);
571
622
  try {
572
623
  const fn = indexName ? new Function(itemName, indexName, `return (${keyExpr});`) : new Function(itemName, `return (${keyExpr});`);
573
- return (item, i) => { try { return fn(item, i); } catch { return item; } };
624
+ return (item, i) => { try { return plain(fn(plain(item), i)); } catch { return plain(item); } };
574
625
  } catch {
575
- return (item) => item;
626
+ return (item) => plain(item);
576
627
  }
577
628
  }
578
629
 
@@ -1,2 +1,2 @@
1
- !function(){function e(){Alpine.directive("virtual",(e,{expression:l},{evaluate:s,evaluateLater:c,effect:a,cleanup:u})=>{const d=e.querySelector("template[x-for]")||e.querySelector(":scope template");if(!d||!d.getAttribute("x-for"))return void(e.querySelector("[data-virtual-spacer]")||console.warn('[x-virtual] expects a descendant <template> with x-for, e.g. <template x-for="row in $x.items" :key="row.id">…'));const f=d.getAttribute("x-for"),p=/^\s*\(?\s*([A-Za-z_$][\w$]*)\s*(?:,\s*([A-Za-z_$][\w$]*)\s*)?\)?\s+(?:in|of)\s+(.+?)\s*$/.exec(f);if(!p)return void console.warn("[x-virtual] could not parse x-for expression: "+f);const h=p[1],g=p[2]||null,m=p[3].trim(),y=d.getAttribute(":key")||d.getAttribute("x-bind:key")||`${h}.id`;d.removeAttribute("x-for"),d.removeAttribute(":key"),d.removeAttribute("x-bind:key");const v=l&&s(l)||{},b=v.estimate,w=b&&"object"==typeof b?Number(b.height)||50:Number(b)>0?Number(b):50,x=b&&"object"==typeof b&&Number(b.width)||120,A=Number.isFinite(v.overscan)&&v.overscan>=0?Number(v.overscan):3,S=e,T=d.parentElement,C=getComputedStyle(S);"visible"===C.overflow&&"visible"===C.overflowY&&(S.style.overflow="auto");const E="masonry"===v.mode;let N=t(T),F=!1;const M=Number(v.columns)>0?Math.floor(v.columns):0,B=Number(v.columnWidth)>0?Number(v.columnWidth):0,k="function"==typeof v.span?v.span:null,L="function"==typeof v.height?v.height:null,$=Number.isFinite(v.gap)?Number(v.gap):parseFloat(C.gap)||0;E&&"static"===C.position&&(S.style.position="relative");const q=d.content.firstElementChild?d.content.firstElementChild.children.length:1;let R,W,O;function z(){r(R,N),r(W,N),F="gallery"===(v.mode||function(e,t){return"flex"===e&&(getComputedStyle(t).flexWrap||"").startsWith("wrap")?"gallery":"rows"}(N,T))}E?(O=document.createElement("div"),O.dataset.virtualSpacer="",O.setAttribute("aria-hidden","true"),O.style.cssText="position:absolute;top:0;left:0;width:1px;height:0;pointer-events:none",T.appendChild(O)):(R=n(N,q),W=n(N,q),T.insertBefore(R,d),T.insertBefore(W,d),N&&z());const H=E?O:W,I=new Map,D=new Map;let j=0,G=0;const P=new Map;let Y,Z=[],_=new Float64Array(1),V=-1,J=[],K=[],Q=[],U=0,X=0,ee=!1,te=null;const ne=function(e,t,n){try{const o=t?new Function(e,t,`return (${n});`):new Function(e,`return (${n});`);return(e,t)=>{try{return o(e,t)}catch{return e}}}catch{return e=>e}}(h,g,y),oe=()=>G>0?j/G:w,re=e=>I.get(e)??oe(),ie=e=>D.get(e)??x,le=(e,t)=>L?Number(L(e))||w:re(ne(e,t));function se(){E?function(){const e=ve(),t=$;let n=M||(B?Math.max(1,Math.floor((e+t)/(B+t))):3);const o=(e-(n-1)*t)/n,r=new Float64Array(n),i=Z.length;K=new Array(i),X=0;for(let e=0;e<i;e++){const i=Z[e];let l=k?0|k(i):1;l<1?l=1:l>n&&(l=n);const s=le(i,e);let c=0,a=1/0;for(let e=0;e+l<=n;e++){let t=0;for(let n=0;n<l;n++)r[e+n]>t&&(t=r[e+n]);t<a&&(a=t,c=e)}const u=l*o+(l-1)*t;K[e]={x:c*(o+t),y:a,w:u,h:s};const d=a+s+t;for(let e=0;e<l;e++)r[c+e]=d;s>X&&(X=s)}let l=0;for(let e=0;e<n;e++)r[e]>l&&(l=r[e]);U=l>0?l-t:0,Q=Array.from({length:i},(e,t)=>t).sort((e,t)=>K[e].y-K[t].y)}():F?function(){const e=ve(),t=function(){const e=getComputedStyle(S);return parseFloat(e.columnGap||e.gap||0)||0}(),n=function(){const e=getComputedStyle(S);return parseFloat(e.rowGap||e.gap||0)||0}();J=[];let o=0;const r=Z.length;for(;o<r;){const n=o;let i=0,l=0;for(;o<r;){const n=ne(Z[o],o),r=ie(n),s=0===i?r:t+r;if(i>0&&i+s>e)break;i+=s,l=Math.max(l,re(n)),o++}o===n&&o++,J.push({start:n,end:o,height:l})}_=new Float64Array(J.length+1);let i=0;for(let e=0;e<J.length;e++)_[e]=i,i+=J[e].height+n;_[J.length]=J.length?i-n:0}():function(){const e=Z.length;_=new Float64Array(e+1);let t=0;for(let n=0;n<e;n++)_[n]=t,t+=re(ne(Z[n],n));_[e]=t}()}function ce(e,t){let n=0,o=t;for(;n<o;){const t=n+o>>>1;_[t+1]<=e?n=t+1:o=t}return n}function ae(t){const n=Z.length?ne(Z[0],0):void 0;(Z.length<V||n!==Y)&&(V=-1),Y=n,t&&Z.length&&V!==Z.length&&(V=Z.length,e.dispatchEvent(new CustomEvent("virtual-end",{bubbles:!0,detail:{length:Z.length}})))}function ue(){if(E)return function(){if(!Z.length)return he(),void(O.style.height="0px");const e=S.clientHeight;if(!e)return;ee=!0,O.style.height=U+"px";const t=A*oe(),n=S.scrollTop-t,o=S.scrollTop+e+t;let r=0,i=Q.length;const l=n-X;for(;r<i;){const e=r+i>>>1;K[Q[e]].y<l?r=e+1:i=e}const s=new Set,c=[];for(let e=r;e<Q.length;e++){const t=Q[e],r=K[t];if(r.y>o)break;if(r.y+r.h<n)continue;const i=Z[t];if(null==i)continue;const l=ne(i,t);if(null==l)continue;s.add(l),c.push(l);let a=P.get(l);a?de(a,i,t):a=fe(i,l,H,t);const u=a.node.style;u.position="absolute",u.left=r.x+"px",u.top=r.y+"px",u.width=r.w+"px"}for(const[e,t]of P)s.has(e)||pe(e,t);ae(s.has(ne(Z[Z.length-1],Z.length-1))),me(c)}();if(!Z.length)return he(),i(R,0),void i(W,0);const e=S.clientHeight;if(!e||!(N||E||(N=t(T))&&(te&&T!==S&&te.unobserve(T),z(),se(),1)))return;ee=!0;const n=F?J.length:Z.length,o=Math.max(0,S.scrollTop-function(){const e=S.getBoundingClientRect();return R.getBoundingClientRect().top-e.top+S.scrollTop}());let r=ce(o,n)-A;r<0&&(r=0);let l=ce(o+e,n)+1+A;l>n&&(l=n),i(R,_[r]),i(W,_[n]-_[l]);const s=F?J[r].start:r,c=F?J[l-1].end:l;ae(c>=Z.length);const a=new Set,u=[],d=[],f=[];for(let e=s;e<c;e++){const t=Z[e];if(null==t)continue;const n=ne(t,e);null!=n&&(a.add(n),u.push(n),d.push(t),f.push(e))}for(const[e,t]of P)a.has(e)||pe(e,t);const p=new Set;for(const e of P.values())p.add(e.node);const h=e=>{for(;e&&e!==W&&e.parentNode===T&&!p.has(e);)e=e.nextSibling;return e&&e.parentNode===T?e:W};let g=h(R.nextSibling);for(let e=0;e<u.length;e++){g.parentNode!==T&&(g=W);let t=P.get(u[e]);t?(de(t,d[e],f[e]),t.node===g?g=h(g.nextSibling):T.insertBefore(t.node,g)):(t=fe(d[e],u[e],g,f[e]),p.add(t.node),t.node.parentNode!==T&&T.insertBefore(t.node,g))}me(u)}function de(e,t,n){e.scope[h]!==t&&(e.scope[h]=t),g&&e.scope[g]!==n&&(e.scope[g]=n)}function fe(e,t,n=H,o){const r=d.content.firstElementChild.cloneNode(!0);T.insertBefore(r,n);const i=Alpine.reactive(g?{[h]:e,[g]:o}:{[h]:e}),l=Alpine.addScopeToNode(r,i);Alpine.initTree(r);const s={node:r,scope:i,removeScope:l};return P.set(t,s),s}function pe(e,t){t.removeScope&&t.removeScope(),Alpine.destroyTree&&Alpine.destroyTree(t.node),t.node.remove(),P.delete(e)}function he(){for(const[e,t]of P)pe(e,t)}let ge=!1;function me(e){if(E&&L)return;const t=[];for(const n of e){(F?!I.has(n)||!D.has(n):!I.has(n))&&P.has(n)&&t.push(n)}t.length&&!ge&&(ge=!0,requestAnimationFrame(()=>{ge=!1;let e=!1;for(const n of t){const t=P.get(n);t&&ye(n,t.node)&&(e=!0)}e&&(se(),ue())}))}function ye(e,t){if(!t.isConnected)return!1;const n=function(e){if("contents"!==getComputedStyle(e).display)return e.offsetHeight;const t={top:1/0,bottom:-1/0};return o(e,t),t.bottom>t.top?t.bottom-t.top:0}(t);if(!n)return!1;let r=!1;const i=I.get(e);if(i!==n&&(void 0!==i?j-=i:G++,j+=n,I.set(e,n),r=!0),F){const n=t.offsetWidth;n&&D.get(e)!==n&&(D.set(e,n),r=!0)}return r}function ve(){const e=getComputedStyle(S);return S.clientWidth-parseFloat(e.paddingLeft||0)-parseFloat(e.paddingRight||0)}const be=c(m);a(()=>{be(e=>{Z=Array.isArray(e)?e:e?Array.from(e):[];const t=new Set;for(let e=0;e<Z.length;e++)null!=Z[e]&&t.add(ne(Z[e],e));for(const[e,n]of P)t.has(e)||pe(e,n);se(),ue()})});let we=!1,xe=!1;const Ae=()=>{xe||(xe=!0,requestAnimationFrame(()=>{xe=!1,we||ue()}))};S.addEventListener("scroll",Ae,{passive:!0});let Se=null;te=new ResizeObserver(()=>{ee?(clearTimeout(Se),Se=setTimeout(()=>{se(),ue()},100)):requestAnimationFrame(()=>{se(),ue()})}),te.observe(S),N||E||T===S||te.observe(T),u(()=>{we=!0,S.removeEventListener("scroll",Ae),te.disconnect(),clearTimeout(Se),he(),E?O.remove():(R.remove(),W.remove())})})}function t(e){const t=e.tagName;if("TBODY"===t||"THEAD"===t||"TFOOT"===t||"TABLE"===t)return"table";const n=getComputedStyle(e).display;return"none"===n?null:n.includes("grid")?"grid":n.includes("flex")?"flex":"block"}function n(e,t){let n;if("table"===e){n=document.createElement("tr");const e=document.createElement("td");t>1&&(e.colSpan=t),e.style.cssText="padding:0;border:0;height:0",n.appendChild(e)}else n=document.createElement("div"),n.style.width="100%";return n.dataset.virtualSpacer="",n.setAttribute("aria-hidden","true"),n.style.height="0px",n.style.padding="0",n.style.margin="0",n.style.border="0",n.style.background="none",n.style.pointerEvents="none",n}function o(e,t){for(const n of e.children){if("TEMPLATE"===n.tagName)continue;const e=n.getBoundingClientRect();e.width||e.height?(e.top<t.top&&(t.top=e.top),e.bottom>t.bottom&&(t.bottom=e.bottom)):"contents"===getComputedStyle(n).display&&o(n,t)}}function r(e,t){e.style.gridColumn="grid"===t?"1 / -1":"",e.style.flex="flex"===t?"0 0 100%":""}function i(e,t){const n=Math.max(0,t)+"px";e.style.height=n,e.firstElementChild&&"TR"===e.tagName&&(e.firstElementChild.style.height=n)}let l=!1;function s(){l||window.Alpine&&"function"==typeof window.Alpine.directive&&(l=!0,e())}if(window.ensureVirtualPluginInitialized=s,"loading"===document.readyState&&document.addEventListener("DOMContentLoaded",s),document.addEventListener("alpine:init",s),window.Alpine&&"function"==typeof window.Alpine.directive)setTimeout(s,0);else{const e=setInterval(()=>{window.Alpine&&"function"==typeof window.Alpine.directive&&(clearInterval(e),s())},10);setTimeout(()=>clearInterval(e),5e3)}}();
1
+ !function(){const t=/^\s*\(?\s*([A-Za-z_$][\w$]*)\s*(?:,\s*([A-Za-z_$][\w$]*)\s*)?\)?\s+(?:in|of)\s+(.+?)\s*$/;function e(e){const n=e.getAttribute("x-for");if(null===n||!t.test(n))return;e.setAttribute("data-virtual-for",n);const o=e.getAttribute(":key")??e.getAttribute("x-bind:key");null!==o&&e.setAttribute("data-virtual-key",o),e.removeAttribute("x-for"),e.removeAttribute(":key"),e.removeAttribute("x-bind:key")}function n(){"function"==typeof Alpine.interceptInit&&Alpine.interceptInit(t=>{if(1!==t.nodeType||!function(t){if(t.hasAttribute("x-virtual"))return!0;for(const e of t.attributes)if(e.name.startsWith("x-virtual."))return!0;return!1}(t)||t.hasAttribute("x-ignore"))return;const n=t.querySelector("template[x-for]");n&&e(n)});const n=Alpine.reactive([]).some!==Array.prototype.some,c=()=>!0;Alpine.directive("virtual",(a,{expression:u},{evaluate:f,evaluateLater:d,effect:p,cleanup:h})=>{const g=a.querySelector("template[x-for], template[data-virtual-for]")||a.querySelector(":scope template");g&&e(g);const m=g&&(g.getAttribute("data-virtual-for")??g.getAttribute("x-for"));if(!m)return void(a.querySelector("[data-virtual-spacer]")||console.warn('[x-virtual] expects a descendant <template> with x-for, e.g. <template x-for="row in $x.items" :key="row.id">…'));const y=t.exec(m);if(!y)return void console.warn("[x-virtual] could not parse x-for expression: "+m);const v=y[1],b=y[2]||null,A=y[3].trim(),w=g.getAttribute("data-virtual-key")||`${v}.id`;g.removeAttribute("data-virtual-for"),g.removeAttribute("data-virtual-key");const x=u&&f(u)||{},S=x.estimate,T=S&&"object"==typeof S?Number(S.height)||50:Number(S)>0?Number(S):50,C=S&&"object"==typeof S&&Number(S.width)||120,E=Number.isFinite(x.overscan)&&x.overscan>=0?Number(x.overscan):3,N=a,F=g.parentElement,k=getComputedStyle(N);"visible"===k.overflow&&"visible"===k.overflowY&&(N.style.overflow="auto");const M="masonry"===x.mode;let B=o(F),L=!1;const $=Number(x.columns)>0?Math.floor(x.columns):0,q=Number(x.columnWidth)>0?Number(x.columnWidth):0,W="function"==typeof x.span?x.span:null,I="function"==typeof x.height?x.height:null,R=Number.isFinite(x.gap)?Number(x.gap):parseFloat(k.gap)||0;M&&"static"===k.position&&(N.style.position="relative");const z=g.content.firstElementChild?g.content.firstElementChild.children.length:1;let O,H,j;function D(){l(O,B),l(H,B),L="gallery"===(x.mode||function(t,e){return"flex"===t&&(getComputedStyle(e).flexWrap||"").startsWith("wrap")?"gallery":"rows"}(B,F))}M?(j=document.createElement("div"),j.dataset.virtualSpacer="",j.setAttribute("aria-hidden","true"),j.style.cssText="position:absolute;top:0;left:0;width:1px;height:0;pointer-events:none",F.appendChild(j)):(O=r(B,z),H=r(B,z),F.insertBefore(O,g),F.insertBefore(H,g),B&&D());const G=M?j:H,P=new Map,Y=new Map;let Z=0,_=0;const V=new Map;let J,K=[],Q=[],U=new Float64Array(1),X=-1,tt=[],et=[],nt=[],ot=0,rt=0,it=!1,lt=null;const st=function(t,e,n){const o=t=>t&&"object"==typeof t&&window.Alpine&&Alpine.raw?Alpine.raw(t):t;try{const r=e?new Function(t,e,`return (${n});`):new Function(t,`return (${n});`);return(t,e)=>{try{return o(r(o(t),e))}catch{return o(t)}}}catch{return t=>o(t)}}(v,b,w),ct=()=>_>0?Z/_:T,at=t=>P.get(t)??ct(),ut=t=>Y.get(t)??C,ft=(t,e)=>I?Number(I(t))||T:at(st(t,e));function dt(){M?function(){const t=St(),e=R;let n=$||(q?Math.max(1,Math.floor((t+e)/(q+e))):3);const o=(t-(n-1)*e)/n,r=new Float64Array(n),i=K.length;et=new Array(i),rt=0;const l=!(!W&&!I);for(let t=0;t<i;t++){const i=l?K[t]:Q[t];let s=W?0|W(i):1;s<1?s=1:s>n&&(s=n);const c=ft(i,t);let a=0,u=1/0;for(let t=0;t+s<=n;t++){let e=0;for(let n=0;n<s;n++)r[t+n]>e&&(e=r[t+n]);e<u&&(u=e,a=t)}const f=s*o+(s-1)*e;et[t]={x:a*(o+e),y:u,w:f,h:c};const d=u+c+e;for(let t=0;t<s;t++)r[a+t]=d;c>rt&&(rt=c)}let s=0;for(let t=0;t<n;t++)r[t]>s&&(s=r[t]);ot=s>0?s-e:0,nt=Array.from({length:i},(t,e)=>e).sort((t,e)=>et[t].y-et[e].y)}():L?function(){const t=St(),e=function(){const t=getComputedStyle(N);return parseFloat(t.columnGap||t.gap||0)||0}(),n=function(){const t=getComputedStyle(N);return parseFloat(t.rowGap||t.gap||0)||0}();tt=[];let o=0;const r=K.length;for(;o<r;){const n=o;let i=0,l=0;for(;o<r;){const n=st(Q[o],o),r=ut(n),s=0===i?r:e+r;if(i>0&&i+s>t)break;i+=s,l=Math.max(l,at(n)),o++}o===n&&o++,tt.push({start:n,end:o,height:l})}U=new Float64Array(tt.length+1);let i=0;for(let t=0;t<tt.length;t++)U[t]=i,i+=tt[t].height+n;U[tt.length]=tt.length?i-n:0}():function(){const t=K.length;U=new Float64Array(t+1);let e=0;for(let n=0;n<t;n++)U[n]=e,e+=at(st(Q[n],n));U[t]=e}()}function pt(t,e){let n=0,o=e;for(;n<o;){const e=n+o>>>1;U[e+1]<=t?n=e+1:o=e}return n}function ht(t){const e=K.length?st(K[0],0):void 0;(K.length<X||e!==J)&&(X=-1),J=e,t&&K.length&&X!==K.length&&(X=K.length,a.dispatchEvent(new CustomEvent("virtual-end",{bubbles:!0,detail:{length:K.length}})))}function gt(){if(M)return function(){if(!K.length)return bt(),void(j.style.height="0px");const t=N.clientHeight;if(!t)return!1;it=!0,j.style.height=ot+"px";const e=E*ct(),n=N.scrollTop-e,o=N.scrollTop+t+e;let r=0,i=nt.length;const l=n-rt;for(;r<i;){const t=r+i>>>1;et[nt[t]].y<l?r=t+1:i=t}const s=new Set,c=[];for(let t=r;t<nt.length;t++){const e=nt[t],r=et[e];if(r.y>o)break;if(r.y+r.h<n)continue;const i=K[e];if(null==i)continue;const l=st(i,e);if(null==l)continue;s.add(l),c.push(l);let a=V.get(l);a?mt(a,i,e):a=yt(i,l,G,e);const u=a.node.style;u.position="absolute",u.left=r.x+"px",u.top=r.y+"px",u.width=r.w+"px"}for(const[t,e]of V)s.has(t)||vt(t,e);ht(s.has(st(K[K.length-1],K.length-1))),wt(c)}();if(!K.length)return bt(),s(O,0),void s(H,0);const t=N.clientHeight;if(!t||!(B||M||(B=o(F))&&(lt&&F!==N&&lt.unobserve(F),D(),dt(),1)))return!1;it=!0;const e=L?tt.length:K.length,n=Math.max(0,N.scrollTop-function(){const t=N.getBoundingClientRect();return O.getBoundingClientRect().top-t.top+N.scrollTop}());let r=pt(n,e)-E;r<0&&(r=0);let i=pt(n+t,e)+1+E;i>e&&(i=e),s(O,U[r]),s(H,U[e]-U[i]);const l=L?tt[r].start:r,c=L?tt[i-1].end:i;ht(c>=K.length);const a=new Set,u=[],f=[],d=[];for(let t=l;t<c;t++){const e=K[t];if(null==e)continue;const n=st(e,t);null!=n&&(a.add(n),u.push(n),f.push(e),d.push(t))}for(const[t,e]of V)a.has(t)||vt(t,e);const p=new Set;for(const t of V.values())p.add(t.node);const h=t=>{for(;t&&t!==H&&t.parentNode===F&&!p.has(t);)t=t.nextSibling;return t&&t.parentNode===F?t:H};let g=h(O.nextSibling);for(let t=0;t<u.length;t++){g.parentNode!==F&&(g=H);let e=V.get(u[t]);e?(mt(e,f[t],d[t]),e.node===g?g=h(g.nextSibling):F.insertBefore(e.node,g)):(e=yt(f[t],u[t],g,d[t]),p.add(e.node),e.node.parentNode!==F&&F.insertBefore(e.node,g))}wt(u)}function mt(t,e,n){t.scope[v]!==e&&(t.scope[v]=e),b&&t.scope[b]!==n&&(t.scope[b]=n)}function yt(t,e,n=G,o){const r=g.content.firstElementChild.cloneNode(!0);F.insertBefore(r,n);const i=Alpine.reactive(b?{[v]:t,[b]:o}:{[v]:t}),l=Alpine.addScopeToNode(r,i);Alpine.initTree(r);const s={node:r,scope:i,removeScope:l};return V.set(e,s),s}function vt(t,e){e.removeScope&&e.removeScope(),Alpine.destroyTree&&Alpine.destroyTree(e.node),e.node.remove(),V.delete(t)}function bt(){for(const[t,e]of V)vt(t,e)}let At=!1;function wt(t){if(M&&I)return;const e=[];for(const n of t){(L?!P.has(n)||!Y.has(n):!P.has(n))&&V.has(n)&&e.push(n)}e.length&&!At&&(At=!0,requestAnimationFrame(()=>{At=!1;let t=!1;for(const n of e){const e=V.get(n);e&&xt(n,e.node)&&(t=!0)}t&&(dt(),gt())}))}function xt(t,e){if(!e.isConnected)return!1;const n=function(t){if("contents"!==getComputedStyle(t).display)return t.offsetHeight;const e={top:1/0,bottom:-1/0};return i(t,e),e.bottom>e.top?e.bottom-e.top:0}(e);if(!n)return!1;let o=!1;const r=P.get(t);if(r!==n&&(void 0!==r?Z-=r:_++,Z+=n,P.set(t,n),o=!0),L){const n=e.offsetWidth;n&&Y.get(t)!==n&&(Y.set(t,n),o=!0)}return o}function St(){const t=getComputedStyle(N);return N.clientWidth-parseFloat(t.paddingLeft||0)-parseFloat(t.paddingRight||0)}const Tt=d(A);p(()=>{Tt(t=>{!function(t){if(Array.isArray(t))if(t.length,n)t.some(c);else for(let e=0;e<t.length;e++)t[e]}(t),K=Array.isArray(t)?t:t?Array.from(t):[],Q=Alpine.raw?Alpine.raw(K):K,dt(),!1===gt()&&V.size&&function(){const t=new Set;for(let e=0;e<Q.length;e++)null!=Q[e]&&t.add(st(Q[e],e));for(const[e,n]of V)t.has(e)||vt(e,n)}()})});let Ct=!1,Et=!1;const Nt=()=>{Et||(Et=!0,requestAnimationFrame(()=>{Et=!1,Ct||gt()}))};N.addEventListener("scroll",Nt,{passive:!0});let Ft=null;lt=new ResizeObserver(()=>{it?(clearTimeout(Ft),Ft=setTimeout(()=>{dt(),gt()},100)):requestAnimationFrame(()=>{dt(),gt()})}),lt.observe(N),B||M||F===N||lt.observe(F),h(()=>{Ct=!0,N.removeEventListener("scroll",Nt),lt.disconnect(),clearTimeout(Ft),bt(),M?j.remove():(O.remove(),H.remove())})})}function o(t){const e=t.tagName;if("TBODY"===e||"THEAD"===e||"TFOOT"===e||"TABLE"===e)return"table";const n=getComputedStyle(t).display;return"none"===n?null:n.includes("grid")?"grid":n.includes("flex")?"flex":"block"}function r(t,e){let n;if("table"===t){n=document.createElement("tr");const t=document.createElement("td");e>1&&(t.colSpan=e),t.style.cssText="padding:0;border:0;height:0",n.appendChild(t)}else n=document.createElement("div"),n.style.width="100%";return n.dataset.virtualSpacer="",n.setAttribute("aria-hidden","true"),n.style.height="0px",n.style.padding="0",n.style.margin="0",n.style.border="0",n.style.background="none",n.style.pointerEvents="none",n}function i(t,e){for(const n of t.children){if("TEMPLATE"===n.tagName)continue;const t=n.getBoundingClientRect();t.width||t.height?(t.top<e.top&&(e.top=t.top),t.bottom>e.bottom&&(e.bottom=t.bottom)):"contents"===getComputedStyle(n).display&&i(n,e)}}function l(t,e){t.style.gridColumn="grid"===e?"1 / -1":"",t.style.flex="flex"===e?"0 0 100%":""}function s(t,e){const n=Math.max(0,e)+"px";t.style.height=n,t.firstElementChild&&"TR"===t.tagName&&(t.firstElementChild.style.height=n)}let c=!1;function a(){c||window.Alpine&&"function"==typeof window.Alpine.directive&&(c=!0,n())}if(window.ensureVirtualPluginInitialized=a,"loading"===document.readyState&&document.addEventListener("DOMContentLoaded",a),document.addEventListener("alpine:init",a),window.Alpine&&"function"==typeof window.Alpine.directive)setTimeout(a,0);else{const t=setInterval(()=>{window.Alpine&&"function"==typeof window.Alpine.directive&&(clearInterval(t),a())},10);setTimeout(()=>clearInterval(t),5e3)}}();
2
2
  //# sourceMappingURL=manifest.virtual.min.js.map