added mobile category page
This commit is contained in:
27
features/category/components/CategoriesClient.tsx
Normal file
27
features/category/components/CategoriesClient.tsx
Normal file
@@ -0,0 +1,27 @@
|
||||
"use client";
|
||||
|
||||
import { useTranslations } from "next-intl";
|
||||
import CategoryGrid from "@/features/home/components/CategoryGrid";
|
||||
import { useCategories } from "@/lib/hooks";
|
||||
|
||||
export default function CategoriesClient({ locale }: { locale: string }) {
|
||||
const t = useTranslations("common");
|
||||
const {
|
||||
data: categories,
|
||||
isLoading: categoriesLoading,
|
||||
isError: categoriesError,
|
||||
} = useCategories();
|
||||
|
||||
return (
|
||||
<div className="px-2 md:px-4 lg:px-6 pt-4 pb-12 max-w-[1504px] mx-auto min-h-screen">
|
||||
<CategoryGrid
|
||||
categories={categories}
|
||||
isLoading={categoriesLoading}
|
||||
isError={categoriesError}
|
||||
locale={locale}
|
||||
title={t("categories")}
|
||||
showAllOnMobile={true}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user