refactor(UI): 优化表单布局并添加磁盘使用统计功能

- 将登录表单改为浮动标签样式提升用户体验
- 为版本管理表单添加占位符文本
- 在首页添加网站空间使用情况统计
This commit is contained in:
2025-07-12 15:19:14 +08:00
parent 5b009b838b
commit 81b08598d0
4 changed files with 39 additions and 14 deletions

View File

@@ -84,13 +84,13 @@ if (!isset($_SESSION['admin'])) {
</script>
<?php endif; ?>
<form method="post">
<div class="mb-3">
<label for="username" class="form-label">用户名</label>
<div class="form-floating mb-3">
<input type="text" class="form-control" id="username" name="username" required>
<label for="username">用户名</label>
</div>
<div class="mb-3">
<label for="password" class="form-label">密码</label>
<div class="form-floating mb-3">
<input type="password" class="form-control" id="password" name="password" required>
<label for="password">密码</label>
</div>
<button type="submit" class="btn btn-primary">登录</button>
</form>

View File

@@ -286,11 +286,11 @@ if (isset($_GET['success'])) {
<div class="modal-body">
<input type="hidden" name="version_id" value="<?php echo $version['id']; ?>">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="version_<?php echo $version['id']; ?>" name="version" value="<?php echo htmlspecialchars($version['version']); ?>" required>
<input type="text" class="form-control" id="version_<?php echo $version['id']; ?>" name="version" value="<?php echo htmlspecialchars($version['version']); ?>" placeholder="如: 1.0.0" required>
<label for="version_<?php echo $version['id']; ?>">版本号</label>
</div>
<div class="form-floating mb-3">
<textarea class="form-control" id="changelog_<?php echo $version['id']; ?>" name="changelog" rows="3" required><?php echo htmlspecialchars($version['changelog']); ?></textarea>
<textarea class="form-control" id="changelog_<?php echo $version['id']; ?>" name="changelog" rows="3" placeholder="描述本次更新内容" required><?php echo htmlspecialchars($version['changelog']); ?></textarea>
<label for="changelog_<?php echo $version['id']; ?>">更新日志</label>
</div>
<div class="mb-3">