nerulyrics
A modern music streaming web application with synchronized lyrics and auto-hide UI. Built with React, TypeScript, and Tailwind CSS.
NerU Lyrics šµ
A modern music streaming web application with synchronized lyrics and auto-hide UI. Built with React, TypeScript, and Tailwind CSS.
#⨠Features
- š Smart Music Search - Search across multiple music databases
- šµ Audio Streaming - Stream music directly in your browser
- š Synchronized Lyrics - Real-time lyrics that highlight as the song plays
- š» Auto-Hide UI - Controls automatically hide when mouse is idle during playback
- š„ļø Fullscreen Lyrics - Immersive lyrics viewing experience
- šØ Modern Design - Beautiful gradient backgrounds and smooth animations
- š± Responsive - Works on desktop, tablet, and mobile devices
#š Quick Start
-
Clone the repository
git clone https://github.com/nerufuyo/nerulyrics.git cd nerulyrics
-
Install dependencies
npm install
-
Set up environment variables (optional)
cp .env.example .env # Edit .env and add your YouTube API key for live search
-
Start the development server
npm run dev
-
Open your browser and navigate to
http://localhost:5173
#š ļø Tech Stack
- Frontend: React 18 + TypeScript
- Build Tool: Vite
- Styling: Tailwind CSS
- Icons: Lucide React
- HTTP Client: Axios
- APIs: YouTube Data API, Lyrics.ovh API
#šÆ How It Works
##Search & Play
- Type any song, artist, or album name in the search bar
- Click on a search result to start playing
- Enjoy synchronized lyrics that appear in real-time
##Auto-Hide UI
- When music is playing, move your mouse to see controls
- After 4 seconds of inactivity, controls smoothly fade away
- Perfect for distraction-free lyrics reading
##Fullscreen Lyrics
- Click the fullscreen button for an immersive lyrics experience
- Large, centered text with smooth scrolling
- Escape or click X to return to normal view
#š§ API Configuration
##YouTube Data API (Optional)
For live music search, you'll need a YouTube Data API key:
- Go to Google Cloud Console
- Create a new project or select existing one
- Enable YouTube Data API v3
- Create credentials (API key)
- Add the key to your
.env
file asVITE_YOUTUBE_API_KEY
Note: The app works without API keys using demo data for testing.
#šØ UI Features
##Auto-Hide Controls
// Mouse idle detection with customizable timeout
const { showUI } = useMouseIdle(4000, isPlaying);
##Synchronized Lyrics
// Real-time lyrics synchronization
const { currentLine } = useSyncedLyrics(lyrics, currentTime);
##Smooth Animations
- Fade transitions for UI elements
- Smooth scrolling lyrics
- Gradient progress bars
- Hover effects on interactive elements
#š± Responsive Design
- Desktop: Full featured experience with all controls
- Tablet: Optimized layout for touch interaction
- Mobile: Simplified UI with essential controls
#šµ Supported Features
- ā Music search and streaming
- ā Synchronized lyrics display
- ā Auto-hide UI system
- ā Progress tracking and seeking
- ā Volume control
- ā Fullscreen lyrics mode
- ā Responsive design
- š Queue management (coming soon)
- š Playlist support (coming soon)
- š Offline lyrics cache (coming soon)
#š§± Project Structure
src/
āāā components/ # React components
ā āāā Search/ # Search-related components
ā āāā Player/ # Audio player components
ā āāā Lyrics/ # Lyrics display components
ā āāā UI/ # General UI components
āāā hooks/ # Custom React hooks
āāā services/ # API service classes
āāā types/ # TypeScript type definitions
āāā utils/ # Utility functions
#š® Future Enhancements
- Queue Management: Add, remove, and reorder songs
- Playlist Support: Create and save custom playlists
- User Accounts: Save favorites and listening history
- Social Features: Share songs and playlists
- Offline Mode: Cache lyrics and basic functionality
- Keyboard Shortcuts: Full keyboard navigation
- Visualizer: Audio visualization during playback
#š¤ Contributing
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
#š License
This project is licensed under the MIT License - see the LICENSE file for details.
#š Acknowledgments
- APIs: YouTube Data API, Lyrics.ovh
- Icons: Lucide React
- Styling: Tailwind CSS
- Build Tool: Vite
Made with ā¤ļø by nerufuyo