@ledvance/group-ui-biz-bundle 1.0.46 → 1.0.48
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.
- package/package.json +1 -1
- package/src/modules/biorhythm/BiorhythmActions.ts +5 -13
- package/src/modules/biorhythm/BiorhythmBean.ts +6 -6
- package/src/modules/biorhythm/BiorhythmPage.tsx +373 -420
- package/src/modules/biorhythm/Router.ts +34 -0
- package/src/modules/fixedTimeForPlug/Router.ts +25 -0
- package/src/modules/fixedTimingForLight/Router.ts +25 -0
- package/src/modules/flags/Router.ts +25 -0
- package/src/modules/mood/AddMoodPage.tsx +2 -2
- package/src/modules/mood_new/AddMoodPage.tsx +197 -0
- package/src/modules/mood_new/DynamicMoodEditorPage.tsx +654 -0
- package/src/modules/mood_new/Interface.ts +219 -0
- package/src/modules/mood_new/MixDynamicMoodEditor.tsx +788 -0
- package/src/modules/mood_new/MoodActions.ts +227 -0
- package/src/modules/mood_new/MoodInfo.ts +2151 -0
- package/src/modules/mood_new/MoodItem.tsx +148 -0
- package/src/modules/mood_new/MoodPage.tsx +374 -0
- package/src/modules/mood_new/MoodParse.ts +442 -0
- package/src/modules/mood_new/RecommendMoodItem.tsx +69 -0
- package/src/modules/mood_new/Router.ts +43 -0
- package/src/modules/mood_new/StaticMoodEditorPage.tsx +293 -0
- package/src/modules/music/Router.ts +16 -0
- package/src/modules/randomTimeForPlug/Router.ts +25 -0
- package/src/modules/randomTimingForLight/Router.ts +25 -0
- package/src/modules/remoteSwitch/Router.ts +16 -0
- package/src/modules/select/Router.ts +16 -0
- package/src/modules/switchGradient/Router.ts +16 -0
- package/src/modules/timeSchedule/Interface.ts +150 -0
- package/src/modules/timeSchedule/Router.ts +25 -0
- package/src/modules/timeSchedule/TimeScheduleActions.ts +140 -0
- package/src/modules/timeSchedule/TimeScheduleDetailPage.tsx +625 -0
- package/src/modules/timeSchedule/TimeSchedulePage.tsx +220 -0
- package/src/modules/timeSchedule/components/ManuaSettings.tsx +376 -0
- package/src/modules/timeSchedule/components/ScheduleCard.tsx +109 -0
- package/src/modules/timeSchedule/components/Summary.tsx +124 -0
- package/src/modules/timer/Router.ts +16 -0
- package/src/navigation/Routers.ts +1 -0
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import React, { ReactElement, memo } from "react";
|
|
2
|
+
import { Text, Image, ViewStyle, View, StyleSheet } from 'react-native'
|
|
3
|
+
import res from "@ledvance/base/src/res"
|
|
4
|
+
import I18n from "@ledvance/base/src/i18n";
|
|
5
|
+
import { Utils } from "tuya-panel-kit";
|
|
6
|
+
import Spacer from "@ledvance/base/src/components/Spacer";
|
|
7
|
+
|
|
8
|
+
const { convertX: cx } = Utils.RatioUtils;
|
|
9
|
+
|
|
10
|
+
interface SummaryProps {
|
|
11
|
+
style?: ViewStyle
|
|
12
|
+
frequency?: string | ReactElement
|
|
13
|
+
time?: string | ReactElement
|
|
14
|
+
actions?: ReactElement
|
|
15
|
+
hideActions?: boolean
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const Summary = (props: SummaryProps) => {
|
|
19
|
+
return (
|
|
20
|
+
<View style={styles.cardContainer}>
|
|
21
|
+
<Text style={styles.itemTitle}>{I18n.getLang('add_randomtimecycle_subheadline_text')}</Text>
|
|
22
|
+
<Spacer height={cx(10)} />
|
|
23
|
+
<View style={{}}>
|
|
24
|
+
<View style={styles.summaryContainer}>
|
|
25
|
+
<View style={styles.summaryLeft}>
|
|
26
|
+
<Image
|
|
27
|
+
source={res.summary_icon1}
|
|
28
|
+
resizeMode="contain"
|
|
29
|
+
style={styles.summaryImg}
|
|
30
|
+
/>
|
|
31
|
+
<View>
|
|
32
|
+
<Text style={styles.leftTitle}>{I18n.getLang('feature_summary_frequency_headline')}</Text>
|
|
33
|
+
</View>
|
|
34
|
+
</View>
|
|
35
|
+
<View style={styles.summaryRight}>
|
|
36
|
+
<View style={styles.rightWrap}>
|
|
37
|
+
<Text style={styles.rightItem}>{props.frequency}</Text>
|
|
38
|
+
</View>
|
|
39
|
+
</View>
|
|
40
|
+
</View>
|
|
41
|
+
<View style={styles.summaryContainer}>
|
|
42
|
+
<View style={styles.summaryLeft}>
|
|
43
|
+
<Image
|
|
44
|
+
source={res.summary_icon2}
|
|
45
|
+
resizeMode="contain"
|
|
46
|
+
style={styles.summaryImg}
|
|
47
|
+
/>
|
|
48
|
+
<View>
|
|
49
|
+
<Text style={styles.leftTitle}>{I18n.getLang('feature_summary_time_headline')}</Text>
|
|
50
|
+
</View>
|
|
51
|
+
</View>
|
|
52
|
+
<View style={styles.summaryRight}>
|
|
53
|
+
<View style={styles.rightWrap}>
|
|
54
|
+
<Text style={styles.rightItem}>{props.time}</Text>
|
|
55
|
+
</View>
|
|
56
|
+
</View>
|
|
57
|
+
</View>
|
|
58
|
+
{!props.hideActions && <View style={[styles.summaryContainer, { alignItems: 'flex-start' }]}>
|
|
59
|
+
<View style={styles.summaryLeft}>
|
|
60
|
+
<Image
|
|
61
|
+
source={res.summary_icon3}
|
|
62
|
+
resizeMode="contain"
|
|
63
|
+
style={styles.summaryImg}
|
|
64
|
+
/>
|
|
65
|
+
<View>
|
|
66
|
+
<Text style={styles.leftTitle}>{I18n.getLang('motion_detection_add_time_schedule_actions_text1')}</Text>
|
|
67
|
+
</View>
|
|
68
|
+
</View>
|
|
69
|
+
<View style={styles.summaryRight}>
|
|
70
|
+
{props.actions}
|
|
71
|
+
</View>
|
|
72
|
+
</View>}
|
|
73
|
+
</View>
|
|
74
|
+
</View>
|
|
75
|
+
)
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
const styles = StyleSheet.create({
|
|
79
|
+
cardContainer: {
|
|
80
|
+
marginHorizontal: cx(24),
|
|
81
|
+
},
|
|
82
|
+
itemTitle: {
|
|
83
|
+
color: '#000',
|
|
84
|
+
fontSize: cx(16),
|
|
85
|
+
fontWeight: 'bold',
|
|
86
|
+
fontFamily: 'helvetica_neue_lt_std_bd',
|
|
87
|
+
},
|
|
88
|
+
summaryContainer: {
|
|
89
|
+
flex: 1,
|
|
90
|
+
flexDirection: 'row',
|
|
91
|
+
marginBottom: cx(10),
|
|
92
|
+
},
|
|
93
|
+
summaryLeft: {
|
|
94
|
+
flexDirection: 'row',
|
|
95
|
+
alignItems: 'center',
|
|
96
|
+
minWidth: cx(100)
|
|
97
|
+
},
|
|
98
|
+
summaryImg: {
|
|
99
|
+
width: cx(12),
|
|
100
|
+
height: cx(12),
|
|
101
|
+
marginRight: cx(6)
|
|
102
|
+
},
|
|
103
|
+
leftTitle: {
|
|
104
|
+
fontSize: cx(14),
|
|
105
|
+
color: '#000'
|
|
106
|
+
},
|
|
107
|
+
summaryRight: {
|
|
108
|
+
flex: 1,
|
|
109
|
+
flexDirection: 'column',
|
|
110
|
+
marginLeft: cx(15),
|
|
111
|
+
},
|
|
112
|
+
rightWrap: {
|
|
113
|
+
borderRadius: cx(16),
|
|
114
|
+
paddingHorizontal: cx(12),
|
|
115
|
+
alignSelf: 'flex-start',
|
|
116
|
+
backgroundColor: '#cbcbcb',
|
|
117
|
+
},
|
|
118
|
+
rightItem: {
|
|
119
|
+
color: '#000',
|
|
120
|
+
fontSize: cx(14)
|
|
121
|
+
},
|
|
122
|
+
})
|
|
123
|
+
|
|
124
|
+
export default memo(Summary)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import {NavigationRoute} from "tuya-panel-kit";
|
|
2
|
+
import TimerPage from "./TimerPage";
|
|
3
|
+
import {ui_biz_routerKey} from "../../navigation/Routers";
|
|
4
|
+
|
|
5
|
+
const TimerPageRouters: NavigationRoute[] = [
|
|
6
|
+
{
|
|
7
|
+
name: ui_biz_routerKey.group_ui_biz_timer,
|
|
8
|
+
component: TimerPage,
|
|
9
|
+
options:{
|
|
10
|
+
hideTopbar: true,
|
|
11
|
+
showOfflineView: false,
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
|
|
16
|
+
export default TimerPageRouters
|
|
@@ -32,6 +32,7 @@ export const ui_biz_routerKey = {
|
|
|
32
32
|
'group_ui_biz_mood_add': 'group_ui_biz_mood_add',
|
|
33
33
|
'group_ui_biz_static_mood_edit': 'group_ui_biz_static_mood_edit',
|
|
34
34
|
'group_ui_biz_dynamic_mood_edit': 'group_ui_biz_dynamic_mood_edit',
|
|
35
|
+
'group_ui_biz_dynamic_mix_mood_edit': 'group_ui_biz_dynamic_mix_mood_edit',
|
|
35
36
|
'group_ui_biz_select_page': 'group_ui_biz_select_page',
|
|
36
37
|
'group_ui_biz_flag_page': 'group_ui_biz_flag_page',
|
|
37
38
|
'group_ui_biz_flag_page_edit': 'group_ui_biz_flag_page_edit',
|