炒冷饭,源自本站Blog修改记录

调整 Aplayer 收回方式、隐藏歌词和美化

毛玻璃、夜间模式美化(2025/8/13)

参考hexo博客butterfly主题aplyer音乐播放器美化与深色模式
效果本站播放器。大佬的样式,豪康(好看)!

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
/*aplayer日间模式调整*/
/*背景色*/
.aplayer{
background: rgba(255, 255, 255, 0.60)!important;
box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.07),0 1px 5px 0 rgba(0,0,0,.1);
position: relative;
}
.aplayer.aplayer-fixed .aplayer-lrc:after,.aplayer.aplayer-fixed .aplayer-lrc:before {
display: none
}
.aplayer.aplayer.aplayer-fixed .aplayer-body{
background:rgba(255, 255, 255, 0.60)!important;
box-shadow: 0 2px 2px 0 rgba(0,0,0,.07),0 1px 5px 0 rgba(0,0,0,.1);
position: fixed;
}
/*毛玻璃效果*/
.aplayer-list{
backdrop-filter: blur(3px);
}
.aplayer-info{
backdrop-filter: blur(3px);
}
/*滚动条*/
.aplayer .aplayer-list ol::-webkit-scrollbar {
width: 5px
}
.aplayer .aplayer-list ol::-webkit-scrollbar-thumb {
border-radius: 3px;
background-color: #b0e1ff
}
.aplayer .aplayer-list ol::-webkit-scrollbar-thumb:hover {
background-color: #b0e1ff
}
/*圆角*/
.aplayer.aplayer-fixed .aplayer-list{
border-radius: 6px 6px 0 0!important;
}
.aplayer.aplayer-fixed .aplayer-miniswitcher{
border-radius: 0 6px 6px 0!important;
}
.aplayer.aplayer-fixed.aplayer-narrow .aplayer-body{
border-radius: 6px!important;
}
.aplayer-body{
border-radius:0 6px 6px 0!important;
}
.aplayer.no-destroy.no-reload.aplayer-withlist.aplayer-fixed{
border-radius:6px 6px 0 0!important;
}
/*选中与播放中歌曲激活颜色*/
.aplayer .aplayer-list ol li:hover{
background: #b0e1ff!important;
}
.aplayer .aplayer-list ol li.aplayer-list-light{
background: #ffdffa!important;
}
/*aplayer黑暗模式*/
[data-theme=dark]
.aplayer{
background: rgba(22, 22, 22, 0.60)!important;
color: rgb(255, 255, 255);
box-shadow: 0 2px 2px 0 rgba(0,0,0,.07),0 1px 5px 0 rgba(0,0,0,.1);
}
[data-theme=dark]
.aplayer.aplayer-fixed .aplayer-body{
background: rgba(22, 22, 22, 0.60)!important;
color: rgb(255, 255, 255);
box-shadow: 0 2px 2px 0 rgba(0,0,0,.07),0 1px 5px 0 rgba(0,0,0,.1);
}
[data-theme=dark]
.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon path{
fill: #d4d4d4;
}
[data-theme=dark]
.aplayer .aplayer-list ol li:hover{
background: #407290!important;
}
[data-theme=dark]
.aplayer .aplayer-list ol li.aplayer-list-light{
background: #9c8098!important;
}
[data-theme=dark]
.aplayer .aplayer-info .aplayer-controller .aplayer-time{
color: #d4d4d4;
}
[data-theme=dark]
.aplayer .aplayer-list ol li .aplayer-list-index{
color: #d4d4d4;
}
[data-theme=dark]
.aplayer .aplayer-list ol li .aplayer-list-author{
color: #d4d4d4;
}

Aplayer 收回方式

调整 Aplayer 收回方式及隐藏歌词

参考并添加了一点小动画:

1
2
3
4
5
6
7
8
.aplayer.aplayer-fixed.aplayer-narrow .aplayer-body{
left:-66px!important;
transition-delay: 2s;
}/*隐藏播放器*/
.aplayer.aplayer-fixed.aplayer-narrow .aplayer-body:hover{
left:0!important;
transition-delay: 0s;
}

隐藏歌词

歌词默认显示,在_config.butterfly.yml替换CDN模拟点击关闭歌词。
例如:

1
2
3
4
5
bottom:
aplayer_css: https://lf6-cdn-tos.bytecdntp.com/cdn/expire-1-M/aplayer/1.10.1/APlayer.min.css
aplayer_js: https://lf6-cdn-tos.bytecdntp.com/cdn/expire-1-M/aplayer/1.10.1/APlayer.min.js
+ meting_js: https://cdn.akioi.eu.org/meting.min.js
- meting_js: https://cdn1.tianli0.top/npm/js-heo@1.0.12/metingjs/Meting.min.js