Skip to content

Flutter Theme Generator is a dynamic tool that simplifies Flutter app theming by generating complete, production-ready color schemes from your brand assets. Upload an image/logo or pick custom colors, and instantly export a tailored ThemeData configuration for seamless integration into your Flutter project. Perfect for designers and developers.

License

Notifications You must be signed in to change notification settings

mukhbit0/Flutter-Theme-Generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

52 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

✨ Flutter Theme Generator

Flutter Theme Generator

🎨 Create Beautiful Flutter Themes in Minutes, Not Hours

Live Demo License Last Commit GitHub Stars


Transform your Flutter app's appearance with our professional theme generator
Material 3 compliant β€’ Multiple contrast modes β€’ Logo color extraction β€’ Enhanced accessibility β€’ Real-time previews

πŸ“± Try Live Demo β€’ 🀝 Contribute β€’ πŸ’¬ Support β€’ πŸ“Š 150+ Themes Generated!


🌟 Why Flutter Theme Generator?

The Problem

Creating consistent, beautiful themes in Flutter is time-consuming and complex:

  • ⏰ Hours spent tweaking colors and styles
  • πŸ”„ Manual light/dark mode implementation
  • 🎨 Difficulty extracting brand colors from logos
  • πŸ‘€ No live preview of theme changes
  • πŸ“¦ Complex theme file structure setup
  • β™Ώ Accessibility compliance challenges
  • 🎯 Contrast mode variants missing

Our Solution

Flutter Theme Generator streamlines the entire process:

  • ⚑ Generate themes in under 5 minutes
  • πŸ€– Advanced color extraction with 95% accuracy
  • πŸ‘οΈ Real-time widget previews with 6 contrast modes
  • πŸ“± Material 3 & accessibility compliant (WCAG AAA)
  • 🎯 Production-ready code with ScreenUtil support
  • πŸ”¬ Industry-leading algorithms (K-Means, LAB, Oklab)
// What you get - ready to use!
ThemeData lightTheme = ThemeData(
  useMaterial3: true,
  colorScheme: ColorScheme.fromSeed(
    seedColor: Color(0xFF6750A4),
    brightness: Brightness.light,
  ),
  // + 50+ other properties configured
);

⬇️ From hours of work to minutes ⬇️

Time Saved


πŸš€ Key Features

🎨 Smart Color Extraction πŸ‘οΈ Live Preview ⚑ Material 3 Ready
Upload your logo and watch as we automatically extract your brand colors See your theme applied to real Flutter widgets instantly Full Material Design 3 compliance with seamless dark mode
Color Extraction Live Preview Material 3

πŸ”₯ Complete Feature Set

🎨 Advanced Color Engineering

  • 🧠 AI-Powered Logo Analysis: K-Means clustering extracts dominant brand colors with 95% accuracy
  • οΏ½ 6 Contrast Modes: Light, dark, and 4 accessibility variants (medium/high contrast)
  • πŸ”¬ Oklab Color Space: Industry-leading perceptual color accuracy for natural gradients
  • βš–οΈ APCA Accessibility: Next-generation contrast algorithms exceeding WCAG AAA standards
  • οΏ½ Color Harmony: Scientifically-generated complementary and analogous palettes

πŸ‘οΈ Real-Time Preview System

  • πŸ“± 20+ Widget Previews: See your theme on buttons, cards, forms, navigation, and more
  • πŸ”„ Instant Updates: Changes appear immediately across all preview components
  • πŸ“Š Contrast Validation: Live accessibility scoring with detailed WCAG compliance reports
  • οΏ½ Responsive Design: ScreenUtil integration for consistent sizing across devices
  • 🎭 Multi-Mode Testing: Switch between all 6 contrast modes in real-time

πŸ“¦ Production-Ready Export

  • ⬇️ Complete Theme Package: Structured ZIP with all theme files and documentation
  • οΏ½ ScreenUtil Support: Responsive design tokens that scale perfectly across devices
  • πŸ—οΈ Clean Architecture: Organized file structure following Flutter best practices
  • πŸ“– Implementation Guide: Step-by-step integration instructions with code examples
  • πŸ”§ Hot Reload Ready: Drop-in themes that work immediately with your existing project
  • πŸ”§ Easy Integration: Step-by-step integration guide included

πŸ› οΈ Built With Modern Tech

Frontend Build Tool Styling Deployment Language
React Vite Tailwind Cloudflare TypeScript

Why this stack?

  • ⚑ Lightning fast development with Vite hot reload
  • πŸ”’ Type safety with TypeScript for better code quality
  • 🎨 Rapid styling with Tailwind's utility-first approach
  • 🌍 Global deployment via Cloudflare's edge network
  • βš›οΈ Component architecture with React for maintainability

πŸ“Έ Visual Showcase

🏠 Homepage Experience

Clean, intuitive interface that gets you started in seconds

Homepage

🎨 Theme Generator Interface

Powerful customization tools with real-time preview

Theme Generator

πŸ‘οΈ Live Widget Preview

See your theme applied to real Flutter components

Theme Preview

πŸŒ™ Dark Mode Ready

Seamless dark mode experience

Dark Mode

πŸš€ Quick Start Guide

Get Your Custom Theme in 4 Simple Steps

1️⃣ Upload

Upload Icon

Drag & drop your logo or choose colors manually

2️⃣ Customize

Customize Icon

Fine-tune colors, typography, and components

3️⃣ Preview

Preview Icon

See your theme on real Flutter widgets

4️⃣ Export

Export Icon

Get production-ready theme files


πŸ’» Local Development

πŸ”§ Setup Instructions

Prerequisites

  • Node.js 18+ and npm
  • Git

Installation

# Clone the repository
git clone https://github.com/mukhbit0/Flutter-Theme-Generator.git
cd Flutter-Theme-Generator

# Install dependencies
npm install

# Start development server
npm run dev

Available Scripts

Command Description
npm run dev Start development server with hot reload
npm run build Build for production
npm run preview Preview production build locally
npm run lint Run ESLint for code quality
npm run type-check Run TypeScript type checking

πŸ”¬ Technical Excellence

Built with industry-leading algorithms and best practices

TypeScript React Material 3 WCAG AAA

🧬 Advanced Color Science

K-Means Clustering Algorithm

  • Intelligently analyzes uploaded logos to extract dominant brand colors
  • Groups similar pixels to identify the most representative color palette
  • 95% accuracy in brand color identification across diverse logo types

Oklab Perceptual Color Space

  • State-of-the-art perceptual uniformity for natural color transitions
  • Superior gradient generation compared to traditional RGB/HSL methods
  • Ensures color adjustments appear visually consistent to human perception

APCA (Advanced Perceptual Contrast Algorithm)

  • Next-generation accessibility standard exceeding WCAG AAA requirements
  • More accurate representation of real-world contrast perception
  • Optimized for modern displays and diverse visual capabilities

🎨 Material 3 Color System Implementation

Complete Theme Coverage

  • 6 Theme Variants: Light, Dark, Medium Contrast (Light/Dark), High Contrast (Light/Dark)
  • Full Color Palette: Primary, Secondary, Tertiary colors with all tonal variants
  • Surface Colors: Background, surface, outline colors optimized for each mode
  • Error Handling: Consistent error states across all theme variants

ScreenUtil Integration

  • Responsive Typography: All text sizes scale with screen density (.sp suffix)
  • Adaptive Dimensions: Width and height values respond to device size (.w/.h suffix)
  • Consistent Spacing: Padding and margins maintain proportions across devices
  • Production Ready: Zero configuration required for multi-device support

⚑ Performance Optimizations

Efficient Processing

  • Real-time color calculations using optimized algorithms
  • Lazy loading for preview components to maintain smooth interactions
  • Intelligent caching of generated theme data
  • Minimal bundle size with tree-shaking optimization

Quality Assurance

  • Automated contrast validation for all generated color combinations
  • Cross-platform compatibility testing for Flutter integration
  • Comprehensive accessibility compliance checking
  • Production-grade code generation with proper formatting

🌐 Deployment

☁️ Cloudflare Workers Deployment

Prerequisites

  • Cloudflare account
  • Wrangler CLI installed (npm install -g wrangler)

Deploy Steps

# Build the application
npm run build

# Deploy to Cloudflare Workers
npx wrangler deploy --env production

Environment Configuration

Create a wrangler.toml file:

name = "flutter-theme-generator"
main = "dist/index.js"
compatibility_date = "2023-05-18"

[env.production]
name = "flutter-theme-generator-prod"

🀝 Contributing

Help make Flutter Theme Generator even better!

Contributors PRs Welcome Good First Issues

We welcome contributions of all kinds! Whether you're fixing bugs, adding features, improving documentation, or sharing ideas.

Quick Contribution Options:

πŸ‘‰ Read our detailed Contributing Guide for step-by-step instructions.


πŸ“Š Project Stats

GitHub Stats

Repo Size Issues Pull Requests


οΏ½ Recent Enhancements (v2024.1)

Latest improvements make Flutter Theme Generator more powerful than ever

Updates Version

🎨 Enhanced Color Algorithms

  • Oklab Color Space: Added perceptually uniform color processing for more natural transitions
  • APCA Accessibility: Implemented next-generation contrast algorithms exceeding WCAG AAA
  • K-Means Clustering: Improved logo color extraction with 95% accuracy rate
  • Fixed Contrast Logic: Resolved theme polarity issues - light themes stay light, dark themes stay dark

πŸ“± Complete ScreenUtil Integration

  • Typography Support: All text sizes now scale with .sp suffix for perfect responsive design
  • Dimension Support: Width and height values adapt with .w and .h suffixes
  • Spacing System: Padding and margins maintain proportions across all devices
  • Zero Configuration: Drop-in support requiring no additional setup

🎯 Material 3 Enhancements

  • 6 Theme Variants: Complete light/dark/medium contrast/high contrast implementation
  • Enhanced Accessibility: All color combinations meet or exceed accessibility standards
  • Improved Preview: Real-time visualization of all theme variants
  • Professional Export: Production-ready Dart code with comprehensive documentation

⚑ User Experience Improvements

  • Theme Counter: Live tracking of globally generated themes (150+ and counting!)
  • Refined UI: Consistent badge styling and improved visual hierarchy
  • Enhanced Documentation: Comprehensive algorithm explanations and implementation guides
  • Performance Optimizations: Faster color processing and real-time previews

οΏ½πŸ’¬ Support & Community

Get Help & Connect

Discord Stack Overflow GitHub Discussions

Support Development

If this tool saves you time and helps your projects, consider supporting its development:

Buy Me A Coffee

Other ways to support:

  • ⭐ Star this repository
  • 🐦 Share on social media
  • πŸ“ Write a blog post about your experience
  • πŸŽ₯ Create a tutorial video

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

What this means:

  • βœ… Commercial use allowed
  • βœ… Modification allowed
  • βœ… Distribution allowed
  • βœ… Private use allowed
  • ❗ License and copyright notice required

πŸ‘¨β€πŸ’» About the Author

mukhbit0

Created with ❀️ by mukhbit0

Passionate Flutter developer dedicated to making app development more accessible

GitHub LinkedIn Twitter


⭐ If this project helped you, please consider giving it a star! ⭐

Made with πŸ’™ for the Flutter community

Footer

About

Flutter Theme Generator is a dynamic tool that simplifies Flutter app theming by generating complete, production-ready color schemes from your brand assets. Upload an image/logo or pick custom colors, and instantly export a tailored ThemeData configuration for seamless integration into your Flutter project. Perfect for designers and developers.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published