Phone hub folds: emergency ops, market toolbar, calc tabs, OKX options.

Collapse bulky monitor/market controls by default on phone, show OKX options on tiles, add calculator tab switch, and request landscape on market fullscreen.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-07-15 22:56:02 +08:00
parent f16dcac202
commit 8838f1f221
5 changed files with 387 additions and 72 deletions
+151
View File
@@ -4035,6 +4035,38 @@ body.login-page {
}
}
/* —— 可折叠条:桌面/平板始终展开(隐藏 summary) —— */
.hub-m-fold {
margin: 0 0 12px;
border: none;
background: transparent;
padding: 0;
}
.hub-m-fold > .hub-m-fold-summary {
display: none;
list-style: none;
}
.hub-m-fold > .hub-m-fold-summary::-webkit-details-marker {
display: none;
}
.calc-mobile-tabs {
display: none;
}
.card-stat-chip.card-stat-options {
border-color: rgba(0, 212, 255, 0.35);
color: var(--accent, #6ea8ff);
background: rgba(0, 212, 255, 0.08);
}
.hub-tile-opt {
color: var(--accent, #6ea8ff) !important;
font-weight: 500;
}
/* —— 手机壳:底栏四件套(仅 ≤720px;桌面/平板完全不进此规则) —— */
.hub-mobile-tabbar,
.hub-mobile-more {
@@ -4370,6 +4402,125 @@ body.login-page {
font-size: 13px;
}
/* 手机折叠条 */
body.hub-phone .hub-m-fold {
margin: 0 0 10px;
border: 1px solid var(--border);
border-radius: var(--radius);
background: var(--panel);
overflow: hidden;
}
body.hub-phone .hub-m-fold > .hub-m-fold-summary {
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
padding: 10px 12px;
cursor: pointer;
font-size: 13px;
font-weight: 600;
color: var(--text);
-webkit-tap-highlight-color: transparent;
}
body.hub-phone .hub-m-fold > .hub-m-fold-summary::after {
content: "▾";
color: var(--muted);
font-size: 12px;
transition: transform 0.15s;
}
body.hub-phone .hub-m-fold[open] > .hub-m-fold-summary::after {
transform: rotate(180deg);
}
body.hub-phone .hub-m-fold-meta {
flex: 1 1 auto;
min-width: 0;
text-align: right;
font-size: 10px;
font-weight: 500;
font-family: var(--mono);
color: var(--muted);
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
body.hub-phone .hub-m-fold .toolbar,
body.hub-phone .hub-m-fold .market-toolbar {
margin-bottom: 0;
border: none;
border-top: 1px solid var(--border-soft);
border-radius: 0;
box-shadow: none;
}
/* 计算器手机 Tab */
body.hub-phone .calc-mobile-tabs {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 6px;
margin: 0 0 10px;
}
body.hub-phone .calc-m-tab {
min-height: 38px;
border: 1px solid var(--border-soft);
border-radius: 10px;
background: var(--nav-bg, rgba(255, 255, 255, 0.03));
color: var(--muted);
font: inherit;
font-size: 13px;
font-weight: 600;
cursor: pointer;
}
body.hub-phone .calc-m-tab.is-active {
color: var(--accent, #6ea8ff);
border-color: color-mix(in srgb, var(--accent, #6ea8ff) 45%, var(--border-soft));
background: var(--accent-dim, rgba(110, 168, 255, 0.12));
}
body.hub-phone .calc-layout[data-calc-tab="trend"] [data-calc-pane="roll"],
body.hub-phone .calc-layout[data-calc-tab="roll"] [data-calc-pane="trend"] {
display: none;
}
body.hub-phone .calc-layout {
grid-template-columns: 1fr;
}
body.hub-phone #page-calculator .calc-card h2 {
display: none;
}
/* 行情全屏:竖屏提示转横;横屏吃满 */
@media (orientation: portrait) {
body.hub-phone.market-chart-fs-open .market-chart-wrap.is-fullscreen::before {
content: "全屏看图请横持手机";
position: absolute;
top: max(10px, env(safe-area-inset-top));
left: 50%;
transform: translateX(-50%);
z-index: 5;
padding: 6px 12px;
border-radius: 999px;
background: rgba(0, 0, 0, 0.72);
color: #fff;
font-size: 12px;
pointer-events: none;
}
}
@media (orientation: landscape) {
body.hub-phone.market-chart-fs-open .app-header,
body.hub-phone.market-chart-fs-open .hub-mobile-tabbar {
display: none !important;
}
}
.hub-mobile-tabbar {
display: flex;
position: fixed;