Skip to content

Conversation

@esouthren
Copy link
Contributor

Revised re-land of #119819. Fixes #118150 and #118244.

Instead of hard-defaulting to no shadow in M3, we add a shadowColor property to bottomAppBar and bottomSheet, and their respective themes.

The M3 default is then set to Colors.transparent shadow, but can be overridden by users.

Updated M3 defaults:
Screenshot 2023-02-24 3 04 29 PM

Internal testing has been conducted and g3fix created (cl/512056372).

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement].
  • I signed the [CLA].
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is [test-exempt].
  • All existing and new tests are passing.

@flutter-dashboard flutter-dashboard bot added f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels. c: contributor-productivity Team-specific productivity, code health, technical debt. labels Feb 24, 2023
@esouthren esouthren marked this pull request as ready for review February 24, 2023 17:51
@esouthren esouthren requested a review from guidezpl February 27, 2023 13:37
Copy link
Contributor

@HansMuller HansMuller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Creating a shadowColor theme property is a good move. Just small small-stuff feedback.

@esouthren esouthren requested a review from HansMuller March 1, 2023 11:59
Copy link
Contributor

@HansMuller HansMuller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@esouthren esouthren merged commit d696b05 into flutter:master Mar 6, 2023
@esouthren esouthren deleted the bottom_sheet_shadow_property branch March 6, 2023 11:56
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 6, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 6, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 8, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 8, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 8, 2023
Color? get surfaceTintColor => Theme.of(context).colorScheme.surfaceTint;

@override
Color get shadowColor => Colors.transparent;
Copy link
Contributor

@QuncCccccc QuncCccccc Mar 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shadowColor should have same type Color? as the template. Fixing this in PR: #122548 #122557 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

c: contributor-productivity Team-specific productivity, code health, technical debt. f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BottomAppBar does not match M3 spec

4 participants