├── vue3NeteaseCloud ├── public │ ├── favicon.ico │ └── index.html ├── src │ ├── assets │ │ ├── cover.png │ │ ├── head.jpg │ │ ├── logo.png │ │ ├── liverpool.jpg │ │ ├── mui │ │ │ └── fonts │ │ │ │ └── mui.ttf │ │ ├── common.scss │ │ └── style.scss │ ├── api │ │ ├── album.js │ │ ├── sort.js │ │ ├── http.js │ │ ├── home.js │ │ ├── mv.js │ │ ├── search.js │ │ ├── playList.js │ │ └── singer.js │ ├── components │ │ ├── banners │ │ │ ├── getImgs.js │ │ │ └── banners.vue │ │ ├── footer │ │ │ ├── footer.scss │ │ │ └── footer.vue │ │ ├── common.vue │ │ ├── switchPannel │ │ │ └── switchPannel.vue │ │ ├── header │ │ │ ├── header.vue │ │ │ ├── header.scss │ │ │ └── headNav.vue │ │ ├── mv │ │ │ ├── MvTitle.vue │ │ │ ├── MvBlock.vue │ │ │ └── OneMv.vue │ │ ├── home │ │ │ ├── modTitle.vue │ │ │ ├── modMv.vue │ │ │ └── modSection.vue │ │ ├── searchBar │ │ │ └── searchBar.vue │ │ ├── songItem.vue │ │ ├── sort │ │ │ ├── sortPannel.vue │ │ │ └── trackPannel.vue │ │ ├── video │ │ │ └── VideoComponent.vue │ │ └── playBar │ │ │ ├── playBar.scss │ │ │ └── playBar.vue │ ├── tools │ │ ├── rem.js │ │ ├── sessionStore.js │ │ └── common.js │ ├── main.js │ ├── App.vue │ ├── store │ │ └── index.js │ ├── router │ │ └── index.js │ └── views │ │ ├── Home.vue │ │ ├── sort.vue │ │ ├── sortDetails.vue │ │ ├── playSquare.vue │ │ ├── singer.vue │ │ ├── playList.vue │ │ ├── MvIndex.vue │ │ ├── highqualitySquare.vue │ │ ├── album.vue │ │ ├── search.vue │ │ └── singerDetails.vue ├── babel.config.js ├── .babelrc ├── .gitignore ├── README.md ├── postcss.config.js ├── vue.config.js └── package.json └── README.md /vue3NeteaseCloud/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chensidi/vue3-project/HEAD/vue3NeteaseCloud/public/favicon.ico -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/assets/cover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chensidi/vue3-project/HEAD/vue3NeteaseCloud/src/assets/cover.png -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/assets/head.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chensidi/vue3-project/HEAD/vue3NeteaseCloud/src/assets/head.jpg -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chensidi/vue3-project/HEAD/vue3NeteaseCloud/src/assets/logo.png -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/assets/liverpool.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chensidi/vue3-project/HEAD/vue3NeteaseCloud/src/assets/liverpool.jpg -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/assets/mui/fonts/mui.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chensidi/vue3-project/HEAD/vue3NeteaseCloud/src/assets/mui/fonts/mui.ttf -------------------------------------------------------------------------------- /vue3NeteaseCloud/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: [ 3 | ['import', { 4 | libraryName: 'vant', 5 | libraryDirectory: 'es', 6 | style: true 7 | }, 'vant'] 8 | ] 9 | }; 10 | -------------------------------------------------------------------------------- /vue3NeteaseCloud/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "plugins": [ 3 | [ 4 | "import", 5 | { 6 | "libraryName": "vant", 7 | "libraryDirectory": "es", 8 | "style": true 9 | } 10 | ] 11 | ] 12 | } -------------------------------------------------------------------------------- /vue3NeteaseCloud/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | 6 | # local env files 7 | .env.local 8 | .env.*.local 9 | 10 | # Log files 11 | npm-debug.log* 12 | yarn-debug.log* 13 | yarn-error.log* 14 | pnpm-debug.log* 15 | 16 | # Editor directories and files 17 | .idea 18 | .vscode 19 | *.suo 20 | *.ntvs* 21 | *.njsproj 22 | *.sln 23 | *.sw? 24 | -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/api/album.js: -------------------------------------------------------------------------------- 1 | import { httpGet } from './http'; 2 | 3 | export const getAlbum = async (id) => { //专辑 4 | let res = await httpGet(`/album?id=${id}`).catch(err => { 5 | return Promise.reject(err); 6 | }) 7 | if(res.status === 200){ 8 | return res.data; 9 | }else{ 10 | return Promise.reject(res.status); 11 | } 12 | } -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/components/banners/getImgs.js: -------------------------------------------------------------------------------- 1 | import { httpGet } from '@/api/http.js'; 2 | 3 | const getImgs = async () => { 4 | let res = await httpGet('/banner').catch(err => { 5 | return Promise.reject(err); 6 | }) 7 | if(res.status === 200){ 8 | return res.data.banners; 9 | }else{ 10 | return Promise.reject(res.status); 11 | } 12 | } 13 | 14 | export default getImgs; -------------------------------------------------------------------------------- /vue3NeteaseCloud/README.md: -------------------------------------------------------------------------------- 1 | # app3.0beta 2 | 3 | ## Project setup 4 | ``` 5 | yarn install 6 | ``` 7 | 8 | ### Compiles and hot-reloads for development 9 | ``` 10 | yarn serve 11 | ``` 12 | 13 | ### Compiles and minifies for production 14 | ``` 15 | yarn build 16 | ``` 17 | 18 | ### Lints and fixes files 19 | ``` 20 | yarn lint 21 | ``` 22 | 23 | ### Customize configuration 24 | See [Configuration Reference](https://cli.vuejs.org/config/). 25 | -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/components/footer/footer.scss: -------------------------------------------------------------------------------- 1 | @mixin flex-b{ 2 | display: flex; 3 | align-items: center; 4 | justify-content: space-between; 5 | } 6 | .copyright { 7 | margin-top: 1.5rem; 8 | padding: .8rem 0; 9 | text-align: center; 10 | font-size: 12px; 11 | color: rgba(26,26,26,1); 12 | } 13 | .copyright__media { 14 | width: 4rem; 15 | height: 1.1rem; 16 | margin: 0 auto .5rem; 17 | img{ 18 | width: 100%; 19 | } 20 | } -------------------------------------------------------------------------------- /vue3NeteaseCloud/postcss.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | 'autoprefixer': { 4 | browsers: [ 5 | "> 1%", 6 | "last 5 versions", 7 | "not ie <= 8", 8 | "ios >= 7", 9 | "android >= 4.0" 10 | ] 11 | }, 12 | 'postcss-pxtorem': { 13 | rootValue: 20,//结果为:设计稿元素尺寸/16,比如元素宽320px,最终页面会换算成 20rem 14 | propList: ['*'] 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/tools/rem.js: -------------------------------------------------------------------------------- 1 | (function (doc, win) { // 自适应 2 | var docEl = doc.documentElement, 3 | resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize', 4 | recalc = function () { 5 | var clientWidth = docEl.clientWidth; 6 | if (!clientWidth) return; 7 | docEl.style.fontSize = 20 * (clientWidth / 375) + 'px'; // 放下16个字 8 | }; 9 | if (!doc.addEventListener) return; 10 | win.addEventListener(resizeEvt, recalc, false); 11 | doc.addEventListener('DOMContentLoaded', recalc, false); 12 | })(document, window); -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/components/footer/footer.vue: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 16 | 17 | -------------------------------------------------------------------------------- /vue3NeteaseCloud/src/tools/sessionStore.js: -------------------------------------------------------------------------------- 1 | const sessionStore = { 2 | get(key) { 3 | try{ 4 | let res = sessionStorage.getItem(key); 5 | if(res == null) { 6 | return {}; 7 | }else { 8 | res = JSON.parse(res); 9 | return res; 10 | } 11 | }catch(e) { 12 | return {}; 13 | } 14 | }, 15 | set(key, val) { 16 | sessionStorage.setItem(key, JSON.stringify(val)); 17 | }, 18 | remove(key) { 19 | sessionStorage.removeItem(key); 20 | }, 21 | clear() { 22 | sessionStorage.clear(); 23 | } 24 | } 25 | 26 | export default sessionStore; -------------------------------------------------------------------------------- /vue3NeteaseCloud/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 | 7 | 8 |this is common
4 |componentVal: {{value}}
6 | 7 |{{ item.artistName }}
12 |6 | {{ song }} 7 |
8 |9 | {{ info }} 10 |
11 |
6 | {{item.updateFrequency}}
7 |{{item.name}}
9 |
7 | {{item.updateFrequency}}
8 |{{i+1}}. {{trackFormat(items)}}
12 |{{ item.name }}
12 |{{ item.name }}
12 |
14 |
15 | {{sortDetails.creator}}
16 |
15 |
16 | {{ item.name }}
21 |点击加载更多
24 |
25 |
5 | {{ item.txt }} 6 |
7 |8 | {{ item.txt }} 9 |
10 |
19 |
20 | {{ obj.name }} {{ obj.alias.length > 0?'(' + obj.alias[0] + ')':'' }}
21 |
13 |
14 | {{sortDetails.creator}}
15 |
15 |
16 | {{ item.name }}
21 |点击加载更多
24 |
25 |
14 |
15 | {{ album.artist&&album.artist.name }}
16 |
41 | {{ item.name }} 42 |
43 |44 | {{ albumAndSinger(item.al, item.ar) }} 45 |
46 |45 | {{ item.name }} 46 |
47 |48 | {{ name }} 49 |
50 |
69 | {{timeFormat(item.publishTime)}} {{item.size}}首
72 |95 | {{ item.name }} 96 |
97 |加载更多
101 |
102 |
110 | {{ descOfSinger.briefDesc }} 111 |
112 |{{ item.txt }}
116 | 117 |