v2.1更新

This commit is contained in:
2026-05-26 13:47:01 +08:00
parent c575d711ee
commit f84c9d3efb
26 changed files with 1482 additions and 567 deletions

View File

@@ -32,12 +32,12 @@ include __DIR__ . '/../includes/header.php';
<div class="container">
<!-- 科目管理折叠面板 -->
<div class="card" style="margin-bottom: 20px;">
<div class="collapsible-header" onclick="toggleSubjectPanel()" style="cursor: pointer; display: flex; justify-content: space-between; align-items: center; padding: 15px 20px;">
<div class="card collapsible-card" style="margin-bottom: 20px;">
<div class="collapsible-header" id="subjectPanelHeader">
<h3 style="margin: 0; font-size: 16px;">📚 科目管理</h3>
<span id="subjectPanelToggle" class="toggle-icon">▶ 展开</span>
</div>
<div id="subjectPanelContent" style="display: none; padding: 0 20px 20px;">
<div id="subjectPanelContent" class="collapsible-content">
<div class="action-bar">
<button class="btn btn-primary" onclick="showAddSubjectModal()">添加科目</button>
</div>
@@ -92,9 +92,6 @@ include __DIR__ . '/../includes/header.php';
<div class="deduction-types">
<button type="button" class="btn btn-sm" onclick="selectDeductionType(-window.DEDUCTION_HOMEWORK_NOT_SUBMIT, '未交作业')">未交作业(-<span class="hw-not-submit"></span>分)</button>
<button type="button" class="btn btn-sm" onclick="selectDeductionType(-window.DEDUCTION_HOMEWORK_LATE, '迟交作业')">迟交作业(-<span class="hw-late"></span>分)</button>
<button type="button" class="btn btn-sm" onclick="selectDeductionType(null, '卫生')">卫生</button>
<button type="button" class="btn btn-sm" onclick="selectDeductionType(null, '课堂')">课堂</button>
<button type="button" class="btn btn-sm" onclick="selectDeductionType(null, '纪律')">纪律</button>
<button type="button" class="btn btn-sm" onclick="selectDeductionType(0, '')">自定义</button>
</div>
</div>
@@ -189,7 +186,7 @@ include __DIR__ . '/../includes/header.php';
gap: 12px;
}
.subject-item {
background: #f8f9fa;
background: var(--color-hover);
padding: 12px 20px;
border-radius: 8px;
display: flex;
@@ -201,7 +198,7 @@ include __DIR__ . '/../includes/header.php';
font-size: 16px;
}
.subject-code {
color: #999;
color: var(--color-text-muted);
font-size: 12px;
}
.subject-status {
@@ -217,22 +214,36 @@ include __DIR__ . '/../includes/header.php';
background: #fed7d7;
color: #742a2a;
}
.collapsible-header {
.collapsible-card .collapsible-header {
cursor: pointer;
display: flex;
justify-content: space-between;
align-items: center;
padding: 15px 20px;
user-select: none;
transition: background 0.2s;
border-radius: 12px;
}
.collapsible-header:hover {
background: #f8f9fa;
.collapsible-card .collapsible-header:hover {
background: var(--color-hover, #f7fafc);
}
.collapsible-card .collapsible-content {
max-height: 0;
overflow: hidden;
transition: max-height 0.3s ease-out, padding 0.3s ease-out;
padding: 0 20px;
}
.collapsible-card .collapsible-content.expanded {
max-height: 1000px;
padding: 0 20px 20px;
}
.toggle-icon {
font-size: 12px;
color: #666;
color: var(--color-text-secondary, #666);
transition: transform 0.3s;
}
.btn-danger {
background: #e53e3e;
color: white;
}
.btn-danger:hover {
background: #c53030;
.toggle-icon.expanded {
transform: rotate(90deg);
}
</style>