跳到内容
Yuva help article菜单

Yuva help article

One help article with its sanitized body, a Was this helpful? Yes and No rating, related articles and a Message us button that hands the article id to your chat.

预览使用示例数据运行,不需要网络,也不需要渠道。

安装

在 shadcn 项目中运行。文件会复制到你自己的代码里。

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

用法

tsx
import { YuvaHelpArticle } from "@/components/yuva-help-article"

<YuvaHelpArticle server={server} channel={channel} id={articleId} onAsk={(id) => chat.open(id)} />

Props

YuvaHelpArticleProps

Prop类型
idstring
server?string
channel?string
client?YuvaClient
identityToken?IdentityTokenSource | null
locale?string
help?YuvaHelpState
search?string
onSelect?(article: ClientHelpArticleSummary) => void
onAsk?(articleId: string) => void
labels?Partial<YuvaHelpLabels>
className?string

标签

标签列在 Yuva help 页面。

依赖

安装此项时还会添加以下内容。

来自 shadcn/ui 的组件

其他 Yuva 项

npm 包