PageSourceSearch

https://aifind.info/_next/static/chunks/app/(site)/layout-669d834df0621f9a.js

js aifind.info collected 2026-10-04 14:34:44 UTC 15,329 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7457],{4933:function(e,t,r){Promise.resolve().then(r.bind(r,5745)),Promise.resolve().then(r.bind(r,5362)),Promise.resolve().then(r.t.bind(r,2972,23))},5745:function(e,t,r){"use strict";r.d(t,{default:function(){return c}});var s=r(7437),a=r(2265),n=r(7648),l=r(2342),o=r(3273),i=r(9376);function d(e){let{open:t,onClose:r}=e,n=(0,i.useRouter)(),[l,o]=(0,a.useState)(""),[d,c]=(0,a.useState)([]),[h,u]=(0,a.useState)(0),x=(0,a.useRef)(null);(0,a.useEffect)(()=>{if(!t)return;o(""),c([]),u(0);let e=window.setTimeout(()=>{var e;return null===(e=x.current)||void 0===e?void 0:e.focus()},10);return document.body.style.overflow="hidden",()=>{window.clearTimeout(e),document.body.style.overflow=""}},[t]),(0,a.useEffect)(()=>{if(!t||!l.trim()){c([]);return}let e=new AbortController,r=window.setTimeout(async()=>{try{let t=await fetch("/api/search?q=".concat(encodeURIComponent(l.trim())),{signal:e.signal}),r=await t.json();c(r.results),u(0)}catch(e){}},250);return()=>{e.abort(),window.clearTimeout(r)}},[l,t]);let m=e=>{r(),n.push("/tools/".concat(e))};return t?(0,s.jsx)("div",{className:"fixed inset-0 z-[60] flex items-start justify-center bg-slate-900/50 px-4 pt-[12vh] backdrop-blur-sm",onClick:r,children:(0,s.jsxs)("div",{role:"dialog","aria-modal":"true","aria-label":"Search AI tools",className:"w-full max-w-xl overflow-hidden rounded-xl border border-slate-200 bg-white shadow-2xl dark:border-slate-700 dark:bg-slate-800",onClick:e=>e.stopPropagation(),children:[(0,s.jsxs)("div",{className:"flex items-center gap-3 border-b border-slate-100 px-4 py-3.5 dark:border-slate-700",children:[(0,s.jsxs)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-5 w-5 shrink-0 text-slate-400","aria-hidden":"true",children:[(0,s.jsx)("circle",{cx:"11",cy:"11",r:"7"}),(0,s.jsx)("path",{strokeLinecap:"round",d:"m20 20-3.2-3.2"})]}),(0,s.jsx)("input",{ref:x,value:l,onChange:e=>o(e.target.value),onKeyDown:e=>{if("Escape"===e.key)r();else if("ArrowDown"===e.key)e.preventDefault(),u(e=>Math.min(e+1,d.length-1));else if("ArrowUp"===e.key)e.preventDefault(),u(e=>Math.max(e-1,0));else if("Enter"===e.key){e.preventDefault();let t=d[h];t?m(t.slug):l.trim()&&(r(),n.push("/tools?q=".concat(encodeURIComponent(l.trim()))))}},placeholder:"Search AI tools by name or task...",className:"w-full bg-transparent text-base text-slate-900 outline-none placeholder:text-slate-400 dark:text-slate-100"}),(0,s.jsx)("kbd",{className:"shrink-0 rounded border border-slate-200 px-1.5 py-0.5 text-[11px] text-slate-400 dark:border-slate-600",children:"Esc"})]}),(0,s.jsxs)("div",{className:"max-h-[50vh] overflow-y-auto py-2",children:[0===d.length&&l.trim()&&(0,s.jsx)("p",{className:"px-4 py-6 text-center text-sm text-slate-400",children:"No tools matched yet."}),0===d.length&&!l.trim()&&(0,s.jsx)("p",{className:"px-4 py-6 text-center text-sm text-slate-400",children:"Start typing to search the directory."}),d.map((e,t)=>(0,s.jsxs)("button",{type:"button",onMouseEnter:()=>u(t),onClick:()=>m(e.slug),className:"flex w-full items-center gap-3 px-4 py-2.5 text-left transition-colors ".concat(t===h?"bg-indigo-50 dark:bg-indigo-950":""),children:[e.logo_url?(0,s.jsx)("img",{src:e.logo_url,alt:"",className:"h-7 w-7 shrink-0 rounded object-cover"}):(0,s.jsx)("span",{className:"h-7 w-7 shrink-0 rounded bg-slate-100 dark:bg-slate-700"}),(0,s.jsxs)("span",{className:"min-w-0 flex-1",children:[(0,s.jsx)("span",{className:"block truncate text-sm font-medium text-slate-900 dark:text-slate-100",children:e.name}),(0,s.jsx)("span",{className:"block truncate text-xs text-slate-400",children:e.tagline})]}),(0,s.jsx)("span",{className:"shrink-0 rounded bg-slate-100 px-2 py-0.5 text-[11px] text-slate-500 dark:bg-slate-700 dark:text-slate-300",children:e.category})]},e.slug))]})]})}):null}function c(){let[e,t]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{let e=e=>{let r=e.target,s=(null==r?void 0:r.tagName)==="INPUT"||(null==r?void 0:r.tagName)==="TEXTAREA"||(null==r?void 0:r.isContentEditable);("k"===e.key&&(e.metaKey||e.ctrlKey)||"/"===e.key&&!s)&&(e.preventDefault(),t(!0))};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[]),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("header",{className:"sticky top-0 z-50 border-b border-slate-200 bg-white/85 backdrop-blur-md dark:border-slate-800 dark:bg-slate-900/85",children:(0,s.jsxs)("div",{className:"mx-auto flex h-14 max-w-6xl items-center gap-4 px-6",children:[(0,s.jsxs)(n.default,{href:"/",className:"flex shrink-0 items-center gap-2 font-display text-lg font-semibold tracking-tight text-indigo-600 dark:text-indigo-400",children:[(0,s.jsx)("img",{src:"/icons/icon.svg",alt:"",className:"h-7 w-7"}),"AIFind"]}),(0,s.jsxs)("button",{type:"button",onClick:()=>t(!0),className:"hidden min-w-0 flex-1 items-center gap-2 rounded-md border border-slate-200 bg-slate-50 px-3 py-2 text-left text-sm text-slate-400 transition-colors transition-transform duration-150 hover-hover:border-indigo-300 active:scale-[0.99] md:flex dar
1k:border-slate-700 dark:bg-slate-800",children:[(0,s.jsxs)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-4 w-4 shrink-0","aria-hidden":"true",children:[(0,s.jsx)("circle",{cx:"11",cy:"11",r:"7"}),(0,s.jsx)("path",{strokeLinecap:"round",d:"m20 20-3.2-3.2"})]}),(0,s.jsx)("span",{className:"flex-1 truncate",children:"Search AI tools..."}),(0,s.jsx)("kbd",{className:"shrink-0 rounded border border-slate-300 bg-white px-1.5 py-0.5 text-[11px] dark:border-slate-600 dark:bg-slate-900",children:"⌘K"})]}),(0,s.jsx)("button",{type:"button",onClick:()=>t(!0),"aria-label":"Search",className:"ml-auto inline-flex h-9 w-9 items-center justify-center rounded-md border border-slate-200 text-slate-600 transition-transform active:scale-90 md:hidden dark:border-slate-700 dark:text-slate-300",children:(0,s.jsxs)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-4 w-4","aria-hidden":"true",children:[(0,s.jsx)("circle",{cx:"11",cy:"11",r:"7"}),(0,s.jsx)("path",{strokeLinecap:"round",d:"m20 20-3.2-3.2"})]})}),(0,s.jsxs)("nav",{className:"hidden items-center gap-5 text-sm text-slate-600 lg:flex dark:text-slate-300",children:[(0,s.jsx)(n.default,{href:"/tools",className:"hover-hover:text-indigo-600 dark:hover-hover:text-indigo-400",children:"Tools"}),(0,s.jsx)(n.default,{href:"/categories",className:"hover-hover:text-indigo-600 dark:hover-hover:text-indigo-400",children:"Categories"}),(0,s.jsx)(n.default,{href:"/collections",className:"hover-hover:text-indigo-600 dark:hover-hover:text-indigo-400",children:"Collections"}),(0,s.jsx)(n.default,{href:"/news",className:"hover-hover:text-indigo-600 dark:hover-hover:text-indigo-400",children:"News"})]}),(0,s.jsxs)("div",{className:"hidden items-center gap-2 sm:flex",children:[(0,s.jsx)(o.Z,{}),(0,s.jsx)(l.Z,{})]}),(0,s.jsx)(n.default,{href:"/submit",className:"shrink-0 rounded-md bg-indigo-600 px-4 py-2 text-sm font-medium text-white transition-transform active:scale-95 hover-hover:bg-indigo-500",children:"Submit a tool"})]})}),(0,s.jsx)(d,{open:e,onClose:()=>t(!1)})]})}},5362:function(e,t,r){"use strict";r.d(t,{default:function(){return u}});var s=r(7437),a=r(2265),n=r(7648),l=r(9376),o=r(2342),i=r(3273),d=r(8120);function c(e){let{open:t,onClose:r}=e,{theme:a}=(0,d.F)();return t?(0,s.jsx)("div",{className:"fixed inset-0 z-[60] flex items-end bg-slate-900/50 backdrop-blur-sm md:hidden",onClick:r,children:(0,s.jsxs)("div",{className:"w-full rounded-t-2xl border-t border-slate-200 bg-white p-5 pb-[calc(1.25rem+env(safe-area-inset-bottom))] shadow-2xl dark:border-slate-700 dark:bg-slate-800",onClick:e=>e.stopPropagation(),children:[(0,s.jsx)("div",{className:"mx-auto mb-4 h-1 w-10 rounded-full bg-slate-200 dark:bg-slate-600"}),(0,s.jsx)("h2",{className:"font-display text-base font-semibold text-slate-900 dark:text-slate-100",children:"Settings"}),(0,s.jsxs)("div",{className:"mt-4 flex items-center justify-between rounded-lg border border-slate-200 px-4 py-3 dark:border-slate-700",children:[(0,s.jsxs)("span",{className:"text-sm text-slate-600 dark:text-slate-300",children:["Appearance — ","dark"===a?"Dark":"Light"]}),(0,s.jsx)(o.Z,{})]}),(0,s.jsxs)("div",{className:"mt-3 flex items-center justify-between rounded-lg border border-slate-200 px-4 py-3 dark:border-slate-700",children:[(0,s.jsx)("span",{className:"text-sm text-slate-600 dark:text-slate-300",children:"Install AIFind as an app"}),(0,s.jsx)(i.Z,{className:"rounded-md bg-indigo-600 px-3 py-1.5 text-sm font-medium text-white active:scale-95"})]}),(0,s.jsxs)("div",{className:"mt-4 flex flex-col gap-1 text-sm",children:[(0,s.jsx)(n.default,{href:"/about",onClick:r,className:"rounded-lg px-4 py-2.5 text-slate-600 hover-hover:bg-slate-50 dark:text-slate-300 dark:hover-hover:bg-slate-700",children:"About AIFind"}),(0,s.jsx)(n.default,{href:"/disclosure",onClick:r,className:"rounded-lg px-4 py-2.5 text-slate-600 hover-hover:bg-slate-50 dark:text-slate-300 dark:hover-hover:bg-slate-700",children:"Affiliate disclosure"})]})]})}):null}let h=[{href:"/",label:"Home",icon:(0,s.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 10.5 12 4l8 6.5V19a1 1 0 0 1-1 1h-4.5v-6h-5v6H5a1 1 0 0 1-1-1v-8.5Z"})},{href:"/categories",label:"Categories",icon:(0,s.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 5h7v7H4V5Zm9 0h7v7h-7V5ZM4 15h7v4H4v-4Zm9 0h7v4h-7v-4Z"})}];function u(){let e=(0,l.usePathname)(),[t,r]=(0,a.useState)(!1),o=t=>"/"===t?"/"===e:e.startsWith(t);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("nav",{className:"fixed inset-x-0 bottom-0 z-40 border-t border-slate-200 bg-white/95 backdrop-blur-md pb-[env(safe-area-inset-bottom)] md:hidden dark:border-slate-800 dark:bg-slate-900/95","aria-label":"Primary",children:(0,s.jsxs)("div",{className:"grid grid-cols-4 items-center px-1 py-1.5",children:[h.map(e=>(0,s.jsxs)(n.default,{href:e.href,className:"flex flex-col items-center gap-0.5 rounded-lg py-1.5 text-[11px] transition-transform active:scale-90 ".concat(o(e.href)?"text-indigo-600 dark:text-indigo-400":"text-slate-500 dark:text-slate-400"),children:[(0,s.jsx)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",className:"h-5 w-5",children:e.icon}),e.label]},e.href)),(0,s.jsx)("div",{className:"flex items-center justify-center",children:(0,s.jsx)(n.default,{href:"/submit","aria-label":"Submit an AI tool",className:"flex h-12 w-12 -translate-y-3 items-center justify-center rounded-full bg-indigo-600 text-white shadow-lg shadow-indigo-600/30 transition-transform active:scale-90",children:(0,s.jsx)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.2",className:"h-6 w-6",children:(0,s.jsx)("path",{strokeLinecap:"round",d:"M12 5v14M5 12h14"})})})}),(0,s.jsxs)("button",{type:"button",onClick:()=>r(!0),className:"flex flex-col items-center gap-0.5 rounded-lg py-1.5 text-[11px] text-slate-500 transition-transform active:scale-90 dark:text-slate-400",children:[(0,s.jsxs)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",className:"h-5 w-5",children:[(0,s.jsx)("circle",{cx:"12",cy:"12",r:"3"}),(0,s.jsx)("path",{strokeLinecap:"round",d:"M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09a1.65 1.65 0 0 0-1-1.51 1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 1 1 0-4h.09a1.65 1.65 0 0 0 1.51-1 1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1Z"})]}),"Settings"]})]})}),(0,s.jsx)(c,{open:t,onClose:()=>r(!1)})]})}},3273:function(e,t,r){"use strict";r.d(t,{Z:function(){return n}});var s=r(7437),a=r(2265);function n(e){let{className:t}=e,{canInstall:r,promptInstall:n}=function(){let[e,t]=(0,a.useState)(null),[r,s]=(0,a.useState)(!1);(0,a.useEffect)(()=>{let e=e=>{e.preventDefault(),t(e)},r=()=>{s(!0),t(null)};return window.addEventListener("beforeinstallprompt",e),window.addEventListener("appinstalled",r),()=>{window.removeEventListener("beforeinstallprompt",e),window.removeEventListener("appinstalled",r)}},[]);let n=async()=>{e&&(await e.prompt(),await e.userChoice,t(null))};return{canInstall:!!e&&!r,promptInstall:n}}();return r?(0,s.jsxs)("button",{type:"button",onClick:n,className:null!=t?t:"inline-flex items-center gap-1.5 rounded-md border border-indigo-200 px-3 py-1.5 text-sm font-medium text-indigo-600 transition-colors hover-hover:bg-indigo-50 active:scale-95 dark:border-indigo-800 dark:text-indigo-300 dark:hover-hover:bg-indigo-950",children:[(0,s.jsx)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",className:"h-4 w-4","aria-hidden":"true",children:(0,s.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 3v12m0 0-4-4m4 4 4-4M5 17v2a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-2"})}),"Install App"]}):null}},2342:function(e,t,r){"use strict";r.d(t,{Z:function(){return n}});var s=r(7437),a=r(8120);function n(e){let{className:t}=e,{theme:r,toggleTheme:n}=(0,a.F)(),l="dark"===r;return(0,s.jsx)("button",{type:"button",onClick:n,"aria-label":l?"Switch to light mode":"Switch to dark mode",title:l?"Switch to light mode":"Switch to dark mode",className:null!=t?t:"inline-flex h-9 w-9 items-center justify-center rounded-md border border-slate-200 text-slate-600 transition-colors hover-hover:border-indigo-300 hover-hover:text-indigo-600 active:scale-95 dark:border-slate-700 dark:text-slate-300",children:l?(0,s.jsxs)("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",className:"h-4 w-4","aria-hidden":"true",children:[(0,s.jsx)("circle",{cx:"12",cy:"12",r:"4.2"}),(0,s.jsx)("path",{strokeLinecap:"round",d:"M12 2.5v2M12 19.5v2M4.2 4.2l1.4 1.4M18.4 18.4l1.4 1.4M2.5 12h2M19.5 12h2M4.2 19.8l1.4-1.4M18.4 5.6l1.4-1.4"})]}
1):(0,s.jsx)("svg",{viewBox:"0 0 24 24",fill:"currentColor",className:"h-4 w-4","aria-hidden":"true",children:(0,s.jsx)("path",{d:"M20.7 14.9A8.5 8.5 0 1 1 9.1 3.3a.8.8 0 0 1 .9 1.2 6.9 6.9 0 0 0 9.5 9.5.8.8 0 0 1 1.2.9Z"})})})}},8120:function(e,t,r){"use strict";r.d(t,{F:function(){return a}});var s=r(2265);function a(){let[e,t]=(0,s.useState)("light");return(0,s.useEffect)(()=>{t(function(){let e=window.localStorage.getItem("aifind-theme");return"light"===e||"dark"===e?e:window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}())},[]),{theme:e,toggleTheme:(0,s.useCallback)(()=>{t(e=>{let t="dark"===e?"light":"dark";return window.localStorage.setItem("aifind-theme",t),document.documentElement.classList.toggle("dark","dark"===t),t})},[])}}},7648:function(e,t,r){"use strict";r.d(t,{default:function(){return a.a}});var s=r(2972),a=r.n(s)},9376:function(e,t,r){"use strict";var s=r(5475);r.o(s,"usePathname")&&r.d(t,{usePathname:function(){return s.usePathname}}),r.o(s,"useRouter")&&r.d(t,{useRouter:function(){return s.useRouter}})}},function(e){e.O(0,[2972,2971,2117,1744],function(){return e(e.s=4933)}),_N_E=e.O()}]);

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.