feat: wallpaper padrao nas conversas, logo colorida na sidebar e ajustes na aba de espacos
This commit is contained in:
@@ -13,7 +13,6 @@ import 'package:tatchat/pages/chat/encryption_info.dart';
|
||||
import 'package:tatchat/pages/chat/events/message.dart';
|
||||
import 'package:tatchat/pages/chat/seen_by_row.dart';
|
||||
import 'package:tatchat/pages/chat/typing_indicators.dart';
|
||||
import 'package:tatchat/utils/account_config.dart';
|
||||
import 'package:tatchat/utils/matrix_sdk_extensions/filtered_timeline_extension.dart';
|
||||
import 'package:tatchat/utils/platform_infos.dart';
|
||||
import 'package:material_ui/material_ui.dart';
|
||||
@@ -53,8 +52,7 @@ class ChatEventList extends StatelessWidget {
|
||||
thisEventsKeyMap[events[i].eventId] = i;
|
||||
}
|
||||
|
||||
final hasWallpaper =
|
||||
controller.room.client.applicationAccountConfig.wallpaperUrl != null;
|
||||
const hasWallpaper = true;
|
||||
|
||||
return SelectionArea(
|
||||
child: MediaQuery(
|
||||
|
||||
@@ -352,25 +352,38 @@ class ChatView extends StatelessWidget {
|
||||
top: false,
|
||||
child: Stack(
|
||||
children: <Widget>[
|
||||
if (accountConfig.wallpaperUrl != null)
|
||||
Opacity(
|
||||
opacity: accountConfig.wallpaperOpacity ?? 0.5,
|
||||
child: ImageFiltered(
|
||||
imageFilter: ui.ImageFilter.blur(
|
||||
sigmaX: accountConfig.wallpaperBlur ?? 0.0,
|
||||
sigmaY: accountConfig.wallpaperBlur ?? 0.0,
|
||||
),
|
||||
child: MxcImage(
|
||||
cacheKey: accountConfig.wallpaperUrl.toString(),
|
||||
uri: accountConfig.wallpaperUrl,
|
||||
fit: BoxFit.cover,
|
||||
height: MediaQuery.sizeOf(context).height,
|
||||
width: MediaQuery.sizeOf(context).width,
|
||||
isThumbnail: false,
|
||||
placeholder: (_) => Container(),
|
||||
),
|
||||
Opacity(
|
||||
opacity: accountConfig.wallpaperUrl != null
|
||||
? accountConfig.wallpaperOpacity ?? 0.5
|
||||
: 0.3,
|
||||
child: ImageFiltered(
|
||||
imageFilter: ui.ImageFilter.blur(
|
||||
sigmaX: accountConfig.wallpaperUrl != null
|
||||
? accountConfig.wallpaperBlur ?? 0.0
|
||||
: 0.0,
|
||||
sigmaY: accountConfig.wallpaperUrl != null
|
||||
? accountConfig.wallpaperBlur ?? 0.0
|
||||
: 0.0,
|
||||
),
|
||||
child: accountConfig.wallpaperUrl != null
|
||||
? MxcImage(
|
||||
cacheKey: accountConfig.wallpaperUrl
|
||||
.toString(),
|
||||
uri: accountConfig.wallpaperUrl,
|
||||
fit: BoxFit.cover,
|
||||
height: MediaQuery.sizeOf(context).height,
|
||||
width: MediaQuery.sizeOf(context).width,
|
||||
isThumbnail: false,
|
||||
placeholder: (_) => Container(),
|
||||
)
|
||||
: Image.asset(
|
||||
'./assets/logo/background.png',
|
||||
fit: BoxFit.cover,
|
||||
height: MediaQuery.sizeOf(context).height,
|
||||
width: MediaQuery.sizeOf(context).width,
|
||||
),
|
||||
),
|
||||
),
|
||||
GestureDetector(
|
||||
onTap: controller.clearSingleSelectedEvent,
|
||||
child: ChatEventList(controller: controller),
|
||||
|
||||
Reference in New Issue
Block a user