Skip to content

feat(theme): add transition isPending UI to Sidebar#2778

Merged
SoonIter merged 1 commit intomainfrom
syt/add-transition-to-link
Nov 18, 2025
Merged

feat(theme): add transition isPending UI to Sidebar#2778
SoonIter merged 1 commit intomainfrom
syt/add-transition-to-link

Conversation

@SoonIter
Copy link
Member

@SoonIter SoonIter commented Nov 18, 2025

Summary

feat(theme): add transition isPending UI to Sidebar

20260227193723_rec_-convert

Related Issue

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

Copilot AI review requested due to automatic review settings November 18, 2025 10:45
@netlify
Copy link

netlify bot commented Nov 18, 2025

Deploy Preview for rspress-v2 ready!

Name Link
🔨 Latest commit 65eef2e
🔍 Latest deploy log https://app.netlify.com/projects/rspress-v2/deploys/691c574342a44500081aa8ad
😎 Deploy Preview https://deploy-preview-2778--rspress-v2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 18, 2025

Rsdoctor Bundle Diff Analysis

📁 web

Path: website/doc_build/web/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 14.3 MB - -
📄 JavaScript 13.7 MB - -
🎨 CSS 109.1 KB - -
🌐 HTML 0 B - -
📁 Other Assets 496.7 KB - -

Generated by Rsdoctor GitHub Action

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds transition pending UI feedback to the Sidebar component by integrating React's useTransition hook to show visual feedback during navigation.

Key changes:

  • Integrated useTransition hook in SidebarItem to track navigation pending state
  • Added pending state styling (opacity and background) to sidebar items
  • Refactored useLinkNavigate to accept an optional startTransition parameter
  • Fixed function naming issue in useScrollAfterNav.ts (renamed from useSetup)

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/core/src/theme/logic/useSetup.ts New empty placeholder function for setup logic
packages/core/src/theme/logic/useScrollAfterNav.ts Fixed incorrect function name from useSetup to useScrollAfterNav
packages/core/src/theme/layout/Layout/index.tsx Reorganized imports to use @theme exports instead of relative paths
packages/core/src/theme/index.ts Updated exports to include type exports and moved useSetup to new location
packages/core/src/theme/components/Sidebar/SidebarItem.tsx Added useTransition hook integration and passed startTransition to Link component
packages/core/src/theme/components/Sidebar/SidebarItem.scss Added pending state styling with reduced opacity and background color
packages/core/src/theme/components/Link/useLinkNavigate.ts Modified to accept optional startTransition parameter for transition support
packages/core/src/theme/components/Link/index.tsx Added startTransition prop and passed it to useLinkNavigate

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@SoonIter SoonIter force-pushed the syt/add-transition-to-link branch from 89154b8 to 65eef2e Compare November 18, 2025 11:23
@SoonIter SoonIter merged commit b5f73cd into main Nov 18, 2025
9 checks passed
@SoonIter SoonIter deleted the syt/add-transition-to-link branch November 18, 2025 12:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants