修复bug

This commit is contained in:
李瑞
2025-10-12 23:49:02 +08:00
parent 35dfc7ffc8
commit 12600ebdfb
12 changed files with 45 additions and 33 deletions

View File

@@ -39,7 +39,6 @@ const FilterPopup = (props: FilterPopupProps) => {
// const [selectedDates, setSelectedDates] = useState<String[]>([])
const handleDateChange = (dates: Date[]) => {
console.log(dates,'datesdatesdatesdatesdates');
let times: String[] = [];
if (Array.isArray(dates)) {
const currentDay = dayjs(dates[0]).format('YYYY-MM-DD');
@@ -129,6 +128,11 @@ const FilterPopup = (props: FilterPopupProps) => {
showRangeStart={false}
value={filterOptions?.dateRange}
onChange={handleDateChange}
style={{
bottom: '25%',
width: 'calc(100vw - 32px)',
left: '16px',
}}
/>
</View>
{/* 时间气泡选项 */}

View File

@@ -3,7 +3,7 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 400px;
height: calc(100vh - 94px - 72px - 110px);
.listLoadErrorImg {
width: 154px;

View File

@@ -1,4 +1,4 @@
import { Image, View, Text, Button } from "@tarojs/components";
import { Image, View, Text } from "@tarojs/components";
import styles from "./index.module.scss";
import img from "@/config/images";
@@ -24,10 +24,10 @@ const ListLoadError = (props: IProps) => {
/>
{text && <Text className={styles.listLoadErrorText}>{text}</Text>}
{reload && (
<Button className={styles.listLoadErrorBtn} onClick={handleReload}>
<View className={styles.listLoadErrorBtn} onClick={handleReload}>
<Image src={btnImg ? img[btnImg] : img?.ICON_LIST_RELOAD} className={styles.reloadIcon} />
{btnText ? " " + btnText : "重试"}
</Button>
</View>
)}
</View>
);

View File

@@ -19,6 +19,7 @@ interface NutUICalendarProps {
showQuickActions?: boolean;
onHeaderClick?: (date: Date) => void;
showRangeStart?: boolean;
style?: React.CSSProperties;
}
export interface CalendarUIRef {
@@ -36,6 +37,7 @@ const NutUICalendar = React.forwardRef<CalendarUIRef, NutUICalendarProps>(
showRangeStart = true,
showQuickActions = true,
onHeaderClick,
style,
},
ref
) => {
@@ -281,6 +283,7 @@ const NutUICalendar = React.forwardRef<CalendarUIRef, NutUICalendarProps>(
value={[current.getFullYear(), current.getMonth() + 1]}
type="month"
onChange={(value) => handleMonthChange(value)}
style={style}
/>
)}
</View>

View File

@@ -25,6 +25,7 @@ interface PickerProps {
img?: string;
onConfirm?: (options: PickerOption[], values: (string | number)[]) => void;
onChange?: (value: (string | number)[]) => void;
style?: React.CSSProperties
}
const PopupPicker = ({
@@ -36,6 +37,7 @@ const PopupPicker = ({
onChange,
options = [],
type = null,
style,
}: PickerProps) => {
const [defaultValue, setDefaultValue] = useState<(string | number)[]>([]);
const [defaultOptions, setDefaultOptions] = useState<PickerOption[][]>([]);
@@ -106,6 +108,7 @@ const PopupPicker = ({
position="bottom"
round
zIndex={1000}
style={style}
>
{type === "ntrp" && (
<View className={styles.evaluateCardWrap}>

View File

@@ -487,8 +487,8 @@ const ShareCardCanvas: React.FC<ShareCardCanvasProps> = ({
// 绘制用户昵称 已完成
const nicknameX = avatarX + avatarSize + 8 * dpr // 距离头像8px
const nicknameY = avatarY + (avatarSize - 24 * dpr) / 2 // 与头像水平居中对齐
const nicknameFontSize = scale * 24 * dpr
const nicknameY = avatarY + (avatarSize - 18 * dpr) / 2 // 与头像水平居中对齐
const nicknameFontSize = scale * 18 * dpr
drawText(ctx, data.userNickname, nicknameX, nicknameY, 200 * dpr, nicknameFontSize, '#000000', true, '"Noto Sans SC"')
// 绘制"邀你加入球局"文案
@@ -669,8 +669,8 @@ const ShareCardCanvas: React.FC<ShareCardCanvasProps> = ({
width: `${canvasWidth}px`,
height: `${canvasHeight}px`,
position: 'absolute', // 绝对定位避免影响布局
top: '-9999px', // 移出可视区域
left: '-9999px'
// top: '-9999px', // 移出可视区域
// left: '-9999px'
}}
width={`${canvasWidth * dpr}`}
height={`${canvasHeight * dpr}`}