diff --git a/package-lock.json b/package-lock.json
index 1926ffa..ebd800b 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -6242,6 +6242,14 @@
"prop-types": "15.5.10"
}
},
+ "react-native-deck-swiper": {
+ "version": "1.3.8",
+ "resolved": "https://registry.npmjs.org/react-native-deck-swiper/-/react-native-deck-swiper-1.3.8.tgz",
+ "integrity": "sha1-U2LjDSksuFrrn/fJ3xvNst+vZGs=",
+ "requires": {
+ "prop-types": "15.5.10"
+ }
+ },
"react-native-dismiss-keyboard": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/react-native-dismiss-keyboard/-/react-native-dismiss-keyboard-1.0.0.tgz",
@@ -6263,6 +6271,14 @@
"react-native-drawer-layout": "1.3.2"
}
},
+ "react-native-progress": {
+ "version": "3.4.0",
+ "resolved": "https://registry.npmjs.org/react-native-progress/-/react-native-progress-3.4.0.tgz",
+ "integrity": "sha512-Kqc+wwQHyBG83Fnbb84oM9qqgn1d51ABVS/RK36V+35KmihEYx33WijdQT05iwT+tfJWGArvFLsZWbd8mKyJ6A==",
+ "requires": {
+ "prop-types": "15.5.10"
+ }
+ },
"react-native-router-flux": {
"version": "4.0.0-beta.21",
"resolved": "https://registry.npmjs.org/react-native-router-flux/-/react-native-router-flux-4.0.0-beta.21.tgz",
diff --git a/package.json b/package.json
index 73fbafd..d469ab0 100644
--- a/package.json
+++ b/package.json
@@ -11,7 +11,7 @@
"react-native": "0.47.0",
"react-native-deck-swiper": "^1.3.8",
"react-native-progress": "^3.4.0",
- "react-native-router-flux": "^4.0.0-beta.21"
+ "react-native-router-flux": "^4.0.0-beta.21"
},
"devDependencies": {
"babel-jest": "21.0.2",
diff --git a/src/Router.js b/src/Router.js
index 19df243..f9428c5 100644
--- a/src/Router.js
+++ b/src/Router.js
@@ -3,6 +3,7 @@ import { Scene, Router, Stack } from 'react-native-router-flux';
import Categories from './components/Categories';
import LessonCategories from './components/LessonCategories';
import AnatomyCard from './components/AnatomyCard';
+import Lesson from './components/Lesson';
const RouterComponent = () => {
const { headerTextStyle } = styles;
@@ -30,6 +31,13 @@ const RouterComponent = () => {
headerStyle={headerStyle('#808285')}
headerTitleStyle={headerTextStyle}
/>
+
);
diff --git a/src/components/Lesson.js b/src/components/Lesson.js
index e345a10..f81c116 100644
--- a/src/components/Lesson.js
+++ b/src/components/Lesson.js
@@ -12,10 +12,6 @@ const Lesson = (props) => {
return (
-
{renderQuestions()}
diff --git a/src/components/LessonCategories.js b/src/components/LessonCategories.js
index 1465c0f..de9a113 100644
--- a/src/components/LessonCategories.js
+++ b/src/components/LessonCategories.js
@@ -1,12 +1,28 @@
import React from 'react';
import { View } from 'react-native';
+import { Actions } from 'react-native-router-flux';
import CategoryItem from './CategoryItem';
const LessonCategories = () => {
const { categoriesContainerStyle, categoriesListStyle } = styles;
const onLessonSelected = (selectedLesson) => {
- console.log(selectedLesson);
+ switch(selectedLesson){
+ case 'IMA LI MLIJEKA?':
+ Actions.lesson({
+ lessonHeaderText: 'IMA LI MLIJEKA?',
+ questions:
+ ['Kako funkcioniše produkcija mlijeka?',
+ 'Uspostavljanje i zadržavanje zaliha mlijeka kad beba ne doji',
+ 'Prejak refleks otpuštanja mlijeka ili prekomjerne zalihe',
+ 'Koje biljke izbjegavati za vrijeme dojenja'
+ ],
+ lessonHeaderBackroundColor: '#7270a8'
+ });
+ break;
+ default:
+ console.log(selectedLesson);
+ }
};
return (