Skip to content

fix(widget): stop header scrollbar flicker while history spinner runs - #925

Open
thesems wants to merge 3 commits into
mainfrom
fix/history-spinner-scrollbar
Open

thesems wants to merge 3 commits into
mainfrom
fix/history-spinner-scrollbar

Conversation

@thesems

@thesems thesems commented Nov 6, 2026 •

Copy link
Copy Markdown

Which Linear task is linked to this PR?

None.

Summary

While a transaction is in progress, the history button shows a spinning ring. During that time the header's scrollbar kept appearing and disappearing, which moved the whole view up and down.

The ring spins by rotating its 40×40 box. At 45° that box measures about 56px, so it sticks out about 8px past the button. The header container has overflow: auto and no bottom padding, so on each turn the rotated box made it overflow and show a scrollbar for part of the time.

screenrecording-2026-11-06_09-01-48.mp4

Changes

  • ActivitiesButton: the track and the spinning ring now sit inside a new ProgressClip box (40×40, overflow: hidden). The ring is round and fits inside the box, so the clip hides nothing visible.
  • ProgressTrack: added top: 0, left: 0. Without them, IconButton's text-align: center moved the track 20px to the right inside the clip.
  • Changeset: patch for @lifi/widget.

Why was it implemented this way?

  • Changing the header's overflow: auto would affect every header layout and custom theme.header config.
  • Putting overflow: hidden on the button itself would clip the error badge in its top-right corner.
  • Clipping only the spinner keeps the change inside ActivitiesButton.

Visual showcase (Screenshots or Videos)

Test results

  • pnpm --filter @lifi/widget check:types: 0 errors. Biome and knip passed in the pre-commit hook.
  • Minimal reproduction in Chromium: an overflow:auto container with no bottom padding, holding a 40px box rotated 45°. Without the clip, the content was 60px tall in a 52px container (scrollbar). With the clip, both were 52px (no scrollbar).
  • Checked manually in the playground during a running transaction: no scrollbar flicker, and the track and spinner line up.

Known limitations

  • No automated test covers this; the fix is visual only.

Checklist before requesting a review

  • I have performed a self-review and testing of my code.
  • This pull request is focused and addresses a single problem.
  • If this PR modifies the Widget API or adds new features that require documentation, I have updated the documentation in the public-docs repository.

🤖 Generated with Claude Code

Clip the rotating progress ring so its box no longer overflows the scrollable header.
@changeset-bot

changeset-bot Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 83be98b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 20 packages
Name Type
@lifi/widget Patch
@lifi/widget-checkout Patch
connectkit Patch
deposit-flow Patch
dynamic Patch
nextjs Patch
nextjs15 Patch
nft-checkout Patch
nuxt-app Patch
privy-ethers-example Patch
privy Patch
rainbowkit Patch
react-router Patch
remix Patch
reown Patch
svelte Patch
tanstack-router-example Patch
vite-project Patch
vue Patch
zustand-widget-config Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

📦 Bundle size

✅ No significant changes. Every check is within budget.

@lifi/widget

Import Base PR Change Budget used
⚪ LiFiWidget (without translations) 277.1 kB 277.2 kB 🔺 +0.17 kB (+0.1%) ▰▰▰▰▰▰▰▰▰▱ 86%
⚪ English translations (always loaded) 7.44 kB 7.44 kB — ▰▰▰▰▰▰▰▱▱▱ 74%
⚪ /shared (all exports) 175.3 kB 175.5 kB 🔺 +0.25 kB (+0.1%) ▰▰▰▰▰▰▰▰▰▱ 85%
⚪ /queries (all exports) 2.14 kB 2.14 kB — ▰▰▰▰▰▰▰▱▱▱ 71%
⚪ /skeleton (WidgetSkeleton) 44.0 kB 44.0 kB — ▰▰▰▰▰▰▰▰▱▱ 83%

@lifi/wallet-management

Import Base PR Change Budget used
⚪ all exports (without translations) 72.4 kB 72.4 kB — ▰▰▰▰▰▰▰▰▱▱ 82%

@lifi/widget-light

Import Base PR Change Budget used
⚪ LiFiWidgetLight 1.21 kB 1.21 kB — ▰▰▰▰▰▰▱▱▱▱ 60%

Providers

Import Base PR Change Budget used
⚪ ethereum 101.2 kB 101.2 kB — ▰▰▰▰▰▰▰▰▰▱ 86%
⚪ solana 31.9 kB 31.9 kB — ▰▰▰▰▰▰▰▰▱▱ 82%
⚪ bitcoin 89.1 kB 89.1 kB — ▰▰▰▰▰▰▰▰▱▱ 83%
⚪ sui 99.2 kB 99.2 kB — ▰▰▰▰▰▰▰▰▰▱ 89%
⚪ tron (incl. WalletConnect loaded on demand) 721.3 kB 721.3 kB — ▰▰▰▰▰▰▰▰▱▱ 82%
⚪ stellar 180.3 kB 180.3 kB — ▰▰▰▰▰▰▰▰▱▱ 85%
⚪ zcash 6.59 kB 6.59 kB — ▰▰▰▰▰▰▰▰▱▱ 82%

Full integration

Import Base PR Change Budget used
⚪ LiFiWidget + all providers + their peers (incl. on-demand code) 2003.2 kB 2003.1 kB 🔻 −0.14 kB (−0.0%) ▰▰▰▰▰▰▰▰▰▱ 87%
How to read this
  • Sizes are minified + brotli, measured with size-limit the way an app bundles the import: tree-shaken, with all dependencies included except the ones in the check's ignore list (packages the app already has, such as peers).
  • Code behind a dynamic import() is counted too, unless the check's name says otherwise.
  • 🟠 / 🟢 mark a change of at least 512 B and at least 1% or 5.00 kB. 🔴 means the check is over its budget.
  • Budgets live in .size-limit.json. The base commit is measured with the same checks as the PR.

83be98b merged into 8186786 · workflow run

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

✅ E2E Dev Smoke — passing

Check Result
Dev server start (pnpm dev) ✅ started
Smoke tests ✅ passed

4 passed · 0 failed · 0 skipped · 22s

View run

@thesems
thesems marked this pull request as ready for review November 6, 2026 08:06
@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

E2E Examples — all passed

All examples passed in the latest run.

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

E2E Playground results

passed  164 passed

Details

stats  164 tests across 11 suites
duration  2 minutes, 18 seconds
commit  83be98b

📥 Download full HTML report (open the run → Artifacts → playwright-report)

The CircularProgressPending root rotated, so its corners overflowed every scroll
container around it (the header, the active transaction card and the step timer
ring). Keep the root still and clipped, and rotate the SVG inside it. Center the
history ring with a shared size and reuse ProgressTrack from the timer styles.
@chybisov

Copy link
Copy Markdown
Member

@thesems I pushed a commit on top of yours (dfa261c). Now the spinner root stays still and clips, and only its SVG rotates. This replaces ProgressClip and also fixes the spinners in the transaction card and the step timer.

Please test the solution again on the preview deployment.

This branch was successfully deployed

1 active deployment
widget-test-pr-925 — 83be98b8 Deployed Nov 13, 2026 by chybisov via Publish to Cloudflare Pages #3399
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants