Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 23, 2025

PR-8 PR-8 PR-8 Powered by Pull Request Badge

Consolidates scattered animate-spin implementations into a reusable Spinner component and adds a Loading overlay component based on the Idea-React reference.

Changes

  • New Spinner component - Centralizes all spinner animations with configurable sizes (sm/md/lg) and accessibility attributes
  • New Loading component - Full-screen overlay using Spinner for blocking operations
  • Refactored components - Replaced inline animate-spin divs in searchable-input, rest-table, and lucide-react's Loader2 in image-preview with Spinner
  • Registry updates - Added both components to shadcn registry with proper dependency tracking

Usage

// Simple spinner
<Spinner size="sm" />
<Spinner className="text-primary" />

// Full-screen loading overlay
<Loading>Processing data...</Loading>

All existing functionality preserved - changes are drop-in replacements.

Original prompt

当整个项目中的 animate-spin 抽出一个通用的 <Spinner /> 组件,并基于此实现:https://github.com/idea2app/Idea-React/blob/master/source%2FLoading.tsx

Human changes

  1. [optimize] simplify Copilot's source codes

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 4 commits December 23, 2025 10:55
Co-authored-by: TechQuery <19969570+TechQuery@users.noreply.github.com>
Co-authored-by: TechQuery <19969570+TechQuery@users.noreply.github.com>
Co-authored-by: TechQuery <19969570+TechQuery@users.noreply.github.com>
Co-authored-by: TechQuery <19969570+TechQuery@users.noreply.github.com>
Copilot AI changed the title [WIP] Extract common Spinner component from animate-spin Extract common Spinner component and add Loading overlay Dec 23, 2025
Copilot AI requested a review from TechQuery December 23, 2025 11:08
@TechQuery TechQuery changed the title Extract common Spinner component and add Loading overlay [add] Spinner & Loading components Dec 23, 2025
@TechQuery TechQuery marked this pull request as ready for review December 23, 2025 15:05
@TechQuery TechQuery merged commit fe1af35 into main Dec 23, 2025
1 check passed
@TechQuery TechQuery deleted the copilot/add-spinner-component branch December 23, 2025 15:22
@github-project-automation github-project-automation bot moved this from In progress to Done in 开源项目 Dec 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Some improvements

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants