From 886ef82573430666e55df8a8c1d42cdfeb5ae56e Mon Sep 17 00:00:00 2001 From: dekun Date: Sun, 4 Oct 2026 06:58:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=AD=E6=8E=A7=E5=86=85=E5=B5=8C=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E5=8F=B0=E5=B8=A6=E9=B1=BC=E5=B1=8F=E9=93=BA=E6=BB=A1?= =?UTF-8?q?=E5=AE=BD=E5=BA=A6=EF=BC=8C=E7=8B=AC=E7=AB=8B=E6=89=93=E5=BC=80?= =?UTF-8?q?=E4=BB=8D=E4=BF=9D=E6=8C=81=201920=20=E5=B1=85=E4=B8=AD?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Cursor --- lib/common/static/instance_page.css | 13 ++++++++++++- lib/instance/templates/embed_shell.html | 2 +- lib/instance/templates/index.html | 2 +- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/lib/common/static/instance_page.css b/lib/common/static/instance_page.css index f54458d..0b4f628 100644 --- a/lib/common/static/instance_page.css +++ b/lib/common/static/instance_page.css @@ -6,6 +6,13 @@ body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;background:#0b0d14;color:#eaeaea;padding:14px 12px} /* 1920 左右用满:约 96vw / 1840,两侧留白更小 */ .container{width:100%;max-width:min(1840px,96vw);margin:0 auto;padding:0 clamp(6px,1vw,14px)} + /* 中控工作台内嵌:铺满 iframe,不受带鱼屏 1920 居中限制 */ + body[data-embed-shell="1"] .container{ + max-width:none; + width:100%; + margin:0; + padding:0 clamp(6px,1vw,14px); + } .header{display:flex;flex-direction:column;align-items:center;gap:8px;margin-bottom:12px} .header h1{font-size:1.75rem;color:#dbe4ff;text-align:center;line-height:1.25} .exchange-tag{font-size:.82rem;font-weight:600;color:#b8f5d0;background:#14241e;border:1px solid #2d6a4f;padding:5px 14px;border-radius:999px;letter-spacing:.06em} @@ -168,7 +175,7 @@ .panel-scroll,.pos-list{max-height:420px} .records-card .table-wrap{max-height:620px;overflow:auto} } - /* 带鱼屏(宽高比≥21:9):整页固定 1920 居中;不依赖视口宽度(避免 Win 缩放后失效) */ + /* 带鱼屏(宽高比≥21:9):独立打开时固定 1920 居中;中控内嵌仍全宽 */ @media (min-aspect-ratio: 21/9) { .container{ width:100%; @@ -176,6 +183,10 @@ margin-left:auto; margin-right:auto; } + body[data-embed-shell="1"] .container{ + max-width:none; + margin:0; + } } @media (min-width: 2560px){ .dual-panel-grid{gap:18px} diff --git a/lib/instance/templates/embed_shell.html b/lib/instance/templates/embed_shell.html index b31fa0c..9e06848 100644 --- a/lib/instance/templates/embed_shell.html +++ b/lib/instance/templates/embed_shell.html @@ -8,7 +8,7 @@ - + diff --git a/lib/instance/templates/index.html b/lib/instance/templates/index.html index 8665f3d..e863262 100644 --- a/lib/instance/templates/index.html +++ b/lib/instance/templates/index.html @@ -18,7 +18,7 @@ {{ pwa_app_name }} - +