Skip to content

Commit 2f100f7

Browse files
authored
Remove side panel hint from code viewers (#318)
1 parent 1d1d810 commit 2f100f7

2 files changed

Lines changed: 3 additions & 10 deletions

File tree

apps/web/src/components/CodeViewerPanel.tsx

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import {
2222
import { useTheme } from "~/hooks/useTheme";
2323
import { isElectron } from "~/env";
2424
import { projectQueryKeys, projectReadFileQueryOptions } from "~/lib/projectReactQuery";
25-
import { cn, isMacPlatform } from "~/lib/utils";
25+
import { cn } from "~/lib/utils";
2626
import { isMarkdownPreviewFilePath } from "~/markdownPreview";
2727
import { readNativeApi } from "~/nativeApi";
2828
import { type CodeContextSelection, CodeMirrorViewer } from "./CodeMirrorViewer";
@@ -600,7 +600,7 @@ export default function CodeViewerPanel() {
600600
[setPendingContext],
601601
);
602602

603-
const modKey = isMacPlatform(navigator.platform) ? "\u2318" : "Ctrl+";
603+
604604

605605
return (
606606
<div className="flex h-full w-full flex-col bg-background">
@@ -618,9 +618,6 @@ export default function CodeViewerPanel() {
618618
onCloseAll={onCloseAll}
619619
/>
620620
<div className="flex shrink-0 items-center gap-2 [-webkit-app-region:no-drag]">
621-
<span className="hidden text-[10px] text-muted-foreground/50 sm:inline">
622-
Select code + {modKey}L to add context
623-
</span>
624621
<Button
625622
size="icon-xs"
626623
variant="ghost"

apps/web/src/components/file-view/FileViewShell.tsx

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { useCallback, useEffect } from "react";
55
import { useAppSettings } from "~/appSettings";
66
import { useCodeViewerStore } from "~/codeViewerStore";
77
import { useTheme } from "~/hooks/useTheme";
8-
import { isMacPlatform } from "~/lib/utils";
98
import type { CodeContextSelection } from "../CodeMirrorViewer";
109
import { CodeViewerFileContent, CodeViewerTabStrip } from "../CodeViewerPanel";
1110
import { Button } from "../ui/button";
@@ -85,7 +84,7 @@ export function FileViewShell(props: { initialCwd: string; initialPath: string |
8584
[setPendingContext],
8685
);
8786

88-
const modKey = isMacPlatform(navigator.platform) ? "\u2318" : "Ctrl+";
87+
8988

9089
return (
9190
<div className="flex h-full w-full flex-col">
@@ -99,9 +98,6 @@ export function FileViewShell(props: { initialCwd: string; initialPath: string |
9998
onCloseAll={onCloseAll}
10099
/>
101100
<div className="flex shrink-0 items-center gap-2 [-webkit-app-region:no-drag]">
102-
<span className="hidden text-[10px] text-muted-foreground/50 sm:inline">
103-
Select code + {modKey}L to add context
104-
</span>
105101
<Button
106102
size="icon-xs"
107103
variant="ghost"

0 commit comments

Comments
 (0)