Skip to content

docs: 添加构建文档脚本#559

Merged
ikenxuan merged 1 commit intomainfrom
feat-typedoc
Oct 11, 2025
Merged

docs: 添加构建文档脚本#559
ikenxuan merged 1 commit intomainfrom
feat-typedoc

Conversation

@ikenxuan
Copy link
Collaborator

@ikenxuan ikenxuan commented Oct 11, 2025

Sourcery 总结

配置并启用使用 TypeDoc 为核心包自动生成 API 文档的功能。

新功能:

  • 添加 TypeDoc、typedoc-plugin-markdown 和 typedoc-vitepress-theme 作为开发依赖项
  • 引入一个 "docs:build" npm 脚本,用于通过 TypeDoc 生成文档
  • 添加一个 typedoc.config.js 文件,用于定义文档输出、主题和分类

改进:

  • 澄清 ScreenshotOptions 中 encoding 选项的弃用消息
Original summary in English

Summary by Sourcery

Configure and enable automatic API documentation generation for the core package using TypeDoc.

New Features:

  • Add TypeDoc, typedoc-plugin-markdown, and typedoc-vitepress-theme as dev dependencies
  • Introduce a "docs:build" npm script to generate documentation via TypeDoc
  • Add a typedoc.config.js file to define documentation output, theming, and categorization

Enhancements:

  • Clarify the deprecation message for the encoding option in ScreenshotOptions

@ikenxuan ikenxuan merged commit 8cca251 into main Oct 11, 2025
2 of 3 checks passed
@ikenxuan ikenxuan deleted the feat-typedoc branch October 11, 2025 22:34
@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Oct 11, 2025

🧙 Sourcery 正在审查您的拉取请求!


提示和命令

与 Sourcery 互动

  • 触发新审查: 在拉取请求上评论 @sourcery-ai review
  • 继续讨论: 直接回复 Sourcery 的审查评论。
  • 从审查评论生成 GitHub issue: 通过回复审查评论,要求 Sourcery 从中创建一个 issue。您也可以回复审查评论并带上 @sourcery-ai issue 来从中创建一个 issue。
  • 生成拉取请求标题: 随时在拉取请求标题的任何位置写入 @sourcery-ai 以生成标题。您也可以在拉取请求上评论 @sourcery-ai title 以随时(重新)生成标题。
  • 生成拉取请求摘要: 随时在拉取请求正文的任何位置写入 @sourcery-ai summary 以在您想要的位置生成 PR 摘要。您也可以在拉取请求上评论 @sourcery-ai summary 以随时(重新)生成摘要。
  • 生成审阅者指南: 随时在拉取请求上评论 @sourcery-ai guide 以(重新)生成审阅者指南。
  • 解决所有 Sourcery 评论: 在拉取请求上评论 @sourcery-ai resolve 以解决所有 Sourcery 评论。如果您已经处理了所有评论并且不想再看到它们,这会很有用。
  • 关闭所有 Sourcery 审查: 在拉取请求上评论 @sourcery-ai dismiss 以关闭所有现有的 Sourcery 审查。如果您想重新开始新的审查,这会特别有用——别忘了评论 @sourcery-ai review 来触发新的审查!

自定义您的体验

访问您的 仪表板 以:

  • 启用或禁用审查功能,例如 Sourcery 生成的拉取请求摘要、审阅者指南等。
  • 更改审查语言。
  • 添加、删除或编辑自定义审查说明。
  • 调整其他审查设置。

获取帮助

Original review guide in English

🧙 Sourcery is reviewing your pull request!


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

你好 - 我已经审阅了你的更改,它们看起来很棒!

AI 代理提示
请处理此代码审查中的评论:

## Individual Comments

### Comment 1
<location> `packages/core/src/adapter/render/admin/types.ts:73-78` </location>
<code_context>
    * 图像的编码方式。
    *
-   * @deprecated 这是无效选项,强制性返回string<base64>
+   * @deprecated 这是无效选项,强制性返回base64编码的字符串
    */
   encoding?: 'base64' | 'binary'
</code_context>

<issue_to_address>
**建议:** 澄清编码选项的弃用消息。

在弃用消息中明确指出用户应该使用什么替代方案,或者明确说明该选项已被忽略,以防止混淆。

```suggestion
  /**
   * 图像的编码方式。
   *
   * @deprecated 此选项已被弃用且会被忽略,始终返回 base64 编码的字符串。请勿使用该选项,直接依赖默认行为即可。
   */
  encoding?: 'base64' | 'binary'
```
</issue_to_address>

Sourcery 对开源项目免费 - 如果你喜欢我们的审查,请考虑分享它们 ✨
帮助我更有用!请点击每个评论上的 👍 或 👎,我将利用这些反馈来改进你的审查。
Original comment in English

Hey there - I've reviewed your changes and they look great!

Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location> `packages/core/src/adapter/render/admin/types.ts:73-78` </location>
<code_context>
    * 图像的编码方式。
    *
-   * @deprecated 这是无效选项,强制性返回string<base64>
+   * @deprecated 这是无效选项,强制性返回base64编码的字符串
    */
   encoding?: 'base64' | 'binary'
</code_context>

<issue_to_address>
**suggestion:** Clarify the deprecation message for encoding option.

Specify in the deprecation message what users should use instead, or clearly state that the option is ignored to prevent confusion.

```suggestion
  /**
   * 图像的编码方式。
   *
   * @deprecated 此选项已被弃用且会被忽略,始终返回 base64 编码的字符串。请勿使用该选项,直接依赖默认行为即可。
   */
  encoding?: 'base64' | 'binary'
```
</issue_to_address>

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Comment on lines 73 to 78
/**
* 图像的编码方式。
*
* @deprecated 这是无效选项,强制性返回string<base64>
* @deprecated 这是无效选项,强制性返回base64编码的字符串
*/
encoding?: 'base64' | 'binary'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

建议: 澄清编码选项的弃用消息。

在弃用消息中明确指出用户应该使用什么替代方案,或者明确说明该选项已被忽略,以防止混淆。

Suggested change
/**
* 图像的编码方式。
*
* @deprecated 这是无效选项,强制性返回string<base64>
* @deprecated 这是无效选项,强制性返回base64编码的字符串
*/
encoding?: 'base64' | 'binary'
/**
* 图像的编码方式。
*
* @deprecated 此选项已被弃用且会被忽略,始终返回 base64 编码的字符串。请勿使用该选项,直接依赖默认行为即可。
*/
encoding?: 'base64' | 'binary'
Original comment in English

suggestion: Clarify the deprecation message for encoding option.

Specify in the deprecation message what users should use instead, or clearly state that the option is ignored to prevent confusion.

Suggested change
/**
* 图像的编码方式。
*
* @deprecated 这是无效选项,强制性返回string<base64>
* @deprecated 这是无效选项,强制性返回base64编码的字符串
*/
encoding?: 'base64' | 'binary'
/**
* 图像的编码方式。
*
* @deprecated 此选项已被弃用且会被忽略,始终返回 base64 编码的字符串。请勿使用该选项,直接依赖默认行为即可。
*/
encoding?: 'base64' | 'binary'

@github-actions github-actions bot mentioned this pull request Oct 11, 2025
@github-actions
Copy link
Contributor

你可以通过以下命令安装该版本:

pnpm add https://pkg.pr.new/node-karin@5187580 -w

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant