ข้ามไปยังเนื้อหา
Yuva discussion threadเมนู

Yuva discussion thread

One discussion: the opening post, the accepted answer, replies one level deep, votes, follow, accept, edit and delete, and the reply composer.

ตัวอย่างทำงานด้วยข้อมูลตัวอย่าง ไม่ต้องใช้เครือข่ายหรือช่องทาง

การติดตั้ง

รันคำสั่งนี้ในโปรเจกต์ shadcn ไฟล์จะถูกคัดลอกไปเป็นโค้ดของคุณเอง

Shell
npx shadcn@latest add https://useyuva.com/r/yuva-discussion-thread.json

การใช้งาน

tsx
import { YuvaDiscussionThread } from "@/components/yuva-discussion-thread"

<YuvaDiscussionThread id={id} onBack={() => setId(null)} />

Props

YuvaDiscussionThreadProps

Propชนิด
idstring
labels?Partial<YuvaDiscussionsLabels>
className?string
onBack?() => void
onGone?() => void
badges?(discussion: Discussion) => React.ReactNode
votingClosed?(discussion: Discussion) => boolean

ป้ายข้อความ

รายการป้ายข้อความอยู่ที่หน้า Yuva discussions

ส่วนที่ต้องพึ่งพา

การติดตั้งรายการนี้จะเพิ่มรายการต่อไปนี้ด้วย

คอมโพเนนต์จาก shadcn/ui

รายการ Yuva อื่น ๆ

แพ็กเกจ npm