Compare commits

...
Author SHA1 Message Date
l0ng-ai 1dbca0388e Merge remote-tracking branch 'origin/main' into feat/project-view-hscroll-option
# Conflicts:
#	src/platform/locales/text/en.json
#	src/platform/locales/text/zh.json
2026-11-19 17:55:45 +08:00
l0ng-ai bb118e3159 feat(project-view): option to turn off horizontal scrolling
With long names or deep nesting the whole Project view scrolled sideways and
cut file names on the left. The view options get Horizontal Scrolling (on by
default, as IDEA scrolls); off clips long rows like the other trees, with the
full path in the row tooltip.
2026-11-19 17:44:40 +08:00
5 changed files with 10 additions and 4 deletions

No files matched your search

+2 -1
View File
@@ -44,6 +44,7 @@ export const OPTION_LABELS: Array<[ToggleOption, string]> = [
["showExcluded", "Show Excluded Files"],
["showMembers", "Show Members"],
["showRootPaths", "Show Root Paths"],
["horizontalScroll", "Horizontal Scrolling"],
["compact", "Compact Middle Packages"],
["foldersFirst", "Sort Folders First"],
["autoscrollFromSource", "Always Select Opened File"],
@@ -54,7 +55,7 @@ export const OPTION_LABELS: Array<[ToggleOption, string]> = [
];
/** The first entries of OPTION_LABELS are Appearance options, the rest Behavior. */
const APPEARANCE_OPTIONS = 6;
const APPEARANCE_OPTIONS = 7;
/** Header controls of the Project tool window (IDEA: Locate, Expand/Collapse All). */
export function ProjectHeaderActions() {
+1 -1
View File
@@ -907,7 +907,7 @@ export function ProjectView() {
</div>
)}
<Tree<ProjectNode>
horizontalScroll
horizontalScroll={options.horizontalScroll}
aria-label="Project"
focusContext="projectViewFocus"
handleRef={setTreeHandle}
+3
View File
@@ -63,6 +63,8 @@ export interface ViewOptions extends TreeOptions {
showMembers: boolean;
/** Show the location of each project root beside its name. */
showRootPaths: boolean;
/** Rows wider than the pane scroll sideways; off clips long names (VS Code's horizontal scrolling). */
horizontalScroll: boolean;
}
export const DEFAULT_VIEW_OPTIONS: ViewOptions = {
@@ -75,6 +77,7 @@ export const DEFAULT_VIEW_OPTIONS: ViewOptions = {
previewTab: false,
showMembers: false,
showRootPaths: true,
horizontalScroll: true,
};
function storedOptions(): ViewOptions {
+2 -1
View File
@@ -2634,5 +2634,6 @@
"No branches were updated": "No branches were updated",
"Selected branches are up-to-date": "Selected branches are up-to-date",
"Use application title as tab name": "Use application title as tab name",
"When command is running": "When command is running"
"When command is running": "When command is running",
"Horizontal Scrolling": "Horizontal Scrolling"
}
+2 -1
View File
@@ -9013,5 +9013,6 @@
"No branches were updated": "没有分支被更新",
"Selected branches are up-to-date": "所选分支都是最新的",
"Use application title as tab name": "使用应用标题作为标签页名称",
"When command is running": "命令运行时"
"When command is running": "命令运行时",
"Horizontal Scrolling": "横向滚动"
}