"chats" menu open by default

master
Avraham Sakal 3 months ago
parent 01d2997f77
commit d7716bd451

@ -54,7 +54,7 @@ export default function LayoutDefault({
// }
// }, [isConversationListExpanded]);
function handleDeleteConversation(conversationId: ConversationsId) {
function handleDeleteConversation(conversationId: string) {
removeConversation(conversationId);
trpc.chat.deleteConversation.mutate({ id: conversationId });
}
@ -95,10 +95,9 @@ export default function LayoutDefault({
<NavLink
key="chat-new"
href="#required-for-focus-management"
label="Chats"
leftSection={<IconActivity size={16} stroke={1.5} />}
rightSection={
<>
label={
<Group justify="space-between">
<span>Chats</span>
<IconPlus
size={16}
stroke={1.5}
@ -113,15 +112,19 @@ export default function LayoutDefault({
});
}}
/>
<IconChevronRight
size={12}
stroke={1.5}
className="mantine-rotate-rtl"
/>
</>
</Group>
}
leftSection={<IconActivity size={16} stroke={1.5} />}
rightSection={
<IconChevronRight
size={12}
stroke={1.5}
className="mantine-rotate-rtl"
/>
}
variant="subtle"
active={urlPathname.startsWith("/chat")}
defaultOpened={true}
>
{conversations.map((conversation) => (
<NavLink

Loading…
Cancel
Save