-
-
Notifications
You must be signed in to change notification settings - Fork 201
docs: add Callout component documentation #2998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for rspress-v2 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Rsdoctor Bundle Diff AnalysisFound 3 projects in monorepo, 3 projects with changes. 📊 Quick Summary
📋 Detailed Reports (Click to expand)📁 nodePath:
📦 Download Diff Report: node Bundle Diff 📁 webPath:
📦 Download Diff Report: web Bundle Diff 📁 node_mdPath:
📦 Download Diff Report: node_md Bundle Diff Generated by Rsdoctor GitHub Action |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This pull request adds comprehensive documentation for the Callout component in both English and Chinese. The Callout component is used to display highlighted information blocks such as tips, warnings, and notes.
Changes:
- Added English documentation for the Callout component (
website/docs/en/ui/components/callout.mdx) - Added Chinese documentation for the Callout component (
website/docs/zh/ui/components/callout.mdx) - Documents both container syntax usage (recommended) and direct component usage in MDX files
- Includes customization instructions via component ejection
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| website/docs/en/ui/components/callout.mdx | English documentation for the Callout component, including usage examples, customization guide, and Props interface |
| website/docs/zh/ui/components/callout.mdx | Chinese documentation for the Callout component, providing the same content as the English version in Chinese |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
2beb671 to
02c0b52
Compare
|
@copilot 执行 |
- `website/docs/en/ui/components/callout.mdx`
- `website/docs/zh/ui/components/callout.mdx`
文档内容包括:
1. **容器语法** - 推荐方式,展示所有类型(note/tip/info/warning/danger/details)和自定义标题
2. **组件用法** - 通过 `import { Callout } from '@rspress/core/theme-original'` 直接使用
3. **自定义** - 通过 `npx rspress eject Callout` 导出并自定义
4. **Props** - 组件的类型定义
**新增文件:** - `website/docs/en/fragments/container-syntax.mdx` - 英文容器语法示例 - `website/docs/zh/fragments/container-syntax.mdx` - 中文容器语法示例 **修改文件:** - `website/docs/en/guide/use-mdx/container.mdx` - 使用 `<ContainerSyntax />` fragment - `website/docs/zh/guide/use-mdx/container.mdx` - 使用 `<ContainerSyntax />` fragment - `website/docs/en/ui/components/callout.mdx` - 使用 `<ContainerSyntax />` fragment - `website/docs/zh/ui/components/callout.mdx` - 使用 `<ContainerSyntax />` fragment 现在 container.mdx 和 callout.mdx 共享同一个 fragment,避免了重复内容。
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: SoonIter <[email protected]>
afc7d60 to
0dfa10d
Compare
Summary
Related Issue
Checklist
AI Summary
Add documentation for the Callout component in both English and Chinese.
Changes Made
website/docs/en/ui/components/callout.mdxwebsite/docs/zh/ui/components/callout.mdxDocumentation Contents
import { Callout } from '@rspress/core/theme-original'for MDX filesnpx rspress eject CalloutWhy
The Callout component is an eject-only component that powers the container syntax (
:::tip,:::warning, etc.). Users who want to customize its appearance need documentation on:This PR was written using Vibe Kanban