@ledvance/ui-biz-bundle 1.1.90 → 1.1.91

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/package.json +1 -1
  2. package/src/modules/flags/FlagEditPage.tsx +180 -179
  3. package/src/modules/flags/FlagItem.tsx +26 -42
  4. package/src/modules/flags/FlagPage.tsx +27 -26
  5. package/src/modules/history/HistoryPage.tsx +111 -103
  6. package/src/modules/music/MusicPage.tsx +90 -88
  7. package/src/modules/timer/TimerPage.tsx +13 -9
  8. package/src/newModules/biorhythm/BiorhythmEditPage.tsx +54 -54
  9. package/src/newModules/biorhythm/BiorhythmPage.tsx +163 -162
  10. package/src/newModules/biorhythm/IconSelect.tsx +5 -4
  11. package/src/newModules/childLock/ChildLockPage.tsx +49 -47
  12. package/src/newModules/energyConsumption/component/EnergyModal.tsx +2 -2
  13. package/src/newModules/fixedTime/FixedTimeDetailPage.tsx +127 -124
  14. package/src/newModules/fixedTime/FixedTimePage.tsx +108 -104
  15. package/src/newModules/lightMode/LightModePage.tsx +74 -67
  16. package/src/newModules/mood/AddMoodPage.tsx +18 -15
  17. package/src/newModules/mood/DynamicMoodEditorPage.tsx +103 -100
  18. package/src/newModules/mood/MixDynamicMoodEditor.tsx +107 -104
  19. package/src/newModules/mood/MoodItem.tsx +59 -55
  20. package/src/newModules/mood/MoodPage.tsx +58 -57
  21. package/src/newModules/mood/RecommendMoodItem.tsx +27 -24
  22. package/src/newModules/mood/StaticMoodEditorPage.tsx +77 -85
  23. package/src/newModules/overchargeSwitch/OverchargeSwitchPage.tsx +36 -48
  24. package/src/newModules/powerOnBehavior/LightBehaviorPage.tsx +137 -135
  25. package/src/newModules/powerOnBehavior/PlugBehaviorPage.tsx +67 -61
  26. package/src/newModules/randomTime/RandomTimeDetailPage.tsx +114 -151
  27. package/src/newModules/randomTime/RandomTimePage.tsx +110 -105
  28. package/src/newModules/randomTime/Summary.tsx +61 -57
  29. package/src/newModules/remoteControl/RemoteControlPage.tsx +4 -3
  30. package/src/newModules/select/SelectPage.tsx +65 -62
  31. package/src/newModules/sleepWakeUp/SleepWakeUpActions.ts +16 -8
  32. package/src/newModules/sleepWakeUp/SleepWakeUpDetailPage.tsx +131 -123
  33. package/src/newModules/sleepWakeUp/SleepWakeUpPage.tsx +144 -140
  34. package/src/newModules/switchGradient/SwitchGradientPage.tsx +24 -25
  35. package/src/newModules/swithInching/SwithInching.tsx +154 -152
  36. package/src/newModules/timeSchedule/TimeScheduleDetailPage.tsx +83 -83
  37. package/src/newModules/timeSchedule/components/ManuaSettings.tsx +3 -2
  38. package/src/newModules/swithInching/pickerView.tsx +0 -91
@@ -1,91 +0,0 @@
1
- import React from 'react'
2
- import { StyleProp, StyleSheet, View, ViewStyle, Text } from 'react-native'
3
- import { Picker, Utils } from 'tuya-panel-kit'
4
- import _ from 'lodash'
5
-
6
- const { convertX } = Utils.RatioUtils
7
-
8
- const hours = _.times(61, (n) => _.padStart(n.toString(), 2, '0'))
9
- const minutes = _.times(61, (n) => _.padStart(n.toString(), 2, '0'))
10
- const pickerTheme = {
11
- fontSize: 20,
12
- }
13
-
14
- interface LdvPickerViewProps {
15
- hour: string,
16
- minute: string,
17
- setHour: (string) => void,
18
- setMinute: (string) => void,
19
- style?: StyleProp<ViewStyle> | undefined,
20
- unit?:string[]
21
- }
22
-
23
- const LdvPickerView = (props: LdvPickerViewProps) => {
24
-
25
- const { hour, minute, unit, setHour, setMinute } = props
26
-
27
- return (
28
- <View style={[styles.pickerContainer, props.style]}>
29
- <View style={styles.picContainer}>
30
- <Picker
31
- style={[styles.picker, styles.pickerLeft]}
32
- theme={pickerTheme}
33
- itemStyle={styles.pickerItem}
34
- textSize={convertX(14)}
35
- selectedValue={hour}
36
- itemAlign={'center'}
37
- onValueChange={value => setHour(value as string)}>
38
- {hours.map((value) => (
39
- <Picker.Item key={value} value={value} label={value} />
40
- ))}
41
- </Picker>
42
- {unit ? <View style={styles.pickerUnit}>
43
- <Text style={{ color: '#000', fontSize: convertX(18) }}>
44
- {unit[0]}
45
- </Text>
46
- </View> : null}
47
- </View>
48
- <View style={styles.picContainer}>
49
- <Picker
50
- style={[styles.picker, styles.pickerLeft]}
51
- theme={pickerTheme}
52
- itemStyle={styles.pickerItem}
53
- textSize={convertX(14)}
54
- selectedValue={minute}
55
- onValueChange={value => setMinute(value as string)}>
56
- {minutes.map((value) => (
57
- <Picker.Item key={value} value={value} label={value} />
58
- ))}
59
- </Picker>
60
- {unit ? <View style={styles.pickerUnit}>
61
- <Text style={{ color: '#000', fontSize: convertX(18) }}>
62
- {unit[1]}
63
- </Text>
64
- </View> : null}
65
- </View>
66
- </View>
67
- )
68
- }
69
-
70
- const styles = StyleSheet.create({
71
- pickerContainer: {
72
- flexDirection: 'row',
73
- alignItems: 'center',
74
- },
75
- picker: {
76
- flex: 1,
77
- },
78
- pickerLeft: {},
79
- pickerItem: {},
80
- picContainer: {
81
- flex: 1,
82
- alignItems: 'center',
83
- flexDirection: 'row',
84
- },
85
- pickerUnit: {
86
- position: 'absolute',
87
- right: convertX(20),
88
- },
89
- });
90
-
91
- export default LdvPickerView