Skip to content

Commit

Permalink
Fix PR issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Pante committed Jun 6, 2024
1 parent 2f54f76 commit 4deb908
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 15 deletions.
28 changes: 14 additions & 14 deletions forui/lib/src/theme/theme_data.dart
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ class FThemeData with Diagnosticable {
/// The header styles.
final FHeaderStyle headerStyle;

/// The text field style.
final FTextFieldStyle textFieldStyle;

/// The box style.
final FBoxStyle boxStyle;

Expand All @@ -34,9 +37,6 @@ class FThemeData with Diagnosticable {
/// The switch style.
final FSwitchStyle switchStyle;

/// The text field style.
final FTextFieldStyle textFieldStyle;

/// Creates a [FThemeData].
FThemeData({
required this.colorScheme,
Expand All @@ -46,10 +46,10 @@ class FThemeData with Diagnosticable {
required this.buttonStyles,
required this.cardStyle,
required this.headerStyle,
required this.textFieldStyle,
required this.boxStyle,
required this.separatorStyles,
required this.switchStyle,
required this.textFieldStyle,
});

/// Creates a [FThemeData] that inherits the given properties.
Expand All @@ -65,10 +65,10 @@ class FThemeData with Diagnosticable {
),
cardStyle = FCardStyle.inherit(colorScheme: colorScheme, font: font, style: style),
headerStyle = FHeaderStyle.inherit(colorScheme: colorScheme, font: font),
textFieldStyle = FTextFieldStyle.inherit(colorScheme: colorScheme, font: font, style: style),
boxStyle = FBoxStyle.inherit(colorScheme: colorScheme),
separatorStyles = FSeparatorStyles.inherit(colorScheme: colorScheme, style: style),
switchStyle = FSwitchStyle.inherit(colorScheme: colorScheme),
textFieldStyle = FTextFieldStyle.inherit(colorScheme: colorScheme, font: font, style: style);
switchStyle = FSwitchStyle.inherit(colorScheme: colorScheme);

/// Creates a copy of this [FThemeData] with the given properties replaced.
FThemeData copyWith({
Expand All @@ -79,10 +79,10 @@ class FThemeData with Diagnosticable {
FButtonStyles? buttonStyles,
FCardStyle? cardStyle,
FHeaderStyle? headerStyle,
FTextFieldStyle? textFieldStyle,
FBoxStyle? boxStyle,
FSeparatorStyles? separatorStyles,
FSwitchStyle? switchStyle,
FTextFieldStyle? textFieldStyle,
}) =>
FThemeData(
colorScheme: colorScheme ?? this.colorScheme,
Expand All @@ -92,10 +92,10 @@ class FThemeData with Diagnosticable {
buttonStyles: buttonStyles ?? this.buttonStyles,
cardStyle: cardStyle ?? this.cardStyle,
headerStyle: headerStyle ?? this.headerStyle,
textFieldStyle: textFieldStyle ?? this.textFieldStyle,
boxStyle: boxStyle ?? this.boxStyle,
separatorStyles: separatorStyles ?? this.separatorStyles,
switchStyle: switchStyle ?? this.switchStyle,
textFieldStyle: textFieldStyle ?? this.textFieldStyle,
);

@override
Expand All @@ -109,10 +109,10 @@ class FThemeData with Diagnosticable {
..add(DiagnosticsProperty('buttonStyles', buttonStyles, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('cardStyle', cardStyle, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('headerStyle', headerStyle, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('textFieldStyle', textFieldStyle, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('boxStyle', boxStyle, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('separatorStyles', separatorStyles, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('switchStyle', switchStyle, level: DiagnosticLevel.debug))
..add(DiagnosticsProperty('textFieldStyle', textFieldStyle, level: DiagnosticLevel.debug));
..add(DiagnosticsProperty('switchStyle', switchStyle, level: DiagnosticLevel.debug));
}

@override
Expand All @@ -127,10 +127,10 @@ class FThemeData with Diagnosticable {
buttonStyles == other.buttonStyles &&
cardStyle == other.cardStyle &&
headerStyle == other.headerStyle &&
textFieldStyle == other.textFieldStyle &&
boxStyle == other.boxStyle &&
separatorStyles == other.separatorStyles &&
switchStyle == other.switchStyle &&
textFieldStyle == other.textFieldStyle;
switchStyle == other.switchStyle;

@override
int get hashCode =>
Expand All @@ -141,8 +141,8 @@ class FThemeData with Diagnosticable {
buttonStyles.hashCode ^
cardStyle.hashCode ^
headerStyle.hashCode ^
textFieldStyle.hashCode ^
boxStyle.hashCode ^
separatorStyles.hashCode ^
switchStyle.hashCode ^
textFieldStyle.hashCode;
switchStyle.hashCode;
}
2 changes: 1 addition & 1 deletion forui/test/src/widgets/text_field/flutter_test_config.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ const _kGoldenTestsThreshold = 4 / 100;
Future<void> testExecutable(FutureOr<void> Function() testMain) async {
await configureGoldenTests(_kGoldenTestsThreshold);
await testMain();
}
}

0 comments on commit 4deb908

Please sign in to comment.