From 863f1f075e316ccca15fe396daa525808c6fb584 Mon Sep 17 00:00:00 2001 From: Stringadmin Date: Fri, 12 Jun 2026 11:33:13 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=20compact=20?= =?UTF-8?q?=E6=A8=A1=E5=BC=8F=E4=B8=8B=E5=AF=B9=E8=AF=9D=E6=A1=86=E5=BA=95?= =?UTF-8?q?=E9=83=A8=E5=A4=A7=E9=87=8F=E7=A9=BA=E7=99=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 高特异性 min-height 规则覆盖了 compact 模式的 max-height: 126px, 导致 .ecom-command-composer 在缩小状态下仍保持 218px+ 的最小高度。 在文件末尾添加更高特异性的 is-compact 覆盖,强制 min-height: 118px。 Co-Authored-By: Claude Opus 4.7 --- src/styles/ecommerce-standalone.css | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/styles/ecommerce-standalone.css b/src/styles/ecommerce-standalone.css index 9c9e0ed..7809960 100644 --- a/src/styles/ecommerce-standalone.css +++ b/src/styles/ecommerce-standalone.css @@ -11889,3 +11889,15 @@ html body #root .ecommerce-standalone.web-shell .ecom-watermark-workspace { --ecommerce-topbar-height: 62px; } } + +/* Compact composer override: force small dimensions when is-compact is active, beating all min-height rules. */ +html body #root .ecommerce-standalone.ecommerce-standalone .product-clone-page[data-tool="clone"][data-tool="clone"] .ecom-command-composer-wrap.has-generated.is-compact .clone-ai-input-wrapper.ecom-command-composer, +html body #root .ecommerce-standalone.ecommerce-standalone .product-clone-page[data-tool="clone"][data-tool="clone"] .ecom-command-composer-wrap.has-generated.is-compact .clone-ai-input-wrapper.ecom-command-composer:has(.ecom-command-asset-popover) { + min-height: 118px !important; + max-height: 126px !important; +} + +html body #root .ecommerce-standalone.ecommerce-standalone .product-clone-page[data-tool="clone"][data-tool="clone"] .ecom-command-composer-wrap.has-generated.is-compact .ecom-command-composer textarea { + min-height: 22px !important; + max-height: 22px !important; +} From e88edbe165c6a814396f4dac789ea933abfbdb2b Mon Sep 17 00:00:00 2001 From: Stringadmin Date: Fri, 12 Jun 2026 12:37:32 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=20compact=20?= =?UTF-8?q?=E5=AF=B9=E8=AF=9D=E6=A1=86=E3=80=81=E7=94=BB=E5=B8=83=E8=8A=82?= =?UTF-8?q?=E7=82=B9=E6=A0=87=E7=AD=BE=E3=80=81=E5=88=A0=E5=9B=BE=E9=87=8D?= =?UTF-8?q?=E7=BD=AE=E5=8F=8A=E6=AF=94=E4=BE=8B=E5=BC=B9=E7=AA=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - compact 模式尺寸调整,生成按钮不再溢出框外 - 生成时自动进入 compact 状态,idle 时恢复 - 删除所有样图后重置为新对话状态(清除画布、恢复标题) - 去掉 drag handle 模式标签,原图右上角统一高级黑 tag - 作品图不再显示重复标识 - 比例弹窗宽度自适应内容,添加 hover/active 交互样式 - 套图模式默认三种各一张 - 设置弹窗点击外部可关闭 - 历史记录删除按钮样式优化 Co-Authored-By: Claude Opus 4.7 --- src/features/ecommerce/EcommercePage.tsx | 47 +++++--- src/styles/ecommerce-standalone.css | 143 +++++++++++++++-------- 2 files changed, 120 insertions(+), 70 deletions(-) diff --git a/src/features/ecommerce/EcommercePage.tsx b/src/features/ecommerce/EcommercePage.tsx index fbed900..34f86a4 100644 --- a/src/features/ecommerce/EcommercePage.tsx +++ b/src/features/ecommerce/EcommercePage.tsx @@ -981,9 +981,9 @@ const cloneSetCountOptions: Array<{ ]; const cloneSetCountKeys = cloneSetCountOptions.map((option) => option.key); const defaultCloneSetCounts: Record = { - selling: 3, + selling: 1, white: 1, - scene: 3, + scene: 1, }; const minCloneSetTotal = 1; const maxCloneSetTotal = 16; @@ -1674,9 +1674,9 @@ function ProductClonePage(_props: ProductClonePageProps = {}) { const [selectedScenes, setSelectedScenes] = useState([]); useEffect(() => { - if (status === "done") { + if (status === "done" || status === "generating") { setIsCommandComposerCompact(true); - } else if (status === "generating" || status === "idle") { + } else if (status === "idle") { setIsCommandComposerCompact(false); } }, [status]); @@ -2623,6 +2623,12 @@ function ProductClonePage(_props: ProductClonePageProps = {}) { if (next.length === 0) { setStatus("idle"); setResults([]); + setCanvasNodes([]); + setIsCommandComposerCompact(false); + setPreviewOffset({ x: 0, y: 0 }); + previewOffsetRef.current = { x: 0, y: 0 }; + setPreviewZoom(1); + setActiveHistoryRecordId(null); } return next; }); @@ -3013,7 +3019,7 @@ function ProductClonePage(_props: ProductClonePageProps = {}) { const composer = commandComposerWrapRef.current; if (composer?.contains(target)) return; - if (composerMenu && composerMenu !== "settings") setComposerMenu(null); + if (composerMenu) setComposerMenu(null); if (status === "done" && !isCommandComposerCompact) setIsCommandComposerCompact(true); }; @@ -3629,6 +3635,7 @@ function ProductClonePage(_props: ProductClonePageProps = {}) { setDetailRequirement(""); setSelectedDetailModules(defaultDetailModuleIds); setDetailStatus("idle"); + setIsCommandComposerCompact(false); }; const activeToolMeta = sideTools.find((tool) => tool.key === activeTool); @@ -4655,25 +4662,27 @@ function ProductClonePage(_props: ProductClonePageProps = {}) { } }} > - {node.mode === "set" ? "套图" : node.mode === "detail" ? "详情图" : node.mode === "model" ? "模特图" : node.mode === "hot" ? "爆款图" : node.mode} {node.sourceImage ? ( - +
+ +
) : null}