super_core 2.1.0 copy "super_core: ^2.1.0" to clipboard
super_core: ^2.1.0 copied to clipboard

Super Core — GeniusLink’s shared design-system foundation for the Super toolkit: super_auto_suggestion_box, super_form_field, super_map, super_table_field, super_tree, and super_tab_bar. Defines the v [...]

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:super_core/super_core.dart';

import 'theme_demo_screen.dart';

void main() => runApp(const SuperCoreExampleApp());

/// Root widget that owns [SuperPalette] + [ThemeMode] state and wires
/// [SuperMaterialThemeData] into the [MaterialApp].
///
/// Demonstrates:
/// - [SuperMaterialThemeData.light] and [SuperMaterialThemeData.dark]
/// - Runtime palette switching via [SuperPalette.values]
/// - Light / Dark / System [ThemeMode] toggle
class SuperCoreExampleApp extends StatefulWidget {
  const SuperCoreExampleApp({super.key});

  @override
  State<SuperCoreExampleApp> createState() => _SuperCoreExampleAppState();
}

class _SuperCoreExampleAppState extends State<SuperCoreExampleApp> {
  SuperPalette _palette = SuperPalette.bluePalette;
  ThemeMode _themeMode = ThemeMode.system;

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Super Core — Theme Demo',
      debugShowCheckedModeBanner: false,
      themeMode: _themeMode,
      // SuperMaterialThemeData generates complete Material 3 ThemeData and
      // registers SuperThemeData as a ThemeExtension automatically.
      theme: SuperMaterialThemeData.light(palette: _palette),
      darkTheme: SuperMaterialThemeData.dark(palette: _palette),
      home: ThemeDemoScreen(
        selectedPalette: _palette,
        themeMode: _themeMode,
        onPaletteChanged: (p) => setState(() => _palette = p),
        onThemeModeChanged: (m) => setState(() => _themeMode = m),
      ),
    );
  }
}
0
likes
140
points
597
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

Super Core — GeniusLink’s shared design-system foundation for the Super toolkit: super_auto_suggestion_box, super_form_field, super_map, super_table_field, super_tree, and super_tab_bar. Defines the visual source: six swappable SuperPalette schemes, Material 3 SuperMaterialThemeData, brand/semantic colors, three-face typography, 4px spacing, control/field sizes, radii, motion, light/dark SuperThemeData, intl-free formatters, and core widgets. Supports light/dark and LTR/RTL.

Homepage
Repository (GitHub)
View/report issues

Topics

#flutter #widget #design-system #theme #tokens

License

MIT (license)

Dependencies

flutter

More

Packages that depend on super_core