diff --git a/README.md b/README.md index 2af8df4..a35a46f 100644 --- a/README.md +++ b/README.md @@ -12,8 +12,8 @@ - [x] 日期及时间 - [x] 天气信息 - [x] 时光进度条 +- [x] 音乐插件 -* [ ] 音乐插件 * [ ] 没想好 ### 插件 @@ -23,6 +23,7 @@ * [Iconfont](https://www.iconfont.cn/) * [Font Awesome](https://fontawesome.com/) * [jQuery](https://jquery.com/) +* [Aplayer](https://aplayer.js.org/) ### API diff --git a/css/font.css b/css/font.css index 76c35d3..e96386c 100644 --- a/css/font.css +++ b/css/font.css @@ -16,9 +16,9 @@ @font-face { font-family: "iconfont"; /* Project id 2831425 */ - src: url('//at.alicdn.com/t/font_2831425_312vsfjkcz9.woff2?t=1642345600138') format('woff2'), - url('//at.alicdn.com/t/font_2831425_312vsfjkcz9.woff?t=1642345600138') format('woff'), - url('//at.alicdn.com/t/font_2831425_312vsfjkcz9.ttf?t=1642345600138') format('truetype'); + src: url('../font/font_2831425_312vsfjkcz9.woff') format('woff2'), + url('../font/font_2831425_312vsfjkcz9.woff') format('woff'), + url('../font/font_2831425_312vsfjkcz9.ttf') format('truetype'); } .iconfont { diff --git a/css/mobile.css b/css/mobile.css index be5a9bf..328345b 100644 --- a/css/mobile.css +++ b/css/mobile.css @@ -17,6 +17,11 @@ .weekday { display: none; } + + /*音乐播放器*/ + .music-text { + max-width: 170px !important; + } } /*小于992px时*/ @@ -135,13 +140,24 @@ /*链接卡片*/ .link-card { + height: 80px !important; align-items: center !important; flex-direction: column !important; justify-content: center !important; } + .link-card i { + font-size: 1.75rem; + } + span.link-name { display: block !important; + font-size: 1.05rem; + } + + span.line-text, + i.iconfont.icon-link { + font-size: 1.20rem; } /*菜单栏按钮*/ @@ -171,6 +187,16 @@ font-size: 0.85rem; } + /*音乐播放器*/ + .music-text { + max-width: 100% !important; + } + + /*隐藏鼠标样式*/ + #cursor { + background: transparent !important; + } + } /*小于390px时*/ diff --git a/css/style.css b/css/style.css index 586f26a..4ab9426 100644 --- a/css/style.css +++ b/css/style.css @@ -49,6 +49,7 @@ section { position: fixed; width: 100%; height: 100%; + min-height: 600px; } main { @@ -203,10 +204,10 @@ i.iconfont.icon-yinhao-copy { font-size: 1.10rem; } -.close-music { +.open-music { display: none; justify-content: center; - background: rgb(0 0 0 / 25%); + background: rgb(0 0 0 / 15%); padding: 4px 0px; animation: fade; -webkit-animation: fade 0.5s; @@ -215,6 +216,97 @@ i.iconfont.icon-yinhao-copy { -ms-animation: fade 0.5s; } +.open-music:hover { + background: rgb(0 0 0 / 30%); +} + +/*音乐播放器卡片*/ +#music { + display: none; +} + +.music { + width: 100%; + background: rgb(0 0 0 / 25%); + backdrop-filter: blur(10px); + padding: 20px; + border-radius: 6px; + height: 165px; + display: flex; + justify-content: center; + flex-direction: column; + animation: fade; + -webkit-animation: fade 0.3s; + -moz-animation: fade 0.3s; + -o-animation: fade 0.3s; + -ms-animation: fade 0.3s; +} + +.music-all { + display: flex; + flex-direction: column; + align-items: center; + justify-content: space-around; + height: 100%; +} + +.music-button { + display: flex; + align-items: center; + margin-bottom: 6px; +} + +.music-control { + display: flex; + flex-direction: row; + align-items: center; + justify-content: space-evenly; + width: 100%; +} + +i.iconfont.icon-play, +i.iconfont.icon-pause { + font-size: 2.25rem; + padding: 6px; + border-radius: 6px; +} + +i.iconfont.icon-play:hover, +i.iconfont.icon-pause:hover { + background: rgb(255 255 255 / 20%); + padding: 6px; + border-radius: 6px; +} + +i#last, +i#next { + font-size: 2.0rem; +} + +.music-text { + font-size: 1.15rem; + text-overflow: ellipsis; + max-width: 200px; + overflow-x: hidden; + white-space: nowrap; +} + +#music-open, +#music-close { + background: rgb(255 255 255 / 15%); + padding: 2px 8px; + border-radius: 6px; + margin: 0px 6px; + text-overflow: ellipsis; + overflow-x: hidden; + white-space: nowrap; +} + +#music-open:hover, +#music-close:hover { + background: rgb(255 255 255 / 30%); +} + /*时间卡片*/ .time { width: 100%; @@ -416,7 +508,8 @@ span.link-name { transform: scale(1.2); } -i.iconfont.icon-close { +i.iconfont.icon-close, +i.iconfont.icon-github1 { font-size: 1.45rem; } @@ -502,68 +595,6 @@ span.aplayer-list-index { /*Aplayer结束*/ -/*音乐播放器*/ -#music { - display: none; -} - -.music { - width: 100%; - background: rgb(0 0 0 / 25%); - backdrop-filter: blur(10px); - padding: 20px; - border-radius: 6px; - height: 165px; - display: flex; - justify-content: center; - flex-direction: column; -} - -.music-all { - display: flex; - flex-direction: column; - align-items: center; - justify-content: space-around; - height: 100%; -} - -.music-button { - display: flex; - align-items: center; -} - -.music-control { - display: flex; - flex-direction: row; - align-items: center; - justify-content: space-evenly; - width: 100%; -} - -i.iconfont.icon-play, -i.iconfont.icon-pause { - font-size: 2.25rem; -} - -i#last, -i#next { - font-size: 2.0rem; -} - -.music-text { - font-size: 1.15rem; - text-overflow: ellipsis; - max-width: 160px; -} - -#music-open, -#music-close { - background: rgb(255 255 255 / 20%); - padding: 2px 8px; - border-radius: 6px; - margin: 0px 6px; -} - /*移动端页面切换按钮*/ i.iconfont.icon-bars, i.iconfont.icon-times { @@ -589,6 +620,10 @@ footer { backdrop-filter: blur(10px) !important; } +.iziToast>.iziToast-body .iziToast-title { + font-size: 16px !important; +} + .iziToast-body .iziToast-message { line-height: 18px !important; } diff --git a/font/font_2831425_ekwvaabvo8l.ttf b/font/font_2831425_312vsfjkcz9.ttf similarity index 69% rename from font/font_2831425_ekwvaabvo8l.ttf rename to font/font_2831425_312vsfjkcz9.ttf index 5278118..e43c1b5 100644 Binary files a/font/font_2831425_ekwvaabvo8l.ttf and b/font/font_2831425_312vsfjkcz9.ttf differ diff --git a/font/font_2831425_312vsfjkcz9.woff b/font/font_2831425_312vsfjkcz9.woff new file mode 100644 index 0000000..e6aefff Binary files /dev/null and b/font/font_2831425_312vsfjkcz9.woff differ diff --git a/font/font_2831425_312vsfjkcz9.woff2 b/font/font_2831425_312vsfjkcz9.woff2 new file mode 100644 index 0000000..10c555d Binary files /dev/null and b/font/font_2831425_312vsfjkcz9.woff2 differ diff --git a/font/font_2831425_ekwvaabvo8l.woff b/font/font_2831425_ekwvaabvo8l.woff deleted file mode 100644 index d5f77e4..0000000 Binary files a/font/font_2831425_ekwvaabvo8l.woff and /dev/null differ diff --git a/font/font_2831425_ekwvaabvo8l.woff2 b/font/font_2831425_ekwvaabvo8l.woff2 deleted file mode 100644 index 05c21c8..0000000 Binary files a/font/font_2831425_ekwvaabvo8l.woff2 and /dev/null differ diff --git a/index.html b/index.html index a820270..a5b7f40 100644 --- a/index.html +++ b/index.html @@ -127,7 +127,7 @@