列表搜索页面
This commit is contained in:
@@ -3,10 +3,17 @@ import ListCard from "@/components/ListCard";
|
||||
import ListLoadError from "@/components/ListLoadError";
|
||||
import ListCardSkeleton from "@/components/ListCardSkeleton";
|
||||
import "./index.scss";
|
||||
import { useReachBottom } from "@tarojs/taro";
|
||||
|
||||
const ListContainer = (props) => {
|
||||
const { loading, data = [], error, reload, recommendList } = props;
|
||||
|
||||
useReachBottom(() => {
|
||||
console.log("触底了");
|
||||
// 调用 store 的加载更多方法
|
||||
// loadMoreMatches();
|
||||
});
|
||||
|
||||
if (error) {
|
||||
return <ListLoadError reload={reload} />;
|
||||
}
|
||||
@@ -38,6 +45,8 @@ const ListContainer = (props) => {
|
||||
<Text className="recommendText">搜索结果较少,已为你推荐其他内容</Text>
|
||||
</View>
|
||||
{renderList(recommendList)}
|
||||
{/* 到底了 */}
|
||||
<View className="bottomTextWrapper">到底了</View>
|
||||
</View>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user