PageSourceSearch

https://vwd.ai/assets/Help-Js1fPtTF.js

js vwd.ai collected 2026-10-05 13:19:54 UTC 24,361 bytes, 1 lines download raw bytes

1var Re=t=>{throw TypeError(t)};var he=(t,e,s)=>e.has(t)||Re("Cannot "+s);var r=(t,e,s)=>(he(t,e,"read from private field"),s?s.call(t):e.get(t)),R=(t,e,s)=>e.has(t)?Re("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,s),x=(t,e,s,i)=>(he(t,e,"write to private field"),i?i.call(t,s):e.set(t,s),s),v=(t,e,s)=>(he(t,e,"access private method"),s);import{aq as Me,ar as Se,as as $,at as ue,au as te,av as pe,aw as me,ax as Ne,ay as ze,az as Pe,aA as qe,aB as Ce,aC as Qe,r as w,aD as Be,aE as Ve,e as We,j as a,d as Ge,L as B,C as Te,i as De,F as Ke,s as ne}from"./index-C9cYLvaG.js";import{p as Ie}from"./purify.es-t2lEkcJL.js";import{r as le}from"./retryQuery-CnZbuuE2.js";import{S as Ze}from"./search-De3hC7tv.js";import{E as Ye}from"./external-link-Cg02cm9_.js";var C,d,se,S,F,G,k,L,re,K,Z,A,H,Q,Y,g,ee,fe,ge,be,xe,ye,_e,ve,Fe,Le,Je=(Le=class extends Me{constructor(e,s){super();R(this,g);R(this,C);R(this,d);R(this,se);R(this,S);R(this,F);R(this,G);R(this,k);R(this,L);R(this,re);R(this,K);R(this,Z);R(this,A);R(this,H);R(this,Q);R(this,Y,new Set);this.options=s,x(this,C,e),x(this,L,null),x(this,k,Se()),this.options.experimental_prefetchInRender||r(this,k).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(s)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(r(this,d).addObserver(this),Ee(r(this,d),this.options)?v(this,g,ee).call(this):this.updateResult(),v(this,g,xe).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return we(r(this,d),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return we(r(this,d),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,v(this,g,ye).call(this),v(this,g,_e).call(this),r(this,d).removeObserver(this)}setOptions(e){const s=this.options,i=r(this,d);if(this.options=r(this,C).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof $(this.options.enabled,r(this,d))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");v(this,g,ve).call(this),r(this,d).setOptions(this.options),s._defaulted&&!ue(this.options,s)&&r(this,C).getQueryCache().notify({type:"observerOptionsUpdated",query:r(this,d),observer:this});const o=this.hasListeners();o&&$e(r(this,d),i,this.options,s)&&v(this,g,ee).call(this),this.updateResult(),o&&(r(this,d)!==i||$(this.options.enabled,r(this,d))!==$(s.enabled,r(this,d))||te(this.options.staleTime,r(this,d))!==te(s.staleTime,r(this,d)))&&v(this,g,fe).call(this);const h=v(this,g,ge).call(this);o&&(r(this,d)!==i||$(this.options.enabled,r(this,d))!==$(s.enabled,r(this,d))||h!==r(this,Q))&&v(this,g,be).call(this,h)}getOptimisticResult(e){const s=r(this,C).getQueryCache().build(r(this,C),e),i=this.createResult(s,e);return et(this,i)&&(x(this,S,i),x(this,G,this.options),x(this,F,r(this,d).state)),i}getCurrentResult(){return r(this,S)}trackResult(e,s){return new Proxy(e,{get:(i,o)=>(this.trackProp(o),s==null||s(o),Reflect.get(i,o))})}trackProp(e){r(this,Y).add(e)}getCurrentQuery(){return r(this,d)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const s=r(this,C).defaultQueryOptions(e),i=r(this,C).getQueryCache().build(r(this,C),s);return i.fetch().then(()=>this.createResult(i,s))}fetch(e){return v(this,g,ee).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),r(this,S)))}createResult(e,s){var j;const i=r(this,d),o=this.options,h=r(this,S),n=r(this,F),y=r(this,G),c=e!==i?e.state:r(this,se),{state:N}=e;let m={...N},D=!1,b;if(s._optimisticResults){const p=this.hasListeners(),P=!p&&Ee(e,s),q=p&&$e(e,i,s,o);(P||q)&&(m={...m,...qe(N.data,e.options)}),s._optimisticResults==="isRestoring"&&(m.fetchStatus="idle")}let{error:I,errorUpdatedAt:E,status:_}=m;b=m.data;let U=!1;if(s.placeholderData!==void 0&&b===void 0&&_==="pending"){let p;h!=null&&h.isPlaceholderData&&s.placeholderData===(y==null?void 0:y.placeholderData)?(p=h.data,U=!0):p=typeof s.placeholderData=="function"?s.placeholderData((j=r(this,Z))==null?void 0:j.state.data,r(this,Z)):s.placeholderData,p!==void 0&&(_="success",b=Ce(h==null?void 0:h.data,p,s),D=!0)}if(s.select&&b!==void 0&&!U)if(h&&b===(n==null?void 0:n.data)&&s.select===r(this,re))b=r(this,K);else try{x(this,re,s.select),b=s.select(b),b=Ce(h==null?void 0:h.data,b,s),x(this,K,b),x(this,L,null)}catch(p){x(this,L,p)}r(this,L)&&(I=r(this,L),b=r(this,K),E=Date.now(),_="error");const M=m.fetchStatus==="fetching",J=_==="pending",z=_==="error",ie=J&&M,X=b!==void 0,f={status:_,fetchStatus:m.fetchStatus,isPending:J,isSuccess:_==="success",isError:z,isInitialLoading:ie,isLoading:ie,data:b,dataUpdatedAt:m.dataUpdatedAt,error:I,errorUpdatedAt:E,failureCount:m.fetchFailureCount,failureReason:m.fetchFailureReason,errorUpdate
1Count:m.errorUpdateCount,isFetched:m.dataUpdateCount>0||m.errorUpdateCount>0,isFetchedAfterMount:m.dataUpdateCount>c.dataUpdateCount||m.errorUpdateCount>c.errorUpdateCount,isFetching:M,isRefetching:M&&!J,isLoadingError:z&&!X,isPaused:m.fetchStatus==="paused",isPlaceholderData:D,isRefetchError:z&&X,isStale:je(e,s),refetch:this.refetch,promise:r(this,k),isEnabled:$(s.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const p=ae=>{f.status==="error"?ae.reject(f.error):f.data!==void 0&&ae.resolve(f.data)},P=()=>{const ae=x(this,k,f.promise=Se());p(ae)},q=r(this,k);switch(q.status){case"pending":e.queryHash===i.queryHash&&p(q);break;case"fulfilled":(f.status==="error"||f.data!==q.value)&&P();break;case"rejected":(f.status!=="error"||f.error!==q.reason)&&P();break}}return f}updateResult(){const e=r(this,S),s=this.createResult(r(this,d),this.options);if(x(this,F,r(this,d).state),x(this,G,this.options),r(this,F).data!==void 0&&x(this,Z,r(this,d)),ue(s,e))return;x(this,S,s);const i=()=>{if(!e)return!0;const{notifyOnChangeProps:o}=this.options,h=typeof o=="function"?o():o;if(h==="all"||!h&&!r(this,Y).size)return!0;const n=new Set(h??r(this,Y));return this.options.throwOnError&&n.add("error"),Object.keys(r(this,S)).some(y=>{const l=y;return r(this,S)[l]!==e[l]&&n.has(l)})};v(this,g,Fe).call(this,{listeners:i()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&v(this,g,xe).call(this)}},C=new WeakMap,d=new WeakMap,se=new WeakMap,S=new WeakMap,F=new WeakMap,G=new WeakMap,k=new WeakMap,L=new WeakMap,re=new WeakMap,K=new WeakMap,Z=new WeakMap,A=new WeakMap,H=new WeakMap,Q=new WeakMap,Y=new WeakMap,g=new WeakSet,ee=function(e){v(this,g,ve).call(this);let s=r(this,d).fetch(this.options,e);return e!=null&&e.throwOnError||(s=s.catch(pe)),s},fe=function(){v(this,g,ye).call(this);const e=te(this.options.staleTime,r(this,d));if(me||r(this,S).isStale||!Ne(e))return;const i=ze(r(this,S).dataUpdatedAt,e)+1;x(this,A,setTimeout(()=>{r(this,S).isStale||this.updateResult()},i))},ge=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(r(this,d)):this.options.refetchInterval)??!1},be=function(e){v(this,g,_e).call(this),x(this,Q,e),!(me||$(this.options.enabled,r(this,d))===!1||!Ne(r(this,Q))||r(this,Q)===0)&&x(this,H,setInterval(()=>{(this.options.refetchIntervalInBackground||Pe.isFocused())&&v(this,g,ee).call(this)},r(this,Q)))},xe=function(){v(this,g,fe).call(this),v(this,g,be).call(this,v(this,g,ge).call(this))},ye=function(){r(this,A)&&(clearTimeout(r(this,A)),x(this,A,void 0))},_e=function(){r(this,H)&&(clearInterval(r(this,H)),x(this,H,void 0))},ve=function(){const e=r(this,C).getQueryCache().build(r(this,C),this.options);if(e===r(this,d))return;const s=r(this,d);x(this,d,e),x(this,se,e.state),this.hasListeners()&&(s==null||s.removeObserver(this),e.addObserver(this))},Fe=function(e){Qe.batch(()=>{e.listeners&&this.listeners.forEach(s=>{s(r(this,S))}),r(this,C).getQueryCache().notify({query:r(this,d),type:"observerResultsUpdated"})})},Le);function Xe(t,e){return $(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&e.retryOnMount===!1)}function Ee(t,e){return Xe(t,e)||t.state.data!==void 0&&we(t,e,e.refetchOnMount)}function we(t,e,s){if($(e.enabled,t)!==!1&&te(e.staleTime,t)!=="static"){const i=typeof s=="function"?s(t):s;return i==="always"||i!==!1&&je(t,e)}return!1}function $e(t,e,s,i){return(t!==e||$(i.enabled,t)===!1)&&(!s.suspense||t.state.status!=="error")&&je(t,s)}function je(t,e){return $(e.enabled,t)!==!1&&t.isStaleByTime(te(e.staleTime,t))}function et(t,e){return!ue(t.getCurrentResult(),e)}var Ae=w.createContext(!1),tt=()=>w.useContext(Ae);Ae.Provider;function st(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var rt=w.createContext(st()),it=()=>w.useContext(rt),at=(t,e)=>{(t.suspense||t.throwOnError||t.experimental_prefetchInRender)&&(e.isReset()||(t.retryOnMount=!1))},nt=t=>{w.useEffect(()=>{t.clearReset()},[t])},lt=({result:t,errorResetBoundary:e,throwOnError:s,query:i,suspense:o})=>t.isError&&!e.isReset()&&!t.isFetching&&i&&(o&&t.data===void 0||Be(s,[t.error,i])),ot=t=>{if(t.suspense){const e=i=>i==="static"?i:Math.max(i??1e3,1e3),s=t.staleTime;t.staleTime=typeof s=="function"?(...i)=>e(s(...i)):e(s),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3))}},ct=(t,e)=>t.isLoading&&t.isFetching&&!e,ht=(t,e)=>(t==null?void 0:t.suspense)&&e.isPending,Oe=(t,e,s)=>e.fetchOptimistic(t).catch(()=>{s.clearReset()});function dt(t,e,s){var m,D,b,I,E;const i=tt(),o=it(),h=Ve(),n=h.defaultQueryOptions(t);(D=(m=h.getDefaultOptions().queries)==null?void 0:m._experimental_beforeQuery)==null||D.call(m,n),n._optimisticResults=i?"isRestoring":"optimistic",ot(n),at(n,o),nt(o);const y=!h.getQueryCache().get(n.queryHash),[l]=w.useState(()=>new e(h,n)),c=l.getOptimisticResult(n),N=!i&&t.subscribed!==!1;if(w.useSyncExternalStore(w.useCallback(_=>{const U=N?l.subscribe(Qe.batchCalls(_)):pe;return l.updateResult(),U},[l,N]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),w.useEffect(()=>{l.setOptions(n)},[n,l]),ht(n,c))throw Oe(n,l,o);if(lt({result:c,errorResetBoundary:o,throwOnError:n.throwOnError,query:h.getQueryCache().get(n.queryHash),suspense:n.suspense}))throw c.error;if((I=(b=h.getDefaultOptions().queries)==null?void 0:b._experimental_afterQuery)==null||I.call(b,n,c),n.experimental_prefetchInRender&&!me&&ct(c,i)){const _=y?Oe(n,l,o):(E=h.getQueryCache().get(n.queryHash))==null?void 0:E.promise;_==null||_.catch(pe).finally(()=>{l.updateResult()})}return n.notifyOnChangeProps?c:l.trackResult(c)}function oe(t,e){return dt(t,Je)}const ut="bg-[hsl(220_30%_98%)]",pt="bg-white",O="text-[hsl(225_40%_12%)]",T="text-[hsl(225_15%_45%)]",V="border-[hsl(225_15%_88%)]",ke="text-[hsl(2
163_85%_58%)]",mt=typeof window<"u"&&window.location.hostname==="help.vwd.ai",W=t=>mt?t==="/help"?"/":t.startsWith("/help/")?t.slice(5):t:t,He=t=>{const e=document.createElement("textarea");return e.innerHTML=t,e.value},ft=t=>{try{const e=new URL(He(t));if(e.hostname==="youtu.be"){const s=e.pathname.split("/").filter(Boolean)[0];return s?`https://www.youtube.com/embed/${s}`:null}if(e.hostname.includes("youtube.com")){const s=e.searchParams.get("v")||e.pathname.split("/").filter(Boolean).pop();return s?`https://www.youtube.com/embed/${s}`:null}}catch{return null}return null},gt=t=>{try{const e=new URL(He(t));if(!e.hostname.includes("guidde.com"))return null;const s=e.pathname.split("/").filter(Boolean),i=s.indexOf("playbooks"),o=i>=0?s[i+1]:s[s.length-1];if(!o)return null;const h=e.searchParams.get("mode")??"videoAndDoc";return`https://embed.app.guidde.com/playbooks/${o}?mode=${h}`}catch{return null}},de=t=>{const e=ft(t);if(e)return`<figure class="help-video"><iframe src="${e}" title="Help video" loading="lazy" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe></figure>`;const s=gt(t);return s?`<figure class="help-guidde"><iframe src="${s}" title="Help walkthrough" loading="lazy" referrerpolicy="unsafe-url" allow="clipboard-write" allowfullscreen sandbox="allow-popups allow-popups-to-escape-sandbox allow-scripts allow-forms allow-same-origin allow-presentation"></iframe></figure>`:""},bt=t=>{var h;if(!t)return"";const e=t.match(/<article\b[^>]*class=["'][^"']*\barticle\b[^"']*["'][^>]*>([\s\S]*?)<\/article>/i),s=t.match(/<body\b[^>]*>([\s\S]*?)<\/body>/i);let i=(e==null?void 0:e[1])??(s==null?void 0:s[1])??t;i=i.replace(/<figure\b[^>]*class=["'][^"']*\bmedia\b[^"']*["'][^>]*>[\s\S]*?<\/figure>/gi,n=>{var l,c;const y=((l=n.match(/data-oembed-url=["']([^"']+)["']/i))==null?void 0:l[1])??((c=n.match(/src=["']([^"']+)["']/i))==null?void 0:c[1]);return y?de(y):""}),i=i.replace(/<iframe\b[^>]*src=["']([^"']*guidde\.com[^"']*)["'][^>]*>\s*<\/iframe>/gi,(n,y)=>de(y)||n);const o=(h=i.match(/https?:\/\/[^\s"'<>]*guidde\.com\/playbooks\/[A-Za-z0-9]+(?:\?[^\s"'<>]*)?/i))==null?void 0:h[0];if(o&&!/guidde\.com[^"']*"[^>]*><\/iframe>/i.test(i)&&!/class=["']help-guidde["']/i.test(i)){const n=de(o);n&&(i=n+i)}return i=i.replace(/<a\b[^>]*href=["'][^"']*guidde\.com\/playbooks\/[^"']*["'][^>]*>[\s\S]*?<\/a>/gi,""),i=i.replace(/<p\b[^>]*>\s*(?:https?:\/\/)?[^\s<]*guidde\.com\/playbooks\/[^\s<]*\s*<\/p>/gi,""),i=i.replace(/(?:https?:\/\/)?[^\s<>"']*guidde\.com\/playbooks\/[A-Za-z0-9]+(?:\?[^\s<>"']*)?/gi,n=>n.includes("embed.app.guidde.com")?n:""),i=i.replace(/<!doctype[^>]*>/gi,"").replace(/<\/?(?:html|head|body)[^>]*>/gi,"").replace(/<(?:script|style|link|meta|title|next-route-announcer)\b[\s\S]*?<\/(?:script|style|link|meta|title|next-route-announcer)>/gi,"").replace(/<(?:link|meta)\b[^>]*>/gi,"").replace(/<h1\b[\s\S]*?<\/h1>/i,"").replace(/<div\b[^>]*class=["'][^"']*\bmt-2\b[^"']*\btext-lg\b[^"']*["'][^>]*>[\s\S]*?<\/div>/i,"").trim(),i=i.replace(/<iframe\b[^>]*>[\s\S]*?<\/iframe>|<iframe\b[^>]*\/?>/gi,n=>{var l;const y=((l=n.match(/src=["']([^"']+)["']/i))==null?void 0:l[1])??"";return/^https:\/\/(?:[a-z0-9-]+\.)*(?:guidde\.com|youtube\.com|youtube-nocookie\.com|youtu\.be)\//i.test(y)?n:""}),Ie.sanitize(i,{ADD_TAGS:["iframe"],ADD_ATTR:["allow","allowfullscreen","frameborder","scrolling","loading","referrerpolicy","target"],FORBID_TAGS:["script","style","object","embed","form","link","meta"],FORBID_ATTR:["onerror","onload","onclick","onmouseover","onfocus","onanimationend","srcdoc"]})},ce=5*60*1e3,Ue=t=>t?Ie.sanitize(t,{ALLOWED_TAGS:["mark"],ALLOWED_ATTR:[]}):null;function St({allMode:t=!1}){var X;const{slug:e}=We(),s=oe({queryKey:["help-categories"],staleTime:ce,queryFn:async()=>{const{data:u,error:f}=await le(j=>ne.from("help_categories").select("id, slug, name, sort_order").order("sort_order").abortSignal(j).then(p=>({data:p.data,error:p.error})));if(f)throw f;return u??[]}}),i=oe({queryKey:["help-articles"],staleTime:ce,queryFn:async()=>{const{data:u,error:f}=await le(j=>ne.from("help_articles").select("id, slug, title, excerpt, category_id").eq("published",!0).order("title").abort
1Signal(j).then(p=>({data:p.data,error:p.error})));if(f)throw f;return u??[]}}),o=oe({queryKey:["help-article",e],enabled:!!e,staleTime:ce,queryFn:async()=>{const{data:u,error:f}=await le(j=>ne.from("help_articles").select("id, slug, title, excerpt, category_id, body_html, source_url, seo_title, seo_description, published_at").eq("slug",e).eq("published",!0).abortSignal(j).maybeSingle().then(p=>({data:p.data,error:p.error})));if(f)throw f;return u??null}}),h=w.useMemo(()=>s.data??[],[s.data]),n=w.useMemo(()=>i.data??[],[i.data]),y=s.isLoading||i.isLoading,l=e?o.data??null:null,c=!!e&&o.isLoading,N=e?o.error?((X=o.error)==null?void 0:X.message)??"Could not load this article.":!o.isLoading&&!o.data?"Article not found.":null:null,[m,D]=w.useState(""),[b,I]=w.useState("");w.useEffect(()=>{const u=setTimeout(()=>I(m.trim()),250);return()=>clearTimeout(u)},[m]);const E=b.length>=2,_=oe({queryKey:["help-search",b],enabled:E,staleTime:ce,queryFn:async()=>{const{data:u,error:f}=await le(()=>ne.rpc("search_help_articles",{q:b,max_results:20}).then(j=>({data:j.data,error:j.error})));if(f)throw f;return u??[]}});w.useEffect(()=>{const u=document.title;return document.title=l?`${l.seo_title||l.title} · Help · VwD`:"Help Center · VwD",()=>{document.title=u}},[l]);const U=w.useMemo(()=>{if(!E)return null;if(_.data)return _.data.map(u=>({id:u.id,slug:u.slug,title:u.title,excerpt:u.excerpt,category_id:u.category_id,snippet:Ue(u.snippet)??u.excerpt??null}));if(_.error){const u=b.toLowerCase().split(/\s+/).filter(Boolean);return u.length===0?null:n.filter(f=>{const j=`${f.title} ${f.excerpt??""}`.toLowerCase();return u.every(p=>j.includes(p))})}return null},[E,_.data,_.error,b,n]),M=w.useMemo(()=>{const u=p=>/^welcome to vwd!?$/i.test(p.trim()),f=n.filter(p=>u(p.title)),j=n.filter(p=>!u(p.title));return[...f,...j.sort((p,P)=>p.title.localeCompare(P.title))]},[n]),J=w.useMemo(()=>{const u=new Map;for(const f of M){const j=f.category_id,p=u.get(j)??[];p.push(f),u.set(j,p)}return u},[M]),z=l?h.find(u=>u.id===l.category_id)??null:null,ie=w.useMemo(()=>l?bt(l.body_html):"",[l]);return a.jsxs("main",{className:`${ut} min-h-screen overflow-x-hidden`,children:[a.jsx(Ge,{}),a.jsxs("section",{className:"relative pt-28 pb-16 md:pt-36 md:pb-20 overflow-hidden",children:[a.jsx("div",{"aria-hidden":!0,className:"absolute inset-0 -z-10",style:{background:"radial-gradient(60% 80% at 50% 0%, hsl(263 95% 96%) 0%, hsl(263 90% 99%) 45%, hsl(220 30% 99%) 100%)"}}),a.jsx("div",{"aria-hidden":!0,className:"absolute inset-x-0 top-0 -z-10 h-[420px] opacity-60",style:{background:"radial-gradient(40% 50% at 20% 20%, hsl(263 95% 92% / .55) 0%, transparent 70%), radial-gradient(35% 45% at 85% 10%, hsl(280 95% 92% / .5) 0%, transparent 70%)"}}),a.jsxs("div",{className:"container-vwd text-center",children:[a.jsx("h1",{className:`font-sans font-bold tracking-tight ${O} mx-auto`,style:{fontSize:"clamp(2.5rem, 6vw, 4.75rem)",letterSpacing:"-0.04em",lineHeight:1.05},children:"VwD Help Center"}),a.jsx("p",{className:`mt-5 text-base md:text-lg ${T} max-w-xl mx-auto`,children:"Guides, answers, and how-tos for VwD."}),a.jsx("div",{className:"mt-10 max-w-2xl mx-auto",children:a.jsxs("div",{className:"relative",children:[a.jsx(Ze,{className:"absolute left-5 top-1/2 -translate-y-1/2 w-5 h-5 text-[hsl(263_85%_58%)]"}),a.jsx("input",{type:"text",value:m,onChange:u=>D(u.target.value),placeholder:"Search help…",className:`w-full h-16 pl-14 pr-6 rounded-full border ${V} ${O} bg-white text-base shadow-[0_20px_50px_-20px_hsl(263_85%_40%/.25)] placeholder:text-[hsl(225_15%_55%)] focus:outline-none focus:ring-4 focus:ring-[hsl(263_85%_58%/.18)] focus:border-[hsl(263_85%_58%)] transition`})]})})]})]}),a.jsx("div",{className:"container-vwd pb-16",children:e?a.jsx("section",{className:`rounded-xl border ${V} ${pt} p-6 md:p-10 min-h-[60vh] max-w-4xl mx-auto`,children:c?a.jsxs("div",{className:`flex items-center justify-center py-24 ${T}`,children:[a.jsx(De,{className:"w-5 h-5 animate-spin mr-2"})," Loading article…"]}):N?a.jsxs("div",{className:"py-12",children:[a.jsx("p",{className:`text-sm ${T}`,children:N}),a.jsx(B,{to:W("/help"),className:`inline-block mt-4 ${ke} hover:underline`,children:"← Back to help"})]}):l?a.jsxs("article",{children:[a.jsxs("nav",{className:`flex items-center gap-1.5 text-xs ${T}
1 mb-6`,children:[a.jsx(B,{to:W("/help"),className:"hover:underline",children:"Help"}),z&&a.jsxs(a.Fragment,{children:[a.jsx(Te,{className:"w-3 h-3"}),a.jsx("span",{children:z.name})]})]}),a.jsx("h1",{className:`font-sans font-bold ${O} tracking-tight mb-3`,style:{fontSize:"clamp(1.5rem, 2.5vw, 2.25rem)",letterSpacing:"-0.025em",lineHeight:1.15},children:l.title}),l.excerpt&&a.jsx("p",{className:`text-base ${T} mb-8 leading-relaxed`,children:l.excerpt}),a.jsx("div",{className:"help-prose prose prose-slate max-w-none prose-headings:tracking-tight prose-headings:text-[hsl(225_40%_12%)] prose-a:text-[hsl(263_85%_58%)] prose-a:no-underline hover:prose-a:underline prose-img:rounded-lg prose-img:border prose-img:border-[hsl(225_15%_88%)] prose-code:text-[hsl(263_85%_45%)] prose-code:bg-[hsl(263_85%_58%/.06)] prose-code:px-1 prose-code:py-0.5 prose-code:rounded prose-code:before:content-none prose-code:after:content-none prose-pre:bg-[hsl(225_25%_15%)] prose-pre:text-white prose-blockquote:border-[hsl(263_85%_58%)] prose-blockquote:text-[hsl(225_40%_12%)] prose-strong:text-[hsl(225_40%_12%)] [&_.help-video]:my-8 [&_.help-video]:aspect-video [&_.help-video]:overflow-hidden [&_.help-video]:rounded-lg [&_.help-video]:border [&_.help-video]:border-[hsl(225_15%_88%)] [&_.help-video_iframe]:h-full [&_.help-video_iframe]:w-full [&_.help-guidde]:my-8 [&_.help-guidde]:overflow-hidden [&_.help-guidde]:rounded-lg [&_.help-guidde]:border [&_.help-guidde]:border-[hsl(225_15%_88%)] [&_.help-guidde_iframe]:block [&_.help-guidde_iframe]:w-full [&_.help-guidde_iframe]:h-[640px] md:[&_.help-guidde_iframe]:h-[720px]",dangerouslySetInnerHTML:{__html:ie}}),l.source_url&&a.jsxs("div",{className:`mt-12 pt-6 border-t ${V} text-xs ${T}`,children:["Originally published at"," ",a.jsxs("a",{href:l.source_url,target:"_blank",rel:"noreferrer",className:`${ke} hover:underline`,children:["help.vwd.ai ",a.jsx(Ye,{className:"inline w-3 h-3"})]})]})]}):null}):a.jsxs("div",{className:"max-w-5xl mx-auto",children:[a.jsx(xt,{categories:h,articlesByCategory:J,loading:y||E&&_.isLoading,allMode:t,searchResults:U}),!t&&!y&&!E&&a.jsx("div",{className:"mt-12 flex justify-center",children:a.jsxs(B,{to:W("/help/all"),className:"inline-flex items-center px-6 py-3 rounded-full bg-[hsl(263_85%_58%)] text-white text-sm font-medium hover:bg-[hsl(263_85%_52%)] transition-colors",children:["All articles",a.jsx(Te,{className:"w-4 h-4 ml-1"})]})})]})}),a.jsx(Ke,{})]})}function xt({categories:t,articlesByCategory:e,loading:s,allMode:i=!1,searchResults:o=null}){var y,l;if(s)return a.jsxs("div",{className:`flex items-center justify-center py-24 ${T}`,children:[a.jsx(De,{className:"w-5 h-5 animate-spin mr-2"})," Loading…"]});if(o)return o.length===0?a.jsx("div",{className:"py-12",children:a.jsx("p",{className:`text-sm ${T}`,children:"No articles match your search."})}):a.jsxs("div",{children:[a.jsxs("p",{className:`text-sm ${T} mb-4`,children:[o.length," ",o.length===1?"result":"results"]}),a.jsx("div",{className:"grid sm:grid-cols-2 gap-3 auto-rows-fr",children:o.map(c=>a.jsxs(B,{to:W(`/help/${c.slug}`),className:`flex flex-col h-full p-4 rounded-lg border ${V} bg-white hover:border-[hsl(263_85%_58%/.5)] transition-colors`,children:[a.jsx("div",{className:`font-medium ${O}`,children:c.title}),(c.snippet??c.excerpt)&&a.jsx("p",{className:`text-sm ${T} mt-1 [&_mark]:bg-[hsl(263_85%_58%/.15)] [&_mark]:text-[hsl(225_40%_12%)] [&_mark]:rounded-sm [&_mark]:px-0.5`,dangerouslySetInnerHTML:{__html:Ue(c.snippet??c.excerpt)}})]},c.id))})]});const h=i?t:t.filter(c=>c.slug==="general"||c.name.toLowerCase()==="general");return h.some(c=>{var N;return(((N=e.get(c.id))==null?void 0:N.length)??0)>0})||i&&(((y=e.get(null))==null?void 0:y.length)??0)>0?a.jsxs("div",{className:"space-y-10",children:[h.map(c=>{const N=e.get(c.id)??[];return N.length===0?null:a.jsxs("section",{children:[i&&a.jsx("h2",{className:`font-sans font-semibold ${O} text-lg mb-4`,children:c.name}),a.jsx("div",{className:"grid sm:grid-cols-2 gap-3 auto-rows-fr",children:N.map(m=>a.jsxs(B,{to:W(`/help/${m.slug}`),className:`flex flex-col h-full p-4 rounded-lg border ${V} bg-white hover:border-[hsl(263_85%_58%/.5)] hover:bg-white transition-colors`,children:[a.jsx("div",{className:`font-medium ${O}`,children:m.title}),m.excerpt&&a.jsx("p",{className:`text-sm ${T} mt-1`,children:m.excerpt})]},m.id))})]},c.id)}),i&&(((l=e.get(null))==null?void 0:l.length)??0)>0&&a.jsxs("section",{children:[a.jsx("h2",{className:`font-sans font-semibold ${O} text-lg mb-4`,children:"Other"}),a.jsx("div",{className:"grid sm:grid-cols-2 gap-3 auto-rows-fr",children:(e.get(null)??[]).map(c=>a.jsxs(B,{to:W(`/help/${c.slug}`),className:`flex flex-col h-full p-4 rounded-lg border ${V} bg-white hover:border-[hsl(263_85%_58%/.5)] hover:bg-white transition-colors`,children:[a.jsx("div",{className:`font-medium ${O}`,children:c.title}),c.excerpt&&a.jsx("p",{className:`text-sm ${T} mt-1`,children:c.excerpt})]},c.id))})]})]}):a.jsx("div",{className:"py-12",children:a.jsx("p",{className:`text-sm ${T}`,children:"No articles published yet."})})}export{St as default};

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.