mama-box: 退出按钮改卡片右上角绝对定位 + 仅已登录(userName)时显示 (v26090707)
This commit is contained in:
15
index.html
15
index.html
@@ -6,8 +6,8 @@
|
||||
<meta name="theme-color" content="#F4593C">
|
||||
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||
<title>妈妈盒子 · 孕育陪伴</title>
|
||||
<!-- V:26090706 缓存版本标记:改 css/js 时同步 bump 该值,并给下方资源引用加 ?v= 以强制 webview 刷新子资源 -->
|
||||
<link rel="stylesheet" href="mama-box.css?v=26090706">
|
||||
<!-- V:26090707 缓存版本标记:改 css/js 时同步 bump 该值,并给下方资源引用加 ?v= 以强制 webview 刷新子资源 -->
|
||||
<link rel="stylesheet" href="mama-box.css?v=26090707">
|
||||
<script src="https://res.wx.qq.com/open/js/jweixin-1.6.0.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
@@ -761,8 +761,9 @@
|
||||
谁要是把那行加回来,会把连续记录天数冲掉,而且是静默的。 -->
|
||||
<p>已连续记录 <b>42</b> 天</p>
|
||||
</div>
|
||||
<!-- 右侧:退出登录图标按钮(清除本机身份 → 重新授权测试)+ 尖括号提示卡可点 -->
|
||||
<button class="icon-btn plain me-exit" id="meLogoutBtn" aria-label="退出登录">
|
||||
<!-- 退出登录图标按钮:默认隐藏,applyRemoteProfile 确认已登录(有 userName)才显示。
|
||||
绝对定位在卡片右上角(尖括号左边);stopPropagation 防止触发资料弹窗 -->
|
||||
<button class="icon-btn plain me-exit" id="meLogoutBtn" aria-label="退出登录" style="display:none">
|
||||
<svg viewBox="0 0 24 24" width="19" height="19" aria-hidden="true">
|
||||
<path d="M14 5h5a1.5 1.5 0 0 1 1.5 1.5v11A1.5 1.5 0 0 1 19 19h-5" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round"/>
|
||||
<path d="M10 12H3m0 0 3.5-3.5M3 12l3.5 3.5" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
@@ -1757,8 +1758,8 @@
|
||||
加载失败/离线时 window.wx 为 undefined,goMall() 会降级为 toast 提示,
|
||||
不影响应用其余功能。 -->
|
||||
|
||||
<script src="js/app.js?v=26090706"></script>
|
||||
<!-- 页面版本号(排查 webview 缓存):底部会显示 v26090706 -->
|
||||
<div id="ver" style="position:fixed;left:0;right:0;bottom:10px;text-align:center;z-index:9999;pointer-events:none;color:#B3A69C;font-size:10px;letter-spacing:.5px">v26090706</div>
|
||||
<script src="js/app.js?v=26090707"></script>
|
||||
<!-- 页面版本号(排查 webview 缓存):底部会显示 v26090707 -->
|
||||
<div id="ver" style="position:fixed;left:0;right:0;bottom:10px;text-align:center;z-index:9999;pointer-events:none;color:#B3A69C;font-size:10px;letter-spacing:.5px">v26090707</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -3994,6 +3994,8 @@
|
||||
if (_aw) _aw.classList.add('has-img');
|
||||
}
|
||||
var _box = $('#meAuthBox'); if (_box) _box.style.display = _auth ? 'none' : '';
|
||||
/* 退出按钮只在已登录(有 userName)时显示 —— 未登录"退出"没有意义 */
|
||||
var _lx = $('#meLogoutBtn'); if (_lx) _lx.style.display = p.userName ? '' : 'none';
|
||||
if (!p.userName) { var _ai2 = $('#meAvatarImg'); if (_ai2) _ai2.removeAttribute('src'); }
|
||||
}
|
||||
if (pg && pg.code === 200 && pg.result) {
|
||||
|
||||
10
mama-box.css
10
mama-box.css
@@ -1556,10 +1556,12 @@ a.skip:focus{left:16px;top:16px}
|
||||
position:relative;z-index:2;overflow:hidden;cursor:pointer;transition:transform .18s var(--ease)}
|
||||
.me-card:active{transform:scale(.985)}
|
||||
/* 尖括号跟全站 .chev 一个灰度,别再用白色 */
|
||||
.me-chev{flex:0 0 auto;font-style:normal;font-size:24px;line-height:1;color:#C9BFB8;margin-left:6px}
|
||||
/* 退出登录图标按钮(住 me-card 右上角,尖括号左边)。
|
||||
⚠️ 退出按钮接管了 margin-left:auto 把自己推到最右,chev 改普通间距跟在后面。 */
|
||||
.me-exit{margin-left:auto;color:#C9BFB8;flex:0 0 auto}
|
||||
.me-chev{margin-left:auto;flex:0 0 auto;font-style:normal;font-size:24px;line-height:1;color:#C9BFB8}
|
||||
/* 退出登录图标按钮:住 me-card **右上角**(绝对定位,不占 flex 流)。
|
||||
⚠️ 只在已登录时显示(applyRemoteProfile 按 p.userName 控制显隐);
|
||||
未登录显示"退出"没有意义。chev 恢复 margin-left:auto 占最右。 */
|
||||
.me-card{position:relative}
|
||||
.me-exit{position:absolute;top:10px;right:44px;color:#C9BFB8;flex:0 0 auto}
|
||||
.me-exit:active{color:#C33A2E}
|
||||
/* 头像底从「白蒙版 + 白描边」换成暖橘底 + 品牌色剪影(与 .pc-ico 同一套配色)。
|
||||
⚠️ 外圈本批从 #FFF3EC 改回了纯 #fff。那圈浅橘白光晕本来是照着
|
||||
|
||||
Reference in New Issue
Block a user