Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
ycc-website
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
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
Website
ycc-website
Commits
89a38181
Commit
89a38181
authored
Feb 22, 2022
by
chenqikuai
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 新增首页动画
parent
f49072a7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
170 additions
and
26 deletions
+170
-26
App.vue
src/App.vue
+13
-0
cc-image.png
src/assets/images/blockChainBrowser/cc-image.png
+0
-0
bg_t.png
src/assets/images/home/bg_t.png
+0
-0
bg_t_2.png
src/assets/images/home/bg_t_2.png
+0
-0
ChainCard.vue
...mponents/pc/BlockChainBrowser/ChainOverview/ChainCard.vue
+8
-8
ChainSearch.vue
src/components/pc/BlockChainBrowser/ChainSearch.vue
+2
-2
ChainTitle.vue
src/components/pc/BlockChainBrowser/ChainTitle.vue
+26
-6
banner.vue
src/components/pc/banner.vue
+2
-5
Header.vue
src/layout/MainPage/Header.vue
+16
-0
index.vue
src/layout/MainPage/index.vue
+1
-0
Home.vue
src/views/pc/Home.vue
+0
-0
blockChainBrowser.vue
src/views/pc/blockChainBrowser.vue
+102
-5
No files found.
src/App.vue
View file @
89a38181
...
@@ -39,4 +39,17 @@ export default Vue.extend({
...
@@ -39,4 +39,17 @@ export default Vue.extend({
font-weight
:
400
;
font-weight
:
400
;
color
:
#1f3470
;
color
:
#1f3470
;
}
}
.slide-in-enter-active
{
transition
:
all
.3s
ease
;
}
.slide-in-leave-active
{
transition
:
all
.8s
cubic-bezier
(
1.0
,
0.5
,
0.8
,
1.0
);
}
.slide-in-enter
,
.slide-fade-leave-to
/* .slide-in-leave-active for below version 2.1.8 */
{
transform
:
translateX
(
10px
);
opacity
:
0
;
}
</
style
>
</
style
>
src/assets/images/blockChainBrowser/cc-image.png
0 → 100644
View file @
89a38181
166 KB
src/assets/images/home/bg_t.png
deleted
100644 → 0
View file @
f49072a7
576 KB
src/assets/images/home/bg_t_2.png
0 → 100644
View file @
89a38181
706 KB
src/components/pc/BlockChainBrowser/ChainOverview/ChainCard.vue
View file @
89a38181
...
@@ -5,12 +5,12 @@
...
@@ -5,12 +5,12 @@
v-for=
"(item, index) in msgList"
v-for=
"(item, index) in msgList"
:key=
"index"
:key=
"index"
>
>
<img
:src=
"item.icon"
class=
"w-8 h-8
"
alt=
""
/>
<img
:src=
"item.icon"
style=
"width: 52px; height: 52px;
"
alt=
""
/>
<div>
<div>
<div
class=
"text-text-color font-normal"
>
<div
class=
"text-text-color font-normal"
>
{{
item
.
title
}}
{{
item
.
title
}}
</div>
</div>
<div
class=
"text-title-color
text-xl font-bold
"
>
<div
class=
"text-title-color
font-bold"
style=
"font-size: 32px;
"
>
{{
item
.
number
}}
{{
item
.
number
}}
</div>
</div>
</div>
</div>
...
@@ -34,18 +34,18 @@ export default Vue.extend({
...
@@ -34,18 +34,18 @@ export default Vue.extend({
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.card
{
.card
{
width
:
25
0px
;
width
:
40
0px
;
height
:
313
px
;
height
:
500
px
;
background
:
#ffffff
;
background
:
#ffffff
;
box-shadow
:
0px
9px
25px
0px
rgba
(
31
,
52
,
112
,
0.14
);
box-shadow
:
0px
9px
25px
0px
rgba
(
31
,
52
,
112
,
0.14
);
border-radius
:
25
px
;
border-radius
:
40
px
;
padding-top
:
2
0px
;
padding-top
:
3
0px
;
}
}
.item
{
.item
{
height
:
69
px
;
height
:
110
px
;
padding-left
:
19px
;
padding-left
:
19px
;
}
}
.item
img
{
.item
img
{
margin-right
:
13
px
;
margin-right
:
20
px
;
}
}
</
style
>
</
style
>
src/components/pc/BlockChainBrowser/ChainSearch.vue
View file @
89a38181
<
template
>
<
template
>
<div
class=
"search flex items-center shadow-shadow1"
>
<div
class=
"search flex items-center shadow-shadow1
overflow-hidden
"
>
<input
<input
type=
"text"
type=
"text"
:value=
"value"
:value=
"value"
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
@
click=
"!loading && searchResult(value)"
@
click=
"!loading && searchResult(value)"
v-loading=
"loading"
v-loading=
"loading"
>
>
{{
$t
(
'lang.search'
)
}}
{{
$t
(
'lang.search'
)
}}
</div>
</div>
</div>
</div>
</
template
>
</
template
>
...
...
src/components/pc/BlockChainBrowser/ChainTitle.vue
View file @
89a38181
<
template
>
<
template
>
<div>
<div>
<div
class=
"flex"
>
<div
class=
"flex
chain-title-img relative
"
>
<img
:src=
"yc"
alt=
""
style=
"width: 222px; height: 147px;"
class=
"yc"
/>
<img
:src=
"yc"
alt=
""
style=
"width: 222px; height: 147px;"
class=
"yc"
/>
<img
:src=
"cc"
alt=
""
style=
"with: 214px; height: 147px;"
class=
"cc"
/>
<img
:src=
"cc"
alt=
""
style=
"with: 214px; height: 147px;"
class=
"cc"
/>
</div>
</div>
<div
class=
"text-lightBlue title relative z-10"
>
<div
{{
$t
(
'lang.yccBlockChainBrowser'
)
}}
class=
"text-lightBlue title relative z-10 chain-title-txt mt-4 text-center"
>
{{
$t
(
'lang.yccBlockChainBrowser'
)
}}
</div>
</div>
</div>
</div>
</
template
>
</
template
>
...
@@ -23,14 +25,32 @@ export default Vue.extend({
...
@@ -23,14 +25,32 @@ export default Vue.extend({
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.yc
{
.chain-title-img
{
position
:
relative
;
animation-name
:
fadeIn
;
animation-duration
:
2s
;
animation-timing-function
:
ease-out
;
animation-fill-mode
:
forwards
;
opacity
:
0
;
z-index
:
4
;
z-index
:
4
;
margin-right
:
4px
;
}
}
.chain-title-txt
{
animation-name
:
fadeIn
;
animation-duration
:
2s
;
animation-timing-function
:
ease-out
;
animation-fill-mode
:
forwards
;
animation-delay
:
0.3s
;
opacity
:
0
;
z-index
:
4
;
}
.cc
{
.cc
{
z-index
:
4
;
z-index
:
4
;
}
}
.yc
{
position
:
relative
;
margin-right
:
4px
;
z-index
:
4
;
}
.title
{
.title
{
font-size
:
53px
;
font-size
:
53px
;
}
}
...
...
src/components/pc/banner.vue
View file @
89a38181
<
template
>
<
template
>
<div
class=
"home_banner relative w-full"
>
<div
class=
"home_banner relative w-full
overflow-hidden
"
>
<div
class=
"banner_content md:w-bodySet"
>
<div
class=
"banner_content md:w-bodySet"
>
<img
src=
"../../assets/images/home/bg_t_2.png"
style=
"width:1021px;height:923px; position:absolute; left: 404px;top:-307px;"
alt=
""
>
<img
class=
"mb-7 w-52"
src=
"@/assets/images/home/ycc.png"
alt=
"YCC"
>
<img
class=
"mb-7 w-52"
src=
"@/assets/images/home/ycc.png"
alt=
"YCC"
>
<div
class=
"flex mb-5"
>
<div
class=
"flex mb-5"
>
<p
class=
"text-4xl"
style=
"color: #3D5EE9"
>
<p
class=
"text-4xl"
style=
"color: #3D5EE9"
>
...
@@ -43,10 +44,6 @@ export default Vue.extend({
...
@@ -43,10 +44,6 @@ export default Vue.extend({
.home_banner
{
.home_banner
{
/* width: 1200px; */
/* width: 1200px; */
height
:
798px
;
height
:
798px
;
background-image
:
url('../../assets/images/home/bg_t.png')
;
background-size
:
cover
;
background-repeat
:
no-repeat
;
background-position-x
:
50%
;
position
:
relative
;
position
:
relative
;
}
}
.banner_content
{
.banner_content
{
...
...
src/layout/MainPage/Header.vue
View file @
89a38181
...
@@ -18,6 +18,9 @@
...
@@ -18,6 +18,9 @@
:to=
"
{ path: '/home', query: { lang: $route.query.lang } }"
:to=
"
{ path: '/home', query: { lang: $route.query.lang } }"
tag="li"
tag="li"
class="pl-5 pr-5 cursor-pointer relative"
class="pl-5 pr-5 cursor-pointer relative"
:class="{
' text-white': $route.path === '/blockChainBrowser'
&&
isTop,
}"
>
>
{{
$t
(
'lang.home'
)
}}
{{
$t
(
'lang.home'
)
}}
<span
<span
...
@@ -27,6 +30,10 @@
...
@@ -27,6 +30,10 @@
</router-link>
</router-link>
<li
class=
"pl-5 pr-5 cursor-pointer"
>
<li
class=
"pl-5 pr-5 cursor-pointer"
>
<a
<a
:class=
"
{
' text-white': $route.path === '/blockChainBrowser'
&&
isTop,
}"
class="transition-none"
:href="
:href="
iconType === 'zh-CN'
iconType === 'zh-CN'
? 'https://yuanorg.oss-ap-southeast-1.aliyuncs.com/ycc/white-paper/zh.pdf'
? 'https://yuanorg.oss-ap-southeast-1.aliyuncs.com/ycc/white-paper/zh.pdf'
...
@@ -40,6 +47,9 @@
...
@@ -40,6 +47,9 @@
<router-link
<router-link
:to=
"
{ path: '/newsList', query: { lang: $route.query.lang } }"
:to=
"
{ path: '/newsList', query: { lang: $route.query.lang } }"
tag="li"
tag="li"
:class="{
' text-white': $route.path === '/blockChainBrowser'
&&
isTop,
}"
class="pl-5 pr-5 cursor-pointer relative"
class="pl-5 pr-5 cursor-pointer relative"
>
>
{{
$t
(
'lang.news'
)
}}
{{
$t
(
'lang.news'
)
}}
...
@@ -57,6 +67,9 @@
...
@@ -57,6 +67,9 @@
}"
}"
tag="li"
tag="li"
class="pl-5 pr-5 cursor-pointer relative"
class="pl-5 pr-5 cursor-pointer relative"
:class="{
' text-white': $route.path === '/blockChainBrowser'
&&
isTop,
}"
>
>
{{
$t
(
'lang.blockChainBrowser'
)
}}
{{
$t
(
'lang.blockChainBrowser'
)
}}
<span
<span
...
@@ -67,6 +80,9 @@
...
@@ -67,6 +80,9 @@
$route.path === '/tradeHash'
$route.path === '/tradeHash'
"
"
class=
"absolute block w-7 h-1 bg-active rounded-2xl left-1/2 -bottom-2 transform -translate-x-1/2"
class=
"absolute block w-7 h-1 bg-active rounded-2xl left-1/2 -bottom-2 transform -translate-x-1/2"
:class=
"
{
' bg-white': $route.path === '/blockChainBrowser'
&&
isTop,
}"
>
</span>
>
</span>
</router-link>
</router-link>
</ul>
</ul>
...
...
src/layout/MainPage/index.vue
View file @
89a38181
...
@@ -35,5 +35,6 @@ export default Vue.extend({
...
@@ -35,5 +35,6 @@ export default Vue.extend({
<
style
scoped
>
<
style
scoped
>
.ycc_container
{
.ycc_container
{
min-width
:
1200px
;
min-width
:
1200px
;
overflow
:
hidden
;
}
}
</
style
>
</
style
>
src/views/pc/Home.vue
View file @
89a38181
This diff is collapsed.
Click to expand it.
src/views/pc/blockChainBrowser.vue
View file @
89a38181
<
template
>
<
template
>
<div
class=
"mx-auto md:w-bodySet blockChain min-w-1200 relative flow-root"
>
<div
class=
"mx-auto md:w-bodySet blockChain min-w-1200 relative flow-root"
>
<img
:src=
"ccImg"
alt=
""
class=
"ccImg"
style=
"
width: 1920px;
height: 1265px;
position: absolute;
top: -549px;
right: -1073px;
"
/>
<div
class=
"stone"
></div>
<ChainCard
:msgList=
"msgList"
class=
"chainCard"
></ChainCard>
<ChainCard
:msgList=
"msgList"
class=
"chainCard"
></ChainCard>
<ChainTitle
/>
<ChainTitle
class=
"chain-title"
/>
<div
class=
"blue-card"
></div>
<chain-search
<chain-search
class=
"chain-search"
style=
"width: 600px;"
style=
"width: 600px;"
:value=
"value"
:value=
"value"
:setValue=
"setValue"
:setValue=
"setValue"
:clickSearch=
"clickSearch"
:clickSearch=
"clickSearch"
/>
/>
<div
class=
"rect-block"
></div>
<ChainOverview
:totalTx=
"totalTx"
/>
<ChainOverview
:totalTx=
"totalTx"
/>
<div
class=
"flex justify-between mt-14"
style=
"margin-bottom: 60px;"
>
<div
class=
"flex justify-between mt-14"
style=
"margin-bottom: 60px;"
>
<latest-block
:latestBlocks=
"latestBlocks"
></latest-block>
<latest-block
:latestBlocks=
"latestBlocks"
></latest-block>
...
@@ -25,7 +39,7 @@ import ChainSearch from '@/components/pc/BlockChainBrowser/ChainSearch.vue'
...
@@ -25,7 +39,7 @@ import ChainSearch from '@/components/pc/BlockChainBrowser/ChainSearch.vue'
import
ChainOverview
from
'@/components/pc/BlockChainBrowser/ChainOverview/index.vue'
import
ChainOverview
from
'@/components/pc/BlockChainBrowser/ChainOverview/index.vue'
import
LatestBlock
from
'@/components/pc/BlockChainBrowser/LatestBlock/index.vue'
import
LatestBlock
from
'@/components/pc/BlockChainBrowser/LatestBlock/index.vue'
import
LatestTx
from
'@/components/pc/BlockChainBrowser/LatestTx/index.vue'
import
LatestTx
from
'@/components/pc/BlockChainBrowser/LatestTx/index.vue'
import
ccImg
from
'@/assets/images/blockChainBrowser/cc-image.png'
import
blockChainBrowserMixin
from
'@/mixin/blockChainBrowser'
import
blockChainBrowserMixin
from
'@/mixin/blockChainBrowser'
export
default
VueTypedMixins
(
blockChainBrowserMixin
).
extend
({
export
default
VueTypedMixins
(
blockChainBrowserMixin
).
extend
({
...
@@ -37,6 +51,11 @@ export default VueTypedMixins(blockChainBrowserMixin).extend({
...
@@ -37,6 +51,11 @@ export default VueTypedMixins(blockChainBrowserMixin).extend({
LatestBlock
,
LatestBlock
,
LatestTx
,
LatestTx
,
},
},
data
()
{
return
{
ccImg
,
}
},
})
})
</
script
>
</
script
>
...
@@ -44,8 +63,86 @@ export default VueTypedMixins(blockChainBrowserMixin).extend({
...
@@ -44,8 +63,86 @@ export default VueTypedMixins(blockChainBrowserMixin).extend({
.blockChain
{
.blockChain
{
padding-top
:
64px
;
padding-top
:
64px
;
}
}
.ccImg
{
animation-name
:
rotate
;
animation-fill-mode
:
forwards
;
animation-duration
:
0.7s
;
animation-delay
:
0.4s
;
}
@keyframes
rotate
{
from
{
transform
:
rotate
(
0
);
}
to
{
transform
:
rotate
(
90deg
);
}
}
.chainCard
{
.chainCard
{
position
:
relative
;
position
:
absolute
;
z-index
:
1
;
z-index
:
2
;
top
:
102px
;
animation-name
:
slideIn
;
animation-duration
:
0.7s
;
animation-timing-function
:
ease-out
;
}
.chain-title
{
position
:
absolute
;
top
:
172px
;
left
:
575px
;
}
.chain-search
{
position
:
absolute
;
top
:
472px
;
left
:
572px
;
animation-name
:
fadeIn
;
animation-duration
:
1s
;
animation-timing-function
:
ease-out
;
animation-delay
:
0.5s
;
opacity
:
0
;
animation-fill-mode
:
forwards
;
}
.stone
{
height
:
832px
;
}
.blue-card
{
position
:
absolute
;
top
:
0px
;
left
:
197px
;
width
:
600px
;
height
:
840px
;
background
:
#2545cb
;
animation-name
:
slideDown
;
animation-duration
:
0.7s
;
animation-timing-function
:
ease-out
;
}
</
style
>
<
style
>
@keyframes
slideDown
{
from
{
transform
:
translateY
(
-100%
);
}
to
{
transform
:
translateY
(
0
);
}
}
@keyframes
slideIn
{
from
{
transform
:
translateX
(
-20px
);
opacity
:
0
;
}
to
{
transform
:
translateX
(
0
);
}
}
@keyframes
fadeIn
{
from
{
opacity
:
0
;
}
to
{
opacity
:
1
;
}
}
}
</
style
>
</
style
>
chenqikuai
@chenqikuai
mentioned in commit
748f7ae1
·
Mar 03, 2022
mentioned in commit
748f7ae1
mentioned in commit 748f7ae18ac2f8eb14ee7c2865eaea786342a520
Toggle commit list
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