slide
This commit is contained in:
@@ -6,11 +6,14 @@ import { useParams } from "next/navigation";
|
||||
import Text from "../lib_components/text";
|
||||
import Link from "next/link";
|
||||
import { useCarType } from "@/store/carType";
|
||||
import { useSubCategory } from "@/store/subCategory";
|
||||
|
||||
export default function CarType_Header() {
|
||||
const params = useParams();
|
||||
const initialCar = useCarType((state) => state.initialCar);
|
||||
console.log(params);
|
||||
const initialSubCategory = useSubCategory(
|
||||
(state) => state.initialSubCategory,
|
||||
);
|
||||
return (
|
||||
<div
|
||||
dir="ltr"
|
||||
@@ -35,7 +38,7 @@ export default function CarType_Header() {
|
||||
id="title"
|
||||
className="text-white font-bold text-4xl tracking-[2px]"
|
||||
>
|
||||
<Text txt={`${params.carType}`} />
|
||||
<Text txt={`${initialSubCategory.name}`} />
|
||||
</div>
|
||||
|
||||
<div
|
||||
@@ -57,7 +60,7 @@ export default function CarType_Header() {
|
||||
: "text-secondary"
|
||||
}
|
||||
>
|
||||
{initialCar.name}
|
||||
{initialSubCategory.name}
|
||||
</Link>
|
||||
{params.carDeatil && "/"}
|
||||
{params.carDeatil && (
|
||||
|
||||
Reference in New Issue
Block a user