style: colors

This commit is contained in:
shalong-tanwen 2023-12-03 23:47:12 +05:30
parent 85841e3349
commit 3b8656a603
11 changed files with 57 additions and 60 deletions

View file

@ -95,10 +95,6 @@ class AlbumThumbnailCard extends StatelessWidget {
return GestureDetector(
onTap: onTap,
child: Flex(
direction: Axis.vertical,
children: [
Flexible(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
@ -106,15 +102,14 @@ class AlbumThumbnailCard extends StatelessWidget {
width: cardSize,
height: cardSize,
child: ClipRRect(
borderRadius:
const BorderRadius.all(Radius.circular(20)),
borderRadius: const BorderRadius.all(Radius.circular(20)),
child: album.thumbnail.value == null
? buildEmptyThumbnail()
: buildAlbumThumbnail(),
),
),
Padding(
padding: const EdgeInsets.only(top: 8.0),
padding: const EdgeInsets.only(top: 8.0, left: 8.0),
child: SizedBox(
width: cardSize,
child: Text(
@ -126,9 +121,9 @@ class AlbumThumbnailCard extends StatelessWidget {
),
),
),
buildAlbumTextRow(),
],
),
Padding(
padding: const EdgeInsets.only(top: 2.0, left: 8.0),
child: buildAlbumTextRow(),
),
],
),

View file

@ -4,6 +4,7 @@ import 'package:flutter/material.dart';
import 'package:flutter_hooks/flutter_hooks.dart';
import 'package:hooks_riverpod/hooks_riverpod.dart';
import 'package:immich_mobile/extensions/build_context_extensions.dart';
import 'package:immich_mobile/extensions/color_extensions.dart';
import 'package:immich_mobile/modules/album/providers/album.provider.dart';
import 'package:immich_mobile/modules/album/ui/album_thumbnail_card.dart';
import 'package:immich_mobile/routing/router.dart';
@ -144,13 +145,14 @@ class LibraryPage extends HookConsumerWidget {
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Expanded(
child: Container(
decoration: BoxDecoration(
color: context.themeData.cardColor,
borderRadius:
const BorderRadius.all(Radius.circular(20)),
SizedBox.square(
dimension: constraints.maxWidth,
child: Card(
clipBehavior: Clip.hardEdge,
shape: const RoundedRectangleBorder(
borderRadius: BorderRadius.all(Radius.circular(20)),
),
color: context.themeData.cardColor.lighten(5),
child: Center(
child: Icon(
Icons.add_rounded,
@ -164,6 +166,7 @@ class LibraryPage extends HookConsumerWidget {
padding: const EdgeInsets.only(
top: 8.0,
bottom: 16,
left: 8.0,
),
child: Text(
'library_page_new_album',
@ -188,14 +191,7 @@ class LibraryPage extends HookConsumerWidget {
onPressed: onClick,
label: Padding(
padding: const EdgeInsets.only(left: 8.0),
child: Text(
label,
style: TextStyle(
color: context.isDarkTheme
? Colors.white
: Colors.black.withAlpha(200),
),
),
child: Text(label),
),
style: context.themeData.elevatedButtonTheme.style?.copyWith(
alignment: Alignment.centerLeft,
@ -215,7 +211,7 @@ class LibraryPage extends HookConsumerWidget {
return trashEnabled
? InkWell(
onTap: () => context.autoPush(const TrashRoute()),
borderRadius: BorderRadius.circular(12),
borderRadius: const BorderRadius.all(Radius.circular(12)),
child: const Icon(
Icons.delete_rounded,
size: 25,

View file

@ -674,7 +674,6 @@ class BackupControllerPage extends HookConsumerWidget {
return Scaffold(
appBar: AppBar(
elevation: 0,
title: const Text(
"backup_controller_page_backup",
).tr(),

View file

@ -222,7 +222,9 @@ class ImmichAssetGridViewState extends State<ImmichAssetGridView> {
padding: const EdgeInsets.only(left: 12.0, top: 24.0),
child: Text(
title,
style: context.textTheme.displayLarge,
style: context.textTheme.displayLarge?.copyWith(
color: context.colorScheme.onSurface,
),
),
);
}

View file

@ -617,7 +617,7 @@ class LoadingIcon extends StatelessWidget {
height: 24,
child: FittedBox(
child: CircularProgressIndicator(
strokeWidth: 2,
strokeWidth: 5,
),
),
),

View file

@ -52,13 +52,13 @@ class CuratedPlacesRow extends CuratedRow {
child: Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10),
color: Colors.black,
color: context.colorScheme.shadow,
gradient: LinearGradient(
begin: FractionalOffset.topCenter,
end: FractionalOffset.bottomCenter,
colors: [
Colors.blueGrey.withOpacity(0.0),
Colors.black.withOpacity(0.4),
context.colorScheme.shadow.withOpacity(0.1),
context.colorScheme.shadow.withOpacity(0.2),
],
stops: const [0.0, 0.4],
),

View file

@ -71,15 +71,15 @@ class ThumbnailWithInfo extends StatelessWidget {
Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(borderRadius),
color: Colors.white,
color: context.colorScheme.inverseSurface,
gradient: LinearGradient(
begin: FractionalOffset.topCenter,
end: FractionalOffset.bottomCenter,
colors: [
context.colorScheme.surfaceVariant.withOpacity(0.0),
context.colorScheme.shadow.withOpacity(0),
textInfo == ''
? context.colorScheme.surface.withOpacity(0.1)
: context.colorScheme.surface.withOpacity(0.6),
? context.colorScheme.shadow.withOpacity(0.1)
: context.colorScheme.shadow.withOpacity(0.2),
],
stops: const [0.0, 1.0],
),

View file

@ -131,6 +131,7 @@ class ImmichAppBar extends ConsumerWidget implements PreferredSizeWidget {
}
return AppBar(
elevation: 0.0,
backgroundColor: context.themeData.appBarTheme.backgroundColor,
shape: const RoundedRectangleBorder(
borderRadius: BorderRadius.all(

View file

@ -30,9 +30,9 @@ class ImmichToast {
switch (type) {
case ToastType.info:
return Icons.info_outline_rounded;
case ToastType.error:
return Icons.check_circle_outline_rounded;
case ToastType.success:
return Icons.check_circle_outline_rounded;
case ToastType.error:
return Icons.report_problem_outlined;
}
}

View file

@ -93,7 +93,9 @@ class SplashScreenPage extends HookConsumerWidget {
);
return Scaffold(
appBar: AppBar(),
appBar: AppBar(
elevation: 0.0,
),
body: const Center(
child: Image(
image: AssetImage('assets/immich-logo-no-outline.png'),

View file

@ -84,6 +84,8 @@ ThemeData getThemeForScheme(ColorScheme scheme) {
color: scheme.primary,
),
centerTitle: true,
scrolledUnderElevation: 4.0,
elevation: 4.0,
),
snackBarTheme: const SnackBarThemeData(
contentTextStyle: TextStyle(