2
0
Эх сурвалжийг харах

fix(desktop): don't show image button in shell mode

Adam 2 сар өмнө
parent
commit
228b6444f8

+ 11 - 9
packages/desktop/src/components/prompt-input.tsx

@@ -1004,15 +1004,17 @@ export const PromptInput: Component<PromptInputProps> = (props) => {
                 e.currentTarget.value = ""
                 e.currentTarget.value = ""
               }}
               }}
             />
             />
-            <Tooltip placement="top" value="Attach image">
-              <IconButton
-                type="button"
-                icon="photo"
-                variant="ghost"
-                class="h-10 w-8"
-                onClick={() => fileInputRef.click()}
-              />
-            </Tooltip>
+            <Show when={store.mode === "normal"}>
+              <Tooltip placement="top" value="Attach image">
+                <IconButton
+                  type="button"
+                  icon="photo"
+                  variant="ghost"
+                  class="h-10 w-8"
+                  onClick={() => fileInputRef.click()}
+                />
+              </Tooltip>
+            </Show>
             <Tooltip
             <Tooltip
               placement="top"
               placement="top"
               inactive={!prompt.dirty() && !working()}
               inactive={!prompt.dirty() && !working()}