This commit is contained in:
ditiqi 2025-02-27 12:22:06 +08:00
parent ad6413b978
commit a0912fee02
1 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,23 @@
import PostList from "@web/src/components/models/course/list/PostList";
import { useMainContext } from "../../layout/MainProvider";
import PathCard from "../../path/components/PathCard";
import { useEffect } from "react";
export default function SearchListContainer() {
const { searchCondition, termsCondition, searchMode } = useMainContext();
return (
<>
<PostList
renderItem={(post) => <PathCard path={post}></PathCard>}
params={{
pageSize: 12,
where: {
type: searchMode === "both" ? undefined : searchMode,
...termsCondition,
...searchCondition,
},
}}
cols={4}></PostList>
</>
);
}