-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Frontend: Implement Dashboard screen UI
- Loading branch information
1 parent
6baf29a
commit 5cbcc77
Showing
35 changed files
with
1,154 additions
and
75 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 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,41 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:frontend/utils/constants.dart'; | ||
|
||
class IndicatorLegend extends StatelessWidget { | ||
const IndicatorLegend({required this.text, required this.color, super.key}); | ||
|
||
final String text; | ||
final Color color; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Row( | ||
mainAxisSize: MainAxisSize.min, | ||
children: [ | ||
Container( | ||
decoration: BoxDecoration( | ||
color: color, | ||
shape: BoxShape.circle, | ||
), | ||
width: 16, | ||
height: 16, | ||
), | ||
const SizedBox(width: 16), | ||
Flexible( | ||
child: Opacity( | ||
opacity: 0.8, | ||
child: Text( | ||
text, | ||
style: const TextStyle( | ||
fontFamily: Constants.fontKantumruy, | ||
fontSize: 12, | ||
), | ||
maxLines: 1, | ||
overflow: TextOverflow.ellipsis, | ||
), | ||
), | ||
), | ||
], | ||
); | ||
} | ||
} |
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,57 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:frontend/common/view/app_colors.dart'; | ||
import 'package:frontend/common/view/dta_icon.dart'; | ||
import 'package:frontend/common/view/underlined_text.dart'; | ||
import 'package:frontend/common/view/zoom_tap_animation.dart'; | ||
import 'package:frontend/constants/assets.dart'; | ||
import 'package:frontend/utils/constants.dart'; | ||
|
||
class SectionHeader extends StatelessWidget { | ||
const SectionHeader({ | ||
required this.title, | ||
super.key, | ||
this.actionText = 'View All', | ||
this.onActionTap, | ||
this.dense = false, | ||
}); | ||
|
||
final String title; | ||
final String actionText; | ||
final VoidCallback? onActionTap; | ||
final bool dense; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
Expanded( | ||
child: Text( | ||
title, | ||
style: TextStyle( | ||
fontFamily: Constants.fontDMSerifDisplay, | ||
fontSize: dense ? 16 : 24, | ||
), | ||
maxLines: 1, | ||
overflow: TextOverflow.ellipsis, | ||
), | ||
), | ||
if (onActionTap != null) | ||
Row( | ||
children: [ | ||
ZoomTapDetector( | ||
onTap: onActionTap, | ||
child: UnderlinedText(actionText), | ||
), | ||
const SizedBox(width: 8), | ||
DtaIcon( | ||
Assets.iconsArrowForward, | ||
color: appColors.accent, | ||
width: 8, | ||
) | ||
], | ||
), | ||
], | ||
); | ||
} | ||
} |
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,23 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:frontend/common/view/app_colors.dart'; | ||
import 'package:frontend/utils/constants.dart'; | ||
|
||
class UnderlinedText extends StatelessWidget { | ||
const UnderlinedText(this.text, {super.key}); | ||
|
||
final String text; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Text( | ||
text, | ||
style: TextStyle( | ||
color: appColors.accent, | ||
fontFamily: Constants.fontKantumruy, | ||
fontSize: 12, | ||
decoration: TextDecoration.underline, | ||
decorationColor: appColors.accent, | ||
), | ||
); | ||
} | ||
} |
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
Oops, something went wrong.