-
Notifications
You must be signed in to change notification settings - Fork 272
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#7 Add setting to enable auto centering of the commit details view.
- Loading branch information
Showing
6 changed files
with
114 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,74 +1,75 @@ | ||
import { | ||
GitCommandStatus as GitCommandStatusX, | ||
GitCommitDetails as GitCommitDetailsX, | ||
GitCommitNode as GitCommitNodeX, | ||
GitFileChange as GitFileChangeX, | ||
GitFileChangeType as GitFileChangeTypeX, | ||
GitGraphViewSettings as GitGraphViewSettingsX, | ||
GitResetMode as GitResetModeX, | ||
RequestMessage as RequestMessageX, | ||
ResponseMessage as ResponseMessageX | ||
GitCommandStatus as GitCommandStatusX, | ||
GitCommitDetails as GitCommitDetailsX, | ||
GitCommitNode as GitCommitNodeX, | ||
GitFileChange as GitFileChangeX, | ||
GitFileChangeType as GitFileChangeTypeX, | ||
GitGraphViewSettings as GitGraphViewSettingsX, | ||
GitResetMode as GitResetModeX, | ||
RequestMessage as RequestMessageX, | ||
ResponseMessage as ResponseMessageX | ||
} from "../out/types"; | ||
|
||
declare global { | ||
/* Types from Backend */ | ||
type GitCommandStatus = GitCommandStatusX; | ||
type GitCommitDetails = GitCommitDetailsX; | ||
type GitCommitNode = GitCommitNodeX; | ||
type GitFileChange = GitFileChangeX; | ||
type GitFileChangeType = GitFileChangeTypeX; | ||
type GitGraphViewSettings = GitGraphViewSettingsX; | ||
type GitResetMode = GitResetModeX; | ||
type RequestMessage = RequestMessageX; | ||
type ResponseMessage = ResponseMessageX; | ||
/* Types from Backend */ | ||
type GitCommandStatus = GitCommandStatusX; | ||
type GitCommitDetails = GitCommitDetailsX; | ||
type GitCommitNode = GitCommitNodeX; | ||
type GitFileChange = GitFileChangeX; | ||
type GitFileChangeType = GitFileChangeTypeX; | ||
type GitGraphViewSettings = GitGraphViewSettingsX; | ||
type GitResetMode = GitResetModeX; | ||
type RequestMessage = RequestMessageX; | ||
type ResponseMessage = ResponseMessageX; | ||
|
||
/* Globals defined in Webview HTML content */ | ||
function acquireVsCodeApi(): any; | ||
var settings: GitGraphViewSettings; | ||
/* Globals defined in Webview HTML content */ | ||
function acquireVsCodeApi(): any; | ||
var settings: GitGraphViewSettings; | ||
|
||
/* Graph Interfaces */ | ||
interface Point { | ||
x: number; | ||
y: number; | ||
} | ||
interface Line { | ||
p1: Point; | ||
p2: Point; | ||
isCommitted: boolean; | ||
} | ||
interface Config { | ||
grid: { x: number, y: number, offsetX: number, offsetY: number }; | ||
colours: string[]; | ||
graphStyle: 'rounded' | 'angular'; | ||
initialLoadCommits: number; | ||
loadMoreCommits: number; | ||
} | ||
interface ContextMenuItem { | ||
title: string; | ||
onClick: () => void; | ||
} | ||
interface ExpandedCommit { | ||
id: number; | ||
hash: string; | ||
srcElem: HTMLElement | null; | ||
commitDetails: GitCommitDetails | null; | ||
fileTree: GitFolder | null; | ||
} | ||
/* Graph Interfaces */ | ||
interface Point { | ||
x: number; | ||
y: number; | ||
} | ||
interface Line { | ||
p1: Point; | ||
p2: Point; | ||
isCommitted: boolean; | ||
} | ||
interface Config { | ||
autoCenterCommitDetailsView: boolean; | ||
colours: string[]; | ||
graphStyle: 'rounded' | 'angular'; | ||
grid: { x: number, y: number, offsetX: number, offsetY: number }; | ||
initialLoadCommits: number; | ||
loadMoreCommits: number; | ||
} | ||
interface ContextMenuItem { | ||
title: string; | ||
onClick: () => void; | ||
} | ||
interface ExpandedCommit { | ||
id: number; | ||
hash: string; | ||
srcElem: HTMLElement | null; | ||
commitDetails: GitCommitDetails | null; | ||
fileTree: GitFolder | null; | ||
} | ||
|
||
/* Git Interfaces / Types */ | ||
interface GitFolder { | ||
type: 'folder'; | ||
name: string; | ||
folderPath: string; | ||
contents: GitFolderContents; | ||
open: boolean; | ||
} | ||
interface GitFile { | ||
type: 'file'; | ||
name: string; | ||
index: number; | ||
} | ||
type GitFolderOrFile = GitFolder | GitFile; | ||
type GitFolderContents = { [name: string]: GitFolderOrFile }; | ||
/* Git Interfaces / Types */ | ||
interface GitFolder { | ||
type: 'folder'; | ||
name: string; | ||
folderPath: string; | ||
contents: GitFolderContents; | ||
open: boolean; | ||
} | ||
interface GitFile { | ||
type: 'file'; | ||
name: string; | ||
index: number; | ||
} | ||
type GitFolderOrFile = GitFolder | GitFile; | ||
type GitFolderContents = { [name: string]: GitFolderOrFile }; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters