Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
JDChain
Explorer
提交
33784cb3
E
Explorer
项目概览
JDChain
/
Explorer
通知
0
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
E
Explorer
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
33784cb3
编写于
5月 29, 2019
作者:
J
jinlong12
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增侧边栏菜单
上级
36234ca1
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
143 addition
and
79 deletion
+143
-79
package-lock.json
package-lock.json
+76
-76
src/web/components/header/header.js
src/web/components/header/header.js
+22
-1
src/web/components/header/header.scss
src/web/components/header/header.scss
+22
-1
src/web/components/header/header.t.html
src/web/components/header/header.t.html
+23
-1
未找到文件。
package-lock.json
浏览文件 @
33784cb3
...
...
@@ -7851,8 +7851,8 @@
"dev": true,
"optional": true,
"requires": {
"delegates": "1.0.0",
"readable-stream": "
2.3
.6"
"delegates": "
^
1.0.0",
"readable-stream": "
^2.0
.6"
}
},
"balanced-match": {
...
...
@@ -7867,7 +7867,7 @@
"dev": true,
"optional": true,
"requires": {
"balanced-match": "1.0.0",
"balanced-match": "
^
1.0.0",
"concat-map": "0.0.1"
}
},
...
...
@@ -7934,7 +7934,7 @@
"dev": true,
"optional": true,
"requires": {
"minipass": "
2.2.4
"
"minipass": "
^2.2.1
"
}
},
"fs.realpath": {
...
...
@@ -7949,14 +7949,14 @@
"dev": true,
"optional": true,
"requires": {
"aproba": "
1.2.0
",
"console-control-strings": "
1.1
.0",
"has-unicode": "
2.0.1
",
"object-assign": "
4.1.1
",
"signal-exit": "
3.0.2
",
"string-width": "
1.0.2
",
"strip-ansi": "3.0.1",
"wide-align": "
1.1.2
"
"aproba": "
^1.0.3
",
"console-control-strings": "
^1.0
.0",
"has-unicode": "
^2.0.0
",
"object-assign": "
^4.1.0
",
"signal-exit": "
^3.0.0
",
"string-width": "
^1.0.1
",
"strip-ansi": "
^
3.0.1",
"wide-align": "
^1.1.0
"
}
},
"glob": {
...
...
@@ -7965,12 +7965,12 @@
"dev": true,
"optional": true,
"requires": {
"fs.realpath": "1.0.0",
"inflight": "
1.0.6
",
"inherits": "2
.0.3
",
"minimatch": "3.0.4",
"once": "
1.4
.0",
"path-is-absolute": "
1.0.1
"
"fs.realpath": "
^
1.0.0",
"inflight": "
^1.0.4
",
"inherits": "2",
"minimatch": "
^
3.0.4",
"once": "
^1.3
.0",
"path-is-absolute": "
^1.0.0
"
}
},
"has-unicode": {
...
...
@@ -7985,7 +7985,7 @@
"dev": true,
"optional": true,
"requires": {
"safer-buffer": "
2.1.2
"
"safer-buffer": "
^2.1.0
"
}
},
"ignore-walk": {
...
...
@@ -7994,7 +7994,7 @@
"dev": true,
"optional": true,
"requires": {
"minimatch": "3.0.4"
"minimatch": "
^
3.0.4"
}
},
"inflight": {
...
...
@@ -8003,8 +8003,8 @@
"dev": true,
"optional": true,
"requires": {
"once": "
1.4
.0",
"wrappy": "1
.0.2
"
"once": "
^1.3
.0",
"wrappy": "1"
}
},
"inherits": {
...
...
@@ -8025,7 +8025,7 @@
"dev": true,
"optional": true,
"requires": {
"number-is-nan": "
1.0.1
"
"number-is-nan": "
^1.0.0
"
}
},
"isarray": {
...
...
@@ -8040,7 +8040,7 @@
"dev": true,
"optional": true,
"requires": {
"brace-expansion": "
1.1.11
"
"brace-expansion": "
^1.1.7
"
}
},
"minimist": {
...
...
@@ -8055,8 +8055,8 @@
"dev": true,
"optional": true,
"requires": {
"safe-buffer": "5.1.1",
"yallist": "
3.0.2
"
"safe-buffer": "
^
5.1.1",
"yallist": "
^3.0.0
"
}
},
"minizlib": {
...
...
@@ -8065,7 +8065,7 @@
"dev": true,
"optional": true,
"requires": {
"minipass": "
2.2.4
"
"minipass": "
^2.2.1
"
}
},
"mkdirp": {
...
...
@@ -8089,9 +8089,9 @@
"dev": true,
"optional": true,
"requires": {
"debug": "
2.6.9
",
"iconv-lite": "
0.4.21
",
"sax": "1.2.4"
"debug": "
^2.1.2
",
"iconv-lite": "
^0.4.4
",
"sax": "
^
1.2.4"
}
},
"node-pre-gyp": {
...
...
@@ -8100,16 +8100,16 @@
"dev": true,
"optional": true,
"requires": {
"detect-libc": "
1.0.3
",
"mkdirp": "0.5.1",
"needle": "2.2.0",
"nopt": "4.0.1",
"npm-packlist": "
1.1.10
",
"npmlog": "
4.1
.2",
"rc": "
1.2
.7",
"rimraf": "
2.6.2
",
"semver": "
5.5
.0",
"tar": "
4.4.1
"
"detect-libc": "
^1.0.2
",
"mkdirp": "
^
0.5.1",
"needle": "
^
2.2.0",
"nopt": "
^
4.0.1",
"npm-packlist": "
^1.1.6
",
"npmlog": "
^4.0
.2",
"rc": "
^1.1
.7",
"rimraf": "
^2.6.1
",
"semver": "
^5.3
.0",
"tar": "
^4
"
}
},
"nopt": {
...
...
@@ -8118,8 +8118,8 @@
"dev": true,
"optional": true,
"requires": {
"abbrev": "1
.1.1
",
"osenv": "
0.1.5
"
"abbrev": "1",
"osenv": "
^0.1.4
"
}
},
"npm-bundled": {
...
...
@@ -8134,8 +8134,8 @@
"dev": true,
"optional": true,
"requires": {
"ignore-walk": "3.0.1",
"npm-bundled": "
1.0.3
"
"ignore-walk": "
^
3.0.1",
"npm-bundled": "
^1.0.1
"
}
},
"npmlog": {
...
...
@@ -8144,10 +8144,10 @@
"dev": true,
"optional": true,
"requires": {
"are-we-there-yet": "
1.1.4
",
"console-control-strings": "1.1.0",
"gauge": "
2.7.4
",
"set-blocking": "2.0.0"
"are-we-there-yet": "
~1.1.2
",
"console-control-strings": "
~
1.1.0",
"gauge": "
~2.7.3
",
"set-blocking": "
~
2.0.0"
}
},
"number-is-nan": {
...
...
@@ -8168,7 +8168,7 @@
"dev": true,
"optional": true,
"requires": {
"wrappy": "1
.0.2
"
"wrappy": "1"
}
},
"os-homedir": {
...
...
@@ -8189,8 +8189,8 @@
"dev": true,
"optional": true,
"requires": {
"os-homedir": "
1.0.2
",
"os-tmpdir": "
1.0.2
"
"os-homedir": "
^1.0.0
",
"os-tmpdir": "
^1.0.0
"
}
},
"path-is-absolute": {
...
...
@@ -8211,10 +8211,10 @@
"dev": true,
"optional": true,
"requires": {
"deep-extend": "0.5.1",
"ini": "
1.3.5
",
"minimist": "1.2.0",
"strip-json-comments": "2.0.1"
"deep-extend": "
^
0.5.1",
"ini": "
~1.3.0
",
"minimist": "
^
1.2.0",
"strip-json-comments": "
~
2.0.1"
},
"dependencies": {
"minimist": {
...
...
@@ -8231,13 +8231,13 @@
"dev": true,
"optional": true,
"requires": {
"core-util-is": "
1.0.2
",
"inherits": "2.0.3",
"isarray": "1.0.0",
"process-nextick-args": "2.0.0",
"safe-buffer": "5.1.1",
"string_decoder": "1.1.1",
"util-deprecate": "
1.0.2
"
"core-util-is": "
~1.0.0
",
"inherits": "
~
2.0.3",
"isarray": "
~
1.0.0",
"process-nextick-args": "
~
2.0.0",
"safe-buffer": "
~
5.1.1",
"string_decoder": "
~
1.1.1",
"util-deprecate": "
~1.0.1
"
}
},
"rimraf": {
...
...
@@ -8246,7 +8246,7 @@
"dev": true,
"optional": true,
"requires": {
"glob": "
7.1.2
"
"glob": "
^7.0.5
"
}
},
"safe-buffer": {
...
...
@@ -8291,9 +8291,9 @@
"dev": true,
"optional": true,
"requires": {
"code-point-at": "
1.1
.0",
"is-fullwidth-code-point": "1.0.0",
"strip-ansi": "
3.0.1
"
"code-point-at": "
^1.0
.0",
"is-fullwidth-code-point": "
^
1.0.0",
"strip-ansi": "
^3.0.0
"
}
},
"string_decoder": {
...
...
@@ -8302,7 +8302,7 @@
"dev": true,
"optional": true,
"requires": {
"safe-buffer": "
5.1.1
"
"safe-buffer": "
~5.1.0
"
}
},
"strip-ansi": {
...
...
@@ -8311,7 +8311,7 @@
"dev": true,
"optional": true,
"requires": {
"ansi-regex": "
2.1.1
"
"ansi-regex": "
^2.0.0
"
}
},
"strip-json-comments": {
...
...
@@ -8326,13 +8326,13 @@
"dev": true,
"optional": true,
"requires": {
"chownr": "1.0.1",
"fs-minipass": "1.2.5",
"minipass": "2.2.4",
"minizlib": "1.1.0",
"mkdirp": "
0.5.1
",
"safe-buffer": "5.1.1",
"yallist": "3.0.2"
"chownr": "
^
1.0.1",
"fs-minipass": "
^
1.2.5",
"minipass": "
^
2.2.4",
"minizlib": "
^
1.1.0",
"mkdirp": "
^0.5.0
",
"safe-buffer": "
^
5.1.1",
"yallist": "
^
3.0.2"
}
},
"util-deprecate": {
...
...
@@ -8347,7 +8347,7 @@
"dev": true,
"optional": true,
"requires": {
"string-width": "1.0.2"
"string-width": "
^
1.0.2"
}
},
"wrappy": {
...
...
src/web/components/header/header.js
浏览文件 @
33784cb3
import
{
Component
,
PropTypes
}
from
'
react
'
;
import
React
,
{
Component
,
PropTypes
}
from
'
react
'
;
import
{
observable
,
computed
,
toJS
}
from
'
mobx
'
;
import
{
observer
,
inject
}
from
'
mobx-react
'
;
import
{
registerTmpl
}
from
'
nornj-react
'
;
...
...
@@ -20,6 +20,7 @@ export default class Header extends Component {
@
observable
hash
=
''
;
// url标签
@
observable
visible
=
false
;
@
observable
showMenu
=
false
;
// 是否显示左侧菜单
// 菜单
@
observable
menuData
=
[{
...
...
@@ -49,6 +50,26 @@ export default class Header extends Component {
});
}
titleItem
=
()
=>
(
// <div className={styles.logo} style={{'background': '#333'}}>
// asdf
// </div>
<
div
>
menu
<
/div
>
)
// 点击左侧弹出菜单
@
autobind
handleMenuShow
(
e
)
{
this
.
showMenu
=
true
;
}
@
autobind
handleMenuHide
(
e
)
{
this
.
showMenu
=
false
;
}
//查看账本信息
@
autobind
onClickEye
(){
...
...
src/web/components/header/header.scss
浏览文件 @
33784cb3
...
...
@@ -20,7 +20,14 @@
flex
:
1
;
@media
(
max-width
:
950px
){
margin-left
:
0
;
display
:
none
;
}
// @media (max-width:500px) {
// display: none;
// // .menuDr {
// // display: block;
// // }
// }
li
{
color
:
#fff
!
important
;
font-size
:
16px
;
...
...
@@ -40,6 +47,20 @@
background-repeat
:
no-repeat
;
}
.color
{
color
:
'red'
}
.menuDr
{
line-height
:
62px
;
display
:
none
;
margin
:
2px
0
0
10px
;
color
:
#fff
;
@media
(
max-width
:
950px
)
{
display
:
block
;
}
}
.note
{
color
:
#fff
;
float
:right
;
...
...
@@ -49,7 +70,7 @@
line-height
:
14px
;
display
:
flex
;
align-items
:
center
;
@media
(
max-width
:
950px
){
@media
(
max-width
:
950px
)
and
(
min-width
:
501px
)
{
display
:
none
;
}
...
...
src/web/components/header/header.t.html
浏览文件 @
33784cb3
<header
class=
"site-header"
>
<div
class=
"logo"
>
</div>
<ant-Icon
class=
"menuDr"
type=
"menu"
onClick=
{handleMenuShow}/
>
<ant-Menu
mode=
"horizontal"
class=
"nav"
selectedKeys=
{store.header.selectMenu}
onClick=
{CheckMenu}
>
<!-- <ant-MenuItem key="search"> <ant-Icon type="home" />首页</ant-MenuItem>
<ant-MenuItem key="account"> <ant-Icon type="switcher" />数据账户</ant-MenuItem>
...
...
@@ -37,7 +38,7 @@
visible=
{visible}
maskClosable=
{true}
onClose=
{onClose}
>
>
<fj-Row
class=
"gl"
>
<fj-Col
l=
3
>
账本种子
</fj-Col>
...
...
@@ -103,4 +104,25 @@
columns=
{toJS(tableColumns)}
dataSource=
{toJS(common.ledgerinfo.participantNodes)}
bordered
/>
</ant-Drawer>
<ant-Drawer
title=
{titleItem()}
placement=
"left"
visible=
{showMenu}
onClose=
{handleMenuHide}
closable=
{true}
maskClosable=
{true}
style=
"padding:0"
>
<ant-Menu
mode=
"vertical"
selectedKeys=
{store.header.selectMenu}
onClick=
{CheckMenu}
>
<!-- <ant-MenuItem key="search"> <ant-Icon type="home" />首页</ant-MenuItem>
<ant-MenuItem key="account"> <ant-Icon type="switcher" />数据账户</ant-MenuItem>
<ant-MenuItem key="3"> <ant-Icon type="block" />区块</ant-MenuItem>
<ant-MenuItem key="4"> <ant-Icon type="swap" />交易</ant-MenuItem>
<ant-MenuItem key="user"> <ant-Icon type="user" />用户</ant-MenuItem> -->
<
#each
{
store.header.menuData
}
>
<ant-MenuItem
key=
{path}
>
<ant-Icon
type=
{icon}
/>
{name}
</ant-MenuItem>
</
#
each>
</ant-Menu>
</ant-Drawer>
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录