Skip to content

pabloparejo/costream-override

Repository files navigation

Costream Override

A Chrome extension that allows League of Legends esports fans to watch their favorite co-streamer on lolesports.com while earning official rewards and drops.

Features

  • Configure Preferred Co-Streamer: Set your favorite Twitch streamer through an easy-to-use popup interface
  • Automatic Iframe Override: Replaces Twitch video and chat embeds on lolesports.com with your configured co-streamer's content without losing native styling
  • Auto-Redirect (Optional): Automatically redirect from your co-streamer's Twitch channel to lolesports.com to maximize rewards
  • Session Reminders: Gentle “Visit lolesports” reminder with a one-click “Don’t show again” toggle, plus a master switch to pause the entire extension
  • Bilingual UI (EN/ES): Popup and notifications auto-localize to English or Spanish based on the browser language
  • Beautiful and clean UI: Clean interface with purple branding, success/error feedback, and contextual helper text

Installation

Load as Unpacked Extension (Development)

  1. Clone this repository
  2. Open Chrome and navigate to chrome://extensions
  3. Enable "Developer mode" (toggle in top-right corner)
  4. Click "Load unpacked"
  5. Select the /extension directory from this repository
  6. The extension icon should appear in your Chrome toolbar

Usage

Configure Your Co-Streamer

  1. Click the extension icon in your Chrome toolbar
  2. Enter your preferred Twitch streamer's username (or paste their Twitch URL)
  3. Optionally enable "Auto-redirect to lolesports" toggle
  4. Click "Save Settings"

Watch on Lolesports

  1. Visit lolesports.com/live during an active match
  2. The Twitch video and chat will automatically show your configured co-streamer
  3. You'll see a notification with a "Revert to Official Stream" button if you want to switch back

Auto-Redirect Feature

When enabled:

  • Visiting your co-streamer's Twitch channel automatically redirects you to lolesports.com
  • This ensures you earn rewards and drops while watching your favorite streamer

When disabled:

  • A reminder notification appears once per session
  • Includes a "Don't show again" option for permanent dismissal

Technical Details

Architecture

  • Manifest V3: Latest Chrome extension standard
  • ES2020+ JavaScript: Modern, modular code
  • No External Dependencies: Pure vanilla JavaScript
  • Chrome Storage Sync: Cross-device preference synchronization

Project Structure

extension/
├── manifest.json           # Extension configuration
├── popup/
│   ├── popup.html         # Configuration UI
│   ├── popup.css          # Twitch-inspired styling
│   └── popup.js           # Popup logic
├── content/
│   ├── lolesports.js      # Iframe override script
│   └── twitch.js          # Auto-redirect script
├── lib/
│   ├── storage.js         # Storage abstraction
│   ├── validator.js       # Username validation
│   ├── notification.js    # Notification UI library
│   └── i18n.js            # Lightweight localization helper
└── icons/
    └── ...                # Extension icons

Permissions

This extension only requests minimal permissions:

  • storage: Save your preferred streamer username and settings
  • tabs: Enable auto-redirect functionality
  • host_permissions:
    • twitch.tv/*: Detect when you're viewing your co-streamer's channel
    • lolesports.com/*: Replace Twitch iframes with your co-streamer's content

Privacy

  • No Data Collection: This extension does not collect, transmit, or store any personal data beyond your local browser
  • No External Servers: All functionality runs locally in your browser
  • Open Source: Review the code yourself in this repository

Development

Manual Testing

See tests/manual/test-procedures.md for the complete test suite (27 test scenarios).

Specification

See specs/001-costream-override/ for detailed feature specifications, design guidelines, and technical documentation.

Browser Compatibility

  • Chrome 88+ (Manifest V3 support)
  • Chromium-based browsers (Edge, Brave, etc.) with Manifest V3 support

License

MIT License - See LICENSE file for details

Disclaimer

This is an unofficial fan project and is not affiliated with, endorsed by, or connected to Riot Games, Twitch, or lolesports.com.

Contributing

Contributions are welcome! Please read the constitution for development principles and guidelines.

Support

For issues, questions, or feature requests, please open an issue on GitHub.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published