Changes

parent 7545cdb1
......@@ -19,6 +19,7 @@
"react": "18.2.0",
"react-native": "0.73.5",
"react-native-calendars": "^1.1304.1",
"react-native-chart-kit": "^6.12.0",
"react-native-gesture-handler": "^2.15.0",
"react-native-reanimated": "^3.8.0",
"react-native-safe-area-context": "^4.9.0",
......@@ -7309,6 +7310,12 @@
"resolved": "https://registry.npmjs.org/blueimp-md5/-/blueimp-md5-2.19.0.tgz",
"integrity": "sha512-DRQrD6gJyy8FbiE4s+bDoXS9hiW3Vbx5uCdwvcCf3zLHL+Iv7LtGHLpr+GZV8rHG8tK766FGYBwRbu8pELTt+w=="
},
"node_modules/boolbase": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz",
"integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==",
"peer": true
},
"node_modules/bplist-creator": {
"version": "0.1.0",
"resolved": "https://registry.npmjs.org/bplist-creator/-/bplist-creator-0.1.0.tgz",
......@@ -7993,6 +8000,56 @@
"node": ">=8"
}
},
"node_modules/css-select": {
"version": "5.1.0",
"resolved": "https://registry.npmjs.org/css-select/-/css-select-5.1.0.tgz",
"integrity": "sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg==",
"peer": true,
"dependencies": {
"boolbase": "^1.0.0",
"css-what": "^6.1.0",
"domhandler": "^5.0.2",
"domutils": "^3.0.1",
"nth-check": "^2.0.1"
},
"funding": {
"url": "https://github.com/sponsors/fb55"
}
},
"node_modules/css-tree": {
"version": "1.1.3",
"resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz",
"integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==",
"peer": true,
"dependencies": {
"mdn-data": "2.0.14",
"source-map": "^0.6.1"
},
"engines": {
"node": ">=8.0.0"
}
},
"node_modules/css-tree/node_modules/source-map": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
"peer": true,
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/css-what": {
"version": "6.1.0",
"resolved": "https://registry.npmjs.org/css-what/-/css-what-6.1.0.tgz",
"integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==",
"peer": true,
"engines": {
"node": ">= 6"
},
"funding": {
"url": "https://github.com/sponsors/fb55"
}
},
"node_modules/dag-map": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/dag-map/-/dag-map-1.0.2.tgz",
......@@ -8190,6 +8247,61 @@
"node": ">=8"
}
},
"node_modules/dom-serializer": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-2.0.0.tgz",
"integrity": "sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==",
"peer": true,
"dependencies": {
"domelementtype": "^2.3.0",
"domhandler": "^5.0.2",
"entities": "^4.2.0"
},
"funding": {
"url": "https://github.com/cheeriojs/dom-serializer?sponsor=1"
}
},
"node_modules/domelementtype": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz",
"integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==",
"funding": [
{
"type": "github",
"url": "https://github.com/sponsors/fb55"
}
],
"peer": true
},
"node_modules/domhandler": {
"version": "5.0.3",
"resolved": "https://registry.npmjs.org/domhandler/-/domhandler-5.0.3.tgz",
"integrity": "sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==",
"peer": true,
"dependencies": {
"domelementtype": "^2.3.0"
},
"engines": {
"node": ">= 4"
},
"funding": {
"url": "https://github.com/fb55/domhandler?sponsor=1"
}
},
"node_modules/domutils": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/domutils/-/domutils-3.1.0.tgz",
"integrity": "sha512-H78uMmQtI2AhgDJjWeQmHwJJ2bLPD3GMmO7Zja/ZZh84wkm+4ut+IUnUdRa8uCGX88DiVx1j6FRe1XfxEgjEZA==",
"peer": true,
"dependencies": {
"dom-serializer": "^2.0.0",
"domelementtype": "^2.3.0",
"domhandler": "^5.0.3"
},
"funding": {
"url": "https://github.com/fb55/domutils?sponsor=1"
}
},
"node_modules/dotenv": {
"version": "16.0.3",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.0.3.tgz",
......@@ -8237,6 +8349,18 @@
"once": "^1.4.0"
}
},
"node_modules/entities": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz",
"integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==",
"peer": true,
"engines": {
"node": ">=0.12"
},
"funding": {
"url": "https://github.com/fb55/entities?sponsor=1"
}
},
"node_modules/env-editor": {
"version": "0.4.2",
"resolved": "https://registry.npmjs.org/env-editor/-/env-editor-0.4.2.tgz",
......@@ -10629,6 +10753,12 @@
"resolved": "https://registry.npmjs.org/md5hex/-/md5hex-1.0.0.tgz",
"integrity": "sha512-c2YOUbp33+6thdCUi34xIyOU/a7bvGKj/3DB1iaPMTuPHf/Q2d5s4sn1FaCOO43XkXggnb08y5W2PU8UNYNLKQ=="
},
"node_modules/mdn-data": {
"version": "2.0.14",
"resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz",
"integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==",
"peer": true
},
"node_modules/memoize-one": {
"version": "5.2.1",
"resolved": "https://registry.npmjs.org/memoize-one/-/memoize-one-5.2.1.tgz",
......@@ -11484,6 +11614,18 @@
"node": ">=4"
}
},
"node_modules/nth-check": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz",
"integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==",
"peer": true,
"dependencies": {
"boolbase": "^1.0.0"
},
"funding": {
"url": "https://github.com/fb55/nth-check?sponsor=1"
}
},
"node_modules/nullthrows": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/nullthrows/-/nullthrows-1.1.1.tgz",
......@@ -11794,6 +11936,14 @@
"node": ">=8"
}
},
"node_modules/paths-js": {
"version": "0.4.11",
"resolved": "https://registry.npmjs.org/paths-js/-/paths-js-0.4.11.tgz",
"integrity": "sha512-3mqcLomDBXOo7Fo+UlaenG6f71bk1ZezPQy2JCmYHy2W2k5VKpP+Jbin9H0bjXynelTbglCqdFhSEkeIkKTYUA==",
"engines": {
"node": ">=0.11.0"
}
},
"node_modules/picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
......@@ -11930,6 +12080,11 @@
"node": ">=4.0.0"
}
},
"node_modules/point-in-polygon": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/point-in-polygon/-/point-in-polygon-1.1.0.tgz",
"integrity": "sha512-3ojrFwjnnw8Q9242TzgXuTD+eKiutbzyslcq1ydfu82Db2y+Ogbmyrkpv0Hgj31qwT3lbS9+QAAO/pIQM35XRw=="
},
"node_modules/postcss": {
"version": "8.4.35",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.35.tgz",
......@@ -12370,6 +12525,21 @@
"moment": "^2.29.4"
}
},
"node_modules/react-native-chart-kit": {
"version": "6.12.0",
"resolved": "https://registry.npmjs.org/react-native-chart-kit/-/react-native-chart-kit-6.12.0.tgz",
"integrity": "sha512-nZLGyCFzZ7zmX0KjYeeSV1HKuPhl1wOMlTAqa0JhlyW62qV/1ZPXHgT8o9s8mkFaGxdqbspOeuaa6I9jUQDgnA==",
"dependencies": {
"lodash": "^4.17.13",
"paths-js": "^0.4.10",
"point-in-polygon": "^1.0.1"
},
"peerDependencies": {
"react": "> 16.7.0",
"react-native": ">= 0.50.0",
"react-native-svg": "> 6.4.1"
}
},
"node_modules/react-native-gesture-handler": {
"version": "2.15.0",
"resolved": "https://registry.npmjs.org/react-native-gesture-handler/-/react-native-gesture-handler-2.15.0.tgz",
......@@ -12428,6 +12598,20 @@
"react-native": "*"
}
},
"node_modules/react-native-svg": {
"version": "15.1.0",
"resolved": "https://registry.npmjs.org/react-native-svg/-/react-native-svg-15.1.0.tgz",
"integrity": "sha512-p0Sx0EpQNk1nu6UcMEiB8K9P04n3J7s+pNYUwf1d/Yz+v4hk961VjuVqjyndgiEbHZyWiKWLZRVNuvLpwjPY2A==",
"peer": true,
"dependencies": {
"css-select": "^5.1.0",
"css-tree": "^1.1.3"
},
"peerDependencies": {
"react": "*",
"react-native": "*"
}
},
"node_modules/react-native-swipe-gestures": {
"version": "1.0.5",
"resolved": "https://registry.npmjs.org/react-native-swipe-gestures/-/react-native-swipe-gestures-1.0.5.tgz",
......
......@@ -20,6 +20,7 @@
"react": "18.2.0",
"react-native": "0.73.5",
"react-native-calendars": "^1.1304.1",
"react-native-chart-kit": "^6.12.0",
"react-native-gesture-handler": "^2.15.0",
"react-native-reanimated": "^3.8.0",
"react-native-safe-area-context": "^4.9.0",
......
import React, { useRef, useEffect } from 'react';
import { View, Text, TouchableOpacity, ImageBackground, StyleSheet, Animated } from 'react-native';
import React from 'react';
import { View, Text, TouchableOpacity, ImageBackground, StyleSheet } from 'react-native';
const LandingPage = ({ onGoToAddData }) => {
const fadeAnim = useRef(new Animated.Value(0)).current;
useEffect(() => {
Animated.loop(
Animated.sequence([
Animated.timing(fadeAnim, {
toValue: 1,
duration: 1000,
useNativeDriver: true,
}),
Animated.timing(fadeAnim, {
toValue: 0,
duration: 1000,
useNativeDriver: true,
}),
])
).start();
}, []);
return (
<View style={styles.container}>
<Text>S T R E S S T R A C K E R</Text>
......@@ -28,23 +9,11 @@ const LandingPage = ({ onGoToAddData }) => {
source={require('../images/img.jpg')}
style={styles.backgroundImage}
>
<Animated.View
style={{
opacity: fadeAnim,
}}
>
</Animated.View>
</ImageBackground>
<View style={styles.rectangle}>
<Animated.View
style={{
opacity: fadeAnim,
}}
>
<TouchableOpacity style={styles.button} onPress={onGoToAddData}>
<Text style={styles.buttonText}>GET STARTED</Text>
</TouchableOpacity>
</Animated.View>
<TouchableOpacity style={styles.button} onPress={onGoToAddData}>
<Text style={styles.buttonText}>GET STARTED</Text>
</TouchableOpacity>
</View>
</View>
);
......@@ -68,7 +37,7 @@ const styles = StyleSheet.create({
rectangle: {
width: '100%',
height: 150,
backgroundColor: '#616A6B',
backgroundColor: 'white',
position: 'absolute',
bottom: 0,
borderTopLeftRadius: 30,
......@@ -77,14 +46,18 @@ const styles = StyleSheet.create({
alignItems: 'center',
},
button: {
backgroundColor: '#616A6B',
padding: 10,
width: '80%',
height:60,
backgroundColor: '#900303',
padding: 15,
borderRadius: 5,
borderRadius: 18,
},
buttonText: {
color: '#283747',
color: 'white',
fontSize: 18,
fontWeight: 'bold',
textAlign: 'center',
},
});
......
......@@ -4,6 +4,7 @@ import { db, onValue, off } from '../config';
import { ref, set } from 'firebase/database';
import NotificationsComponent from '../src/FetchData';
const AddData = () => {
const [Job_Satisfaction, setJobSatisfaction] = useState('');
const [selectedHours, setSelectedHours] = useState('');
......@@ -55,6 +56,11 @@ const AddData = () => {
<View style={styles.notificationsContainer}>
<NotificationsComponent />
</View>
<View style={styles.rectangle}>
<Image
source={require('../images/back.png')} style={styles.back} resizeMode="contain"
/>
</View>
<TouchableOpacity onPress={() => setModalVisible(true)}>
</TouchableOpacity>
......@@ -103,10 +109,7 @@ const AddData = () => {
style={styles.Sleepinput}
keyboardType='numeric'
/>
<ScrollView
horizontal
contentContainerStyle={styles.horizontalPicker}
>
<ScrollView horizontal contentContainerStyle={styles.horizontalPicker}>
{[5, 6, 7, 8, 9, 10].map((hour) => (
<TouchableOpacity
key={hour}
......@@ -155,8 +158,20 @@ const styles = StyleSheet.create({
flex: 1,
backgroundColor: 'white',
},
backgroundImage:{
rectangle: {
width: 320,
height: 150,
backgroundColor: '#D5D5D5',
top: -240,
left: 20,
padding: 6,
borderRadius: 10,
},
back: {
width: '120%',
height: '240%',
marginLeft:-24,
marginTop:-40,
},
openPopupButton: {
position:'absolute',
......@@ -211,6 +226,7 @@ const styles = StyleSheet.create({
height: 220,
width:320,
left:10,
backgroundColor:'#D21111',
},
image: {
width: '100%',
......@@ -335,7 +351,7 @@ const styles = StyleSheet.create({
},
horizontalPicker: {
marginTop: -10,
paddingHorizontal: 10,
paddingHorizontal: 10,
},
hourItem: {
marginRight: 10,
......@@ -346,6 +362,7 @@ const styles = StyleSheet.create({
borderRadius: 6,
height: 50,
top: 80,
backgroundColor: '#D21111',
},
selectedHourItem: {
backgroundColor: 'lightblue',
......@@ -370,7 +387,7 @@ const styles = StyleSheet.create({
notificationsContainer: {
position: 'absolute',
top: 120,
left: 80,
left: 10,
right: 0,
zIndex: 1,
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment