Toggle navigation
Toggle navigation
This project
Loading...
Sign in
bluejoyq
/
searchGuide
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
김서영
2019-12-09 23:01:15 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
e2d401257e133dedcb0e42df4c385982e1b13fb7
e2d40125
1 parent
8016738c
pie chart
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
77 additions
and
56 deletions
searchGuide/.expo/packager-info.json
searchGuide/.expo/settings.json
searchGuide/components/PromptSearch/PromptSearchRate.js
searchGuide/components/RateBar/RateBar.js
searchGuide/components/RateLine/RateLine.js
searchGuide/.expo/packager-info.json
View file @
e2d4012
...
...
@@ -2,8 +2,8 @@
"devToolsPort"
:
19002
,
"expoServerPort"
:
19000
,
"packagerPort"
:
19001
,
"packagerPid"
:
14
768
,
"expoServerNgrokUrl"
:
"https://
x2-7pb
.anonymous.searchguide.exp.direct"
,
"packagerNgrokUrl"
:
"https://packager.
x2-7pb
.anonymous.searchguide.exp.direct"
,
"ngrokPid"
:
9336
"packagerPid"
:
14
076
,
"expoServerNgrokUrl"
:
"https://
7f-yzp
.anonymous.searchguide.exp.direct"
,
"packagerNgrokUrl"
:
"https://packager.
7f-yzp
.anonymous.searchguide.exp.direct"
,
"ngrokPid"
:
2900
}
...
...
searchGuide/.expo/settings.json
View file @
e2d4012
...
...
@@ -3,6 +3,6 @@
"lanType"
:
"ip"
,
"dev"
:
true
,
"minify"
:
false
,
"urlRandomness"
:
"
x2-7pb
"
,
"urlRandomness"
:
"
7f-yzp
"
,
"https"
:
false
}
...
...
searchGuide/components/PromptSearch/PromptSearchRate.js
View file @
e2d4012
...
...
@@ -3,7 +3,7 @@ import { Text } from 'react-native-paper';
import
{
StyleSheet
,
View
}
from
'react-native'
;
export
default
PromptSearchRate
=
()
=>
(
<
View
style
=
{{
alignItems
:
'center'
}}
>
<
View
style
=
{{
alignItems
:
'center'
,
justifyContent
:
'center'
}}
>
<
Text
style
=
{
styles
.
Text
}
>
아직까지
검색
<
/Text
>
<
Text
style
=
{
styles
.
Text
}
>
결과가
없습니다
!<
/Text
>
<
/View
>
...
...
searchGuide/components/RateBar/RateBar.js
View file @
e2d4012
import
React
,{
useState
}
from
'react'
;
import
{
Surface
,
Text
,
HelperText
}
from
'react-native-paper'
;
import
{
StyleSheet
,
View
}
from
'react-native'
;
import
{
StackedBarChart
}
from
'react-native-svg-charts'
;
import
{
StackedBarChart
,
PieChart
}
from
'react-native-svg-charts'
;
import
PromptSearchRate
from
'../PromptSearch/PromptSearchRate'
;
export
default
RateBar
=
(
props
)
=>
{
...
...
@@ -14,48 +14,53 @@ export default RateBar = (props) => {
<>
<
View
style
=
{
styles
.
container
}
>
<
Text
style
=
{
styles
.
Text
}
>
총
점수
:
{
props
.
score
.
full
}
점
<
/Text
>
<
View
style
=
{
styles
.
colorContainer
}
>
<
View
style
=
{
styles
.
textContainer
}
>
<
View
style
=
{
styles
.
colorA
}
><
/View><Text>키워드 점수</
Text
>
<
/View
>
<
View
style
=
{
styles
.
textContainer
}
>
<
View
style
=
{
styles
.
colorB
}
><
/View><Text>맞춤법 점수</
Text
>
<
/View
>
<
/View
>
<
/View
>
<
StackedBarChart
data
=
{
[{
keyword
:
{
value
:
props
.
score
.
key
,
svg
:
{
onPressIn
:
()
=>
{
setClick
(
1
)},
onPressOut
:
()
=>
{
setClick
(
0
)}
},
},
korean
:
{
value
:
props
.
score
.
fix
,
svg
:
{
onPressIn
:
()
=>
{
setClick
(
2
)},
onPressOut
:
()
=>
{
setClick
(
0
)}
},
},
rest
:
{
value
:
(
100
-
(
props
.
score
.
key
+
props
.
score
.
fix
)),
}
}]}
style
=
{{
height
:
50
,
width
:
'90%'
}}
keys
=
{[
'keyword'
,
'korean'
,
'rest'
]}
colors
=
{[
'#ffaa5a'
,
'#2cc3c2'
,
'#ffffff'
]}
showGrid
=
{
false
}
horizontal
=
{
true
}
contentInset
=
{
{
top
:
10
}
}
valueAccessor
=
{({
item
,
key
})
=>
item
[
key
].
value
}
/>
<
View
style
=
{
styles
.
container
}
>
<
Text
style
=
{
styles
.
message
}
>
눌러서
각각의
점수를
알아보세요
!<
/Text>
<
/View
>
<
View
style
=
{
styles
.
infoContainer
}
>
<
HelperText
type
=
{
'info'
}
visible
=
{
click
==
1
}
style
=
{
styles
.
helper
}
>
키워드
:
{
props
.
score
.
key
}
<
/HelperText
>
<
HelperText
type
=
{
'info'
}
visible
=
{
click
==
2
}
style
=
{
styles
.
helper
}
>
맞춤법
:
{
props
.
score
.
fix
}
<
/HelperText
>
<
HelperText
type
=
{
'info'
}
visible
=
{
click
==
1
}
style
=
{
styles
.
helper
}
>
키워드
:
{
props
.
score
.
key
}
<
/HelperText>
<
/View
>
<
View
style
=
{
styles
.
chartContatiner
}
>
<
View
>
<
PieChart
style
=
{
styles
.
chart
}
data
=
{[{
value
:
props
.
score
.
key
,
svg
:{
fill
:
'#e85a71'
,
onPressIn
:
()
=>
{
setClick
(
1
)},
onPressOut
:
()
=>
{
setClick
(
0
)}
},
key
:
"키워드"
},
{
value
:
props
.
score
.
fix
,
svg
:
{
fill
:
'#d8e9ef'
,
onPressIn
:
()
=>
{
setClick
(
2
)},
onPressOut
:
()
=>
{
setClick
(
0
)}
},
key
:
"맞춤법"
},
{
value
:
(
100
-
(
props
.
score
.
key
+
props
.
score
.
fix
)),
key
:
""
}
]}
innerRadius
=
{
"60%"
}
/
>
<
/View>
<
View
style
=
{
styles
.
colorContainer
}
>
<
View
style
=
{
styles
.
textContainer
}
>
<
View
style
=
{
styles
.
colorA
}
><
/View><Text>키워드 점수</
Text
>
<
/View
>
<
View
style
=
{
styles
.
textContainer
}
>
<
View
style
=
{
styles
.
colorB
}
><
/View><Text>맞춤법 점수</
Text
>
<
/View>
<
/View
>
<
/View
>
<
Text
style
=
{
styles
.
message
}
>
눌러서
각각의
점수를
알아보세요
!<
/Text
>
<
/
>
:
<
PromptSearchRate
/>
}
<
/Surface
>
...
...
@@ -73,10 +78,10 @@ const styles = StyleSheet.create({
},
colorContainer
:{
position
:
"absolute"
,
right
:
0
,
right
:
1
0
,
},
colorA
:{
backgroundColor
:
'#
ffaa5a
'
,
backgroundColor
:
'#
e85a71
'
,
height
:
7
,
width
:
7
,
marginRight
:
5
,
...
...
@@ -84,13 +89,23 @@ const styles = StyleSheet.create({
fontSize
:
13
,
},
colorB
:{
backgroundColor
:
'#
2cc3c2
'
,
backgroundColor
:
'#
d8e9ef
'
,
height
:
7
,
width
:
7
,
marginRight
:
5
,
fontFamily
:
"Regular"
,
fontSize
:
13
,
},
chartContatiner
:{
flexDirection
:
'row'
,
justifyContent
:
"flex-start"
,
alignItems
:
'flex-start'
,
},
chart
:{
height
:
120
,
width
:
"90%"
,
position
:
"absolute"
,
},
textContainer
:{
flexDirection
:
'row'
,
justifyContent
:
'center'
,
...
...
@@ -104,11 +119,13 @@ const styles = StyleSheet.create({
width
:
'100%'
},
surface
:
{
padding
:
8
,
flex
:
0.3
,
paddingTop
:
8
,
paddingBottom
:
5
,
flex
:
0.45
,
width
:
'95%'
,
alignItems
:
'center'
,
justifyContent
:
'center'
,
flexDirection
:
'column'
,
alignItems
:
"center"
,
justifyContent
:
'flex-start'
,
elevation
:
2
,
marginTop
:
10
,
borderRadius
:
5
,
...
...
@@ -121,9 +138,10 @@ const styles = StyleSheet.create({
message
:{
fontFamily
:
"Son"
,
fontSize
:
20
,
marginBottom
:
10
,
},
helper
:{
fontFamily
:
"
Regular
"
,
fontFamily
:
"
Bold
"
,
fontSize
:
15
}
});
...
...
searchGuide/components/RateLine/RateLine.js
View file @
e2d4012
...
...
@@ -39,7 +39,8 @@ const RateLine = ({load,pastRecords }) => {
const
styles
=
StyleSheet
.
create
({
surface
:
{
padding
:
8
,
paddingTop
:
5
,
paddingBottom
:
5
,
flex
:
0.3
,
width
:
'95%'
,
alignItems
:
'center'
,
...
...
@@ -51,7 +52,7 @@ const styles = StyleSheet.create({
},
info
:{
fontSize
:
22
,
marginBottom
:
5
,
marginBottom
:
10
,
fontFamily
:
"Bold"
,
},
score
:{
...
...
@@ -61,7 +62,8 @@ const styles = StyleSheet.create({
scoreContainer
:{
flexDirection
:
'row'
,
justifyContent
:
'space-around'
,
width
:
'100%'
width
:
'100%'
,
backgroundColor
:
'#ececf8'
,
},
data
:{
fontSize
:
10
,
...
...
@@ -69,6 +71,7 @@ const styles = StyleSheet.create({
fontFamily
:
"Regular"
,
},
past
:{
backgroundColor
:
'#ececf8'
,
alignItems
:
'center'
,
marginBottom
:
5
},
...
...
Please
register
or
login
to post a comment