Skip to content

Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active

📱 fix: Mention Touch UX and MCP Tool UI Consistency (#11627)

Danny Avilae89e514fcb3e
diff --git a/client/src/components/Chat/Input/Mention.tsx b/client/src/components/Chat/Input/Mention.tsx
index 2defcc7623..9e56068def 100644
--- a/client/src/components/Chat/Input/Mention.tsx
+++ b/client/src/components/Chat/Input/Mention.tsx
@@ -12,7 +12,7 @@ import useMentions from '~/hooks/Input/useMentions';
import { removeCharIfLast } from '~/utils';
import MentionItem from './MentionItem';
-const ROW_HEIGHT = 40;
+const ROW_HEIGHT = 44;
export default function Mention({
conversation,
diff --git a/client/src/components/Chat/Input/MentionItem.tsx b/client/src/components/Chat/Input/MentionItem.tsx
index fcfb22c312..6c978240ee 100644
--- a/client/src/components/Chat/Input/MentionItem.tsx
+++ b/client/src/components/Chat/Input/MentionItem.tsx
@@ -25,15 +25,16 @@ export default function MentionItem({
}: MentionItemProps) {
return (
<button
+ type="button"
+ style={style}
tabIndex={index}
onClick={onClick}
id={`${type}-item-${index}`}
- className="w-full"
- style={style}
+ className="w-full touch-manipulation"
>
<div
className={cn(
- 'text-token-text-primary bg-token-main-surface-secondary group flex h-10 items-center gap-2 rounded-lg px-2 text-sm font-medium hover:bg-surface-secondary',
+ 'text-token-text-primary bg-token-main-surface-secondary group flex min-h-[44px] items-center gap-2 rounded-lg px-2 text-sm font-medium hover:bg-surface-secondary active:bg-surface-active',
isActive === true ? 'bg-surface-active' : 'bg-transparent',
)}
>
diff --git a/client/src/components/Chat/Input/PromptsCommand.tsx b/client/src/components/Chat/Input/PromptsCommand.tsx
index 2ea36a5236..1740ed43a2 100644
--- a/client/src/components/Chat/Input/PromptsCommand.tsx
+++ b/client/src/components/Chat/Input/PromptsCommand.tsx
@@ -4,8 +4,8 @@ import { Spinner, useCombobox } from '@librechat/client';
import { useSetRecoilState, useRecoilValue } from 'recoil';
import type { TPromptGroup } from 'librechat-data-provider';
import type { PromptOption } from '~/common';
-import { removeCharIfLast, detectVariables } from '~/utils';
import VariableDialog from '~/components/Prompts/Groups/VariableDialog';
+import { removeCharIfLast, detectVariables } from '~/utils';
import { usePromptGroupsContext } from '~/Providers';
import MentionItem from './MentionItem';
import { useLocalize } from '~/hooks';
@@ -48,7 +48,7 @@ const PopoverContainer = memo(
},
);
-const ROW_HEIGHT = 40;
+const ROW_HEIGHT = 44;
function PromptsCommand({
index,
diff --git a/client/src/components/SidePanel/Agents/MCPToolItem.tsx b/client/src/components/SidePanel/Agents/MCPToolItem.tsx
index 3854e3fcaa..e2fbd79802 100644
--- a/client/src/components/SidePanel/Agents/MCPToolItem.tsx
+++ b/client/src/components/SidePanel/Agents/MCPToolItem.tsx
@@ -42,12 +42,12 @@ export default function MCPToolItem({
tool,
isSelected,
isDeferred,
+ onToggleDefer,
+ onToggleSelect,
isProgrammatic,
+ onToggleProgrammatic,
deferredToolsEnabled,
programmaticToolsEnabled,
- onToggleSelect,
- onToggleDefer,
- onToggleProgrammatic,
}: MCPToolItemProps) {
const localize = useLocalize();
const hasOptions = isDeferred || isProgrammatic;
@@ -104,10 +104,10 @@ export default function MCPToolItem({
<DropdownMenuContent
align="end"
side="left"
- className="w-64"
+ className="w-80"
onClick={(e) => e.stopPropagation()}
>
- <DropdownMenuLabel className="text-xs font-normal text-text-secondary">
+ <DropdownMenuLabel className="text-xs font-normal text-text-primary">
{tool.metadata.description || localize('com_ui_mcp_no_description')}
</DropdownMenuLabel>
<DropdownMenuSeparator />
@@ -121,7 +121,7 @@ export default function MCPToolItem({
<Clock className="h-4 w-4 text-amber-500" />
<div className="flex flex-col">
<span>{localize('com_ui_mcp_defer_loading')}</span>
- <span className="text-xs text-text-tertiary">
+ <span className="text-xs text-text-secondary">
{localize('com_ui_mcp_click_to_defer')}
</span>
</div>
@@ -138,7 +138,7 @@ export default function MCPToolItem({
<Code2 className="h-4 w-4 text-violet-500" />
<div className="flex flex-col">
<span>{localize('com_ui_mcp_programmatic')}</span>
- <span className="text-xs text-text-tertiary">
+ <span className="text-xs text-text-secondary">
{localize('com_ui_mcp_click_to_programmatic')}
</span>
</div>
diff --git a/client/src/components/SidePanel/Agents/MCPTools.tsx b/client/src/components/SidePanel/Agents/MCPTools.tsx
index fa028b2d55..552f2b313b 100644
--- a/client/src/components/SidePanel/Agents/MCPTools.tsx
+++ b/client/src/components/SidePanel/Agents/MCPTools.tsx
@@ -1,10 +1,10 @@
import React from 'react';
+import { PermissionTypes, Permissions } from 'librechat-data-provider';
import UninitializedMCPTool from './UninitializedMCPTool';
import UnconfiguredMCPTool from './UnconfiguredMCPTool';
-import { useAgentPanelContext } from '~/Providers';
import { useHasAccess, useLocalize } from '~/hooks';
+import { useAgentPanelContext } from '~/Providers';
import MCPTool from './MCPTool';
-import { PermissionTypes, Permissions } from 'librechat-data-provider';
export default function MCPTools({
agentId,
diff --git a/packages/client/src/components/DropdownMenu.tsx b/packages/client/src/components/DropdownMenu.tsx
index 488ab18f6e..013301bc6a 100644
--- a/packages/client/src/components/DropdownMenu.tsx
+++ b/packages/client/src/components/DropdownMenu.tsx
@@ -30,7 +30,7 @@ function DropdownMenuContent({
data-slot="dropdown-menu-content"
sideOffset={sideOffset}
className={cn(
- 'text-popover-foreground max-h-(--radix-dropdown-menu-content-available-height) origin-(--radix-dropdown-menu-content-transform-origin) z-40 min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border border-border-light bg-surface-secondary p-1 shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
+ 'max-h-(--radix-dropdown-menu-content-available-height) origin-(--radix-dropdown-menu-content-transform-origin) z-40 min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border border-border-medium bg-surface-primary p-1 text-text-primary shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
className,
)}
{...props}
@@ -198,7 +198,7 @@ function DropdownMenuSubContent({
<DropdownMenuPrimitive.SubContent
data-slot="dropdown-menu-sub-content"
className={cn(
- 'text-popover-foreground origin-(--radix-dropdown-menu-content-transform-origin) z-40 min-w-[8rem] overflow-hidden rounded-md border border-border-medium bg-surface-secondary p-1 shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
+ 'origin-(--radix-dropdown-menu-content-transform-origin) z-40 min-w-[8rem] overflow-hidden rounded-md border border-border-medium bg-surface-primary p-1 text-text-primary shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
className,
)}
{...props}