only_ever_generator 0.1.9 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -75,7 +75,10 @@ class GenerateCards {
|
|
|
75
75
|
parseFlashCard(data) {
|
|
76
76
|
let displayTitle = this.generateFlashCardDisplayTitle(data.card_content.front, data.card_content.back);
|
|
77
77
|
let flashCardData = {
|
|
78
|
-
type:
|
|
78
|
+
type: {
|
|
79
|
+
category: 'learning',
|
|
80
|
+
sub_type: data.type,
|
|
81
|
+
},
|
|
79
82
|
heading: data.card_reference,
|
|
80
83
|
displayTitle: displayTitle,
|
|
81
84
|
content: {
|
|
@@ -102,7 +105,10 @@ class GenerateCards {
|
|
|
102
105
|
}
|
|
103
106
|
let displayTitle = this.generateMcqCardDisplayTitle(data.card_content.prompt, mcqAnswers);
|
|
104
107
|
let mcqCard = {
|
|
105
|
-
type:
|
|
108
|
+
type: {
|
|
109
|
+
category: 'learning',
|
|
110
|
+
sub_type: data.type,
|
|
111
|
+
},
|
|
106
112
|
heading: data.card_reference,
|
|
107
113
|
displayTitle: displayTitle,
|
|
108
114
|
content: {
|
|
@@ -129,7 +135,10 @@ class GenerateCards {
|
|
|
129
135
|
parseClozeCard(data) {
|
|
130
136
|
let displayTitle = this.generateClozeCardDisplayTitle(data.card_content.text, data.card_content.options);
|
|
131
137
|
let clozeCardData = {
|
|
132
|
-
type:
|
|
138
|
+
type: {
|
|
139
|
+
category: 'learning',
|
|
140
|
+
sub_type: data.type,
|
|
141
|
+
},
|
|
133
142
|
heading: data.card_reference,
|
|
134
143
|
displayTitle: displayTitle,
|
|
135
144
|
content: {
|
|
@@ -171,7 +180,10 @@ class GenerateCards {
|
|
|
171
180
|
}
|
|
172
181
|
let displayTitle = this.generateMatchCardDisplayTitle(transformedData);
|
|
173
182
|
let matchCard = {
|
|
174
|
-
type:
|
|
183
|
+
type: {
|
|
184
|
+
category: 'learning',
|
|
185
|
+
sub_type: data.type,
|
|
186
|
+
},
|
|
175
187
|
heading: cardData.card_reference,
|
|
176
188
|
content: transformedData,
|
|
177
189
|
// content: cardData.card_content,
|
package/package.json
CHANGED
|
@@ -67,7 +67,10 @@ if(unparsedTestCards !== undefined && unparsedTestCards.length != 0) {
|
|
|
67
67
|
data.card_content.back
|
|
68
68
|
);
|
|
69
69
|
let flashCardData = {
|
|
70
|
-
type:
|
|
70
|
+
type: {
|
|
71
|
+
category: 'learning',
|
|
72
|
+
sub_type: data.type,
|
|
73
|
+
},
|
|
71
74
|
heading: data.card_reference,
|
|
72
75
|
displayTitle: displayTitle,
|
|
73
76
|
content: {
|
|
@@ -100,7 +103,10 @@ if(unparsedTestCards !== undefined && unparsedTestCards.length != 0) {
|
|
|
100
103
|
mcqAnswers
|
|
101
104
|
);
|
|
102
105
|
let mcqCard = {
|
|
103
|
-
|
|
106
|
+
type: {
|
|
107
|
+
category: 'learning',
|
|
108
|
+
sub_type: data.type,
|
|
109
|
+
},
|
|
104
110
|
heading: data.card_reference,
|
|
105
111
|
displayTitle: displayTitle,
|
|
106
112
|
content: {
|
|
@@ -133,7 +139,10 @@ if(unparsedTestCards !== undefined && unparsedTestCards.length != 0) {
|
|
|
133
139
|
data.card_content.options
|
|
134
140
|
);
|
|
135
141
|
let clozeCardData = {
|
|
136
|
-
type:
|
|
142
|
+
type: {
|
|
143
|
+
category: 'learning',
|
|
144
|
+
sub_type: data.type,
|
|
145
|
+
},
|
|
137
146
|
heading: data.card_reference,
|
|
138
147
|
displayTitle: displayTitle,
|
|
139
148
|
content: {
|
|
@@ -180,7 +189,10 @@ if(unparsedTestCards !== undefined && unparsedTestCards.length != 0) {
|
|
|
180
189
|
}
|
|
181
190
|
let displayTitle = this.generateMatchCardDisplayTitle(transformedData);
|
|
182
191
|
let matchCard = {
|
|
183
|
-
type:
|
|
192
|
+
type: {
|
|
193
|
+
category: 'learning',
|
|
194
|
+
sub_type: data.type,
|
|
195
|
+
},
|
|
184
196
|
heading: cardData.card_reference,
|
|
185
197
|
content: transformedData,
|
|
186
198
|
// content: cardData.card_content,
|