PageSourceSearch

https://www.ircam.fr/_next/static/chunks/14ff22c158e3810d.js

js ircam.fr collected 2026-10-01 07:43:49 UTC 35,462 bytes, 20 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,490941,e=>{"use strict";var t=e.i(904151),o=e.i(608529),r=e.i(483006);e.s(["BeforeDashboardClient",0,()=>{let{config:e}=(0,o.useConfig)(),[n,a]=(0,r.useState)(""),[i,s]=(0,r.useState)(null),[l,d]=(0,r.useState)(!1),[c,u]=(0,r.useState)("posts"),p=async t=>{if(!t.trim())return void s(null);d(!0);try{let o=await fetch(`${e.serverURL}${e.routes.api}/search/${c}?q=${encodeURIComponent(t)}&per_page=5`);if(!o.ok)throw Error(`Search failed: ${o.status} ${o.statusText}`);let r=await o.json();r&&"object"==typeof r?s({found:r.found||0,hits:r.hits||[],page:r.page||1,search_time_ms:r.search_time_ms||0}):s(null)}catch(e){s(null)}finally{d(!1)}};return(0,t.jsxs)("div",{style:{border:"1px solid #e0e0e0",borderRadius:"8px",margin:"20px 0",padding:"20px"},children:[(0,t.jsxs)("h2",{children:[(0,t.jsx)("span",{"aria-label":"search",role:"img",children:"🔍"})," ","Typesense Search"]}),(0,t.jsx)("form",{onSubmit:e=>{e.preventDefault(),p(n)},style:{marginBottom:"20px"},children:(0,t.jsxs)("div",{style:{display:"flex",gap:"10px",marginBottom:"10px"},children:[(0,t.jsxs)("select",{"aria-label":"Select collection to search",onChange:e=>u(e.target.value),style:{border:"1px solid #ccc",borderRadius:"4px",padding:"8px"},value:c,children:[(0,t.jsx)("option",{value:"posts",children:"Posts"}),(0,t.jsx)("option",{value:"media",children:"Media"})]}),(0,t.jsx)("input",{onChange:e=>a(e.target.value),placeholder:"Search...",style:{border:"1px solid #ccc",borderRadius:"4px",flex:1,padding:"8px"},type:"text",value:n}),(0,t.jsx)("button",{disabled:l,style:{backgroundColor:"#0070f3",border:"none",borderRadius:"4px",color:"white",cursor:l?"not-allowed":"pointer",padding:"8px 16px"},type:"submit",children:l?"Searching...":"Search"})]})}),i&&(0,t.jsxs)("div",{children:[(0,t.jsxs)("h3",{children:["Search Results (",i.found||0," found in ",i.search_time_ms||0,"ms)"]}),i.hits&&i.hits.length>0?(0,t.jsx)("div",{style:{display:"flex",flexDirection:"column",gap:"10px"},children:i.hits.map((e,o)=>(0,t.jsxs)("div",{style:{backgroundColor:"#f9f9f9",border:"1px solid #e0e0e0",borderRadius:"4px",padding:"10px"},children:[(0,t.jsx)("div",{style:{fontWeight:"bold",marginBottom:"5px"},children:String(e.document?.title)||String(e.document?.filename)||`Document ${String(e.document?.id)||o}`}),e.highlight&&(0,t.jsx)("div",{dangerouslySetInnerHTML:{__html:Object.values(e.highlight).join(" ... ")},style:{color:"#666",fontSize:"14px"}}),(0,t.jsxs)("div",{style:{color:"#999",fontSize:"12px",marginTop:"5px"},children:["ID: ",String(e.document?.id)||"Unknown"," | Updated:"," ",e.document?.updatedAt?new Date(String(e.document.updatedAt)).toLocaleDateString():"Unknown"]})]},o))}):(0,t.jsx)("p",{children:"No results found"})]})]})}])},380194,e=>{"use strict";var t=e.i(483006);let o={animations:{animationFast:"0.15s",animationNormal:"0.2s",animationSlow:"0.3s",easeIn:"cubic-bezier(0.4, 0, 1, 1)",easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0, 0, 0.2, 1)",transitionFast:"0.15s",transitionNormal:"0.2s",transitionSlow:"0.3s"},shadows:{focusShadow:"0 0 0 3px",focusShadowColor:"rgba(59, 130, 246, 0.1)",shadowLg:"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)",shadowMd:"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)",shadowSm:"0 1px 2px 0 rgba(0, 0, 0, 0.05)",shadowXl:"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)"},spacing:{headerFontSize:"0.875rem",headerPadding:"0.75rem 1rem",inputBorderRadius:"0.5rem",inputFontSize:"1rem",inputPadding:"0.75rem 1rem",itemBorderRadius:"0",itemMargin:"0",itemPadding:"0.75rem 1rem",metaFontSize:"0.75rem",metaPadding:"0.5rem 0",resultsBorderRadius:"0 0 0.5rem 0.5rem",resultsMaxHeight:"24rem",resultsPadding:"0"},typography:{fontFamily:'system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',fontFamilyMono:'ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", Menlo, monospace',fontSize2xl:"1.5rem",fontSizeBase:"1rem",fontSizeLg:"1.125rem",fontSizeSm:"0.875rem",fontSizeXl:"1.25rem",fontSizeXs:"0.75rem",fontWeightBold:"700",fontWeightMedium:"500",fontWeightNormal:"400",fontWeightSemibold:"600",lineHeightNormal:"1.5",lineHeightRelaxed:"1.625",lineHeightTight:"1.25"}}
1,r={name:"modern",colors:{inputBackground:"#ffffff",inputBorder:"#d1d5db",inputBorderFocus:"#3b82f6",inputPlaceholder:"#6b7280",inputText:"#111827",resultsBackground:"#ffffff",resultsBorder:"#d1d5db",resultsShadow:"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)",headerBackground:"#f9fafb",headerBorder:"#e5e7eb",headerText:"#6b7280",resultBackground:"#ffffff",resultBackgroundFocus:"#eff6ff",resultBackgroundHover:"#f8fafc",resultBorder:"#f3f4f6",descriptionText:"#6b7280",highlightBackground:"#fef3c7",highlightText:"#92400e",metaText:"#9ca3af",titleText:"#111827",collectionBadge:"#dbeafe",collectionBadgeText:"#1e40af",scoreBadge:"#dcfce7",scoreBadgeText:"#166534",errorBackground:"#fef2f2",errorText:"#dc2626",loadingText:"#6b7280",noResultsText:"#6b7280",facetActiveBackground:"#3b82f6",facetActiveText:"#ffffff",facetBackground:"#f3f4f6",facetBorder:"#d1d5db",facetText:"#374151"},...o,spacing:{...o.spacing,headerPadding:"1rem 1.25rem",inputBorderRadius:"0.75rem",inputFontSize:"1.125rem",inputPadding:"1rem 1.25rem",itemPadding:"1rem 1.25rem",resultsBorderRadius:"0 0 0.75rem 0.75rem",resultsMaxHeight:"28rem"}},n={name:"minimal",colors:{inputBackground:"#ffffff",inputBorder:"#e5e7eb",inputBorderFocus:"#000000",inputPlaceholder:"#9ca3af",inputText:"#111827",resultsBackground:"#ffffff",resultsBorder:"#e5e7eb",resultsShadow:"0 4px 6px -1px rgba(0, 0, 0, 0.1)",headerBackground:"#ffffff",headerBorder:"#f3f4f6",headerText:"#6b7280",resultBackground:"#ffffff",resultBackgroundFocus:"#f5f5f5",resultBackgroundHover:"#fafafa",resultBorder:"#f5f5f5",descriptionText:"#6b7280",highlightBackgroun
1d:"#f3f4f6",highlightText:"#111827",metaText:"#9ca3af",titleText:"#000000",collectionBadge:"#f3f4f6",collectionBadgeText:"#374151",scoreBadge:"#f3f4f6",scoreBadgeText:"#374151",errorBackground:"#fef2f2",errorText:"#dc2626",loadingText:"#6b7280",noResultsText:"#6b7280",facetActiveBackground:"#000000",facetActiveText:"#ffffff",facetBackground:"#ffffff",facetBorder:"#e5e7eb",facetText:"#374151"},...o,shadows:{...o.shadows,focusShadow:"0 0 0 2px",focusShadowColor:"rgba(0, 0, 0, 0.1)",shadowLg:"0 4px 6px -1px rgba(0, 0, 0, 0.1)",shadowMd:"0 1px 3px 0 rgba(0, 0, 0, 0.1)",shadowSm:"none",shadowXl:"0 10px 15px -3px rgba(0, 0, 0, 0.1)"},spacing:{...o.spacing,headerPadding:"0.75rem 1rem",inputBorderRadius:"0",inputFontSize:"1rem",inputPadding:"0.75rem 1rem",itemPadding:"1rem 1rem",resultsBorderRadius:"0",resultsMaxHeight:"24rem"}},a={name:"elegant",colors:{inputBackground:"#ffffff",inputBorder:"#e2e8f0",inputBorderFocus:"#8b5cf6",inputPlaceholder:"#64748b",inputText:"#1e293b",resultsBackground:"#ffffff",resultsBorder:"#e2e8f0",resultsShadow:"0 25px 50px -12px rgba(0, 0, 0, 0.25)",headerBackground:"linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%)",headerBorder:"#e2e8f0",headerText:"#475569",resultBackground:"#ffffff",resultBackgroundFocus:"linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%)",resultBackgroundHover:"linear-gradient(135deg, #fefefe 0%, #f8fafc 100%)",resultBorder:"#f1f5f9",descriptionText:"#475569",highlightBackgroun
1d:"linear-gradient(135deg, #fef3c7 0%, #fde68a 100%)",highlightText:"#92400e",metaText:"#64748b",titleText:"#0f172a",collectionBadge:"linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%)",collectionBadgeText:"#3730a3",scoreBadge:"linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%)",scoreBadgeText:"#166534",errorBackground:"linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%)",errorText:"#dc2626",loadingText:"#64748b",noResultsText:"#64748b",facetActiveBackground:"linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%)",facetActiveText:"#ffffff",facetBackground:"#f8fafc",facetBorder:"#e2e8f0",facetText:"#334155"},...o,animations:{...o.animations,easeInOut:"cubic-bezier(0.25, 0.46, 0.45, 0.94)",transitionNormal:"0.3s",transitionSlow:"0.5s"},spacing:{...o.spacing,headerPadding:"1rem 1.5rem",inputBorderRadius:"1rem",inputFontSize:"1.125rem",inputPadding:"1.25rem 1.5rem",itemPadding:"1.25rem 1.5rem",resultsBorderRadius:"0 0 1rem 1rem",resultsMaxHeight:"32rem"}},i={name:"dark",colors:{inputBackground:"#1f2937",inputBorder:"#374151",inputBorderFocus:"#3b82f6",inputPlaceholder:"#9ca3af",inputText:"#f9fafb",resultsBackground:"#1f2937",resultsBorder:"#374151",resultsShadow:"0 25px 50px -12px rgba(0, 0, 0, 0.5)",headerBackground:"#111827",headerBorder:"#374151",headerText:"#9ca3af",resultBackground:"#1f2937",resultBackgroundFocus:"#1e3a8a",resultBackgroundHover:"#111827",resultBorder:"#374151",descriptionText:"#d1d5db",highlightBackgroun
1d:"#451a03",highlightText:"#fbbf24",metaText:"#9ca3af",titleText:"#f9fafb",collectionBadge:"#1e3a8a",collectionBadgeText:"#93c5fd",scoreBadge:"#064e3b",scoreBadgeText:"#6ee7b7",errorBackground:"#7f1d1d",errorText:"#fca5a5",loadingText:"#9ca3af",noResultsText:"#9ca3af",facetActiveBackground:"#3b82f6",facetActiveText:"#ffffff",facetBackground:"#374151",facetBorder:"#4b5563",facetText:"#d1d5db"},...o,spacing:{...o.spacing,headerPadding:"1rem 1.25rem",inputBorderRadius:"0.75rem",inputFontSize:"1.125rem",inputPadding:"1rem 1.25rem",itemPadding:"1rem 1.25rem",resultsBorderRadius:"0 0 0.75rem 0.75rem",resultsMaxHeight:"28rem"}},s={colorful:{name:"colorful",colors:{inputBackground:"#ffffff",inputBorder:"#e879f9",inputBorderFocus:"#ec4899",inputPlaceholder:"#a855f7",inputText:"#1f2937",resultsBackground:"#ffffff",resultsBorder:"#e879f9",resultsShadow:"0 25px 50px -12px rgba(236, 72, 153, 0.25)",headerBackground:"linear-gradient(135deg, #fdf2f8 0%, #fce7f3 100%)",headerBorder:"#f3e8ff",headerText:"#be185d",resultBackground:"#ffffff",resultBackgroundFocus:"linear-gradient(135deg, #fef3c7 0%, #fde68a 100%)",resultBackgroundHover:"linear-gradient(135deg, #fdf2f8 0%, #fce7f3 100%)",resultBorder:"#f3e8ff",descriptionText:"#6b7280",highlightBackgroun
1d:"linear-gradient(135deg, #fef3c7 0%, #fde68a 100%)",highlightText:"#92400e",metaText:"#a855f7",titleText:"#1f2937",collectionBadge:"linear-gradient(135deg, #ddd6fe 0%, #c4b5fd 100%)",collectionBadgeText:"#6d28d9",scoreBadge:"linear-gradient(135deg, #fecaca 0%, #fca5a5 100%)",scoreBadgeText:"#dc2626",errorBackground:"linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%)",errorText:"#dc2626",loadingText:"#a855f7",noResultsText:"#a855f7",facetActiveBackground:"linear-gradient(135deg, #ec4899 0%, #be185d 100%)",facetActiveText:"#ffffff",facetBackground:"#fdf2f8",facetBorder:"#f3e8ff",facetText:"#be185d"},...o,animations:{...o.animations,easeInOut:"cubic-bezier(0.68, -0.55, 0.265, 1.55)",transitionNormal:"0.3s",transitionSlow:"0.5s"},spacing:{...o.spacing,headerPadding:"1rem 1.5rem",inputBorderRadius:"1.5rem",inputFontSize:"1.125rem",inputPadding:"1rem 1.25rem",itemPadding:"1.25rem 1.5rem",resultsBorderRadius:"0 0 1.5rem 1.5rem",resultsMaxHeight:"28rem"}},dark:i,elegant:a,minimal:n,modern:r};function l(e){let t="string"==typeof e.theme?s[e.theme]||r:e.theme;return{...t,animations:{...t.animations,...e.animations},colors:{...t.colors,...e.colors},shadows:{...t.shadows,...e.shadows},spacing:{...t.spacing,...e.spacing},typography:{...t.typography,...e.typography}}}function d(e,t={}){let o=!1!==t.enableAnimations,r=!1!==t.enableShadows,n=!1!==t.enableRoundedCorners,a=e=>Object.entries(e).map(([e,t])=>{if("object"==typeof t&&null!==t){let o=Object.entries(t).map(([e,t])=>`${e.replace(/([A-Z])/g,"-$1").toLowerCase()}: ${t}`).join("; ");return`${e.replace(/([A-Z])/g,"-$1").toLowerCase()}: { ${o} }`}return`${e.replace(/([A-Z])/g,"-$1").toLowerCase()}: ${t}`}).join("; "),i=a({margin:"0 auto",maxWidth:"600px",position:"relative",width:"100%"}),s=a({position:"relative",width:"100%"}),l=a({backgroundColor:e.colors.resultsBackground,border:`1px solid ${e.colors.resultsBorder}`,borderRadius:n?e.spacing.resultsBorderRadius:"0",boxShadow:r?e.shadows.shadowLg:"none",left:"0",marginTop:"4px",maxHeight:e.spacing.resultsMaxHeight,overflowY:"auto",position:"absolute",right:"0",top:"100%",zIndex:"1000",...o&&{animation:"slideDown 0.2s ease-out"}}),c=a({"::placeholder":{color:e.colors.inputPlaceholder},":disabled":{backgroundColor:e.colors.inputBackground,cursor:"not-allowed",opacity:"0.6"},":focus":{borderColor:e.colors.inputBorderFocus,boxShadow:r?`${e.shadows.focusShadow} ${e.shadows.focusShadowColor}`:"none"},backgroundColor:e.colors.inputBackground,border:`2px solid ${e.colors.inputBorder}`,borderRadius:n?e.spacing.inputBorderRadius:"0",boxShadow:"none",color:e.colors.inputText,fontFamily:e.typography.fontFamily,fontSize:e.spacing.inputFontSize,fontWeight:e.typography.fontWeightNormal,lineHeight:e.typography.lineHeightNormal,outline:"none",padding:e.spacing.inputPadding,transition:o?`all ${e.animations.transitionNormal} ${e.animations.easeInOut}`:"none",width:"100%"}),u=a({backgroundColor:e.colors.resultsBackground,border:`1px solid ${e.colors.resultsBorder}`,borderRadius:n?e.spacing.resultsBorderRadius:"0",boxShadow:r?e.shadows.shadowLg:"none",left:"0",maxHeight:e.spacing.resultsMaxHeight,overflowY:"auto",position:"absolute",right:"0",top:"100%",zIndex:"1000"}),p=a({alignItems:"center",backgroundColor:e.colors.headerBackground,borderBottom:`1px solid ${e.colors.headerBorder}`,color:e.colors.headerText,display:"flex",fontFamily:e.typography.fontFamily,fontSize:e.spacing.headerFontSize,fontWeight:e.typography.fontWeightMedium,justifyContent:"space-between",padding:e.spacing.headerPadding}),g=a({padding:"8px 0"}),h=a({":focus":{backgroundColor:e.colors.resultBackgroundFocus,boxShadow:r?`inset 0 0 0 2px ${e.colors.inputBorderFocus}`:"none"},":hover":{backgroundColor:e.colors.resultBackgroundHover,transform:o?"translateX(2px)":"none"},":last-child":{borderBottom:"none"},backgroundColor:e.colors.resultBackground,borderBottom:`1px solid ${e.colors.resultBorder}`,cursor:"pointer",outline:"none",padding:e.spacing.itemPadding,transition:o?`all ${e.animations.transitionFast} ${e.animations.easeInOut}`:"none"}),f=a({color:e.colors.titleText,fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeLg,fontWeight:e.typography.fontWeightSemibold,lineHeight:e.typography.lineHeightTight,marginBottom:"8px"}),m=a({color:e.colors.descriptionText,fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeSm,lineHeight:e.typography.lineHeightNormal,marginBottom:"8px"}
1),x=a({backgroundColor:e.colors.highlightBackground,borderRadius:n?"6px":"0",color:e.colors.descriptionText,fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeSm,lineHeight:e.typography.lineHeightNormal,marginBottom:"8px",mark:{backgroundColor:e.colors.highlightBackground,borderRadius:n?"3px":"0",color:e.colors.highlightText,fontWeight:e.typography.fontWeightMedium,padding:"2px 4px"},padding:"8px 12px"}),y=a({alignItems:"center",color:e.colors.metaText,display:"flex",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeXs,justifyContent:"space-between",marginTop:"8px"}),b=a({backgroundColor:e.colors.collectionBadge,borderRadius:n?"12px":"0",color:e.colors.collectionBadgeText,display:"inline-block",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeXs,fontWeight:e.typography.fontWeightSemibold,letterSpacing:"0.5px",padding:"4px 8px",textTransform:"uppercase"}),B=a({backgroundColor:e.colors.scoreBadge,borderRadius:n?"4px":"0",color:e.colors.scoreBadgeText,display:"inline-block",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeXs,fontWeight:e.typography.fontWeightMedium,padding:"2px 6px"}),S=a({alignItems:"center",color:e.colors.loadingText,display:"flex",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeSm,gap:"12px",justifyContent:"center",padding:"24px"}),T=a({animation:o?"spin 1s linear infinite":"none",border:`2px solid ${e.colors.inputBorder}`,borderRadius:"50%",borderTop:`2px solid ${e.colors.inputBorderFocus}`,height:"20px",width:"20px"}),k=a({alignItems:"center",backgroundColor:e.colors.errorBackground,borderBottom:`1px solid ${e.colors.resultBorder}`,color:e.colors.errorText,display:"flex",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeSm,gap:"8px",padding:"16px"}),v=a({color:e.colors.noResultsText,fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeSm,padding:"40px 20px",textAlign:"center"}),w=a({backgroundColor:e.colors.headerBackground,borderBottom:`1px solid ${e.colors.headerBorder}`,padding:"16px"}),C=a({":hover":{backgroundColor:e.colors.facetActiveBackground,borderColor:e.colors.facetActiveBackground,color:e.colors.facetActiveText},backgroundColor:e.colors.facetBackground,border:`1px solid ${e.colors.facetBorder}`,borderRadius:n?"16px":"0",color:e.colors.facetText,cursor:"pointer",display:"inline-block",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSizeXs,fontWeight:e.typography.fontWeightMedium,margin:"4px",padding:"6px 12px",transition:o?`all ${e.animations.transitionFast} ${e.animations.easeInOut}`:"none"}),z=a({backgroundColor:e.colors.facetActiveBackground,borderColor:e.colors.facetActiveBackground,color:e.colors.facetActiveText}),j=a({display:"none"}),F=a({display:"block"});return{container:i,inputContainer:s,resultsContainer:l,input:c,inputDisabled:"",inputFocus:"",results:u,resultsHeader:p,resultsList:g,resultItem:h,resultItemActive:"",resultItemFocus:"",resultItemHover:"",resultDescription:m,resultHighlight:x,resultMeta:y,resultTitle:f,collectionBadge:b,scoreBadge:B,error:k,loading:S,loadingSpinner:T,noResults:v,facetContainer:w,facetItem:C,facetItemActive:z,focusable:a({":focus":{boxShadow:r?`0 0 0 2px ${e.colors.inputBorderFocus}`:"none"},outline:"none"}),hidden:j,visible:F}}function c(e){return"dark"===e.name||e.colors.inputBackground.includes("#1f")||e.colors.inputBackground.includes("#0f")}let u=(0,t.createContext)(null);function p(){let e=(0,t.useContext)(u);if(!e)throw Error("useTheme must be used within a ThemeProvider");return e}function g(e){let o=(0,t.useMemo)(()=>l(e),[e]),r=(0,t.useMemo)(()=>d(o,e),[o,e]),n=(0,t.useCallback)((e,t)=>(function(e,t,o){let r=d(e);if(o){let e=`${t}${o.charAt(0).toUpperCase()+o.slice(1)}`;return`${r[t]||""} ${r[e]||""}`}return r[t]||""})(o,e,t),[o]);return(0,t.useMemo)(()=>({applyTheme:n,classes:r,config:e,isDark:c(o),isLight:!c(o),theme:o}),[o,e,r,n])}function h(e){return(0,t.useMemo)(()=>{var t;return{"--search-collection-badge":(t=l(e)).colors.collectionBadge,"--search-collection-badge-text":t.colors.collectionBadgeText,"--search-description-text":t.colors.descriptionText,"--search-error-bg":t.colors.errorBackgroun
1d,"--search-error-text":t.colors.errorText,"--search-facet-active-bg":t.colors.facetActiveBackground,"--search-facet-active-text":t.colors.facetActiveText,"--search-facet-bg":t.colors.facetBackground,"--search-facet-border":t.colors.facetBorder,"--search-facet-text":t.colors.facetText,"--search-header-bg":t.colors.headerBackground,"--search-header-text":t.colors.headerText,"--search-highlight-bg":t.colors.highlightBackground,"--search-highlight-text":t.colors.highlightText,"--search-input-bg":t.colors.inputBackground,"--search-input-border":t.colors.inputBorder,"--search-input-border-focus":t.colors.inputBorderFocus,"--search-input-placeholder":t.colors.inputPlaceholder,"--search-input-text":t.colors.inputText,"--search-loading-text":t.colors.loadingText,"--search-meta-text":t.colors.metaText,"--search-no-results-text":t.colors.noResultsText,"--search-result-bg":t.colors.resultBackground,"--search-result-bg-hover":t.colors.resultBackgroundHover,"--search-results-bg":t.colors.resultsBackground,"--search-results-border":t.colors.resultsBorder,"--search-score-badge":t.colors.scoreBadge,"--search-score-badge-text":t.colors.scoreBadgeText,"--search-title-text":t.colors.titleText}},[e])}function f(e,o){return(0,t.useMemo)(()=>e.responsive?{...e,spacing:{...e.spacing,headerPadding:"0.75rem 1rem",inputFontSize:"16px",inputPadding:"0.875rem 1rem",itemPadding:"0.875rem 1rem",resultsMaxHeight:"20rem"},animations:o?{...e.animations,transitionFast:"0s",transitionNormal:"0s",transitionSlow:"0s"}:e.animations}:e,[e,o])}function m(e,o,r){return(0,t.useMemo)(()=>r?o:e,[e,o,r])}function x(e){return(0,t.useMemo)(()=>{let t=d(l(e),e),o={};return Object.entries(t).forEach(([e,t])=>{o[e]=t}),o},[e])}function y(e){return(0,t.useMemo)(()=>l(e).colors,[e])}function b(e){return(0,t.useMemo)(()=>l(e).spacing,[e])}function B(e){return(0,t.useMemo)(()=>l(e).typography,[e])}function S(){return(0,t.useMemo)(()=>"u"<typeof window?"light":window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light",[])}function T(e,o){let r=S();return(0,t.useMemo)(()=>"dark"===r?o:e,[r,e,o])}function k(e,o){return(0,t.useMemo)(()=>({theme:e,...o}),[e,o])}e.s(["ThemeContext",()=>u,"useAutoTheme",()=>T,"useCustomTheme",()=>k,"useResponsiveTheme",()=>f,"useSystemTheme",()=>S,"useTheme",()=>p,"useThemeClasses",()=>x,"useThemeColors",()=>y,"useThemeConfig",()=>g,"useThemeSpacing",()=>b,"useThemeStyles",()=>h,"useThemeToggle",()=>m,"useThemeTypography",()=>B],380194)},466737,e=>{"use strict";var t=e.i(904151),o=e.i(483006),r=e.i(380194);let n=({baseUrl:e,className:n="",collection:a,collections:i,debounceMs:s=300,enableSuggestions:l=!0,errorClassName:d="",inputClassName:c="",inputWrapperClassName:u="",loadingClassName:p="",minQueryLength:g=2,noResultsClassName:h="",onResultClick:f,onResults:m,onSearch:x,perPage:y=10,placeholder:b="Search...",renderError:B,renderInput:S,renderLoading:T,renderNoResults:k,renderResult:v,renderResultsHeader:w,resultItemClassName:C="",resultsClassName:z="",resultsHeaderClassName:j="",resultsListClassName:F="",showLoading:$=!0,showResultCount:R=!0,showSearchTime:M=!0,theme:H="modern"})=>{let I,A,[P,W]=(0,o.useState)(""),[N,L]=(0,o.useState)(null),[_,D]=(0,o.useState)(!1),[O,E]=(0,o.useState)(!1),[U,X]=(0,o.useState)(null),q=(0,o.useRef)(null),Y=(0,o.useRef)(null),K=(0,o.useRef)(void 0),Z=(0,o.useRef)(i),V=(0,r.useThemeConfig)({theme:"string"==typeof H?H:H.theme||"modern",..."object"==typeof H?H:{}});(0,o.useEffect)(()=>{Z.current=i},[i]);let G=(0,o.useRef)(m),J=(0,o.useRef)(x);G.current=m,J.current=x;let Q=(0,o.useCallback)(async t=>{if(t.length<g){L(null),D(!1),E(!1);return}D(!0),X(null),E(!0);try{let o,r;o=a?`${e}/api/search/${a}?q=${encodeURIComponent(t)}&per_page=${y}`:Z.current&&Z.current.length>0?`${e}/api/search?q=${encodeURIComponent(t)}&per_page=${2*y}`:`${e}/api/search?q=${encodeURIComponent(t)}&per_page=${y}`;let n=await fetch(o);if(!n.ok)throw Error(`Search failed: ${n.status} ${n.statusText}`);if(r=await n.json(),Z.current&&Z.current.length>0){let e=r.hits?.filter(e=>e.collection&&Z.current.includes(e.collection))||[],t=r.collections?.filter(e=>e.collection&&Z.current.includes(e.collection))||[];r={...r,collections:t,found:e.length,hits:e}}L(r),G.current?.(r),J.current?.(t,r),E(!0)}catch(e){X(e instanceof Error?e.message:"Search failed"),L(null),E(!0)}finally{D(!1)}},[e,a,y,g]);(0,o.useEffect)(()=>(K.current&&clearTimeout(K.current),P.length>=g?(D(!0),E(!0),K.current=setTimeout(()=>{Q(P),J.current?.(P,N||{found:0,hits:[],page:1,request_params:{per_page:10,q:P},search_cutoff:!1,search_time_ms:0})},s)):(L(null),D(!1),E(!1),X(null)),()=>{K.current&&clearTimeout(K.current)}),[P,s,g,Q]);let ee=e=>{W(e.target.value)},et=()=>{P.length>=g&&(_||N)&&E(!0)},eo=e=>{setTimeout(()=>{Y.current?.contains(document.activeElement)||E(!1)},150)},er=e=>{f?.(e),E(!1),W("")},en=e=>{if(!O||!N)return;let t=Y.current?.querySelectorAll("[data-result-item]");if(!t)return;let o=Array.from(t).findIndex(e=>e===document.activeElement);switch(e.key){case"ArrowDown":{e.preventDefault();let r=o<t.length-1?o+1:0;t[r]?.focus();break}case"ArrowUp":{e.preventDefault();let r=o>0?o-1:t.length-1;t[r]?.focus();break}case"Enter":e.preventDefault(),o>=0&&t[o]&&t[o]?.click();break;case"Escape":E(!1),q.current?.blur()}};return(0,o.useEffect)(()=>
1{if("u">typeof document&&!document.getElementById("search-animations")){let e=document.createElement("style");e.id="search-animations",e.textContent=`
2        @keyframes spin {
3          0% {
4            transform: rotate(0deg);
5          }
6          100% {
7            transform: rotate(360deg);
8          }
9        }
10        @keyframes slideDown {
11          0% {
12            opacity: 0;
13            transform: translateY(-10px);
14          }
15          100% {
16            opacity: 1;
17            transform: translateY(0);
18          }
19        }
20      `,document.head.appendChild(e)}},[]),(0,t.jsxs)("div",{className:`${n}`,style:{margin:"0 auto",maxWidth:"600px",position:"relative",width:"100%"},children:[(0,t.jsxs)("div",{className:`${u}`,style:{position:"relative",width:"100%"},children:[S?S({className:`${c}`,onBlur:eo,onChange:ee,onFocus:et,onKeyDown:en,placeholder:b,ref:q,value:P}):(0,t.jsx)("input",{"aria-label":"Search input",autoComplete:"off",className:`${c}`,onBlur:e=>{e.target.style.borderColor=V.theme.colors.inputBorder,e.target.style.boxShadow="none",eo(e)},onChange:ee,onFocus:e=>{e.target.style.borderColor=V.theme.colors.inputBorderFocus,e.target.style.boxShadow=!1!==V.config.enableShadows?`0 0 0 3px ${V.theme.colors.inputBorderFocus}20`:"none",et()},onKeyDown:en,placeholder:b,ref:q,style:{backgroundColor:V.theme.colors.inputBackground,border:`2px solid ${V.theme.colors.inputBorder}`,borderRadius:!1!==V.config.enableRoundedCorners?V.theme.spacing.inputBorderRadius:"0",boxShadow:"none",color:V.theme.colors.inputText,fontFamily:V.theme.typography.fontFamily,fontSize:V.theme.spacing.inputFontSize,fontWeight:V.theme.typography.fontWeightNormal,lineHeight:V.theme.typography.lineHeightNormal,outline:"none",padding:V.theme.spacing.inputPadding,transition:!1!==V.config.enableAnimations?`all ${V.theme.animations.transitionNormal} ${V.theme.animations.easeInOut}`:"none",width:"100%"},type:"text",value:P}),_&&$&&(0,t.jsx)("div",{style:{position:"absolute",right:"12px",to
20p:"50%",transform:"translateY(-50%)"},children:(0,t.jsx)("div",{"data-testid":"loading-spinner",style:{animation:"spin 1s linear infinite",border:`2px solid ${V.theme.colors.inputBorder}`,borderRadius:"50%",borderTop:`2px solid ${V.theme.colors.inputBorderFocus}`,height:"16px",width:"16px"}})})]}),O&&(_||N||U)&&(0,t.jsxs)("div",{className:`${z}`,ref:Y,style:{backgroundColor:V.theme.colors.resultsBackground,border:`1px solid ${V.theme.colors.resultsBorder}`,borderRadius:!1!==V.config.enableRoundedCorners?V.theme.spacing.resultsBorderRadius:"0",boxShadow:!1!==V.config.enableShadows?V.theme.shadows.shadowLg:"none",left:"0",marginTop:"4px",maxHeight:V.theme.spacing.resultsMaxHeight,overflowY:"auto",position:"absolute",right:"0",top:"100%",zIndex:1e3,...!1!==V.config.enableAnimations&&{animation:`slideDown ${V.theme.animations.animationNormal} ${V.theme.animations.easeOut}`}},children:[U&&(B?B(U):(0,t.jsxs)("div",{className:`${d}`,style:{alignItems:"center",backgroundColor:V.theme.colors.errorBackground,borderBottom:`1px solid ${V.theme.colors.resultBorder}`,color:V.theme.colors.errorText,display:"flex",fontFamily:V.theme.typography.fontFamily,fontSize:V.theme.typography.fontSizeSm,gap:"8px",padding:"16px"},children:[(0,t.jsx)("svg",{fill:"currentColor",style:{flexShrink:0,height:"20px",width:"20px"},viewBox:"0 0 20 20",children:(0,t.jsx)("path",{clipRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z",fillRule:"evenodd"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{style:{fontSize:V.theme.typography.fontSizeSm,fontWeight:V.theme.typography.fontWeightMedium,margin:0},children:"Search Error"}),(0,t.jsx)("p",{style:{color:V.theme.colors.errorText,fontSize:V.theme.typography.fontSizeSm,margin:0},children:U})]})]})),!U&&_&&!N&&(0,t.jsxs)("div",{className:`${p}`,style:{alignItems:"center",color:V.theme.colors.loadingText,display:"flex",fontFamily:V.theme.typography.fontFamily,fontSize:V.theme.typography.fontSizeSm,gap:"12px",justifyContent:"center",padding:"24px"},children:[(0,t.jsx)("div",{style:{animation:"spin 1s linear infinite",border:`2px solid ${V.theme.colors.inputBorder}`,borderRadius:"50%",borderTop:`2px solid ${V.theme.colors.inputBorderFocus}`,height:"20px",width:"20px"}}),(0,t.jsx)("span",{children:"Searching..."})]}),!U&&!_&&N&&(0,t.jsxs)(t.Fragment,{children:[R&&(w?w(N.found,N.search_time_ms):(I=N.found,A=N.search_time_ms,(0,t.jsxs)("div",{className:`${j}`,style:{alignItems:"center",backgroundColor:V.theme.colors.headerBackground,borderBottom:`1px solid ${V.theme.colors.headerBorder}`,color:V.theme.colors.headerText,display:"flex",fontFamily:V.theme.typography.fontFamily,fontSize:V.theme.spacing.headerFontSize,fontWeight:V.theme.typography.fontWeightMedium,justifyContent:"space-between",padding:V.theme.spacing.headerPadding},children:[(0,t.jsxs)("div",{style:{alignItems:"center",display:"flex",gap:"8px"},children:[(0,t.jsx)("svg",{fill:"currentColor",style:{color:V.theme.colors.metaText,height:"16px",width:"16px"},viewBox:"0 0 20 20",children:(0,t.jsx)("path",{clipRule:"evenodd",d:"M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z",fillRule:"evenodd"})}),(0,t.jsxs)("span",{style:{color:V.theme.colors.headerText,fontSize:V.theme.typography.fontSizeSm,fontWeight:V.theme.typography.fontWeightMedium},children:[I," result",1!==I?"s":""," found"]})]}),M&&(0,t.jsxs)("span",{style:{backgroundColor:V.theme.colors.inputBorder,borderRadius:"12px",color:V.theme.colors.metaText,fontSize:V.theme.typography.fontSizeXs,padding:"4px 8px"},children:[A,"ms"]})]}))),N.hits.length>0?(0,t.jsx)("div",{className:`${F}`,style:{padding:"8px 0"},children:N.hits.map((e,o)=>{let r,n;return v?v(e,o):(r=N?.hits?.reduce((e,t)=>Math.max(e,t.text_match||0),0)||1,n=Math.round((e.text_match||0)/r*100),(0,t.jsx)("div",{className:`${V.classes.resultItem} ${C}`,"data-result-item":!0,onBlur:e=>{e.currentTarget.style.backgroundColor=V.theme.colors.resultBackground},onClick:()=>er(e),onFocus:e=>{e.currentTarget.style.backgroundColor=V.theme.colors.resultBackgroun
20dFocus},onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),er(e))},onMouseEnter:e=>{e.currentTarget.style.backgroundColor=V.theme.colors.resultBackgroundHover},onMouseLeave:e=>{e.currentTarget.style.backgroundColor=V.theme.colors.resultBackground},role:"button",style:{backgroundColor:V.theme.colors.resultBackground,borderBottom:`1px solid ${V.theme.colors.resultBorder}`,cursor:"pointer",padding:V.theme.spacing.itemPadding,transition:!1!==V.config.enableAnimations?`all ${V.theme.animations.transitionFast} ${V.theme.animations.easeInOut}`:"none"},tabIndex:0,children:(0,t.jsxs)("div",{style:{alignItems:"flex-start",display:"flex",gap:"12px"},children:[(0,t.jsx)("div",{style:{flexShrink:0,marginTop:"4px"},children:(0,t.jsx)("div",{style:{alignItems:"center",backgroundColor:V.theme.colors.collectionBadge,borderRadius:V.theme.spacing.inputBorderRadius,color:V.theme.colors.collectionBadgeText,display:"flex",fontSize:"14px",fontWeight:V.theme.typography.fontWeightMedium,height:"32px",justifyContent:"center",width:"32px"},children:e.collection?.charAt(0).toUpperCase()||"📄"})}),(0,t.jsxs)("div",{style:{flex:1,minWidth:0},children:[(0,t.jsxs)("div",{style:{alignItems:"center",display:"flex",justifyContent:"space-between",marginBottom:"8px"},children:[(0,t.jsx)("h3",{style:{color:V.theme.colors.titleText,fontFamily:V.theme.typography.fontFamily,fontSize:V.theme.typography.fontSizeLg,fontWeight:V.theme.typography.fontWeightSemibold,lineHeight:V.theme.typography.lineHeightTight,margin:0,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e.document?.title||e.document?.name||e.title||"Untitled"}),e.text_match&&(0,t.jsxs)("span",{style:{alignItems:"center",backgroundColor:V.theme.colors.scoreBadge,borderRadius:"4px",color:V.theme.colors.scoreBadgeText,display:"inline-flex",fontSize:V.theme.typography.fontSizeXs,fontWeight:V.theme.typography.fontWeightMedium,marginLeft:"8px",padding:"2px 6px"},children:[n,"%"]})]}),(e.highlight?.title?.snippet||e.highlight?.content?.snippet)&&(0,t.jsx)("div",{dangerouslySetInnerHTML:{__html:e.highlight?.title?.snippet||e.highlight?.content?.snippet||""},style:{color:V.theme.colors.descriptionText,display:"-webkit-box",fontSize:V.theme.typography.fontSizeSm,lineHeight:V.theme.typography.lineHeightNormal,marginTop:"4px",overflow:"hidden",WebkitBoxOrient:"vertical",WebkitLineClamp:2}}),(0,t.jsxs)("div",{style:{alignItems:"center",color:V.theme.colors.metaText,display:"flex",fontSize:V.theme.typography.fontSizeXs,gap:"12px",marginTop:"8px"},children:[(0,t.jsxs)("span",{style:{alignItems:"center",display:"inline-flex"},children:[(0,t.jsx)("svg",{fill:"currentColor",style:{height:"12px",marginRight:"4px",width:"12px"},viewBox:"0 0 20 20",children:(0,t.jsx)("path",{clipRule:"evenodd",d:"M3 4a1 1 0 011-1h12a1 1 0 110 2H4a1 1 0 01-1-1zm0 4a1 1 0 011-1h12a1 1 0 110 2H4a1 1 0 01-1-1zm0 4a1 1 0 011-1h12a1 1 0 110 2H4a1 1 0 01-1-1zm0 4a1 1 0 011-1h12a1 1 0 110 2H4a1 1 0 01-1-1z",fillRule:"evenodd"})}),e.collection]}),(e.document?.updatedAt||e.updatedAt)&&(0,t.jsxs)("span",{style:{alignItems:"center",display:"inline-flex"},children:[(0,t.jsx)("svg",{fill:"currentColor",style:{height:"12px",marginRight:"4px",width:"12px"},viewBox:"0 0 20 20",children:(0,t.jsx)("path",{clipRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm1-12a1 1 0 10-2 0v4a1 1 0 00.293.707l2.828 2.829a1 1 0 101.415-1.415L11 9.586V6z",fillRule:"evenodd"})}),new Date(e.document?.updatedAt||e.updatedAt).toLocaleDateString()]})]})]}),(0,t.jsx)("div",{style:{flexShrink:0,opacity:0,transition:`opacity ${V.theme.animations.transitionNormal} ${V.theme.animations.easeInOut}`},children:(0,t.jsx)("svg",{fill:"none",stroke:"currentColor",style:{color:V.theme.colors.metaText,height:"16px",width:"16px"},viewBox:"0 0 24 24",children:(0,t.jsx)("path",{d:"M9 5l7 7-7 7",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2})})})]})},e.document?.id||e.id||o))})}):k?k(P):(0,t.jsx)("div",{className:`${h}`,style:{color:V.theme.colors.noResultsText,fontFamily:V.theme.typography.fontFamily,fontSize:V.theme.typography.fontSizeSm,padding:"40px 20px",textAlign:"center"},children:(0,t.jsxs)("div",{style:{alignItems:"center",display:"flex",flexDirection:"column"},children:[(0,t.jsx)("svg",{fill:"none",stroke:"currentColor",style:{color:V.theme.colors.metaText,height:"48px",marginBottom:"12px",width:"48px"},viewBox:"0 0 24 24",children:(0,t.jsx)("path",{d:"M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1})}),(0,t.jsx)("h3",{style:{color:V.theme.colors.titleText,fontSize:V.theme.typography.fontSizeSm,fontWeight:V.theme.typography.fontWeightMedium,margin:0,marginBottom:"4px"},children:"No results found"}),(0,t.jsx)("p",{style:{color:V.theme.colors.descriptionText,fontSize:V.theme.typography.fontSizeSm,margin:0},children:"Try searching for something else"})]})})]})]})]})};e.s(["HeadlessSearchInput",()=>n,"default",0,n])},216278,e=>{"use strict";var t=e.i(904151),o=e.i(483006),r=e.i(380194);let n=(0,o.createContext)(null);function a({children:e,config:o}){let a=(0,r.useThemeConfig)(o);return(0,t.jsx)(n,{value:a,children:e})}function i(){let e=(0,o.use)(n);if(!e)throw Error("useTheme must be used within a ThemeProvider");return e}e.s(["ThemeProvider",()=>a,"useTheme",()=>i])}]);

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.