fix(explore-cards): update scroll view props for horizontal scroll

replace outdated overflow-x-autoshow-scrollbar prop with scroll-x and show-scrollbar="false" to enable proper horizontal scrolling and hide the scrollbar
This commit is contained in:
duanshuwen
2026-07-25 11:38:10 +08:00
parent cd307da2ff
commit 04a7acc8b3
6 changed files with 6 additions and 6 deletions

View File

@@ -1,6 +1,6 @@
<template> <template>
<view> <view>
<view class="quick-access flex flex-row ml-[12px] pt-[8px] pb-[8px] overflow-x-autowhitespace-nowrap"> <view class="quick-access flex flex-row ml-[12px] pt-[8px] pb-[8px] overflow-x-auto whitespace-nowrap">
<view class="item rounded-[50px] flex flex-row items-center" v-for="(item, index) in itemList" :key="index" <view class="item rounded-[50px] flex flex-row items-center" v-for="(item, index) in itemList" :key="index"
@click="sendReply(item)"> @click="sendReply(item)">
<view class="flex items-center justify-center"> <view class="flex items-center justify-center">

View File

@@ -2,7 +2,7 @@
<view class="container"> <view class="container">
<ModuleTitle :title="recommendTheme.themeName" /> <ModuleTitle :title="recommendTheme.themeName" />
<view class="container-scroll text-[0px] overflow-x-autowhitespace-nowrap"> <view class="container-scroll text-[0px] overflow-x-auto whitespace-nowrap">
<view class="card-item bg-white inline-block rounded-[20px] mr-[8px]" <view class="card-item bg-white inline-block rounded-[20px] mr-[8px]"
v-for="(item, index) in recommendTheme.recommendPostsList" :key="index" @click="sendReply(item)"> v-for="(item, index) in recommendTheme.recommendPostsList" :key="index" @click="sendReply(item)">
<view class="m-[4px] relative"> <view class="m-[4px] relative">

View File

@@ -1,6 +1,6 @@
<template> <template>
<view class="recommendation-list-card w-full"> <view class="recommendation-list-card w-full">
<scroll-view class="recommendation-list-card__scroll overflow-x-autowhitespace-nowrap w-full" scroll-x <scroll-view class="recommendation-list-card__scroll overflow-x-auto whitespace-nowrap w-full" scroll-x
:show-scrollbar="false" enhanced> :show-scrollbar="false" enhanced>
<view v-for="item in items" :key="item.id || item.title" <view v-for="item in items" :key="item.id || item.title"
class="recommendation-list-card__item inline-block bg-white rounded-[20px] overflow-hidden" class="recommendation-list-card__item inline-block bg-white rounded-[20px] overflow-hidden"

View File

@@ -1,6 +1,6 @@
<template> <template>
<view class="explore-cards"> <view class="explore-cards">
<scroll-view class="explore-scroll" overflow-x-autoshow-scrollbar="false"> <scroll-view class="explore-scroll" scroll-x show-scrollbar="false">
<view class="explore-track"> <view class="explore-track">
<view v-for="(item, index) in normalizedList" :key="getItemKey(item, index)" class="explore-card" <view v-for="(item, index) in normalizedList" :key="getItemKey(item, index)" class="explore-card"
:class="`is-${item.tone}`" hover-class="is-pressed" hover-stay-time="80" :class="`is-${item.tone}`" hover-class="is-pressed" hover-stay-time="80"

View File

@@ -1,5 +1,5 @@
<template> <template>
<scroll-view class="prompt-strip" overflow-x-autoshow-scrollbar="false"> <scroll-view class="prompt-strip" scroll-x show-scrollbar="false">
<view class="prompt-track"> <view class="prompt-track">
<view v-for="(item, index) in normalizedList" :key="getItemKey(item, index)" class="prompt-card" <view v-for="(item, index) in normalizedList" :key="getItemKey(item, index)" class="prompt-card"
hover-class="is-pressed" hover-stay-time="80" @tap="handleTap(item.raw, index)"> hover-class="is-pressed" hover-stay-time="80" @tap="handleTap(item.raw, index)">

View File

@@ -1,6 +1,6 @@
<template> <template>
<view class="container pl-[12px]"> <view class="container pl-[12px]">
<view class="container-scroll text-[0px] overflow-x-autowhitespace-nowrap"> <view class="container-scroll text-[0px] overflow-x-auto whitespace-nowrap">
<view class="card-item bg-white inline-block rounded-[20px] mr-[10px]" v-for="(item, index) in list" :key="index" <view class="card-item bg-white inline-block rounded-[20px] mr-[10px]" v-for="(item, index) in list" :key="index"
@click="sendReply(item)"> @click="sendReply(item)">