echarts模拟股票交易系统代码
代码语言:html
所属分类:其他
代码描述:模拟股票交易系统
下面为部分代码预览,完整代码请点击下载或在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>专业股票交易模拟器 (ECharts)</title>
<!-- 引入 ECharts -->
<script src="https://cdn.jsdelivr.net/npm/echarts@5.4.3/dist/echarts.min.js"></script>
<style>
:root {
--bg-color: #121212;
--panel-bg: #1e1e1e;
--text-color: #e0e0e0;
--accent-color: #2962ff;
--up-color: #ef232a; /* A股习惯:红涨 */
--down-color: #14b143; /* A股习惯:绿跌 */
--border-color: #333;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
background-color: var(--bg-color);
color: var(--text-color);
height: 100vh;
display: flex;
overflow: hidden;
}
/* 左侧图表区 */
.chart-container {
flex: 1;
display: flex;
flex-direction: column;
border-right: 1px solid var(--border-color);
}
#main-chart {
width: 100%;
height: 100%;
}
/* 右侧控制面板 */
.sidebar {
width: 320px;
background-color: var(--panel-bg);
display: flex;
flex-direction: column;
padding: 20px;
gap: 20px;
overflow-y: auto;
}
.panel {
background-color: rgba(255, 255, 255, 0.03);
border: 1px solid var(--border-color);
border-radius: 8px;
padding: 15px;
}
.panel h3 {
font-size: 14px;
color: #888;
margin-bottom: 12px;
text-transform: uppercase;
letter-spacing: 1px;
}
.stat-row {
display: flex;
justify-content: space-between;
margin-bottom: 8px;
font-size: 15px;
}
.stat-value {
font-weight: bold;
font-family: 'Courier New', monospace;
}
.price-display {
font-size: 28px;
font-weight: bold;
text-align: center;
margin: 10px 0;
font-family: 'Courier New', monospace;
}
.trade-controls {
display: flex;
flex-direction: column;
.........完整代码请登录后点击上方下载按钮下载查看















网友评论0