Skip to content

Commit

Permalink
Merge pull request #189 from Shreemanarjun/fix-187
Browse files Browse the repository at this point in the history
🐛 Fix #187
  • Loading branch information
iampawan authored Oct 18, 2023
2 parents bf50394 + 9812742 commit 81d9d0f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/src/flutter/shapes.dart
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ class VxContinuousRectangle extends StatelessWidget
this.gradient,
this.backgroundImage,
this.shadows,
}) {
}) : assert(!(backgroundColor != null && gradient != null)) {
setChildForShadow(this);
}

Expand Down Expand Up @@ -420,7 +420,7 @@ class VxContinuousRectangle extends StatelessWidget
assert(debugCheckHasMediaQuery(context));
final ThemeData theme = Theme.of(context);
Color? effectiveBackgroundColor = backgroundColor;
if (effectiveBackgroundColor == null) {
if (effectiveBackgroundColor == null && gradient == null) {
switch (theme.brightness) {
case Brightness.dark:
effectiveBackgroundColor = theme.primaryColorLight;
Expand Down

0 comments on commit 81d9d0f

Please sign in to comment.