feat: 电商页面 KeepAlive 保活机制,切换页面不再丢失生成状态
通过 display:none 模式实现轻量 KeepAlive,电商页面首次访问后保持挂载, 切换到其他页面再切回时所有右侧面板状态(上传图片、生成进度、结果)完整保留。 同时清理项目中的临时文件和本地冗余图片。 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -3000,6 +3000,346 @@
|
||||
font-weight: 800;
|
||||
}
|
||||
|
||||
/* ═══════════════════════════════════════════════
|
||||
Flowchart Pipeline Layout (参考图风格)
|
||||
流程图式布局:原图 → 分镜文本 → 分镜图 → 分镜视频
|
||||
═══════════════════════════════════════════════ */
|
||||
|
||||
.clone-ai-flow-pipeline {
|
||||
display: flex;
|
||||
align-items: stretch;
|
||||
gap: 0;
|
||||
width: min(100%, 1100px);
|
||||
min-height: 320px;
|
||||
padding: 20px 0;
|
||||
}
|
||||
|
||||
/* ── Source Node ── */
|
||||
.clone-ai-flow-source {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
border: 1px solid #2c3038;
|
||||
border-radius: var(--radius-sm, 10px);
|
||||
background: #1b1d23;
|
||||
transition: border-color 200ms ease, transform 200ms ease, box-shadow 200ms ease;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node:hover {
|
||||
border-color: rgba(var(--accent-rgb), 0.4);
|
||||
transform: translateY(-2px);
|
||||
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
.clone-ai-flow-node--source {
|
||||
width: 160px;
|
||||
height: 200px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node--source img {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__placeholder {
|
||||
display: grid;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
min-height: 80px;
|
||||
place-items: center;
|
||||
color: #565d6b;
|
||||
font-size: 32px;
|
||||
background: linear-gradient(135deg, #1b1d23 0%, #14161b 100%);
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__label {
|
||||
color: #aeb8b1;
|
||||
font-size: 13px;
|
||||
font-weight: 700;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__tag {
|
||||
position: absolute;
|
||||
left: 8px;
|
||||
top: 8px;
|
||||
max-width: calc(100% - 16px);
|
||||
overflow: hidden;
|
||||
border: 1px solid #303540;
|
||||
border-radius: 999px;
|
||||
background: rgba(21, 23, 28, 0.92);
|
||||
backdrop-filter: blur(6px);
|
||||
color: #d8deed;
|
||||
padding: 4px 10px;
|
||||
font-size: 11px;
|
||||
font-weight: 800;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__tag--accent {
|
||||
border-color: rgba(var(--accent-rgb), 0.35);
|
||||
background: rgba(var(--accent-rgb), 0.12);
|
||||
color: var(--accent);
|
||||
}
|
||||
|
||||
/* ── Text Node ── */
|
||||
.clone-ai-flow-node--text {
|
||||
min-width: 130px;
|
||||
max-width: 160px;
|
||||
padding: 16px 14px;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__text-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__text-title {
|
||||
color: #eef2f6;
|
||||
font-size: 14px;
|
||||
font-weight: 800;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node__text-desc {
|
||||
color: #758096;
|
||||
font-size: 12px;
|
||||
line-height: 1.5;
|
||||
display: -webkit-box;
|
||||
-webkit-line-clamp: 3;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* ── Result Node ── */
|
||||
.clone-ai-flow-node--result,
|
||||
.clone-ai-flow-node--output {
|
||||
width: 180px;
|
||||
height: 140px;
|
||||
flex-shrink: 0;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node--result img,
|
||||
.clone-ai-flow-node--output img {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
/* ── Video Node ── */
|
||||
.clone-ai-flow-node--video {
|
||||
width: 160px;
|
||||
height: 120px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
/* ── Connector (分支连接线) ── */
|
||||
.clone-ai-flow-connector {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-shrink: 0;
|
||||
width: 40px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector__trunk {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 50%;
|
||||
width: 20px;
|
||||
height: 2px;
|
||||
background: #3a3f48;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector__branches {
|
||||
position: absolute;
|
||||
left: 20px;
|
||||
top: 15%;
|
||||
bottom: 15%;
|
||||
width: 20px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector__branch {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 2px;
|
||||
background: #3a3f48;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector__branch::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: -8px;
|
||||
width: 2px;
|
||||
height: 18px;
|
||||
background: #3a3f48;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector__branch:last-child::before {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector__branches::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
width: 2px;
|
||||
background: #3a3f48;
|
||||
}
|
||||
|
||||
/* ── Flow Arrow (节点间箭头) ── */
|
||||
.clone-ai-flow-branch .clone-ai-flow-arrow {
|
||||
width: 28px;
|
||||
height: 16px;
|
||||
flex-shrink: 0;
|
||||
background: var(--accent);
|
||||
clip-path: polygon(0 34%, 55% 34%, 55% 0, 100% 50%, 55% 100%, 55% 66%, 0 66%);
|
||||
opacity: 0.7;
|
||||
animation: clone-ai-arrow-pulse 1.6s ease-in-out infinite;
|
||||
}
|
||||
|
||||
@keyframes clone-ai-arrow-pulse {
|
||||
0%, 100% { opacity: 0.5; transform: translateX(0); }
|
||||
50% { opacity: 1; transform: translateX(3px); }
|
||||
}
|
||||
|
||||
/* ── Branches Container ── */
|
||||
.clone-ai-flow-branches {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 16px;
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.clone-ai-flow-branch {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
/* ── Empty State Branches ── */
|
||||
.clone-ai-flow-branches--empty .clone-ai-flow-branch {
|
||||
opacity: 0.55;
|
||||
}
|
||||
|
||||
.clone-ai-flow-branches--empty .clone-ai-flow-branch.is-generating {
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
.clone-ai-flow-branches--empty .clone-ai-flow-branch.is-generating .clone-ai-flow-node {
|
||||
border-color: rgba(var(--accent-rgb), 0.25);
|
||||
}
|
||||
|
||||
.clone-ai-flow-branches--empty .clone-ai-flow-branch.is-failed {
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
.clone-ai-flow-branches--empty .clone-ai-flow-branch.is-failed .clone-ai-flow-node {
|
||||
border-color: rgba(255, 90, 95, 0.3);
|
||||
}
|
||||
|
||||
/* ── Status Overlay ── */
|
||||
.clone-ai-flow-status {
|
||||
display: grid;
|
||||
place-items: center;
|
||||
align-content: center;
|
||||
gap: 10px;
|
||||
text-align: center;
|
||||
padding: 16px 24px;
|
||||
border: 1px solid #2c3038;
|
||||
border-radius: var(--radius-md, 14px);
|
||||
background: rgba(27, 29, 35, 0.85);
|
||||
backdrop-filter: blur(8px);
|
||||
width: min(100%, 480px);
|
||||
}
|
||||
|
||||
.clone-ai-flow-status strong {
|
||||
color: #d8deed;
|
||||
font-size: 18px;
|
||||
font-weight: 900;
|
||||
}
|
||||
|
||||
.clone-ai-flow-status span {
|
||||
color: #758096;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.clone-ai-flow-status .anticon {
|
||||
color: var(--accent);
|
||||
}
|
||||
|
||||
/* ── Flowchart Responsive ── */
|
||||
@media (max-width: 900px) {
|
||||
.clone-ai-flow-pipeline {
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.clone-ai-flow-connector {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.clone-ai-flow-source {
|
||||
flex-direction: row;
|
||||
gap: 16px;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node--source {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
}
|
||||
|
||||
.clone-ai-flow-branches {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.clone-ai-flow-branch {
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node--result,
|
||||
.clone-ai-flow-node--output {
|
||||
width: 140px;
|
||||
height: 110px;
|
||||
}
|
||||
|
||||
.clone-ai-flow-node--text {
|
||||
min-width: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
/* ── Scope to clone tool + video output ── */
|
||||
.product-clone-page[data-tool="clone"] .clone-ai-flow-pipeline {
|
||||
width: min(100%, 1100px);
|
||||
}
|
||||
|
||||
/* ═══════════════════════════════════════════════
|
||||
End Flowchart Pipeline Styles
|
||||
═══════════════════════════════════════════════ */
|
||||
|
||||
.product-clone-page .clone-ai-input-wrapper {
|
||||
position: relative;
|
||||
}
|
||||
@@ -8081,6 +8421,7 @@
|
||||
.ecommerce-template-apple-carousel.is-resetting .ecommerce-template-apple-card,
|
||||
.ecommerce-template-apple-carousel.is-resetting .ecommerce-template-apple-card img {
|
||||
transition: none;
|
||||
}
|
||||
.clone-ai-video-outfit-upload {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
Reference in New Issue
Block a user