Skip to content

Commit

Permalink
Update golden tests
Browse files Browse the repository at this point in the history
  • Loading branch information
kawaijoe committed Jun 23, 2024
1 parent be16d9e commit b0634ad
Show file tree
Hide file tree
Showing 99 changed files with 15 additions and 12 deletions.
6 changes: 4 additions & 2 deletions forui/lib/src/widgets/button/button_content.dart
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,14 @@ class FButtonContentStyle with Diagnosticable {
vertical: 12.5,
),
enabledTextStyle = typography.base.copyWith(
fontWeight: FontWeight.w500,
color: enabled,
fontWeight: FontWeight.w500,
height: 1,
),
disabledTextStyle = typography.base.copyWith(
fontWeight: FontWeight.w500,
color: disabled,
fontWeight: FontWeight.w500,
height: 1,
);

/// Returns a copy of this [FButtonContentStyle] with the given properties replaced.
Expand Down
2 changes: 1 addition & 1 deletion forui/lib/src/widgets/dialog/dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ class FDialog extends StatelessWidget {
removeBottom: true,
context: context,
child: Align(
child: DefaultTextStyle(
child: DefaultTextStyle.merge(
style: typography.base.copyWith(color: theme.colorScheme.foreground),
child: Semantics(
scopesRoute: true,
Expand Down
19 changes: 10 additions & 9 deletions forui/lib/src/widgets/header/header.dart
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,11 @@ class FHeader extends StatelessWidget {
this.rawTitle,
this.actions = const [],
super.key,
}):
assert((title != null) ^ (rawTitle != null), 'title or rawTitle must be provided, but not both.');
}) : assert((title != null) ^ (rawTitle != null), 'title or rawTitle must be provided, but not both.');

@override
Widget build(BuildContext context) {
final style = this.style ?? context.theme.headerStyle;
final typography = context.theme.typography;

final title = switch ((this.title, rawTitle)) {
(final String title, _) => Text(title),
Expand Down Expand Up @@ -106,8 +104,9 @@ final class FHeaderStyle with Diagnosticable {
/// Creates a [FHeaderStyle] that inherits its properties from the given [FColorScheme] and [FTypography].
FHeaderStyle.inherit({required FColorScheme colorScheme, required FTypography typography})
: titleTextStyle = typography.xl3.copyWith(
fontWeight: FontWeight.w700,
color: colorScheme.foreground,
fontWeight: FontWeight.w700,
height: 1,
),
action = FHeaderActionStyle.inherit(colorScheme: colorScheme);

Expand All @@ -126,13 +125,15 @@ final class FHeaderStyle with Diagnosticable {
/// print(style.titleTextStyle == copy.titleTextStyle); // true
/// print(style.action == copy.action); // false
/// ```
@useResult FHeaderStyle copyWith({
@useResult
FHeaderStyle copyWith({
TextStyle? titleTextStyle,
FHeaderActionStyle? action,
}) => FHeaderStyle(
titleTextStyle: titleTextStyle ?? this.titleTextStyle,
action: action ?? this.action,
);
}) =>
FHeaderStyle(
titleTextStyle: titleTextStyle ?? this.titleTextStyle,
action: action ?? this.action,
);

@override
void debugFillProperties(DiagnosticPropertiesBuilder properties) {
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified forui/test/golden/card/zinc-dark-raw-card-content.png
Binary file modified forui/test/golden/card/zinc-dark-text-card-content.png
Binary file modified forui/test/golden/card/zinc-light-raw-card-content.png
Binary file modified forui/test/golden/card/zinc-light-text-card-content.png
Binary file modified forui/test/golden/header/zinc-dark-header.png
Binary file modified forui/test/golden/header/zinc-dark-raw-title.png
Binary file modified forui/test/golden/header/zinc-light-header.png
Binary file modified forui/test/golden/header/zinc-light-raw-title.png
Binary file modified forui/test/golden/text_field/default-zinc-dark-focused-no-text.png
Binary file modified forui/test/golden/text_field/default-zinc-dark-focused-text.png
Binary file modified forui/test/golden/text_field/default-zinc-dark-unfocused-no-text.png
Binary file modified forui/test/golden/text_field/default-zinc-light-focused-text.png
Binary file modified forui/test/golden/text_field/email-zinc-dark-focused-no-text.png
Binary file modified forui/test/golden/text_field/email-zinc-dark-focused-text.png
Binary file modified forui/test/golden/text_field/email-zinc-dark-unfocused-text.png
Binary file modified forui/test/golden/text_field/email-zinc-light-focused-text.png
Binary file modified forui/test/golden/text_field/email-zinc-light-unfocused-text.png
Binary file modified forui/test/golden/text_field/error-zinc-dark-focused-no-text.png
Binary file modified forui/test/golden/text_field/error-zinc-dark-focused-text.png
Binary file modified forui/test/golden/text_field/error-zinc-dark-unfocused-no-text.png
Binary file modified forui/test/golden/text_field/error-zinc-dark-unfocused-text.png
Binary file modified forui/test/golden/text_field/error-zinc-light-focused-text.png
Binary file modified forui/test/golden/text_field/error-zinc-light-unfocused-text.png
Binary file modified forui/test/golden/text_field/password-zinc-dark-focused-no-text.png
Binary file modified forui/test/golden/text_field/password-zinc-dark-focused-text.png
Binary file modified forui/test/golden/text_field/password-zinc-dark-unfocused-text.png
Binary file modified forui/test/golden/text_field/password-zinc-light-focused-text.png
Binary file modified forui/test/golden/text_field/password-zinc-light-unfocused-text.png

0 comments on commit b0634ad

Please sign in to comment.