diff --git a/demo_app/lib/assets/icons/avatar.png b/demo_app/lib/assets/icons/avatar.png new file mode 100644 index 00000000..685ad1a3 Binary files /dev/null and b/demo_app/lib/assets/icons/avatar.png differ diff --git a/demo_app/lib/assets/icons/back.png b/demo_app/lib/assets/icons/back.png new file mode 100644 index 00000000..6c90e89b Binary files /dev/null and b/demo_app/lib/assets/icons/back.png differ diff --git a/demo_app/lib/assets/icons/badge.png b/demo_app/lib/assets/icons/badge.png new file mode 100644 index 00000000..5d233517 Binary files /dev/null and b/demo_app/lib/assets/icons/badge.png differ diff --git a/demo_app/lib/assets/icons/buttons.png b/demo_app/lib/assets/icons/buttons.png new file mode 100644 index 00000000..d7cf8870 Binary files /dev/null and b/demo_app/lib/assets/icons/buttons.png differ diff --git a/demo_app/lib/assets/icons/buttons.svg b/demo_app/lib/assets/icons/buttons.svg new file mode 100644 index 00000000..415c67d3 --- /dev/null +++ b/demo_app/lib/assets/icons/buttons.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/demo_app/lib/assets/icons/card.png b/demo_app/lib/assets/icons/card.png new file mode 100644 index 00000000..79543ea6 Binary files /dev/null and b/demo_app/lib/assets/icons/card.png differ diff --git a/demo_app/lib/assets/icons/chips.png b/demo_app/lib/assets/icons/chips.png new file mode 100644 index 00000000..99b08372 Binary files /dev/null and b/demo_app/lib/assets/icons/chips.png differ diff --git a/demo_app/lib/assets/icons/danger.svg b/demo_app/lib/assets/icons/danger.svg new file mode 100644 index 00000000..dea91e14 --- /dev/null +++ b/demo_app/lib/assets/icons/danger.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/dark.svg b/demo_app/lib/assets/icons/dark.svg new file mode 100644 index 00000000..a5e5eb1b --- /dev/null +++ b/demo_app/lib/assets/icons/dark.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/dribble.svg b/demo_app/lib/assets/icons/dribble.svg new file mode 100644 index 00000000..dbaca3b1 --- /dev/null +++ b/demo_app/lib/assets/icons/dribble.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/fb.svg b/demo_app/lib/assets/icons/fb.svg new file mode 100644 index 00000000..e6078c98 --- /dev/null +++ b/demo_app/lib/assets/icons/fb.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/google.svg b/demo_app/lib/assets/icons/google.svg new file mode 100644 index 00000000..d837859e --- /dev/null +++ b/demo_app/lib/assets/icons/google.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/images.png b/demo_app/lib/assets/icons/images.png new file mode 100644 index 00000000..b5e4cb02 Binary files /dev/null and b/demo_app/lib/assets/icons/images.png differ diff --git a/demo_app/lib/assets/icons/info.svg b/demo_app/lib/assets/icons/info.svg new file mode 100644 index 00000000..21fd193c --- /dev/null +++ b/demo_app/lib/assets/icons/info.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/items.png b/demo_app/lib/assets/icons/items.png new file mode 100644 index 00000000..1a495321 Binary files /dev/null and b/demo_app/lib/assets/icons/items.png differ diff --git a/demo_app/lib/assets/icons/light.svg b/demo_app/lib/assets/icons/light.svg new file mode 100644 index 00000000..bf6f73a6 --- /dev/null +++ b/demo_app/lib/assets/icons/light.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/link.svg b/demo_app/lib/assets/icons/link.svg new file mode 100644 index 00000000..9260d523 --- /dev/null +++ b/demo_app/lib/assets/icons/link.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/linkedin.svg b/demo_app/lib/assets/icons/linkedin.svg new file mode 100644 index 00000000..7adb1746 --- /dev/null +++ b/demo_app/lib/assets/icons/linkedin.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/lists.png b/demo_app/lib/assets/icons/lists.png new file mode 100644 index 00000000..e3e93174 Binary files /dev/null and b/demo_app/lib/assets/icons/lists.png differ diff --git a/demo_app/lib/assets/icons/menu.png b/demo_app/lib/assets/icons/menu.png new file mode 100644 index 00000000..0932d5f5 Binary files /dev/null and b/demo_app/lib/assets/icons/menu.png differ diff --git a/demo_app/lib/assets/icons/next.png b/demo_app/lib/assets/icons/next.png new file mode 100644 index 00000000..8d3c89d9 Binary files /dev/null and b/demo_app/lib/assets/icons/next.png differ diff --git a/demo_app/lib/assets/icons/pinterest.svg b/demo_app/lib/assets/icons/pinterest.svg new file mode 100644 index 00000000..7aa538e1 --- /dev/null +++ b/demo_app/lib/assets/icons/pinterest.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/primary.svg b/demo_app/lib/assets/icons/primary.svg new file mode 100644 index 00000000..c2ad37e4 --- /dev/null +++ b/demo_app/lib/assets/icons/primary.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/secondary.svg b/demo_app/lib/assets/icons/secondary.svg new file mode 100644 index 00000000..56c06ebe --- /dev/null +++ b/demo_app/lib/assets/icons/secondary.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/slack.svg b/demo_app/lib/assets/icons/slack.svg new file mode 100644 index 00000000..ed08c2a0 --- /dev/null +++ b/demo_app/lib/assets/icons/slack.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/slider.png b/demo_app/lib/assets/icons/slider.png new file mode 100644 index 00000000..03fb809b Binary files /dev/null and b/demo_app/lib/assets/icons/slider.png differ diff --git a/demo_app/lib/assets/icons/success.svg b/demo_app/lib/assets/icons/success.svg new file mode 100644 index 00000000..b06b4ae5 --- /dev/null +++ b/demo_app/lib/assets/icons/success.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/tabs.png b/demo_app/lib/assets/icons/tabs.png new file mode 100644 index 00000000..49678a20 Binary files /dev/null and b/demo_app/lib/assets/icons/tabs.png differ diff --git a/demo_app/lib/assets/icons/toast.png b/demo_app/lib/assets/icons/toast.png new file mode 100644 index 00000000..44ee2d77 Binary files /dev/null and b/demo_app/lib/assets/icons/toast.png differ diff --git a/demo_app/lib/assets/icons/toggle.png b/demo_app/lib/assets/icons/toggle.png new file mode 100644 index 00000000..f33816f9 Binary files /dev/null and b/demo_app/lib/assets/icons/toggle.png differ diff --git a/demo_app/lib/assets/icons/twitter.svg b/demo_app/lib/assets/icons/twitter.svg new file mode 100644 index 00000000..ac962749 --- /dev/null +++ b/demo_app/lib/assets/icons/twitter.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/typo.png b/demo_app/lib/assets/icons/typo.png new file mode 100644 index 00000000..90592362 Binary files /dev/null and b/demo_app/lib/assets/icons/typo.png differ diff --git a/demo_app/lib/assets/icons/warning.svg b/demo_app/lib/assets/icons/warning.svg new file mode 100644 index 00000000..aae2b731 --- /dev/null +++ b/demo_app/lib/assets/icons/warning.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/demo_app/lib/assets/icons/whatsapp.svg b/demo_app/lib/assets/icons/whatsapp.svg new file mode 100644 index 00000000..992ff345 --- /dev/null +++ b/demo_app/lib/assets/icons/whatsapp.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/icons/youtube.svg b/demo_app/lib/assets/icons/youtube.svg new file mode 100644 index 00000000..b2503883 --- /dev/null +++ b/demo_app/lib/assets/icons/youtube.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/demo_app/lib/assets/logo/logo.png b/demo_app/lib/assets/logo/logo.png new file mode 100644 index 00000000..27e5cae0 Binary files /dev/null and b/demo_app/lib/assets/logo/logo.png differ diff --git a/demo_app/lib/screens/badges/badges.dart b/demo_app/lib/screens/badges/badges.dart new file mode 100644 index 00000000..34ff7a15 --- /dev/null +++ b/demo_app/lib/screens/badges/badges.dart @@ -0,0 +1,295 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/badge/gf_badge.dart'; +import 'package:ui_kit/components/badge/gf_button_badge.dart'; +import 'package:ui_kit/components/badge/gf_icon_badge.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/components/typography/gf_typography.dart'; +import 'package:ui_kit/components/tabs/gf_tabs.dart'; +import 'package:ui_kit/components/button/gf_icon_button.dart'; +import 'package:ui_kit/position/gf_position.dart'; +import 'package:ui_kit/shape/gf_badge_shape.dart'; +import 'package:ui_kit/shape/gf_button_shape.dart'; +import 'package:ui_kit/size/gf_size.dart'; +import 'package:ui_kit/types/gf_typography_type.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/components/tabs/gf_tabBarView.dart'; + +class Badges extends StatefulWidget { + @override + _BadgesState createState() => _BadgesState(); +} + +class _BadgesState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + title: Text( + 'Badges', + style: TextStyle(fontSize: 17), + ), + centerTitle: true, + ), + body: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'With Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Primary', + ), + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Second', + color: GFColor.secondary, + ), + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Success', + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Warning', + color: GFColor.warning, + ), + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Danger', + color: GFColor.danger, + ), + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Info', + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Light', + color: GFColor.light, + ), + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Dark', + textStyle: TextStyle(color: getGFColor(GFColor.white)), + color: GFColor.dark, + ), + GFButtonBadge( + icon: GFBadge( + text: '6', + shape: GFBadgeShape.pills, + ), + onPressed: () {}, + text: 'Link', + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Icon with Badges', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + children: [ + SizedBox( + height: 20, + ), + Row( + children: [ + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/primary.svg', + color: getGFColor(GFColor.primary), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.circle, + size: GFSize.small, + )), + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg', + color: getGFColor(GFColor.secondary), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.circle, + size: GFSize.small, + )), + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/success.svg', + color: getGFColor(GFColor.success), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.circle, + size: GFSize.small, + )), + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/warning.svg', + color: getGFColor(GFColor.warning), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.circle, + size: GFSize.small, + )), + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/danger.svg', + color: getGFColor(GFColor.danger), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.circle, + size: GFSize.small, + )), + ], + ), + Row( + children: [ + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/info.svg', + color: getGFColor(GFColor.info), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.standard, + size: GFSize.small, + )), + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/light.svg', + color: getGFColor(GFColor.light), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.square, + size: GFSize.small, + )), + GFIconBadge( + child: GFIconButton( + type: GFType.transparent, + onPressed: () {}, + icon: SvgPicture.asset( + 'lib/assets/icons/dark.svg', + color: getGFColor(GFColor.dark), + )), + counterChild: GFBadge( + text: '12', + shape: GFBadgeShape.pills, + size: GFSize.small, + )), + ], + ) + ], + ), + ), + ], + ), + ); + } +} diff --git a/demo_app/lib/screens/button/button-types.dart b/demo_app/lib/screens/button/button-types.dart new file mode 100644 index 00000000..a9ffb0bb --- /dev/null +++ b/demo_app/lib/screens/button/button-types.dart @@ -0,0 +1,237 @@ +import 'package:demo_app/screens/avatars.dart'; +import 'package:demo_app/screens/button/shadow-buttons.dart'; +import 'package:ui_kit/components/avatar/gf_avatar.dart'; + +import 'standard-buttons.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/components/list_tile/gf_list_tile.dart'; +import 'pill-buttons.dart'; +import 'square-buttons.dart'; +import 'icon-buttons.dart'; +import 'social-buttons.dart'; + +class ButtonTypes extends StatefulWidget { + @override + _ButtonTypesState createState() => _ButtonTypesState(); +} + +class _ButtonTypesState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: (){ + Navigator.pop(context); + }, + child:Image.asset('lib/assets/icons/back.png') + ), + title: Text('Buttons', style: TextStyle(fontSize: 17),), + centerTitle: true, + ), + + body: ListView( + children: [ + SizedBox( + height: 20, + ), + GestureDetector( + onTap: (){ + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => StandardButtons() + ), + ); + }, + child:Container( + margin: EdgeInsets.only(left: 15, right: 15, top: 20), + padding: EdgeInsets.all(5), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(7)), + color: getGFColor(GFColor.dark), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ) + ] + ), + child: GFListTile( + color: getGFColor(GFColor.dark), + showDivider: false, + title: Text('Standard Buttons', style: TextStyle(color: getGFColor(GFColor.white)),), + icon: Image.asset('lib/assets/icons/next.png'), + + ), + ) + ), + + GestureDetector( + onTap: (){ + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => PillsButtons() + ), + ); + }, + child:Container( + margin: EdgeInsets.only(left: 15, right: 15, top: 20), + padding: EdgeInsets.all(5), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(7)), + color: getGFColor(GFColor.dark), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ) + ] + ), + child: GFListTile( + color: getGFColor(GFColor.dark), + showDivider: false, + title: Text('Pills Buttons', style: TextStyle(color: getGFColor(GFColor.white)),), + icon: Image.asset('lib/assets/icons/next.png') + ), + ) + ), + + + GestureDetector( + onTap: (){ + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => SquareButtons() + ), + ); + }, + child:Container( + margin: EdgeInsets.only(left: 15, right: 15, top: 20), + padding: EdgeInsets.all(5), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(7)), + color: getGFColor(GFColor.dark), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ) + ] + ), + child: GFListTile( + color: getGFColor(GFColor.dark), + showDivider: false, + title: Text('Square Buttons', style: TextStyle(color: getGFColor(GFColor.white)),), + icon: Image.asset('lib/assets/icons/next.png') + ), + ) + ), + + GestureDetector( + onTap: (){ + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => ShadowButtons() + ), + ); + }, + child:Container( + margin: EdgeInsets.only(left: 15, right: 15, top: 20), + padding: EdgeInsets.all(5), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(7)), + color: getGFColor(GFColor.dark), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ) + ] + ), + child: GFListTile( + color: getGFColor(GFColor.dark), + showDivider: false, + title: Text('Shadow Buttons', style: TextStyle(color: getGFColor(GFColor.white)),), + icon: Image.asset('lib/assets/icons/next.png') + ), + ) + ), + + GestureDetector( + onTap: (){ + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => IconButtons() + ), + ); + }, + child:Container( + margin: EdgeInsets.only(left: 15, right: 15, top: 20), + padding: EdgeInsets.all(5), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(7)), + color: getGFColor(GFColor.dark), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ) + ] + ), + child: GFListTile( + color: getGFColor(GFColor.dark), + showDivider: false, + title: Text('Icons Buttons', style: TextStyle(color: getGFColor(GFColor.white)),), + icon: Image.asset('lib/assets/icons/next.png') + ), + ) + ), + + GestureDetector( + onTap: (){ + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => SocialButtons() + ), + ); + }, + child:Container( + + margin: EdgeInsets.only(left: 15, right: 15, top: 20, bottom: 20), + padding: EdgeInsets.all(5), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(7)), + color: getGFColor(GFColor.dark), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ) + ] + ), + child: GFListTile( + color: getGFColor(GFColor.dark), + showDivider: false, + title: Text('Social Buttons', style: TextStyle(color: getGFColor(GFColor.white)),), + icon: Image.asset('lib/assets/icons/next.png') + ), + ) + ), + + + ], + ) + + ); + } +} diff --git a/demo_app/lib/screens/button/icon-buttons.dart b/demo_app/lib/screens/button/icon-buttons.dart new file mode 100644 index 00000000..80309f0b --- /dev/null +++ b/demo_app/lib/screens/button/icon-buttons.dart @@ -0,0 +1,1185 @@ +import 'package:flutter/material.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/components/button/gf_icon_button.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/components/typography/gf_typography.dart'; +import 'package:ui_kit/types/gf_typography_type.dart'; +import 'package:ui_kit/shape/gf_button_shape.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/size/gf_size.dart'; +import 'package:flutter_svg/flutter_svg.dart'; + +class IconButtons extends StatefulWidget { + @override + _IconButtonsState createState() => _IconButtonsState(); +} + +class _IconButtonsState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: () { + Navigator.pop(context); + }, + child: Image.asset('lib/assets/icons/back.png')), + title: Text( + 'Icon Buttons', + style: TextStyle(fontSize: 17), + ), + centerTitle: true, + ), + body: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Solid Icons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), +// +// GFCard( +// content: Column( +// children: [ +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +//// GFIconButton( +//// onPressed: (){}, +//// icon: Icon(Icons.ac_unit), +////// iconSize: 12.0, +//// type: GFType.solid, +//// shape: GFButtonShape.pills, +//// size: GFSize.large, +////// buttonBoxShadow: true, +////// color: GFColor.primary, +////// boxShadow: BoxShadow( +////// color: Colors.pink, +////// blurRadius: 2.0, +////// spreadRadius: 1.0, +////// offset: Offset.zero, +////// ), +////// borderSide: BorderSide(color: Colors.pink, width: 1.0, style: BorderStyle.solid), +////// borderShape: RoundedRectangleBorder(side: BorderSide(color: Colors.pink, width: 2.0, style: BorderStyle.solid), borderRadius: BorderRadius.zero), +//// ), +// +// +// ], +// ), +// ], +// ) +// ) + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Primary", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/primary.svg')), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text("Second"), + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg'), + color: GFColor.secondary, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + icon: + SvgPicture.asset('lib/assets/icons/success.svg'), + color: GFColor.success, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + icon: SvgPicture.asset('lib/assets/icons/warning.svg'), + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + icon: SvgPicture.asset('lib/assets/icons/danger.svg'), + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + icon: SvgPicture.asset('lib/assets/icons/info.svg'), + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + icon: SvgPicture.asset('lib/assets/icons/light.svg'), + type: GFType.solid, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + style: TextStyle(color: getGFColor(GFColor.white)), + ), + icon: SvgPicture.asset('lib/assets/icons/dark.svg'), + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + icon: SvgPicture.asset('lib/assets/icons/link.svg'), + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Outline Icons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + onPressed: () {}, + type: GFType.outline, + child: Text( + "Primary", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/primary.svg', + color: getGFColor(GFColor.primary), + )), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text("Second"), + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg', + color: getGFColor(GFColor.secondary), + ), + color: GFColor.secondary, + type: GFType.outline, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/success.svg', + color: getGFColor(GFColor.success), + ), + color: GFColor.success, + type: GFType.outline, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/warning.svg', + color: getGFColor(GFColor.warning), + ), + color: GFColor.warning, + type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/danger.svg', + color: getGFColor(GFColor.danger), + ), + color: GFColor.danger, + type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/info.svg', + color: getGFColor(GFColor.info), + ), + color: GFColor.info, + type: GFType.outline, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/light.svg', + color: getGFColor(GFColor.light), + ), + type: GFType.outline, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/dark.svg', + color: getGFColor(GFColor.dark), + ), + color: GFColor.dark, + type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/link.svg', + color: getGFColor(GFColor.alt), + ), + color: GFColor.transparent, + type: GFType.outline, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Outline 2x Icons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + onPressed: () {}, + type: GFType.outline2x, + child: Text( + "Primary", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/primary.svg', + color: getGFColor(GFColor.primary), + )), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text("Second"), + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg', + color: getGFColor(GFColor.secondary), + ), + color: GFColor.secondary, + type: GFType.outline2x, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/success.svg', + color: getGFColor(GFColor.success), + ), + color: GFColor.success, + type: GFType.outline2x, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/warning.svg', + color: getGFColor(GFColor.warning), + ), + color: GFColor.warning, + type: GFType.outline2x, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/danger.svg', + color: getGFColor(GFColor.danger), + ), + color: GFColor.danger, + type: GFType.outline2x, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/info.svg', + color: getGFColor(GFColor.info), + ), + color: GFColor.info, + type: GFType.outline2x, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/light.svg', + color: getGFColor(GFColor.light), + ), + type: GFType.outline2x, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/dark.svg', + color: getGFColor(GFColor.dark), + ), + color: GFColor.dark, + type: GFType.outline2x, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/link.svg', + color: getGFColor(GFColor.alt), + ), + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Square Icons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Primary", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/primary.svg')), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text("Second"), + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg'), + color: GFColor.secondary, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + shape: GFButtonShape.square, + onPressed: () {}, + child: Text( + "Success", + ), + icon: + SvgPicture.asset('lib/assets/icons/success.svg'), + color: GFColor.success, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Warning", + ), + icon: SvgPicture.asset('lib/assets/icons/warning.svg'), + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Danger", + ), + icon: SvgPicture.asset('lib/assets/icons/danger.svg'), + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Info", + ), + icon: SvgPicture.asset('lib/assets/icons/info.svg'), + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Light", + ), + icon: SvgPicture.asset('lib/assets/icons/light.svg'), + type: GFType.solid, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Dark", + style: TextStyle(color: getGFColor(GFColor.white)), + ), + icon: SvgPicture.asset('lib/assets/icons/dark.svg'), + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Link", + ), + icon: SvgPicture.asset('lib/assets/icons/link.svg'), + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Pills Icons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + icon: SvgPicture.asset( + 'lib/assets/icons/primary.svg')), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text("Second"), + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg'), + color: GFColor.secondary, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + shape: GFButtonShape.pills, + onPressed: () {}, + child: Text( + "Success", + ), + icon: + SvgPicture.asset('lib/assets/icons/success.svg'), + color: GFColor.success, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Warning", + ), + icon: SvgPicture.asset('lib/assets/icons/warning.svg'), + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Danger", + ), + icon: SvgPicture.asset('lib/assets/icons/danger.svg'), + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Info", + ), + icon: SvgPicture.asset('lib/assets/icons/info.svg'), + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Light", + ), + icon: SvgPicture.asset('lib/assets/icons/light.svg'), + type: GFType.solid, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Dark", + style: TextStyle(color: getGFColor(GFColor.white)), + ), + icon: SvgPicture.asset('lib/assets/icons/dark.svg'), + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Link", + ), + icon: SvgPicture.asset('lib/assets/icons/link.svg'), + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Shadow Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Primary", + ), + icon: + SvgPicture.asset('lib/assets/icons/primary.svg'), + buttonBoxShadow: true, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text("Second"), + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg'), + color: GFColor.secondary, + buttonBoxShadow: true, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + icon: + SvgPicture.asset('lib/assets/icons/success.svg'), + color: GFColor.success, + buttonBoxShadow: true, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + icon: SvgPicture.asset('lib/assets/icons/warning.svg'), + color: GFColor.warning, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + icon: SvgPicture.asset('lib/assets/icons/danger.svg'), + color: GFColor.danger, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + icon: SvgPicture.asset('lib/assets/icons/info.svg'), + color: GFColor.info, + buttonBoxShadow: true, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + icon: SvgPicture.asset('lib/assets/icons/light.svg'), + type: GFType.solid, + color: GFColor.light, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + style: TextStyle(color: getGFColor(GFColor.white)), + ), + icon: SvgPicture.asset('lib/assets/icons/dark.svg'), + color: GFColor.dark, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + icon: SvgPicture.asset('lib/assets/icons/link.svg'), + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text("Large", + style: TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + icon: SvgPicture.asset('lib/assets/icons/primary.svg'), + ), + GFButton( + onPressed: () {}, + child: Text("Normal", + style: TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + icon: + SvgPicture.asset('lib/assets/icons/secondary.svg'), + ), + GFButton( + onPressed: () {}, + child: Text("Small", + style: TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + icon: SvgPicture.asset('lib/assets/icons/info.svg'), + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Large", + ), + size: GFSize.large, + icon: SvgPicture.asset('lib/assets/icons/primary.svg'), + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Normal", + ), + size: GFSize.medium, + icon: SvgPicture.asset('lib/assets/icons/secondary.svg'), + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Small", + ), + size: GFSize.small, + icon: SvgPicture.asset('lib/assets/icons/success.svg'), + ), + SizedBox( + height: 10, + ), + ], + ), + ), + + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Icons Only', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + icon: + SvgPicture.asset('lib/assets/icons/primary.svg'), + onPressed: () {}), + GFIconButton( + color: GFColor.secondary, + icon: SvgPicture.asset( + 'lib/assets/icons/secondary.svg'), + onPressed: () {}), + GFIconButton( + color: GFColor.success, + icon: + SvgPicture.asset('lib/assets/icons/success.svg'), + onPressed: () {}), + GFIconButton( + color: GFColor.warning, + icon: + SvgPicture.asset('lib/assets/icons/warning.svg'), + onPressed: () {}), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + color: GFColor.danger, + icon: SvgPicture.asset('lib/assets/icons/danger.svg'), + onPressed: () {}), + GFIconButton( + color: GFColor.info, + icon: SvgPicture.asset('lib/assets/icons/info.svg'), + onPressed: () {}), + GFIconButton( + color: GFColor.light, + icon: SvgPicture.asset('lib/assets/icons/light.svg'), + onPressed: () {}), + GFIconButton( + color: GFColor.dark, + icon: SvgPicture.asset('lib/assets/icons/dark.svg'), + onPressed: () {}), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + type: GFType.outline, + icon: Icon(Icons.settings), + onPressed: () {}), + GFIconButton( + type: GFType.outline, + color: GFColor.secondary, + icon: Icon(Icons.send), + onPressed: () {}), + GFIconButton( + type: GFType.outline, + color: GFColor.success, + icon: Icon(Icons.file_download), + onPressed: () {}), + GFIconButton( + type: GFType.outline, + color: GFColor.warning, + icon: Icon(Icons.warning), + onPressed: () {}), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + type: GFType.outline, + color: GFColor.danger, + icon: Icon(Icons.insert_drive_file), + onPressed: () {}), + GFIconButton( + type: GFType.outline, + color: GFColor.info, + icon: Icon(Icons.delete), + onPressed: () {}), + GFIconButton( + type: GFType.outline, + color: GFColor.light, + icon: Icon(Icons.info), + onPressed: () {}), + GFIconButton( + type: GFType.outline, + color: GFColor.dark, + icon: Icon(Icons.apps), + onPressed: () {}), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + )); + } +} diff --git a/demo_app/lib/screens/button/pill-buttons.dart b/demo_app/lib/screens/button/pill-buttons.dart new file mode 100644 index 00000000..b994ecba --- /dev/null +++ b/demo_app/lib/screens/button/pill-buttons.dart @@ -0,0 +1,1189 @@ +import 'package:flutter/material.dart'; +import 'package:ui_kit/components/typography/gf_typography.dart'; +import 'package:ui_kit/components/tabs/gf_tabs.dart'; +import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/size/gf_size.dart'; +import 'package:ui_kit/types/gf_typography_type.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/shape/gf_button_shape.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/components/tabs/gf_tabBarView.dart'; + +class PillsButtons extends StatefulWidget { + @override + _PillsButtonsState createState() => _PillsButtonsState(); +} + +class _PillsButtonsState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: () { + Navigator.pop(context); + }, + child: Image.asset('lib/assets/icons/back.png')), + title: Text( + 'Pills Buttons', + style: TextStyle(fontSize: 17), + ), + centerTitle: true, + ), + body: GFTabs( + height: MediaQuery.of(context).size.height, + tabBarColor: Color(0xFFD3E9ED), + initialIndex: 0, + length: 3, + indicatorColor: getGFColor(GFColor.info), + unselectedLabelColor: getGFColor(GFColor.danger), + labelColor: getGFColor(GFColor.warning), + tabs: [ + GFButton( + onPressed: null, + child: Text( + "Solid", + style: TextStyle(fontSize: 12), + ), + type: GFType.solid, + textColor: GFColor.white, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: null, + child: Text( + "Outline", + style: TextStyle(fontSize: 12), + ), + type: GFType.outline, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: null, + text: 'Outline 2x', + textStyle: TextStyle(fontSize: 12, color: getGFColor(GFColor.dark)), + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + ], + tabBarView: GFTabBarView( + children: [ + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + color: GFColor.primary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + shape: GFButtonShape.pills, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + shape: GFButtonShape.pills, + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + shape: GFButtonShape.pills, + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + shape: GFButtonShape.pills, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + shape: GFButtonShape.pills, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + shape: GFButtonShape.pills, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + shape: GFButtonShape.pills, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + color: GFColor.primary, + ), + GFButton( + onPressed: null, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + shape: GFButtonShape.pills, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Warning", + ), + shape: GFButtonShape.pills, + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text( + "Danger", + ), + shape: GFButtonShape.pills, + color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), + shape: GFButtonShape.pills, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Light", + ), + shape: GFButtonShape.pills, + color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + ), + shape: GFButtonShape.pills, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + shape: GFButtonShape.pills, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text("Large", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text("Normal", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text("Small", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + shape: GFButtonShape.pills, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Large", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Normal", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Small", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + + //tab 2 + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + type: GFType.outline, + color: GFColor.primary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + type: GFType.outline, + color: GFColor.primary, + ), + GFButton( + onPressed: null, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Warning", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text( + "Danger", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Light", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.outline, + shape: GFButtonShape.pills, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + + //tab 3 + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + type: GFType.outline2x, + color: GFColor.primary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + shape: GFButtonShape.pills, + child: Text( + "Primary", + ), + type: GFType.outline2x, + color: GFColor.primary, + ), + GFButton( + onPressed: null, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Warning", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text( + "Danger", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Light", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.outline2x, + shape: GFButtonShape.pills, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + GFButton( + onPressed: () {}, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline2x, + shape: GFButtonShape.pills, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + ], + ), + ), + ); + } +} diff --git a/demo_app/lib/screens/button/shadow-buttons.dart b/demo_app/lib/screens/button/shadow-buttons.dart new file mode 100644 index 00000000..7724c422 --- /dev/null +++ b/demo_app/lib/screens/button/shadow-buttons.dart @@ -0,0 +1,1048 @@ +import 'package:flutter/material.dart'; +import 'package:ui_kit/components/typography/gf_typography.dart'; +import 'package:ui_kit/components/tabs/gf_tabs.dart'; +import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/size/gf_size.dart'; +import 'package:ui_kit/types/gf_typography_type.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/shape/gf_button_shape.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/components/tabs/gf_tabBarView.dart'; + +class ShadowButtons extends StatefulWidget { + @override + _ShadowButtonsState createState() => _ShadowButtonsState(); +} + +class _ShadowButtonsState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: () { + Navigator.pop(context); + }, + child: Image.asset('lib/assets/icons/back.png')), + title: Text( + 'Shadow Buttons', + style: TextStyle(fontSize: 17), + ), + centerTitle: true, + ), +// body: GFTabs( +// height: MediaQuery.of(context).size.height, +// tabBarColor: Color(0xFFD3E9ED), +// initialIndex: 0, +// length: 3, +// indicatorColor: getGFColor(GFColor.info), +// unselectedLabelColor: getGFColor(GFColor.danger), +// labelColor: getGFColor(GFColor.warning), +// tabs: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Solid", +// style: TextStyle(fontSize: 12), +// ), +// buttonBoxShadow: true, +// textColor: GFColor.white, +// ), +// GFButton( +// onPressed: null, +// child: Text( +// "Outline", +// style: TextStyle(fontSize: 12), +// ), +// type: GFType.outline, +// ), +// GFButton( +// onPressed: null, +// text: 'Outline 2x', +// textStyle: TextStyle(fontSize: 12, color: getGFColor(GFColor.dark)), +// type: GFType.outline2x, +// ), +// ], +// tabBarView: GFTabBarView( +// children: [ +// Container( +//// color: Colors.red, +// child: ListView( +// children: [ +// Padding(padding: EdgeInsets.only(left:15, top:30), +// child: GFTypography( +// text: 'Default', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// shape: GFButtonShape.standard, +// +// buttonBoxShadow: true, +// child: Text("Primary", +// ), +// +// color: GFColor.primary, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Secondary", +// ), +// +// color: GFColor.secondary, +// buttonBoxShadow: true, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Success", +// ), +// buttonBoxShadow: true, +// color: GFColor.success, +// ), +// ], +// ), +// +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Warning", +// ), +// buttonBoxShadow: true, +// color: GFColor.warning, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Danger", +// ), +// buttonBoxShadow: true, +// color: GFColor.danger, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Info", +// ), +// buttonBoxShadow: true, +// color: GFColor.info, +// ), +// ], +// ), +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Light", +// ), +// buttonBoxShadow: true, +// color: GFColor.light, +// ), +// +// GFButton( +// onPressed: (){}, +// child: Text( +// "Dark", +// style: +// TextStyle(color: getGFColor(GFColor.white)), +// ), +// buttonBoxShadow: true, +// color: GFColor.dark, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Link", +// ), +// buttonBoxShadow: false, +// color: GFColor.transparent, +// ), +// ], +// ), +//SizedBox( +// height: 10, +//) +// +// ], +// ), +// ), +// +// +// +// +// Padding(padding: EdgeInsets.only(left:15, top:10), +// child: GFTypography( +// text: 'Button Sizes', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// +// +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text("Large", +// ), +// color: GFColor.primary, +// size: GFSize.large, +// buttonBoxShadow: true, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Normal", +// ), +// color: GFColor.primary, +// size: GFSize.medium, +// buttonBoxShadow: true, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Small", +// ), +// color: GFColor.primary, +// size: GFSize.small, +// buttonBoxShadow: true, +// ), +// ], +// ), +// SizedBox( +// height: 10, +// ), +// +// ], +// ), +// ), +// +// +// Padding(padding: EdgeInsets.only(left:15, top:10), +// child: GFTypography( +// text: 'Block Buttons', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// +// +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Large", +// style: TextStyle( +// color: getGFColor(GFColor.white))), +// color: GFColor.primary, +// size: GFSize.large, +// buttonBoxShadow: true, +// ), +// +// SizedBox( +// height: 10, +// ), +// +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Normal", +// style: TextStyle( +// color: getGFColor(GFColor.white))), +// color: GFColor.primary, +// size: GFSize.medium, +// buttonBoxShadow: true, +// ), +// +// SizedBox( +// height: 10, +// ), +// +// +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Small", +// style: TextStyle( +// color: getGFColor(GFColor.white))), +// color: GFColor.primary, +// size: GFSize.small, +// buttonBoxShadow: true, +// ), +// SizedBox( +// height: 10, +// ), +// +// ], +// ), +// ), +// ], +// ), +// ), +// +// +// //tab 2 +// Container( +//// color: Colors.red, +// child: ListView( +// children: [ +// +// Padding(padding: EdgeInsets.only(left:15, top:30), +// child: GFTypography( +// text: 'Default', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Primary", +// +// ), +// +// type: GFType.outline, +// +// ), +// +// +// GFButton( +// onPressed: (){}, +// child: Text("Secondary"), +// type: GFType.outline, +// color: GFColor.secondary, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Success", +// ), +// type: GFType.outline, +// color: GFColor.success, +// ), +// ], +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Warning", +// ), +// type: GFType.outline, +// color: GFColor.warning, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Danger", +// ), +// type: GFType.outline, +// color: GFColor.danger, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Info", +// ), +// type: GFType.outline, +// color: GFColor.info, +// ), +// ], +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Light", +// ), +// type: GFType.outline, +// color: GFColor.light, +// ), +// +// GFButton( +// onPressed: (){}, +// child: Text( +// "Dark", +// ), +// type: GFType.outline, +// color: GFColor.dark, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Link", +// ), +// color: GFColor.transparent, +// ), +// ], +// ), +// ], +// ), +// ), +// +// +// +// Padding(padding: EdgeInsets.only(left:15, top:10), +// child: GFTypography( +// text: 'Button Sizes', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// +// +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text("Large", +// ), +// color: GFColor.primary, +// size: GFSize.large, +// type: GFType.outline, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Normal", +// ), +// color: GFColor.primary, +// size: GFSize.medium, +// type: GFType.outline, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Small", +// ), +// color: GFColor.primary, +// size: GFSize.small, +// type: GFType.outline, +// ), +// ], +// ), +// +// ], +// ), +// ), +// +// +// Padding(padding: EdgeInsets.only(left:15, top:10), +// child: GFTypography( +// text: 'Block Buttons', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// +// +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Large", +// ), +// color: GFColor.primary, +// size: GFSize.large, +// type: GFType.outline, +// ), +// +// SizedBox( +// height: 10, +// ), +// +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Normal", +// ), +// color: GFColor.primary, +// size: GFSize.medium, +// type: GFType.outline, +// ), +// +// SizedBox( +// height: 10, +// ), +// +// +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Small", +// ), +// color: GFColor.primary, +// size: GFSize.small, +// type: GFType.outline, +// ), +// +// ], +// ), +// ), +// +// ], +// ), +// ), +// +// +// //tab 3 +// Container( +//// color: Colors.red, +// child: ListView( +// children: [ +// +// Padding(padding: EdgeInsets.only(left:15, top:30), +// child: GFTypography( +// text: 'Default', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Primary", +// +// ), +// +// type: GFType.outline2x, +// +// ), +// +// +// GFButton( +// onPressed: (){}, +// child: Text("Secondary"), +// type: GFType.outline2x, +// color: GFColor.secondary, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Success", +// ), +// type: GFType.outline2x, +// color: GFColor.success, +// ), +// ], +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Warning", +// ), +// type: GFType.outline2x, +// color: GFColor.warning, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Danger", +// ), +// type: GFType.outline2x, +// color: GFColor.danger, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Info", +// ), +// type: GFType.outline2x, +// color: GFColor.info, +// ), +// ], +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text( +// "Light", +// ), +// type: GFType.outline2x, +// color: GFColor.light, +// ), +// +// GFButton( +// onPressed: (){}, +// child: Text( +// "Dark", +// ), +// type: GFType.outline2x, +// color: GFColor.dark, +// ), +// GFButton( +// onPressed: (){}, +// child: Text( +// "Link", +// ), +// +// color: GFColor.transparent, +// ), +// ], +// ), +// ], +// ), +// ), +// +// +// +// Padding(padding: EdgeInsets.only(left:15, top:10), +// child: GFTypography( +// text: 'Button Sizes', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// +// +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// GFButton( +// onPressed: (){}, +// child: Text("Large", +// ), +// color: GFColor.primary, +// size: GFSize.large, +// type: GFType.outline2x, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Normal", +// ), +// color: GFColor.primary, +// size: GFSize.medium, +// type: GFType.outline2x, +// ), +// GFButton( +// onPressed: (){}, +// child: Text("Small", +// ), +// color: GFColor.primary, +// size: GFSize.small, +// type: GFType.outline2x, +// ), +// ], +// ), +// +// ], +// ), +// ), +// +// +// Padding(padding: EdgeInsets.only(left:15, top:10), +// child: GFTypography( +// text: 'Block Buttons', +// type: GFTypographyType.typo5, +// dividerWidth: 25, +// dividerColor: Color(0xFF19CA4B), +// +// ), +// ), +// +// +// GFCard( +// content: Column( +// mainAxisAlignment: MainAxisAlignment.start, +// crossAxisAlignment: CrossAxisAlignment.start, +// children: [ +// SizedBox( +// height: 10, +// ), +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Large", +// ), +// color: GFColor.primary, +// size: GFSize.large, +// type: GFType.outline2x, +// ), +// +// SizedBox( +// height: 10, +// ), +// +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Normal", +// ), +// color: GFColor.primary, +// size: GFSize.medium, +// type: GFType.outline2x, +// ), +// +// SizedBox( +// height: 10, +// ), +// +// +// GFButton( +// onPressed: (){}, +// blockButton: true, +// child: Text("Small", +// ), +// color: GFColor.primary, +// size: GFSize.small, +// type: GFType.outline2x, +// ), +// +// ], +// ), +// ), +// +// ], +// ), +// ), +// ], +// ), +// ), + + body: Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.standard, + buttonBoxShadow: true, + child: Text( + "Primary", + ), + color: GFColor.primary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + buttonBoxShadow: true, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + buttonBoxShadow: true, + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + buttonBoxShadow: true, + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + buttonBoxShadow: true, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + buttonBoxShadow: true, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + style: TextStyle(color: getGFColor(GFColor.white)), + ), + buttonBoxShadow: true, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + buttonBoxShadow: false, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ) + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + buttonBoxShadow: true, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Large", + style: TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + buttonBoxShadow: true, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Normal", + style: TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + buttonBoxShadow: true, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Small", + style: TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + buttonBoxShadow: true, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + ); + } +} diff --git a/demo_app/lib/screens/button/social-buttons.dart b/demo_app/lib/screens/button/social-buttons.dart new file mode 100644 index 00000000..0d8bf3ea --- /dev/null +++ b/demo_app/lib/screens/button/social-buttons.dart @@ -0,0 +1,331 @@ +import 'package:flutter/material.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/typography/gf_typography.dart'; +import 'package:ui_kit/types/gf_typography_type.dart'; +import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/components/button/gf_icon_button.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/shape/gf_icon_button_shape.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/size/gf_size.dart'; +import 'package:flutter_svg/flutter_svg.dart'; + +class SocialButtons extends StatefulWidget { + @override + _SocialButtonsState createState() => _SocialButtonsState(); +} + +class _SocialButtonsState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: () { + Navigator.pop(context); + }, + child: Image.asset('lib/assets/icons/back.png')), + title: Text( + 'Social Buttons', + style: TextStyle(fontSize: 17), + ), + centerTitle: true, + ), + body: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Social Buttons Full', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GFButton( + buttonBoxShadow: true, + color: Color(0xFF3B5998), + onPressed: () {}, + child: Text( + "FB", + ), + icon: SvgPicture.asset('lib/assets/icons/fb.svg')), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text("Twitter"), + icon: SvgPicture.asset('lib/assets/icons/twitter.svg'), + color: Color(0xFF00ACEE), + buttonBoxShadow: true, + ), + ), + SizedBox( + width: 6, + ), + Expanded( + child: GFButton( + onPressed: () {}, + child: Text( + "Whatsap", + ), + icon: SvgPicture.asset('lib/assets/icons/whatsapp.svg'), + color: Color(0xFF25D366), + buttonBoxShadow: true, + ), + ) + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Google +", + ), + icon: SvgPicture.asset('lib/assets/icons/google.svg'), + color: Color(0xFFDD4B39), + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dribble", + ), + icon: SvgPicture.asset('lib/assets/icons/dribble.svg'), + color: Color(0xFFEA4C89), + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "LinkedIn", + ), + icon: SvgPicture.asset('lib/assets/icons/linkedin.svg'), + color: Color(0xFF0E76A8), + buttonBoxShadow: true, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Youtube", + ), + icon: SvgPicture.asset('lib/assets/icons/youtube.svg'), + color: Color(0xFFC4302B), + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Slack", + style: TextStyle(color: getGFColor(GFColor.white)), + ), + icon: SvgPicture.asset('lib/assets/icons/slack.svg'), + color: Color(0XFF2EB67D), + buttonBoxShadow: true, + ), + GFButton( + onPressed: () {}, + child: Text( + "Pinterest", + ), + icon: SvgPicture.asset('lib/assets/icons/pinterest.svg'), + color: Color(0XFFC8232C), + buttonBoxShadow: true, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Social Buttons Icons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + color: Color(0xFF3B5998), + icon: SvgPicture.asset('lib/assets/icons/fb.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFF00ACEE), + icon: SvgPicture.asset('lib/assets/icons/twitter.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFF25D366), + icon: SvgPicture.asset('lib/assets/icons/whatsapp.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFFDD4B39), + icon: SvgPicture.asset('lib/assets/icons/google.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFFEA4C89), + icon: SvgPicture.asset('lib/assets/icons/dribble.svg'), + onPressed: () {}), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + color: Color(0xFF0E76A8), + icon: SvgPicture.asset('lib/assets/icons/linkedin.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFFC4302B), + icon: SvgPicture.asset('lib/assets/icons/youtube.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0XFF2EB67D), + icon: SvgPicture.asset('lib/assets/icons/slack.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0XFFC8232C), + icon: + SvgPicture.asset('lib/assets/icons/pinterest.svg'), + onPressed: () {}), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Floating Social Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + color: Color(0xFF3B5998), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/fb.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFF00ACEE), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/twitter.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFF25D366), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/whatsapp.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFFDD4B39), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/google.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFFEA4C89), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/dribble.svg'), + onPressed: () {}), + ], + ), + SizedBox( + height: 20, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFIconButton( + color: Color(0xFF0E76A8), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/linkedin.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0xFFC4302B), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/youtube.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0XFF2EB67D), + shape: GFIconButtonShape.pills, + icon: SvgPicture.asset('lib/assets/icons/slack.svg'), + onPressed: () {}), + GFIconButton( + color: Color(0XFFC8232C), + shape: GFIconButtonShape.pills, + icon: + SvgPicture.asset('lib/assets/icons/pinterest.svg'), + onPressed: () {}), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ); + } +} diff --git a/demo_app/lib/screens/buttons.dart b/demo_app/lib/screens/button/square-buttons.dart similarity index 53% rename from demo_app/lib/screens/buttons.dart rename to demo_app/lib/screens/button/square-buttons.dart index 851a7fa2..6c875bd6 100644 --- a/demo_app/lib/screens/buttons.dart +++ b/demo_app/lib/screens/button/square-buttons.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import 'package:ui_kit/components/typography/gf_typography.dart'; import 'package:ui_kit/components/tabs/gf_tabs.dart'; import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/size/gf_size.dart'; import 'package:ui_kit/types/gf_typography_type.dart'; import 'package:ui_kit/types/gf_type.dart'; import 'package:ui_kit/shape/gf_button_shape.dart'; @@ -9,21 +10,27 @@ import 'package:ui_kit/colors/gf_color.dart'; import 'package:ui_kit/components/card/gf_card.dart'; import 'package:ui_kit/components/tabs/gf_tabBarView.dart'; -class Buttons extends StatefulWidget { +class SquareButtons extends StatefulWidget { @override - _ButtonsState createState() => _ButtonsState(); + _SquareButtonsState createState() => _SquareButtonsState(); } -class _ButtonsState extends State { +class _SquareButtonsState extends State { @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: () { + Navigator.pop(context); + }, + child: Image.asset('lib/assets/icons/back.png')), title: Text( - 'Buttons', - style: TextStyle(fontSize: 14), + 'Square Buttons', + style: TextStyle(fontSize: 17), ), + centerTitle: true, ), body: GFTabs( height: MediaQuery.of(context).size.height, @@ -40,8 +47,8 @@ class _ButtonsState extends State { "Solid", style: TextStyle(fontSize: 12), ), - type: GFType.solid, textColor: GFColor.white, + shape: GFButtonShape.square, ), GFButton( onPressed: null, @@ -50,13 +57,14 @@ class _ButtonsState extends State { style: TextStyle(fontSize: 12), ), type: GFType.outline, - shape: GFButtonShape.pills, + shape: GFButtonShape.square, ), GFButton( onPressed: null, - text: 'Transparent', + text: 'Outline 2x', textStyle: TextStyle(fontSize: 12, color: getGFColor(GFColor.dark)), - type: GFType.transparent, + type: GFType.outline2x, + shape: GFButtonShape.square, ), ], tabBarView: GFTabBarView( @@ -65,15 +73,20 @@ class _ButtonsState extends State { // color: Colors.red, child: ListView( children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), GFCard( content: Column( mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFTypography( - text: 'Standard', - type: GFTypographyType.typo6, - ), SizedBox( height: 10, ), @@ -81,116 +94,114 @@ class _ButtonsState extends State { mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, - child: Text("Primary", - style: TextStyle( - color: getGFColor(GFColor.white))), - type: GFType.solid, + onPressed: () {}, + shape: GFButtonShape.square, + child: Text( + "Primary", + ), color: GFColor.primary, ), GFButton( - onPressed: null, - child: Text("Secondary", - style: TextStyle( - color: getGFColor(GFColor.white))), - type: GFType.solid, + onPressed: () {}, + child: Text( + "Secondary", + ), color: GFColor.secondary, + shape: GFButtonShape.square, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Success", ), - type: GFType.solid, + shape: GFButtonShape.square, color: GFColor.success, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Warning", ), - type: GFType.solid, + shape: GFButtonShape.square, color: GFColor.warning, ), GFButton( - onPressed: null, - child: Text("Danger", - style: TextStyle( - color: getGFColor(GFColor.white))), - type: GFType.solid, + onPressed: () {}, + child: Text( + "Danger", + ), + shape: GFButtonShape.square, color: GFColor.danger, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Light", + "Info", ), - type: GFType.solid, - color: GFColor.light, + shape: GFButtonShape.square, + color: GFColor.info, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Info", + "Light", ), - type: GFType.solid, - color: GFColor.info, - ), - GFButton( - onPressed: null, - child: Text("Alt", - style: TextStyle( - color: getGFColor(GFColor.white))), - type: GFType.solid, - color: GFColor.alt, + shape: GFButtonShape.square, + color: GFColor.light, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Dark", - style: - TextStyle(color: getGFColor(GFColor.white)), ), - type: GFType.solid, + shape: GFButtonShape.square, color: GFColor.dark, ), - ], - ), - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Transparent", + "Link", ), - type: GFType.solid, color: GFColor.transparent, ), ], - ) + ), + SizedBox( + height: 10, + ), ], ), ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), GFCard( content: Column( mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFTypography( - text: 'Pills', - type: GFTypographyType.typo6, - ), SizedBox( height: 10, ), @@ -199,30 +210,33 @@ class _ButtonsState extends State { children: [ GFButton( onPressed: null, - child: Text("Primary", - style: TextStyle( - color: getGFColor(GFColor.white))), + shape: GFButtonShape.square, + child: Text( + "Primary", + ), color: GFColor.primary, - shape: GFButtonShape.pills, ), GFButton( onPressed: null, - child: Text("Secondary", - style: TextStyle( - color: getGFColor(GFColor.white))), + child: Text( + "Secondary", + ), color: GFColor.secondary, - shape: GFButtonShape.pills, + shape: GFButtonShape.square, ), GFButton( onPressed: null, child: Text( "Success", ), - shape: GFButtonShape.pills, + shape: GFButtonShape.square, color: GFColor.success, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ @@ -231,83 +245,78 @@ class _ButtonsState extends State { child: Text( "Warning", ), - shape: GFButtonShape.pills, + shape: GFButtonShape.square, color: GFColor.warning, ), GFButton( onPressed: null, - child: Text("Danger", - style: TextStyle( - color: getGFColor(GFColor.white))), - shape: GFButtonShape.pills, + child: Text( + "Danger", + ), + shape: GFButtonShape.square, color: GFColor.danger, ), GFButton( onPressed: null, child: Text( - "Light", + "Info", ), - shape: GFButtonShape.pills, - color: GFColor.light, + shape: GFButtonShape.square, + color: GFColor.info, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( onPressed: null, child: Text( - "Info", + "Light", ), - shape: GFButtonShape.pills, - color: GFColor.info, - ), - GFButton( - onPressed: null, - child: Text("Alt", - style: TextStyle( - color: getGFColor(GFColor.white))), - shape: GFButtonShape.pills, - color: GFColor.alt, + shape: GFButtonShape.square, + color: GFColor.light, ), GFButton( onPressed: null, child: Text( "Dark", - style: - TextStyle(color: getGFColor(GFColor.white)), ), - shape: GFButtonShape.pills, + shape: GFButtonShape.square, color: GFColor.dark, ), - ], - ), - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ GFButton( onPressed: null, child: Text( - "Transparent", + "link", ), - shape: GFButtonShape.pills, color: GFColor.transparent, ), ], - ) + ), + SizedBox( + height: 10, + ), ], ), ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), GFCard( content: Column( mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFTypography( - text: 'Square', - type: GFTypographyType.typo6, - ), SizedBox( height: 10, ), @@ -315,123 +324,122 @@ class _ButtonsState extends State { mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, - child: Text("Primary", + onPressed: () {}, + child: Text("Large", style: TextStyle( color: getGFColor(GFColor.white))), color: GFColor.primary, + size: GFSize.large, shape: GFButtonShape.square, ), GFButton( - onPressed: null, - child: Text("Secondary", + onPressed: () {}, + child: Text("Normal", style: TextStyle( color: getGFColor(GFColor.white))), - color: GFColor.secondary, - shape: GFButtonShape.square, - ), - GFButton( - onPressed: null, - child: Text( - "Success", - ), - shape: GFButtonShape.square, - color: GFColor.success, - ), - ], - ), - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - GFButton( - onPressed: null, - child: Text( - "Warning", - ), + color: GFColor.primary, + size: GFSize.medium, shape: GFButtonShape.square, - color: GFColor.warning, ), GFButton( - onPressed: null, - child: Text("Danger", + onPressed: () {}, + child: Text("Small", style: TextStyle( color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, shape: GFButtonShape.square, - color: GFColor.danger, - ), - GFButton( - onPressed: null, - child: Text( - "Light", - ), - shape: GFButtonShape.square, - color: GFColor.light, ), ], ), - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - GFButton( - onPressed: null, - child: Text( - "Info", - ), - shape: GFButtonShape.square, - color: GFColor.info, - ), - GFButton( - onPressed: null, - child: Text("Alt", - style: TextStyle( - color: getGFColor(GFColor.white))), - shape: GFButtonShape.square, - color: GFColor.alt, - ), - GFButton( - onPressed: null, - child: Text( - "Dark", - style: - TextStyle(color: getGFColor(GFColor.white)), - ), - shape: GFButtonShape.square, - color: GFColor.dark, - ), - ], + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 20), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Large", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Normal", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Small", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, ), - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - GFButton( - onPressed: null, - child: Text( - "Transparent", - ), - shape: GFButtonShape.square, - color: GFColor.transparent, - ), - ], - ) ], ), ), ], ), ), + + //tab 2 Container( // color: Colors.red, child: ListView( children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), GFCard( content: Column( mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFTypography( - text: 'Standard', - type: GFTypographyType.typo6, - ), SizedBox( height: 10, ), @@ -439,98 +447,122 @@ class _ButtonsState extends State { mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, + shape: GFButtonShape.square, child: Text( "Primary", ), type: GFType.outline, + color: GFColor.primary, ), GFButton( - onPressed: null, - child: Text("Secondary"), - type: GFType.outline, + onPressed: () {}, + child: Text( + "Secondary", + ), color: GFColor.secondary, + type: GFType.outline, + shape: GFButtonShape.square, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Success", ), type: GFType.outline, + shape: GFButtonShape.square, color: GFColor.success, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Warning", ), type: GFType.outline, + shape: GFButtonShape.square, color: GFColor.warning, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Danger", ), type: GFType.outline, + shape: GFButtonShape.square, color: GFColor.danger, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Light", + "Info", ), type: GFType.outline, - color: GFColor.light, + shape: GFButtonShape.square, + color: GFColor.info, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Info", + "Light", ), type: GFType.outline, - color: GFColor.info, + shape: GFButtonShape.square, + color: GFColor.light, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Alt", + "Dark", ), type: GFType.outline, - color: GFColor.alt, + shape: GFButtonShape.square, + color: GFColor.dark, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Dark", + "Link", ), - type: GFType.outline, - color: GFColor.dark, + color: GFColor.transparent, ), ], ), + SizedBox( + height: 10, + ), ], ), ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), GFCard( content: Column( mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFTypography( - text: 'Pills', - type: GFTypographyType.typo6, - ), SizedBox( height: 10, ), @@ -539,12 +571,12 @@ class _ButtonsState extends State { children: [ GFButton( onPressed: null, + shape: GFButtonShape.square, child: Text( "Primary", ), type: GFType.outline, color: GFColor.primary, - shape: GFButtonShape.pills, ), GFButton( onPressed: null, @@ -552,20 +584,23 @@ class _ButtonsState extends State { "Secondary", ), color: GFColor.secondary, - shape: GFButtonShape.pills, type: GFType.outline, + shape: GFButtonShape.square, ), GFButton( onPressed: null, child: Text( "Success", ), - shape: GFButtonShape.pills, - color: GFColor.success, type: GFType.outline, + shape: GFButtonShape.square, + color: GFColor.success, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ @@ -574,74 +609,212 @@ class _ButtonsState extends State { child: Text( "Warning", ), - shape: GFButtonShape.pills, - color: GFColor.warning, type: GFType.outline, + shape: GFButtonShape.square, + color: GFColor.warning, ), GFButton( onPressed: null, child: Text( "Danger", ), - shape: GFButtonShape.pills, + type: GFType.outline, + shape: GFButtonShape.square, color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), type: GFType.outline, + shape: GFButtonShape.square, + color: GFColor.info, ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ GFButton( onPressed: null, child: Text( "Light", ), - shape: GFButtonShape.pills, + type: GFType.outline, + shape: GFButtonShape.square, color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + ), type: GFType.outline, + shape: GFButtonShape.square, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + color: GFColor.transparent, ), ], ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Info", + "Large", ), - shape: GFButtonShape.pills, - color: GFColor.info, + color: GFColor.primary, + size: GFSize.large, type: GFType.outline, + shape: GFButtonShape.square, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Alt", + "Normal", ), - shape: GFButtonShape.pills, - color: GFColor.alt, + color: GFColor.primary, + size: GFSize.medium, type: GFType.outline, + shape: GFButtonShape.square, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( - "Dark", + "Small", ), - shape: GFButtonShape.pills, - color: GFColor.dark, + color: GFColor.primary, + size: GFSize.small, type: GFType.outline, + shape: GFButtonShape.square, ), ], ), + SizedBox( + height: 10, + ), ], ), ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), GFCard( content: Column( mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFTypography( - text: 'Square', - type: GFTypographyType.typo6, + SizedBox( + height: 10, ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + + //tab 3 + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ SizedBox( height: 10, ), @@ -649,199 +822,354 @@ class _ButtonsState extends State { mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, + shape: GFButtonShape.square, child: Text( "Primary", ), - type: GFType.outline, + type: GFType.outline2x, color: GFColor.primary, - shape: GFButtonShape.square, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Secondary", ), color: GFColor.secondary, + type: GFType.outline2x, shape: GFButtonShape.square, - type: GFType.outline, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Success", ), + type: GFType.outline2x, shape: GFButtonShape.square, color: GFColor.success, - type: GFType.outline, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Warning", ), + type: GFType.outline2x, shape: GFButtonShape.square, color: GFColor.warning, - type: GFType.outline, ), GFButton( - onPressed: null, + onPressed: () {}, child: Text( "Danger", ), + type: GFType.outline2x, shape: GFButtonShape.square, color: GFColor.danger, - type: GFType.outline, ), GFButton( - onPressed: null, + onPressed: () {}, + child: Text( + "Info", + ), + type: GFType.outline2x, + shape: GFButtonShape.square, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, child: Text( "Light", ), + type: GFType.outline2x, shape: GFButtonShape.square, color: GFColor.light, - type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + type: GFType.outline2x, + shape: GFButtonShape.square, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + shape: GFButtonShape.square, + child: Text( + "Primary", + ), + type: GFType.outline2x, + color: GFColor.primary, + ), + GFButton( + onPressed: null, + child: Text( + "Secondary", + ), + color: GFColor.secondary, + type: GFType.outline2x, + shape: GFButtonShape.square, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + type: GFType.outline2x, + shape: GFButtonShape.square, + color: GFColor.success, ), ], ), + SizedBox( + height: 10, + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ + GFButton( + onPressed: null, + child: Text( + "Warning", + ), + type: GFType.outline2x, + shape: GFButtonShape.square, + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text( + "Danger", + ), + type: GFType.outline2x, + shape: GFButtonShape.square, + color: GFColor.danger, + ), GFButton( onPressed: null, child: Text( "Info", ), + type: GFType.outline2x, shape: GFButtonShape.square, color: GFColor.info, - type: GFType.outline, ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ GFButton( onPressed: null, child: Text( - "Alt", + "Light", ), + type: GFType.outline2x, shape: GFButtonShape.square, - color: GFColor.alt, - type: GFType.outline, + color: GFColor.light, ), GFButton( onPressed: null, child: Text( "Dark", ), + type: GFType.outline2x, shape: GFButtonShape.square, color: GFColor.dark, - type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + color: GFColor.transparent, ), ], ), + SizedBox( + height: 10, + ), ], ), ), - ], - ), - ), - Container( - margin: EdgeInsets.only(top: 20, right: 20, left: 20), - height: 100, - child: Column( - children: [ - GFTypography( - text: 'Transparent', - type: GFTypographyType.typo6, + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), ), - Row( + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFButton( - onPressed: null, - child: Text( - "Primary", - ), - type: GFType.transparent, - textColor: GFColor.primary, + SizedBox( + height: 10, ), - GFButton( - onPressed: null, - child: Text( - "Secondary", - ), - type: GFType.transparent, - textColor: GFColor.secondary, + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline2x, + shape: GFButtonShape.square, + ), + GFButton( + onPressed: () {}, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline2x, + shape: GFButtonShape.square, + ), + GFButton( + onPressed: () {}, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline2x, + shape: GFButtonShape.square, + ), + ], ), - GFButton( - onPressed: null, - child: Text( - "Success", - ), - type: GFType.transparent, - textColor: GFColor.success, + SizedBox( + height: 10, ), ], ), - Row( + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, children: [ - GFButton( - onPressed: null, - child: Text( - "Warning", - ), - type: GFType.transparent, - textColor: GFColor.warning, + SizedBox( + height: 10, ), GFButton( - onPressed: null, + onPressed: () {}, + blockButton: true, child: Text( - "Danger", + "Large", ), - type: GFType.transparent, - textColor: GFColor.danger, + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline2x, + shape: GFButtonShape.square, ), - GFButton( - onPressed: null, - child: Text( - "Dark", - ), - type: GFType.transparent, - textColor: GFColor.dark, + SizedBox( + height: 10, ), - ], - ), - Row( - children: [ GFButton( - onPressed: null, + onPressed: () {}, + blockButton: true, child: Text( - "Light", + "Normal", ), - type: GFType.transparent, - textColor: GFColor.light, + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline2x, + shape: GFButtonShape.square, ), - GFButton( - onPressed: null, - child: Text( - "Info", - ), - type: GFType.transparent, - textColor: GFColor.info, + SizedBox( + height: 10, ), GFButton( - onPressed: null, + onPressed: () {}, + blockButton: true, child: Text( - "Alt", + "Small", ), - type: GFType.transparent, - textColor: GFColor.alt, + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline2x, + shape: GFButtonShape.square, + ), + SizedBox( + height: 10, ), ], ), - ], - )) + ), + ], + ), + ), ], ), ), diff --git a/demo_app/lib/screens/button/standard-buttons.dart b/demo_app/lib/screens/button/standard-buttons.dart new file mode 100644 index 00000000..0f1e3b70 --- /dev/null +++ b/demo_app/lib/screens/button/standard-buttons.dart @@ -0,0 +1,1213 @@ +import 'package:flutter/material.dart'; +import 'package:ui_kit/components/typography/gf_typography.dart'; +import 'package:ui_kit/components/tabs/gf_tabs.dart'; +import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/size/gf_size.dart'; +import 'package:ui_kit/types/gf_typography_type.dart'; +import 'package:ui_kit/types/gf_toggle_type.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/shape/gf_button_shape.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/components/tabs/gf_tabBarView.dart'; + +class StandardButtons extends StatefulWidget { + @override + _StandardButtonsState createState() => _StandardButtonsState(); +} + +class _StandardButtonsState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + leading: GestureDetector( + onTap: () { + Navigator.pop(context); + }, + child: Image.asset('lib/assets/icons/back.png')), + title: Text( + 'Standard Buttons', + style: TextStyle(fontSize: 17), + ), + centerTitle: true, + ), + body: GFTabs( + height: MediaQuery.of(context).size.height, + tabBarColor: Color(0xFFD3E9ED), + initialIndex: 0, + length: 3, + indicatorColor: getGFColor(GFColor.info), + unselectedLabelColor: getGFColor(GFColor.danger), + labelColor: getGFColor(GFColor.warning), + tabs: [ + GFButton( + onPressed: null, + child: Text( + "Solid", + style: TextStyle(fontSize: 12), + ), + type: GFType.solid, + textColor: GFColor.white, + ), + GFButton( + onPressed: null, + child: Text( + "Outline", + style: TextStyle(fontSize: 12), + ), + type: GFType.outline, + ), + GFButton( + onPressed: null, + text: 'Outline 2x', + textStyle: TextStyle(fontSize: 12, color: getGFColor(GFColor.dark)), + type: GFType.outline2x, + ), + ], + tabBarView: GFTabBarView( + children: [ + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + shape: GFButtonShape.standard, + child: Text("Primary", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + ), + GFButton( + onPressed: () {}, + child: Text("Secondary", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.secondary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text("Danger", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + style: + TextStyle(color: getGFColor(GFColor.white)), + ), + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.solid, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + shape: GFButtonShape.standard, + child: Text("Primary", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + ), + GFButton( + onPressed: null, + child: Text("Secondary", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.secondary, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Warning", + ), + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text("Danger", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Light", + ), + color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + style: + TextStyle(color: getGFColor(GFColor.white)), + ), + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.solid, + color: GFColor.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Transparent Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Primary", + ), + type: GFType.transparent, + textColor: GFColor.primary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Secondary", + ), + type: GFType.transparent, + textColor: GFColor.secondary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + type: GFType.transparent, + textColor: GFColor.success, + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.transparent, + textColor: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + type: GFType.transparent, + textColor: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + type: GFType.transparent, + textColor: GFColor.info, + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + type: GFType.transparent, + textColor: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + type: GFType.transparent, + textColor: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text("Large", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + ), + GFButton( + onPressed: () {}, + child: Text("Normal", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + ), + GFButton( + onPressed: () {}, + child: Text("Small", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + ), + SizedBox( + height: 10, + ), + ], + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Large", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Normal", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text("Small", + style: + TextStyle(color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + + //tab 2 + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Primary", + ), + type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text("Secondary"), + type: GFType.outline, + color: GFColor.secondary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + type: GFType.outline, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.outline, + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + type: GFType.outline, + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + type: GFType.outline, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + type: GFType.outline, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + type: GFType.outline, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Primary", + ), + type: GFType.outline, + ), + GFButton( + onPressed: null, + child: Text("Secondary"), + type: GFType.outline, + color: GFColor.secondary, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + type: GFType.outline, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.outline, + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text( + "Danger", + ), + type: GFType.outline, + color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), + type: GFType.outline, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Light", + ), + type: GFType.outline, + color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + ), + type: GFType.outline, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline, + ), + GFButton( + onPressed: () {}, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline, + ), + SizedBox( + height: 10, + ), + ], + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + + //tab 3 + Container( +// color: Colors.red, + child: ListView( + children: [ + Padding( + padding: EdgeInsets.only(left: 15, top: 30), + child: GFTypography( + text: 'Default', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Primary", + ), + type: GFType.outline2x, + ), + GFButton( + onPressed: () {}, + child: Text("Secondary"), + type: GFType.outline2x, + color: GFColor.secondary, + ), + GFButton( + onPressed: () {}, + child: Text( + "Success", + ), + type: GFType.outline2x, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.outline2x, + color: GFColor.warning, + ), + GFButton( + onPressed: () {}, + child: Text( + "Danger", + ), + type: GFType.outline2x, + color: GFColor.danger, + ), + GFButton( + onPressed: () {}, + child: Text( + "Info", + ), + type: GFType.outline2x, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Light", + ), + type: GFType.outline2x, + color: GFColor.light, + ), + GFButton( + onPressed: () {}, + child: Text( + "Dark", + ), + type: GFType.outline2x, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Disabled State', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Primary", + ), + type: GFType.outline2x, + ), + GFButton( + onPressed: null, + child: Text("Secondary"), + type: GFType.outline2x, + color: GFColor.secondary, + ), + GFButton( + onPressed: null, + child: Text( + "Success", + ), + type: GFType.outline2x, + color: GFColor.success, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Warning", + ), + type: GFType.outline2x, + color: GFColor.warning, + ), + GFButton( + onPressed: null, + child: Text( + "Danger", + ), + type: GFType.outline2x, + color: GFColor.danger, + ), + GFButton( + onPressed: null, + child: Text( + "Info", + ), + type: GFType.outline2x, + color: GFColor.info, + ), + ], + ), + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: null, + child: Text( + "Light", + ), + type: GFType.outline2x, + color: GFColor.light, + ), + GFButton( + onPressed: null, + child: Text( + "Dark", + ), + type: GFType.outline2x, + color: GFColor.dark, + ), + GFButton( + onPressed: () {}, + child: Text( + "Link", + ), + type: GFType.transparent, + ), + ], + ), + SizedBox( + height: 10, + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Button Sizes', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFButton( + onPressed: () {}, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline2x, + ), + GFButton( + onPressed: () {}, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline2x, + ), + GFButton( + onPressed: () {}, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline2x, + ), + SizedBox( + height: 10, + ), + ], + ), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 15, top: 10), + child: GFTypography( + text: 'Block Buttons', + type: GFTypographyType.typo5, + dividerWidth: 25, + dividerColor: Color(0xFF19CA4B), + ), + ), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Large", + ), + color: GFColor.primary, + size: GFSize.large, + type: GFType.outline2x, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Normal", + ), + color: GFColor.primary, + size: GFSize.medium, + type: GFType.outline2x, + ), + SizedBox( + height: 10, + ), + GFButton( + onPressed: () {}, + blockButton: true, + child: Text( + "Small", + ), + color: GFColor.primary, + size: GFSize.small, + type: GFType.outline2x, + ), + SizedBox( + height: 10, + ), + ], + ), + ), + ], + ), + ), + ], + ), + ), + ); + } +} diff --git a/demo_app/lib/screens/home.dart b/demo_app/lib/screens/home.dart index 09eec93d..2f3add5e 100644 --- a/demo_app/lib/screens/home.dart +++ b/demo_app/lib/screens/home.dart @@ -1,15 +1,17 @@ -//import 'package:demo_app/screens/cards.dart'; -//import 'package:demo_app/screens/icon-button.dart'; -//import 'package:demo_app/screens/list-tiles.dart'; +import 'package:demo_app/screens/button/button-types.dart'; +import 'package:demo_app/screens/cards.dart'; +import 'package:demo_app/screens/icon-button.dart'; +import 'package:demo_app/screens/list-tiles.dart'; import 'package:flutter/material.dart'; import 'package:ui_kit/colors/gf_color.dart'; import 'package:ui_kit/components/card/gf_card.dart'; import 'avatars.dart'; -import 'buttons.dart'; import 'toggles.dart'; import 'headers.dart'; import 'toasts.dart'; -import 'badges.dart'; +import '../screens/badges/badges.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import '../screens/button/standard-buttons.dart'; class HomePage extends StatefulWidget { @override @@ -20,308 +22,669 @@ class _HomePageState extends State { @override Widget build(BuildContext context) { return Scaffold( - appBar: AppBar( - backgroundColor: getGFColor(GFColor.dark), - title: Text( - 'GET FLUTTER', - style: TextStyle(fontSize: 14), + appBar: AppBar( + backgroundColor: getGFColor(GFColor.dark), + title: Image.asset('lib/assets/logo/logo.png'), + centerTitle: true, ), - centerTitle: true, - ), -// body: Container( -// child: Row( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Expanded(child: GestureDetector( -// onTap: (){ -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Buttons()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.bubble_chart), -// Text('Buttons') -// ], -// ), -// ), -// )), -// Expanded(child: GestureDetector( -// onTap: (){ -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Avatars()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.warning), -// content: Column( -// children: [ -// Icon(Icons.face), -// Text('Avatar') -// ], -// ), -// ), -// ),) -// ], -// ), -// ) - - body:Text("Dcfs") - -// Column( -// children: [ -// Row( -// children: [ -// Expanded( -// child: Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Buttons()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.bubble_chart, -// color: getGFColor(GFColor.white)), -// Text( -// 'Buttons', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// ))), -// Expanded( -// child: Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Avatars()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.face, color: getGFColor(GFColor.white)), -// Text( -// 'Avatar', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// )), -// ), -// Expanded( -// child: Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Toggles()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.all_inclusive, -// color: getGFColor(GFColor.white)), -// Text( -// 'Toggle', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// ))) -// ], -// ), - -// Row( -// children: [ -// Expanded(child:Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Headers()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.menu, -// color: getGFColor(GFColor.white)), -// Text( -// 'Header', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// )) ), -// Expanded(child:Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Toasts()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.call_to_action, -// color: getGFColor(GFColor.white)), -// Text( -// 'Toast', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// )) ), -// Expanded(child:Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Cards()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.credit_card, -// color: getGFColor(GFColor.white)), -// Text( -// 'Card', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// )) ) -// ], -// ), -// -// Row( -// children: [ -// Expanded(child:Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => IconButtons()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.insert_emoticon, -// color: getGFColor(GFColor.white)), -// Text( -// 'Icon Button', -// style: TextStyle(color: getGFColor(GFColor.white), fontSize: 12), -// ) -// ], -// ), -// ), -// )) ), -// Expanded(child:Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => ListTiles()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.list, -// color: getGFColor(GFColor.white)), -// Text( -// 'ListTile', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// )) ), -// Expanded(child:Container( -// height: 100, -// child: GestureDetector( -// onTap: () { -// Navigator.push( -// context, -// MaterialPageRoute( -// builder: (BuildContext context) => Badges()), -// ); -// }, -// child: GFCard( -// color: getGFColor(GFColor.success), -// content: Column( -// mainAxisAlignment: MainAxisAlignment.spaceBetween, -// children: [ -// Icon(Icons.apps, -// color: getGFColor(GFColor.white)), -// Text( -// 'Badges', -// style: TextStyle(color: getGFColor(GFColor.white)), -// ) -// ], -// ), -// ), -// )) -// ) -// ], -// ) -// ], -// ), - ); + body: Container( + margin: EdgeInsets.only(left: 15, right: 15), + child: ListView( + children: [ + SizedBox( + height: 10, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => ButtonTypes()), + ); + }, + child: Container( + height: 160, + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/buttons.png'), + Text( + 'Buttons', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 23, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => Cards()), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/card.png'), +// SvgPicture.asset('lib/assets/icons/buttons.svg', color: getGFColor(GFColor.success),), + Text( + 'Cards', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + )) + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/chips.png'), + Text( + 'Chips', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 23, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/items.png'), +// SvgPicture.asset('lib/assets/icons/buttons.svg', color: getGFColor(GFColor.success),), + Text( + 'Items', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + )) + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/lists.png'), + Text( + 'Lists', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 23, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/menu.png'), +// SvgPicture.asset('lib/assets/icons/buttons.svg', color: getGFColor(GFColor.success),), + Text( + 'Menu', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + )) + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/slider.png'), + Text( + 'Sliders', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 23, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Image.asset('lib/assets/icons/tabs.png'), +// SvgPicture.asset('lib/assets/icons/buttons.svg', color: getGFColor(GFColor.success),), + Text( + 'Tabs', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + )) + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/toast.png'), + Text( + 'Toasts', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 23, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Image.asset('lib/assets/icons/toggle.png'), +// SvgPicture.asset('lib/assets/icons/buttons.svg', color: getGFColor(GFColor.success),), + Text( + 'Toggle', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + )) + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => Badges() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/badge.png'), + Text( + 'Badges', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 23, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Buttons() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Image.asset('lib/assets/icons/avatar.png'), +// SvgPicture.asset('lib/assets/icons/buttons.svg', color: getGFColor(GFColor.success),), + Text( + 'Avatars', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + )) + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => Headers()), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/typo.png'), + Text( + 'Typography', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ), + SizedBox( + width: 20, + ), + Expanded( + child: GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( +// builder: (BuildContext context) => Headers() + ), + ); + }, + child: Container( + margin: EdgeInsets.only(top: 23), + decoration: BoxDecoration( +// color:getGFColor( GFColor.dark,), + color: Color(0xFF333333), + borderRadius: BorderRadius.all(Radius.circular(7)), + boxShadow: [ + new BoxShadow( + color: Colors.black.withOpacity(0.61), + blurRadius: 8.0, + spreadRadius: 0.0), + ]), + height: 160, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + SizedBox( + height: 10, + ), + Image.asset('lib/assets/icons/images.png'), + Text( + 'Images', + style: TextStyle( + fontSize: 20, + color: getGFColor( + GFColor.white, + )), + ) + ], + ), + ), + ), + ) + ], + ), + SizedBox( + height: 20, + ), + ], + ), + )); } } diff --git a/demo_app/lib/screens/list-tiles.dart b/demo_app/lib/screens/list-tiles.dart index 32249344..7adc8f33 100644 --- a/demo_app/lib/screens/list-tiles.dart +++ b/demo_app/lib/screens/list-tiles.dart @@ -19,81 +19,89 @@ class _ListTilesState extends State { return Scaffold( appBar: AppBar( backgroundColor: getGFColor(GFColor.dark), - title: Text('List Tile', style: TextStyle(fontSize: 14),), + title: Text( + 'List Tile', + style: TextStyle(fontSize: 14), + ), ), body: ListView( children: [ - - GFCard( - content: GFListTile( - + content: GFListTile( title: GFTypography( text: 'List tile', type: GFTypographyType.typo5, showDivider: false, ), - subTitle: Text('Lorem ipsum', style: TextStyle(color: getGFColor(GFColor.dark)),), - + subTitle: Text( + 'Lorem ipsum', + style: TextStyle(color: getGFColor(GFColor.dark)), + ), showDivider: false, - ), ), - GFCard( - content: GFListTile( - avatar: GFAvatar( - shape: GFAvatarShape.standard, - ), - title: GFTypography( - text: 'List tile', - type: GFTypographyType.typo5, - showDivider: false, - ), - subTitle: Text('Lorem ipsum', style: TextStyle(color: getGFColor(GFColor.dark)),), - - description: Text('Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', - style: TextStyle(fontSize: 13, color: getGFColor(GFColor.secondary))), - showDivider: false, - ), - ), - - GFCard( - content: GFListTile( - - title: GFTypography( - text: 'List tile', - type: GFTypographyType.typo5, - showDivider: false, - ), - subTitle: Text('Lorem ipsum', style: TextStyle(color: getGFColor(GFColor.dark)),), - - description: Text('Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', - style: TextStyle(fontSize: 13, color: getGFColor(GFColor.secondary))), - icon: GFAvatar( - shape: GFAvatarShape.circle, - ), - showDivider: false, - - ), - ), - GFCard( - content: GFListTile( - avatar: GFAvatar( - shape: GFAvatarShape.square, - ), + content: GFListTile( + avatar: GFAvatar( + shape: GFAvatarShape.standard, + ), title: GFTypography( text: 'List tile', type: GFTypographyType.typo5, showDivider: false, ), - subTitle: Text('Lorem ipsum', style: TextStyle(color: getGFColor(GFColor.dark)),), - - description: Text('Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', - style: TextStyle(fontSize: 13, color: getGFColor(GFColor.secondary))), + subTitle: Text( + 'Lorem ipsum', + style: TextStyle(color: getGFColor(GFColor.dark)), + ), + description: Text( + 'Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', + style: TextStyle( + fontSize: 13, color: getGFColor(GFColor.secondary))), + showDivider: false, + ), + ), + GFCard( + content: GFListTile( + title: GFTypography( + text: 'List tile', + type: GFTypographyType.typo5, + showDivider: false, + ), + subTitle: Text( + 'Lorem ipsum', + style: TextStyle(color: getGFColor(GFColor.dark)), + ), + description: Text( + 'Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', + style: TextStyle( + fontSize: 13, color: getGFColor(GFColor.secondary))), + icon: GFAvatar( + shape: GFAvatarShape.circle, + ), + showDivider: false, + ), + ), + GFCard( + content: GFListTile( + avatar: GFAvatar( + shape: GFAvatarShape.square, + ), + title: GFTypography( + text: 'List tile', + type: GFTypographyType.typo5, + showDivider: false, + ), + subTitle: Text( + 'Lorem ipsum', + style: TextStyle(color: getGFColor(GFColor.dark)), + ), + description: Text( + 'Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', + style: TextStyle( + fontSize: 13, color: getGFColor(GFColor.secondary))), icon: GFIconButton(icon: Icon(Icons.share), onPressed: null), showDivider: false, - ), ) ], diff --git a/demo_app/pubspec.lock b/demo_app/pubspec.lock index 57c5df30..91263cf1 100644 --- a/demo_app/pubspec.lock +++ b/demo_app/pubspec.lock @@ -69,6 +69,13 @@ packages: description: flutter source: sdk version: "0.0.0" + flutter_svg: + dependency: "direct main" + description: + name: flutter_svg + url: "https://pub.dartlang.org" + source: hosted + version: "0.15.0" flutter_test: dependency: "direct dev" description: flutter @@ -102,6 +109,20 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.6.4" + path_drawing: + dependency: transitive + description: + name: path_drawing + url: "https://pub.dartlang.org" + source: hosted + version: "0.4.1" + path_parsing: + dependency: transitive + description: + name: path_parsing + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.4" pedantic: dependency: transitive description: @@ -200,3 +221,4 @@ packages: version: "3.5.0" sdks: dart: ">=2.4.0 <3.0.0" + flutter: ">=1.5.9-pre.94 <2.0.0" diff --git a/demo_app/pubspec.yaml b/demo_app/pubspec.yaml index 47d0c1f5..95424a34 100644 --- a/demo_app/pubspec.yaml +++ b/demo_app/pubspec.yaml @@ -1,16 +1,5 @@ name: demo_app description: A new Flutter project. - -# The following defines the version and build number for your application. -# A version number is three numbers separated by dots, like 1.2.43 -# followed by an optional build number separated by a +. -# Both the version and the builder number may be overridden in flutter -# build by specifying --build-name and --build-number, respectively. -# In Android, build-name is used as versionName while build-number used as versionCode. -# Read more about Android versioning at https://developer.android.com/studio/publish/versioning -# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. -# Read more about iOS versioning at -# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html version: 1.0.0+1 environment: @@ -23,6 +12,7 @@ dependencies: path: ../ cupertino_icons: ^0.1.2 + flutter_svg: ^0.15.0 dev_dependencies: flutter_test: @@ -30,3 +20,43 @@ dev_dependencies: flutter: uses-material-design: true + + assets: + - lib/assets/logo/logo.png + - lib/assets/icons/buttons.png + - lib/assets/icons/buttons.svg + - lib/assets/icons/avatar.png + - lib/assets/icons/badge.png + - lib/assets/icons/card.png + - lib/assets/icons/chips.png + - lib/assets/icons/items.png + - lib/assets/icons/lists.png + - lib/assets/icons/menu.png + - lib/assets/icons/slider.png + - lib/assets/icons/tabs.png + - lib/assets/icons/toast.png + - lib/assets/icons/toggle.png + - lib/assets/icons/typo.png + - lib/assets/icons/images.png + - lib/assets/icons/back.png + - lib/assets/icons/next.png + - lib/assets/icons/primary.svg + - lib/assets/icons/secondary.svg + - lib/assets/icons/success.svg + - lib/assets/icons/warning.svg + - lib/assets/icons/danger.svg + - lib/assets/icons/info.svg + - lib/assets/icons/dark.svg + - lib/assets/icons/link.svg + - lib/assets/icons/light.svg + - lib/assets/icons/fb.svg + - lib/assets/icons/twitter.svg + - lib/assets/icons/whatsapp.svg + - lib/assets/icons/google.svg + - lib/assets/icons/dribble.svg + - lib/assets/icons/youtube.svg + - lib/assets/icons/slack.svg + - lib/assets/icons/pinterest.svg + - lib/assets/icons/linkedin.svg + + diff --git a/example/lib/main.dart b/example/lib/main.dart index 97bc01a7..d79cb9f1 100644 --- a/example/lib/main.dart +++ b/example/lib/main.dart @@ -149,8 +149,7 @@ class _MyHomePageState extends State appBar: GFAppBar( backgroundColor: Colors.tealAccent, centerTitle: true, - title: - Text("UI KIT"), + title: Text("UI KIT"), // GFSegmentTabs( // tabController: tabController, // initialIndex: 0, @@ -188,12 +187,11 @@ class _MyHomePageState extends State // Container(color: Colors.green), // Container(color: Colors.blue) // ]), - SingleChildScrollView( + SingleChildScrollView( child: Column( mainAxisAlignment: MainAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center, children: [ - GFCard( content: Column( children: [ @@ -233,67 +231,65 @@ class _MyHomePageState extends State GFCard( content: Column( - crossAxisAlignment: CrossAxisAlignment.center, - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - GFTypography( - text: 'GF Header Typo1', - type: GFTypographyType.typo1, - backgroundImage: NetworkImage( - 'https://cdn.pixabay.com/photo/2019/12/25/16/49/happy-new-year-4718894_960_720.png'), - ), - SizedBox( - height: 40, - ), - GFTypography( - icon: GFAvatar(), - text: 'GF Header Typo2', - type: GFTypographyType.typo2, - dividerColor: GFColor.primary, - dividerAlignment: Alignment.center, - ), - SizedBox( - height: 40, - ), - GFTypography( - icon: Icon(Icons.insert_emoticon), - text: 'GF Header Typo3', - type: GFTypographyType.typo3, - dividerWidth: 150, - dividerColor: GFColor.warning, - dividerBorderRadius: BorderRadius.all(Radius.circular(0)), - ), - SizedBox( - height: 40, - ), - GFTypography( - text: 'GF Header Typo4', - type: GFTypographyType.typo4, - dividerWidth: 345, - icon: Image.network( - 'https://cdn.pixabay.com/photo/2016/12/15/03/27/cocoa-1908020_960_720.jpg', - width: 50, - )), - SizedBox( - height: 40, - ), - GFTypography( - text: 'GF Header Typo5', - type: GFTypographyType.typo5, - dividerColor: GFColor.alt, - ), - SizedBox( - height: 40, - ), - GFTypography( - text: 'GF Header Typo6', - type: GFTypographyType.typo6, - dividerWidth: 20, - ), - ], - )), - - + crossAxisAlignment: CrossAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GFTypography( + text: 'GF Header Typo1', + type: GFTypographyType.typo1, + backgroundImage: NetworkImage( + 'https://cdn.pixabay.com/photo/2019/12/25/16/49/happy-new-year-4718894_960_720.png'), + ), + SizedBox( + height: 40, + ), + GFTypography( + icon: GFAvatar(), + text: 'GF Header Typo2', + type: GFTypographyType.typo2, + dividerColor: GFColor.primary, + dividerAlignment: Alignment.center, + ), + SizedBox( + height: 40, + ), + GFTypography( + icon: Icon(Icons.insert_emoticon), + text: 'GF Header Typo3', + type: GFTypographyType.typo3, + dividerWidth: 150, + dividerColor: GFColor.warning, + dividerBorderRadius: BorderRadius.all(Radius.circular(0)), + ), + SizedBox( + height: 40, + ), + GFTypography( + text: 'GF Header Typo4', + type: GFTypographyType.typo4, + dividerWidth: 345, + icon: Image.network( + 'https://cdn.pixabay.com/photo/2016/12/15/03/27/cocoa-1908020_960_720.jpg', + width: 50, + )), + SizedBox( + height: 40, + ), + GFTypography( + text: 'GF Header Typo5', + type: GFTypographyType.typo5, + dividerColor: GFColor.alt, + ), + SizedBox( + height: 40, + ), + GFTypography( + text: 'GF Header Typo6', + type: GFTypographyType.typo6, + dividerWidth: 20, + ), + ], + )), // GFButton( // onPressed: (){}, @@ -323,7 +319,6 @@ class _MyHomePageState extends State // showDivider: false, ), - GFListTile( avatar: GFAvatar( shape: GFAvatarShape.standard, @@ -333,11 +328,15 @@ class _MyHomePageState extends State type: GFTypographyType.typo5, showDivider: false, ), - subTitle: Text('Lorem ipsum', style: TextStyle(color: getGFColor(GFColor.dark)),), - - description: Text('Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ' + subTitle: Text( + 'Lorem ipsum', + style: TextStyle(color: getGFColor(GFColor.dark)), + ), + description: Text( + 'Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ' 'sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', - style: TextStyle(fontSize: 13, color: getGFColor(GFColor.secondary))), + style: TextStyle( + fontSize: 13, color: getGFColor(GFColor.secondary))), showDivider: true, icon: GFIconButton( onPressed: null, @@ -346,10 +345,8 @@ class _MyHomePageState extends State ), ), - - GFCard( - content: GFListTile( + content: GFListTile( avatar: GFAvatar( shape: GFAvatarShape.standard, ), @@ -358,28 +355,32 @@ class _MyHomePageState extends State type: GFTypographyType.typo5, showDivider: false, ), - subTitle: Text('Lorem ipsum', style: TextStyle(color: getGFColor(GFColor.dark)),), - - description: Text('Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', - style: TextStyle(fontSize: 13, color: getGFColor(GFColor.secondary))), + subTitle: Text( + 'Lorem ipsum', + style: TextStyle(color: getGFColor(GFColor.dark)), + ), + description: Text( + 'Dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ', + style: TextStyle( + fontSize: 13, color: getGFColor(GFColor.secondary))), showDivider: false, ), ), - GFCard( - content: GFImageOverlay( - height: 200.0, - width: MediaQuery.of(context).size.width, - child: Text("Dcs"), + GFCard( + content: GFImageOverlay( + height: 200.0, + width: MediaQuery.of(context).size.width, + child: Text("Dcs"), // color: color ?? cardTheme.color ?? Theme.of(context).cardColor, - image: AssetImage("lib/assets/food.jpeg"), - boxFit: BoxFit.fill, - colorFilter: new ColorFilter.mode(Colors.black.withOpacity(0.67), BlendMode.darken), + image: AssetImage("lib/assets/food.jpeg"), + boxFit: BoxFit.fill, + colorFilter: new ColorFilter.mode( + Colors.black.withOpacity(0.67), BlendMode.darken), // border: border, // borderRadius: borderRadius ?? BorderRadius.all(Radius.circular(4.0)), + ), ), - ), - GFCard( content: Container( @@ -388,15 +389,15 @@ class _MyHomePageState extends State decoration: new BoxDecoration( shape: BoxShape.circle, image: new DecorationImage( - fit: BoxFit.fill, - image: AssetImage("lib/assets/food.jpeg",), - ) - )), + fit: BoxFit.fill, + image: AssetImage( + "lib/assets/food.jpeg", + ), + ))), ), - GFButtonBadge( - onPressed: (){}, + onPressed: () {}, // position: GFPosition.end, // borderSide: BorderSide(color: Colors.pink, width: 1.0, style: BorderStyle.solid), // borderShape: RoundedRectangleBorder(side: BorderSide(color: Colors.pink, width: 2.0, style: BorderStyle.solid), borderRadius: BorderRadius.zero), @@ -900,7 +901,7 @@ class _MyHomePageState extends State // icon: Icon(Icons.ac_unit), // size: GFSize.large, // ), - GFAvatar( + GFAvatar( child: Text("sefv"), size: GFSize.small, ), @@ -981,8 +982,7 @@ class _MyHomePageState extends State ], ), ), - bottomNavigationBar: - GFTabBar( + bottomNavigationBar: GFTabBar( initialIndex: 0, length: 3, controller: tabController, diff --git a/gf_web/.gitignore b/gf_web/.gitignore new file mode 100644 index 00000000..ae1f1838 --- /dev/null +++ b/gf_web/.gitignore @@ -0,0 +1,37 @@ +# Miscellaneous +*.class +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ + +# IntelliJ related +*.iml +*.ipr +*.iws +.idea/ + +# The .vscode folder contains launch configuration and tasks you configure in +# VS Code which you may wish to be included in version control, so this line +# is commented out by default. +#.vscode/ + +# Flutter/Dart/Pub related +**/doc/api/ +.dart_tool/ +.flutter-plugins +.flutter-plugins-dependencies +.packages +.pub-cache/ +.pub/ +/build/ + +# Web related +lib/generated_plugin_registrant.dart + +# Exceptions to above rules. +!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages diff --git a/gf_web/.metadata b/gf_web/.metadata new file mode 100644 index 00000000..361e1e4c --- /dev/null +++ b/gf_web/.metadata @@ -0,0 +1,10 @@ +# This file tracks properties of this Flutter project. +# Used by Flutter tool to assess capabilities and perform upgrades etc. +# +# This file should be version controlled and should not be manually edited. + +version: + revision: 18cd7a3601bcffb36fdf2f679f763b5e827c2e8e + channel: beta + +project_type: app diff --git a/gf_web/README.md b/gf_web/README.md new file mode 100644 index 00000000..f4f9b0c6 --- /dev/null +++ b/gf_web/README.md @@ -0,0 +1,16 @@ +# gf_web + +A new Flutter project. + +## Getting Started + +This project is a starting point for a Flutter application. + +A few resources to get you started if this is your first Flutter project: + +- [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) +- [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) + +For help getting started with Flutter, view our +[online documentation](https://flutter.dev/docs), which offers tutorials, +samples, guidance on mobile development, and a full API reference. diff --git a/gf_web/android/.gitignore b/gf_web/android/.gitignore new file mode 100644 index 00000000..bc2100d8 --- /dev/null +++ b/gf_web/android/.gitignore @@ -0,0 +1,7 @@ +gradle-wrapper.jar +/.gradle +/captures/ +/gradlew +/gradlew.bat +/local.properties +GeneratedPluginRegistrant.java diff --git a/gf_web/android/app/build.gradle b/gf_web/android/app/build.gradle new file mode 100644 index 00000000..0c927f7f --- /dev/null +++ b/gf_web/android/app/build.gradle @@ -0,0 +1,67 @@ +def localProperties = new Properties() +def localPropertiesFile = rootProject.file('local.properties') +if (localPropertiesFile.exists()) { + localPropertiesFile.withReader('UTF-8') { reader -> + localProperties.load(reader) + } +} + +def flutterRoot = localProperties.getProperty('flutter.sdk') +if (flutterRoot == null) { + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") +} + +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') +if (flutterVersionCode == null) { + flutterVersionCode = '1' +} + +def flutterVersionName = localProperties.getProperty('flutter.versionName') +if (flutterVersionName == null) { + flutterVersionName = '1.0' +} + +apply plugin: 'com.android.application' +apply plugin: 'kotlin-android' +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" + +android { + compileSdkVersion 28 + + sourceSets { + main.java.srcDirs += 'src/main/kotlin' + } + + lintOptions { + disable 'InvalidPackage' + } + + defaultConfig { + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). + applicationId "com.example.gf_web" + minSdkVersion 16 + targetSdkVersion 28 + versionCode flutterVersionCode.toInteger() + versionName flutterVersionName + testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" + } + + buildTypes { + release { + // TODO: Add your own signing config for the release build. + // Signing with the debug keys for now, so `flutter run --release` works. + signingConfig signingConfigs.debug + } + } +} + +flutter { + source '../..' +} + +dependencies { + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" + testImplementation 'junit:junit:4.12' + androidTestImplementation 'androidx.test:runner:1.1.1' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1' +} diff --git a/gf_web/android/app/src/debug/AndroidManifest.xml b/gf_web/android/app/src/debug/AndroidManifest.xml new file mode 100644 index 00000000..56702152 --- /dev/null +++ b/gf_web/android/app/src/debug/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/gf_web/android/app/src/main/AndroidManifest.xml b/gf_web/android/app/src/main/AndroidManifest.xml new file mode 100644 index 00000000..048a3923 --- /dev/null +++ b/gf_web/android/app/src/main/AndroidManifest.xml @@ -0,0 +1,30 @@ + + + + + + + + + + + + + diff --git a/gf_web/android/app/src/main/kotlin/com/example/gf_web/MainActivity.kt b/gf_web/android/app/src/main/kotlin/com/example/gf_web/MainActivity.kt new file mode 100644 index 00000000..2735dc9f --- /dev/null +++ b/gf_web/android/app/src/main/kotlin/com/example/gf_web/MainActivity.kt @@ -0,0 +1,12 @@ +package com.example.gf_web + +import androidx.annotation.NonNull; +import io.flutter.embedding.android.FlutterActivity +import io.flutter.embedding.engine.FlutterEngine +import io.flutter.plugins.GeneratedPluginRegistrant + +class MainActivity: FlutterActivity() { + override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) { + GeneratedPluginRegistrant.registerWith(flutterEngine); + } +} diff --git a/gf_web/android/app/src/main/res/drawable/launch_background.xml b/gf_web/android/app/src/main/res/drawable/launch_background.xml new file mode 100644 index 00000000..304732f8 --- /dev/null +++ b/gf_web/android/app/src/main/res/drawable/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/gf_web/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/gf_web/android/app/src/main/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 00000000..db77bb4b Binary files /dev/null and b/gf_web/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/gf_web/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/gf_web/android/app/src/main/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 00000000..17987b79 Binary files /dev/null and b/gf_web/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/gf_web/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/gf_web/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 00000000..09d43914 Binary files /dev/null and b/gf_web/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/gf_web/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/gf_web/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 00000000..d5f1c8d3 Binary files /dev/null and b/gf_web/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/gf_web/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/gf_web/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 00000000..4d6372ee Binary files /dev/null and b/gf_web/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/gf_web/android/app/src/main/res/values/styles.xml b/gf_web/android/app/src/main/res/values/styles.xml new file mode 100644 index 00000000..00fa4417 --- /dev/null +++ b/gf_web/android/app/src/main/res/values/styles.xml @@ -0,0 +1,8 @@ + + + + diff --git a/gf_web/android/app/src/profile/AndroidManifest.xml b/gf_web/android/app/src/profile/AndroidManifest.xml new file mode 100644 index 00000000..56702152 --- /dev/null +++ b/gf_web/android/app/src/profile/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/gf_web/android/build.gradle b/gf_web/android/build.gradle new file mode 100644 index 00000000..3100ad2d --- /dev/null +++ b/gf_web/android/build.gradle @@ -0,0 +1,31 @@ +buildscript { + ext.kotlin_version = '1.3.50' + repositories { + google() + jcenter() + } + + dependencies { + classpath 'com.android.tools.build:gradle:3.5.0' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + } +} + +allprojects { + repositories { + google() + jcenter() + } +} + +rootProject.buildDir = '../build' +subprojects { + project.buildDir = "${rootProject.buildDir}/${project.name}" +} +subprojects { + project.evaluationDependsOn(':app') +} + +task clean(type: Delete) { + delete rootProject.buildDir +} diff --git a/gf_web/android/gradle.properties b/gf_web/android/gradle.properties new file mode 100644 index 00000000..38c8d454 --- /dev/null +++ b/gf_web/android/gradle.properties @@ -0,0 +1,4 @@ +org.gradle.jvmargs=-Xmx1536M +android.enableR8=true +android.useAndroidX=true +android.enableJetifier=true diff --git a/gf_web/android/gradle/wrapper/gradle-wrapper.properties b/gf_web/android/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 00000000..296b146b --- /dev/null +++ b/gf_web/android/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +#Fri Jun 23 08:50:38 CEST 2017 +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip diff --git a/gf_web/android/settings.gradle b/gf_web/android/settings.gradle new file mode 100644 index 00000000..5a2f14fb --- /dev/null +++ b/gf_web/android/settings.gradle @@ -0,0 +1,15 @@ +include ':app' + +def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() + +def plugins = new Properties() +def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') +if (pluginsFile.exists()) { + pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } +} + +plugins.each { name, path -> + def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() + include ":$name" + project(":$name").projectDir = pluginDirectory +} diff --git a/gf_web/ios/.gitignore b/gf_web/ios/.gitignore new file mode 100644 index 00000000..e96ef602 --- /dev/null +++ b/gf_web/ios/.gitignore @@ -0,0 +1,32 @@ +*.mode1v3 +*.mode2v3 +*.moved-aside +*.pbxuser +*.perspectivev3 +**/*sync/ +.sconsign.dblite +.tags* +**/.vagrant/ +**/DerivedData/ +Icon? +**/Pods/ +**/.symlinks/ +profile +xcuserdata +**/.generated/ +Flutter/App.framework +Flutter/Flutter.framework +Flutter/Flutter.podspec +Flutter/Generated.xcconfig +Flutter/app.flx +Flutter/app.zip +Flutter/flutter_assets/ +Flutter/flutter_export_environment.sh +ServiceDefinitions.json +Runner/GeneratedPluginRegistrant.* + +# Exceptions to above rules. +!default.mode1v3 +!default.mode2v3 +!default.pbxuser +!default.perspectivev3 diff --git a/gf_web/ios/Flutter/AppFrameworkInfo.plist b/gf_web/ios/Flutter/AppFrameworkInfo.plist new file mode 100644 index 00000000..6b4c0f78 --- /dev/null +++ b/gf_web/ios/Flutter/AppFrameworkInfo.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + App + CFBundleIdentifier + io.flutter.flutter.app + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + App + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + MinimumOSVersion + 8.0 + + diff --git a/gf_web/ios/Flutter/Debug.xcconfig b/gf_web/ios/Flutter/Debug.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/gf_web/ios/Flutter/Debug.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/gf_web/ios/Flutter/Release.xcconfig b/gf_web/ios/Flutter/Release.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/gf_web/ios/Flutter/Release.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/gf_web/ios/Runner.xcodeproj/project.pbxproj b/gf_web/ios/Runner.xcodeproj/project.pbxproj new file mode 100644 index 00000000..6cd9af51 --- /dev/null +++ b/gf_web/ios/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,518 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; }; + 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; + 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; }; + 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; +/* End PBXBuildFile section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */, + 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */, + ); + name = "Embed Frameworks"; + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; + 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = ""; }; + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; + 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = ""; }; + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 97C146EB1CF9000F007C117D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */, + 3B80C3941E831B6300D905FE /* App.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 9740EEB11CF90186004384FC /* Flutter */ = { + isa = PBXGroup; + children = ( + 3B80C3931E831B6300D905FE /* App.framework */, + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, + 9740EEBA1CF902C7004384FC /* Flutter.framework */, + 9740EEB21CF90195004384FC /* Debug.xcconfig */, + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, + 9740EEB31CF90195004384FC /* Generated.xcconfig */, + ); + name = Flutter; + sourceTree = ""; + }; + 97C146E51CF9000F007C117D = { + isa = PBXGroup; + children = ( + 9740EEB11CF90186004384FC /* Flutter */, + 97C146F01CF9000F007C117D /* Runner */, + 97C146EF1CF9000F007C117D /* Products */, + ); + sourceTree = ""; + }; + 97C146EF1CF9000F007C117D /* Products */ = { + isa = PBXGroup; + children = ( + 97C146EE1CF9000F007C117D /* Runner.app */, + ); + name = Products; + sourceTree = ""; + }; + 97C146F01CF9000F007C117D /* Runner */ = { + isa = PBXGroup; + children = ( + 97C146FA1CF9000F007C117D /* Main.storyboard */, + 97C146FD1CF9000F007C117D /* Assets.xcassets */, + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, + 97C147021CF9000F007C117D /* Info.plist */, + 97C146F11CF9000F007C117D /* Supporting Files */, + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, + ); + path = Runner; + sourceTree = ""; + }; + 97C146F11CF9000F007C117D /* Supporting Files */ = { + isa = PBXGroup; + children = ( + ); + name = "Supporting Files"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 97C146ED1CF9000F007C117D /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + 9740EEB61CF901F6004384FC /* Run Script */, + 97C146EA1CF9000F007C117D /* Sources */, + 97C146EB1CF9000F007C117D /* Frameworks */, + 97C146EC1CF9000F007C117D /* Resources */, + 9705A1C41CF9048500538489 /* Embed Frameworks */, + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Runner; + productName = Runner; + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 97C146E61CF9000F007C117D /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1020; + ORGANIZATIONNAME = "The Chromium Authors"; + TargetAttributes = { + 97C146ED1CF9000F007C117D = { + CreatedOnToolsVersion = 7.3.1; + LastSwiftMigration = 1100; + }; + }; + }; + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 97C146E51CF9000F007C117D; + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 97C146ED1CF9000F007C117D /* Runner */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 97C146EC1CF9000F007C117D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Thin Binary"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin"; + }; + 9740EEB61CF901F6004384FC /* Run Script */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Run Script"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 97C146EA1CF9000F007C117D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C146FB1CF9000F007C117D /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C147001CF9000F007C117D /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 249021D3217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Profile; + }; + 249021D4217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + LIBRARY_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.gfWeb; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Profile; + }; + 97C147031CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 97C147041CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 97C147061CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + LIBRARY_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.gfWeb; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + 97C147071CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + LIBRARY_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.gfWeb; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147031CF9000F007C117D /* Debug */, + 97C147041CF9000F007C117D /* Release */, + 249021D3217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147061CF9000F007C117D /* Debug */, + 97C147071CF9000F007C117D /* Release */, + 249021D4217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 97C146E61CF9000F007C117D /* Project object */; +} diff --git a/gf_web/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/gf_web/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..1d526a16 --- /dev/null +++ b/gf_web/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/gf_web/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/gf_web/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 00000000..a28140cf --- /dev/null +++ b/gf_web/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/gf_web/ios/Runner.xcworkspace/contents.xcworkspacedata b/gf_web/ios/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..1d526a16 --- /dev/null +++ b/gf_web/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/gf_web/ios/Runner/AppDelegate.swift b/gf_web/ios/Runner/AppDelegate.swift new file mode 100644 index 00000000..70693e4a --- /dev/null +++ b/gf_web/ios/Runner/AppDelegate.swift @@ -0,0 +1,13 @@ +import UIKit +import Flutter + +@UIApplicationMain +@objc class AppDelegate: FlutterAppDelegate { + override func application( + _ application: UIApplication, + didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? + ) -> Bool { + GeneratedPluginRegistrant.register(with: self) + return super.application(application, didFinishLaunchingWithOptions: launchOptions) + } +} diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..d36b1fab --- /dev/null +++ b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,122 @@ +{ + "images" : [ + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@3x.png", + "scale" : "3x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@3x.png", + "scale" : "3x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@3x.png", + "scale" : "3x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@2x.png", + "scale" : "2x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@3x.png", + "scale" : "3x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@1x.png", + "scale" : "1x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@1x.png", + "scale" : "1x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@1x.png", + "scale" : "1x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@2x.png", + "scale" : "2x" + }, + { + "size" : "83.5x83.5", + "idiom" : "ipad", + "filename" : "Icon-App-83.5x83.5@2x.png", + "scale" : "2x" + }, + { + "size" : "1024x1024", + "idiom" : "ios-marketing", + "filename" : "Icon-App-1024x1024@1x.png", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png new file mode 100644 index 00000000..dc9ada47 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png new file mode 100644 index 00000000..28c6bf03 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png new file mode 100644 index 00000000..f091b6b0 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png new file mode 100644 index 00000000..4cde1211 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png new file mode 100644 index 00000000..d0ef06e7 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png new file mode 100644 index 00000000..dcdc2306 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png new file mode 100644 index 00000000..c8f9ed8f Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png new file mode 100644 index 00000000..75b2d164 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png new file mode 100644 index 00000000..c4df70d3 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png new file mode 100644 index 00000000..6a84f41e Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png new file mode 100644 index 00000000..d0e1f585 Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json new file mode 100644 index 00000000..0bedcf2f --- /dev/null +++ b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "LaunchImage.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@3x.png", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ diff --git a/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md new file mode 100644 index 00000000..89c2725b --- /dev/null +++ b/gf_web/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md @@ -0,0 +1,5 @@ +# Launch Screen Assets + +You can customize the launch screen with your own desired assets by replacing the image files in this directory. + +You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. \ No newline at end of file diff --git a/gf_web/ios/Runner/Base.lproj/LaunchScreen.storyboard b/gf_web/ios/Runner/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 00000000..f2e259c7 --- /dev/null +++ b/gf_web/ios/Runner/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/gf_web/ios/Runner/Base.lproj/Main.storyboard b/gf_web/ios/Runner/Base.lproj/Main.storyboard new file mode 100644 index 00000000..f3c28516 --- /dev/null +++ b/gf_web/ios/Runner/Base.lproj/Main.storyboard @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/gf_web/ios/Runner/Info.plist b/gf_web/ios/Runner/Info.plist new file mode 100644 index 00000000..f80a85cd --- /dev/null +++ b/gf_web/ios/Runner/Info.plist @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + gf_web + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleSignature + ???? + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UIViewControllerBasedStatusBarAppearance + + + diff --git a/gf_web/ios/Runner/Runner-Bridging-Header.h b/gf_web/ios/Runner/Runner-Bridging-Header.h new file mode 100644 index 00000000..7335fdf9 --- /dev/null +++ b/gf_web/ios/Runner/Runner-Bridging-Header.h @@ -0,0 +1 @@ +#import "GeneratedPluginRegistrant.h" \ No newline at end of file diff --git a/gf_web/lib/assets/icons/avatar.png b/gf_web/lib/assets/icons/avatar.png new file mode 100644 index 00000000..685ad1a3 Binary files /dev/null and b/gf_web/lib/assets/icons/avatar.png differ diff --git a/gf_web/lib/assets/icons/back.png b/gf_web/lib/assets/icons/back.png new file mode 100644 index 00000000..6c90e89b Binary files /dev/null and b/gf_web/lib/assets/icons/back.png differ diff --git a/gf_web/lib/assets/icons/badge.png b/gf_web/lib/assets/icons/badge.png new file mode 100644 index 00000000..5d233517 Binary files /dev/null and b/gf_web/lib/assets/icons/badge.png differ diff --git a/gf_web/lib/assets/icons/buttons.png b/gf_web/lib/assets/icons/buttons.png new file mode 100644 index 00000000..d7cf8870 Binary files /dev/null and b/gf_web/lib/assets/icons/buttons.png differ diff --git a/gf_web/lib/assets/icons/buttons.svg b/gf_web/lib/assets/icons/buttons.svg new file mode 100644 index 00000000..415c67d3 --- /dev/null +++ b/gf_web/lib/assets/icons/buttons.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/gf_web/lib/assets/icons/card.png b/gf_web/lib/assets/icons/card.png new file mode 100644 index 00000000..79543ea6 Binary files /dev/null and b/gf_web/lib/assets/icons/card.png differ diff --git a/gf_web/lib/assets/icons/chips.png b/gf_web/lib/assets/icons/chips.png new file mode 100644 index 00000000..99b08372 Binary files /dev/null and b/gf_web/lib/assets/icons/chips.png differ diff --git a/gf_web/lib/assets/icons/danger.svg b/gf_web/lib/assets/icons/danger.svg new file mode 100644 index 00000000..dea91e14 --- /dev/null +++ b/gf_web/lib/assets/icons/danger.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/dark.svg b/gf_web/lib/assets/icons/dark.svg new file mode 100644 index 00000000..a5e5eb1b --- /dev/null +++ b/gf_web/lib/assets/icons/dark.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/dribble.svg b/gf_web/lib/assets/icons/dribble.svg new file mode 100644 index 00000000..dbaca3b1 --- /dev/null +++ b/gf_web/lib/assets/icons/dribble.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/fb.svg b/gf_web/lib/assets/icons/fb.svg new file mode 100644 index 00000000..e6078c98 --- /dev/null +++ b/gf_web/lib/assets/icons/fb.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/google.svg b/gf_web/lib/assets/icons/google.svg new file mode 100644 index 00000000..d837859e --- /dev/null +++ b/gf_web/lib/assets/icons/google.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/images.png b/gf_web/lib/assets/icons/images.png new file mode 100644 index 00000000..b5e4cb02 Binary files /dev/null and b/gf_web/lib/assets/icons/images.png differ diff --git a/gf_web/lib/assets/icons/info.svg b/gf_web/lib/assets/icons/info.svg new file mode 100644 index 00000000..21fd193c --- /dev/null +++ b/gf_web/lib/assets/icons/info.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/items.png b/gf_web/lib/assets/icons/items.png new file mode 100644 index 00000000..1a495321 Binary files /dev/null and b/gf_web/lib/assets/icons/items.png differ diff --git a/gf_web/lib/assets/icons/light.svg b/gf_web/lib/assets/icons/light.svg new file mode 100644 index 00000000..bf6f73a6 --- /dev/null +++ b/gf_web/lib/assets/icons/light.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/link.svg b/gf_web/lib/assets/icons/link.svg new file mode 100644 index 00000000..9260d523 --- /dev/null +++ b/gf_web/lib/assets/icons/link.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/linkedin.svg b/gf_web/lib/assets/icons/linkedin.svg new file mode 100644 index 00000000..7adb1746 --- /dev/null +++ b/gf_web/lib/assets/icons/linkedin.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/lists.png b/gf_web/lib/assets/icons/lists.png new file mode 100644 index 00000000..e3e93174 Binary files /dev/null and b/gf_web/lib/assets/icons/lists.png differ diff --git a/gf_web/lib/assets/icons/menu.png b/gf_web/lib/assets/icons/menu.png new file mode 100644 index 00000000..0932d5f5 Binary files /dev/null and b/gf_web/lib/assets/icons/menu.png differ diff --git a/gf_web/lib/assets/icons/next.png b/gf_web/lib/assets/icons/next.png new file mode 100644 index 00000000..8d3c89d9 Binary files /dev/null and b/gf_web/lib/assets/icons/next.png differ diff --git a/gf_web/lib/assets/icons/pinterest.svg b/gf_web/lib/assets/icons/pinterest.svg new file mode 100644 index 00000000..7aa538e1 --- /dev/null +++ b/gf_web/lib/assets/icons/pinterest.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/primary.svg b/gf_web/lib/assets/icons/primary.svg new file mode 100644 index 00000000..c2ad37e4 --- /dev/null +++ b/gf_web/lib/assets/icons/primary.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/secondary.svg b/gf_web/lib/assets/icons/secondary.svg new file mode 100644 index 00000000..56c06ebe --- /dev/null +++ b/gf_web/lib/assets/icons/secondary.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/slack.svg b/gf_web/lib/assets/icons/slack.svg new file mode 100644 index 00000000..ed08c2a0 --- /dev/null +++ b/gf_web/lib/assets/icons/slack.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/slider.png b/gf_web/lib/assets/icons/slider.png new file mode 100644 index 00000000..03fb809b Binary files /dev/null and b/gf_web/lib/assets/icons/slider.png differ diff --git a/gf_web/lib/assets/icons/success.svg b/gf_web/lib/assets/icons/success.svg new file mode 100644 index 00000000..b06b4ae5 --- /dev/null +++ b/gf_web/lib/assets/icons/success.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/tabs.png b/gf_web/lib/assets/icons/tabs.png new file mode 100644 index 00000000..49678a20 Binary files /dev/null and b/gf_web/lib/assets/icons/tabs.png differ diff --git a/gf_web/lib/assets/icons/toast.png b/gf_web/lib/assets/icons/toast.png new file mode 100644 index 00000000..44ee2d77 Binary files /dev/null and b/gf_web/lib/assets/icons/toast.png differ diff --git a/gf_web/lib/assets/icons/toggle.png b/gf_web/lib/assets/icons/toggle.png new file mode 100644 index 00000000..f33816f9 Binary files /dev/null and b/gf_web/lib/assets/icons/toggle.png differ diff --git a/gf_web/lib/assets/icons/twitter.svg b/gf_web/lib/assets/icons/twitter.svg new file mode 100644 index 00000000..ac962749 --- /dev/null +++ b/gf_web/lib/assets/icons/twitter.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/typo.png b/gf_web/lib/assets/icons/typo.png new file mode 100644 index 00000000..90592362 Binary files /dev/null and b/gf_web/lib/assets/icons/typo.png differ diff --git a/gf_web/lib/assets/icons/warning.svg b/gf_web/lib/assets/icons/warning.svg new file mode 100644 index 00000000..aae2b731 --- /dev/null +++ b/gf_web/lib/assets/icons/warning.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/gf_web/lib/assets/icons/whatsapp.svg b/gf_web/lib/assets/icons/whatsapp.svg new file mode 100644 index 00000000..992ff345 --- /dev/null +++ b/gf_web/lib/assets/icons/whatsapp.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/icons/youtube.svg b/gf_web/lib/assets/icons/youtube.svg new file mode 100644 index 00000000..b2503883 --- /dev/null +++ b/gf_web/lib/assets/icons/youtube.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/gf_web/lib/assets/logo.png b/gf_web/lib/assets/logo.png new file mode 100644 index 00000000..27e5cae0 Binary files /dev/null and b/gf_web/lib/assets/logo.png differ diff --git a/gf_web/lib/assets/screen.png b/gf_web/lib/assets/screen.png new file mode 100644 index 00000000..54aed019 Binary files /dev/null and b/gf_web/lib/assets/screen.png differ diff --git a/gf_web/lib/main.dart b/gf_web/lib/main.dart new file mode 100644 index 00000000..c06d0f7f --- /dev/null +++ b/gf_web/lib/main.dart @@ -0,0 +1,110 @@ +import 'package:flutter/material.dart'; +import 'package:gf_web/screens/pages/home.dart'; +import 'screens/layout/routes.dart'; + + +void main() => runApp(MyApp()); + +class MyApp extends StatelessWidget { + // This widget is the root of your application. + + @override + Widget build(BuildContext context) { + return MaterialApp( + title: 'Flutter Demo', + debugShowCheckedModeBanner: false, + + theme: ThemeData( + primarySwatch: Colors.blue, + ), + home: HomePage(), + + initialRoute: "/", +routes: routes, + ); + } +} + + +class FirstScreen extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text('First Screen'), + ), + body: Center( + child: RaisedButton( + child: Text('Launch screen'), + onPressed: () { + // Navigate to the second screen using a named route. + Navigator.pushNamed(context, '/second'); + }, + ), + ), + ); + } +} + +class SecondScreen extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text("Second Screen"), + ), + body: Center( + child: RaisedButton( + onPressed: () { + // Navigate back to the first screen by popping the current route + // off the stack. + Navigator.pushNamed(context, '/third'); + }, + child: Text('Third!'), + ), + ), + ); + } +} + +class ThirdScreen extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text("3 Screen"), + ), + body: Center( + child: RaisedButton( + onPressed: () { + // Navigate back to the first screen by popping the current route + // off the stack. + Navigator.pushNamed(context, '/fourth'); + }, + child: Text('Fourth!'), + ), + ), + ); + } +} + +class FourthScreen extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text("4 Screen"), + ), + body: Center( + child: RaisedButton( + onPressed: () { + // Navigate back to the first screen by popping the current route + // off the stack. + Navigator.pushNamed(context, '/'); + }, + child: Text('Go back!'), + ), + ), + ); + } +} \ No newline at end of file diff --git a/gf_web/lib/screens/buttons/standard-buttons.dart b/gf_web/lib/screens/buttons/standard-buttons.dart new file mode 100644 index 00000000..a6d8eac3 --- /dev/null +++ b/gf_web/lib/screens/buttons/standard-buttons.dart @@ -0,0 +1,442 @@ +import 'package:flutter/material.dart'; +import 'package:gf_web/screens/layout/layout.dart'; +import '../../styles/styles.dart'; +import 'package:ui_kit/components/button/gf_button.dart'; +import 'package:ui_kit/components/card/gf_card.dart'; +import 'package:ui_kit/colors/gf_color.dart'; +import 'package:ui_kit/types/gf_type.dart'; +import 'package:ui_kit/size/gf_size.dart'; + +class StandardButtons extends StatefulWidget { + @override + _StandardButtonsState createState() => _StandardButtonsState(); +} + +class _StandardButtonsState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + body: Layout( + body: ListView( + children: [ + Text('Standard Buttons', style: hintStyleTextblackbolder(),), + SizedBox( + height: 20, + ), + Text('Buttons of type Standard which comes in different sizes that can be used in forms, alerts, and more...', style: hintStyleTextblackdull(),), + SizedBox( + height: 30, + ), + Text('Solid Buttons', style: hintStyleTextblackbold(),), + GFCard( + content: Column( + children: [ + Row( + children: [ + Expanded(child: GFButton( + onPressed: (){}, + text: 'Primary', + textColor: Colors.white, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Primary', + textColor: Colors.white, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Primary', + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Secondary', + color: GFColor.secondary, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Success', + color: GFColor.success, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Warning', + color: GFColor.warning, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'danger', + color: GFColor.danger, + )) + ], + ), +SizedBox( + height: 20, +), + Row( + children: [ + Expanded(child: GFButton( + onPressed: (){}, + text: 'Info', + color: GFColor.info, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Light', + color: GFColor.light, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Dark', + color: GFColor.dark, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Link', + color: GFColor.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: Text('')) + + ], + ), + + ], + ), + ), + SizedBox( + height: 20, + ), + + Text('Disabled Buttons', style: hintStyleTextblackbold(),), + GFCard( + content: Column( + children: [ + Row( + children: [ + Expanded(child: GFButton( + onPressed:null, + text: 'Primary', + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Secondary', + color: GFColor.secondary, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Success', + color: GFColor.success, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Warning', + color: GFColor.warning, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'danger', + color: GFColor.danger, + )) + ], + ), + SizedBox( + height: 20, + ), + Row( + children: [ + Expanded(child: GFButton( + onPressed:null, + text: 'Info', + color: GFColor.info, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Light', + color: GFColor.light, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Dark', + color: GFColor.dark, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Link', + color: GFColor.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: Text('')) + + ], + ), + + ], + ), + ), + + SizedBox( + height: 20, + ), + + Text('Transparent Buttons', style: hintStyleTextblackbold(),), + GFCard( + content: Column( + children: [ + Row( + children: [ + Expanded(child: GFButton( + onPressed:null, + text: 'Primary', + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Secondary', + color: GFColor.secondary, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Success', + color: GFColor.success, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Warning', + color: GFColor.warning, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'danger', + color: GFColor.danger, + type: GFType.transparent, + )) + ], + ), + SizedBox( + height: 20, + ), + Row( + children: [ + Expanded(child: GFButton( + onPressed:null, + text: 'Info', + color: GFColor.info, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Light', + color: GFColor.light, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed:null, + text: 'Dark', + color: GFColor.dark, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: GFButton( + onPressed: (){}, + text: 'Link', + color: GFColor.transparent, + type: GFType.transparent, + )), + SizedBox( + width: 10, + ), + Expanded(child: Text('')) + + ], + ), + + ], + ), + ), + SizedBox( + height: 20, + ), + + Text(' Button Sizes', style: hintStyleTextblackbold(),), + GFCard( + content: Column( + children: [ + Row( + children: [ + Expanded(child:GFButton( + onPressed: (){}, + child: Text("Large", + ), + + size: GFSize.large, + ), + ), + SizedBox( + width: 10, + ), + Expanded(child:GFButton( + onPressed: (){}, + child: Text("Medium", + ), + size: GFSize.medium, + ), + ), + SizedBox( + width: 10, + ), + Expanded(child:GFButton( + onPressed: (){}, + child: Text("Small", + ), + size: GFSize.small, + ), + ), + + ], + ), + + + ], + ), + ), + + SizedBox( + height: 20, + ), + + Text(' Block Buttons', style: hintStyleTextblackbold(),), + GFCard( + content: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + height: 10, + ), + GFButton( + onPressed: (){}, + blockButton: true, + child: Text("Large", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.large, + ), + + SizedBox( + height: 10, + ), + + GFButton( + onPressed: (){}, + blockButton: true, + child: Text("Normal", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.medium, + ), + + SizedBox( + height: 10, + ), + + + GFButton( + onPressed: (){}, + blockButton: true, + child: Text("Small", + style: TextStyle( + color: getGFColor(GFColor.white))), + color: GFColor.primary, + size: GFSize.small, + ), + SizedBox( + height: 10, + ), + + ], + ), + + ) + ], + ), + ), + ); + } +} diff --git a/gf_web/lib/screens/layout/body.dart b/gf_web/lib/screens/layout/body.dart new file mode 100644 index 00000000..f56ad48a --- /dev/null +++ b/gf_web/lib/screens/layout/body.dart @@ -0,0 +1,23 @@ +import 'package:flutter/material.dart'; + +class Body extends StatefulWidget { + @override + _BodyState createState() => _BodyState(); +} + +class _BodyState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Colors.white, + body:Container( + margin: EdgeInsets.only(left: 40, top: 20), + child: ListView( + children: [ + Text('dfcghyjunkm') + ], + ), + ) + ); + } +} diff --git a/gf_web/lib/screens/layout/header.dart b/gf_web/lib/screens/layout/header.dart new file mode 100644 index 00000000..c9797ff1 --- /dev/null +++ b/gf_web/lib/screens/layout/header.dart @@ -0,0 +1,45 @@ +import 'package:flutter/material.dart'; + +class Header extends StatefulWidget { + @override + _HeaderState createState() => _HeaderState(); +} + +class _HeaderState extends State
{ + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Colors.white, + body: Container( + color: Colors.black, + width: MediaQuery.of(context).size.width, + height: 100, + child: Row( +// mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Flexible( + fit: FlexFit.tight, + flex: 6, +// child: Image.asset('lib/assets/logo.png') + child: Image.network('https://ik.imagekit.io/ionicfirebaseapp/get-flutter-logo_FAN-82xCG.png', height: 40.0,), + ), + Flexible( + fit: FlexFit.tight, + flex: 8, + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Text('Home', style: TextStyle(fontSize: 17, color: Colors.white, fontWeight: FontWeight.w600),), + Text('Features', style: TextStyle(fontSize: 17, color: Colors.white, fontWeight: FontWeight.w600),), + Text('Docs', style: TextStyle(fontSize: 17, color: Colors.white, fontWeight: FontWeight.w600),), + Text('Blog', style: TextStyle(fontSize: 17, color: Colors.white, fontWeight: FontWeight.w600),), + Text('Contact', style: TextStyle(fontSize: 17, color: Colors.white, fontWeight: FontWeight.w600),) + ], + )) + ], + ), + + ), + ); + } +} diff --git a/gf_web/lib/screens/layout/layout.dart b/gf_web/lib/screens/layout/layout.dart new file mode 100644 index 00000000..bfdf59d2 --- /dev/null +++ b/gf_web/lib/screens/layout/layout.dart @@ -0,0 +1,53 @@ +import 'package:flutter/material.dart'; +import 'package:gf_web/screens/layout/mobile-demo.dart'; +import 'sidebar.dart'; +import 'header.dart'; +import 'body.dart'; + +class Layout extends StatefulWidget { + final Widget body; + const Layout ({Key key, + this.body, + }):super(key:key); + + @override + _LayoutState createState() => _LayoutState(); +} + +class _LayoutState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Colors.white, + body: Column( + children: [ + Container( + height: 70, + child: Header(), + ), + Row( + children: [ + Container( + height: MediaQuery.of(context).size.height-70, + width: 300, + child: Sidebar(), + ), + Container( + padding: EdgeInsets.only(top: 20, left: 20, right: 20), + height:MediaQuery.of(context).size.height -70, + width: MediaQuery.of(context).size.width -730, + child: widget.body + ), + Container( + width: 430, +// color: Colors.red, + height: 600, + child: MobileDemo(), + ) + ], + ) + ], + ), + ); + } +} diff --git a/gf_web/lib/screens/layout/mobile-demo.dart b/gf_web/lib/screens/layout/mobile-demo.dart new file mode 100644 index 00000000..e7e0c21a --- /dev/null +++ b/gf_web/lib/screens/layout/mobile-demo.dart @@ -0,0 +1,16 @@ +import 'package:flutter/material.dart'; + +class MobileDemo extends StatefulWidget { + @override + _MobileDemoState createState() => _MobileDemoState(); +} + +class _MobileDemoState extends State { + @override + Widget build(BuildContext context) { + return Container( + height: 300, + child: Image.asset('lib/assets/screen.png'), + ); + } +} diff --git a/gf_web/lib/screens/layout/routes.dart b/gf_web/lib/screens/layout/routes.dart new file mode 100644 index 00000000..a2ef37f1 --- /dev/null +++ b/gf_web/lib/screens/layout/routes.dart @@ -0,0 +1,15 @@ + + + +import 'package:gf_web/screens/buttons/standard-buttons.dart'; +import 'package:gf_web/screens/pages/home.dart'; + + +//Map route = Map(); + +final routes = + { + '/gf-buttons/standard-button': (context) => StandardButtons(), +// '/third': (context) => ThirdScreen(), +// '/fourth':(context) => FourthScreen() + }; diff --git a/gf_web/lib/screens/layout/sidebar.dart b/gf_web/lib/screens/layout/sidebar.dart new file mode 100644 index 00000000..b3dc8934 --- /dev/null +++ b/gf_web/lib/screens/layout/sidebar.dart @@ -0,0 +1,236 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:gf_web/styles/styles.dart'; + +class Sidebar extends StatefulWidget { + @override + _SidebarState createState() => _SidebarState(); +} + +class _SidebarState extends State with TickerProviderStateMixin { + Animation animation; + AnimationController animationController; + AnimationController controller; + Animation offset; + + + @override + void initState() { + super.initState(); + animationController = AnimationController(duration: Duration(seconds: 2), vsync: this); + controller = AnimationController(vsync: this, duration: Duration(milliseconds: 300)); + offset = Tween(begin: Offset.zero, end: Offset(0.0, 0.1),).animate(controller); +// animation = Tween(begin: 1.0, end: 0.0).animate(CurvedAnimation(parent: animationController, curve: Curves.fastLinearToSlowEaseIn)); + } + + + + bool showButtonTypes = false; + @override + Widget build(BuildContext context) { + return Scaffold( + body: Container( +margin: EdgeInsets.only(right: 10,), + padding: EdgeInsets.only(left:60, right: 20, top:30), + width: 300, + height: MediaQuery.of(context).size.height, + decoration: BoxDecoration( + border: Border.all( + color: Colors.black.withOpacity(0.30) + ), + color: Colors.white, + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40), + blurRadius: 5.0 + ), + ] + ), + child: ListView( + children: [ + + Text('COMPONENTS', style: hintStyleTextblack(),), + SizedBox( + height: 25, + ), + GestureDetector( + onTap: (){ + setState(() { + switch (controller.status) { + case AnimationStatus.completed: + controller.forward(from: 0); + break; + case AnimationStatus.dismissed: + controller.forward(); + break; + default: + } + showButtonTypes = !showButtonTypes; + }); + + }, + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Text('GF Buttons', style: hintStyleTextblackdull()), + showButtonTypes? Icon(Icons.keyboard_arrow_down): Icon(Icons.keyboard_arrow_right) + ], + ) + ), + showButtonTypes? + SlideTransition( + position: offset, + child: Container( + height: 200, + decoration: BoxDecoration( + color: Colors.white, + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.40) + ) + ] + ), + padding: EdgeInsets.only(top:0, bottom: 30, left: 25, right: 20), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + GestureDetector( + onTap: (){ + Navigator.pushNamed(context, '/gf-buttons/standard-button'); + }, + child: Text('Standard Buttons'), + ), + Text('Pills Buttons'), + Text('Square Buttons'), + Text('Shadow Buttons'), + Text('Icon Buttons'), + Text('Social Buttons') + ], + ), + ), + ):Container(), + + SizedBox( + height: 20, + ), + + Text('GF Badge', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Avatar', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Image', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Card', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Slider', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Tile', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Tab', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Typography', style: hintStyleTextblackdull()), + SizedBox( + height: 30, + ), + Text('COMING SOON', style: hintStyleTextblack(),), + SizedBox( + height: 25, + ), + Text('GF Forms', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Chip', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + + Text('GF List', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Spinner', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Header', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Footer', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Toggle', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Drawer', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Accordian', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Toast', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Alert', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Model', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Action Sheet', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Floating Button', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Popover', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Recorder', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Infinite Scroll', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Searchbar', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + Text('GF Refresher', style: hintStyleTextblackdull()), + SizedBox( + height: 20, + ), + ], + ), + ), + ); + } +} diff --git a/gf_web/lib/screens/pages/home.dart b/gf_web/lib/screens/pages/home.dart new file mode 100644 index 00000000..c26544f9 --- /dev/null +++ b/gf_web/lib/screens/pages/home.dart @@ -0,0 +1,33 @@ +import 'package:flutter/material.dart'; +import 'package:gf_web/screens/layout/layout.dart'; + + +class HomePage extends StatefulWidget { + @override + _HomePageState createState() => _HomePageState(); +} + +class _HomePageState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Colors.white, + body: Layout( + body: Column( + children: [ + Text('Introduction', style: TextStyle(fontSize: 20),), + SizedBox( + height: 20, + ), + Text('GetFlutter is UI libraries for building flutter app.', style: TextStyle(fontSize: 20),), + SizedBox( + height: 20, + ), + Image.network('https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LvKegU8SBuWnETMfqrz%2F-LxtgL3yw3epnXU4dni3%2F-LxtgsMugSV2jttI5pTC%2FButtons%403x.png?alt=media&token=54a7ad05-716d-4cd2-84f7-78e2697fbdec', + height: 600,) + ], + ) + ) + ); + } +} \ No newline at end of file diff --git a/gf_web/lib/styles/styles.dart b/gf_web/lib/styles/styles.dart new file mode 100644 index 00000000..7490beba --- /dev/null +++ b/gf_web/lib/styles/styles.dart @@ -0,0 +1,42 @@ +import 'package:flutter/material.dart'; + +final primary = const Color(0xff19CA4B); +final secondary = const Color(0xFFFF7644); +final blacktext = const Color(0xFF0D0D0D); +final blackdull = const Color(0xFFbababa); + + + +//.............................................RalewayRegular................................................................................... + +TextStyle hintStyleTextblackdull() { + return TextStyle( + fontWeight: FontWeight.w500, + fontSize: 16.0, + color: blacktext.withOpacity(0.60), + ); +} + +TextStyle hintStyleTextblack() { + return TextStyle( + fontWeight: FontWeight.w500, + fontSize: 17.0, + color: blacktext, + ); +} + +TextStyle hintStyleTextblackbold() { + return TextStyle( + fontWeight: FontWeight.w600, + fontSize: 23.0, + color: blacktext, + ); +} + +TextStyle hintStyleTextblackbolder() { + return TextStyle( + fontWeight: FontWeight.w600, + fontSize: 26.0, + color: blacktext, + ); +} \ No newline at end of file diff --git a/gf_web/pubspec.lock b/gf_web/pubspec.lock new file mode 100644 index 00000000..c6869e31 --- /dev/null +++ b/gf_web/pubspec.lock @@ -0,0 +1,202 @@ +# Generated by pub +# See https://dart.dev/tools/pub/glossary#lockfile +packages: + archive: + dependency: transitive + description: + name: archive + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.11" + args: + dependency: transitive + description: + name: args + url: "https://pub.dartlang.org" + source: hosted + version: "1.5.2" + async: + dependency: transitive + description: + name: async + url: "https://pub.dartlang.org" + source: hosted + version: "2.4.0" + boolean_selector: + dependency: transitive + description: + name: boolean_selector + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" + charcode: + dependency: transitive + description: + name: charcode + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.2" + collection: + dependency: transitive + description: + name: collection + url: "https://pub.dartlang.org" + source: hosted + version: "1.14.11" + convert: + dependency: transitive + description: + name: convert + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.1" + crypto: + dependency: transitive + description: + name: crypto + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.3" + cupertino_icons: + dependency: "direct main" + description: + name: cupertino_icons + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.3" + flutter: + dependency: "direct main" + description: flutter + source: sdk + version: "0.0.0" + flutter_test: + dependency: "direct dev" + description: flutter + source: sdk + version: "0.0.0" + image: + dependency: transitive + description: + name: image + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.4" + matcher: + dependency: transitive + description: + name: matcher + url: "https://pub.dartlang.org" + source: hosted + version: "0.12.6" + meta: + dependency: transitive + description: + name: meta + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.8" + path: + dependency: transitive + description: + name: path + url: "https://pub.dartlang.org" + source: hosted + version: "1.6.4" + pedantic: + dependency: transitive + description: + name: pedantic + url: "https://pub.dartlang.org" + source: hosted + version: "1.8.0+1" + petitparser: + dependency: transitive + description: + name: petitparser + url: "https://pub.dartlang.org" + source: hosted + version: "2.4.0" + quiver: + dependency: transitive + description: + name: quiver + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.5" + sky_engine: + dependency: transitive + description: flutter + source: sdk + version: "0.0.99" + source_span: + dependency: transitive + description: + name: source_span + url: "https://pub.dartlang.org" + source: hosted + version: "1.5.5" + stack_trace: + dependency: transitive + description: + name: stack_trace + url: "https://pub.dartlang.org" + source: hosted + version: "1.9.3" + stream_channel: + dependency: transitive + description: + name: stream_channel + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.0" + string_scanner: + dependency: transitive + description: + name: string_scanner + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" + term_glyph: + dependency: transitive + description: + name: term_glyph + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.0" + test_api: + dependency: transitive + description: + name: test_api + url: "https://pub.dartlang.org" + source: hosted + version: "0.2.11" + typed_data: + dependency: transitive + description: + name: typed_data + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.6" + ui_kit: + dependency: "direct dev" + description: + path: ".." + relative: true + source: path + version: "0.0.1" + vector_math: + dependency: transitive + description: + name: vector_math + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.8" + xml: + dependency: transitive + description: + name: xml + url: "https://pub.dartlang.org" + source: hosted + version: "3.5.0" +sdks: + dart: ">=2.4.0 <3.0.0" diff --git a/gf_web/pubspec.yaml b/gf_web/pubspec.yaml new file mode 100644 index 00000000..7f4c2c0d --- /dev/null +++ b/gf_web/pubspec.yaml @@ -0,0 +1,26 @@ +name: gf_web +description: A new Flutter project. + +version: 1.0.0+1 + +environment: + sdk: ">=2.1.0 <3.0.0" + +dependencies: + flutter: + sdk: flutter + cupertino_icons: ^0.1.2 + +dev_dependencies: + flutter_test: + sdk: flutter + ui_kit: + path: ../ + +flutter: + uses-material-design: true + + assets: + - lib/assets/logo.png + - lib/assets/icons/next.png + - lib/assets/screen.png diff --git a/gf_web/test/widget_test.dart b/gf_web/test/widget_test.dart new file mode 100644 index 00000000..e89b8c9e --- /dev/null +++ b/gf_web/test/widget_test.dart @@ -0,0 +1,30 @@ +// This is a basic Flutter widget test. +// +// To perform an interaction with a widget in your test, use the WidgetTester +// utility that Flutter provides. For example, you can send tap and scroll +// gestures. You can also use WidgetTester to find child widgets in the widget +// tree, read text, and verify that the values of widget properties are correct. + +import 'package:flutter/material.dart'; +import 'package:flutter_test/flutter_test.dart'; + +import 'package:gf_web/main.dart'; + +void main() { + testWidgets('Counter increments smoke test', (WidgetTester tester) async { + // Build our app and trigger a frame. + await tester.pumpWidget(MyApp()); + + // Verify that our counter starts at 0. + expect(find.text('0'), findsOneWidget); + expect(find.text('1'), findsNothing); + + // Tap the '+' icon and trigger a frame. + await tester.tap(find.byIcon(Icons.add)); + await tester.pump(); + + // Verify that our counter has incremented. + expect(find.text('0'), findsNothing); + expect(find.text('1'), findsOneWidget); + }); +} diff --git a/gf_web/web/index.html b/gf_web/web/index.html new file mode 100644 index 00000000..3f15ee61 --- /dev/null +++ b/gf_web/web/index.html @@ -0,0 +1,10 @@ + + + + + gf_web + + + + + diff --git a/lib/components/list_tile/gf_list_tile.dart b/lib/components/list_tile/gf_list_tile.dart index 729a7beb..3062478a 100644 --- a/lib/components/list_tile/gf_list_tile.dart +++ b/lib/components/list_tile/gf_list_tile.dart @@ -1,5 +1,6 @@ import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; +import 'package:ui_kit/colors/gf_color.dart'; import 'package:ui_kit/components/avatar/gf_avatar.dart'; class GFListTile extends StatelessWidget { @@ -80,27 +81,25 @@ class GFListTile extends StatelessWidget { this.color, this.avatar, this.title, - this.subTitle , - this.description , + this.subTitle, + this.description, this.icon, this.showDivider = true, - this.padding, - this.trailing, - this.dividerEndIndent, - this.dividerHeight, - this.dividerIndent, - this.dividerThickness, - this.dividerColor - }) + this.padding, + this.trailing, + this.dividerEndIndent, + this.dividerHeight, + this.dividerIndent, + this.dividerThickness, + this.dividerColor}) : super(key: key); @override Widget build(BuildContext context) { - - final double height = this.dividerHeight ?? 16.0; - final double thickness = this.dividerThickness ?? 0.0; - final double indent = this.dividerIndent ?? 0.0; - final double endIndent = this.dividerEndIndent ?? 0.0; + final double height = this.dividerHeight ?? 16.0; + final double thickness = this.dividerThickness ?? 0.0; + final double indent = this.dividerIndent ?? 0.0; + final double endIndent = this.dividerEndIndent ?? 0.0; return Column( crossAxisAlignment: CrossAxisAlignment.start, @@ -111,31 +110,34 @@ class GFListTile extends StatelessWidget { child: ListTile( leading: avatar, title: title, - subtitle: subTitle != null || description != null ? Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - subTitle ?? Container(), - description ?? Container() - ], - ): null, - trailing: icon != null ? Column( - children: [ - Padding(padding: EdgeInsets.only(top: 16.0), child: - icon ) - ], - ): null - ), + subtitle: subTitle != null || description != null + ? Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + subTitle ?? Container(), + description ?? Container() + ], + ) + : null, + trailing: icon != null + ? Column( + children: [ + Padding( + padding: EdgeInsets.only(top: 16.0), child: icon) + ], + ) + : null), ), - - showDivider ? - Divider( - height: height ?? dividerHeight, - thickness: thickness ?? dividerThickness, - color: dividerColor ?? Theme.of(context).dividerColor, - indent: indent ?? dividerIndent, - endIndent: endIndent ?? dividerEndIndent, - ) : Container() + showDivider + ? Divider( + height: height ?? dividerHeight, + thickness: thickness ?? dividerThickness, + color: dividerColor ?? Theme.of(context).dividerColor, + indent: indent ?? dividerIndent, + endIndent: endIndent ?? dividerEndIndent, + ) + : Container() ], ); } -} \ No newline at end of file +}