@coorpacademy/app-review 0.7.7-alpha.13 → 0.7.7-alpha.61
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.
- package/es/reducers/data/current-skill.d.ts +5 -0
- package/es/reducers/data/current-skill.js +13 -0
- package/es/reducers/data/index.d.ts +4 -1
- package/es/reducers/data/index.js +10 -1
- package/es/reducers/index.d.ts +2 -1
- package/es/services/fetch-skill.js +2 -1
- package/es/types/common.d.ts +5 -2
- package/es/views/skills/index.js +4 -2
- package/es/views/slides/index.js +9 -7
- package/es/views/slides/map-api-slide-to-ui.d.ts +2 -2
- package/es/views/slides/map-api-slide-to-ui.js +14 -11
- package/lib/reducers/data/current-skill.d.ts +5 -0
- package/lib/reducers/data/current-skill.js +15 -0
- package/lib/reducers/data/index.d.ts +4 -1
- package/lib/reducers/data/index.js +10 -1
- package/lib/reducers/index.d.ts +2 -1
- package/lib/services/fetch-skill.js +2 -1
- package/lib/types/common.d.ts +5 -2
- package/lib/views/skills/index.js +4 -2
- package/lib/views/slides/index.js +9 -7
- package/lib/views/slides/map-api-slide-to-ui.d.ts +2 -2
- package/lib/views/slides/map-api-slide-to-ui.js +14 -11
- package/locales/.mtslconfig.json +1 -0
- package/locales/cs/review.json +4 -1
- package/locales/de/review.json +4 -1
- package/locales/en/review.json +3 -0
- package/locales/es/review.json +4 -1
- package/locales/fr/review.json +4 -1
- package/locales/hr/review.json +4 -1
- package/locales/hu/review.json +4 -1
- package/locales/id/review.json +4 -1
- package/locales/it/review.json +4 -1
- package/locales/ja/review.json +4 -1
- package/locales/ko/review.json +4 -1
- package/locales/nl/review.json +4 -1
- package/locales/pl/review.json +4 -1
- package/locales/pt/review.json +4 -1
- package/locales/ro/review.json +4 -1
- package/locales/ru/review.json +4 -1
- package/locales/sk/review.json +4 -1
- package/locales/th/review.json +4 -1
- package/locales/tl/review.json +4 -1
- package/locales/tr/review.json +4 -1
- package/locales/uk/review.json +4 -1
- package/locales/vi/review.json +4 -1
- package/locales/zh/review.json +4 -1
- package/locales/zh_TW/review.json +4 -1
- package/package.json +4 -4
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ReceivedSkill } from '../../actions/api/fetch-skill';
|
|
2
|
+
import { Skill } from '../../types/common';
|
|
3
|
+
export declare type CurrentSkillState = Skill | null;
|
|
4
|
+
declare const reducer: (state: CurrentSkillState | undefined, action: ReceivedSkill) => CurrentSkillState;
|
|
5
|
+
export default reducer;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { SKILL_FETCH_SUCCESS } from '../../actions/api/fetch-skill';
|
|
2
|
+
const initialState = null;
|
|
3
|
+
const reducer = (
|
|
4
|
+
// eslint-disable-next-line default-param-last
|
|
5
|
+
state = initialState, action) => {
|
|
6
|
+
switch (action.type) {
|
|
7
|
+
case SKILL_FETCH_SUCCESS:
|
|
8
|
+
return action.payload;
|
|
9
|
+
default:
|
|
10
|
+
return state;
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
export default reducer;
|
|
@@ -4,6 +4,7 @@ import { SkillsState } from './skills';
|
|
|
4
4
|
import { SlidesState } from './slides';
|
|
5
5
|
import { TokenState } from './token';
|
|
6
6
|
import { RankState } from './rank';
|
|
7
|
+
import { CurrentSkillState } from './current-skill';
|
|
7
8
|
export declare type DataState = {
|
|
8
9
|
corrections: CorrectionsState;
|
|
9
10
|
progression: ProgressionState;
|
|
@@ -11,6 +12,7 @@ export declare type DataState = {
|
|
|
11
12
|
slides: SlidesState;
|
|
12
13
|
token: TokenState;
|
|
13
14
|
rank: RankState;
|
|
15
|
+
currentSkill: CurrentSkillState;
|
|
14
16
|
};
|
|
15
17
|
declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
16
18
|
corrections: CorrectionsState;
|
|
@@ -19,5 +21,6 @@ declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
|
19
21
|
slides: SlidesState;
|
|
20
22
|
token: string;
|
|
21
23
|
rank: RankState;
|
|
22
|
-
|
|
24
|
+
currentSkill: CurrentSkillState;
|
|
25
|
+
}>, import("../../actions/api/fetch-skill").ReceivedSkill | import("../../actions/api/post-progression").FetchProgression | import("../../actions/api/post-progression").ReceivedProgression | import("./corrections").CorrectionsAction | import("../../actions/api/fetch-rank").RankAction | import("../../actions/api/post-answer").PostAnswerSuccessAction | import("../../actions/api/fetch-skills").ReceivedSkills | import("./slides").SlidesAction | import("../../actions/data/token").StoreToken>;
|
|
23
26
|
export default _default;
|
|
@@ -5,4 +5,13 @@ import skills from './skills';
|
|
|
5
5
|
import slides from './slides';
|
|
6
6
|
import token from './token';
|
|
7
7
|
import rank from './rank';
|
|
8
|
-
|
|
8
|
+
import currentSkill from './current-skill';
|
|
9
|
+
export default combineReducers({
|
|
10
|
+
corrections,
|
|
11
|
+
progression,
|
|
12
|
+
skills,
|
|
13
|
+
slides,
|
|
14
|
+
token,
|
|
15
|
+
rank,
|
|
16
|
+
currentSkill
|
|
17
|
+
});
|
package/es/reducers/index.d.ts
CHANGED
|
@@ -12,6 +12,7 @@ declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
|
12
12
|
slides: import("./data/slides").SlidesState;
|
|
13
13
|
token: string;
|
|
14
14
|
rank: import("./data/rank").RankState;
|
|
15
|
+
currentSkill: import("./data/current-skill").CurrentSkillState;
|
|
15
16
|
}>;
|
|
16
17
|
ui: import("redux").CombinedState<{
|
|
17
18
|
currentSlideRef: string;
|
|
@@ -23,7 +24,7 @@ declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
|
23
24
|
showButtonRevising: boolean;
|
|
24
25
|
showCongrats: boolean;
|
|
25
26
|
}>;
|
|
26
|
-
}>, import("../actions/ui/slides").SetCurrentSlideAction | import("../actions/api/post-progression").FetchProgression | import("../actions/api/post-progression").ReceivedProgression | import("./data/corrections").CorrectionsAction | import("../actions/api/fetch-rank").RankAction | import("../actions/api/fetch-slides-to-review-by-skill-ref").ReceivedSlidesToReviewBySkillRef | import("../actions/api/post-answer").PostAnswerRequestAction | import("../actions/api/post-answer").PostAnswerSuccessAction | import("../actions/api/fetch-skills").ReceivedSkills | import("./data/slides").SlidesAction | import("../actions/data/token").StoreToken | import("../actions/ui/next-slide").NextSlideAction | import("../actions/ui/navigation").NavigateToAction | import("../actions/ui/navigation").NavigateBackAction | import("../actions/ui/answers").EditAnswerAction | {
|
|
27
|
+
}>, import("../actions/ui/slides").SetCurrentSlideAction | import("../actions/api/fetch-skill").ReceivedSkill | import("../actions/api/post-progression").FetchProgression | import("../actions/api/post-progression").ReceivedProgression | import("./data/corrections").CorrectionsAction | import("../actions/api/fetch-rank").RankAction | import("../actions/api/fetch-slides-to-review-by-skill-ref").ReceivedSlidesToReviewBySkillRef | import("../actions/api/post-answer").PostAnswerRequestAction | import("../actions/api/post-answer").PostAnswerSuccessAction | import("../actions/api/fetch-skills").ReceivedSkills | import("./data/slides").SlidesAction | import("../actions/data/token").StoreToken | import("../actions/ui/next-slide").NextSlideAction | import("../actions/ui/navigation").NavigateToAction | import("../actions/ui/navigation").NavigateBackAction | import("../actions/ui/answers").EditAnswerAction | {
|
|
27
28
|
type: "@@ui/OPEN_POPIN";
|
|
28
29
|
} | {
|
|
29
30
|
type: "@@ui/CLOSE_POPIN";
|
|
@@ -6,5 +6,6 @@ export const fetchSkill = async (skillRef, token) => {
|
|
|
6
6
|
const response = await crossFetch(`${host}/api/v2/skills?conditions={"ref":"${skillRef}"}`, {
|
|
7
7
|
headers: { authorization: token }
|
|
8
8
|
});
|
|
9
|
-
|
|
9
|
+
const skills = await toJSON(response);
|
|
10
|
+
return skills[0];
|
|
10
11
|
};
|
package/es/types/common.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
export declare type ViewName = 'skills' | 'onboarding' | 'slides' | 'loader';
|
|
2
|
+
export interface Translate {
|
|
3
|
+
(key: string, data?: Record<string, string>): string;
|
|
4
|
+
}
|
|
2
5
|
export declare type ChoiceFromAPI = {
|
|
3
6
|
_id: string;
|
|
4
7
|
id?: string;
|
|
@@ -146,13 +149,13 @@ export declare type Options = {
|
|
|
146
149
|
services: Services;
|
|
147
150
|
};
|
|
148
151
|
export declare type ConnectedOptions = {
|
|
149
|
-
translate:
|
|
152
|
+
translate: Translate;
|
|
150
153
|
onQuitClick: () => void;
|
|
151
154
|
};
|
|
152
155
|
export declare type AppOptions = ConnectedOptions & {
|
|
153
156
|
token: string;
|
|
154
157
|
skillRef?: string;
|
|
155
|
-
services
|
|
158
|
+
services?: Services;
|
|
156
159
|
callbackOnViewChanged?: (viewName: ViewName) => void;
|
|
157
160
|
};
|
|
158
161
|
export declare type ThunkOptions = {
|
package/es/views/skills/index.js
CHANGED
|
@@ -12,8 +12,10 @@ export const mapStateToSkillsProps = (state, options) => {
|
|
|
12
12
|
skillAriaLabel: skill.name,
|
|
13
13
|
buttonLabel: translate('Review this skill'),
|
|
14
14
|
buttonAriaLabel: translate('Review this skill'),
|
|
15
|
-
reviseLabel: translate('{{count}} questions to review', { count: skill.slidesToReview }),
|
|
16
|
-
reviseAriaLabel: translate('{{count}} questions to review', {
|
|
15
|
+
reviseLabel: translate('{{count}} questions to review', { count: `${skill.slidesToReview}` }),
|
|
16
|
+
reviseAriaLabel: translate('{{count}} questions to review', {
|
|
17
|
+
count: `${skill.slidesToReview}`
|
|
18
|
+
}),
|
|
17
19
|
// eslint-disable-next-line no-console
|
|
18
20
|
onClick: () => console.log('@todo plug dispatcher select skill')
|
|
19
21
|
})),
|
package/es/views/slides/index.js
CHANGED
|
@@ -85,7 +85,7 @@ const buildStackSlides = (state, dispatch, options) => {
|
|
|
85
85
|
if (!slideFromAPI)
|
|
86
86
|
return set(index, { ...uiSlide, position }, acc);
|
|
87
87
|
const answers = getOr([], ['ui', 'answers', slideRef], state);
|
|
88
|
-
const { questionText, answerUI } = mapApiSlideToUi(dispatch)(slideFromAPI, answers);
|
|
88
|
+
const { questionText, answerUI } = mapApiSlideToUi(dispatch, translate)(slideFromAPI, answers);
|
|
89
89
|
const { title: parentContentTitle, type: parentContentType } = slideFromAPI.parentContentTitle;
|
|
90
90
|
const isCurrentSlideRef = currentSlideRef === slideRef;
|
|
91
91
|
const slideUI = get(['ui', 'slide', slideRef], state);
|
|
@@ -177,7 +177,8 @@ export const buildStepItems = (state) => {
|
|
|
177
177
|
});
|
|
178
178
|
return steps;
|
|
179
179
|
};
|
|
180
|
-
const getCorrectionPopinProps = (dispatch) => (isCorrect, correctAnswer, klf, translate) => {
|
|
180
|
+
const getCorrectionPopinProps = (dispatch) => (isCorrect, correctAnswer, klf, translate, endReview) => {
|
|
181
|
+
const nextLabel = endReview ? translate('Continue') : translate('Next Question');
|
|
181
182
|
return {
|
|
182
183
|
klf: isCorrect
|
|
183
184
|
? undefined
|
|
@@ -188,11 +189,11 @@ const getCorrectionPopinProps = (dispatch) => (isCorrect, correctAnswer, klf, tr
|
|
|
188
189
|
resultLabel: isCorrect ? translate('Correct Answer') : translate('Wrong Answer'),
|
|
189
190
|
information: {
|
|
190
191
|
label: isCorrect ? translate('KLF') : translate('Correct Answer'),
|
|
191
|
-
message: isCorrect ? klf : join(',', correctAnswer)
|
|
192
|
+
message: isCorrect ? klf : join(', ', correctAnswer)
|
|
192
193
|
},
|
|
193
194
|
next: {
|
|
194
|
-
'aria-label':
|
|
195
|
-
label:
|
|
195
|
+
'aria-label': nextLabel,
|
|
196
|
+
label: nextLabel,
|
|
196
197
|
onClick: () => {
|
|
197
198
|
dispatch(nextSlide);
|
|
198
199
|
}
|
|
@@ -319,10 +320,11 @@ export const mapStateToSlidesProps = (state, dispatch, options) => {
|
|
|
319
320
|
const klf = getOr('', ['data', 'slides', currentSlideRef, 'klf'], state);
|
|
320
321
|
const showQuitPopin = get(['ui', 'showQuitPopin'], state);
|
|
321
322
|
const showCongrats = get(['ui', 'showCongrats'], state);
|
|
323
|
+
const skillName = getOr('', ['data', 'currentSkill', 'name'], state);
|
|
322
324
|
return {
|
|
323
325
|
header: {
|
|
324
326
|
mode: translate('Review Title'),
|
|
325
|
-
skillName
|
|
327
|
+
skillName,
|
|
326
328
|
onQuitClick: () => dispatch(openQuitPopin),
|
|
327
329
|
'aria-label': 'aria-header-wrapper',
|
|
328
330
|
closeButtonAriaLabel: 'aria-close-button',
|
|
@@ -339,7 +341,7 @@ export const mapStateToSlidesProps = (state, dispatch, options) => {
|
|
|
339
341
|
}
|
|
340
342
|
},
|
|
341
343
|
correctionPopinProps: correction &&
|
|
342
|
-
getCorrectionPopinProps(dispatch)(isCorrect, correction.correctAnswer, klf, translate),
|
|
344
|
+
getCorrectionPopinProps(dispatch)(isCorrect, correction.correctAnswer, klf, translate, endReview),
|
|
343
345
|
endReview: endReview && state.ui.showCongrats
|
|
344
346
|
},
|
|
345
347
|
congrats: buildCongratsProps(state, dispatch, options),
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Dispatch } from 'redux';
|
|
2
2
|
import { AnswerUI } from '../../types/slides';
|
|
3
|
-
import { Question, SlideFromAPI } from '../../types/common';
|
|
3
|
+
import { Question, SlideFromAPI, Translate } from '../../types/common';
|
|
4
4
|
export declare const getQuestionType: (question: Question) => Question['type'];
|
|
5
|
-
export declare const mapApiSlideToUi: (dispatch: Dispatch) => (slide: SlideFromAPI, answers: string[]) => {
|
|
5
|
+
export declare const mapApiSlideToUi: (dispatch: Dispatch, translate: Translate) => (slide: SlideFromAPI, answers: string[]) => {
|
|
6
6
|
questionText: string;
|
|
7
7
|
answerUI: AnswerUI;
|
|
8
8
|
};
|
|
@@ -54,11 +54,11 @@ const updateTemplateAnswer = (text, _answers, index, max) => {
|
|
|
54
54
|
const answers = isEmpty(_answers) ? times(constant(undefined), max) : _answers;
|
|
55
55
|
return map(a => (isNil(a) ? '' : a), set(index, text, answers));
|
|
56
56
|
};
|
|
57
|
-
const templateTextProps = (dispatch, answers, choice, index, maxLength) => {
|
|
57
|
+
const templateTextProps = (dispatch, translate, answers, choice, index, maxLength) => {
|
|
58
58
|
return {
|
|
59
59
|
type: 'text',
|
|
60
60
|
name: getOr('', 'name', choice),
|
|
61
|
-
placeholder: 'Type here',
|
|
61
|
+
placeholder: translate('Type here'),
|
|
62
62
|
value: get(index, answers),
|
|
63
63
|
onChange: (text) => {
|
|
64
64
|
const newAnswers = updateTemplateAnswer(text, answers, index, maxLength);
|
|
@@ -66,10 +66,10 @@ const templateTextProps = (dispatch, answers, choice, index, maxLength) => {
|
|
|
66
66
|
}
|
|
67
67
|
};
|
|
68
68
|
};
|
|
69
|
-
const templateSelectProps = (dispatch, answers, choice, index, maxLength) => {
|
|
69
|
+
const templateSelectProps = (dispatch, translate, answers, choice, index, maxLength) => {
|
|
70
70
|
const answer = get(index, answers);
|
|
71
71
|
const temporaryOption = {
|
|
72
|
-
name: 'Select an answer',
|
|
72
|
+
name: translate('Select an answer'),
|
|
73
73
|
value: '',
|
|
74
74
|
validOption: false,
|
|
75
75
|
selected: true
|
|
@@ -93,15 +93,15 @@ const templateSelectProps = (dispatch, answers, choice, index, maxLength) => {
|
|
|
93
93
|
options: isEmpty(answer) ? concat([temporaryOption], selectOptions) : selectOptions
|
|
94
94
|
};
|
|
95
95
|
};
|
|
96
|
-
const templateProps = (dispatch) => (answers, question) => {
|
|
96
|
+
const templateProps = (dispatch, translate) => (answers, question) => {
|
|
97
97
|
const choices = question.content.choices;
|
|
98
98
|
const maxLength = size(choices);
|
|
99
99
|
return {
|
|
100
100
|
type: 'template',
|
|
101
101
|
template: get('content.template', question),
|
|
102
102
|
answers: choices.map((choice, index) => choice.type === 'text'
|
|
103
|
-
? templateTextProps(dispatch, answers, choice, index, maxLength)
|
|
104
|
-
: templateSelectProps(dispatch, answers, choice, index, maxLength))
|
|
103
|
+
? templateTextProps(dispatch, translate, answers, choice, index, maxLength)
|
|
104
|
+
: templateSelectProps(dispatch, translate, answers, choice, index, maxLength))
|
|
105
105
|
};
|
|
106
106
|
};
|
|
107
107
|
const basicProps = (dispatch) => (answers, question) => {
|
|
@@ -144,7 +144,7 @@ const sliderProps = (dispatch) => (answers, question) => {
|
|
|
144
144
|
};
|
|
145
145
|
export const getQuestionType = (question) => question.type;
|
|
146
146
|
const getHelp = (slide) => get('question.explanation', slide);
|
|
147
|
-
const getAnswerUIModel = (question, answers, dispatch) => {
|
|
147
|
+
const getAnswerUIModel = (question, answers, dispatch, translate) => {
|
|
148
148
|
const type = getQuestionType(question);
|
|
149
149
|
switch (type) {
|
|
150
150
|
case 'qcm':
|
|
@@ -156,17 +156,20 @@ const getAnswerUIModel = (question, answers, dispatch) => {
|
|
|
156
156
|
case 'basic':
|
|
157
157
|
return basicProps(dispatch)(answers, question);
|
|
158
158
|
case 'template':
|
|
159
|
-
return templateProps(dispatch)(answers, question);
|
|
159
|
+
return templateProps(dispatch, translate)(answers, question);
|
|
160
160
|
case 'slider':
|
|
161
161
|
return sliderProps(dispatch)(answers, question);
|
|
162
162
|
default:
|
|
163
163
|
throw new Error(`${type} is not an handled question.type`);
|
|
164
164
|
}
|
|
165
165
|
};
|
|
166
|
-
export const mapApiSlideToUi = (dispatch) => (slide, answers) => {
|
|
166
|
+
export const mapApiSlideToUi = (dispatch, translate) => (slide, answers) => {
|
|
167
167
|
const questionText = getOr('', 'question.header', slide);
|
|
168
168
|
return {
|
|
169
169
|
questionText,
|
|
170
|
-
answerUI: {
|
|
170
|
+
answerUI: {
|
|
171
|
+
model: getAnswerUIModel(slide.question, answers, dispatch, translate),
|
|
172
|
+
help: getHelp(slide)
|
|
173
|
+
}
|
|
171
174
|
};
|
|
172
175
|
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ReceivedSkill } from '../../actions/api/fetch-skill';
|
|
2
|
+
import { Skill } from '../../types/common';
|
|
3
|
+
export declare type CurrentSkillState = Skill | null;
|
|
4
|
+
declare const reducer: (state: CurrentSkillState | undefined, action: ReceivedSkill) => CurrentSkillState;
|
|
5
|
+
export default reducer;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const fetch_skill_1 = require("../../actions/api/fetch-skill");
|
|
4
|
+
const initialState = null;
|
|
5
|
+
const reducer = (
|
|
6
|
+
// eslint-disable-next-line default-param-last
|
|
7
|
+
state = initialState, action) => {
|
|
8
|
+
switch (action.type) {
|
|
9
|
+
case fetch_skill_1.SKILL_FETCH_SUCCESS:
|
|
10
|
+
return action.payload;
|
|
11
|
+
default:
|
|
12
|
+
return state;
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
exports.default = reducer;
|
|
@@ -4,6 +4,7 @@ import { SkillsState } from './skills';
|
|
|
4
4
|
import { SlidesState } from './slides';
|
|
5
5
|
import { TokenState } from './token';
|
|
6
6
|
import { RankState } from './rank';
|
|
7
|
+
import { CurrentSkillState } from './current-skill';
|
|
7
8
|
export declare type DataState = {
|
|
8
9
|
corrections: CorrectionsState;
|
|
9
10
|
progression: ProgressionState;
|
|
@@ -11,6 +12,7 @@ export declare type DataState = {
|
|
|
11
12
|
slides: SlidesState;
|
|
12
13
|
token: TokenState;
|
|
13
14
|
rank: RankState;
|
|
15
|
+
currentSkill: CurrentSkillState;
|
|
14
16
|
};
|
|
15
17
|
declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
16
18
|
corrections: CorrectionsState;
|
|
@@ -19,5 +21,6 @@ declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
|
19
21
|
slides: SlidesState;
|
|
20
22
|
token: string;
|
|
21
23
|
rank: RankState;
|
|
22
|
-
|
|
24
|
+
currentSkill: CurrentSkillState;
|
|
25
|
+
}>, import("../../actions/api/fetch-skill").ReceivedSkill | import("../../actions/api/post-progression").FetchProgression | import("../../actions/api/post-progression").ReceivedProgression | import("./corrections").CorrectionsAction | import("../../actions/api/fetch-rank").RankAction | import("../../actions/api/post-answer").PostAnswerSuccessAction | import("../../actions/api/fetch-skills").ReceivedSkills | import("./slides").SlidesAction | import("../../actions/data/token").StoreToken>;
|
|
23
26
|
export default _default;
|
|
@@ -10,4 +10,13 @@ const skills_1 = __importDefault(require("./skills"));
|
|
|
10
10
|
const slides_1 = __importDefault(require("./slides"));
|
|
11
11
|
const token_1 = __importDefault(require("./token"));
|
|
12
12
|
const rank_1 = __importDefault(require("./rank"));
|
|
13
|
-
|
|
13
|
+
const current_skill_1 = __importDefault(require("./current-skill"));
|
|
14
|
+
exports.default = (0, redux_1.combineReducers)({
|
|
15
|
+
corrections: corrections_1.default,
|
|
16
|
+
progression: progression_1.default,
|
|
17
|
+
skills: skills_1.default,
|
|
18
|
+
slides: slides_1.default,
|
|
19
|
+
token: token_1.default,
|
|
20
|
+
rank: rank_1.default,
|
|
21
|
+
currentSkill: current_skill_1.default
|
|
22
|
+
});
|
package/lib/reducers/index.d.ts
CHANGED
|
@@ -12,6 +12,7 @@ declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
|
12
12
|
slides: import("./data/slides").SlidesState;
|
|
13
13
|
token: string;
|
|
14
14
|
rank: import("./data/rank").RankState;
|
|
15
|
+
currentSkill: import("./data/current-skill").CurrentSkillState;
|
|
15
16
|
}>;
|
|
16
17
|
ui: import("redux").CombinedState<{
|
|
17
18
|
currentSlideRef: string;
|
|
@@ -23,7 +24,7 @@ declare const _default: import("redux").Reducer<import("redux").CombinedState<{
|
|
|
23
24
|
showButtonRevising: boolean;
|
|
24
25
|
showCongrats: boolean;
|
|
25
26
|
}>;
|
|
26
|
-
}>, import("../actions/ui/slides").SetCurrentSlideAction | import("../actions/api/post-progression").FetchProgression | import("../actions/api/post-progression").ReceivedProgression | import("./data/corrections").CorrectionsAction | import("../actions/api/fetch-rank").RankAction | import("../actions/api/fetch-slides-to-review-by-skill-ref").ReceivedSlidesToReviewBySkillRef | import("../actions/api/post-answer").PostAnswerRequestAction | import("../actions/api/post-answer").PostAnswerSuccessAction | import("../actions/api/fetch-skills").ReceivedSkills | import("./data/slides").SlidesAction | import("../actions/data/token").StoreToken | import("../actions/ui/next-slide").NextSlideAction | import("../actions/ui/navigation").NavigateToAction | import("../actions/ui/navigation").NavigateBackAction | import("../actions/ui/answers").EditAnswerAction | {
|
|
27
|
+
}>, import("../actions/ui/slides").SetCurrentSlideAction | import("../actions/api/fetch-skill").ReceivedSkill | import("../actions/api/post-progression").FetchProgression | import("../actions/api/post-progression").ReceivedProgression | import("./data/corrections").CorrectionsAction | import("../actions/api/fetch-rank").RankAction | import("../actions/api/fetch-slides-to-review-by-skill-ref").ReceivedSlidesToReviewBySkillRef | import("../actions/api/post-answer").PostAnswerRequestAction | import("../actions/api/post-answer").PostAnswerSuccessAction | import("../actions/api/fetch-skills").ReceivedSkills | import("./data/slides").SlidesAction | import("../actions/data/token").StoreToken | import("../actions/ui/next-slide").NextSlideAction | import("../actions/ui/navigation").NavigateToAction | import("../actions/ui/navigation").NavigateBackAction | import("../actions/ui/answers").EditAnswerAction | {
|
|
27
28
|
type: "@@ui/OPEN_POPIN";
|
|
28
29
|
} | {
|
|
29
30
|
type: "@@ui/CLOSE_POPIN";
|
|
@@ -12,6 +12,7 @@ const fetchSkill = async (skillRef, token) => {
|
|
|
12
12
|
const response = await (0, cross_fetch_1.default)(`${host}/api/v2/skills?conditions={"ref":"${skillRef}"}`, {
|
|
13
13
|
headers: { authorization: token }
|
|
14
14
|
});
|
|
15
|
-
|
|
15
|
+
const skills = await (0, fetch_responses_1.toJSON)(response);
|
|
16
|
+
return skills[0];
|
|
16
17
|
};
|
|
17
18
|
exports.fetchSkill = fetchSkill;
|
package/lib/types/common.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
export declare type ViewName = 'skills' | 'onboarding' | 'slides' | 'loader';
|
|
2
|
+
export interface Translate {
|
|
3
|
+
(key: string, data?: Record<string, string>): string;
|
|
4
|
+
}
|
|
2
5
|
export declare type ChoiceFromAPI = {
|
|
3
6
|
_id: string;
|
|
4
7
|
id?: string;
|
|
@@ -146,13 +149,13 @@ export declare type Options = {
|
|
|
146
149
|
services: Services;
|
|
147
150
|
};
|
|
148
151
|
export declare type ConnectedOptions = {
|
|
149
|
-
translate:
|
|
152
|
+
translate: Translate;
|
|
150
153
|
onQuitClick: () => void;
|
|
151
154
|
};
|
|
152
155
|
export declare type AppOptions = ConnectedOptions & {
|
|
153
156
|
token: string;
|
|
154
157
|
skillRef?: string;
|
|
155
|
-
services
|
|
158
|
+
services?: Services;
|
|
156
159
|
callbackOnViewChanged?: (viewName: ViewName) => void;
|
|
157
160
|
};
|
|
158
161
|
export declare type ThunkOptions = {
|
|
@@ -15,8 +15,10 @@ const mapStateToSkillsProps = (state, options) => {
|
|
|
15
15
|
skillAriaLabel: skill.name,
|
|
16
16
|
buttonLabel: translate('Review this skill'),
|
|
17
17
|
buttonAriaLabel: translate('Review this skill'),
|
|
18
|
-
reviseLabel: translate('{{count}} questions to review', { count: skill.slidesToReview }),
|
|
19
|
-
reviseAriaLabel: translate('{{count}} questions to review', {
|
|
18
|
+
reviseLabel: translate('{{count}} questions to review', { count: `${skill.slidesToReview}` }),
|
|
19
|
+
reviseAriaLabel: translate('{{count}} questions to review', {
|
|
20
|
+
count: `${skill.slidesToReview}`
|
|
21
|
+
}),
|
|
20
22
|
// eslint-disable-next-line no-console
|
|
21
23
|
onClick: () => console.log('@todo plug dispatcher select skill')
|
|
22
24
|
})),
|
|
@@ -91,7 +91,7 @@ const buildStackSlides = (state, dispatch, options) => {
|
|
|
91
91
|
if (!slideFromAPI)
|
|
92
92
|
return (0, set_1.default)(index, { ...uiSlide, position }, acc);
|
|
93
93
|
const answers = (0, getOr_1.default)([], ['ui', 'answers', slideRef], state);
|
|
94
|
-
const { questionText, answerUI } = (0, map_api_slide_to_ui_1.mapApiSlideToUi)(dispatch)(slideFromAPI, answers);
|
|
94
|
+
const { questionText, answerUI } = (0, map_api_slide_to_ui_1.mapApiSlideToUi)(dispatch, translate)(slideFromAPI, answers);
|
|
95
95
|
const { title: parentContentTitle, type: parentContentType } = slideFromAPI.parentContentTitle;
|
|
96
96
|
const isCurrentSlideRef = currentSlideRef === slideRef;
|
|
97
97
|
const slideUI = (0, get_1.default)(['ui', 'slide', slideRef], state);
|
|
@@ -184,7 +184,8 @@ const buildStepItems = (state) => {
|
|
|
184
184
|
return steps;
|
|
185
185
|
};
|
|
186
186
|
exports.buildStepItems = buildStepItems;
|
|
187
|
-
const getCorrectionPopinProps = (dispatch) => (isCorrect, correctAnswer, klf, translate) => {
|
|
187
|
+
const getCorrectionPopinProps = (dispatch) => (isCorrect, correctAnswer, klf, translate, endReview) => {
|
|
188
|
+
const nextLabel = endReview ? translate('Continue') : translate('Next Question');
|
|
188
189
|
return {
|
|
189
190
|
klf: isCorrect
|
|
190
191
|
? undefined
|
|
@@ -195,11 +196,11 @@ const getCorrectionPopinProps = (dispatch) => (isCorrect, correctAnswer, klf, tr
|
|
|
195
196
|
resultLabel: isCorrect ? translate('Correct Answer') : translate('Wrong Answer'),
|
|
196
197
|
information: {
|
|
197
198
|
label: isCorrect ? translate('KLF') : translate('Correct Answer'),
|
|
198
|
-
message: isCorrect ? klf : (0, join_1.default)(',', correctAnswer)
|
|
199
|
+
message: isCorrect ? klf : (0, join_1.default)(', ', correctAnswer)
|
|
199
200
|
},
|
|
200
201
|
next: {
|
|
201
|
-
'aria-label':
|
|
202
|
-
label:
|
|
202
|
+
'aria-label': nextLabel,
|
|
203
|
+
label: nextLabel,
|
|
203
204
|
onClick: () => {
|
|
204
205
|
dispatch(next_slide_1.nextSlide);
|
|
205
206
|
}
|
|
@@ -326,10 +327,11 @@ const mapStateToSlidesProps = (state, dispatch, options) => {
|
|
|
326
327
|
const klf = (0, getOr_1.default)('', ['data', 'slides', currentSlideRef, 'klf'], state);
|
|
327
328
|
const showQuitPopin = (0, get_1.default)(['ui', 'showQuitPopin'], state);
|
|
328
329
|
const showCongrats = (0, get_1.default)(['ui', 'showCongrats'], state);
|
|
330
|
+
const skillName = (0, getOr_1.default)('', ['data', 'currentSkill', 'name'], state);
|
|
329
331
|
return {
|
|
330
332
|
header: {
|
|
331
333
|
mode: translate('Review Title'),
|
|
332
|
-
skillName
|
|
334
|
+
skillName,
|
|
333
335
|
onQuitClick: () => dispatch(quit_popin_1.openQuitPopin),
|
|
334
336
|
'aria-label': 'aria-header-wrapper',
|
|
335
337
|
closeButtonAriaLabel: 'aria-close-button',
|
|
@@ -346,7 +348,7 @@ const mapStateToSlidesProps = (state, dispatch, options) => {
|
|
|
346
348
|
}
|
|
347
349
|
},
|
|
348
350
|
correctionPopinProps: correction &&
|
|
349
|
-
getCorrectionPopinProps(dispatch)(isCorrect, correction.correctAnswer, klf, translate),
|
|
351
|
+
getCorrectionPopinProps(dispatch)(isCorrect, correction.correctAnswer, klf, translate, endReview),
|
|
350
352
|
endReview: endReview && state.ui.showCongrats
|
|
351
353
|
},
|
|
352
354
|
congrats: buildCongratsProps(state, dispatch, options),
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Dispatch } from 'redux';
|
|
2
2
|
import { AnswerUI } from '../../types/slides';
|
|
3
|
-
import { Question, SlideFromAPI } from '../../types/common';
|
|
3
|
+
import { Question, SlideFromAPI, Translate } from '../../types/common';
|
|
4
4
|
export declare const getQuestionType: (question: Question) => Question['type'];
|
|
5
|
-
export declare const mapApiSlideToUi: (dispatch: Dispatch) => (slide: SlideFromAPI, answers: string[]) => {
|
|
5
|
+
export declare const mapApiSlideToUi: (dispatch: Dispatch, translate: Translate) => (slide: SlideFromAPI, answers: string[]) => {
|
|
6
6
|
questionText: string;
|
|
7
7
|
answerUI: AnswerUI;
|
|
8
8
|
};
|
|
@@ -57,11 +57,11 @@ const updateTemplateAnswer = (text, _answers, index, max) => {
|
|
|
57
57
|
const answers = (0, fp_1.isEmpty)(_answers) ? (0, fp_1.times)((0, fp_1.constant)(undefined), max) : _answers;
|
|
58
58
|
return (0, fp_1.map)(a => ((0, fp_1.isNil)(a) ? '' : a), (0, fp_1.set)(index, text, answers));
|
|
59
59
|
};
|
|
60
|
-
const templateTextProps = (dispatch, answers, choice, index, maxLength) => {
|
|
60
|
+
const templateTextProps = (dispatch, translate, answers, choice, index, maxLength) => {
|
|
61
61
|
return {
|
|
62
62
|
type: 'text',
|
|
63
63
|
name: (0, fp_1.getOr)('', 'name', choice),
|
|
64
|
-
placeholder: 'Type here',
|
|
64
|
+
placeholder: translate('Type here'),
|
|
65
65
|
value: (0, fp_1.get)(index, answers),
|
|
66
66
|
onChange: (text) => {
|
|
67
67
|
const newAnswers = updateTemplateAnswer(text, answers, index, maxLength);
|
|
@@ -69,10 +69,10 @@ const templateTextProps = (dispatch, answers, choice, index, maxLength) => {
|
|
|
69
69
|
}
|
|
70
70
|
};
|
|
71
71
|
};
|
|
72
|
-
const templateSelectProps = (dispatch, answers, choice, index, maxLength) => {
|
|
72
|
+
const templateSelectProps = (dispatch, translate, answers, choice, index, maxLength) => {
|
|
73
73
|
const answer = (0, fp_1.get)(index, answers);
|
|
74
74
|
const temporaryOption = {
|
|
75
|
-
name: 'Select an answer',
|
|
75
|
+
name: translate('Select an answer'),
|
|
76
76
|
value: '',
|
|
77
77
|
validOption: false,
|
|
78
78
|
selected: true
|
|
@@ -96,15 +96,15 @@ const templateSelectProps = (dispatch, answers, choice, index, maxLength) => {
|
|
|
96
96
|
options: (0, fp_1.isEmpty)(answer) ? (0, fp_1.concat)([temporaryOption], selectOptions) : selectOptions
|
|
97
97
|
};
|
|
98
98
|
};
|
|
99
|
-
const templateProps = (dispatch) => (answers, question) => {
|
|
99
|
+
const templateProps = (dispatch, translate) => (answers, question) => {
|
|
100
100
|
const choices = question.content.choices;
|
|
101
101
|
const maxLength = (0, fp_1.size)(choices);
|
|
102
102
|
return {
|
|
103
103
|
type: 'template',
|
|
104
104
|
template: (0, fp_1.get)('content.template', question),
|
|
105
105
|
answers: choices.map((choice, index) => choice.type === 'text'
|
|
106
|
-
? templateTextProps(dispatch, answers, choice, index, maxLength)
|
|
107
|
-
: templateSelectProps(dispatch, answers, choice, index, maxLength))
|
|
106
|
+
? templateTextProps(dispatch, translate, answers, choice, index, maxLength)
|
|
107
|
+
: templateSelectProps(dispatch, translate, answers, choice, index, maxLength))
|
|
108
108
|
};
|
|
109
109
|
};
|
|
110
110
|
const basicProps = (dispatch) => (answers, question) => {
|
|
@@ -148,7 +148,7 @@ const sliderProps = (dispatch) => (answers, question) => {
|
|
|
148
148
|
const getQuestionType = (question) => question.type;
|
|
149
149
|
exports.getQuestionType = getQuestionType;
|
|
150
150
|
const getHelp = (slide) => (0, fp_1.get)('question.explanation', slide);
|
|
151
|
-
const getAnswerUIModel = (question, answers, dispatch) => {
|
|
151
|
+
const getAnswerUIModel = (question, answers, dispatch, translate) => {
|
|
152
152
|
const type = (0, exports.getQuestionType)(question);
|
|
153
153
|
switch (type) {
|
|
154
154
|
case 'qcm':
|
|
@@ -160,18 +160,21 @@ const getAnswerUIModel = (question, answers, dispatch) => {
|
|
|
160
160
|
case 'basic':
|
|
161
161
|
return basicProps(dispatch)(answers, question);
|
|
162
162
|
case 'template':
|
|
163
|
-
return templateProps(dispatch)(answers, question);
|
|
163
|
+
return templateProps(dispatch, translate)(answers, question);
|
|
164
164
|
case 'slider':
|
|
165
165
|
return sliderProps(dispatch)(answers, question);
|
|
166
166
|
default:
|
|
167
167
|
throw new Error(`${type} is not an handled question.type`);
|
|
168
168
|
}
|
|
169
169
|
};
|
|
170
|
-
const mapApiSlideToUi = (dispatch) => (slide, answers) => {
|
|
170
|
+
const mapApiSlideToUi = (dispatch, translate) => (slide, answers) => {
|
|
171
171
|
const questionText = (0, fp_1.getOr)('', 'question.header', slide);
|
|
172
172
|
return {
|
|
173
173
|
questionText,
|
|
174
|
-
answerUI: {
|
|
174
|
+
answerUI: {
|
|
175
|
+
model: getAnswerUIModel(slide.question, answers, dispatch, translate),
|
|
176
|
+
help: getHelp(slide)
|
|
177
|
+
}
|
|
175
178
|
};
|
|
176
179
|
};
|
|
177
180
|
exports.mapApiSlideToUi = mapApiSlideToUi;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"ignore_dirs":[]}
|
package/locales/cs/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Kontrolní režim",
|
|
3
|
-
"Content Parent Title": "Od
|
|
3
|
+
"Content Parent Title": "Od „{{contentTitle}}“ {{contentType}}",
|
|
4
4
|
"Validate": "Ověřit",
|
|
5
5
|
"Next Question": "Další otázka",
|
|
6
6
|
"KLF": "Klíčový bod",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Jste na správné cestě! Pokud skončíte nyní, ztratíte svůj postup.",
|
|
17
17
|
"Stop learning": "Ukončit relaci",
|
|
18
18
|
"Continue learning": "Pokračovat v učení",
|
|
19
|
+
"Continue": "Pokračovat",
|
|
20
|
+
"Type here": "Zadejte zde",
|
|
21
|
+
"Select an answer": "Vyberte odpověď",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Schránka prověření prezentace",
|
|
21
24
|
"title": "Co je <br/>režim revizí?",
|
package/locales/de/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Überprüfungsmodus",
|
|
3
|
-
"Content Parent Title": "Von
|
|
3
|
+
"Content Parent Title": "Von \"{{contentTitle}}\" {{contentType}}\n",
|
|
4
4
|
"Validate": "Bestätigen",
|
|
5
5
|
"Next Question": "Nächste Frage",
|
|
6
6
|
"KLF": "Schwerpunkt",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Du bist auf dem richtigen Weg! Wenn du jetzt aufhörst, verlierst du deine Fortschritte.",
|
|
17
17
|
"Stop learning": "Lerneinheit beenden",
|
|
18
18
|
"Continue learning": "Weiter lernen",
|
|
19
|
+
"Continue": "Weiter",
|
|
20
|
+
"Type here": "Type here\n",
|
|
21
|
+
"Select an answer": "Wählen Sie eine Antwort\n",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Präsentations-Container prüfen",
|
|
21
24
|
"title": "Was ist der<br/>Wiederholungsmodus?",
|
package/locales/en/review.json
CHANGED
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "You’re right on track! If you quit now, you’ll lose your progress.",
|
|
17
17
|
"Stop learning": "End session",
|
|
18
18
|
"Continue learning": "Continue learning",
|
|
19
|
+
"Continue": "Continue",
|
|
20
|
+
"Type here": "Type here",
|
|
21
|
+
"Select an answer": "Select an answer",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Review Presentation Container",
|
|
21
24
|
"title": "What is<br/>Revision Mode ?",
|
package/locales/es/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Modo revisión",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "De \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Validar",
|
|
5
5
|
"Next Question": "Siguiente pregunta",
|
|
6
6
|
"KLF": "Aspecto clave",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "¡Vas por buen camino! Si sales ahora perderás tu progreso.",
|
|
17
17
|
"Stop learning": "Finalizar sesión",
|
|
18
18
|
"Continue learning": "Seguir aprendiendo",
|
|
19
|
+
"Continue": "Continuar",
|
|
20
|
+
"Type here": "Escriba aquí",
|
|
21
|
+
"Select an answer": "Seleccione una respuesta",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Revisar contenedor de presentación",
|
|
21
24
|
"title": "¿Qué es el <br/>Modo revisión?",
|
package/locales/fr/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Mode Révision",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "Du {{contentType}} \"{{contentTitle}}\"",
|
|
4
4
|
"Validate": "Valider",
|
|
5
5
|
"Next Question": "Question suivante",
|
|
6
6
|
"KLF": "Point clé",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Vous êtes sur la bonne voie ! Si vous partez maintenant, vous perdrez votre progression.",
|
|
17
17
|
"Stop learning": "Terminer la session",
|
|
18
18
|
"Continue learning": "Continuer à apprendre",
|
|
19
|
+
"Continue": "Continuer ",
|
|
20
|
+
"Type here": "Saisir ici",
|
|
21
|
+
"Select an answer": "Sélectionner une réponse ",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Revoir le conteneur de présentation",
|
|
21
24
|
"title": "Qu'est-ce que le mode<br/>Révision ?",
|
package/locales/hr/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Način provjere",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "Od \"{{contentTitle}}\" {{contentType}",
|
|
4
4
|
"Validate": "Potvrdite",
|
|
5
5
|
"Next Question": "Sljedeće pitanje",
|
|
6
6
|
"KLF": "Ključna stvar",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Na pravom ste putu! Ako sada odustanete, izgubit ćete svoj napredak.",
|
|
17
17
|
"Stop learning": "Završi sesiju",
|
|
18
18
|
"Continue learning": "Nastavite učiti",
|
|
19
|
+
"Continue": "Nastavite",
|
|
20
|
+
"Type here": "Upišite ovdje",
|
|
21
|
+
"Select an answer": "Odaberite odgovor",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Pregledajte prezentacijski spremnik",
|
|
21
24
|
"title": "Što je<br/>način revizije?",
|
package/locales/hu/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Felülvizsgálati mód",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "\"{{contentTitle}}\" {{contentType}} felől",
|
|
4
4
|
"Validate": "Érvényesít",
|
|
5
5
|
"Next Question": "Következő kérdés",
|
|
6
6
|
"KLF": "Kulcsfontosságú pont",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Jó úton haladsz! Ha most kilépsz, eddig elért eredményeid odavesznek.",
|
|
17
17
|
"Stop learning": "Munkamenet befejezése",
|
|
18
18
|
"Continue learning": "Folytasd a tanulást ",
|
|
19
|
+
"Continue": "Folytatás",
|
|
20
|
+
"Type here": "Gépeljen ide",
|
|
21
|
+
"Select an answer": "Válasszon egy választ",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Prezentációs konténer áttekintése",
|
|
21
24
|
"title": "Mi az a <br/> Áttekintés mód?",
|
package/locales/id/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Mode Tinjauan",
|
|
3
|
-
"Content Parent Title": "Dari
|
|
3
|
+
"Content Parent Title": "Dari \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Validasi",
|
|
5
5
|
"Next Question": "Pertanyaan Berikutnya",
|
|
6
6
|
"KLF": "Poin utama",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Anda berada di jalur yang tepat! Jika berhenti sekarang, Anda akan kehilangan kemajuan Anda.",
|
|
17
17
|
"Stop learning": "Akhiri sesi",
|
|
18
18
|
"Continue learning": "Lanjutkan belajar",
|
|
19
|
+
"Continue": "Lanjutkan",
|
|
20
|
+
"Type here": "Ketik di sini",
|
|
21
|
+
"Select an answer": "Pilih satu jawaban",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Tinjau Wadah Presentasi",
|
|
21
24
|
"title": "Apa itu<br/>Mode Revisi?",
|
package/locales/it/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Modalità revisione",
|
|
3
|
-
"Content Parent Title": "Da
|
|
3
|
+
"Content Parent Title": "Da \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Convalida",
|
|
5
5
|
"Next Question": "Domanda seguente",
|
|
6
6
|
"KLF": "Punto chiave",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Sei sulla buona strada! Se esci ora, perderai i tuoi progressi.",
|
|
17
17
|
"Stop learning": "Termina sessione",
|
|
18
18
|
"Continue learning": "Continua a imparare",
|
|
19
|
+
"Continue": "Continua",
|
|
20
|
+
"Type here": "Scrivi qui",
|
|
21
|
+
"Select an answer": "Seleziona una risposta",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Contenitore di presentazione di ripetizione",
|
|
21
24
|
"title": "Cos'è<br/> la modalità ripetizione?",
|
package/locales/ja/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "レビューモード",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "「{{contentTitle}」 {{contentType}} から",
|
|
4
4
|
"Validate": "検証",
|
|
5
5
|
"Next Question": "次の質問",
|
|
6
6
|
"KLF": "キーポイント",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "今順調に進んでいます!今やめると、進行状況が失われます。",
|
|
17
17
|
"Stop learning": "セッションを終了",
|
|
18
18
|
"Continue learning": "学習を続ける",
|
|
19
|
+
"Continue": "続行する",
|
|
20
|
+
"Type here": "ここに入力する",
|
|
21
|
+
"Select an answer": "回答を選択する",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "プレゼンテーションコンテナの確認",
|
|
21
24
|
"title": "<br/>リビジョンモードとは?",
|
package/locales/ko/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "복습 모드",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "\"{{contentTitle}}\" {{contentType}} 에서",
|
|
4
4
|
"Validate": "검증하기",
|
|
5
5
|
"Next Question": "다음 질문",
|
|
6
6
|
"KLF": "요점",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "잘 진행하고 있는 상태입니다! 지금 나가시면 진행 상황을 잃게 됩니다.",
|
|
17
17
|
"Stop learning": "세션 종료",
|
|
18
18
|
"Continue learning": "학습 계속 진행",
|
|
19
|
+
"Continue": "계속하기",
|
|
20
|
+
"Type here": "여기에 입력하세요",
|
|
21
|
+
"Select an answer": "답을 선택하세요",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "프레젠테이션 검토 컨테이너",
|
|
21
24
|
"title": "검토 모드가<br/>무엇인가요?",
|
package/locales/nl/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Beoordelingsmodus",
|
|
3
|
-
"Content Parent Title": "Van
|
|
3
|
+
"Content Parent Title": "Van '{{contentTitle}}' {{contentType}}",
|
|
4
4
|
"Validate": "Valideren",
|
|
5
5
|
"Next Question": "Volgende vraag",
|
|
6
6
|
"KLF": "Kernpunt",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "U bent op het juiste spoor! Als u niet stopt, verliest u uw vorderingen.",
|
|
17
17
|
"Stop learning": "Sessie beëindigen",
|
|
18
18
|
"Continue learning": "Verder leren",
|
|
19
|
+
"Continue": "Verdergaan",
|
|
20
|
+
"Type here": "Hier typen",
|
|
21
|
+
"Select an answer": "Selecteer een antwoord",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Review presentatie container",
|
|
21
24
|
"title": "Wat is<br/>Revisiemodus?",
|
package/locales/pl/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Tryb przeglądania",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "Z {{contentType}} „{{contentTitle}}”",
|
|
4
4
|
"Validate": "Zatwierdź",
|
|
5
5
|
"Next Question": "Kolejne pytanie",
|
|
6
6
|
"KLF": "Kluczowy punkt",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Idziesz prosto do celu! Jeśli teraz zrezygnujesz, utracisz postępy.",
|
|
17
17
|
"Stop learning": "Zakończ sesję",
|
|
18
18
|
"Continue learning": "Kontynuuj naukę",
|
|
19
|
+
"Continue": "Anuluj",
|
|
20
|
+
"Type here": "Wpisz tutaj",
|
|
21
|
+
"Select an answer": "Wybierz odpowiedź",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Kontener prezentacji utrwalania",
|
|
21
24
|
"title": "Czym jest<br/>tryb utrwalania?",
|
package/locales/pt/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Modo de Revisão",
|
|
3
|
-
"Content Parent Title": "De
|
|
3
|
+
"Content Parent Title": "De \"{{contentTitle}}\" {{contentType}} ",
|
|
4
4
|
"Validate": "Validar",
|
|
5
5
|
"Next Question": "Próxima Pergunta",
|
|
6
6
|
"KLF": "Ponto chave",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Está no caminho certo! Se desistir agora, perderá o seu progresso.\n",
|
|
17
17
|
"Stop learning": "Terminar sessão",
|
|
18
18
|
"Continue learning": "Continue a aprender",
|
|
19
|
+
"Continue": "Continuar",
|
|
20
|
+
"Type here": "Escreva aqui",
|
|
21
|
+
"Select an answer": "Selecione uma resposta ",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Analisar Recipiente de Apresentação",
|
|
21
24
|
"title": "O que é o <br/>Modo de Revisão?",
|
package/locales/ro/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Modul de revizuire",
|
|
3
|
-
"Content Parent Title": "De la
|
|
3
|
+
"Content Parent Title": "De la \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Validați",
|
|
5
5
|
"Next Question": "Întrebarea următoare",
|
|
6
6
|
"KLF": "Punct cheie",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Sunteți pe drumul cel bun! Dacă renunțați acum, vă veți pierde progresul.",
|
|
17
17
|
"Stop learning": "Încheiați sesiunea",
|
|
18
18
|
"Continue learning": "Continuați să învățați",
|
|
19
|
+
"Continue": "Continuați",
|
|
20
|
+
"Type here": "Scrieți aici",
|
|
21
|
+
"Select an answer": "Selectați un răspuns",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Revizuiți containerul de prezentare",
|
|
21
24
|
"title": "Ce este<br/>Modul de revizuire?",
|
package/locales/ru/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Режим повторения",
|
|
3
|
-
"Content Parent Title": "Из
|
|
3
|
+
"Content Parent Title": "Из \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Подтвердить",
|
|
5
5
|
"Next Question": "Следующий вопрос",
|
|
6
6
|
"KLF": "Ключевой момент",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Вы на верном пути! Если вы сейчас уйдете, то потеряете свой прогресс.",
|
|
17
17
|
"Stop learning": "Закончить сеанс",
|
|
18
18
|
"Continue learning": "Продолжить обучение",
|
|
19
|
+
"Continue": "Продолжить",
|
|
20
|
+
"Type here": "Напишите здесь",
|
|
21
|
+
"Select an answer": "Выберите ответ",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Контейнер для повторения презентации",
|
|
21
24
|
"title": "Что такое<br/>режим повторения?",
|
package/locales/sk/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Režim kontroly",
|
|
3
|
-
"Content Parent Title": "Z
|
|
3
|
+
"Content Parent Title": "Z „{{contentTitle}}“ {{contentType}}",
|
|
4
4
|
"Validate": "Overiť",
|
|
5
5
|
"Next Question": "Ďalšia otázka",
|
|
6
6
|
"KLF": "Kľúčový bod",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Ste na dobrej ceste! Ak teraz skončíte, stratíte svoj pokrok.",
|
|
17
17
|
"Stop learning": "Ukončiť reláciu",
|
|
18
18
|
"Continue learning": "Pokračovať v učení",
|
|
19
|
+
"Continue": "Pokračovať",
|
|
20
|
+
"Type here": "Píšte sem",
|
|
21
|
+
"Select an answer": "Vybrať odpoveď",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Kontrola prezentačného kontajnera",
|
|
21
24
|
"title": "Čo je to<br/>režim revízie?",
|
package/locales/th/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "โหมดทบทวน",
|
|
3
|
-
"Content Parent Title": "จาก
|
|
3
|
+
"Content Parent Title": "จาก \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "ผ่านการตรวจสอบ",
|
|
5
5
|
"Next Question": "คำถามถัดไป",
|
|
6
6
|
"KLF": "ประเด็นสำคัญ",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "คุณมาถูกทางแล้ว! ถ้าคุณออกตอนนี้คุณจะสูญเสียความคืบหน้าไป",
|
|
17
17
|
"Stop learning": "สิ้นสุดเซสชัน",
|
|
18
18
|
"Continue learning": "เรียนรู้ต่อไป",
|
|
19
|
+
"Continue": "ดำเนินการต่อ",
|
|
20
|
+
"Type here": "พิมพ์ที่นี่",
|
|
21
|
+
"Select an answer": "เลือกคำตอบ",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "ทบทวนคอนเทนเนอร์นำเสนอ",
|
|
21
24
|
"title": "อะไรคือ<br/>โหมดทบทวน",
|
package/locales/tl/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Mode Para Sa Pagrerebyu",
|
|
3
|
-
"Content Parent Title": "Mula sa
|
|
3
|
+
"Content Parent Title": "Mula sa \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Patunayan",
|
|
5
5
|
"Next Question": "Susunod na Tanong",
|
|
6
6
|
"KLF": "Mahalagang punto",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Nasa tamang landas ka! Kung huminto ka ngayon, mawawala ang iyong pagsulong.",
|
|
17
17
|
"Stop learning": "Tapusin ang sesyon",
|
|
18
18
|
"Continue learning": "Magpatuloy na mag-aral",
|
|
19
|
+
"Continue": "Magpatuloy",
|
|
20
|
+
"Type here": "Mag-type dito",
|
|
21
|
+
"Select an answer": "Pumili ng sagot",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Lalagyan ng Rerepasuhing Presentasyon",
|
|
21
24
|
"title": "Ano ang<br/>Revision Mode ?",
|
package/locales/tr/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "İnceleme Modu",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "\"{{contentTitle}}\" {{contentType}} içeriğinden",
|
|
4
4
|
"Validate": "Doğrula",
|
|
5
5
|
"Next Question": "Sonraki Soru",
|
|
6
6
|
"KLF": "Temel nokta",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Şu anda doğru yoldasın! Şimdi çıkarsan ilerlemeni kaybedeceksin.",
|
|
17
17
|
"Stop learning": "Oturumu sonlandır",
|
|
18
18
|
"Continue learning": "Öğrenmeye devam et",
|
|
19
|
+
"Continue": "Devam et",
|
|
20
|
+
"Type here": "Buraya yaz",
|
|
21
|
+
"Select an answer": "Bir cevap seç",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Sunum Kapsayıcısını İncele",
|
|
21
24
|
"title": "Tekrar Modu <br/>nedir?",
|
package/locales/uk/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Режим перегляду",
|
|
3
|
-
"Content Parent Title": "Від
|
|
3
|
+
"Content Parent Title": "Від \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Підтвердити",
|
|
5
5
|
"Next Question": "Наступне питання",
|
|
6
6
|
"KLF": "Ключова точка",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Ви на правильному шляху! Якщо ви припините зараз, ви втратите свій прогрес.",
|
|
17
17
|
"Stop learning": "Завершити сесію",
|
|
18
18
|
"Continue learning": "Продовжити навчання",
|
|
19
|
+
"Continue": "Продовжити",
|
|
20
|
+
"Type here": "Друкуйте тут",
|
|
21
|
+
"Select an answer": "Обрати відповідь",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Контейнер з презентацією перегляду",
|
|
21
24
|
"title": "Що таке <br/>Режим перегляду?",
|
package/locales/vi/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "Chế độ soát lại",
|
|
3
|
-
"Content Parent Title": "Từ
|
|
3
|
+
"Content Parent Title": "Từ \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "Xác thực",
|
|
5
5
|
"Next Question": "Câu hỏi Tiếp theo",
|
|
6
6
|
"KLF": "Điểm quan trọng",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "Bạn đang đi đúng hướng! Nếu bạn thoát ngay bây giờ, bạn sẽ mất tiến trình của mình.",
|
|
17
17
|
"Stop learning": "Kết thúc phiên",
|
|
18
18
|
"Continue learning": "Tiếp tục học",
|
|
19
|
+
"Continue": "Tiếp tục",
|
|
20
|
+
"Type here": "Nhập vào đây",
|
|
21
|
+
"Select an answer": "Chọn một đáp án",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "Vùng chứa Ôn tập Trình bày",
|
|
21
24
|
"title": "Chế độ Ôn tập<br/>là gì?",
|
package/locales/zh/review.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "复习模式\n",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "来自 \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "验证",
|
|
5
5
|
"Next Question": "下一个问题",
|
|
6
6
|
"KLF": "关键点",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "您正走在正轨上!如果现在退出,您将丢失进度。",
|
|
17
17
|
"Stop learning": "结束课程",
|
|
18
18
|
"Continue learning": "继续学习",
|
|
19
|
+
"Continue": "继续",
|
|
20
|
+
"Type here": "在此输入",
|
|
21
|
+
"Select an answer": "选择一个答案",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "复习演示容器",
|
|
21
24
|
"title": "<br/>温习模式是什么?",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Review Title": "檢閱模式",
|
|
3
|
-
"Content Parent Title": "
|
|
3
|
+
"Content Parent Title": "從 \"{{contentTitle}}\" {{contentType}}",
|
|
4
4
|
"Validate": "驗證",
|
|
5
5
|
"Next Question": "下一題",
|
|
6
6
|
"KLF": "重點",
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"Quit Description Text": "你就快要完成了!如果現在離開,下次就必須重新開始。",
|
|
17
17
|
"Stop learning": "結束課程",
|
|
18
18
|
"Continue learning": "繼續學習",
|
|
19
|
+
"Continue": "繼續",
|
|
20
|
+
"Type here": "在此輸入",
|
|
21
|
+
"Select an answer": "選一個答案",
|
|
19
22
|
"presentation": {
|
|
20
23
|
"aria_label": "複習簡報箱",
|
|
21
24
|
"title": "什麼是<br/>複習模式?",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coorpacademy/app-review",
|
|
3
|
-
"version": "0.7.7-alpha.
|
|
3
|
+
"version": "0.7.7-alpha.61+87e8913ff",
|
|
4
4
|
"description": "",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": ">=16.15.0"
|
|
@@ -35,9 +35,9 @@
|
|
|
35
35
|
"main": "lib/index.js",
|
|
36
36
|
"module": "es/index.js",
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@coorpacademy/components": "10.
|
|
38
|
+
"@coorpacademy/components": "10.27.5-alpha.89+87e8913ff",
|
|
39
39
|
"@coorpacademy/redux-task": "1.1.6",
|
|
40
|
-
"@coorpacademy/translate": "6.1.
|
|
40
|
+
"@coorpacademy/translate": "6.1.6-alpha.340+87e8913ff",
|
|
41
41
|
"cross-fetch": "^3.1.5",
|
|
42
42
|
"jwt-decode": "^3.1.2",
|
|
43
43
|
"react-redux": "^7.2.9",
|
|
@@ -71,5 +71,5 @@
|
|
|
71
71
|
"webpack-cli": "^4.10.0",
|
|
72
72
|
"webpack-dev-server": "^4.11.1"
|
|
73
73
|
},
|
|
74
|
-
"gitHead": "
|
|
74
|
+
"gitHead": "87e8913fff56755b6f822a3946dfffe2494b09cf"
|
|
75
75
|
}
|