@ledvance/group-ui-biz-bundle 1.0.52 → 1.0.54

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 CHANGED
@@ -4,7 +4,7 @@
4
4
  "name": "@ledvance/group-ui-biz-bundle",
5
5
  "pid": [],
6
6
  "uiid": "",
7
- "version": "1.0.52",
7
+ "version": "1.0.54",
8
8
  "scripts": {},
9
9
  "dependencies": {
10
10
  "@ledvance/base": "^1.x",
@@ -21,7 +21,7 @@ export const defMixDeviceData = {
21
21
 
22
22
  export const defStripDeviceData = {
23
23
  ...defDeviceData,
24
- activeKey: 0,
24
+ activeKey: 1,
25
25
  colorDiskActiveKey: 0,
26
26
  colors: ColorList[0],
27
27
  };
@@ -33,11 +33,6 @@ export const defCeilingLihtDeviceData = {
33
33
  }
34
34
 
35
35
  export const addTimeSchedule = async (props: IAddSingleTime) => {
36
- console.log({
37
- ...props,
38
- bizType: '1',
39
- category: 'category'
40
- }, '< --- schedule --- >')
41
36
  try {
42
37
  const res = await commonApi.timerApi.addSingleTimer({
43
38
  ...props,
@@ -125,7 +125,6 @@ const TimeScheduleDetailPage = () => {
125
125
  getRemoteMoodList(uaGroupInfo.tyGroupId.toString(), props).then(res => {
126
126
  if (res.success && Array.isArray(res.data)) {
127
127
  state.moods = cloneDeep(res.data);
128
- console.log(state.moods, '< --- moods')
129
128
  setMoods(cloneDeep(res.data));
130
129
  if (!state.mood) state.mood = cloneDeep(res.data[0]);
131
130
  }
@@ -495,6 +494,7 @@ const TimeScheduleDetailPage = () => {
495
494
  const res = await props.modDeleteTimeSchedule('del', state.timeSchedule, state.timeSchedule.id.toString());
496
495
  state.loading = false;
497
496
  if (res.success) {
497
+ props.refreshFn()
498
498
  navigation.goBack();
499
499
  }
500
500
  },
@@ -1,5 +1,5 @@
1
1
  import React, { memo, useMemo } from 'react';
2
- import { CeilingLightData, DeviceType, ManualSettingProps } from '../Interface';
2
+ import { CeilingLightData, DeviceType, ManualSettingProps, StripLightData } from '../Interface';
3
3
  import { View } from 'react-native';
4
4
  import Card from '@ledvance/base/src/components/Card';
5
5
  import LampAdjustView from '@ledvance/base/src/components/LampAdjustView';
@@ -209,9 +209,10 @@ function ManualSettings(props: ManualSettingProps) {
209
209
  }, [state.deviceData, state.applyForList]);
210
210
 
211
211
  const stripLightCard = useMemo(() => {
212
+ const deviceData = state.deviceData as StripLightData
212
213
  return (
213
214
  <View>
214
- <Card>
215
+ <Card style={{ marginHorizontal: cx(24) }}>
215
216
  <LdvSwitch
216
217
  title={I18n.getLang('light_sources_tile_tw_lighting_headline')}
217
218
  color={'#fff'}
@@ -228,8 +229,24 @@ function ManualSettings(props: ManualSettingProps) {
228
229
  isSupportTemperature={props.isSupportTemperature}
229
230
  lampTabs={tabList}
230
231
  reserveSV={true}
231
- activeKey={0}
232
- onActiveKeyChange={() => { }}
232
+ activeKey={deviceData.activeKey}
233
+ colorDiskActiveKey={deviceData.colorDiskActiveKey}
234
+ onActiveKeyChange={(activekey) => {
235
+ state.deviceData = {
236
+ ...state.deviceData,
237
+ activeKey: Number(activekey),
238
+ isColorMode: !(Number(activekey) === 0)
239
+ }
240
+ state.manualFlag = Symbol()
241
+ }}
242
+ onColorDiskChange={(colors, idx) => {
243
+ state.deviceData = {
244
+ ...state.deviceData,
245
+ colors,
246
+ colorDiskActiveKey: idx
247
+ }
248
+ state.manualFlag = Symbol()
249
+ }}
233
250
  h={state.deviceData.h}
234
251
  s={state.deviceData.s}
235
252
  v={state.deviceData.v}
@@ -307,7 +324,6 @@ function ManualSettings(props: ManualSettingProps) {
307
324
  activeKey={deviceData.activeKey}
308
325
  colorDiskActiveKey={deviceData.colorDiskActiveKey}
309
326
  onActiveKeyChange={(activekey) => {
310
- console.log(activekey, '< -- activeKey')
311
327
  state.deviceData = {
312
328
  ...state.deviceData,
313
329
  activeKey: Number(activekey)