import{j as r}from"./vendor-react-wBh_31cN.js";import{aq as l,R as c}from"./index-dNe6i2rS.js";import{B as n}from"./BlinkingDots-CJK9OJE3.js";import{A as x}from"./AnimatedLoadingIcon-mddZBUgk.js";import{H as d}from"./LoadMore-Bg-Y-iGB.js";import{b as f,c as u}from"./useSearchData-6n4CLDfC.js";import{c as h}from"./vendor-router-D1GqFWiT.js";import"./vendor-redux-CJZrIb6x.js";import"./vendor-utils-OeoE2qq_.js";import"./vendor-icons-BUUmD6ht.js";import"./vendor-radix-BRyWS4bQ.js";import"./vendor-grid-CeFlDWv4.js";import"./Search-BFc2vuRf.js";import"./textarea-BJVuSob1.js";import"./popover-BzVbz_d3.js";import"./useDebounce-BiuGz9t2.js";import"./tooltip-DFFgUYh6.js";import"./useProjectId-DeuaOE3U.js";import"./includes-ucXR_9jq.js";import"./concat-CTXo1gGM.js";import"./useLazyInfiniteData-e9pn7fwX.js";import"./mergeRight-D1nsCm60.js";import"./range-fQfpUw16.js";import"./_isNumber-DRgbAj-F.js";import"./chain-C8Kkfd5P.js";import"./inc-BMMaAqPC.js";import"./add-SI0q72Q7.js";import"./time-utils-CQYZ5msB.js";import"./addDays-Cdit4yPz.js";import"./always-oSAuSdys.js";import"./init-Dq_gEBi9.js";import"./formatDistance-B6o-SXVU.js";const j=({data:o,isFetching:t,isLoading:e,hasMore:s,isFetchingMore:m,loadMore:i,component:a})=>{const{hasSearchCriteria:p}=f();return r.jsx("div",{className:"flex h-full w-full bg-muted",children:e?r.jsx("div",{className:"my-5 flex h-full w-full",children:r.jsx(l,{})}):r.jsxs("div",{className:"my-5 flex w-full flex-col items-center overflow-auto px-5",children:[t&&r.jsx("div",{className:"mb-5",children:r.jsx(x,{size:"lg"})}),!p&&o.length>0&&r.jsx(c,{className:"pb-2",children:"Result from previous search"}),r.jsx(a,{data:o}),m&&r.jsx(n,{className:"text-[40px] text-foreground"}),s&&!t&&r.jsx(d,{onLoadMore:i})]})})},Y=({docType:o,component:t})=>{const{id:e}=h(),s=u(o,e);return r.jsx(j,{component:t,...s})};export{Y as default};
