11import 'package:flutter/cupertino.dart' ;
22import 'package:flutter/material.dart' ;
3- import 'package:ui_kit/components/avatar/gf_avatar.dart' ;
43import 'package:ui_kit/components/button_bar/gf_button_bar.dart' ;
54import 'package:ui_kit/components/header_bar/gf_title_bar.dart' ;
65import 'package:ui_kit/components/image/gf_image_overlay.dart' ;
@@ -21,8 +20,6 @@ class GFCard extends StatelessWidget {
2120 this .clipBehavior,
2221 this .semanticContainer,
2322 this .title,
24- this .subTitleTextStyle,
25- this .titleTextStyle,
2623 this .content,
2724 this .image,
2825 this .buttonBar,
@@ -55,7 +52,6 @@ class GFCard extends StatelessWidget {
5552 final Clip clipBehavior;
5653
5754 /// The empty space that surrounds the card. Defines the card's outer [Container.margin] .
58-
5955 final EdgeInsetsGeometry margin;
6056
6157 /// The empty space that surrounds the card. Defines the card's outer [Container.margin] ..
@@ -68,12 +64,6 @@ class GFCard extends StatelessWidget {
6864 /// The title to display inside the [GFTitleBar] . see [GFTitleBar]
6965 final GFTitleBar title;
7066
71- /// pass [style] as title's textStyle
72- final TextStyle titleTextStyle;
73-
74- /// pass [style] as subTitle's textStyle
75- final TextStyle subTitleTextStyle;
76-
7767 /// widget can be used to define content
7868 final Widget content;
7969
@@ -109,11 +99,11 @@ class GFCard extends StatelessWidget {
10999
110100 Widget cardChild = Column (
111101 children: < Widget > [
112- titlePosition == GFPosition .start ? title : ClipRRect (
102+ titlePosition == GFPosition .start ? title != null ? title : Container () : image != null ? ClipRRect (
113103 borderRadius: BorderRadius .vertical (top: Radius .circular (4.0 )),
114104 child: image,
115- ),
116- titlePosition == GFPosition .start ? image : title,
105+ ): Container () ,
106+ titlePosition == GFPosition .start ? image != null ? image : Container () : title != null ? title : Container () ,
117107 Padding (
118108 padding: padding,
119109 child: content,
0 commit comments