Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
ant-design-pro
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Thiago Borges
ant-design-pro
Commits
474c7468
Commit
474c7468
authored
Jan 07, 2018
by
Connor Brathwaite
Committed by
偏右
Jan 07, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(GlobalFooter): manually define link item keys (#586)
parent
662fd28c
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
4 deletions
+13
-4
basic.md
src/components/GlobalFooter/demo/basic.md
+6
-2
index.js
src/components/GlobalFooter/index.js
+1
-1
BasicLayout.js
src/layouts/BasicLayout.js
+4
-1
UserLayout.js
src/layouts/UserLayout.js
+2
-0
No files found.
src/components/GlobalFooter/demo/basic.md
View file @
474c7468
...
...
@@ -11,12 +11,16 @@ import GlobalFooter from 'ant-design-pro/lib/GlobalFooter';
import { Icon } from 'antd';
const links = [{
key: '帮助',
title: '帮助',
href: '',
}, {
title: '隐私',
href: '',
key: 'github'
title: <Icon type="github" />,
href: 'https://github.com/ant-design/ant-design-pro',
blankTarget: true,
}, {
key: '条款',
title: '条款',
href: '',
blankTarget: true,
...
...
src/components/GlobalFooter/index.js
View file @
474c7468
...
...
@@ -11,7 +11,7 @@ export default ({ className, links, copyright }) => {
<
div
className
=
{
styles
.
links
}
>
{
links
.
map
(
link
=>
(
<
a
key
=
{
link
.
title
}
key
=
{
link
.
key
}
target
=
{
link
.
blankTarget
?
'_blank'
:
'_self'
}
href
=
{
link
.
href
}
>
...
...
src/layouts/BasicLayout.js
View file @
474c7468
...
...
@@ -184,14 +184,17 @@ class BasicLayout extends React.PureComponent {
<
/div
>
<
GlobalFooter
links
=
{[{
key
:
'Pro 首页'
,
title
:
'Pro 首页'
,
href
:
'http://pro.ant.design'
,
blankTarget
:
true
,
},
{
title
:
'GitHub'
,
key
:
'github'
,
title
:
<
Icon
type
=
"github"
/>
,
href
:
'https://github.com/ant-design/ant-design-pro'
,
blankTarget
:
true
,
},
{
key
:
'Ant Design'
,
title
:
'Ant Design'
,
href
:
'http://ant.design'
,
blankTarget
:
true
,
...
...
src/layouts/UserLayout.js
View file @
474c7468
...
...
@@ -11,9 +11,11 @@ const links = [{
title
:
'帮助'
,
href
:
''
,
},
{
key
:
'隐私'
,
title
:
'隐私'
,
href
:
''
,
},
{
key
:
'隐私'
,
title
:
'条款'
,
href
:
''
,
}];
...
...
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