Skip to content

Set modal bottom sheet barrier color#45067

Merged
darrenaustin merged 2 commits intoflutter:masterfrom
katallaxie:modal_barrier_color
Dec 10, 2019
Merged

Set modal bottom sheet barrier color#45067
darrenaustin merged 2 commits intoflutter:masterfrom
katallaxie:modal_barrier_color

Conversation

@katallaxie
Copy link
Copy Markdown
Contributor

Description

When presenting a Modal Bottom Sheet this PR allows to pass down a value for the color of the modal barrier. This is a non-breaking change, because the default behavior is being kept.

Tests

I added the following tests:

  • A test which confirms that the presented modal barrier color reflects the passed in value for the color.

Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I signed the CLA.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • I updated/added relevant documentation (doc comments with ///).
  • All existing and new tests are passing.
  • The analyzer (flutter analyze --flutter-repo) does not report any problems on my PR.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Does your PR require Flutter developers to manually update their apps to accommodate your change?

  • Yes, this is a breaking change (Please read Handling breaking changes). Replace this with a link to the e-mail where you asked for input on this proposed change.
  • No, this is not a breaking change.

@fluttergithubbot fluttergithubbot added f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels. labels Nov 17, 2019
@katallaxie
Copy link
Copy Markdown
Contributor Author

@darrenaustin any thoughts here. Has been laying around for a bit.

Copy link
Copy Markdown
Contributor

@darrenaustin darrenaustin left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution. This is a reasonable feature with a good implementation and test. LGTM.

@darrenaustin
Copy link
Copy Markdown
Contributor

@darrenaustin any thoughts here. Has been laying around for a bit.

Sorry about that. Looks good. I will push this when the build goes green. Thanks for submitting this.

@darrenaustin darrenaustin merged commit 645c323 into flutter:master Dec 10, 2019
@droidery
Copy link
Copy Markdown

@katallaxie Shouldn't this also be exposed in the BottomSheetThemeData. This would allow the same modal sheet barrier color to be used across the entire app.

It would also be more consistent with the other properties available in the BottomSheetThemeData like backgroundColor and shape.

@katallaxie
Copy link
Copy Markdown
Contributor Author

@droidery I thought of this. But because there is default behavior that actually reflects the standard design guidelines I thought it would be better to have this more as a special customization.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Aug 2, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

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.

5 participants