js实现在线视频时间轴轨道剪辑代码
代码语言:html
所属分类:其他
代码由minimax-v3 ai生成,可能有错误,仅供参考:点击查看提示词
代码描述:web在线视频剪辑软件(类似剪映)
下面为部分代码预览,完整代码请点击下载或在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>MiniMax Clip · 在线视频剪辑工具</title>
<style>
* { box-sizing: border-box; margin: 0; padding: 0; }
:root {
--bg: #0f1115;
--panel: #1a1d24;
--panel-2: #232732;
--line: #2a2f3a;
--text: #e6e8ee;
--text-2: #9aa3b2;
--accent: #4f7cff;
--accent-2: #7aa0ff;
--danger: #ff5b5b;
--warn: #ffb84d;
--ok: #4ad17b;
--video: #4f7cff;
--audio: #4ad17b;
--text-track: #ffb84d;
--image: #c47bff;
}
html, body { height: 100%; }
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
"Hiragino Sans GB", "Microsoft YaHei", sans-serif;
background: var(--bg);
color: var(--text);
overflow: hidden;
user-select: none;
}
/* 顶部工具栏 */
header.topbar {
height: 48px;
background: var(--panel);
border-bottom: 1px solid var(--line);
display: flex;
align-items: center;
padding: 0 14px;
gap: 10px;
}
.logo {
font-weight: 700;
font-size: 15px;
letter-spacing: 0.4px;
background: linear-gradient(90deg, #4f7cff, #c47bff);
-webkit-background-clip: text;
background-clip: text;
color: transparent;
margin-right: 8px;
}
.btn {
background: var(--panel-2);
border: 1px solid var(--line);
color: var(--text);
padding: 6px 12px;
border-radius: 6px;
cursor: pointer;
font-size: 13px;
display: inline-flex;
align-items: center;
gap: 6px;
transition: all 0.15s;
}
.btn:hover { background: #2c3140; border-color: #3a4150; }
.btn.primary { background: var(--accent); border-color: var(--accent); }
.btn.primary:hover { background: var(--accent-2); border-color: var(--accent-2); }
.btn.danger { background: var(--danger); border-color: var(--danger); }
.btn.danger:hover { background: #ff7070; }
.btn.ghost { background: transparent; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.btn svg { width: 14px; height: 14px; }
.spacer { flex: 1; }
.time-readout {
font-variant-numeric: tabular-nums;
font-size: 13px;
color: var(--text-2);
background: var(--panel-2);
padding: 5px 10px;
border-radius: 6px;
border: 1px solid var(--line);
}
.time-readout b { color: var(--text); }
/* 主体三栏 */
.main {
display: grid;
grid-template-columns: 240px 1fr;
height: calc(100% - 48px);
}
/* 素材管理区 */
aside.media-panel {
background: var(--panel);
border-right: 1px solid var(--line);
display: flex;
flex-direction: column;
overflow: hidden;
}
.panel-title {
padding: 10px 14px;
font-size: 12px;
color: var(--text-2);
text-transform: uppercase;
letter-spacing: 0.8px;
border-bottom: 1px solid var(--line);
display: flex;
align-items: center;
justify-content: space-between;
}
.media-list {
flex: 1;
overflow-y: auto;
padding: 8px;
}
.media-item {
background: var(--panel-2);
border: 1px solid var(--line);
border-radius: 6px;
padding: 8px;
margin-bottom: 8px;
cursor: grab;
display: flex;
gap: 8px;
align-items: center;
transition: all 0.15s;
}
.media-item:hover { border-color: var(--accent); background: #262b38; }
.media-item:active { cursor: grabbing; }
.media-thumb {
width: 56px;
height: 36px;
background: #000;
border-radius: 4px;
flex-shrink: 0;
object-fit: cover;
display: flex;
align-items: center;
justify-content: center;
color: var(--text-2);
font-size: 10px;
overflow: hidden;
}
.media-thumb img, .media-thumb video { width: 100%; height: 100%; object-fit: cover; }
.media-info { flex: 1; min-width: 0; }
.media-name {
font-size: 12px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.media-meta {
font-size: 10px;
color: var(--text-2);
margin-top: 2px;
}
.tag {
display: inline-block;
font-size: 9px;
padding: 1px 5px;
border-radius: 3px;
background: var(--line);
color: var(--text-2);
margin-right: 4px;
text-transform: uppercase;
}
.tag.video { background: rgba(79,124,255,0.2); color: var(--video); }
.tag.audio { background: rgba(74,209,123,0.2); color: var(--audio); }
.tag.image { background: rgba(196,123,255,0.2); color: var(--image); }
.empty-hint {
text-align: center;
color: var(--text-2);
font-size: 12px;
padding: 30px 14px;
line-height: 1.7;
}
.empty-hint svg { width: 36px; height: 36px; opacity: 0.4; margin-bottom: 8px; }
/* 预览区 */
section.preview-area {
display: flex;
flex-direction: column;
overflow: hidden;
}
.preview-toolbar {
height: 40px;
background: var(--panel);
border-bottom: 1px solid var(--line);
display: flex;
align-items: center;
padding: 0 12px;
gap: 6px;
}
.play-btn {
width: 32px;
height:.........完整代码请登录后点击上方下载按钮下载查看















网友评论0