Theme constructor

const Theme({
  1. required Color primary,
  2. required Color secondary,
  3. required Color surface,
  4. required Color background,
  5. required Color error,
  6. required Color success,
  7. required Color warning,
  8. required Color onPrimary,
  9. required Color onSecondary,
  10. required Color onSurface,
  11. required Color onBackground,
  12. required Color onError,
  13. required Color muted,
  14. required Color border,
  15. Color? surfaceVariant,
  16. Color? onSurfaceVariant,
  17. Color? outline,
  18. Color? info,
  19. Color? onSuccess,
  20. Color? onWarning,
  21. Color? onInfo,
  22. Color? highlight,
  23. Color? onHighlight,
  24. Color? shadow,
  25. required Style titleLarge,
  26. required Style titleMedium,
  27. required Style titleSmall,
  28. required Style bodyLarge,
  29. required Style bodyMedium,
  30. required Style bodySmall,
  31. required Style labelLarge,
  32. required Style labelMedium,
  33. required Style labelSmall,
  34. StatusBarThemeData? statusBarTheme,
  35. AccentPanelThemeData? accentPanelTheme,
  36. CommandPaletteThemeData? commandPaletteTheme,
  37. DialogThemeData? dialogTheme,
  38. GitDiffThemeData? gitDiffTheme,
})

Implementation

const Theme({
  // Core semantic colors (required)
  required this.primary,
  required this.secondary,
  required this.surface,
  required this.background,
  required this.error,
  required this.success,
  required this.warning,
  required this.onPrimary,
  required this.onSecondary,
  required this.onSurface,
  required this.onBackground,
  required this.onError,
  required this.muted,
  required this.border,
  // Extended semantic colors (optional)
  this.surfaceVariant,
  this.onSurfaceVariant,
  this.outline,
  this.info,
  this.onSuccess,
  this.onWarning,
  this.onInfo,
  this.highlight,
  this.onHighlight,
  this.shadow,
  // Text styles (required)
  required this.titleLarge,
  required this.titleMedium,
  required this.titleSmall,
  required this.bodyLarge,
  required this.bodyMedium,
  required this.bodySmall,
  required this.labelLarge,
  required this.labelMedium,
  required this.labelSmall,
  // Component themes (optional)
  this.statusBarTheme,
  this.accentPanelTheme,
  this.commandPaletteTheme,
  this.dialogTheme,
  this.gitDiffTheme,
});