BsThemeData class

Bootstrap 5.3 Theme Extension for Flutter.

All color values reference BsColors palettes — no hardcoded hex values except where Bootstrap itself specifies fixed values (e.g., rgba transparencies and bodyBg white/black).

Inheritance

Constructors

BsThemeData({required Color primary, required Color secondary, required Color success, required Color danger, required Color warning, required Color info, required Color light, required Color dark, required Color bodyText, required Color bodyTextSecondary, required Color bodyTextTertiary, required Color emphasisColor, required Color bodyBg, required Color bodyBgSecondary, required Color bodyBgTertiary, required Color border, required Color borderTranslucent, required Color linkColor, required Color linkHoverColor, required Color primaryTextEmphasis, required Color secondaryTextEmphasis, required Color successTextEmphasis, required Color dangerTextEmphasis, required Color warningTextEmphasis, required Color infoTextEmphasis, required Color lightTextEmphasis, required Color darkTextEmphasis, required Color primaryBgSubtle, required Color secondaryBgSubtle, required Color successBgSubtle, required Color dangerBgSubtle, required Color warningBgSubtle, required Color infoBgSubtle, required Color lightBgSubtle, required Color darkBgSubtle, required Color primaryBorderSubtle, required Color secondaryBorderSubtle, required Color successBorderSubtle, required Color dangerBorderSubtle, required Color warningBorderSubtle, required Color infoBorderSubtle, required Color lightBorderSubtle, required Color darkBorderSubtle, required Color onDark, required Color onLight})
Creates a BsThemeData instance with the given Bootstrap-specific colors.
const

Properties

bodyBg Color
The main background color of the body.
final
bodyBgSecondary Color
final
bodyBgTertiary Color
final
bodyText Color
final
bodyTextSecondary Color
final
bodyTextTertiary Color
final
border Color
final
borderTranslucent Color
final
danger Color
final
dangerBgSubtle Color
final
dangerBorderSubtle Color
final
dangerTextEmphasis Color
final
dark Color
final
darkBgSubtle Color
final
darkBorderSubtle Color
final
darkTextEmphasis Color
final
emphasisColor Color
final
hashCode int
The hash code for this object.
no setterinherited
info Color
final
infoBgSubtle Color
final
infoBorderSubtle Color
final
infoTextEmphasis Color
final
light Color
final
lightBgSubtle Color
final
lightBorderSubtle Color
final
lightTextEmphasis Color
final
linkColor Color
final
linkHoverColor Color
final
onDark Color
final
onLight Color
final
primary Color
final
primaryBgSubtle Color
final
primaryBorderSubtle Color
final
primaryTextEmphasis Color
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
secondary Color
final
secondaryBgSubtle Color
final
secondaryBorderSubtle Color
final
secondaryTextEmphasis Color
final
success Color
final
successBgSubtle Color
final
successBorderSubtle Color
final
successTextEmphasis Color
final
type Object
The extension's type.
no setterinherited
warning Color
final
warningBgSubtle Color
final
warningBorderSubtle Color
final
warningTextEmphasis Color
final

Methods

copyWith({Color? primary, Color? secondary, Color? success, Color? danger, Color? warning, Color? info, Color? light, Color? dark, Color? onDark, Color? onLight, Color? bodyText, Color? bodyTextSecondary, Color? bodyTextTertiary, Color? emphasisColor, Color? bodyBg, Color? bodyBgSecondary, Color? bodyBgTertiary, Color? border, Color? borderTranslucent, Color? linkColor, Color? linkHoverColor, Color? primaryTextEmphasis, Color? secondaryTextEmphasis, Color? successTextEmphasis, Color? dangerTextEmphasis, Color? warningTextEmphasis, Color? infoTextEmphasis, Color? lightTextEmphasis, Color? darkTextEmphasis, Color? primaryBgSubtle, Color? secondaryBgSubtle, Color? successBgSubtle, Color? dangerBgSubtle, Color? warningBgSubtle, Color? infoBgSubtle, Color? lightBgSubtle, Color? darkBgSubtle, Color? primaryBorderSubtle, Color? secondaryBorderSubtle, Color? successBorderSubtle, Color? dangerBorderSubtle, Color? warningBorderSubtle, Color? infoBorderSubtle, Color? lightBorderSubtle, Color? darkBorderSubtle}) BsThemeData
Creates a copy of this theme extension with the given fields replaced by the non-null parameter values.
override
lerp(covariant ThemeExtension<BsThemeData>? other, double t) BsThemeData
Linearly interpolate with another ThemeExtension object.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

darkTheme BsThemeData
final
lightTheme BsThemeData
final