feat: Don't forget about the adverbs

This commit is contained in:
Alexander Polynomdivision
2018-10-02 15:49:53 +02:00
parent 2971069954
commit d6f5ef4cc5
4 changed files with 47 additions and 14 deletions

View File

@@ -29,6 +29,10 @@ export interface IAdjektivData {
endung_n: string;
};
export interface IAdverbData {
grundform: string;
};
export interface IVocab {
// If a word has multiple meanings
german: string[];
@@ -36,7 +40,7 @@ export interface IVocab {
mnemonic?: string;
type: VocabType;
latin: INomenData | IVerbData | IAdjektivData;
latin: INomenData | IVerbData | IAdjektivData | IAdverbData;
// This number is unique across all vocabulary items
id: number;
@@ -152,9 +156,14 @@ export function vocabToReviewCard(vocab: IVocab): IReviewCard[] {
qtype: ReviewQType.ADJ_ENDUNG_N,
id: vocab.id,
}];
default:
// TODO: Remove after removing Adverbien
return [];
case VocabType.ADVERB:
return [{
// Latin -> German
question: vocab.latin.grundform,
answers: vocab.german,
qtype: ReviewQType.GERMAN,
id: vocab.id,
}];
}
}