mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-25 11:40:04 +08:00
site: add promote link
This commit is contained in:
parent
ea3e923349
commit
8ccd6b8277
@ -375,3 +375,13 @@ svg {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.banner-1024 {
|
||||
cursor: pointer;
|
||||
transition: all .4s;
|
||||
display: block;
|
||||
|
||||
&:hover {
|
||||
transform: translateY(-16px) scale(1.01);
|
||||
}
|
||||
}
|
||||
|
@ -50,10 +50,13 @@ class Banner extends React.PureComponent {
|
||||
<ScrollParallax location="banner" className="banner-bg" animation={{ playScale: [1, 1.5], rotate: 0 }} />
|
||||
</div>
|
||||
<QueueAnim className={`${className} page`} type="alpha" delay={150}>
|
||||
{isMobile && (
|
||||
<div className="img-wrapper" key="image">
|
||||
<BannerImage />
|
||||
</div>)}
|
||||
{
|
||||
isMobile && (
|
||||
<div className="img-wrapper" key="image">
|
||||
<BannerImage />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
<QueueAnim
|
||||
className="text-wrapper"
|
||||
key="text"
|
||||
|
@ -1,6 +1,7 @@
|
||||
import React from 'react';
|
||||
import TweenOne from 'rc-tween-one';
|
||||
import PathPlugin from 'rc-tween-one/lib/plugin/PathPlugin';
|
||||
import moment from 'moment';
|
||||
|
||||
TweenOne.plugins.push(PathPlugin);
|
||||
const duration = 7000;
|
||||
@ -58,6 +59,21 @@ function TweenOneG(props) {
|
||||
}
|
||||
|
||||
export default function BannerImage() {
|
||||
if (moment().format('YYYY-MM-DD') === '2018-10-24') {
|
||||
return (
|
||||
<a
|
||||
href="https://1024.yuque.com"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="banner-1024"
|
||||
>
|
||||
<img
|
||||
src="https://gw.alipayobjects.com/zos/rmsportal/BaqKyDBXRAzoncSoBQGU.svg"
|
||||
alt="1024"
|
||||
/>
|
||||
</a>
|
||||
);
|
||||
}
|
||||
return (
|
||||
<svg width="482px" height="500px" viewBox="0 0 482 500">
|
||||
<defs>
|
||||
|
Loading…
Reference in New Issue
Block a user