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
6eb7139a
Commit
6eb7139a
authored
Jun 03, 2019
by
ιεΈ
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add netlify logo in footer
parent
34c74a05
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
0 deletions
+26
-0
src/layouts/BasicLayout.tsx
src/layouts/BasicLayout.tsx
+26
-0
No files found.
src/layouts/BasicLayout.tsx
View file @
6eb7139a
...
...
@@ -11,6 +11,7 @@ import React, { useState } from 'react';
import
logo
from
'
../assets/logo.svg
'
;
import
Authorized
from
'
@/utils/Authorized
'
;
import
{
formatMessage
}
from
'
umi-plugin-react/locale
'
;
import
{
isAntDesignProOrDev
}
from
'
@/utils/utils
'
;
import
{
BasicLayout
as
ProLayoutComponents
,
BasicLayoutProps
as
ProLayoutComponentsProps
,
...
...
@@ -40,6 +41,30 @@ const menuDataRender = (menuList: MenuDataItem[]): MenuDataItem[] => {
});
};
const
footerRender
:
BasicLayoutProps
[
'
footerRender
'
]
=
(
_
,
defaultDom
)
=>
{
if
(
!
isAntDesignProOrDev
())
{
return
defaultDom
;
}
return
(
<>
{
defaultDom
}
<
div
style
=
{
{
textAlign
:
'
center
'
,
padding
:
'
0px 20px 20px
'
,
}
}
>
<
a
href
=
"https://www.netlify.com"
>
<
img
src
=
"https://www.netlify.com/img/global/badges/netlify-dark.svg"
alt
=
"netlify logo"
/>
</
a
>
</
div
>
</>
);
};
const
BasicLayout
:
React
.
FC
<
BasicLayoutProps
>
=
props
=>
{
const
{
dispatch
,
children
,
settings
}
=
props
;
/**
...
...
@@ -86,6 +111,7 @@ const BasicLayout: React.FC<BasicLayoutProps> = props => {
...
routers
,
];
}
}
footerRender
=
{
footerRender
}
menuDataRender
=
{
menuDataRender
}
formatMessage
=
{
formatMessage
}
rightContentRender
=
{
rightProps
=>
<
RightContent
{
...
rightProps
}
/>
}
...
...
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