js+css实现选择本地音乐实时麦克风跟唱k歌评分代码
代码语言:html
所属分类:多媒体
代码描述:js+css实现选择本地音乐实时麦克风跟唱k歌评分代码
代码标签: js css 选择 本地 音乐 实时 麦克风 跟唱 k歌 评分 代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>🎤 K歌评分系统</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background: linear-gradient(135deg, #0c0015, #1a0033, #0d001a);
color: #fff;
min-height: 100vh;
overflow-x: hidden;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 20px;
}
h1 {
text-align: center;
font-size: 2.5em;
background: linear-gradient(90deg, #ff6ec7, #7b68ee, #00bfff);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
margin-bottom: 30px;
text-shadow: 0 0 30px rgba(123, 104, 238, 0.3);
}
.controls {
display: flex;
flex-wrap: wrap;
gap: 15px;
justify-content: center;
margin-bottom: 30px;
padding: 20px;
background: rgba(255, 255, 255, 0.05);
border-radius: 15px;
border: 1px solid rgba(255, 255, 255, 0.1);
}
.btn {
padding: 12px 24px;
border: none;
border-radius: 25px;
font-size: 16px;
font-weight: bold;
cursor: pointer;
transition: all 0.3s ease;
display: flex;
align-items: center;
gap: 8px;
}
.btn:disabled {
opacity: 0.4;
cursor: not-allowed;
}
.btn-primary {
background: linear-gradient(135deg, #7b68ee, #5b4bdf);
color: white;
box-shadow: 0 4px 15px rgba(123, 104, 238, 0.4);
}
.btn-primary:hover:not(:disabled) {
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(123, 104, 238, 0.6);
}
.btn-success {
background: linear-gradient(135deg, #00c851, #007e33);
color: white;
box-shadow: 0 4px 15px rgba(0, 200, 81, 0.4);
}
.btn-success:hover:not(:disabled) {
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(0, 200, 81, 0.6);
}
.btn-danger {
background: linear-gradient(135deg, #ff4444, #cc0000);
color: white;
box-shadow: 0 4px 15px rgba(255, 68, 68, 0.4);
}
.btn-danger:hover:not(:disabled) {
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(255, 68, 68, 0.6);
}
.btn-warning {
background: linear-gradient(135deg, #ffbb33, #ff8800);
color: white;
box-shadow: 0 4px 15px rgba(255, 187, 51, 0.4);
}
.btn-warning:hover:not(:disabled) {
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(255, 187, 51, 0.6);
}
.file-input-wrapper {
position: relative;
}
.file-input-wrapper input[type="file"] {
position: absolute;
width: 100%;
height: 100%;
opacity: 0;
cursor: pointer;
top: 0;
left: 0;
}
.status-bar {
display: flex;
justify-content: space-between;
align-items: center;
padding: 15px 20px;
background: rgba(255, 255, 255, 0.05);
border-radius: 10px;
margin-bottom: 20px;
border: 1px solid rgba(255, 255, 255, 0.1);
flex-wrap: wrap;
gap: 10px;
}
.status-item {
display: flex;
align-items: center;
gap: 8px;
}
.status-dot {
width: 10px;
height: 10px;
border-radius: 50%;
background: #666;
}
.status-dot.active {
background: #00ff88;
box-shadow: 0 0 10px #00ff88;
animation: pulse 1.5s infinite;
}
.status-dot.recording {
background: #ff4444;
box-shadow: 0 0 10px #ff4444;
animation: pulse 0.8s infinite;
}
@keyframes pulse {
0%, 100% { opacity: 1; }
50% .........完整代码请登录后点击上方下载按钮下载查看
















网友评论0