소스 검색

chore: 手机端隐藏快捷键展示

DDMeaqua 1 년 전
부모
커밋
db39fbc419
1개의 변경된 파일9개의 추가작업 그리고 5개의 파일을 삭제
  1. 9 5
      app/components/chat.tsx

+ 9 - 5
app/components/chat.tsx

@@ -504,6 +504,8 @@ export function ChatActions(props: {
   const currentStyle =
     chatStore.currentSession().mask.modelConfig?.style ?? "vivid";
 
+  const isMobileScreen = useMobileScreen();
+
   useEffect(() => {
     const show = isVisionModel(currentModel);
     setShowUploadImage(show);
@@ -758,11 +760,13 @@ export function ChatActions(props: {
         />
       )}
 
-      <ChatAction
-        onClick={() => props.setShowShortcutKeyModal(true)}
-        text={Locale.Chat.ShortcutKey.Title}
-        icon={<ShortcutkeyIcon />}
-      />
+      {!isMobileScreen && (
+        <ChatAction
+          onClick={() => props.setShowShortcutKeyModal(true)}
+          text={Locale.Chat.ShortcutKey.Title}
+          icon={<ShortcutkeyIcon />}
+        />
+      )}
     </div>
   );
 }