@ledvance/group-ui-biz-bundle 1.0.0

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 (40) hide show
  1. package/.babelrc +31 -0
  2. package/.eslintignore +6 -0
  3. package/.eslintrc.js +27 -0
  4. package/.prettierignore +0 -0
  5. package/.prettierrc.js +1 -0
  6. package/.versionrc +5 -0
  7. package/package.json +73 -0
  8. package/rn-cli.config.js +8 -0
  9. package/src/modules/mood/AddMoodPage.tsx +826 -0
  10. package/src/modules/mood/DynamicMoodEditorPage.tsx +547 -0
  11. package/src/modules/mood/MoodItem.tsx +114 -0
  12. package/src/modules/mood/MoodPage.tsx +332 -0
  13. package/src/modules/mood/RecommendMoodItem.tsx +75 -0
  14. package/src/modules/mood/SceneAction.ts +459 -0
  15. package/src/modules/mood/SceneInfo.ts +886 -0
  16. package/src/modules/mood/StaticMoodEditorPage.tsx +251 -0
  17. package/src/modules/mood/tools.ts +12 -0
  18. package/src/modules/select/SelectPage.d.ts +12 -0
  19. package/src/modules/select/SelectPage.tsx +139 -0
  20. package/src/modules/time_schedule/Interface.ts +85 -0
  21. package/src/modules/time_schedule/ScheduleCard.tsx +111 -0
  22. package/src/modules/time_schedule/TimeScheduleActions.ts +81 -0
  23. package/src/modules/time_schedule/TimeScheduleDetailPage.tsx +704 -0
  24. package/src/modules/time_schedule/TimeSchedulePage.tsx +246 -0
  25. package/src/modules/timer/TimerAction.d.ts +12 -0
  26. package/src/modules/timer/TimerAction.ts +150 -0
  27. package/src/modules/timer/TimerPage.d.ts +2 -0
  28. package/src/modules/timer/TimerPage.tsx +351 -0
  29. package/src/navigation/Routers.d.ts +5 -0
  30. package/src/navigation/Routers.ts +97 -0
  31. package/src/navigation/tools.d.ts +0 -0
  32. package/src/navigation/tools.ts +0 -0
  33. package/src/res/GroupBizRes.ts +4 -0
  34. package/src/res/materialiconsFilledCancel.png +0 -0
  35. package/src/res/materialiconsFilledCancel@2x.png +0 -0
  36. package/src/res/materialiconsFilledCancel@3x.png +0 -0
  37. package/src/res/materialiconsOutlinedArrowsNavAddBox.png +0 -0
  38. package/src/res/materialiconsOutlinedArrowsNavAddBox@2x.png +0 -0
  39. package/src/res/materialiconsOutlinedArrowsNavAddBox@3x.png +0 -0
  40. package/tsconfig.json +51 -0
@@ -0,0 +1,826 @@
1
+ import Strings from '@ledvance/base/src/i18n'
2
+ import Page from '@ledvance/base/src/components/Page'
3
+ import React, { useCallback } from 'react'
4
+ import { FlatList, StyleSheet, Text, View } from 'react-native'
5
+ import { Utils } from 'tuya-panel-kit'
6
+ import RecommendMoodItem, { ColorsLineProps } from './RecommendMoodItem'
7
+ import Spacer from '@ledvance/base/src/components/Spacer'
8
+ import { useReactive } from 'ahooks'
9
+ import { useNavigation, useRoute } from '@react-navigation/native'
10
+ import { SceneNodeTransitionMode, SceneUIState, SceneMode } from './SceneInfo'
11
+ import { MoodPageProps } from './MoodPage'
12
+ import { Result } from '@ledvance/base/src/models/modules/Result'
13
+ import { ui_biz_routerKey } from '../../navigation/Routers'
14
+
15
+ const cx = Utils.RatioUtils.convertX
16
+
17
+ export interface AddMoodPageParams {
18
+ isStatic: boolean,
19
+ moods: SceneUIState[],
20
+ moduleParams: MoodPageProps
21
+ modDeleteMood: (mode: 'add' | 'edit' | 'del', currentMood: SceneUIState) => Promise<Result<any>>
22
+ }
23
+
24
+ interface AddMoodPageState {
25
+ data: RecommendMood[]
26
+ }
27
+
28
+ const AddMoodPage = () => {
29
+ const navigation = useNavigation()
30
+ const routeParams = useRoute().params as AddMoodPageParams
31
+ const moduleParams = routeParams.moduleParams
32
+ const state = useReactive<AddMoodPageState>({
33
+ data: getRecommendMoods(
34
+ routeParams.isStatic,
35
+ moduleParams,
36
+ ),
37
+ })
38
+ const recommendMood2SceneUIState = useCallback((recommendMood: RecommendMood) => {
39
+ const id = routeParams.moods.length > 0 ? Math.max(...routeParams.moods.map(m => m.id)) + 1 : 0
40
+ return {
41
+ id: id,
42
+ image: '',
43
+ fanEnable: recommendMood.fanEnable,
44
+ fanSpeed: recommendMood.fanSpeed,
45
+ speed: recommendMood.speed,
46
+ name: recommendMood.name,
47
+ nodes: recommendMood.moodColorsLineProps?.nodes || [],
48
+ mode: recommendMood.mode,
49
+ segmented: 0,
50
+ excessive: 0,
51
+ expand: 0,
52
+ direction: 0
53
+ }
54
+ }, [routeParams, routeParams.moods])
55
+
56
+ return (
57
+ <Page
58
+ backText={Strings.getLang('add_new_static_mood_system_back')}
59
+ headlineText={Strings.getLang(routeParams.isStatic ? 'add_new_static_mood_headline_text' : 'add_new_dynamic_mood_headline_text')}>
60
+ <View style={styles.root}>
61
+ <Text style={styles.desc}>
62
+ {Strings.getLang(routeParams.isStatic ? 'add_new_static_mood_description_text' : 'add_new_dynamic_mood_description_text')}
63
+ </Text>
64
+ <FlatList
65
+ style={{ flex: 1 }}
66
+ data={state.data}
67
+ renderItem={({ item, index }) => {
68
+ return <RecommendMoodItem
69
+ title={item.name}
70
+ moodColorsLineProps={item.moodColorsLineProps}
71
+ onPress={() => {
72
+ const id = routeParams.moods.length > 0 ? Math.max(...routeParams.moods.map(m => m.id)) + 1 : 0
73
+ if (routeParams.isStatic) {
74
+ navigation.navigate(ui_biz_routerKey.group_ui_biz_static_mood_edit,
75
+ {
76
+ mode: 'add',
77
+ currentMood: index === 0 ? newMood(
78
+ id,
79
+ moduleParams.isSupportColor && moduleParams.isSupportTemperature,
80
+ routeParams.isStatic,
81
+ moduleParams
82
+ ) : recommendMood2SceneUIState(item),
83
+ moduleParams,
84
+ modDeleteMood: routeParams.modDeleteMood
85
+ })
86
+ } else {
87
+ navigation.navigate(ui_biz_routerKey.group_ui_biz_dynamic_mood_edit,
88
+ {
89
+ mode: 'add',
90
+ currentMood: index === 0 ? newMood(
91
+ id,
92
+ moduleParams.isSupportColor && moduleParams.isSupportTemperature,
93
+ routeParams.isStatic,
94
+ moduleParams
95
+ ) : recommendMood2SceneUIState(item),
96
+ moduleParams,
97
+ modDeleteMood: routeParams.modDeleteMood
98
+ })
99
+ }
100
+ }} />
101
+ }}
102
+ ItemSeparatorComponent={() => <Spacer />}
103
+ ListHeaderComponent={() => <Spacer />}
104
+ ListFooterComponent={() => <Spacer />}
105
+ keyExtractor={item => item.name} />
106
+ </View>
107
+ </Page>
108
+ )
109
+ }
110
+
111
+ const styles = StyleSheet.create({
112
+ root: {
113
+ flex: 1,
114
+ flexDirection: 'column',
115
+ },
116
+ desc: {
117
+ color: '#000',
118
+ fontSize: cx(16),
119
+ marginHorizontal: cx(24),
120
+ marginTop: cx(12),
121
+ },
122
+ })
123
+
124
+ export default AddMoodPage
125
+
126
+ function newMood(
127
+ id: number,
128
+ isColorMode: boolean,
129
+ isStatic: boolean,
130
+ moduleParams: MoodPageProps
131
+ ): SceneUIState {
132
+ const jump = moduleParams.isStringLight ? SceneMode.StringJump : moduleParams.isStripLight ? SceneMode.StripJump : SceneMode.SourceJump
133
+ const node = {
134
+ brightness: 100,
135
+ colorTemp: 100,
136
+ h: 0,
137
+ s: 50,
138
+ v: 80,
139
+ isColorNode: isColorMode,
140
+ switchingInterval: 13,
141
+ transitionMode: isStatic ? SceneNodeTransitionMode.Static : jump,
142
+ transitionTime: 13,
143
+ }
144
+ return {
145
+ name: '',
146
+ image: '',
147
+ id,
148
+ fanEnable: false,
149
+ fanSpeed: 2,
150
+ speed: 12,
151
+ mode: isStatic ? SceneNodeTransitionMode.Static : jump,
152
+ // @ts-ignore
153
+ nodes: isStatic ? [node] : [node, { ...node }],
154
+ segmented: 0,
155
+ excessive: 0,
156
+ expand: 0,
157
+ direction: 0,
158
+ }
159
+ }
160
+
161
+ type RecommendMood = {
162
+ name: string
163
+ fanEnable: boolean
164
+ fanSpeed: number
165
+ moodColorsLineProps?: ColorsLineProps
166
+ speed?: number
167
+ mode?: number
168
+ }
169
+
170
+ function getRecommendMoods(
171
+ isStatic: boolean,
172
+ moduleParams: MoodPageProps
173
+ ): RecommendMood[] {
174
+ const { isSupportColor, isSupportTemperature } = moduleParams
175
+ const jump = moduleParams.isStringLight ? SceneMode.StringJump : moduleParams.isStripLight ? SceneMode.StripJump : SceneMode.SourceJump
176
+ const gradient = moduleParams.isStringLight ? SceneMode.StringGradient : moduleParams.isStripLight ? SceneMode.StripGradient : SceneMode.SourceGradient
177
+ if (isStatic) {
178
+ if (isSupportColor) {
179
+ return [
180
+ {
181
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text1'),
182
+ fanEnable: true,
183
+ fanSpeed: 1,
184
+ },
185
+ {
186
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text2'),
187
+ fanEnable: true,
188
+ fanSpeed: 1,
189
+ moodColorsLineProps: {
190
+ type: 'gradient',
191
+ nodes: [
192
+ {
193
+ h: 125,
194
+ s: 46,
195
+ v: 100,
196
+ brightness: 100,
197
+ colorTemp: 100,
198
+ isColorNode: true,
199
+ switchingInterval: 0,
200
+ transitionTime: 14,
201
+ transitionMode: SceneNodeTransitionMode.Static,
202
+ },
203
+ ],
204
+ },
205
+ },
206
+ {
207
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text3'),
208
+ fanEnable: true,
209
+ fanSpeed: 1,
210
+ moodColorsLineProps: {
211
+ type: 'gradient',
212
+ nodes: [
213
+ {
214
+ h: 0,
215
+ s: 46,
216
+ v: 100,
217
+ brightness: 100,
218
+ colorTemp: 100,
219
+ isColorNode: true,
220
+ switchingInterval: 0,
221
+ transitionTime: 14,
222
+ transitionMode: SceneNodeTransitionMode.Static,
223
+ },
224
+ ],
225
+ },
226
+ },
227
+ {
228
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text4'),
229
+ fanEnable: true,
230
+ fanSpeed: 1,
231
+ moodColorsLineProps: {
232
+ type: 'gradient',
233
+ nodes: [
234
+ {
235
+ h: 34,
236
+ s: 67,
237
+ v: 100,
238
+ brightness: 100,
239
+ colorTemp: 100,
240
+ isColorNode: true,
241
+ switchingInterval: 0,
242
+ transitionTime: 14,
243
+ transitionMode: SceneNodeTransitionMode.Static,
244
+ },
245
+ ],
246
+ },
247
+ },
248
+ ]
249
+ } else if (isSupportTemperature) {
250
+ return [
251
+ {
252
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text1'),
253
+ fanEnable: true,
254
+ fanSpeed: 1,
255
+ },
256
+ {
257
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text2'),
258
+ fanEnable: true,
259
+ fanSpeed: 1,
260
+ moodColorsLineProps: {
261
+ type: 'gradient',
262
+ nodes: [
263
+ {
264
+ h: 0,
265
+ s: 50,
266
+ v: 80,
267
+ brightness: 60,
268
+ colorTemp: 20,
269
+ isColorNode: false,
270
+ switchingInterval: 0,
271
+ transitionTime: 14,
272
+ transitionMode: SceneNodeTransitionMode.Static,
273
+ },
274
+ ],
275
+ },
276
+ },
277
+ {
278
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text3'),
279
+ fanEnable: true,
280
+ fanSpeed: 1,
281
+ moodColorsLineProps: {
282
+ type: 'gradient',
283
+ nodes: [
284
+ {
285
+ h: 0,
286
+ s: 50,
287
+ v: 80,
288
+ brightness: 80,
289
+ colorTemp: 40,
290
+ isColorNode: false,
291
+ switchingInterval: 0,
292
+ transitionTime: 14,
293
+ transitionMode: SceneNodeTransitionMode.Static,
294
+ },
295
+ ],
296
+ },
297
+ },
298
+ {
299
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text4'),
300
+ fanEnable: true,
301
+ fanSpeed: 1,
302
+ moodColorsLineProps: {
303
+ type: 'gradient',
304
+ nodes: [
305
+ {
306
+ h: 0,
307
+ s: 50,
308
+ v: 80,
309
+ brightness: 100,
310
+ colorTemp: 100,
311
+ isColorNode: false,
312
+ switchingInterval: 0,
313
+ transitionTime: 14,
314
+ transitionMode: SceneNodeTransitionMode.Static,
315
+ },
316
+ ],
317
+ },
318
+ },
319
+ ]
320
+ } else {
321
+ return [
322
+ {
323
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text1'),
324
+ fanEnable: true,
325
+ fanSpeed: 1,
326
+ },
327
+ {
328
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text2'),
329
+ fanEnable: true,
330
+ fanSpeed: 1,
331
+ moodColorsLineProps: {
332
+ type: 'gradient',
333
+ nodes: [
334
+ {
335
+ h: 0,
336
+ s: 50,
337
+ v: 80,
338
+ brightness: 60,
339
+ colorTemp: 100,
340
+ isColorNode: false,
341
+ switchingInterval: 0,
342
+ transitionTime: 14,
343
+ transitionMode: SceneNodeTransitionMode.Static,
344
+ },
345
+ ],
346
+ },
347
+ },
348
+ {
349
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text3'),
350
+ fanEnable: true,
351
+ fanSpeed: 1,
352
+ moodColorsLineProps: {
353
+ type: 'gradient',
354
+ nodes: [
355
+ {
356
+ h: 0,
357
+ s: 50,
358
+ v: 80,
359
+ brightness: 80,
360
+ colorTemp: 100,
361
+ isColorNode: false,
362
+ switchingInterval: 0,
363
+ transitionTime: 14,
364
+ transitionMode: SceneNodeTransitionMode.Static,
365
+ },
366
+ ],
367
+ },
368
+ },
369
+ {
370
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text4'),
371
+ fanEnable: true,
372
+ fanSpeed: 1,
373
+ moodColorsLineProps: {
374
+ type: 'gradient',
375
+ nodes: [
376
+ {
377
+ h: 0,
378
+ s: 50,
379
+ v: 80,
380
+ brightness: 100,
381
+ colorTemp: 100,
382
+ isColorNode: false,
383
+ switchingInterval: 0,
384
+ transitionTime: 14,
385
+ transitionMode: SceneNodeTransitionMode.Static,
386
+ },
387
+ ],
388
+ },
389
+ },
390
+ ]
391
+ }
392
+ }
393
+ if (isSupportColor) {
394
+ return [
395
+ {
396
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text1'),
397
+ fanEnable: true,
398
+ fanSpeed: 1,
399
+ speed: 50,
400
+ },
401
+ {
402
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text2'),
403
+ fanEnable: true,
404
+ fanSpeed: 1,
405
+ speed: 14,
406
+ mode: jump,
407
+ moodColorsLineProps: {
408
+ type: 'separate',
409
+ nodes: [
410
+ {
411
+ h: 75,
412
+ s: 90,
413
+ v: 48,
414
+ brightness: 100,
415
+ colorTemp: 100,
416
+ isColorNode: true,
417
+ switchingInterval: 0,
418
+ transitionTime: 14,
419
+ transitionMode: jump,
420
+ },
421
+ {
422
+ h: 200,
423
+ s: 26,
424
+ v: 86,
425
+ brightness: 100,
426
+ colorTemp: 100,
427
+ isColorNode: true,
428
+ switchingInterval: 0,
429
+ transitionTime: 14,
430
+ transitionMode: jump,
431
+ },
432
+ {
433
+ h: 75,
434
+ s: 90,
435
+ v: 80,
436
+ brightness: 100,
437
+ colorTemp: 100,
438
+ isColorNode: true,
439
+ switchingInterval: 0,
440
+ transitionTime: 14,
441
+ transitionMode: jump,
442
+ },
443
+ ],
444
+ },
445
+ },
446
+ {
447
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text4'),
448
+ fanEnable: true,
449
+ fanSpeed: 1,
450
+ speed: 14,
451
+ mode: gradient,
452
+ moodColorsLineProps: {
453
+ type: 'gradient',
454
+ nodes: [
455
+ {
456
+ h: 40,
457
+ s: 100,
458
+ v: 100,
459
+ brightness: 100,
460
+ colorTemp: 100,
461
+ isColorNode: true,
462
+ switchingInterval: 0,
463
+ transitionTime: 14,
464
+ transitionMode: gradient,
465
+ },
466
+ {
467
+ h: 24,
468
+ s: 100,
469
+ v: 100,
470
+ brightness: 100,
471
+ colorTemp: 100,
472
+ isColorNode: true,
473
+ switchingInterval: 0,
474
+ transitionTime: 14,
475
+ transitionMode: gradient,
476
+ },
477
+ {
478
+ h: 0,
479
+ s: 100,
480
+ v: 100,
481
+ brightness: 100,
482
+ colorTemp: 100,
483
+ isColorNode: true,
484
+ switchingInterval: 0,
485
+ transitionTime: 14,
486
+ transitionMode: gradient,
487
+ },
488
+ ],
489
+ },
490
+ },
491
+ {
492
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text3'),
493
+ fanEnable: true,
494
+ fanSpeed: 1,
495
+ speed: 14,
496
+ mode: jump,
497
+ moodColorsLineProps: {
498
+ type: 'separate',
499
+ nodes: [
500
+ {
501
+ h: 300,
502
+ s: 17,
503
+ v: 59,
504
+ brightness: 100,
505
+ colorTemp: 100,
506
+ isColorNode: true,
507
+ switchingInterval: 0,
508
+ transitionTime: 14,
509
+ transitionMode: jump,
510
+ },
511
+ {
512
+ h: 183,
513
+ s: 51,
514
+ v: 82,
515
+ brightness: 100,
516
+ colorTemp: 100,
517
+ isColorNode: true,
518
+ switchingInterval: 0,
519
+ transitionTime: 14,
520
+ transitionMode: jump,
521
+ },
522
+ {
523
+ h: 40,
524
+ s: 100,
525
+ v: 100,
526
+ brightness: 100,
527
+ colorTemp: 100,
528
+ isColorNode: true,
529
+ switchingInterval: 0,
530
+ transitionTime: 14,
531
+ transitionMode: jump,
532
+ },
533
+ ],
534
+ },
535
+ },
536
+ ]
537
+ } else if (isSupportTemperature) {
538
+ return [
539
+ {
540
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text1'),
541
+ fanEnable: true,
542
+ fanSpeed: 1,
543
+ speed: 50
544
+ },
545
+ {
546
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text2'),
547
+ fanEnable: true,
548
+ fanSpeed: 1,
549
+ speed: 14,
550
+ mode: jump,
551
+ moodColorsLineProps: {
552
+ type: 'separate',
553
+ nodes: [
554
+ {
555
+ h: 0,
556
+ s: 50,
557
+ v: 80,
558
+ brightness: 20,
559
+ colorTemp: 20,
560
+ isColorNode: false,
561
+ switchingInterval: 0,
562
+ transitionTime: 14,
563
+ transitionMode: jump,
564
+ },
565
+ {
566
+ h: 0,
567
+ s: 50,
568
+ v: 80,
569
+ brightness: 40,
570
+ colorTemp: 40,
571
+ isColorNode: false,
572
+ switchingInterval: 0,
573
+ transitionTime: 14,
574
+ transitionMode: jump,
575
+ },
576
+ {
577
+ h: 0,
578
+ s: 50,
579
+ v: 80,
580
+ brightness: 60,
581
+ colorTemp: 60,
582
+ isColorNode: false,
583
+ switchingInterval: 0,
584
+ transitionTime: 14,
585
+ transitionMode: jump,
586
+ },
587
+ ],
588
+ },
589
+ },
590
+ {
591
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text4'),
592
+ fanEnable: true,
593
+ fanSpeed: 1,
594
+ speed: 14,
595
+ mode: gradient,
596
+ moodColorsLineProps: {
597
+ type: 'gradient',
598
+ nodes: [
599
+ {
600
+ h: 0,
601
+ s: 50,
602
+ v: 80,
603
+ brightness: 40,
604
+ colorTemp: 40,
605
+ isColorNode: false,
606
+ switchingInterval: 0,
607
+ transitionTime: 14,
608
+ transitionMode: gradient,
609
+ },
610
+ {
611
+ h: 0,
612
+ s: 50,
613
+ v: 80,
614
+ brightness: 60,
615
+ colorTemp: 60,
616
+ isColorNode: false,
617
+ switchingInterval: 0,
618
+ transitionTime: 14,
619
+ transitionMode: gradient,
620
+ },
621
+ {
622
+ h: 0,
623
+ s: 50,
624
+ v: 80,
625
+ brightness: 80,
626
+ colorTemp: 80,
627
+ isColorNode: false,
628
+ switchingInterval: 0,
629
+ transitionTime: 14,
630
+ transitionMode: gradient,
631
+ },
632
+ ],
633
+ },
634
+ },
635
+ {
636
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text3'),
637
+ fanEnable: true,
638
+ fanSpeed: 1,
639
+ speed: 14,
640
+ mode: jump,
641
+ moodColorsLineProps: {
642
+ type: 'separate',
643
+ nodes: [
644
+ {
645
+ h: 0,
646
+ s: 50,
647
+ v: 80,
648
+ brightness: 50,
649
+ colorTemp: 50,
650
+ isColorNode: false,
651
+ switchingInterval: 0,
652
+ transitionTime: 14,
653
+ transitionMode: jump,
654
+ },
655
+ {
656
+ h: 0,
657
+ s: 50,
658
+ v: 80,
659
+ brightness: 70,
660
+ colorTemp: 70,
661
+ isColorNode: false,
662
+ switchingInterval: 0,
663
+ transitionTime: 14,
664
+ transitionMode: jump,
665
+ },
666
+ {
667
+ h: 0,
668
+ s: 50,
669
+ v: 80,
670
+ brightness: 100,
671
+ colorTemp: 100,
672
+ isColorNode: false,
673
+ switchingInterval: 0,
674
+ transitionTime: 14,
675
+ transitionMode: jump,
676
+ },
677
+ ],
678
+ },
679
+ },
680
+ ]
681
+ } else {
682
+ return [
683
+ {
684
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text1'),
685
+ fanEnable: true,
686
+ fanSpeed: 1,
687
+ speed: 50
688
+ },
689
+ {
690
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text2'),
691
+ fanEnable: true,
692
+ fanSpeed: 1,
693
+ speed: 14,
694
+ mode: jump,
695
+ moodColorsLineProps: {
696
+ type: 'separate',
697
+ nodes: [
698
+ {
699
+ h: 0,
700
+ s: 50,
701
+ v: 80,
702
+ brightness: 20,
703
+ colorTemp: 100,
704
+ isColorNode: false,
705
+ switchingInterval: 0,
706
+ transitionTime: 14,
707
+ transitionMode: jump,
708
+ },
709
+ {
710
+ h: 0,
711
+ s: 50,
712
+ v: 80,
713
+ brightness: 40,
714
+ colorTemp: 100,
715
+ isColorNode: false,
716
+ switchingInterval: 0,
717
+ transitionTime: 14,
718
+ transitionMode: jump,
719
+ },
720
+ {
721
+ h: 0,
722
+ s: 50,
723
+ v: 80,
724
+ brightness: 60,
725
+ colorTemp: 100,
726
+ isColorNode: false,
727
+ switchingInterval: 0,
728
+ transitionTime: 14,
729
+ transitionMode: jump,
730
+ },
731
+ ],
732
+ },
733
+ },
734
+ {
735
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text4'),
736
+ fanEnable: true,
737
+ fanSpeed: 1,
738
+ speed: 14,
739
+ mode: gradient,
740
+ moodColorsLineProps: {
741
+ type: 'gradient',
742
+ nodes: [
743
+ {
744
+ h: 0,
745
+ s: 50,
746
+ v: 80,
747
+ brightness: 40,
748
+ colorTemp: 100,
749
+ isColorNode: false,
750
+ switchingInterval: 0,
751
+ transitionTime: 14,
752
+ transitionMode: gradient,
753
+ },
754
+ {
755
+ h: 0,
756
+ s: 50,
757
+ v: 80,
758
+ brightness: 60,
759
+ colorTemp: 100,
760
+ isColorNode: false,
761
+ switchingInterval: 0,
762
+ transitionTime: 14,
763
+ transitionMode: gradient,
764
+ },
765
+ {
766
+ h: 0,
767
+ s: 50,
768
+ v: 80,
769
+ brightness: 80,
770
+ colorTemp: 100,
771
+ isColorNode: false,
772
+ switchingInterval: 0,
773
+ transitionTime: 14,
774
+ transitionMode: gradient,
775
+ },
776
+ ],
777
+ },
778
+ },
779
+ {
780
+ name: Strings.getLang('add_new_dynamic_mood_field_headline_text3'),
781
+ fanEnable: true,
782
+ fanSpeed: 1,
783
+ speed: 14,
784
+ mode: jump,
785
+ moodColorsLineProps: {
786
+ type: 'separate',
787
+ nodes: [
788
+ {
789
+ h: 0,
790
+ s: 50,
791
+ v: 80,
792
+ brightness: 50,
793
+ colorTemp: 100,
794
+ isColorNode: false,
795
+ switchingInterval: 0,
796
+ transitionTime: 14,
797
+ transitionMode: jump,
798
+ },
799
+ {
800
+ h: 0,
801
+ s: 50,
802
+ v: 80,
803
+ brightness: 70,
804
+ colorTemp: 100,
805
+ isColorNode: false,
806
+ switchingInterval: 0,
807
+ transitionTime: 14,
808
+ transitionMode: jump,
809
+ },
810
+ {
811
+ h: 0,
812
+ s: 50,
813
+ v: 80,
814
+ brightness: 100,
815
+ colorTemp: 100,
816
+ isColorNode: false,
817
+ switchingInterval: 0,
818
+ transitionTime: 14,
819
+ transitionMode: jump,
820
+ },
821
+ ],
822
+ },
823
+ },
824
+ ]
825
+ }
826
+ }