added objects to be transfered from parser to db

This commit is contained in:
Austin Fulbright
2024-08-20 06:06:19 -04:00
parent 4ec0dcfe1f
commit d9d9cc9ddc
2 changed files with 26 additions and 7 deletions

View File

@@ -15,6 +15,7 @@ import { commitType } from './gitGraphTypes.js';
import { ImperativeState } from '../../utils/imperativeState.js';
import DEFAULT_CONFIG from '../../defaultConfig.js';
import type { GitGraphDiagramConfig } from '../../config.type.js';
interface GitGraphState {
commits: Map<string, Commit>;

View File

@@ -9,13 +9,31 @@ export const commitType = {
CHERRY_PICK: 4,
} as const;
export const gitcommitType = {
NORMAL: 0,
REVERSE: 1,
HIGHLIGHT: 2,
MERGE: 3,
CHERRY_PICK: 4,
} as const;
export interface CommitDB {
message: string;
id: string;
type: typeof commitType;
tags?: string[];
}
export interface BranchDB {
name: string;
order: number;
}
export interface MergeDB {
branch: string;
id: string;
type?: typeof commitType;
tags?: string[];
}
export interface CherryPickDB {
id: string;
targetId: string;
parent: string;
tags?: string[];
}
export interface Commit {
id: string;