@ledvance/base 1.1.45 → 1.1.46

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/base",
5
5
  "pid": [],
6
6
  "uiid": "",
7
- "version": "1.1.45",
7
+ "version": "1.1.46",
8
8
  "scripts": {},
9
9
  "dependencies": {
10
10
  "@reduxjs/toolkit": "^1.8.6",
@@ -47,7 +47,7 @@ export declare function useGroupConfig<T>(): [T, (dps: any, newConfig: T) => Pro
47
47
  */
48
48
  export declare function useGroupConfigFeature<GC, GCPT extends {
49
49
  [K in keyof GC]: GC[K];
50
- }[keyof GC]>(key: keyof GC, dpKey?: string): [GCPT, (value: GCPT, dpValue: any, extraDps: any) => Promise<Result<any>>];
50
+ }[keyof GC]>(key: keyof GC, dpKey?: string): [GCPT, (value: GCPT, dpValue: any, extraDps?: any) => Promise<Result<any>>];
51
51
  export declare const useFanMaxSpeed: () => 3 | 20;
52
52
  export declare const ldvModules: import("@reduxjs/toolkit").Reducer<NativeProps, import("@reduxjs/toolkit").AnyAction>;
53
53
  export declare const setNativeProps: import("@reduxjs/toolkit").ActionCreatorWithPayload<NativeProps, string>, setGroupNativeProps: import("@reduxjs/toolkit").ActionCreatorWithPayload<NativeProps, string>, setDps: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, string>, setTimeSchedule: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, string>, setEnergieverbrauch: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, string>;
@@ -234,13 +234,13 @@ export function useGroupConfig<T>(): [T, (dps: any, newConfig: T) => Promise<Res
234
234
  * @param dpKey
235
235
  */
236
236
  export function useGroupConfigFeature<GC, GCPT extends { [K in keyof GC]: GC[K] }[keyof GC]>
237
- (key: keyof GC, dpKey?: string): [GCPT, (value: GCPT, dpValue: any, extraDps: any) => Promise<Result<any>>] {
237
+ (key: keyof GC, dpKey?: string): [GCPT, (value: GCPT, dpValue: any, extraDps?: any) => Promise<Result<any>>] {
238
238
  const [groupConfig, setGroupConfig] = useGroupConfig<GC>()
239
- const setGroupConfigFeature = async (value: GCPT, dpValue: any, extraDps: any = {}) => {
239
+ const setGroupConfigFeature = async (value: GCPT, dpValue: any, extraDps?: any) => {
240
240
  return await setGroupConfig(
241
241
  {
242
242
  [!!dpKey ? dpKey : GlobalParams.dpSchemaMap[snakeCase(key as string)].dp]: dpValue,
243
- ...extraDps,
243
+ ...(extraDps || {}),
244
244
  },
245
245
  {
246
246
  ...groupConfig,