Skip to content

Expose motion ref type#78

Open
QDyanbing wants to merge 1 commit into
react-component:masterfrom
QDyanbing:avoid-deep-imports
Open

Expose motion ref type#78
QDyanbing wants to merge 1 commit into
react-component:masterfrom
QDyanbing:avoid-deep-imports

Conversation

@QDyanbing
Copy link
Copy Markdown
Contributor

变更内容

  • 升级 @rc-component/util 到当前 latest ^1.11.1
  • 在根入口补充导出 CSSMotionRef 类型,方便下游从包根入口使用公开 API。

背景

配合 rc 包统一避免依赖其他 rc 包的 es / lib 构建产物内部路径,缺失的类型从包根入口补齐导出。

验证

  • git diff --check
  • commit hook 已执行 prettier
  • 此前批量调整中已跑通 npm run compilenpm run lintnpm test

@vercel
Copy link
Copy Markdown

vercel Bot commented May 19, 2026

@QDyanbing is attempting to deploy a commit to the React Component Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 19, 2026

Warning

Rate limit exceeded

@QDyanbing has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 41 minutes and 39 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 9c80d8e7-4172-40f6-998e-6f71c21b25f2

📥 Commits

Reviewing files that changed from the base of the PR and between 5b7cb37 and ee4f07c.

📒 Files selected for processing (2)
  • package.json
  • src/index.tsx
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 19, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.09%. Comparing base (5b7cb37) to head (ee4f07c).

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #78   +/-   ##
=======================================
  Coverage   98.09%   98.09%           
=======================================
  Files          11       11           
  Lines         421      421           
  Branches      120      119    -1     
=======================================
  Hits          413      413           
  Misses          7        7           
  Partials        1        1           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates the @rc-component/util dependency and adds CSSMotionRef to the library's public exports. The reviewer suggested also importing and exporting the MotionName type to further complete the public API and improve usability for downstream consumers.

Comment thread src/index.tsx
Comment on lines +1 to +5
import type {
CSSMotionConfig,
CSSMotionProps,
CSSMotionRef,
} from './CSSMotion';
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

为了支持在根入口导出 MotionName 类型,建议在此处增加导入。这有助于完善公开 API,方便下游用户在定义 motionName 属性时直接使用该类型。

Suggested change
import type {
CSSMotionConfig,
CSSMotionProps,
CSSMotionRef,
} from './CSSMotion';
import type {
CSSMotionConfig,
CSSMotionProps,
CSSMotionRef,
MotionName,
} from './CSSMotion';

Comment thread src/index.tsx
export type {
CSSMotionConfig,
CSSMotionProps,
CSSMotionRef,
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

建议在此处导出 MotionName 类型。作为 CSSMotionProps 的重要组成部分,导出该类型可以避免下游用户引用内部路径,符合本次 PR “补齐导出缺失类型”的改进目标。

Suggested change
CSSMotionRef,
CSSMotionRef,
MotionName,

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