Skip to content

Commit

Permalink
fix: Top app bar padding (#215)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikecoomber authored Nov 20, 2024
1 parent fd9aada commit 7b374b7
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 17 deletions.
37 changes: 20 additions & 17 deletions lib/src/components/top_app_bar/top_app_bar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -329,23 +329,26 @@ class _ZetaTopAppBarState extends State<ZetaTopAppBar> {

return ZetaRoundedScope(
rounded: context.rounded,
child: Padding(
padding: EdgeInsets.symmetric(horizontal: spacing.minimum),
child: AppBar(
elevation: 0,
scrolledUnderElevation: 0,
backgroundColor: colors.surfacePrimary,
iconTheme: IconThemeData(color: colors.iconDefault),
leading: leading,
toolbarHeight: spacing.xl_9,
automaticallyImplyLeading: widget.automaticallyImplyLeading,
surfaceTintColor: Colors.transparent,
centerTitle: widget.type == ZetaTopAppBarType.centered,
titleTextStyle: widget.titleTextStyle == null
? ZetaTextStyles.bodyLarge.copyWith(color: colors.textDefault)
: widget.titleTextStyle!.copyWith(color: colors.textDefault),
title: title,
actions: actions,
child: ColoredBox(
color: colors.surfaceDefault,
child: Padding(
padding: EdgeInsets.symmetric(horizontal: spacing.minimum),
child: AppBar(
elevation: 0,
scrolledUnderElevation: 0,
backgroundColor: colors.surfacePrimary,
iconTheme: IconThemeData(color: colors.iconDefault),
leading: leading,
toolbarHeight: spacing.xl_9,
automaticallyImplyLeading: widget.automaticallyImplyLeading,
surfaceTintColor: Colors.transparent,
centerTitle: widget.type == ZetaTopAppBarType.centered,
titleTextStyle: widget.titleTextStyle == null
? ZetaTextStyles.bodyLarge.copyWith(color: colors.textDefault)
: widget.titleTextStyle!.copyWith(color: colors.textDefault),
title: title,
actions: actions,
),
),
),
);
Expand Down
Binary file modified test/src/components/top_app_bar/golden/top_app_bar_centered.png
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 test/src/components/top_app_bar/golden/top_app_bar_default.png
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 test/src/components/top_app_bar/golden/top_app_bar_search.png
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.

0 comments on commit 7b374b7

Please sign in to comment.