refactor(css): maximize usage of variables (1st part, to simplify CSS & style)

note: there is still work to do, but has there are risks to conflict I prefer to commit this first part now
This commit is contained in:
Edouard Vanbelle
2026-04-08 11:03:20 +02:00
parent 904aca5edf
commit 94b36e41e0
35 changed files with 2957 additions and 2535 deletions
+23 -65
View File
@@ -3,19 +3,19 @@
/* ── Empty state icons (large, muted) ── */
.empty-state-icon {
font-size: 48px;
color: #ddd;
color: var(--color-border-ddd);
margin-bottom: 16px;
}
.empty-state-icon.error {
color: #f44336;
color: var(--color-trash-delete);
}
.empty-state-icon.spinner {
color: #666;
color: var(--color-text-medium);
}
/* ── Dialog header icons (accent color) ── */
.dialog-header-icon {
color: #ff5e3a;
color: var(--color-accent);
}
/* ── Icon spacing ── */
@@ -29,13 +29,13 @@
/* ── Success check icon ── */
.check-icon {
color: #48bb78;
color: var(--color-success-border);
}
/* ── Move dialog ── */
.move-dialog-hint {
margin: 0 0 12px;
color: #718096;
color: var(--color-text-muted);
font-size: 14px;
}
.folder-select-container {
@@ -55,13 +55,13 @@
/* ── Search empty state text ── */
.search-empty-text {
color: var(--text-secondary, #64748b);
color: var(--text-secondary, var(--color-text-subtle));
}
/* ── Notification upload current file ── */
.notif-upload-current {
font-size: 11px;
color: #64748b;
color: var(--color-text-subtle);
margin: 3px 0;
white-space: nowrap;
overflow: hidden;
@@ -70,7 +70,7 @@
/* ── Login auth hint ── */
.auth-hint {
color: var(--text-secondary, #666);
color: var(--text-secondary, var(--color-text-medium));
margin-top: 4px;
display: block;
}
@@ -87,8 +87,8 @@
width: 64px;
height: 64px;
border-radius: 50%;
background: linear-gradient(135deg, #3b82f6, #6366f1);
color: #fff;
background: var(--color-avatar-gradient);
color: var(--color-danger-text);
display: inline-flex;
align-items: center;
justify-content: center;
@@ -99,12 +99,12 @@
.about-modal-username {
margin: 0;
font-size: 18px;
color: #1a1a2e;
color: var(--color-text-navy);
}
.about-modal-email {
margin: 4px 0 0;
font-size: 13px;
color: #64748b;
color: var(--color-text-subtle);
}
.about-modal-role {
display: inline-block;
@@ -115,19 +115,19 @@
font-weight: 600;
}
.about-modal-role-admin {
background: #dbeafe;
color: #1d4ed8;
background: var(--color-role-admin-bg);
color: var(--color-role-admin-text);
}
.about-modal-role-user {
background: #f1f5f9;
color: #64748b;
background: var(--color-border-light);
color: var(--color-text-subtle);
}
.about-modal-storage {
padding: 16px 20px;
}
.about-modal-storage-label {
font-size: 12px;
color: #64748b;
color: var(--color-text-subtle);
text-transform: uppercase;
letter-spacing: 0.05em;
margin-bottom: 6px;
@@ -136,7 +136,7 @@
margin-right: 4px;
}
.about-modal-bar-bg {
background: #f1f5f9;
background: var(--color-border-light);
border-radius: 6px;
height: 8px;
overflow: hidden;
@@ -149,7 +149,7 @@
}
.about-modal-bar-text {
font-size: 12px;
color: #64748b;
color: var(--color-text-subtle);
text-align: right;
}
.about-modal-footer {
@@ -159,54 +159,12 @@
}
.about-modal-close-btn {
padding: 8px 24px;
border: 1px solid #e2e8f0;
border: 1px solid var(--color-border);
border-radius: 8px;
background: #fff;
color: #334155;
background: var(--color-bg-surface);
color: var(--color-text-dark);
font-size: 13px;
font-weight: 600;
cursor: pointer;
transition: background 0.15s;
}
/* ── Dark theme overrides ── */
[data-theme="dark"] .empty-state-icon {
color: #475569;
}
[data-theme="dark"] .empty-state-icon.error {
color: #ef4444;
}
[data-theme="dark"] .about-modal-username {
color: #f1f5f9;
}
[data-theme="dark"] .about-modal-email {
color: #94a3b8;
}
[data-theme="dark"] .about-modal-role-admin {
background: #1e3a5f;
color: #60a5fa;
}
[data-theme="dark"] .about-modal-role-user {
background: #334155;
color: #94a3b8;
}
[data-theme="dark"] .about-modal-storage-label {
color: #94a3b8;
}
[data-theme="dark"] .about-modal-bar-bg {
background: #334155;
}
[data-theme="dark"] .about-modal-bar-text {
color: #94a3b8;
}
[data-theme="dark"] .about-modal-close-btn {
background: #1e293b;
border-color: #334155;
color: #cbd5e1;
}
[data-theme="dark"] .move-dialog-hint {
color: #94a3b8;
}
[data-theme="dark"] .search-empty-text {
color: #94a3b8;
}