Skip to content

fix: share one tooltip provider and wrap long tooltip content - #257

Merged
everpcpc merged 1 commit into
masterfrom
fix/tooltip-shared-provider
Oct 18, 2026
Merged

everpcpc merged 1 commit into
masterfrom
fix/tooltip-shared-provider

Conversation

@everpcpc

Copy link
Copy Markdown
Member

Goal

Two tooltip annoyances, most visible on the book detail page's File field:

  • Slow to appear: every Tooltip instance created its own Radix Provider, so Radix's grouping behavior (after the first tooltip opens, adjacent ones open instantly) never kicked in — each tooltip waited the full 350 ms delay, every time.
  • Awkward look for long content: the content had no width constraint, so a full file path rendered as a single unwrapped line stretching across the screen.

Changes

  • Hoist a single TooltipProvider (delayDuration={350}) to the app root in main.tsx; the Tooltip component no longer wraps each instance in its own Provider. Moving between tooltips now re-opens instantly within Radix's skip-delay window.
  • Constrain the content bubble: max-w-sm + break-words, so long paths wrap instead of overflowing.

All 20 tooltip call sites (16 files) go through the shared component, so the fix applies everywhere.

Test

  • pnpm lint and pnpm build (tsc + vite) pass.

@everpcpc
everpcpc marked this pull request as ready for review October 18, 2026 17:39
@everpcpc
everpcpc merged commit 3822e35 into master Oct 18, 2026
7 checks passed
@everpcpc
everpcpc deleted the fix/tooltip-shared-provider branch October 18, 2026 17:39
everpcpc added a commit that referenced this pull request Oct 18, 2026
## Goal

Bump the workspace version to 0.22.3 (patch). Covers since 0.22.2:

- feat: media comment on book/oneshot detail pages, with clamped long comments (#252)
- feat: the update check outcome moved to an always-200 `/api/v1/update-check` (#253)
- ci: aggregate always-reporting gate job (#254)
- fix: zero-count segments hidden in library and series stat lines (#255)
- fix: oneshots library field relabeled as the keyword it is (#256)
- fix: shared tooltip provider (instant re-open) and wrapped long content (#257, #258)

The release workflow publishes the GitHub release and tag once this lands on master.

## Test

- `cargo check --workspace` (Cargo.lock synced)
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