|
|
@@ -9,6 +9,7 @@ import NewTimePicker from "../base/new_timepicker";
|
|
|
import { IconCalendar } from "@/components/basic/Icons";
|
|
|
import dayjs from "dayjs";
|
|
|
import { useRouter } from "@tarojs/taro";
|
|
|
+import Card from "../components/card";
|
|
|
|
|
|
let useRoute;
|
|
|
let useNavigation;
|
|
|
@@ -42,59 +43,60 @@ export default function LogTime() {
|
|
|
useEffect(() => {
|
|
|
|
|
|
}, [])
|
|
|
- return <View>
|
|
|
- <View className='picker_time_card'>
|
|
|
- <View className='picker_time_card_header' style={{ backgroundColor: '#fff' }}>
|
|
|
- <View style={{ flex: 1 }} />
|
|
|
- <NewButton
|
|
|
- type={NewButtonType.gray}
|
|
|
- title={isToday ? "Today" : "Yesterday"}
|
|
|
- fontSize={rpxToPx(34)}
|
|
|
- width={rpxToPx(196)}
|
|
|
- height={rpxToPx(84)}
|
|
|
- onClick={() => {
|
|
|
- setIsToday(!isToday)
|
|
|
- }}
|
|
|
- />
|
|
|
- <View style={{ width: rpxToPx(12) }} />
|
|
|
- <NewButton
|
|
|
- type={NewButtonType.alpha}
|
|
|
- color={getThemeColor('FAST')}
|
|
|
- title={time}
|
|
|
- fontSize={rpxToPx(34)}
|
|
|
- width={rpxToPx(196)}
|
|
|
- height={rpxToPx(84)}
|
|
|
- onClick={() => {
|
|
|
+ return <View className="page_container">
|
|
|
+ <Card>
|
|
|
+ <View style={{ position: 'relative' }}>
|
|
|
+ <View className="card_header">
|
|
|
+ <View style={{ flex: 1 }} />
|
|
|
+ <NewButton
|
|
|
+ type={NewButtonType.gray}
|
|
|
+ title={isToday ? "Today" : "Yesterday"}
|
|
|
+ fontSize={rpxToPx(34)}
|
|
|
+ width={rpxToPx(196)}
|
|
|
+ height={rpxToPx(84)}
|
|
|
+ onClick={() => {
|
|
|
+ setIsToday(!isToday)
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ <View style={{ width: rpxToPx(12) }} />
|
|
|
+ <NewButton
|
|
|
+ type={NewButtonType.alpha}
|
|
|
+ color={getThemeColor('FAST')}
|
|
|
+ title={time}
|
|
|
+ fontSize={rpxToPx(34)}
|
|
|
+ width={rpxToPx(196)}
|
|
|
+ height={rpxToPx(84)}
|
|
|
+ onClick={() => {
|
|
|
|
|
|
- }}
|
|
|
- />
|
|
|
- <View style={{ flex: 1 }} />
|
|
|
- {
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ <View style={{ flex: 1 }} />
|
|
|
<View className='border_footer_line' />
|
|
|
- }
|
|
|
- </View>
|
|
|
- {
|
|
|
+ </View>
|
|
|
+
|
|
|
<NewTimePicker time={time} onChange={(e) => {
|
|
|
setTime(e)
|
|
|
}} color={getThemeColor(health.mode)} />
|
|
|
- }
|
|
|
- {
|
|
|
- <View className='picker_time_card_footer'>
|
|
|
+
|
|
|
+ <View className='card_footer'>
|
|
|
<IconCalendar width={rpxToPx(24)} color='#5C7099' />
|
|
|
<Text style={{ color: '#5C7099', marginLeft: rpxToPx(12), fontSize: rpxToPx(26) }}>Scheduled for xxx today</Text>
|
|
|
</View>
|
|
|
- }
|
|
|
+ </View>
|
|
|
+ </Card>
|
|
|
+ <View style={{ flex: 1 }} />
|
|
|
+ <View style={{ marginBottom: rpxToPx(128), display: 'flex', alignItems: 'center', justifyContent: 'center' }}>
|
|
|
+ <NewButton
|
|
|
+ color={getThemeColor('FAST')}
|
|
|
+ type={NewButtonType.fill}
|
|
|
+ title={'Log'}
|
|
|
+ width={rpxToPx(670)}
|
|
|
+ height={rpxToPx(96)}
|
|
|
+ bold={true}
|
|
|
+ onClick={() => {
|
|
|
|
|
|
+ }} />
|
|
|
</View>
|
|
|
- <NewButton
|
|
|
- color={getThemeColor('FAST')}
|
|
|
- type={NewButtonType.fill}
|
|
|
- title={'Log'}
|
|
|
- width={rpxToPx(670)}
|
|
|
- height={rpxToPx(96)}
|
|
|
- bold={true}
|
|
|
- onClick={() => {
|
|
|
|
|
|
- }} />
|
|
|
</View>
|
|
|
}
|