From b49bf0f0f9fb249d22d67a3b480b0dfd7bc864c1 Mon Sep 17 00:00:00 2001 From: Blizzard Date: Tue, 4 Aug 2026 09:51:09 +0800 Subject: [PATCH] =?UTF-8?q?feat(fe):=20=E9=9A=90=E8=97=8F=E7=A4=BE?= =?UTF-8?q?=E5=8C=BA=20tab=EF=BC=88=E5=8F=AA=E7=95=99=E9=A6=96=E9=A1=B5/?= =?UTF-8?q?=E6=8A=A5=E5=91=8A/=E6=88=91=E7=9A=84=EF=BC=89+=20=E5=88=AB?= =?UTF-8?q?=E4=BA=BA=E4=B8=BB=E9=A1=B5=E5=85=B3=E6=B3=A8=E7=B2=89=E4=B8=9D?= =?UTF-8?q?=E4=B8=8D=E5=8F=AF=E5=86=8D=E7=82=B9=E5=BC=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - custom-tab-bar 去掉社区入口(页面与 app.json 注册保留,加回一行即可恢复) - profile-head 新增 relationsClickable,别人主页传 false:从关注/粉丝列表进对方 主页后,对方的关注/粉丝数字只展示不可点开,避免无限套娃;「我的」页不受影响 Co-Authored-By: Claude Opus 5 --- pets-fe/components/profile-head/index.js | 4 ++++ pets-fe/custom-tab-bar/index.js | 4 +++- pets-fe/pages/user/user.wxml | 3 ++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/pets-fe/components/profile-head/index.js b/pets-fe/components/profile-head/index.js index 9b32445..621aff0 100644 --- a/pets-fe/components/profile-head/index.js +++ b/pets-fe/components/profile-head/index.js @@ -8,6 +8,9 @@ Component({ // 装扮页的实时预览:只看效果,不要底部那排按钮 preview: { type: Boolean, value: false }, hideWall: { type: Boolean, value: false }, // 「我的」页藏掉社交宠物墙,避免和「我的毛孩子」卡重复 + // 关注/粉丝数字是否可点开列表。别人主页设 false:从关注/粉丝列表点进对方主页后, + // 不再允许打开对方的关注/粉丝,否则会无限套娃 + relationsClickable: { type: Boolean, value: true }, }, data: { initial: '', theme: 'warm' }, observers: { @@ -28,6 +31,7 @@ Component({ this.triggerEvent('decorate'); }, onRelations(e) { + if (!this.data.relationsClickable) return; // 别人主页:只看数字,不给点开列表 this.triggerEvent('relations', { kind: e.currentTarget.dataset.kind }); }, onPet(e) { diff --git a/pets-fe/custom-tab-bar/index.js b/pets-fe/custom-tab-bar/index.js index eb0883b..cf115d8 100644 --- a/pets-fe/custom-tab-bar/index.js +++ b/pets-fe/custom-tab-bar/index.js @@ -1,7 +1,9 @@ +// 社区 tab 暂时下线:从这里去掉入口即可(页面与 app.json 里的注册都保留, +// 需要恢复时把社区那行加回来就行) const LIST = [ { pagePath: '/pages/home/home', text: '首页', icon: 'home' }, { pagePath: '/pages/report/report', text: '报告', icon: 'report' }, - { pagePath: '/pages/community/community', text: '社区', icon: 'community' }, + // { pagePath: '/pages/community/community', text: '社区', icon: 'community' }, { pagePath: '/pages/mine/mine', text: '我的', icon: 'user' }, ]; diff --git a/pets-fe/pages/user/user.wxml b/pets-fe/pages/user/user.wxml index fee2bff..74772ed 100644 --- a/pets-fe/pages/user/user.wxml +++ b/pets-fe/pages/user/user.wxml @@ -9,7 +9,8 @@ module.exports.isUrl = function (s) { return s && s.indexOf('http') === 0; } 加载中… - +