@ledvance/base 1.3.36 → 1.3.37
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/api/native.ts +11 -1
- package/src/i18n/strings.ts +281 -281
package/package.json
CHANGED
package/src/api/native.ts
CHANGED
|
@@ -25,6 +25,7 @@ interface LDVDevicePanelManager {
|
|
|
25
25
|
getSystemTimeFormat: () => Promise<number>
|
|
26
26
|
getMicrophoneAccess: (res:any) => Promise<Result<any>>
|
|
27
27
|
firebaseEvent: (dimensions:Record<any, any>) => Promise<NativeResult<any>>
|
|
28
|
+
appEvent: (action: string, payload: Record<string, any>) => void
|
|
28
29
|
}
|
|
29
30
|
|
|
30
31
|
export enum UADeviceCategory {
|
|
@@ -61,7 +62,7 @@ export interface DeviceInfo {
|
|
|
61
62
|
deviceCategory: UADeviceCategory
|
|
62
63
|
roomName: string
|
|
63
64
|
status: number
|
|
64
|
-
dps: string
|
|
65
|
+
dps: string
|
|
65
66
|
tuyaDeviceId: string
|
|
66
67
|
}
|
|
67
68
|
|
|
@@ -179,6 +180,15 @@ export const putFeature: SetFeatureResultType = (
|
|
|
179
180
|
})
|
|
180
181
|
}
|
|
181
182
|
|
|
183
|
+
export const sendAppEvent = (action: string, payload?: Record<string, any>) => {
|
|
184
|
+
try {
|
|
185
|
+
console.log(action, payload)
|
|
186
|
+
devicePanel.appEvent(action, payload ?? {})
|
|
187
|
+
} catch (e) {
|
|
188
|
+
console.log('sendAppEvent', e)
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
|
|
182
192
|
type DeleteDeviceResultType = (deviceId: string, isReset: boolean) => Promise<NativeResult<any>>
|
|
183
193
|
|
|
184
194
|
const deleteDevice: DeleteDeviceResultType = (deviceId: string, isReset: boolean) => {
|