-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into ui/exam_card
- Loading branch information
Showing
8 changed files
with
203 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
1.9.0-beta.23+286 | ||
1.9.0-beta.24+287 |
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,28 @@ | ||
import 'package:figma_squircle/figma_squircle.dart'; | ||
import 'package:flutter/material.dart'; | ||
|
||
class ModalDialog extends StatelessWidget { | ||
const ModalDialog({ | ||
required this.children, | ||
}); | ||
|
||
final List<Widget> children; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Dialog( | ||
backgroundColor: Colors.transparent, | ||
child: ClipSmoothRect( | ||
radius: SmoothBorderRadius(cornerRadius: 30, cornerSmoothing: 1), | ||
child: Container( | ||
padding: const EdgeInsets.all(20.0), | ||
color: Theme.of(context).colorScheme.surface, | ||
child: Column( | ||
mainAxisSize: MainAxisSize.min, | ||
mainAxisAlignment: MainAxisAlignment.center, | ||
children: children, | ||
), | ||
)), | ||
); | ||
} | ||
} |
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:uni_ui/theme.dart'; | ||
|
||
class ModalEnrollementInfo extends StatelessWidget { | ||
const ModalEnrollementInfo({required this.enrollements}); | ||
|
||
final Map<String, String> enrollements; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Container( | ||
padding: const EdgeInsets.only(top: 10.0), | ||
width: double.infinity, | ||
decoration: BoxDecoration( | ||
border: Border( | ||
top: BorderSide( | ||
color: Theme.of(context).dividerColor, width: 1))), | ||
child: Column( | ||
crossAxisAlignment: CrossAxisAlignment.start, | ||
children: [ | ||
Text("Enrollments", style: Theme.of(context).textTheme.bodyMedium), | ||
Wrap( | ||
spacing: 1, | ||
direction: Axis.horizontal, | ||
children: enrollements.entries.map((entry) { | ||
return Row( | ||
mainAxisSize: MainAxisSize.min, | ||
children: [ | ||
Text(entry.key, | ||
style: Theme.of(context) | ||
.textTheme | ||
.labelLarge | ||
?.copyWith( | ||
color: Theme.of(context).primaryColor)), | ||
Container( | ||
padding: const EdgeInsets.all(4.0), | ||
margin: const EdgeInsets.all(3.0), | ||
decoration: BoxDecoration( | ||
borderRadius: | ||
BorderRadius.all(Radius.circular(20)), | ||
color: Theme.of(context).primaryColor), | ||
child: Text( | ||
entry.value, | ||
style: Theme.of(context) | ||
.textTheme | ||
.labelSmall | ||
?.copyWith( | ||
color: pureWhite, | ||
), | ||
)) | ||
], | ||
); | ||
}).toList()) | ||
], | ||
)); | ||
} | ||
} |
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,45 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:phosphor_flutter/phosphor_flutter.dart'; | ||
|
||
class ModalInfoRow extends StatelessWidget { | ||
const ModalInfoRow( | ||
{super.key, | ||
required this.title, | ||
required this.description, | ||
required this.icon, | ||
this.onPressed}); | ||
|
||
final String title; | ||
final String description; | ||
final IconData icon; | ||
final void Function()? onPressed; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Container( | ||
padding: const EdgeInsets.all(3.0), | ||
decoration: BoxDecoration( | ||
border: Border( | ||
top: BorderSide( | ||
color: Theme.of(context).dividerColor, width: 1))), | ||
child: Row( | ||
children: [ | ||
Expanded( | ||
child: Column( | ||
crossAxisAlignment: CrossAxisAlignment.start, | ||
children: [ | ||
Text( | ||
title, | ||
style: Theme.of(context).textTheme.bodyMedium, | ||
), | ||
Text(description, | ||
style: Theme.of(context).textTheme.bodySmall!.copyWith( | ||
color: Theme.of(context).secondaryHeaderColor)), | ||
], | ||
), | ||
), | ||
IconButton(onPressed: onPressed, icon: PhosphorIcon(icon)) | ||
], | ||
)); | ||
} | ||
} |
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,28 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
class ModalPersonInfo extends StatelessWidget { | ||
const ModalPersonInfo({this.image, required this.name}); | ||
|
||
final Image? image; | ||
final String name; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Padding( | ||
padding: EdgeInsets.only(bottom: 20.0), | ||
child: Column( | ||
children: [ | ||
CircleAvatar( | ||
radius: 60.0, | ||
backgroundImage: image?.image, | ||
backgroundColor: Colors.green, | ||
), | ||
Text( | ||
name, | ||
style: Theme.of(context).textTheme.displaySmall, | ||
) | ||
], | ||
), | ||
); | ||
} | ||
} |
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,42 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:phosphor_flutter/phosphor_flutter.dart'; | ||
import 'package:uni_ui/theme.dart'; | ||
|
||
class ModalServiceInfo extends StatelessWidget { | ||
const ModalServiceInfo({required this.name, required this.durations}); | ||
|
||
final String name; | ||
final List<String> durations; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Padding( | ||
padding: EdgeInsets.only(bottom: 20.0), | ||
child: Column( | ||
children: [ | ||
Text( | ||
name, | ||
style: TextStyle( | ||
fontSize: 25.0, color: Theme.of(context).primaryColor), | ||
), | ||
Row( | ||
mainAxisAlignment: MainAxisAlignment.center, | ||
children: [ | ||
PhosphorIcon( | ||
PhosphorIcons.clock(PhosphorIconsStyle.duotone), | ||
color: darkGray, | ||
duotoneSecondaryColor: normalGray, | ||
), | ||
Column( | ||
children: durations.map((duration) { | ||
return Text(duration, | ||
style: Theme.of(context).textTheme.bodySmall!.copyWith( | ||
color: Theme.of(context).secondaryHeaderColor)); | ||
}).toList(), | ||
) | ||
], | ||
), | ||
], | ||
)); | ||
} | ||
} |
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