mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2025-07-23 14:40:58 -04:00
switch to smpl key
This commit is contained in:
parent
e68cbb26eb
commit
ee80dbf3a5
13 changed files with 192 additions and 136 deletions
|
@ -23,8 +23,9 @@ class ChatSingleContactItemWidget extends ConsumerWidget {
|
|||
final scale = theme.extension<ScaleScheme>()!;
|
||||
|
||||
final activeChat = ref.watch(activeChatStateProvider).asData?.value;
|
||||
final selected = activeChat ==
|
||||
proto.TypedKeyProto.fromProto(contact.remoteConversationKey);
|
||||
final remoteConversationRecordKey =
|
||||
proto.TypedKeyProto.fromProto(contact.remoteConversationRecordKey);
|
||||
final selected = activeChat == remoteConversationRecordKey;
|
||||
|
||||
return Container(
|
||||
margin: const EdgeInsets.fromLTRB(4, 4, 4, 0),
|
||||
|
@ -47,8 +48,7 @@ class ChatSingleContactItemWidget extends ConsumerWidget {
|
|||
await deleteChat(
|
||||
activeAccountInfo: activeAccountInfo,
|
||||
remoteConversationRecordKey:
|
||||
proto.TypedKeyProto.fromProto(
|
||||
contact.remoteConversationKey));
|
||||
remoteConversationRecordKey);
|
||||
ref.invalidate(fetchChatListProvider);
|
||||
}
|
||||
},
|
||||
|
@ -71,8 +71,7 @@ class ChatSingleContactItemWidget extends ConsumerWidget {
|
|||
// component is not dragged.
|
||||
child: ListTile(
|
||||
onTap: () async {
|
||||
activeChatState.add(proto.TypedKeyProto.fromProto(
|
||||
contact.remoteConversationKey));
|
||||
activeChatState.add(remoteConversationRecordKey);
|
||||
ref.invalidate(fetchChatListProvider);
|
||||
},
|
||||
title: Text(contact.editedProfile.name),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue