Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: #1126 More appealing empty history screen #1212

Merged
merged 6 commits into from
Mar 16, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,42 @@ class _ProductListPageState extends State<ProductListPage> {
),
),
body: products.isEmpty
? Center(
child: Text(appLocalizations.no_prodcut_in_list,
style: Theme.of(context).textTheme.subtitle1),
? Column(
children: [
Container(
height: MediaQuery.of(context).size.height * 0.3,
child: LayoutBuilder(builder: (context, constraint) {
return Icon(
Icons.find_in_page_rounded,
color: Colors.blue,
size: constraint.biggest.height,
semanticLabel: 'History not available',
);
}),
),
Text(
'Start scanning!',
bhattabhi013 marked this conversation as resolved.
Show resolved Hide resolved
style: TextStyle(
color: Colors.black,
bhattabhi013 marked this conversation as resolved.
Show resolved Hide resolved
fontWeight: FontWeight.bold,
fontSize: 36.0,
bhattabhi013 marked this conversation as resolved.
Show resolved Hide resolved
),
),
Padding(
padding: EdgeInsets.all(20.0),
bhattabhi013 marked this conversation as resolved.
Show resolved Hide resolved
child: Text(
'Product you scan in will appear here and you can check detailed information about them',
style: TextStyle(
color: Colors.black,
),
),
)
],
)
// ? Center(
// child: Text(appLocalizations.no_prodcut_in_list,
// style: Theme.of(context).textTheme.subtitle1),
// )
bhattabhi013 marked this conversation as resolved.
Show resolved Hide resolved
: ListView.builder(
itemCount: products.length,
itemBuilder: (BuildContext context, int index) {
Expand Down