1import{$ as e,At as t,B as n,F as r,H as i,I as a,M as o,P as s,Tt as c,V as l,W as u,at as d,ft as f,h as p,it as m,jt as h,k as g,kt as _,l as v,ot as y,rt as b,st as x,t as S,v as C,vt as w,w as T,wt as E,z as D}from"./DrVZr9bS.js";import{s as O}from"./DNtujeDB.js";import{t as k}from"./a9nU1Rkd.js";import{r as A}from"./Q_Hq-pae.js";import{n as j}from"./CzvAPXTe.js";import"./DTt4N8vO.js";import{n as M,t as N}from"./DtlB2_cG.js";import{n as P,t as F}from"./C9Hg4rJI.js";import{t as I}from"./Ccx0F-iA.js";import{n as L}from"./DTmq9fmi.js";import{n as R}from"./CEDBCaHY.js";var z=a(`<div class="tw:fixed tw:inset-0 tw:z-1040 tw:bg-black/50" role="presentation"></div> <div class="tw:fixed tw:top-0 tw:right-0 tw:bottom-0 tw:z-1045 tw:w-100 tw:max-w-full tw:translate-x-0 tw:border-l tw:border-gray-200 tw:bg-white tw:shadow-lg" tabindex="-1" aria-modal="true" role="dialog"><div class="tw:flex tw:items-center tw:justify-between tw:p-4"><!> <button type="button" class="tw:mb-1 tw:border-0 tw:bg-transparent tw:p-0 tw:text-plum tw:hover:text-amber-500" aria-label="Close"><svg height="24" width="24"><title>Close offcanvas</title><use href="/images/icons/icons.svg#x"></use></svg></button></div> <div class="tw:p-4"><!></div></div>`,1);function B(n,a){c(a,!0);let y=j(),S=w(()=>`${a.id}Title`),M=w(()=>A.url.hash===`#${a.id}`),N=w(()=>(A.url,!1)),B=w(()=>u(M)&&!u(N)),V,H=e=>{V=R(),y.formInvalid=!1;let t=L(()=>a.focusField)(e);return()=>{t(),V?.()}},U=()=>{if(document.referrer.startsWith(A.url.origin))history.back();else{let e=A.url.pathname+A.url.search;O(k(e),{replace:!1})}},W=()=>{u(B)&&(f(N,!0),y.formInvalid=!1,V?.())},G=()=>{u(N)&&U()},K=e=>{u(B)&&e.key===`Escape`&&(e.stopPropagation(),W())},q=e=>{e.stopPropagation(),W()};var J={close:W},Y=r();i(`keydown`,b,K);var X=d(Y),Z=n=>{var r=z(),c=d(r),f=x(c,2),y=m(f),b=m(y);I(b,{get id(){return u(S)},children:(t,n)=>{_();var r=D();e(()=>o(r,a.title)),s(t,r)},$$slots:{default:!0}});var w=x(b,2);t(y);var T=x(y,2),E=m(T);g(E,()=>a.children??h),t(T),t(f),p(f,()=>H),e(()=>{v(f,`id`,a.id),v(f,`aria-labelledby`,u(S))}),l(`click`,c,q),i(`outroend`,c,G),C(3,c,()=>F,()=>({duration:300})),l(`click`,w,W),C(3,f,()=>P,()=>({x:400,duration:300})),s(n,r)};return T(X,e=>{u(B)&&e(Z)}),s(n,Y),E(J)}n([`click`]);var V=a(`<button> </button>`);function H(t,n){c(n,!0);let r=j(),i=S(n,`label`,3,`Add to Cart`),a=S(n,`title`,3,`Add to cart button`),u=S(n,`disabled`,3,!1),d=e=>{let t=N(r.products,e);if(!t)throw Error(`Error: product ID ${e} not found.`);let n=t,i=M.items.find(t=>t.product.id===e);i?i.quantity++:M.items.push({product:n,quantity:1}),document.getElementById(`cart`)?.click()};var f=V(),p=y(f,!0);e(()=>
1{v(f,`id`,`product${n.productId??``}`),v(f,`title`,a()),f.disabled=u(),o(p,i())}),l(`click`,f,()=>d(n.productId)),s(t,f),E()}n([`click`]);export{B as n,H as t};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.