Skip to content
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

chore: sync main to feature #407

Closed
wants to merge 11 commits into from
Closed

chore: sync main to feature #407

wants to merge 11 commits into from

Conversation

YumoImer
Copy link
Collaborator

No description provided.

YumoImer and others added 11 commits December 20, 2024 23:16
* feat(bubble): add typing suffix support

* docs(Bubble): improve typing demo documentation

Co-authored-by: bqxbqx <[email protected]>
* feat: XStream 返回流同时支持异步迭代

* feat: asyncGenerator -> asyncIterable

* Update components/x-stream/index.ts

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* refactor: return to asyncGenerator

* refactor: delete try..finally

* refactor: add type

* feat: return stream

* feat: XReadableStream -> XReadableStream<Output>

* feat: add test

* feat: add interrupt streaming output demo

* feat: add cleanup code

* fix: add useEffect import

* fix: lint

* feat: update snapshot

---------

Co-authored-by: 行楠 <[email protected]>
Co-authored-by: 🏎️ Imer <[email protected]>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
* refactor: code semantics, typingSuffix -> customSuffix

* fix: code error
* feat: Sender support focus.

* refactor: demo dom

* chore: update test snap

* fix: ts error

* refactor: remove export SenderRef and use GetRef instead

* refactor: SenderRef

* docs: update SenderRef

* docs: add blur demo

* chore: update test snap

* refactor: useProxyImperativeHandle instead of React.useImperativeHandle

* test: add test for useProxyImperativeHandle
* chore: update version

* docs: update changelog of 1.0.4

* docs: fix

* docs: update img link (#395)

* refactor: delete repetitive style import (#394)

* feat: Sender support focus. (#397)

* feat: Sender support focus.

* refactor: demo dom

* chore: update test snap

* fix: ts error

* refactor: remove export SenderRef and use GetRef instead

* refactor: SenderRef

* docs: update SenderRef

* docs: add blur demo

* chore: update test snap

* refactor: useProxyImperativeHandle instead of React.useImperativeHandle

* test: add test for useProxyImperativeHandle

* chore: add DingTalk Release Notification (#401)

* docs: update changelog
Copy link
Contributor

coderabbitai bot commented Dec 25, 2024

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

Prepare preview

Copy link

Walkthrough\nThis pull request synchronizes the main branch with the feature branch. It includes updates to various components, enhancements, and bug fixes. Notable changes include the addition of new features, improvements to existing functionalities, and updates to documentation.\n\n### Changes\n| Files | Summary |\n|-------|---------|\n| .dumi/theme/common/PeterCat.tsx, .dumi/theme/layouts/GlobalLayout.tsx | Removed unused style import from @petercatai/assistant. |\n| .github/workflows/release-dingtalk.yml | Added new workflow configuration. |\n| CHANGELOG.en-US.md, CHANGELOG.zh-CN.md | Updated changelog with new features and fixes for version 1.0.4. |\n| README.md | Replaced <div> with <> for fragment shorthand. |\n| components/_util/tests/hooks.test.tsx, components/_util/hooks/use-proxy-imperative-handle.ts | Added new hook useProxyImperativeHandle and its test. |\n| components/attachments/demo/with-sender.tsx, components/sender/demo/focus.tsx, components/sender/demo/paste-image.tsx | Updated Sender component references and demos. |\n| components/bubble/Bubble.tsx, components/bubble/hooks/useTypingConfig.ts, components/bubble/interface.ts | Enhanced Bubble component with typing suffix support. |\n| components/sender/index.tsx | Refactored Sender component to use useProxyImperativeHandle. |\n| components/useXChat/demo/stream-cancel.tsx | Added demo for interrupting streaming output. |\n| components/x-stream/index.ts | Refactored XStream to support async iterator. |\n| docs/spec/intention-introduce.en-US.md, docs/spec/intention-introduce.zh-CN.md | Updated image links in documentation. |\n| package.json | Updated package version to 1.0.4 and dependencies. |

@@ -137,11 +137,13 @@ export interface XStreamOptions<Output> {
transformStream?: TransformStream<string, Output>;
}

type XReadableStream<R = SSEOutput> = ReadableStream<R> & AsyncGenerator<R>;

Choose a reason for hiding this comment

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

The XStream function has been refactored to return a ReadableStream that supports async iteration. Ensure that all usages of XStream are compatible with this change, as it may affect how streams are consumed in the application.

@YumoImer YumoImer closed this Dec 25, 2024
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.

3 participants