PageSourceSearch

https://www.007icu.top/assets/Content-CtX1F0gO.js

js 007icu.top collected 2026-10-09 04:35:10 UTC 2,718 bytes, 1 lines download raw bytes

1import{n as e,o as t}from"./rolldown-runtime-CMxvf4Kt.js";import{Yi as n}from"../vendor/vendor-ai-runtime-DrDK77gy.js";import{Ao as r,jo as i}from"./app-const-BzFqCjOv.js";import{vo as a}from"./ScrollArea-CdDxdn_v.js";import{n as o}from"./es-D7HWafs1.js";import{b as s,t as c}from"./selectors-IDJ5-Ts8.js";import{Eo as l,n as u}from"./store-JX60g0Lu.js";import{m as d,p as f}from"./ErrorContent-DH2cR0nE.js";import{F as p,I as m}from"./NavPanel-CkWemAPV.js";import{n as h,t as g}from"./AsyncError-DaHIxwPg.js";import{n as _,r as v}from"./SkeletonList-CDk0uYF0.js";import{n as y,t as b}from"./TopicEmpty-B0ReIJDy.js";var x,S,C,w,T;e((()=>{o(),x=t(n()),S=t(i()),f(),h(),v(),y(),l(),c(),m(),C=t(r()),w=36,T=(0,S.memo)(({open:e,searchKeyword:t})=>{let n=(0,S.useRef)(null),r=(0,S.useRef)(-1),i=(0,S.useRef)(!1),[o,c,l,f,m,h,v,y,T]=u(e=>[e.activeTopicId,e.activeThreadId,s.hasMoreTopics(e),s.isLoadingMoreTopics(e),s.loadMoreTopicsError(e),s.isExpandingPageSize(e),e.loadMoreTopics,e.activeAgentId,e.useSearchTopics]),E=t.trim(),D=E.length>0;(0,S.useEffect)(()=>{D?u.setState({isSearchingTopic:!0}):u.setState({isSearchingTopic:!1,searchTopics:[]})},[D]),T(D?E:void 0,{agentId:y,groupId:void 0});let O=u(s.searchTopics,x.default),k=u(s.displayTopics,x.default),A=u(s.isSearchingTopic),j=D?O:k,M=j?.length||0;(0,S.useEffect)(()=>{r.current>M&&(r.current=M-1)},[M]),(0,S.useEffect)(()=>{if(!e||i.current||f||D||m)return;let t=setTimeout(()=>{let e=n.current;if(!e)return;let t=e.viewportSize,a=Math.ceil(t/w)+3;if(i.current=!0,M<a&&l){r.current=M;let e=a-M,t=Math.ceil(e/20);(async()=>{for(let e=0;e<t&&l;e++)await v()})()}},100);return()=>clearTimeout(t)},[e,M,l,v,f,m,D]),(0,S.useEffect)(()=>{e||(i.current=!1)},[e]);let N=(0,S.useCallback)(async()=>{if(D)return;let e=n.current;if(!e||!l||m)return;let t=e.findItemIndex(e.scrollOffset+e.viewportSize);r.current<M&&t+5>M&&(r.current=M,await v())},[l,v,M,D,m]),P=(f||h)&&!D,F=D&&A,I=!D&&!!m&&!f;return M===0&&I?(0,C.jsx)(a,{padding:12,children:(0,C.jsx)(g,{error:m,variant:`block`,onRetry:()=>{v()}})}):M===0&&!P&&!F?(0,C.jsx)(b,{search:!!t}):F?(0,C.jsx)(a,{gap:1,paddingBlock:1,paddingInline:4,children:(0,C.jsx)(_,{rows:5})}):(0,C.jsxs)(d,{bufferSize:typeof window<`u`?window.innerHeight:0,ref:n,style:{height:`100%`},onScroll:N,children:[j?.map(e=>(0,C.jsx)(a,{gap:1,paddingInline:4,children:(0,C.jsx)(p,{active:o===e.id,fav:e.favorite,id:e.id,metadata:e.metadata,status:e.status,threadId:c,title:e.title,userId:e.userId})},e.id)),P&&(0,C.jsx)(a,{padding:`4px 8px`,children:(0,C.jsx)(_,{rows:3})}),I&&(0,C.jsx)(a,{padding:`4px 8px`,children:(0,C.jsx)(g,{error:m,variant:`inline`,onRetry:()=>{v()}})})]})}),T.displayName=`AllTopicsDrawerContent`}))();export{T 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.