mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2025-05-28 10:42:24 -04:00
ui cleanup, new themes
This commit is contained in:
parent
94988718e8
commit
44fe198e5d
31 changed files with 1051 additions and 407 deletions
|
@ -21,24 +21,42 @@ class ProfileWidget extends StatelessWidget {
|
|||
Widget build(BuildContext context) {
|
||||
final theme = Theme.of(context);
|
||||
final scale = theme.extension<ScaleScheme>()!;
|
||||
final scaleConfig = theme.extension<ScaleConfig>()!;
|
||||
|
||||
final textTheme = theme.textTheme;
|
||||
|
||||
return DecoratedBox(
|
||||
decoration: ShapeDecoration(
|
||||
color: scale.primaryScale.border,
|
||||
shape:
|
||||
RoundedRectangleBorder(borderRadius: BorderRadius.circular(16))),
|
||||
color: scaleConfig.preferBorders
|
||||
? scale.primaryScale.elementBackground
|
||||
: scale.primaryScale.border,
|
||||
shape: RoundedRectangleBorder(
|
||||
side: !scaleConfig.useVisualIndicators
|
||||
? BorderSide.none
|
||||
: BorderSide(
|
||||
strokeAlign: BorderSide.strokeAlignCenter,
|
||||
color: scaleConfig.preferBorders
|
||||
? scale.primaryScale.border
|
||||
: scale.primaryScale.borderText,
|
||||
width: 2),
|
||||
borderRadius: BorderRadius.all(
|
||||
Radius.circular(16 * scaleConfig.borderRadiusScale))),
|
||||
),
|
||||
child: Column(children: [
|
||||
Text(
|
||||
_profile.name,
|
||||
style: textTheme.headlineSmall!
|
||||
.copyWith(color: scale.primaryScale.borderText),
|
||||
style: textTheme.headlineSmall!.copyWith(
|
||||
color: scaleConfig.preferBorders
|
||||
? scale.primaryScale.border
|
||||
: scale.primaryScale.borderText),
|
||||
textAlign: TextAlign.left,
|
||||
).paddingAll(4),
|
||||
if (_profile.pronouns.isNotEmpty)
|
||||
Text(_profile.pronouns,
|
||||
style: textTheme.bodyMedium!
|
||||
.copyWith(color: scale.primaryScale.borderText))
|
||||
style: textTheme.bodyMedium!.copyWith(
|
||||
color: scaleConfig.preferBorders
|
||||
? scale.primaryScale.border
|
||||
: scale.primaryScale.borderText))
|
||||
.paddingLTRB(4, 0, 4, 4),
|
||||
]),
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue