Skip to content

Commit 0035d95

Browse files
committed
fix broken styling of file list in commit view
adapt fileView to new html cdvFileView structure from Hide commit message box #3
1 parent f3d2aba commit 0035d95

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

web/main.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2709,7 +2709,7 @@ class GitGraphView {
27092709
}
27102710
}, () => this.saveState());
27112711

2712-
observeElemScroll('cdvFiles', expandedCommit.scrollTop.fileView, (scrollTop) => {
2712+
observeElemScroll('cdvFilesView', expandedCommit.scrollTop.fileView, (scrollTop) => {
27132713
if (this.expandedCommit === null) return;
27142714
this.expandedCommit.scrollTop.fileView = scrollTop;
27152715
if (this.expandedCommit.contextMenuOpen.fileView > -1) {
@@ -2908,7 +2908,7 @@ class GitGraphView {
29082908
* @param fileWasViewed Was the file viewed - if so, set it to be the last viewed file.
29092909
*/
29102910
private cdvUpdateFileState(file: GG.GitFileChange, fileElem: HTMLElement, isReviewed: boolean | null, fileWasViewed: boolean) {
2911-
const expandedCommit = this.expandedCommit, filesElem = document.getElementById('cdvFiles'), filePath = file.newFilePath;
2911+
const expandedCommit = this.expandedCommit, filesElem = document.getElementById('cdvFilesView'), filePath = file.newFilePath;
29122912
if (expandedCommit === null || expandedCommit.fileTree === null || filesElem === null) return;
29132913

29142914
if (fileWasViewed) {
@@ -2979,7 +2979,7 @@ class GitGraphView {
29792979
}
29802980

29812981
private changeFileViewType(type: GG.FileViewType) {
2982-
const expandedCommit = this.expandedCommit, filesElem = document.getElementById('cdvFiles');
2982+
const expandedCommit = this.expandedCommit, filesElem = document.getElementById('cdvFilesView');
29832983
if (expandedCommit === null || expandedCommit.fileTree === null || expandedCommit.fileChanges === null || filesElem === null) return;
29842984
GitGraphView.closeCdvContextMenuIfOpen(expandedCommit);
29852985
this.setFileViewType(type);
@@ -3301,7 +3301,7 @@ class GitGraphView {
33013301
}
33023302

33033303
private saveAndRenderCodeReview(codeReview: GG.CodeReview | null) {
3304-
let filesElem = document.getElementById('cdvFiles');
3304+
let filesElem = document.getElementById('cdvFilesView');
33053305
if (this.expandedCommit === null || this.expandedCommit.fileTree === null || filesElem === null) return;
33063306

33073307
this.expandedCommit.codeReview = codeReview;

0 commit comments

Comments
 (0)