From d0d6230d69516a88e7d49e54e0e94115b43e90b9 Mon Sep 17 00:00:00 2001 From: Rizqi Date: Sun, 21 Jun 2026 03:55:22 +0700 Subject: [PATCH] feat: add UI templates for login, storage management, and backup job workflows --- vsphere_backup/templates/base.html | 296 ++++++++++++++--------- vsphere_backup/templates/create_job.html | 79 +++--- vsphere_backup/templates/job_detail.html | 83 ++++--- vsphere_backup/templates/jobs.html | 39 +-- vsphere_backup/templates/login.html | 46 ++-- vsphere_backup/templates/nfs.html | 76 +++--- vsphere_backup/templates/vms.html | 79 +++--- 7 files changed, 415 insertions(+), 283 deletions(-) diff --git a/vsphere_backup/templates/base.html b/vsphere_backup/templates/base.html index 3bdf656..d391e0e 100644 --- a/vsphere_backup/templates/base.html +++ b/vsphere_backup/templates/base.html @@ -9,43 +9,47 @@ {% block head %}{% endblock %} diff --git a/vsphere_backup/templates/create_job.html b/vsphere_backup/templates/create_job.html index 5ef9c1c..7da9dec 100644 --- a/vsphere_backup/templates/create_job.html +++ b/vsphere_backup/templates/create_job.html @@ -4,88 +4,99 @@ {% block head %} {% endblock %} diff --git a/vsphere_backup/templates/job_detail.html b/vsphere_backup/templates/job_detail.html index b86c049..37e9ff8 100644 --- a/vsphere_backup/templates/job_detail.html +++ b/vsphere_backup/templates/job_detail.html @@ -6,15 +6,17 @@ {% endblock %} diff --git a/vsphere_backup/templates/jobs.html b/vsphere_backup/templates/jobs.html index c3cb904..6826193 100644 --- a/vsphere_backup/templates/jobs.html +++ b/vsphere_backup/templates/jobs.html @@ -6,52 +6,59 @@ {% endblock %} diff --git a/vsphere_backup/templates/login.html b/vsphere_backup/templates/login.html index bfadd3c..a8319b6 100644 --- a/vsphere_backup/templates/login.html +++ b/vsphere_backup/templates/login.html @@ -3,43 +3,47 @@ {% block head %} {% endblock %} diff --git a/vsphere_backup/templates/vms.html b/vsphere_backup/templates/vms.html index e1b63e6..48acd95 100644 --- a/vsphere_backup/templates/vms.html +++ b/vsphere_backup/templates/vms.html @@ -7,65 +7,79 @@ .vms-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); - gap: 16px; - margin-top: 24px; + gap: 20px; + margin-top: 28px; } .vm-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); - padding: 20px; - transition: all .2s ease; + padding: 24px; + transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); cursor: default; position: relative; overflow: hidden; + box-shadow: var(--shadow); + backdrop-filter: blur(8px); } .vm-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; - background: linear-gradient(90deg, var(--accent), var(--accent-2)); + background: var(--accent-gradient); opacity: 0; - transition: opacity .2s; + transition: opacity 0.3s; + } + .vm-card:hover { + border-color: var(--border-bright); + transform: translateY(-4px) scale(1.01); + box-shadow: var(--shadow-hover); } - .vm-card:hover { border-color: var(--border-bright); transform: translateY(-2px); box-shadow: var(--shadow); } .vm-card:hover::before { opacity: 1; } .vm-card-header { display: flex; align-items: flex-start; justify-content: space-between; - margin-bottom: 14px; + margin-bottom: 18px; } .vm-name { - font-size: 15px; font-weight: 600; word-break: break-word; + font-size: 16px; font-weight: 700; word-break: break-word; flex: 1; padding-right: 10px; + letter-spacing: -0.01em; } - .vm-os { font-size: 11.5px; color: var(--text-muted); margin-top: 2px; } + .vm-os { font-size: 12px; color: var(--text-muted); margin-top: 3px; font-weight: 500; } .vm-stats { display: grid; grid-template-columns: 1fr 1fr; - gap: 10px; margin: 14px 0; + gap: 12px; margin: 18px 0; } .stat { - background: rgba(255,255,255,0.03); - border: 1px solid var(--border); + background: rgba(255,255,255,0.01); + border: 1px solid rgba(255,255,255,0.03); border-radius: var(--radius-sm); - padding: 8px 12px; + padding: 10px 14px; + box-shadow: 0 2px 4px rgba(0,0,0,0.05); } - .stat-label { font-size: 10.5px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; } - .stat-value { font-size: 14px; font-weight: 600; margin-top: 2px; } + .stat-label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 700; } + .stat-value { font-size: 14px; font-weight: 600; margin-top: 3px; } .vm-footer { - display: flex; gap: 8px; margin-top: 16px; + display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; } .vm-footer .btn { flex: 1; min-width: 110px; justify-content: center; } .search-bar { display: flex; align-items: center; gap: 12px; - background: var(--bg-card); + background: rgba(8, 10, 16, 0.4); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 16px; max-width: 340px; + transition: all 0.2s ease; + } + .search-bar:focus-within { + border-color: var(--accent); + box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15); + background: rgba(8, 10, 16, 0.6); } .search-bar input { background: none; border: none; outline: none; @@ -78,33 +92,36 @@ margin-bottom: 4px; flex-wrap: wrap; } .filter-chip { - padding: 5px 14px; border-radius: 100px; - font-size: 12.5px; font-weight: 500; cursor: pointer; - border: 1px solid var(--border); background: none; - color: var(--text-secondary); transition: all .15s; + padding: 6px 16px; border-radius: 100px; + font-size: 13px; font-weight: 600; cursor: pointer; + border: 1px solid var(--border); background: rgba(255,255,255,0.01); + color: var(--text-secondary); transition: all .2s cubic-bezier(0.4, 0, 0.2, 1); } - .filter-chip:hover { border-color: var(--border-bright); color: var(--text-primary); } - .filter-chip.active { background: rgba(124,107,255,.15); border-color: var(--accent); color: var(--accent); } + .filter-chip:hover { border-color: var(--border-bright); color: var(--text-primary); transform: translateY(-1px); } + .filter-chip.active { background: rgba(99, 102, 241, .15); border-color: var(--accent); color: #a5b4fc; box-shadow: 0 4px 12px rgba(99,102,241,0.1); } .stat-chips { - display: flex; gap: 10px; align-items: center; - flex-wrap: wrap; margin-bottom: 20px; + display: flex; gap: 12px; align-items: center; + flex-wrap: wrap; margin-bottom: 24px; } .stat-chip { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); - padding: 10px 18px; + padding: 12px 20px; text-align: center; + min-width: 100px; + box-shadow: var(--shadow); + backdrop-filter: blur(8px); } - .stat-chip-value { font-size: 22px; font-weight: 700; } - .stat-chip-label { font-size: 11px; color: var(--text-muted); margin-top: 1px; } + .stat-chip-value { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; } + .stat-chip-label { font-size: 11px; color: var(--text-muted); margin-top: 2px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; } .empty-state { - text-align: center; padding: 60px 20px; + text-align: center; padding: 64px 20px; color: var(--text-secondary); } - .empty-state .empty-icon { font-size: 48px; margin-bottom: 14px; opacity: 0.5; } + .empty-state .empty-icon { font-size: 52px; margin-bottom: 16px; opacity: 0.4; } {% endblock %}