vm-bench/frontend/templates/_analysis.html
Claus Lohmar 844d86c105 style: Proxmox VE-inspired dark theme — pve-* class naming
Rewrote proxmox.css with consistent pve- prefix matching the Proxmox
VE design language: panels with orange-accent headers, clean tables,
orange progress bars, green/red/orange badges, subtle shadows.

Updated all templates (base, index, _analysis, polling, scp)
to use pve-btn, pve-input, pve-select, pve-panel, pve-progress,
pve-badge, pve-alert, pve-spinner, pve-hidden, pve-dim, etc.
2026-07-23 09:09:29 +00:00

86 lines
3.4 KiB
HTML

{# Fragment — no <script> tags (injected via innerHTML) #}
{% if error %}
<div class="pve-panel" id="analysis-result">
<div class="pve-panel-header">
<span class="pve-panel-title">Analysis Failed</span>
</div>
<div class="pve-panel-body">
<div class="pve-alert pve-alert-error">{{ error }}</div>
<a href="/" class="pve-btn" style="margin-top:0.75rem;">Try Again</a>
</div>
</div>
{% else %}
<div class="pve-panel" id="step2">
<div class="pve-panel-header">
<span class="pve-panel-title">Analysis Result</span>
</div>
<div class="pve-panel-body">
<table class="pve-table">
<tr><td>File</td><td>{{ analysis.filename }}</td></tr>
<tr><td>Disk Format</td><td>{{ analysis.disk_format }}</td></tr>
<tr><td>Disk Size</td><td>{{ analysis.disk_size_gb }} GB</td></tr>
<tr><td>Operating System</td><td>{{ analysis.os_type or 'Unknown' }}</td></tr>
<tr><td>EFI Bootable</td><td>{{ 'Yes' if analysis.efi_detectable else 'Unknown' }}</td></tr>
</table>
<p class="pve-dim" style="margin:0.75rem 0;">Is this correct? Configure the VM below and submit the conversion job.</p>
<form id="confirm-form" data-vmid="{{ vmid }}" data-source-filename="{{ source_filename }}">
<input type="hidden" name="vmid" value="{{ vmid }}">
<input type="hidden" name="source_filename" value="{{ source_filename }}">
<input type="hidden" name="disk_format" value="{{ analysis.disk_format }}">
<div class="pve-row">
<div class="pve-form-group">
<label>VM Name *</label>
<input type="text" name="vm_name" required class="pve-input" value="{{ vm_name or '' }}"
placeholder="my-converted-vm">
</div>
<div class="pve-form-group">
<label>Target Disk Size (GB)</label>
<input type="number" name="target_disk_size_gb" class="pve-input"
value="{{ analysis.disk_size_gb }}"
placeholder="Leave blank for auto-shrink">
<span class="pve-hint">{{ analysis.disk_size_gb }} GB detected. Omit to auto-shrink to 30 GB.</span>
</div>
</div>
<div class="pve-row">
<div class="pve-form-group">
<label>CPU Cores</label>
<input type="number" name="cpu_cores" class="pve-input" value="2" min="1">
</div>
<div class="pve-form-group">
<label>RAM (MB)</label>
<input type="number" name="ram_mb" class="pve-input" value="4096" min="512">
</div>
</div>
<div class="pve-row">
<div class="pve-form-group">
<label>Storage Pool</label>
<input type="text" name="target_storage" class="pve-input" value="local-lvm">
</div>
<div class="pve-form-group">
<label>Boot Detection</label>
<select name="auto_detect_boot" class="pve-select">
<option value="true" selected>Auto-detect (recommended)</option>
<option value="false">Manual</option>
</select>
</div>
</div>
<div class="pve-form-group" id="boot-type-group" style="display:none;">
<label>Boot Type</label>
<select name="boot_type" class="pve-select">
<option value="uefi">UEFI</option>
<option value="legacy">Legacy BIOS</option>
</select>
</div>
<button type="submit" id="submit-btn" class="pve-btn pve-btn-primary">Start Conversion</button>
</form>
<div id="submit-status" class="pve-hidden" style="margin-top:1rem;"></div>
</div>
</div>
{% endif %}