mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-11 23:00:20 +08:00
fix: npm run site (#23658)
This commit is contained in:
parent
1a428e852a
commit
2325a4438d
@ -32,6 +32,7 @@ export default ({
|
||||
onLangChange,
|
||||
onDirectionChange,
|
||||
}: NavigationProps) => {
|
||||
const [isGitee, setIsGitee] = React.useState(false);
|
||||
const menuMode = isMobile ? 'inline' : 'horizontal';
|
||||
|
||||
const module = pathname.split('/').slice(0, -1).join('/');
|
||||
@ -68,7 +69,9 @@ export default ({
|
||||
);
|
||||
}
|
||||
|
||||
const isGitee = document.location.host.indexOf('gitee') !== -1;
|
||||
React.useEffect(() => {
|
||||
setIsGitee(document.location.host.indexOf('gitee') !== -1);
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<Menu
|
||||
|
Loading…
Reference in New Issue
Block a user