Skip to content

Commit

Permalink
Merge pull request #95 from Hyperskill-Community/create-card
Browse files Browse the repository at this point in the history
removed default values for mcq and q&a cards.
  • Loading branch information
Averageasd authored Apr 6, 2024
2 parents 9c078ab + f5884e4 commit eecfa30
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions frontend/src/feature/cards/model/card.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,16 +53,16 @@ export const generateNewCard = (cardType: CardType) : Card =>{
switch (cardType) {
case CardType.SIMPLEQA:
card.type = CardType.SIMPLEQA;
card.answer = 'New card';
card.answer = '';
break;
case CardType.MULTIPLE_CHOICE:
card.type = CardType.MULTIPLE_CHOICE;
card.correctOptions = [0];
card.options = ['choice 1'];
card.correctOptions = [];
card.options = [''];
break;
case CardType.SINGLE_CHOICE:
card.type = CardType.SINGLE_CHOICE;
card.options = ['choice 1'];
card.options = [''];
card.correctOption = 0;
break;
default:
Expand Down

0 comments on commit eecfa30

Please sign in to comment.