"use client";
import { useState } from "react";
import { Button } from "@/components/ui/button";
import { Input } from "@/components/ui/input";
import { Textarea } from "@/components/ui/textarea";
import {
ChevronDown,
Flag,
MessageCircle,
Share2,
ThumbsUp,
} from "lucide-react";
import { useRouter } from "next/navigation";
export default function DetailCommentVideo() {
const [isLoggedIn, setIsLoggedIn] = useState(false);
const router = useRouter();
return (
Comments on:
Kolaborasi dengan Ponpes Darunnajah, Pererat Sinergi Keamanan Hingga
Pembinaan Generasi Muda
{/* Comment Form */}
{isLoggedIn ? (
<>
>
) : (
<>
>
)}
{/* Sort & Comment Count */}
All Comments{" "}
4
Sort by
{/* Comments List */}
);
}
type Comment = {
name: string;
time: string;
content: string;
inReplyTo?: string;
};
function CommentItem({
name,
time,
content,
replies,
}: Comment & { replies?: Comment[] }) {
return (
{name}{" "}
{time}
{content}
{replies && replies.length > 0 && (
{replies.map((reply, idx) => (
{reply.name}{" "}
{reply.time}
In Reply To {reply.inReplyTo}
{reply.content}
))}
)}
);
}