""" BreakPilot Studio - Notenbuch (Gradebook) Modul Funktionen: - Notenübersicht pro Klasse/Schüler - Noteneingabe für verschiedene Prüfungsarten - Durchschnittsberechnung - Trend-Analyse - Export nach Excel/PDF - Integration mit Zeugnissen """ class GradebookModule: """Modul fuer digitale Notenverwaltung.""" @staticmethod def get_css() -> str: """CSS fuer das Gradebook-Modul.""" return """ /* ============================================= GRADEBOOK MODULE - Notenbuch ============================================= */ /* Panel Layout */ .panel-gradebook { display: none; flex-direction: column; height: 100%; background: var(--bp-bg); overflow: hidden; } .panel-gradebook.active { display: flex; } /* Header */ .gradebook-header { display: flex; justify-content: space-between; align-items: center; padding: 20px 32px; border-bottom: 1px solid var(--bp-border); background: var(--bp-surface); } .gradebook-title-section h1 { font-size: 24px; font-weight: 700; color: var(--bp-text); margin-bottom: 4px; } .gradebook-subtitle { font-size: 14px; color: var(--bp-text-muted); } .gradebook-actions { display: flex; gap: 12px; } /* Filter Bar */ .gradebook-filters { display: flex; gap: 16px; padding: 16px 32px; background: var(--bp-surface-elevated); border-bottom: 1px solid var(--bp-border); flex-wrap: wrap; align-items: center; } .filter-group { display: flex; flex-direction: column; gap: 4px; } .filter-group label { font-size: 12px; color: var(--bp-text-muted); font-weight: 500; } .filter-group select, .filter-group input { padding: 8px 12px; border: 1px solid var(--bp-border); border-radius: 8px; background: var(--bp-surface); color: var(--bp-text); font-size: 13px; min-width: 150px; } .filter-group select:focus, .filter-group input:focus { outline: none; border-color: var(--bp-primary); } /* Content Layout */ .gradebook-content { flex: 1; overflow: auto; padding: 24px 32px; } /* Grade Table */ .gradebook-table-container { background: var(--bp-surface); border-radius: 12px; border: 1px solid var(--bp-border); overflow: hidden; } .gradebook-table { width: 100%; border-collapse: collapse; font-size: 13px; } .gradebook-table thead { background: var(--bp-surface-elevated); position: sticky; top: 0; z-index: 10; } .gradebook-table th { padding: 12px 16px; text-align: left; font-weight: 600; color: var(--bp-text); border-bottom: 2px solid var(--bp-border); white-space: nowrap; } .gradebook-table th.grade-column { text-align: center; min-width: 80px; } .gradebook-table th.average-column { text-align: center; background: var(--bp-primary-soft); } .gradebook-table tbody tr { border-bottom: 1px solid var(--bp-border); transition: background 0.2s; } .gradebook-table tbody tr:hover { background: var(--bp-surface-elevated); } .gradebook-table td { padding: 12px 16px; color: var(--bp-text); } .gradebook-table td.grade-cell { text-align: center; } .gradebook-table td.average-cell { text-align: center; font-weight: 600; background: var(--bp-primary-soft); } /* Student Name Column */ .student-name { display: flex; align-items: center; gap: 12px; } .student-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--bp-primary); color: white; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; } .student-info { display: flex; flex-direction: column; } .student-info .name { font-weight: 500; } .student-info .class { font-size: 11px; color: var(--bp-text-muted); } /* Grade Input */ .grade-input { width: 50px; padding: 6px 8px; border: 1px solid transparent; border-radius: 6px; background: var(--bp-surface); color: var(--bp-text); text-align: center; font-size: 14px; font-weight: 500; transition: all 0.2s; } .grade-input:hover { border-color: var(--bp-border); } .grade-input:focus { outline: none; border-color: var(--bp-primary); background: var(--bp-surface-elevated); } /* Grade Colors */ .grade-1 { color: #22c55e; } .grade-2 { color: #84cc16; } .grade-3 { color: #eab308; } .grade-4 { color: #f97316; } .grade-5 { color: #ef4444; } .grade-6 { color: #dc2626; } .grade-badge { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 8px; font-weight: 600; font-size: 14px; } .grade-badge.grade-1 { background: rgba(34, 197, 94, 0.15); } .grade-badge.grade-2 { background: rgba(132, 204, 22, 0.15); } .grade-badge.grade-3 { background: rgba(234, 179, 8, 0.15); } .grade-badge.grade-4 { background: rgba(249, 115, 22, 0.15); } .grade-badge.grade-5 { background: rgba(239, 68, 68, 0.15); } .grade-badge.grade-6 { background: rgba(220, 38, 38, 0.15); } /* Trend Indicator */ .trend-indicator { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; margin-left: 8px; } .trend-up { color: var(--bp-success); } .trend-down { color: var(--bp-danger); } .trend-stable { color: var(--bp-text-muted); } /* Statistics Panel */ .gradebook-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 24px; } .stat-card { background: var(--bp-surface); border: 1px solid var(--bp-border); border-radius: 12px; padding: 20px; } .stat-card .stat-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 20px; margin-bottom: 12px; } .stat-card .stat-icon.blue { background: rgba(59, 130, 246, 0.15); color: #3b82f6; } .stat-card .stat-icon.green { background: rgba(34, 197, 94, 0.15); color: #22c55e; } .stat-card .stat-icon.yellow { background: rgba(234, 179, 8, 0.15); color: #eab308; } .stat-card .stat-icon.red { background: rgba(239, 68, 68, 0.15); color: #ef4444; } .stat-card .stat-value { font-size: 28px; font-weight: 700; color: var(--bp-text); margin-bottom: 4px; } .stat-card .stat-label { font-size: 13px; color: var(--bp-text-muted); } /* Add Grade Modal */ .add-grade-modal { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0, 0, 0, 0.5); display: none; align-items: center; justify-content: center; z-index: 1000; } .add-grade-modal.active { display: flex; } .add-grade-content { background: var(--bp-surface); border-radius: 16px; padding: 24px; width: 100%; max-width: 500px; max-height: 90vh; overflow-y: auto; } .add-grade-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; } .add-grade-header h2 { font-size: 18px; font-weight: 600; } .add-grade-form { display: flex; flex-direction: column; gap: 16px; } .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .form-group { display: flex; flex-direction: column; gap: 6px; } .form-group label { font-size: 13px; font-weight: 500; color: var(--bp-text-muted); } .form-group input, .form-group select, .form-group textarea { padding: 10px 12px; border: 1px solid var(--bp-border); border-radius: 8px; background: var(--bp-surface-elevated); color: var(--bp-text); font-size: 14px; } .form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--bp-primary); } .form-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 8px; } /* Exam Types */ .exam-type-selector { display: flex; gap: 8px; flex-wrap: wrap; } .exam-type-btn { padding: 8px 16px; border: 1px solid var(--bp-border); border-radius: 20px; background: var(--bp-surface); color: var(--bp-text-muted); font-size: 13px; cursor: pointer; transition: all 0.2s; } .exam-type-btn:hover { border-color: var(--bp-primary); color: var(--bp-text); } .exam-type-btn.active { background: var(--bp-primary); border-color: var(--bp-primary); color: white; } /* Chart Container */ .gradebook-chart { background: var(--bp-surface); border: 1px solid var(--bp-border); border-radius: 12px; padding: 20px; margin-bottom: 24px; } .gradebook-chart h3 { font-size: 16px; font-weight: 600; margin-bottom: 16px; } .chart-placeholder { height: 200px; background: var(--bp-surface-elevated); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: var(--bp-text-muted); } /* Responsive */ @media (max-width: 768px) { .gradebook-filters { flex-direction: column; align-items: stretch; } .filter-group { width: 100%; } .filter-group select { width: 100%; } .form-row { grid-template-columns: 1fr; } .gradebook-stats { grid-template-columns: 1fr; } } /* Print Styles */ @media print { .gradebook-header, .gradebook-filters, .gradebook-actions, .add-grade-modal { display: none !important; } .gradebook-content { padding: 0; } .gradebook-table { font-size: 11px; } } """ @staticmethod def get_html() -> str: """HTML fuer das Gradebook-Panel.""" return """
| Schüler/in | Klausur 1 | Test 1 | Klausur 2 | Mündlich | Test 2 | Schnitt | Trend |
|---|