修复 下拉刷新文字,文字大小问题

This commit is contained in:
张成
2025-11-30 20:19:06 +08:00
parent 6815eca84d
commit 42b05a6bc8
15 changed files with 48 additions and 31 deletions

View File

@@ -21,12 +21,12 @@
.btn {
flex: 1;
font-size: 14pt !important; // 14pt 加粗
font-size: 14px !important; // 14pt 加粗
font-weight: 600 !important; // 加粗
// 确保按钮内部文字也应用样式
:global(.nut-button__text) {
font-size: 14pt !important;
font-size: 14px !important;
font-weight: 600 !important;
}
}

View File

@@ -107,13 +107,18 @@
display: flex;
align-items: center;
margin-top: 8px;
column-gap: 4px;
// 只有当 left-section 存在时才添加间距
.left-section + .tags {
margin-left: 4px;
}
}
.left-section {
display: flex;
align-items: center;
gap: 8px;
flex-shrink: 0;
}
.avatar-group {
@@ -159,6 +164,9 @@
.tags {
display: flex;
gap: 4px;
flex: 1;
// 确保标签区域与文字左对齐,没有头像时无额外边距
margin-left: 0;
}
.tag {
@@ -249,7 +257,7 @@
// 设计稿位置 top: 38.62px, left: 10.62px,按比例缩放
top: 31.7px;
left: 8.7px;
z-index:2;
z-index: 2;
transform: rotate(-8deg);
}
}

View File

@@ -196,19 +196,21 @@ const ListCard: React.FC<ListCardProps> = ({
{/* 底部信息行:头像组、报名人数、技能等级、比赛类型 */}
<View className="bottom-info">
<View className="left-section">
<View className="avatar-group">
{(participantsImageList || []).map((item, index) => (
<View key={index} className="avatar">
<Image
className="avatar-image"
src={item?.user?.avatar_url}
mode="aspectFill"
/>
</View>
))}
{participantsImageList && participantsImageList.length > 0 && (
<View className="left-section">
<View className="avatar-group">
{participantsImageList.map((item, index) => (
<View key={index} className="avatar">
<Image
className="avatar-image"
src={item?.user?.avatar_url}
mode="aspectFill"
/>
</View>
))}
</View>
</View>
</View>
)}
<View className="tags">
<View className="tag">

View File

@@ -70,10 +70,10 @@
.organizer-actions {
display: flex;
flex: 0 0 90px;
align-items: center;
gap: 8px;
margin-left: auto;
flex-shrink: 0;
.organizer-actions-follow,
.organizer-actions-comment {
@@ -86,6 +86,7 @@
// border: 0.5px solid rgba(255, 255, 255, 0.10);
background: rgba(255, 255, 255, 0.16);
box-shadow: 0 4px 48px 0 rgba(0, 0, 0, 0.08);
white-space: nowrap;
& > image {
width: 16px;
@@ -102,6 +103,7 @@
font-weight: 500;
line-height: 20px; /* 153.846% */
letter-spacing: -0.23px;
white-space: nowrap;
}
}

View File

@@ -181,7 +181,7 @@ export default function OrganizerInfo(props) {
src={img.ICON_DETAIL_ARROW_RIGHT}
/>
</View>
<ScrollView className={styles["recommend-games-list"]} scrollX>
<ScrollView refresherBackground="#FAFAFA" className={styles["recommend-games-list"]} scrollX>
<View className={styles["recommend-games-list-content"]}>
{recommendGames.map((game, index) => (
<View

View File

@@ -349,7 +349,7 @@ export default function Participants(props) {
</View>
)}
{/* participants list */}
<ScrollView className={styles["participants-list-scroll"]} scrollX>
<ScrollView refresherBackground="#FAFAFA" className={styles["participants-list-scroll"]} scrollX>
<View
className={styles["participants-list-scroll-content"]}
style={{

View File

@@ -183,7 +183,7 @@ const TermsPage: React.FC = () => {
{/* 主要内容 */}
<ScrollView className="terms_main_content" scrollY>
<ScrollView className="terms_main_content" refresherBackground="#FAFAFA" scrollY>
{/* 条款标题 */}
<View className="terms_title">
{termsTitle}

View File

@@ -123,6 +123,8 @@ const ListPageContent: React.FC<ListPageContentProps> = ({
// ScrollView 滚动处理
const handleScrollViewScroll = useCallback(
(e: any) => {
const currentScrollTop = e?.detail?.scrollTop || 0;
const lastScrollTop = lastScrollTopRef.current;
const currentTime = Date.now();
@@ -252,6 +254,8 @@ const ListPageContent: React.FC<ListPageContentProps> = ({
};
const handleRefresh = async () => {
setRefreshing(true);
try {
await refreshMatches();
@@ -264,7 +268,7 @@ const ListPageContent: React.FC<ListPageContentProps> = ({
} finally {
// 使用 requestAnimationFrame 替代 setTimeout(0),性能更好
requestAnimationFrame(() => {
setRefreshing(false);
setRefreshing(false);
});
}
};
@@ -426,7 +430,7 @@ const ListPageContent: React.FC<ListPageContentProps> = ({
</View>
</View>
<ScrollView
<ScrollView refresherBackground="#FAFAFA"
ref={scrollViewRef}
scrollY
scrollTop={scrollTop}

View File

@@ -74,6 +74,7 @@
font-size: 16px;
line-height: 1.5;
color: #000000;
margin-top: 8px;
}
&.active {

View File

@@ -150,7 +150,7 @@ const MyselfPageContent: React.FC = () => {
// };
return (
<ScrollView scrollY className={styles.myselfPage}>
<ScrollView scrollY refresherBackground="#FAFAFA" className={styles.myselfPage}>
<View
className={styles.myselfPageContentMain}
style={{ paddingTop: `${totalHeight}px` }}

View File

@@ -18,7 +18,7 @@ useEffect(() => {
return (
<View className="terms_page">
{/* 主要内容 */}
<ScrollView className="football_rules_main_content" scrollY>
<ScrollView refresherBackground="#FAFAFA" className="football_rules_main_content" scrollY>
{/* 条款标题 */}
<View className="terms_title">

View File

@@ -262,7 +262,7 @@ const SelectStadium: React.FC<SelectStadiumProps> = ({
<Loading type="circular" className='loading-icon'></Loading>
</View>
) : (
<ScrollView className='stadium-list'
<ScrollView className='stadium-list' refresherBackground="#FAFAFA"
scrollWithAnimation
enhanced
showScrollbar={false}

View File

@@ -174,7 +174,7 @@ const StadiumDetail = forwardRef<StadiumDetailRef, StadiumDetailProps>(({
console.log(stadium,'stadiumstadium');
return (
<View className='stadium-detail'>
<ScrollView className='stadium-detail-scroll' scrollY={!openPicker}>
<ScrollView className='stadium-detail-scroll' refresherBackground="#FAFAFA" scrollY={!openPicker}>
{/* 已选球场 */}
<View
className={`stadium-item`}

View File

@@ -272,8 +272,8 @@ const MyselfPage: React.FC = () => {
</View>
{/* 球局列表 */}
<View className="game_list_section">
<ScrollView scrollY>
<View className="game_list_section" >
<ScrollView scrollY refresherBackground="#FAFAFA">
<ListContainer
data={game_records}
recommendList={[]}

View File

@@ -237,7 +237,7 @@ const OtherUserPage: React.FC = () => {
// };
return (
<ScrollView scrollY className="other_user_page">
<ScrollView scrollY className="other_user_page" refresherBackground="#FAFAFA">
{/* <CustomNavbar>
<View className="navbar_content">
<View className="navbar_back" onClick={() => Taro.navigateBack()}>
@@ -294,7 +294,7 @@ const OtherUserPage: React.FC = () => {
{/* 球局列表 */}
{/* <View className="game_list_section"> */}
<ScrollView scrollY>
<ScrollView scrollY refresherBackground="#FAFAFA">
<ListContainer
data={game_records}
recommendList={[]}
@@ -337,7 +337,7 @@ const OtherUserPage: React.FC = () => {
{/* 球局列表 */}
{/* <View className="game_list_section"> */}
<ScrollView scrollY>
<ScrollView scrollY refresherBackground="#FAFAFA">
<ListContainer
data={ended_game_records}
recommendList={[]}