Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Igor Katsuba
committed
Nov 16, 2018
1 parent
d560419
commit f2e7611
Showing
14 changed files
with
349 additions
and
228 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import 'package:flutter/material.dart'; | ||
import './fn_title.dart'; | ||
|
||
class FnBar extends StatelessWidget implements PreferredSizeWidget { | ||
final Widget title; | ||
final List<Widget> actions; | ||
final bool automaticallyImplyLeading; | ||
final Widget leading; | ||
|
||
FnBar( | ||
{Key key, | ||
this.title, | ||
this.actions, | ||
this.automaticallyImplyLeading = true, | ||
this.leading}) | ||
: super(key: key); | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return AppBar( | ||
elevation: 0, | ||
title: title ?? FnTitle(), | ||
actions: actions, | ||
backgroundColor: Theme.of(context).scaffoldBackgroundColor, | ||
automaticallyImplyLeading: automaticallyImplyLeading, | ||
leading: leading); | ||
} | ||
|
||
@override | ||
Size get preferredSize => new Size.fromHeight(kToolbarHeight); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
class FnCard extends StatelessWidget { | ||
final Widget child; | ||
final bool isFirst; | ||
final bool isLast; | ||
|
||
FnCard({Key key, this.child, this.isFirst = false, this.isLast = false}) | ||
: super(key: key); | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Card( | ||
elevation: 1, | ||
margin: EdgeInsets.only( | ||
left: 4.0, | ||
right: 4.0, | ||
top: isFirst ? 8.0 : 1, | ||
bottom: isLast ? 8.0 : 1), | ||
shape: RoundedRectangleBorder( | ||
borderRadius: BorderRadius.vertical( | ||
top: Radius.circular(isFirst ? 16.0 : 0), | ||
bottom: Radius.circular(isLast ? 16.0 : 0))), | ||
child: child); | ||
} | ||
} |
Oops, something went wrong.