You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Remove the direct Floating UI React dependency - #1550
Switch the npm stats tooltip to the Radix Tooltip primitives already used on the site. Keep the immediate hover, keyboard focus, placement offset, and popup styling.
Remove @floating-ui/react and its exclusive tabbable dependency from the lockfile. Radix and Base UI continue to use the remaining Floating UI packages transitively.
Verification
Type checking, lint, and 13 npm stats tests passed locally. Verified that standalone tooltip buttons and Radix menu triggers retain their native button markup and menu ARIA attributes.
The Vite build succeeded with Redact disabled for local bundle analysis. The analyzer reports no longer contain @floating-ui/react.
The pnpm test script stopped at the tsx IPC socket permission error, so the npm stats tests ran through Node's tsx loader. Chromium could not start in this environment.
Summary by CodeRabbit
Updates
Tooltips now use a portal for display, support placement on different sides of the trigger, and appear without a delay. Hovering over tooltip content no longer keeps it open.
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
No actionable comments were generated in the recent review.
Walkthrough
The Tooltip component now uses Radix Tooltip primitives instead of Floating UI state, positioning, and event handlers. Its children type is generalized, and the @floating-ui/react dependency is removed.
Changes: Tooltip migration
Layer / File(s)
Summary
Tooltip component and dependency update src/components/Tooltip.tsx, package.json
TooltipProps.children now uses React.ReactElement. The component uses Radix Tooltip primitives with zero delay, non-hoverable content, asChild, and a 5-pixel side offset. The placement prop maps to Radix side. The Floating UI dependency is removed.
The npm stats tooltip now uses the Radix Tooltip primitives already used elsewhere on the site, and the unused Floating UI dependency is removed. No concrete regression was found, and the change can be reverted easily if a visual or interaction difference shows up in a browser.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title "Remove the direct Floating UI React dependency" matches the main change. The PR removes @floating-ui/react from package.json and the lockfile. It also rewrites the Tooltip component to …
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "Remove the direct Floating UI React dependency" matches the main change. The PR removes @floating-ui/react from package.json and the lockfile. It also rewrites the Tooltip component to use Radix Tooltip primitives. The title names the dependency removal but not the Radix migration, which is the main code change. The title is specific and concise, so it passes.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
File: No configuration file from this repository applied
Commit: Unavailable
Layers: defaults
Review profile: CHILL
Plan: Advanced
Run ID: 9538de9c-c2ec-4bca-b04e-34874e505eb0
Commits
Reviewing files that changed from the base of the PR and between a205832 and 66ea72a.
Files ignored due to path filters: 1
pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing: 2
package.json
src/components/Tooltip.tsx
Files with no reviewable changes: 1
package.json
Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 1 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
@floating-ui/reactand its exclusivetabbabledependency from the lockfile. Radix and Base UI continue to use the remaining Floating UI packages transitively.Verification
@floating-ui/react.pnpm testscript stopped at thetsxIPC socket permission error, so the npm stats tests ran through Node'stsxloader. Chromium could not start in this environment.Summary by CodeRabbit