A modern web application and Chrome extension that leverages Chrome 138+'s built-in AI APIs for translation, language detection, and text summarization. Built with React, TypeScript and Tailwind CSS.
- Full-featured web interface
- Optimized for desktop browsers
- Complete visual effects and animations
- Compact popup interface (400x600px)
- Quick access from Chrome toolbar
- Optimized for extension environment
- All core features available
- Web Store
- Real-time translation between multiple languages
- Intuitive interface with source and target language selection
- Powered by Chrome's Translator API
- Support for 15+ languages including English, Spanish, French, German, Italian, Portuguese, Russian, Chinese, Japanese, Korean, and more
- Automatic detection of any text's language
- Confidence levels for enhanced accuracy
- Utilizes Chrome's Language Detector API
- Instant results with percentage confidence scores
- Generate concise summaries of long texts
- Multiple summary types: TL;DR, key points, teaser, headline
- Customizable summary length and format
- Based on Chrome's Summarizer API
- Smooth animations with Motion (Framer Motion)
- Animated grid patterns in background
- Blur fade entrance animations
- HyperText animated title
- Progress indicators with smooth transitions
- Responsive design with dark/light theme support
- React 18 - Modern UI framework with hooks
- TypeScript - Static typing for enhanced development
- Tailwind CSS - Utility-first CSS framework
- Motion (Framer Motion) - Production-ready motion library
- Magic UI - Specialized components with advanced effects
- Shadcn/ui - High-quality UI component library
- Sonner - Toast notifications
- Vite - Fast build tool and development server
- Chrome AI APIs - Built-in browser AI capabilities
This application requires Chrome 138+ with specific experimental features enabled:
-
Download Chrome Canary/Dev:
- Chrome Canary: https://www.google.com/chrome/canary/
- Chrome Dev: https://www.google.com/chrome/dev/
-
Enable Chrome Flags: Navigate to
chrome://flags
and enable the following flags:#optimization-guide-on-device-model - Enabled #prompt-api-for-gemini-nano - Enabled #summarization-api-for-gemini-nano - Enabled #translation-api - Enabled #language-detection-api - Enabled
-
Configure Gemini Nano:
- Go to
chrome://components
- Find "Optimization Guide On Device Model"
- Click "Check for update"
- Restart Chrome after update completes
- Go to
-
Verify APIs:
- Open DevTools (F12)
- In Console, verify:
console.log(window.Translator); console.log(window.LanguageDetector); console.log(window.Summarizer);
- All should return objects (not undefined)
-
Clone the repository:
git clone <repository-url> cd chromeAI
-
Install dependencies:
npm install
-
Start development server:
npm run dev
-
Open in browser:
- Navigate to
http://localhost:5173
- Ensure you're using Chrome 138+ with enabled flags
- Navigate to
-
Build the extension:
npm install npm run build:extension
-
Load in Chrome:
- Open
chrome://extensions/
- Enable "Developer mode"
- Click "Load unpacked"
- Select the
dist
folder - Pin the extension for easy access
- Open
π Detailed Extension Guide: See EXTENSION_GUIDE.md for complete installation instructions.
- Select source and target languages from the dropdown
- Enter text in the translation textarea
- Click "Translate" button
- View real-time translation results
- Toast notifications confirm successful operations
- Enter any text in the analysis textarea
- Click "Detect Language" button
- Get detected language with confidence percentage
- Results show language code and accuracy level
- Select desired summary type (TL;DR, Key Points, Teaser, Headline)
- Enter long text content
- Click "Generate Summary" button
- Receive concise, formatted summary
- Animated Grid Pattern: Dynamic background grid with opacity transitions
- Blur Fade: Smooth element entrance animations
- Motion Transitions: Scale, rotate, and position animations
- HyperText: Character-by-character text animation
- Progress Indicators: Real-time operation feedback
- Magic UI Integration: Advanced visual effects and interactions
- Responsive Tabs: Clean organization of different AI features
- Custom Language Selector: Searchable combobox with flag icons
- Card Components: Elevated containers with hover effects
- Toast Notifications: User feedback for all operations
src/
βββ components/
β βββ ui/
β β βββ blur-fade.tsx # Entrance animation effect
β β βββ button.tsx # Custom button component
β β βββ card.tsx # Card container component
β β βββ input.tsx # Input form component
β β βββ label.tsx # Form label component
β β βββ progress.tsx # Progress bar component
β β βββ select.tsx # Select dropdown component
β β βββ tabs.tsx # Tab navigation component
β β βββ textarea.tsx # Text area component
β β βββ sonner.tsx # Toast notification component
β βββ magicui/
β β βββ animated-grid-pattern.tsx # Animated background pattern
β β βββ hyper-text.tsx # Animated text component
β βββ Languague.tsx # Language selection combobox
βββ lib/
β βββ utils.ts # Utility functions
βββ App.tsx # Main application component
βββ main.tsx # Application entry point
βββ index.css # Global styles and CSS variables
- Chrome 138+ (Required) - Full feature support
- Chrome Canary/Dev - Recommended for latest features
- Other Browsers - Not supported (APIs unavailable)
The application automatically checks for API availability and provides user feedback:
- Green status: All APIs available and ready
- Yellow status: Some APIs may be loading
- Red status: APIs unavailable (check Chrome version and flags)
-
APIs not available:
- Verify Chrome version (138+ required)
- Check all flags are enabled in
chrome://flags
- Restart Chrome after enabling flags
-
Gemini Nano not working:
- Update components in
chrome://components
- Wait for model download to complete
- Check internet connection for initial download
- Update components in
-
Translations failing:
- Some language pairs may not be supported
- Check console for specific error messages
- Try different language combinations
npm run dev
- Start development servernpm run build
- Build for productionnpm run preview
- Preview production buildnpm run lint
- Run ESLint
- Fork the repository
- Create a feature branch
- Make your changes
- Test with Chrome 138+
- Submit a pull request
- Batch translation support
- Custom language model fine-tuning
- Export functionality for results
- Voice input/output integration
Note: This application uses experimental Chrome APIs that are under active development. Features may change or become unavailable in different configurations. Always use the latest Chrome Canary or Dev build for the best experience.
Disclaimer: Chrome AI APIs are experimental and may not be available in all regions or Chrome configurations. This project is for demonstration and educational purposes.