From 811152faa3ca9ef4e082acdd949732a13283a773 Mon Sep 17 00:00:00 2001 From: algerkong Date: Wed, 21 Jul 2021 15:01:39 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=8A=A8=E7=94=BB=E6=95=88?= =?UTF-8?q?=E6=9E=9C,=E6=8A=BD=E5=87=BA=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/PlaylistType.vue | 68 +++++++++ src/components/RecommendSinger.vue | 70 +++++++++ src/components/RecommendSonglist.vue | 52 +++++++ src/components/common/SongItem.vue | 91 +++++++++++ src/layout/AppLayout.vue | 103 +------------ src/layout/components/PlayBar.vue | 61 ++++++++ src/layout/components/SearchBar.vue | 65 ++++++++ src/layout/components/index.ts | 4 +- src/utils/index.ts | 12 ++ src/views/home/index.vue | 216 +-------------------------- 10 files changed, 437 insertions(+), 305 deletions(-) create mode 100644 src/components/PlaylistType.vue create mode 100644 src/components/RecommendSinger.vue create mode 100644 src/components/RecommendSonglist.vue create mode 100644 src/components/common/SongItem.vue create mode 100644 src/layout/components/PlayBar.vue create mode 100644 src/layout/components/SearchBar.vue create mode 100644 src/utils/index.ts diff --git a/src/components/PlaylistType.vue b/src/components/PlaylistType.vue new file mode 100644 index 0000000..95c737c --- /dev/null +++ b/src/components/PlaylistType.vue @@ -0,0 +1,68 @@ + + + + + diff --git a/src/components/RecommendSinger.vue b/src/components/RecommendSinger.vue new file mode 100644 index 0000000..a99893a --- /dev/null +++ b/src/components/RecommendSinger.vue @@ -0,0 +1,70 @@ + + + + + diff --git a/src/components/RecommendSonglist.vue b/src/components/RecommendSonglist.vue new file mode 100644 index 0000000..b2eb44e --- /dev/null +++ b/src/components/RecommendSonglist.vue @@ -0,0 +1,52 @@ + + + + + \ No newline at end of file diff --git a/src/components/common/SongItem.vue b/src/components/common/SongItem.vue new file mode 100644 index 0000000..e32d34f --- /dev/null +++ b/src/components/common/SongItem.vue @@ -0,0 +1,91 @@ + + + + + diff --git a/src/layout/AppLayout.vue b/src/layout/AppLayout.vue index cf6be4c..6459658 100644 --- a/src/layout/AppLayout.vue +++ b/src/layout/AppLayout.vue @@ -2,105 +2,26 @@
+
- + + +
-
- -
-
-
- - - playMusicEvent -
+ +
\ No newline at end of file diff --git a/src/layout/components/PlayBar.vue b/src/layout/components/PlayBar.vue new file mode 100644 index 0000000..5812933 --- /dev/null +++ b/src/layout/components/PlayBar.vue @@ -0,0 +1,61 @@ + + + + + \ No newline at end of file diff --git a/src/layout/components/SearchBar.vue b/src/layout/components/SearchBar.vue new file mode 100644 index 0000000..d67ff43 --- /dev/null +++ b/src/layout/components/SearchBar.vue @@ -0,0 +1,65 @@ + + + + + \ No newline at end of file diff --git a/src/layout/components/index.ts b/src/layout/components/index.ts index 682bee0..1acfebf 100644 --- a/src/layout/components/index.ts +++ b/src/layout/components/index.ts @@ -1,3 +1,5 @@ import AppMenu from "./AppMenu.vue"; +import PlayBar from "./PlayBar.vue"; +import SearchBar from "./SearchBar.vue"; -export { AppMenu }; +export { AppMenu, PlayBar, SearchBar }; diff --git a/src/utils/index.ts b/src/utils/index.ts new file mode 100644 index 0000000..e32515e --- /dev/null +++ b/src/utils/index.ts @@ -0,0 +1,12 @@ +// 设置歌手背景图片 +export const setBackgroundImg = (url: String) => { + return "background-image:" + "url(" + url + ")"; +}; +// 设置动画类型 +export const setAnimationClass = (type: String) => { + return "animate__animated " + type; +}; +// 设置动画延时 +export const setAnimationDelay = (index: number = 6, time: number = 50) => { + return "animation-delay:" + index * time + "ms"; +}; diff --git a/src/views/home/index.vue b/src/views/home/index.vue index 6bdf870..3794a1b 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -2,226 +2,26 @@
-
-
-
-
-
{{ item.musicSize }}首
-
-
- -
-
-
{{ item.name }}
-
{{ item.name }}
-
-
-
-
-
+
-
-
歌单分类
- - -
{{ !isShowAllPlaylistCategory ? '显示全部' : '隐藏一些' }}
-
-
-
-
本周最热音乐
- - - - - - -
+ + +
\ No newline at end of file +