Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
safetcut-app
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
atichat
safetcut-app
Commits
309f8333
Commit
309f8333
authored
Sep 27, 2019
by
Tonk
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
46d40f16
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
4 deletions
+16
-4
components/MeterCard.js
+16
-4
No files found.
components/MeterCard.js
View file @
309f8333
import
React
from
'react'
;
import
React
from
'react'
;
import
{
View
,
Row
,
Icon
,
Text
}
from
'native-base'
;
import
{
View
,
Icon
,
Text
}
from
'native-base'
;
import
{
Image
,
StyleSheet
,
Platform
}
from
'react-native'
;
import
{
Image
,
StyleSheet
,
Platform
}
from
'react-native'
;
import
{
BaseButton
,
TouchableOpacity
}
from
'react-native-gesture-handler'
;
import
{
BaseButton
,
TouchableOpacity
}
from
'react-native-gesture-handler'
;
import
{
color
,
theme
}
from
'../constants/Styles'
;
import
{
color
,
theme
}
from
'../constants/Styles'
;
...
@@ -41,9 +41,11 @@ const MeterCard = ({ item, onPressEachCard }) => {
...
@@ -41,9 +41,11 @@ const MeterCard = ({ item, onPressEachCard }) => {
{
renderContent
()}
{
renderContent
()}
<
/BaseButton
>
<
/BaseButton
>
)
:
(
)
:
(
<
TouchableOpacity
onPress
=
{
onPressEachCard
}
style
=
{
styles
.
cardContainer
}
>
<
View
style
=
{
styles
.
cardShadow
}
>
{
renderContent
()}
<
TouchableOpacity
onPress
=
{
onPressEachCard
}
style
=
{
styles
.
cardContainer
}
>
<
/TouchableOpacity
>
{
renderContent
()}
<
/TouchableOpacity
>
<
/View
>
);
);
};
};
...
@@ -103,4 +105,14 @@ const styles = StyleSheet.create({
...
@@ -103,4 +105,14 @@ const styles = StyleSheet.create({
backgroundColor
:
'#fff'
,
backgroundColor
:
'#fff'
,
overflow
:
'hidden'
,
overflow
:
'hidden'
,
},
},
cardShadow
:
{
shadowColor
:
'#000'
,
shadowOffset
:
{
width
:
0
,
height
:
2
,
},
shadowOpacity
:
0.25
,
shadowRadius
:
3.84
,
elevation
:
5
,
},
});
});
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