修复个人页问题
This commit is contained in:
@@ -14,6 +14,8 @@ import {
|
||||
} from "@/components/UserInfo";
|
||||
import { UserService, UserInfoType } from "@/services/userService";
|
||||
import * as LoginService from "@/services/loginService";
|
||||
import CustomNavbar from "@/components/CustomNavbar";
|
||||
import { useGlobalState } from "@/store/global";
|
||||
|
||||
const OtherUserPage: React.FC = () => {
|
||||
// 获取页面参数
|
||||
@@ -28,6 +30,10 @@ const OtherUserPage: React.FC = () => {
|
||||
Taro.navigateBack();
|
||||
}
|
||||
|
||||
// 获取导航栏高度信息
|
||||
const { statusNavbarHeightInfo } = useGlobalState() || {};
|
||||
const { totalHeight = 98 } = statusNavbarHeightInfo || {};
|
||||
|
||||
// 模拟用户数据
|
||||
const [user_info, setUserInfo] = useState<Partial<UserInfoType>>({
|
||||
id: parseInt(user_id || "1") || 1,
|
||||
@@ -209,23 +215,19 @@ const OtherUserPage: React.FC = () => {
|
||||
|
||||
return (
|
||||
<View className="other_user_page">
|
||||
<View className="custom-navbar">
|
||||
<View className="detail-navigator">
|
||||
<View
|
||||
className="detail-navigator-back"
|
||||
onClick={() => {
|
||||
Taro.navigateBack();
|
||||
}}
|
||||
>
|
||||
<Image
|
||||
className="detail-navigator-back-icon"
|
||||
src={img.ICON_NAVIGATOR_BACK}
|
||||
/>
|
||||
<CustomNavbar>
|
||||
<View className="navbar_content">
|
||||
<View className="navbar_back" onClick={() => Taro.navigateBack()}>
|
||||
<View className="back_icon" />
|
||||
</View>
|
||||
<Text className="navbar_title"></Text>
|
||||
<View className="navbar_action">
|
||||
{/* 右侧占位,保持标题居中 */}
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
</CustomNavbar>
|
||||
{/* 主要内容 */}
|
||||
<View className="main_content">
|
||||
<View className="main_content" style={{ paddingTop: `${totalHeight}px` }}>
|
||||
{/* 用户信息区域 */}
|
||||
<View className="user_info_section">
|
||||
<UserInfoCard
|
||||
|
||||
Reference in New Issue
Block a user