Skip to content

Build your personal knowledge base with Trilium Notes

fix(mobile): open the AI chat's menus as bottom sheets

Elian Doran3f8f741278b7
diff --git a/apps/client/src/widgets/sidebar/SidebarChat.tsx b/apps/client/src/widgets/sidebar/SidebarChat.tsx
index 9856222d46..66f3174608 100644
--- a/apps/client/src/widgets/sidebar/SidebarChat.tsx
+++ b/apps/client/src/widgets/sidebar/SidebarChat.tsx
@@ -316,6 +316,7 @@ export default function SidebarChat() {
hideToggleArrow
dropdownRef={historyDropdownRef}
onShown={loadRecentChats}
+ mobileBottomSheet
>
{recentChats.length === 0 ? (
<FormListItem disabled>
@@ -363,6 +364,7 @@ export default function SidebarChat() {
title={t("sidebar_chat.more_actions")}
iconAction
hideToggleArrow
+ mobileBottomSheet
>
<FormListItem
icon="bx bx-save"
diff --git a/apps/client/src/widgets/type_widgets/llm_chat/ChatInputBar.tsx b/apps/client/src/widgets/type_widgets/llm_chat/ChatInputBar.tsx
index 3ab84fe759..2a379b4d10 100644
--- a/apps/client/src/widgets/type_widgets/llm_chat/ChatInputBar.tsx
+++ b/apps/client/src/widgets/type_widgets/llm_chat/ChatInputBar.tsx
@@ -409,6 +409,7 @@ export default function ChatInputBar({
titlePosition="top"
buttonClassName="llm-chat-model-select"
className="llm-chat-model-dropdown"
+ mobileBottomSheet
>
{chat.modelGroups.map(group => (
<Fragment key={group.id}>
diff --git a/apps/client/src/widgets/type_widgets/llm_chat/ChatToolsDropdown.tsx b/apps/client/src/widgets/type_widgets/llm_chat/ChatToolsDropdown.tsx
index 71faf02d1c..7fb9bd668e 100644
--- a/apps/client/src/widgets/type_widgets/llm_chat/ChatToolsDropdown.tsx
+++ b/apps/client/src/widgets/type_widgets/llm_chat/ChatToolsDropdown.tsx
@@ -50,6 +50,7 @@ export default function ChatToolsDropdown({ enableNoteTools, onNoteToolsChange,
titlePosition="top"
placement="top-start"
disabled={disabled}
+ mobileBottomSheet
>
<FormListToggleableItem
icon="bx bx-note"
diff --git a/apps/client/src/widgets/type_widgets/llm_chat/ReasoningEffortDropdown.tsx b/apps/client/src/widgets/type_widgets/llm_chat/ReasoningEffortDropdown.tsx
index 13e3b3286e..156dc91066 100644
--- a/apps/client/src/widgets/type_widgets/llm_chat/ReasoningEffortDropdown.tsx
+++ b/apps/client/src/widgets/type_widgets/llm_chat/ReasoningEffortDropdown.tsx
@@ -33,6 +33,7 @@ export default function ReasoningEffortDropdown({ model, value, onChange, disabl
buttonClassName="llm-chat-model-select"
className="llm-chat-reasoning-effort"
disabled={disabled}
+ mobileBottomSheet
>
{(model.reasoningEfforts ?? []).map(level => (
<FormListItem key={level} checked={level === effective} onClick={() => onChange(level)}>