Skip to content

MDC-103: CutCornersBorder does not render anything #134

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jdkoren opened this issue Dec 3, 2018 · 1 comment
Closed

MDC-103: CutCornersBorder does not render anything #134

jdkoren opened this issue Dec 3, 2018 · 1 comment
Labels
bug Something isn't working

Comments

@jdkoren
Copy link
Contributor

jdkoren commented Dec 3, 2018

From https://codelabs.developers.google.com/codelabs/mdc-103-flutter/#6

Using the CutCornersBorder in the inputDecorationTheme renders no border at all around the TextInput. It seems CutCornersBorder uses BorderSide.none by default; I resolved this with the following change:

In CutCornersBorder constructor:

 const CutCornersBorder({
-  BorderSide borderSide: BorderSide.none,
+  BorderSide borderSide: const BorderSide(),
   BorderRadius borderRadius: const BorderRadius.all(Radius.circular(2.0)),
   this.cut: 7.0,
   double gapPadding: 2.0,
 }

(Alternatively, one could pass a BorderSide() when constructing the CutCornersBorder, but I think the above change better supports the Principle of Least Surprise.)

Environment info

Flutter version 0.11.13 at path/redacted/flutter
Framework revision 58c8489fcd (4 days ago), 2018-11-29 19:20:18 -0500
Engine revision 7375a0f414
Dart version 2.1.0 (build 2.1.0-dev.9.4 f9ebf21297)

Android Studio 3.4 Canary 6
Build #AI-183.4284.148.34.5146016, built on November 22, 2018
JRE: 1.8.0_152-release-1248-b01 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Linux (redacted)-amd64

Android Device: Pixel (sailfish) with Android 9.0
jdkoren added a commit to jdkoren/material-components-flutter-codelabs that referenced this issue Dec 3, 2018
- Fix button color (github material-components#133)
- Restore obscureText on password field (github material-components#127)
- Change AccentColorOverride to PrimaryColorOverride (github material-components#128, material-components#132)
- Fix default BorderSide in CutCornersBorder constructor (github material-components#134)
jdkoren added a commit to jdkoren/material-components-flutter-codelabs that referenced this issue Dec 3, 2018
- Fix button color (github material-components#133)
- Restore obscureText on password field (github material-components#127)
- Change AccentColorOverride to PrimaryColorOverride (github material-components#128, material-components#132)
- Fix default BorderSide in CutCornersBorder constructor (github material-components#134)
jdkoren added a commit to jdkoren/material-components-flutter-codelabs that referenced this issue Dec 3, 2018
jdkoren added a commit to jdkoren/material-components-flutter-codelabs that referenced this issue Dec 3, 2018
jdkoren added a commit to jdkoren/material-components-flutter-codelabs that referenced this issue Dec 4, 2018
willlarche pushed a commit that referenced this issue Dec 4, 2018
* Fix default BorderSide in CutCornersBorder constructor

issue #134

* Miscellaneous fixes

- Fix login button color (issue #133)
- Restore obscureText on password field (issue #127)
- Fix AccentColorOverride (issue #128, #132)
@willlarche
Copy link
Collaborator

Should be good to go on all branches. Thank you!

@willlarche willlarche added bug Something isn't working Snippet labels Dec 26, 2018
willlarche added a commit that referenced this issue Mar 25, 2019
[101] Making AppBar something you add in 102.

[Model] Adding model from the start.

[103] Adding fonts.

[103] Supplemental files.

[101] Correcting supplemental files.

[101] Copy correction.

[101] Minor renaming.

[101] Update for Dart 2.

[101] Missing dependency.

[101] Dart 2.

[101] Dart 2.

[101] Dart 2.

[101] Dart 2.

[101] Correcting model.

[Meta] README file.

[Meta] Clarification.

[101] Copy correction.

[104] Updating data.

[101] Correcting widget class. (#23)

Add link to actual codelab in the README

[Meta] README correction.

[101] README specificity.

Add the slanted_menu.png to assets for 101 branch so its ready when needed. (#44)

[101] TODOs for starter code (#50)

[101] Added future TODOs to 101 starter

[101] Included lines to ignore .iml files and files in idea/ (#67)

[101] Remove 104 comments

[All] Icons for Android and iOS. (#69)

[101] Add .vscode/ to gitignore, stop tracking ignored files (#71)

Removes files that should not be tracked because they've been ignored by gitignore rules (but have yet to be removed from the repository itself). Also adds the .vscode folder to gitignore, for users who might use VSCode as their development environment.

[101] Removed legacy 'new' and 'const' from 101 starter codelab (#72)

[101] Restore legacy to data.dart and product.dart (#75)

[101] Update import for app.dart to stop type errors in future codelabs (#83)

Replace data.dart (#99)

[All] Adding back in filter functionality. (#112)

[106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride" (#115)

* [106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride"

* [106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride"

[101] Starter code.

issue #134

[101] Updating pubspec.

Upgrade android gradle plugin and gradle versions. (#143)

Fixes #137
willlarche added a commit that referenced this issue Mar 25, 2019
[101] Making AppBar something you add in 102.

[Model] Adding model from the start.

[103] Adding fonts.

[103] Supplemental files.

[101] Correcting supplemental files.

[101] Copy correction.

[101] Minor renaming.

[101] Update for Dart 2.

[101] Missing dependency.

[101] Dart 2.

[101] Dart 2.

[101] Dart 2.

[101] Dart 2.

[101] Correcting model.

[Meta] README file.

[Meta] Clarification.

[101] Copy correction.

[104] Updating data.

[101] Correcting widget class. (#23)

Add link to actual codelab in the README

[Meta] README correction.

[101] README specificity.

Add the slanted_menu.png to assets for 101 branch so its ready when needed. (#44)

[101] TODOs for starter code (#50)

[101] Added future TODOs to 101 starter

[101] Included lines to ignore .iml files and files in idea/ (#67)

[101] Remove 104 comments

[All] Icons for Android and iOS. (#69)

[101] Add .vscode/ to gitignore, stop tracking ignored files (#71)

Removes files that should not be tracked because they've been ignored by gitignore rules (but have yet to be removed from the repository itself). Also adds the .vscode folder to gitignore, for users who might use VSCode as their development environment.

[101] Removed legacy 'new' and 'const' from 101 starter codelab (#72)

[101] Restore legacy to data.dart and product.dart (#75)

[101] Update import for app.dart to stop type errors in future codelabs (#83)

Replace data.dart (#99)

[All] Adding back in filter functionality. (#112)

[106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride" (#115)

* [106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride"

* [106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride"

[101] Completed code.

[102] Completed code.

[103] Completed code.

104 starter (#136)

* Fix default BorderSide in CutCornersBorder constructor

issue #134

* Miscellaneous fixes

- Fix login button color (issue #133)
- Restore obscureText on password field (issue #127)
- Fix AccentColorOverride (issue #128, #132)

[103] Button theme fix.

[104] Updating pubspec

[103] Completed code.
rami-a pushed a commit that referenced this issue Apr 24, 2019
[101] Making AppBar something you add in 102.

[Model] Adding model from the start.

[103] Adding fonts.

[103] Supplemental files.

[101] Correcting supplemental files.

[101] Copy correction.

[101] Minor renaming.

[101] Update for Dart 2.

[101] Missing dependency.

[101] Dart 2.

[101] Dart 2.

[101] Dart 2.

[101] Dart 2.

[101] Correcting model.

[Meta] README file.

[Meta] Clarification.

[101] Copy correction.

[104] Updating data.

[101] Correcting widget class. (#23)

Add link to actual codelab in the README

[Meta] README correction.

[101] README specificity.

Add the slanted_menu.png to assets for 101 branch so its ready when needed. (#44)

[101] TODOs for starter code (#50)

[101] Added future TODOs to 101 starter

[101] Included lines to ignore .iml files and files in idea/ (#67)

[101] Remove 104 comments

[All] Icons for Android and iOS. (#69)

[101] Add .vscode/ to gitignore, stop tracking ignored files (#71)

Removes files that should not be tracked because they've been ignored by gitignore rules (but have yet to be removed from the repository itself). Also adds the .vscode folder to gitignore, for users who might use VSCode as their development environment.

[101] Removed legacy 'new' and 'const' from 101 starter codelab (#72)

[101] Restore legacy to data.dart and product.dart (#75)

[101] Update import for app.dart to stop type errors in future codelabs (#83)

Replace data.dart (#99)

[All] Adding back in filter functionality. (#112)

[106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride" (#115)

* [106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride"

* [106] Update TODO from "PrimaryColorOverride" to "AccentColorOverride"

[101] Starter code.

issue #134

[101] Updating pubspec.

Upgrade android gradle plugin and gradle versions. (#143)

Fixes #137
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants