This commit is contained in:
oneao committed 2026-02-04 22:42:00 +08:00
1 parent ba9ce9e81b
commit 2b76078a77
2 files changed
+95 -203

No files matched your search

@@ -1,7 +1,7 @@
import SegmentedControl from '@react-native-segmented-control/segmented-control'
import { DateRangePicker } from '@yz1311/react-native-wheel-picker'
import { useEffect, useState } from 'react'
import { Text, View } from 'react-native'
import { ScrollView, Text, View } from 'react-native'
import Button from './Button'
import Drawer from './Drawer'
import Tab from './Tab'
@@ -47,12 +47,10 @@ export default function DateMorePicker({
showHeader={false}
height="60%"
>
{/* 外层必须 flex:1 */}
<View className="flex-1 p-3">
{/* ===== 顶部固定区域 ===== */}
<View
className="gap-2"
style={{ flexShrink: 0, height: 200 }}
style={{ flexShrink: 0 }}
>
<View>
<Text className="text-lg mb-1">快速选择</Text>
@@ -82,22 +80,20 @@ export default function DateMorePicker({
</View>
</View>
{/* ===== 中间:吃掉剩余高度 ===== */}
<View style={{ flex: 1, justifyContent: 'center' }}>
<ScrollView
style={{ flex: 1 }}
showsVerticalScrollIndicator={false}
showsHorizontalScrollIndicator={false}
>
<DateRangePicker
isModal={false}
showHeader={false}
pickerWrapperStyle={{
height: 24,
minHeight: 24,
}}
/>
</View>
</ScrollView>
{/* ===== 底部固定按钮 ===== */}
<View
className="flex-row gap-3 pt-2"
style={{ flexShrink: 0, height: 100 }}
style={{ flexShrink: 0 }}
>
<Button className="flex-1" variant="outline" onPress={handleClose}>
取消