Include reviewed chat row identity transition
This commit is contained in:
@@ -5,6 +5,7 @@ import '../../../../core/api_gateway.dart';
|
||||
import '../../../../ui/layout/app_list_avatar.dart';
|
||||
import '../../../../ui/layout/app_list_row.dart';
|
||||
import '../../../../ui/text/relative_time_label.dart';
|
||||
import '../../../../shell/list_detail_policy.dart';
|
||||
import '../../domain/chat_colors.dart';
|
||||
import '../../domain/chat_list_activity.dart';
|
||||
import '../../domain/chat_sessions.dart';
|
||||
@@ -70,6 +71,20 @@ class ChatSessionRow extends StatelessWidget {
|
||||
: Theme.of(context).colorScheme.primary;
|
||||
final text = chatSessionSubtitle(session);
|
||||
final updatedAt = _chatSessionInstant(session['updated_at']);
|
||||
final avatar = ChatSessionAvatar(
|
||||
session: session,
|
||||
running: session['running'] == true && !unseen,
|
||||
backgroundTasks: session['running'] == true
|
||||
? 0
|
||||
: chatSessionBackgroundTasks(session),
|
||||
selected: selected,
|
||||
);
|
||||
final mobileHero =
|
||||
!showsListBesideDetail(context) &&
|
||||
!(MediaQuery.maybeDisableAnimationsOf(context) ?? false);
|
||||
final identity = mobileHero
|
||||
? Hero(tag: 'chat-identity-$id', child: avatar)
|
||||
: avatar;
|
||||
return ChatVisibilityMarker(
|
||||
sessionId: id,
|
||||
color: chatColorShade(context, chatSessionColor(session)) ?? accent,
|
||||
@@ -86,14 +101,7 @@ class ChatSessionRow extends StatelessWidget {
|
||||
onLongPress: selectionOnly ? null : onLongPress,
|
||||
accent: chatColorShade(context, chatSessionColor(session)),
|
||||
showAccentBorder: false,
|
||||
leading: ChatSessionAvatar(
|
||||
session: session,
|
||||
running: session['running'] == true && !unseen,
|
||||
backgroundTasks: session['running'] == true
|
||||
? 0
|
||||
: chatSessionBackgroundTasks(session),
|
||||
selected: selected,
|
||||
),
|
||||
leading: identity,
|
||||
// The star rides in the title's own text, so a narrow row ellipsises
|
||||
// them together.
|
||||
title: Text.rich(
|
||||
|
||||
Reference in New Issue
Block a user