addad
This commit is contained in:
parent
44c4d152b7
commit
2fdb634195
|
@ -18,7 +18,7 @@ export default function CourseDetailLayout() {
|
||||||
const handleLectureClick = (lectureId: string) => {
|
const handleLectureClick = (lectureId: string) => {
|
||||||
setSelectedLectureId(lectureId);
|
setSelectedLectureId(lectureId);
|
||||||
};
|
};
|
||||||
const [isSyllabusOpen, setIsSyllabusOpen] = useState(false);
|
const [isSyllabusOpen, setIsSyllabusOpen] = useState(true);
|
||||||
return (
|
return (
|
||||||
<div className="relative">
|
<div className="relative">
|
||||||
<CourseDetailHeader />
|
<CourseDetailHeader />
|
||||||
|
@ -30,6 +30,9 @@ export default function CourseDetailLayout() {
|
||||||
{" "}
|
{" "}
|
||||||
{/* 添加这个包装 div */}
|
{/* 添加这个包装 div */}
|
||||||
<motion.div
|
<motion.div
|
||||||
|
initial={{
|
||||||
|
width: "75%",
|
||||||
|
}}
|
||||||
animate={{
|
animate={{
|
||||||
width: isSyllabusOpen ? "75%" : "100%",
|
width: isSyllabusOpen ? "75%" : "100%",
|
||||||
}}
|
}}
|
||||||
|
|
Loading…
Reference in New Issue