Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
软件工程实践2022年春W班
穿梭在银河的火箭队
FZUStudyRoom
提交
f18b75d9
F
FZUStudyRoom
项目概览
软件工程实践2022年春W班
/
穿梭在银河的火箭队
/
FZUStudyRoom
通知
12
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
F
FZUStudyRoom
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
f18b75d9
编写于
5月 04, 2022
作者:
YYYTDMS
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
330_悬浮按钮的切换功能
上级
82172be5
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
269 addition
and
12 deletion
+269
-12
component/HoverButton/index.js
component/HoverButton/index.js
+20
-4
component/Mine/Data/Achievement/index.js
component/Mine/Data/Achievement/index.js
+33
-0
component/Mine/Data/Analysis/index.js
component/Mine/Data/Analysis/index.js
+33
-0
component/Mine/Data/Outline/index.js
component/Mine/Data/Outline/index.js
+33
-0
component/Mine/Data/Rank/index.js
component/Mine/Data/Rank/index.js
+33
-0
component/Mine/index.js
component/Mine/index.js
+83
-6
component/Mine/person.js
component/Mine/person.js
+33
-0
component/Navigation/index.js
component/Navigation/index.js
+1
-2
未找到文件。
component/HoverButton/index.js
浏览文件 @
f18b75d9
...
...
@@ -17,6 +17,10 @@ class HoverButton extends Component {
source
=
{
require
(
'
../../images/Data/菜单.png
'
)}
/
>
)}
onLongPress
=
{()
=>
{
this
.
props
.
changeSelectedTab
(
'
个人信息
'
);
console
.
log
(
'
个人信息
'
);
}}
hideShadow
=
{
true
}
buttonColor
=
"
rgba(255,255,255,0)
"
position
=
"
right
"
...
...
@@ -24,7 +28,10 @@ class HoverButton extends Component {
<
ActionButton
.
Item
buttonColor
=
"
rgba(255,255,255,0)
"
// title="排行榜"
onPress
=
{()
=>
console
.
log
(
'
排行榜
'
)}
>
onPress
=
{()
=>
{
this
.
props
.
changeSelectedTab
(
'
排行榜
'
);
console
.
log
(
'
排行榜
'
);
}}
>
<
Image
style
=
{
styles
.
image
}
source
=
{
require
(
'
../../images/Data/排行榜.png
'
)}
...
...
@@ -34,7 +41,10 @@ class HoverButton extends Component {
<
ActionButton
.
Item
buttonColor
=
"
rgba(255,255,255,0)
"
// title="我的成就"
onPress
=
{()
=>
console
.
log
(
'
成就
'
)}
>
onPress
=
{()
=>
{
this
.
props
.
changeSelectedTab
(
'
我的成就
'
);
console
.
log
(
'
我的成就
'
);
}}
>
<
Image
style
=
{
styles
.
image
}
source
=
{
require
(
'
../../images/Data/成就.png
'
)}
...
...
@@ -44,7 +54,10 @@ class HoverButton extends Component {
<
ActionButton
.
Item
buttonColor
=
"
rgba(255,255,255,0)
"
// title="数据分析"
onPress
=
{()
=>
console
.
log
(
'
数据分析
'
)}
>
onPress
=
{()
=>
{
this
.
props
.
changeSelectedTab
(
'
数据分析
'
);
console
.
log
(
'
数据分析
'
);
}}
>
<
Image
style
=
{
styles
.
image
}
source
=
{
require
(
'
../../images/Data/数据分析.png
'
)}
...
...
@@ -54,7 +67,10 @@ class HoverButton extends Component {
<
ActionButton
.
Item
buttonColor
=
"
rgba(255,255,255,0)
"
// title="自习概览"
onPress
=
{()
=>
console
.
log
(
'
自习概览
'
)}
>
onPress
=
{()
=>
{
this
.
props
.
changeSelectedTab
(
'
自习概览
'
);
console
.
log
(
'
自习概览
'
);
}}
>
<
Image
style
=
{
styles
.
image
}
source
=
{
require
(
'
../../images/Data/自习概览.png
'
)}
...
...
component/Mine/Data/Achievement/index.js
0 → 100644
浏览文件 @
f18b75d9
import
React
,
{
Component
}
from
'
react
'
;
import
{
View
,
Text
,
StyleSheet
}
from
'
react-native
'
;
class
Achievement
extends
Component
{
constructor
(
props
)
{
super
(
props
);
}
render
()
{
return
(
<
View
style
=
{{
display
:
this
.
props
.
show
?
'
flex
'
:
'
none
'
,
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
}}
>
<
Text
style
=
{
styles
.
text
}
>
成就模块
<
/Text
>
<
/View
>
);
}
}
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
},
text
:
{
fontSize
:
50
,
fontWeight
:
'
bold
'
,
textAlign
:
'
center
'
,
},
});
export
default
Achievement
;
component/Mine/Data/Analysis/index.js
0 → 100644
浏览文件 @
f18b75d9
import
React
,
{
Component
}
from
'
react
'
;
import
{
View
,
Text
,
StyleSheet
}
from
'
react-native
'
;
class
Analysis
extends
Component
{
constructor
(
props
)
{
super
(
props
);
}
render
()
{
return
(
<
View
style
=
{{
display
:
this
.
props
.
show
?
'
flex
'
:
'
none
'
,
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
}}
>
<
Text
style
=
{
styles
.
text
}
>
数据分析模块
<
/Text
>
<
/View
>
);
}
}
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
},
text
:
{
fontSize
:
50
,
fontWeight
:
'
bold
'
,
textAlign
:
'
center
'
,
},
});
export
default
Analysis
;
component/Mine/Data/Outline/index.js
0 → 100644
浏览文件 @
f18b75d9
import
React
,
{
Component
}
from
'
react
'
;
import
{
View
,
Text
,
StyleSheet
}
from
'
react-native
'
;
class
Outline
extends
Component
{
constructor
(
props
)
{
super
(
props
);
}
render
()
{
return
(
<
View
style
=
{{
display
:
this
.
props
.
show
?
'
flex
'
:
'
none
'
,
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
}}
>
<
Text
style
=
{
styles
.
text
}
>
自习概览模块
<
/Text
>
<
/View
>
);
}
}
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
},
text
:
{
fontSize
:
50
,
fontWeight
:
'
bold
'
,
textAlign
:
'
center
'
,
},
});
export
default
Outline
;
component/Mine/Data/Rank/index.js
0 → 100644
浏览文件 @
f18b75d9
import
React
,
{
Component
}
from
'
react
'
;
import
{
View
,
Text
,
StyleSheet
}
from
'
react-native
'
;
class
Rank
extends
Component
{
constructor
(
props
)
{
super
(
props
);
}
render
()
{
return
(
<
View
style
=
{{
display
:
this
.
props
.
show
?
'
flex
'
:
'
none
'
,
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
}}
>
<
Text
style
=
{
styles
.
text
}
>
排行榜模块
<
/Text
>
<
/View
>
);
}
}
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
},
text
:
{
fontSize
:
50
,
fontWeight
:
'
bold
'
,
textAlign
:
'
center
'
,
},
});
export
default
Rank
;
component/Mine/index.js
浏览文件 @
f18b75d9
import
React
,
{
Component
}
from
'
react
'
;
import
{
View
,
Text
,
StyleSheet
}
from
'
react-native
'
;
import
{
View
,
Text
,
StyleSheet
,
Image
}
from
'
react-native
'
;
import
HoverButton
from
'
../HoverButton
'
;
import
Person
from
'
./person
'
;
import
Achievement
from
'
./Data/Achievement
'
;
import
Analysis
from
'
./Data/Analysis
'
;
import
Outline
from
'
./Data/Outline
'
;
import
Rank
from
'
./Data/Rank
'
;
class
Mine
extends
Component
{
constructor
()
{
super
();
constructor
(
props
)
{
super
(
props
);
this
.
state
=
{
showPerson
:
true
,
showAchievement
:
false
,
showOutline
:
false
,
showAnalysis
:
false
,
showRank
:
false
,
};
this
.
changeSelectedTab
=
this
.
changeSelectedTab
.
bind
(
this
);
}
changeSelectedTab
(
selectedTab
)
{
if
(
this
.
state
.
showPerson
===
true
)
{
this
.
setState
({
showPerson
:
false
,
});
}
if
(
this
.
state
.
showAchievement
===
true
)
{
this
.
setState
({
showAchievement
:
false
,
});
}
if
(
this
.
state
.
showOutline
===
true
)
{
this
.
setState
({
showOutline
:
false
,
});
}
if
(
this
.
state
.
showAnalysis
===
true
)
{
this
.
setState
({
showAnalysis
:
false
,
});
}
if
(
this
.
state
.
showRank
===
true
)
{
this
.
setState
({
showRank
:
false
,
});
}
switch
(
selectedTab
)
{
case
'
排行榜
'
:
this
.
setState
({
showRank
:
true
,
});
break
;
case
'
我的成就
'
:
this
.
setState
({
showAchievement
:
true
,
});
break
;
case
'
数据分析
'
:
this
.
setState
({
showAnalysis
:
true
,
});
break
;
case
'
自习概览
'
:
this
.
setState
({
showOutline
:
true
,
});
break
;
case
'
个人信息
'
:
this
.
setState
({
showPerson
:
true
,
});
break
;
}
this
.
setState
({
selectedTab
:
selectedTab
,
});
}
render
()
{
return
(
<
View
style
=
{
styles
.
container
}
>
<
Text
style
=
{
styles
.
text
}
>
Mine个人主页模块
<
/Text
>
<
HoverButton
/>
<
Person
show
=
{
this
.
state
.
showPerson
}
/
>
<
Achievement
show
=
{
this
.
state
.
showAchievement
}
/
>
<
Outline
show
=
{
this
.
state
.
showOutline
}
/
>
<
Analysis
show
=
{
this
.
state
.
showAnalysis
}
/
>
<
Rank
show
=
{
this
.
state
.
showRank
}
/
>
<
HoverButton
changeSelectedTab
=
{
this
.
changeSelectedTab
}
/
>
<
/View
>
);
}
...
...
@@ -19,7 +97,6 @@ class Mine extends Component {
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
},
text
:
{
...
...
component/Mine/person.js
0 → 100644
浏览文件 @
f18b75d9
import
React
,
{
Component
}
from
'
react
'
;
import
{
View
,
Text
,
StyleSheet
}
from
'
react-native
'
;
class
person
extends
Component
{
constructor
(
props
)
{
super
(
props
);
}
render
()
{
return
(
<
View
style
=
{{
display
:
this
.
props
.
show
?
'
flex
'
:
'
none
'
,
backgroundColor
:
'
#F2E2CE
'
,
flex
:
1
,
}}
>
<
Text
style
=
{
styles
.
text
}
>
个人信息模块
<
/Text
>
<
/View
>
);
}
}
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#ffa3a3
'
,
flex
:
1
,
},
text
:
{
fontSize
:
50
,
fontWeight
:
'
bold
'
,
textAlign
:
'
center
'
,
},
});
export
default
person
;
component/Navigation/index.js
浏览文件 @
f18b75d9
...
...
@@ -88,14 +88,13 @@ class Navigation extends Component {
this
.
setState
({
selectedTab
:
'
我
'
});
this
.
props
.
changeName
(
'
我
'
);
}}
>
<
Mine
/>
<
Mine
changeName
=
{
this
.
props
.
changeName
}
/
>
<
/TabNavigator.Item
>
<
/TabNavigator
>
);
}
}
const
styles
=
StyleSheet
.
create
({
container
:
{
backgroundColor
:
'
#F2E2CE
'
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录