Skip to content

Refactor: Extract shared AnimatedStarsBackground component #72

@coderabbitai

Description

@coderabbitai

Issue Description

There is duplicated star animation code between the SignIn page (apps/web/src/app/signin/page.tsx) and SignUp page that should be extracted into a reusable component.

Current Problem

The star animation JSX code is duplicated across multiple authentication pages, leading to code duplication and maintenance overhead.

Proposed Solution

Create a reusable AnimatedStarsBackground component that:

  • Encapsulates star positions, sizes, and animation delays in a data array
  • Maps over the array to render StarIcon elements
  • Can be imported and used across different pages

Implementation Details

The component should be created at components/ui/AnimatedStarsBackground.tsx and replace the duplicated star JSX in both signin and signup pages.

References

Acceptance Criteria

  • Create AnimatedStarsBackground component
  • Replace duplicated code in signin page
  • Replace duplicated code in signup page
  • Ensure visual behavior remains identical
  • Add appropriate TypeScript types

Metadata

Metadata

Labels

Projects

Status

Todo

Relationships

None yet

Development

No branches or pull requests

Issue actions