Skip to content

Commit 5967a60

Browse files
committed
Settings changes
Removed the virtualization settings for FilesChangedOverview
1 parent bedbe33 commit 5967a60

File tree

14 files changed

+5
-65
lines changed

14 files changed

+5
-65
lines changed

packages/types/src/global-settings.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,6 @@ export const globalSettingsSchema = z.object({
106106
profileThresholds: z.record(z.string(), z.number()).optional(),
107107
hasOpenedModeSelector: z.boolean().optional(),
108108
filesChangedEnabled: z.boolean().optional(),
109-
filesChangedMaxDisplayFiles: z.number().optional(),
110109
})
111110

112111
export type GlobalSettings = z.infer<typeof globalSettingsSchema>

src/core/webview/ClineProvider.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1694,7 +1694,6 @@ export class ClineProvider
16941694
} = await this.getState()
16951695

16961696
const filesChangedEnabled = this.getGlobalState("filesChangedEnabled")
1697-
const filesChangedMaxDisplayFiles = this.getGlobalState("filesChangedMaxDisplayFiles")
16981697

16991698
const telemetryKey = process.env.POSTHOG_API_KEY
17001699
const machineId = vscode.env.machineId
@@ -1805,7 +1804,6 @@ export class ClineProvider
18051804
cloudApiUrl: getRooCodeApiUrl(),
18061805
hasOpenedModeSelector: this.getGlobalState("hasOpenedModeSelector") ?? false,
18071806
filesChangedEnabled: this.getGlobalState("filesChangedEnabled") ?? true,
1808-
filesChangedMaxDisplayFiles: this.getGlobalState("filesChangedMaxDisplayFiles") ?? 50,
18091807
}
18101808
}
18111809

src/core/webview/__tests__/ClineProvider.spec.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -540,7 +540,6 @@ describe("ClineProvider", () => {
540540
profileThresholds: {},
541541
hasOpenedModeSelector: false,
542542
filesChangedEnabled: true,
543-
filesChangedMaxDisplayFiles: 50,
544543
}
545544

546545
const message: ExtensionMessage = {

src/core/webview/webviewMessageHandler.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -962,7 +962,6 @@ export const webviewMessageHandler = async (
962962
customModePrompts: updatedPrompts,
963963
hasOpenedModeSelector: currentState.hasOpenedModeSelector ?? false,
964964
filesChangedEnabled: currentState.filesChangedEnabled ?? true,
965-
filesChangedMaxDisplayFiles: currentState.filesChangedMaxDisplayFiles ?? 50,
966965
}
967966
provider.postMessageToWebview({ type: "state", state: stateWithPrompts })
968967

src/package.json

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -344,13 +344,6 @@
344344
"type": "boolean",
345345
"default": true,
346346
"description": "%settings.filesChangedEnabled.description%"
347-
},
348-
"roo-cline.filesChangedMaxDisplayFiles": {
349-
"type": "number",
350-
"default": 50,
351-
"minimum": 10,
352-
"maximum": 200,
353-
"description": "%settings.filesChangedMaxDisplayFiles.description%"
354347
}
355348
}
356349
}

src/package.nls.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,5 @@
3333
"settings.customStoragePath.description": "Custom storage path. Leave empty to use the default location. Supports absolute paths (e.g. 'D:\\RooCodeStorage')",
3434
"settings.enableCodeActions.description": "Enable Roo Code quick fixes",
3535
"settings.autoImportSettingsPath.description": "Path to a RooCode configuration file to automatically import on extension startup. Supports absolute paths and paths relative to the home directory (e.g. '~/Documents/roo-code-settings.json'). Leave empty to disable auto-import.",
36-
"settings.filesChangedEnabled.description": "Show an overview of files modified by the AI during conversation",
37-
"settings.filesChangedMaxDisplayFiles.description": "Maximum number of files to display before enabling virtualization for performance (10-200)"
36+
"settings.filesChangedEnabled.description": "Show an overview of files modified by the AI during conversation"
3837
}

src/shared/ExtensionMessage.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,6 @@ export type ExtensionState = Pick<
273273
profileThresholds: Record<string, number>
274274
hasOpenedModeSelector: boolean
275275
filesChangedEnabled: boolean
276-
filesChangedMaxDisplayFiles: number
277276
}
278277

279278
export interface ClineSayTool {

src/shared/WebviewMessage.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,6 @@ export interface WebviewMessage {
181181
| "switchTab"
182182
| "shareTaskSuccess"
183183
| "filesChangedEnabled"
184-
| "filesChangedMaxDisplayFiles"
185184
text?: string
186185
tab?: "settings" | "history" | "mcp" | "modes" | "chat" | "marketplace" | "account"
187186
disabled?: boolean

webview-ui/src/components/file-changes/FilesChangedOverview.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,12 @@ const FilesChangedOverview: React.FC<FilesChangedOverviewProps> = ({
3232
onRejectAll,
3333
}) => {
3434
const { t } = useTranslation()
35-
const { filesChangedEnabled, filesChangedMaxDisplayFiles } = useExtensionState()
35+
const { filesChangedEnabled } = useExtensionState()
3636
const files = changeset.files
3737
const [isCollapsed, setIsCollapsed] = React.useState(true)
3838

3939
// Performance optimization: Use virtualization for large file lists
40-
const VIRTUALIZATION_THRESHOLD = filesChangedMaxDisplayFiles || 50
40+
const VIRTUALIZATION_THRESHOLD = 50
4141
const ITEM_HEIGHT = 60 // Approximate height of each file item
4242
const MAX_VISIBLE_ITEMS = 10
4343
const [scrollTop, setScrollTop] = React.useState(0)

webview-ui/src/components/settings/InterfaceSettings.tsx

Lines changed: 2 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,14 @@ import { Monitor } from "lucide-react"
66
import { SetCachedStateField } from "./types"
77
import { SectionHeader } from "./SectionHeader"
88
import { Section } from "./Section"
9-
import { Slider } from "../ui"
109
import { vscode } from "@/utils/vscode"
1110

1211
type InterfaceSettingsProps = HTMLAttributes<HTMLDivElement> & {
1312
filesChangedEnabled?: boolean
14-
filesChangedMaxDisplayFiles?: number
15-
setCachedStateField: SetCachedStateField<"filesChangedEnabled" | "filesChangedMaxDisplayFiles">
13+
setCachedStateField: SetCachedStateField<"filesChangedEnabled">
1614
}
1715

18-
export const InterfaceSettings = ({
19-
filesChangedEnabled,
20-
filesChangedMaxDisplayFiles,
21-
setCachedStateField,
22-
...props
23-
}: InterfaceSettingsProps) => {
16+
export const InterfaceSettings = ({ filesChangedEnabled, setCachedStateField, ...props }: InterfaceSettingsProps) => {
2417
const { t } = useAppTranslation()
2518

2619
return (
@@ -57,32 +50,6 @@ export const InterfaceSettings = ({
5750
{t("settings:interface.filesChanged.enabled.description")}
5851
</div>
5952
</div>
60-
61-
<div>
62-
<span className="block font-medium mb-1">
63-
{t("settings:interface.filesChanged.maxDisplayFiles.label")}
64-
</span>
65-
<div className="flex items-center gap-2">
66-
<Slider
67-
min={10}
68-
max={200}
69-
step={1}
70-
value={[filesChangedMaxDisplayFiles ?? 50]}
71-
onValueChange={([value]) => {
72-
setCachedStateField("filesChangedMaxDisplayFiles", value)
73-
vscode.postMessage({
74-
type: "filesChangedMaxDisplayFiles",
75-
value: value,
76-
})
77-
}}
78-
data-testid="files-changed-max-display-files-slider"
79-
/>
80-
<span className="w-10">{filesChangedMaxDisplayFiles ?? 50}</span>
81-
</div>
82-
<div className="text-vscode-descriptionForeground text-sm mt-1">
83-
{t("settings:interface.filesChanged.maxDisplayFiles.description")}
84-
</div>
85-
</div>
8653
</div>
8754
</Section>
8855
</div>

0 commit comments

Comments
 (0)