1import{c7 as v,bu as F,ce as b,ah as I,x as L,be as k,b7 as j}from"#entry";const w=(r,s,t)=>r==null||s==null?-1:r.toString().toLocaleLowerCase().indexOf(s.toString().toLocaleLowerCase()),S=j({customFilter:Function,customKeyFilter:Object,filterKeys:[Array,String],filterMode:{type:String,default:"intersection"},noFilter:Boolean},"filter");function O(r,s,t){const c=[],a=t?.default??w,u=t?.filterKeys?b(t.filterKeys):!1,m=Object.keys(t?.customKeyFilter??{}).length;if(!r?.length)return c;e:for(let l=0;l<r.length;l++){const[e,g=e]=b(r[l]),y={},o={};let n=-1;if((s||m>0)&&!t?.noFilter){if(typeof e=="object"){const M=u||Object.keys(g);for(const f of M){const d=I(g,f),K=t?.customKeyFilter?.[f];if(n=K?K(d,s,e):a(d,s,e),n!==-1&&n!==!1)K?y[f]=n:o[f]=n;else if(t?.filterMode==="every")continue e}}else n=a(e,s,e),n!==-1&&n!==!1&&(o.title=n);const i=Object.keys(o).length,h=Object.keys(y).length;if(!i&&!h||t?.filterMode==="union"&&h!==m&&!i||t?.filterMode==="intersection"&&(h!==m||!i))continue}c.push({index:l,matches:{...o,...y}})}return c}function _(r,s,t,c){const a=k([]),u=k(new Map),m=L(()=>c?.transform?F(s).map(e=>[e,c.transform(e)]):F(s));v(()=>{const e=typeof t=="function"?t():F(t),g=typeof e!="string"&&typeof e!="number"?"":String(e),y=O(m.value,g,{customKeyFilter:{...r.customKeyFilter,...F(c?.customKeyFilter)},default:r.customFilter,filterKeys:r.filterKeys,filterMode:r.filterMode,noFilter:r.noFilter}),o=F(s),n=[],i=new Map;y.forEach(h=>{let{index:M,matches:f}=h;const d=o[M];n.push(d),i.set(d.value,f)}),a.value=n,u.value=i});function l(e){return u.value.get(e.value)}return{filteredItems:a,filteredMatches:u,getMatches:l}}export{S as m,_ as u};
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.