Add unified JSON backup and restore

This commit is contained in:
Codex committed 2026-09-17 13:39:42 +08:00
1 parent 5f4a193888
commit bbdfe97c4e
6 files changed
+79 -2

No files matched your search

+1
View File
@@ -184,3 +184,4 @@ aside{display:grid;gap:14px}.side-calendar{margin:0;padding:18px;border-radius:2
.study-hub{max-width:1160px}.hub-grid{display:grid;grid-template-columns:.9fr 1.1fr;gap:20px;margin-top:22px}.hub-grid.lower{grid-template-columns:1fr 1fr}.hub-card{background:#fff;border:1px solid #d9e6ff;border-radius:22px;padding:24px;box-shadow:0 14px 34px #bfd5fb66}.hub-card h2{margin:5px 0 18px;font-size:1.42rem;letter-spacing:-.025em}.hub-card>p:not(.eyebrow){color:#64748b;line-height:1.65}.plan-card{background:linear-gradient(145deg,#122a61,#2865d9);color:#fff}.plan-card .eyebrow{color:#c9dcff}.plan-card strong{display:block;font-size:3.1rem;line-height:1;margin:18px 0 8px}.plan-card p,.plan-card small{color:#dceaff}.hub-card label{display:grid;gap:8px;margin:13px 0;color:#334155;font-size:.88rem;font-weight:700}.hub-card input,.hub-card textarea{width:100%;box-sizing:border-box;border:1px solid #d5e0f0;background:#fbfdff;border-radius:11px;padding:10px 11px;font:inherit;color:#172554}.hub-card textarea{min-height:88px;resize:vertical}.date-field{max-width:190px}.duration-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:9px}.duration-grid label{font-size:.76rem}.duration-grid input{min-width:0;padding:9px}.score-grid{grid-template-columns:repeat(4,1fr)}.primary-action{display:inline-flex;align-items:center;gap:8px;border:0;border-radius:11px;background:#2563eb;color:#fff;padding:11px 15px;margin-top:8px;font:inherit;font-weight:700;cursor:pointer;box-shadow:0 8px 18px #bfdbfe}.primary-action:hover{background:#1d4ed8}.score-total{float:right;color:#2563eb;font-size:1.85rem}.mock-history{border-top:1px solid #e6edf9;margin-top:19px;padding-top:8px}.mock-history p{display:flex;justify-content:space-between;color:#64748b;font-size:.84rem;margin:10px 0}.mock-history b{color:#334155}
@media(max-width:800px){.hub-grid,.hub-grid.lower{grid-template-columns:1fr}.duration-grid{grid-template-columns:repeat(3,1fr)}.score-grid{grid-template-columns:repeat(4,1fr)}}
@media(max-width:480px){.hub-card{padding:18px}.duration-grid{grid-template-columns:repeat(2,1fr)}.score-grid{grid-template-columns:repeat(2,1fr)}}
.backup-page{max-width:980px}.backup-grid{display:grid;grid-template-columns:1fr 1fr;gap:20px;margin-top:22px}.backup-card{position:relative;overflow:hidden;background:#fff;border:1px solid #d9e6ff;border-radius:22px;padding:27px;box-shadow:0 14px 34px #bfd5fb66}.backup-card h2{margin:12px 0 10px;font-size:1.45rem;letter-spacing:-.025em}.backup-card>p:not(.eyebrow){min-height:54px;margin:0;color:#64748b;line-height:1.65}.export-card{background:linear-gradient(145deg,#122a61,#2865d9);border-color:#1d4ed8;color:#fff}.export-card .eyebrow{color:#c9dcff}.export-card>p:not(.eyebrow){color:#dceaff}.backup-icon{display:inline-flex;align-items:center;justify-content:center;width:50px;height:50px;border-radius:15px;background:#e8f1ff;color:#2563eb}.export-card .backup-icon{background:#ffffff22;color:#fff}.backup-action{display:inline-flex;align-items:center;gap:8px;margin-top:24px;border:0;border-radius:12px;background:#2563eb;color:#fff;padding:12px 15px;font:inherit;font-weight:800;cursor:pointer;box-shadow:0 9px 18px #bfdbfe;transition:.16s transform,.16s background}.backup-action:hover:not(:disabled){background:#1d4ed8;transform:translateY(-1px)}.export-card .backup-action{background:#fff;color:#1d4ed8;box-shadow:0 9px 18px #102b6355}.backup-action.outline{background:#edf5ff;color:#1d4ed8}.backup-action:disabled{opacity:.6;cursor:wait}.file-input{display:none}.backup-note{display:flex;gap:11px;align-items:flex-start;margin-top:20px;padding:17px 19px;border:1px solid #d9e6ff;border-radius:16px;background:#f8fbff;color:#64748b;line-height:1.6}.backup-note svg{flex:none;color:#2563eb;margin-top:2px}.backup-note p{margin:0}.backup-note b{color:#334155}@media(max-width:800px){.backup-grid{grid-template-columns:1fr}}