fix: 修复桌面端平铺布局为单列,避免显示为移动端版式
## 问题 桌面端平铺入口(admin-index.html)原使用双列布局(grid-template-columns: repeat(2, 1fr)), 导致桌面端页面显示得很窄,变成移动端的版式。 ## 修复 将桌面端平铺布局改为单列(grid-template-columns: 1fr): - 桌面端:单列布局,每个页面占据全宽 - 移动端:单列垂直布局,每个页面保持手机尺寸 ## 变更 - 修改 grid-template-columns 从 repeat(2, 1fr) 到 1fr - 更新注释:两列平铺 → 单列平铺 - 更新说明:桌面端平铺(2列网格)→ 桌面端平铺(单列网格) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Binary file not shown.
@@ -229,7 +229,7 @@ prototype/
|
||||
/* 平铺网格布局 */
|
||||
.prototype-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, 1fr); /* 两列平铺 */
|
||||
grid-template-columns: 1fr; * 单列平铺,每个页面占据全宽 */
|
||||
gap: 16px;
|
||||
padding: 16px;
|
||||
}
|
||||
@@ -277,7 +277,7 @@ prototype/
|
||||
/* 中屏:2列平铺 */
|
||||
@media (min-width: 768px) and (max-width: 1399px) {
|
||||
.prototype-grid {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
/* 小屏:1列平铺 */
|
||||
@@ -303,7 +303,7 @@ prototype/
|
||||
|
||||
| 布局 | CSS | 适用场景 |
|
||||
|------|-----|----------|
|
||||
| **2列网格** ⭐ | `grid-template-columns: repeat(2, 1fr)` | 默认,桌面端平铺 |
|
||||
| **2列网格** ⭐ | `grid-template-columns: 1fr` | 默认,桌面端平铺 |
|
||||
| 3列网格 | `grid-template-columns: repeat(3, 1fr)` | 大屏幕,更多页面 |
|
||||
| 1列网格 | `grid-template-columns: 1fr` | 小屏幕,移动端 |
|
||||
|
||||
|
||||
Reference in New Issue
Block a user