Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
ant-design-pro
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
duanledexianxianxian
ant-design-pro
Commits
eee76430
Commit
eee76430
authored
Apr 03, 2019
by
陈帅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bugfix:fix #3904 change to formatMessage
parent
7679507b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/components/PageHeaderWrapper/breadcrumb.js
src/components/PageHeaderWrapper/breadcrumb.js
+2
-2
No files found.
src/components/PageHeaderWrapper/breadcrumb.js
View file @
eee76430
import
React
from
'
react
'
;
import
React
from
'
react
'
;
import
pathToRegexp
from
'
path-to-regexp
'
;
import
pathToRegexp
from
'
path-to-regexp
'
;
import
Link
from
'
umi/link
'
;
import
Link
from
'
umi/link
'
;
import
{
Formatted
Message
}
from
'
umi-plugin-react/locale
'
;
import
{
format
Message
}
from
'
umi-plugin-react/locale
'
;
import
{
urlToList
}
from
'
../_utils/pathTools
'
;
import
{
urlToList
}
from
'
../_utils/pathTools
'
;
// 渲染Breadcrumb 子节点
// 渲染Breadcrumb 子节点
...
@@ -17,7 +17,7 @@ const itemRender = (route, params, routes, paths) => {
...
@@ -17,7 +17,7 @@ const itemRender = (route, params, routes, paths) => {
const
renderItemLocal
=
item
=>
{
const
renderItemLocal
=
item
=>
{
if
(
item
.
locale
)
{
if
(
item
.
locale
)
{
return
<
FormattedMessage
id
=
{
item
.
locale
}
defaultMessage
=
{
item
.
name
}
/>
;
return
formatMessage
({
id
:
item
.
locale
,
defaultMessage
:
item
.
name
})
;
}
}
return
item
.
name
;
return
item
.
name
;
};
};
...
...
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