b29732a6535794fa4a68fb557eca045f33507b9b
Add a ThemeContext and provider, wrap the app with ThemeProvider, and sync user settings' theme into the context. Replace hardcoded color classes with design token classes (background, muted, foreground, border, card, etc.) across multiple UI components to centralize theming and enable consistent light/dark styling. Files updated include App.tsx (useTheme, setTheme, ThemeProvider, footer/background tokens), several views and components (AddMediaView, BrowseView, CastDetailView, CastView, MediaCard, MediaListItem, SettingsView, ImporterView) to use tokenized classes, and add new src/contexts/ThemeContext.tsx.
Kyoo - Media Discovery Platform
A modern web application for browsing, managing, and discovering media across multiple categories. Kyoo provides a unified interface for your media library with support for importing from external sources like Playnite, StashAPP, and XBVR.
Features
- Multi-Category Media Management: Browse and organize Anime, Movies, TV Series, Music, Books, Consoles, Games, and Adult content
- Detailed Media Views: Rich information display including descriptions, genres, studios, cast, and ratings
- Cast & Staff Directory: Explore actors, directors, and other staff across your media library
- Search & Filter: Quickly find media by title, year, genre, or studio
- Custom Media: Add your own media entries manually
- External Importers: Import libraries from popular media managers:
- Playnite: Import your game library with playtime, achievements, and metadata
- StashAPP: Import adult content with scene and performer details
- XBVR: Import VR content with scene information
- Category Toggles: Enable/disable categories to customize your view
- Responsive Design: Beautiful UI built with Tailwind CSS and shadcn/ui components
Tech Stack
- Frontend Framework: React 19 with TypeScript
- Build Tool: Vite 6
- Styling: Tailwind CSS 4
- UI Components: shadcn/ui, Base UI
- Icons: Lucide React
- Animations: Motion (Framer Motion)
- Fonts: Geist Variable Font
Prerequisites
- Node.js (v18 or higher)
- npm or yarn
- Backend API server (configured via environment variables)
Installation
- Clone the repository:
git clone <repository-url>
cd frontend
- Install dependencies:
npm install
- Configure environment variables:
cp .env.example .env
Edit .env and configure your settings (see Configuration below).
- Start the development server:
npm run dev
The app will be available at http://localhost:3000
Configuration
Create a .env file based on .env.example:
# App URL (auto-injected by AI Studio in production)
APP_URL="http://localhost:3000"
# XBVR Importer
VITE_XBVR_URL="http://localhost:9999"
# StashAPP Importer
VITE_STASHAPP_URL="http://localhost:9999"
VITE_STASHAPP_API_KEY="your-api-key"
# Playnite Importer
VITE_PLAYNITE_IP="localhost"
VITE_PLAYNITE_PORT="19821"
VITE_PLAYNITE_API_TOKEN="your-api-token"
Importer Configuration
Playnite
- Install the Playnite Bridge extension in Playnite
- Enable the HTTP API server in Playnite settings
- Generate an API token in the Playnite Bridge settings
- Configure the IP, port, and token in your
.envfile - See playnite_skill.md for detailed API documentation
StashAPP
- Ensure StashAPP is running and accessible
- Generate an API key in StashAPP settings
- Configure the URL and API key in your
.envfile
XBVR
- Ensure XBVR is running and accessible
- Configure the URL in your
.envfile
Usage
Browsing Media
- Navigate between categories using the header navigation
- Toggle categories on/off using the category buttons
- Search for media using the search bar
- Click on any media item to view detailed information
Managing Media
- Add Media: Click the "+" button to add custom media entries
- Import: Use the import feature to bring in libraries from Playnite, StashAPP, or XBVR
- View Cast: Browse the cast directory to see all staff across your library
Importing from External Sources
- Click the import button in the header
- Select the importer you want to use
- Follow the on-screen instructions to configure and run the import
- Progress will be displayed in real-time
Available Scripts
npm run dev- Start development servernpm run build- Build for productionnpm run preview- Preview production buildnpm run lint- Run TypeScript type checkingnpm run clean- Remove build artifacts
Project Structure
src/
├── components/ # React components
│ ├── ui/ # shadcn/ui components
│ ├── AddMediaView.tsx
│ ├── BrowseView.tsx
│ ├── CastDetailView.tsx
│ ├── CastView.tsx
│ ├── DetailView.tsx
│ └── ImporterView.tsx
├── lib/ # Utility functions
│ ├── playniteImporter.ts
│ ├── stashappImporter.ts
│ └── utils.ts
├── App.tsx # Main application component
├── api.ts # API client functions
├── data.ts # Mock data
└── types.ts # TypeScript type definitions
API Documentation
For detailed API documentation, see api.md.
License
SPDX-License-Identifier: Apache-2.0
Support
For issues, questions, or contributions, please refer to the project repository.
Description
Languages
TypeScript
98.4%
CSS
1.5%