Skip to content

Commit 1a50c9b

Browse files
Sandip KakadiyaSandip Kakadiya
authored andcommitted
code formatted
1 parent 9dcfc9c commit 1a50c9b

6 files changed

Lines changed: 22 additions & 21 deletions

File tree

analysis_options.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,7 @@ linter:
1414
# - always_put_required_named_parameters_first
1515
- always_require_non_null_named_parameters
1616
# - annotate_overrides
17-
# required to Allow both GFColors and Colors
18-
# - avoid_annotating_with_dynamic
17+
- avoid_annotating_with_dynamic
1918
- avoid_as
2019
- avoid_bool_literals_in_conditional_expressions
2120
- avoid_catches_without_on_clauses

lib/components/badge/gf_badge.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class GFBadge extends StatefulWidget {
2727
final GFBadgeShape shape;
2828

2929
/// Pass [GFColors] or [Color]
30-
final dynamic color;
30+
final Color color;
3131

3232
/// size of [double] or [GFSize] i.e, 1.2, small, medium, large etc.
3333
final double size;
@@ -42,7 +42,7 @@ class GFBadge extends StatefulWidget {
4242
final TextStyle textStyle;
4343

4444
/// Pass [GFColors] or [Color]
45-
final dynamic textColor;
45+
final Color textColor;
4646

4747
@override
4848
_GFBadgeState createState() => _GFBadgeState();

lib/components/drawer/gf_drawer.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ class GFDrawer extends StatelessWidget {
107107
final Gradient gradient;
108108

109109
/// Defines the background color of the drawer
110-
final dynamic color;
110+
final Color color;
111111

112112
@override
113113
Widget build(BuildContext context) {

lib/components/drawer/gf_drawer_header.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import 'package:flutter/widgets.dart';
22
import 'package:flutter/foundation.dart';
33
import 'package:flutter/material.dart';
4-
import 'package:getflutter/components/button/gf_icon_button.dart';
54
import 'package:getflutter/getflutter.dart';
65

76
class GFDrawerHeaderPictures extends StatelessWidget {

lib/components/loader/gf_loader.dart

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,13 @@ class GFLoader extends StatefulWidget {
2323
final Widget child;
2424

2525
/// Type of GFColor or [Color] which defines the color of the first dot in only circle or square type of loader
26-
final dynamic loaderColorOne;
26+
final Color loaderColorOne;
2727

2828
/// Type of GFColor or [Color] which defines the color of the second dot in only circle or square type of loader
29-
final dynamic loaderColorTwo;
29+
final Color loaderColorTwo;
3030

3131
/// Type of GFColor or [Color] which defines the color of the third dot in only circle or square type of loader
32-
final dynamic loaderColorThree;
32+
final Color loaderColorThree;
3333

3434
/// Type of duration which defines the animation duration of the loader only in circle and square type of loader
3535
final Duration duration;

lib/components/typography/gf_typography.dart

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -99,15 +99,17 @@ class GFTypography extends StatelessWidget {
9999
text != null
100100
? Expanded(
101101
child: Text(
102-
text,
103-
style: TextStyle(
104-
color: textColor ?? backgroundImage != null
105-
? Colors.white
106-
: Colors.black,
107-
fontSize: fontSize,
108-
letterSpacing: 0.3,
109-
fontWeight: FontWeight.w500),
110-
))
102+
text,
103+
style: TextStyle(
104+
color: textColor ??
105+
(backgroundImage != null
106+
? Colors.white
107+
: Colors.black),
108+
fontSize: fontSize,
109+
letterSpacing: 0.3,
110+
fontWeight: FontWeight.w500),
111+
),
112+
)
111113
: child
112114
],
113115
),
@@ -119,9 +121,10 @@ class GFTypography extends StatelessWidget {
119121
width: dividerWidth != null ? dividerWidth : 70,
120122
height: fontSize / 5,
121123
decoration: BoxDecoration(
122-
color: dividerColor ?? backgroundImage != null
123-
? Colors.white
124-
: Colors.black,
124+
color: dividerColor ??
125+
(backgroundImage != null
126+
? Colors.white
127+
: Colors.black),
125128
borderRadius: dividerBorderRadius ??
126129
const BorderRadius.all(
127130
Radius.circular(5),

0 commit comments

Comments
 (0)