Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
21_22-J 38
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
21_22-J 38
21_22-J 38
Commits
a1bbbe24
Commit
a1bbbe24
authored
Dec 22, 2021
by
W.D.R.P. Sandeepa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
color page design
parent
d593dfc8
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
70 additions
and
9 deletions
+70
-9
frontend/src/component/ImageButton.js
frontend/src/component/ImageButton.js
+35
-0
frontend/src/router/router.js
frontend/src/router/router.js
+2
-0
frontend/src/screen/Color.js
frontend/src/screen/Color.js
+30
-0
frontend/src/screen/home.js
frontend/src/screen/home.js
+3
-9
No files found.
frontend/src/component/ImageButton.js
0 → 100644
View file @
a1bbbe24
import
{
useNavigation
}
from
"
@react-navigation/native
"
;
import
React
from
"
react
"
;
import
{
Text
,
TouchableOpacity
,
StyleSheet
}
from
'
react-native
'
export
default
function
ImageButton
({
title
}){
const
navigation
=
useNavigation
();
return
(
<
TouchableOpacity
onPress
=
{()
=>
{
navigation
.
navigate
(
"
Color
"
)}}
style
=
{
styles
.
ImageButton
}
>
<
Text
style
=
{
styles
.
text
}
>
{
title
}
<
/Text
>
<
/TouchableOpacity
>
);
}
const
styles
=
StyleSheet
.
create
({
ImageButton
:{
backgroundColor
:
"
rgba(0, 0, 0, 0.3)
"
,
width
:
"
100%
"
,
height
:
"
30%
"
,
position
:
"
absolute
"
,
marginTop
:
120
,
// bottom: 0,
left
:
0
,
},
text
:
{
fontSize
:
40
,
justifyContent
:
"
center
"
,
textAlign
:
"
center
"
,
color
:
'
#ffff
'
,
fontWeight
:
"
bold
"
,
},
})
\ No newline at end of file
frontend/src/router/router.js
View file @
a1bbbe24
...
@@ -7,6 +7,7 @@ import Start from "../screen/Start"
...
@@ -7,6 +7,7 @@ import Start from "../screen/Start"
import
Register
from
"
../screen/auth/Register
"
;
import
Register
from
"
../screen/auth/Register
"
;
import
Login
from
"
../screen/auth/Login
"
;
import
Login
from
"
../screen/auth/Login
"
;
import
Splash
from
"
../screen/splash/Splash
"
;
import
Splash
from
"
../screen/splash/Splash
"
;
import
Color
from
"
../screen/Color
"
;
const
Stack
=
createNativeStackNavigator
();
const
Stack
=
createNativeStackNavigator
();
...
@@ -19,6 +20,7 @@ return(
...
@@ -19,6 +20,7 @@ return(
<
Stack
.
Screen
options
=
{{
headerShown
:
false
}}
name
=
"
Register
"
component
=
{
Register
}
/
>
<
Stack
.
Screen
options
=
{{
headerShown
:
false
}}
name
=
"
Register
"
component
=
{
Register
}
/
>
<
Stack
.
Screen
options
=
{{
headerShown
:
false
}}
name
=
"
Login
"
component
=
{
Login
}
/
>
<
Stack
.
Screen
options
=
{{
headerShown
:
false
}}
name
=
"
Login
"
component
=
{
Login
}
/
>
<
Stack
.
Screen
options
=
{{
headerShown
:
false
}}
name
=
"
Start
"
component
=
{
Start
}
/
>
<
Stack
.
Screen
options
=
{{
headerShown
:
false
}}
name
=
"
Start
"
component
=
{
Start
}
/
>
<
Stack
.
Screen
options
=
{{
headerShown
:
true
}}
name
=
"
Color
"
component
=
{
Color
}
/
>
<
/Stack.Navigator
>
<
/Stack.Navigator
>
<
/NavigationContainer
>
<
/NavigationContainer
>
)
)
...
...
frontend/src/screen/Color.js
0 → 100644
View file @
a1bbbe24
import
{
useNavigation
}
from
"
@react-navigation/native
"
;
import
React
from
"
react
"
;
import
{
StyleSheet
,
View
,
Text
,
Pressable
,
SafeAreaView
,
ScrollView
,
Image
,
ImageBackground
}
from
'
react-native
'
;
export
default
function
Color
(){
const
navigation
=
useNavigation
();
return
(
<
SafeAreaView
>
<
ScrollView
>
<
View
>
<
ImageBackground
style
=
{
styles
.
imagebackground
}
source
=
{
require
(
'
../assets/login/login_background.png
'
)}
resizeMode
=
"
contain
"
>
<
/ImageBackground
>
<
/View
>
<
/ScrollView
>
<
/SafeAreaView
>
)
}
const
styles
=
StyleSheet
.
create
({
imagebackground
:{
width
:
"
100%
"
,
height
:
"
100%
"
,
}
})
\ No newline at end of file
frontend/src/screen/home.js
View file @
a1bbbe24
import
React
from
"
react
"
;
import
React
from
"
react
"
;
import
{
StyleSheet
,
View
,
Text
,
Pressable
,
SafeAreaView
,
ScrollView
,
Image
}
from
'
react-native
'
;
import
{
StyleSheet
,
View
,
Text
,
Pressable
,
SafeAreaView
,
ScrollView
,
Image
}
from
'
react-native
'
;
import
ImageButton
from
"
../component/ImageButton
"
;
export
default
function
Home
({
navigation
}){
export
default
function
Home
({
navigation
}){
...
@@ -14,7 +15,7 @@ export default function Home({ navigation }){
...
@@ -14,7 +15,7 @@ export default function Home({ navigation }){
<
View
style
=
{
styles
.
imageView
}
>
<
View
style
=
{
styles
.
imageView
}
>
<
Image
style
=
{
styles
.
image
}
source
=
{
require
(
'
../assets/color/background.png
'
)}
resizeMode
=
"
contain
"
>
<
Image
style
=
{
styles
.
image
}
source
=
{
require
(
'
../assets/color/background.png
'
)}
resizeMode
=
"
contain
"
>
<
/Image
>
<
/Image
>
<
Text
style
=
{
styles
.
text
}
>
Color
And
Shape
<
/Text
>
<
ImageButton
title
=
"
Color And Sape
"
/
>
<
/View
>
<
/View
>
<
/View
>
<
/View
>
<
/ScrollView
>
<
/ScrollView
>
...
@@ -42,13 +43,6 @@ const styles = StyleSheet.create({
...
@@ -42,13 +43,6 @@ const styles = StyleSheet.create({
height
:
"
100%
"
,
height
:
"
100%
"
,
borderRadius
:
50
borderRadius
:
50
},
},
text
:
{
fontSize
:
40
,
justifyContent
:
"
center
"
,
textAlign
:
"
center
"
,
marginTop
:
-
190
,
color
:
'
#ffff
'
,
fontWeight
:
"
bold
"
},
})
})
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment