feat: 全站视觉焕新与悬浮玻璃 TabBar 迁移

This commit is contained in:
2026-08-07 23:29:19 +08:00
parent 19408e5a8c
commit 61f1217384
97 changed files with 4007 additions and 2024 deletions
+270 -145
View File
@@ -1,24 +1,91 @@
.diy-page {
padding: 0 24px 24px;
padding: 0 32rpx calc(48rpx + env(safe-area-inset-bottom));
min-height: 100vh;
box-sizing: border-box;
}
/* 顶部标题区 */
.diy-page .page-header {
display: flex;
align-items: center;
margin: 0 0 24rpx;
padding-top: 0;
padding-bottom: 16rpx;
background: transparent;
border: none;
box-shadow: none;
}
.diy-page .page-header.surface-card {
background: transparent;
border: none;
box-shadow: none;
}
.diy-page .page-header .flex-between {
min-height: 88rpx;
}
.back-btn {
display: flex;
align-items: center;
justify-content: center;
width: 80rpx;
height: 80rpx;
flex-shrink: 0;
border-radius: 50%;
background: var(--bg-card);
border: 1rpx solid var(--border-strong);
box-shadow: var(--shadow-card);
font-size: 36rpx;
line-height: 1;
color: var(--text-primary);
}
.back-btn:active {
transform: scale(0.96);
}
.diy-page .page-title {
flex: 1;
min-width: 0;
padding: 0 16rpx;
text-align: center;
font-size: 34rpx;
font-weight: 700;
color: var(--text-primary);
letter-spacing: 0;
line-height: 1.2;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.header-spacer {
width: 80rpx;
height: 80rpx;
flex-shrink: 0;
}
/* 画布区域 */
.canvas-wrapper {
padding: 40px;
padding: 24rpx;
display: flex;
justify-content: center;
align-items: center;
border-radius: 24rpx;
}
.canvas-area {
position: relative;
background: var(--bg-input);
overflow: hidden;
border-radius: 16px;
min-width: 200px;
min-height: 200px;
border-radius: 24rpx;
min-width: 300rpx;
min-height: 400rpx;
max-width: 100%;
box-sizing: border-box;
box-shadow: inset 0 0 0 1rpx var(--border-strong);
}
.mask-border {
@@ -37,46 +104,59 @@
max-width: 100%;
max-height: 100%;
z-index: 5;
border: 2px solid transparent;
border: 2rpx solid transparent;
border-radius: 8rpx;
}
.canvas-image.active {
border-color: var(--accent-primary);
box-shadow: 0 0 0 8rpx var(--accent-primary-soft);
}
.canvas-image.overlap {
border-color: var(--danger);
box-shadow: 0 0 12px var(--danger-soft);
box-shadow: 0 0 0 8rpx var(--danger-soft);
}
/* 贴纸面板 */
.sticker-panel {
padding: 28px;
padding: 24rpx;
}
.sticker-panel .section-title {
display: block;
margin-bottom: 20rpx;
font-size: 32rpx;
font-weight: 700;
color: var(--text-primary);
letter-spacing: 0;
}
.sticker-list {
display: flex;
flex-wrap: wrap;
gap: 16px;
gap: 16rpx;
}
.sticker-thumb {
position: relative;
width: 120px;
height: 120px;
width: 164rpx;
height: 164rpx;
border: 1rpx solid var(--border);
border-radius: 12px;
border-radius: 20rpx;
overflow: hidden;
background: var(--bg-input);
box-shadow: var(--shadow-card);
}
.sticker-thumb.active {
border-color: var(--accent-primary);
border-width: 2rpx;
box-shadow: 0 0 0 6rpx var(--accent-primary-soft);
}
.sticker-thumb.overlap {
border-color: var(--danger);
box-shadow: 0 0 0 6rpx var(--danger-soft);
}
.sticker-thumb-img {
@@ -86,52 +166,59 @@
.sticker-del {
position: absolute;
top: 4px;
right: 4px;
width: 36px;
height: 36px;
top: 8rpx;
right: 8rpx;
width: 44rpx;
height: 44rpx;
background: var(--danger);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
z-index: 10;
box-shadow: var(--shadow-card);
}
.del-icon {
color: #fff;
font-size: 24px;
font-size: 28rpx;
font-weight: 700;
line-height: 1;
}
.sticker-add-btn {
width: 120px;
height: 120px;
border: 1rpx solid var(--border);
border-radius: 12px;
width: 164rpx;
height: 164rpx;
border: 1rpx solid var(--border-strong);
border-radius: 20rpx;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
background: var(--bg-input);
background: var(--bg-muted);
}
.sticker-add-btn:active {
transform: scale(0.97);
}
.add-icon {
font-size: 48px;
font-size: 44rpx;
color: var(--accent-primary);
line-height: 1;
font-weight: 600;
}
.add-label {
font-size: 22px;
font-size: 22rpx;
color: var(--text-secondary);
margin-top: 8px;
margin-top: 8rpx;
}
.overlap-hint {
display: block;
margin-top: 16px;
font-size: 26px;
margin-top: 16rpx;
font-size: 24rpx;
color: var(--danger);
font-weight: 600;
text-align: center;
@@ -139,153 +226,78 @@
/* 工具栏 */
.toolbar {
padding: 28px 32px;
padding: 24rpx;
}
.tool-row {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 20px;
gap: 16rpx;
padding: 8rpx 0;
}
.tool-row:last-child {
margin-bottom: 0;
.tool-row + .tool-row {
border-top: 1rpx solid var(--border);
margin-top: 8rpx;
padding-top: 16rpx;
}
.tool-label {
font-size: 28px;
font-size: 26rpx;
font-weight: 600;
color: var(--text-primary);
}
.tool-btn {
width: 56px;
height: 56px;
width: 64rpx;
height: 64rpx;
background: var(--bg-input);
border: 1rpx solid var(--border-strong);
border-radius: 50%;
border: 1rpx solid var(--border);
border-radius: 16rpx;
display: flex;
align-items: center;
justify-content: center;
font-size: 32px;
font-size: 32rpx;
color: var(--text-primary);
font-weight: 700;
font-weight: 600;
}
.tool-btn:active {
transform: scale(0.96);
background: var(--bg-muted);
}
.tool-value {
font-size: 28px;
font-size: 26rpx;
font-weight: 600;
color: var(--accent-primary);
min-width: 80px;
min-width: 88rpx;
text-align: center;
font-variant-numeric: tabular-nums;
}
.tool-hint {
font-size: 24px;
font-size: 24rpx;
color: var(--text-secondary);
}
/* 预览弹窗 */
.preview-overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.5);
display: flex;
align-items: center;
justify-content: center;
z-index: 1000;
padding: 40px;
}
.preview-card {
background: var(--bg-card);
width: 100%;
max-height: 80vh;
overflow-y: auto;
padding: 40px;
}
.preview-title {
font-size: 36px;
font-weight: 700;
color: var(--text-primary);
display: block;
margin-bottom: 24px;
text-align: center;
}
.preview-canvas {
background: var(--bg-input);
border-radius: 16px;
overflow: hidden;
margin: 0 auto 24px;
border: 1rpx solid var(--border-strong);
position: relative;
min-width: 200px;
min-height: 200px;
max-width: 100%;
box-sizing: border-box;
}
.preview-image {
position: absolute;
max-width: 100%;
max-height: 100%;
z-index: 5;
}
.preview-image.overlap {
border: 2px solid var(--danger);
}
.product-info {
text-align: center;
margin-bottom: 32px;
}
.product-name {
font-size: 30px;
font-weight: 700;
color: var(--text-primary);
display: block;
margin-bottom: 8px;
}
.product-size {
font-size: 24px;
color: var(--text-secondary);
}
.preview-actions {
display: flex;
gap: 20px;
}
.preview-actions .btn-secondary,
.preview-actions .btn-primary {
flex: 1;
text-align: center;
}
.preview-actions .btn-primary.disabled {
opacity: 0.5;
pointer-events: none;
}
/* 常驻编辑按钮 */
.edit-btn-bar {
display: flex;
justify-content: flex-end;
margin-top: 24rpx;
}
.edit-btn {
padding: 16px 48px;
border-radius: 50px;
font-size: 28px;
display: flex;
align-items: center;
justify-content: center;
min-width: 176rpx;
height: 88rpx;
padding: 0 40rpx;
border-radius: 999rpx;
font-size: 28rpx;
font-weight: 600;
text-align: center;
background: var(--bg-input);
@@ -301,19 +313,132 @@
}
.edit-btn.disabled {
opacity: 0.45;
pointer-events: none;
}
/* 底部操作栏 — 毛玻璃由 BottomActionBar 提供 */
.bottom-action-bar .btn-primary,
.bottom-action-bar .btn-secondary {
flex: 1;
text-align: center;
padding: 28rpx 0;
font-size: 28rpx;
font-weight: 600;
line-height: 1.2;
}
/* 预览弹层 */
.preview-overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.45);
display: flex;
align-items: flex-end;
justify-content: center;
z-index: 1000;
}
.preview-card {
width: 100%;
max-height: 88vh;
overflow-y: auto;
padding: 40rpx 32rpx calc(32rpx + env(safe-area-inset-bottom));
background: var(--bg-card);
border-radius: 32rpx 32rpx 0 0;
border: 1rpx solid var(--border);
box-shadow: var(--shadow-elevated);
box-sizing: border-box;
}
.preview-card::before {
content: '';
display: block;
width: 64rpx;
height: 8rpx;
margin: 0 auto 32rpx;
border-radius: 999rpx;
background: var(--bg-muted);
}
.preview-title {
font-size: 34rpx;
font-weight: 700;
color: var(--text-primary);
display: block;
margin-bottom: 24rpx;
text-align: center;
letter-spacing: 0;
}
.preview-canvas {
background: var(--bg-input);
border-radius: 24rpx;
overflow: hidden;
margin: 0 auto 24rpx;
border: 1rpx solid var(--border-strong);
position: relative;
min-width: 300rpx;
min-height: 400rpx;
max-width: 100%;
box-sizing: border-box;
}
.preview-image {
position: absolute;
max-width: 100%;
max-height: 100%;
z-index: 5;
}
.preview-image.overlap {
border: 2rpx solid var(--danger);
border-radius: 8rpx;
}
.product-info {
text-align: center;
margin-bottom: 28rpx;
}
.product-name {
font-size: 32rpx;
font-weight: 700;
color: var(--text-primary);
display: block;
margin-bottom: 8rpx;
letter-spacing: 0;
}
.product-size {
font-size: 24rpx;
color: var(--text-secondary);
}
.preview-actions {
display: flex;
gap: 16rpx;
}
.preview-actions .btn-secondary,
.preview-actions .btn-primary {
flex: 1;
text-align: center;
padding: 28rpx 0;
font-size: 28rpx;
font-weight: 600;
line-height: 1.2;
}
.preview-actions .btn-primary.disabled {
opacity: 0.5;
pointer-events: none;
}
/* 底部操作栏 — 毛玻璃规则由全局 .action-bar 提供 */
.action-bar .btn-primary,
.action-bar .btn-secondary {
flex: 1;
text-align: center;
padding: 24px 0;
font-size: 28px;
}
/* 局部间距 */
.mt-20 {
margin-top: 20px;
margin-top: 24rpx;
}