@ledvance/base 1.3.88 → 1.3.90

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 (82) hide show
  1. package/localazy.json +8 -1
  2. package/package.json +1 -1
  3. package/src/components/LdvPickerView.tsx +151 -0
  4. package/src/i18n/strings.ts +201 -5
  5. package/src/models/TuyaApi.ts +65 -3
  6. package/translateKey.txt +8 -1
  7. package/tsconfig.json +72 -46
  8. package/src/api/native.d.ts +0 -71
  9. package/src/api/nativeEventEmitter.d.ts +0 -3
  10. package/src/components/AdvanceCard.d.ts +0 -25
  11. package/src/components/AdvanceList.d.ts +0 -9
  12. package/src/components/ApplyForDeviceItem.d.ts +0 -6
  13. package/src/components/ApplyForDeviceList.d.ts +0 -7
  14. package/src/components/ApplyForText.d.ts +0 -6
  15. package/src/components/Card.d.ts +0 -10
  16. package/src/components/Cell.d.ts +0 -21
  17. package/src/components/CircularProgress.d.ts +0 -8
  18. package/src/components/ColorAdjustView.d.ts +0 -12
  19. package/src/components/ColorExtractor.d.ts +0 -73
  20. package/src/components/ColorTempAdjustView.d.ts +0 -13
  21. package/src/components/ColorsLine.d.ts +0 -7
  22. package/src/components/CustomListDialog.d.ts +0 -15
  23. package/src/components/DeleteButton.d.ts +0 -10
  24. package/src/components/Dialog.d.ts +0 -10
  25. package/src/components/DrawToolView.d.ts +0 -46
  26. package/src/components/FanAdjustView.d.ts +0 -23
  27. package/src/components/InfoText.d.ts +0 -11
  28. package/src/components/LampAdjustView.d.ts +0 -10
  29. package/src/components/LampAdjustView2.d.ts +0 -24
  30. package/src/components/LinearGradientLine.d.ts +0 -9
  31. package/src/components/MoodColorsLine.d.ts +0 -9
  32. package/src/components/Page.d.ts +0 -21
  33. package/src/components/Popup.d.ts +0 -7
  34. package/src/components/Segmented.d.ts +0 -14
  35. package/src/components/SocketItem.d.ts +0 -13
  36. package/src/components/Spacer.d.ts +0 -7
  37. package/src/components/Stepper.d.ts +0 -19
  38. package/src/components/StripAdjustView.d.ts +0 -16
  39. package/src/components/StripLightView.d.ts +0 -14
  40. package/src/components/Tag.d.ts +0 -8
  41. package/src/components/TextButton.d.ts +0 -9
  42. package/src/components/TextField.d.ts +0 -9
  43. package/src/components/TextFieldStyleButton.d.ts +0 -8
  44. package/src/components/UATabTitle.d.ts +0 -6
  45. package/src/components/UATabs.d.ts +0 -12
  46. package/src/components/connect.d.ts +0 -10
  47. package/src/components/ldvColorBrightness.d.ts +0 -1
  48. package/src/components/ldvColorSlider.d.ts +0 -14
  49. package/src/components/ldvItemView.d.ts +0 -12
  50. package/src/components/ldvPickerView.d.ts +0 -13
  51. package/src/components/ldvPickerView.tsx +0 -105
  52. package/src/components/ldvPresetView.d.ts +0 -2
  53. package/src/components/ldvSaturation.d.ts +0 -2
  54. package/src/components/ldvSlider.d.ts +0 -15
  55. package/src/components/ldvSwitch.d.ts +0 -10
  56. package/src/components/ldvTemperatureSlider.d.ts +0 -13
  57. package/src/components/ldvTopBar.d.ts +0 -10
  58. package/src/components/ldvTopName.d.ts +0 -9
  59. package/src/components/segmentControl.d.ts +0 -1
  60. package/src/components/weekSelect.d.ts +0 -7
  61. package/src/composeLayout.d.ts +0 -30
  62. package/src/hooks/Hooks.d.ts +0 -2
  63. package/src/i18n/index.d.ts +0 -16
  64. package/src/i18n/strings.d.ts +0 -15953
  65. package/src/models/GlobalParams.d.ts +0 -14
  66. package/src/models/TuyaApi.d.ts +0 -29
  67. package/src/models/combine.d.ts +0 -26
  68. package/src/models/configureStore.d.ts +0 -9
  69. package/src/models/index.d.ts +0 -31
  70. package/src/models/modules/NativePropsSlice.d.ts +0 -61
  71. package/src/models/modules/Result.d.ts +0 -14
  72. package/src/models/modules/common.d.ts +0 -44
  73. package/src/res/index.d.ts +0 -70
  74. package/src/utils/ColorParser.d.ts +0 -66
  75. package/src/utils/ColorUtils.d.ts +0 -71
  76. package/src/utils/Support.d.ts +0 -13
  77. package/src/utils/TypeUtils.d.ts +0 -3
  78. package/src/utils/cctUtils.d.ts +0 -1
  79. package/src/utils/common.d.ts +0 -35
  80. package/src/utils/index.d.ts +0 -26
  81. package/src/utils/interface.d.ts +0 -6
  82. package/src/utils/loopsCompare.d.ts +0 -1
@@ -1,5 +1,5 @@
1
1
  import {commonApi} from '@tuya/tuya-panel-api'
2
- import { IGetDpResultByHourResponse, IGetDpResultByMonthResponse } from '@tuya/tuya-panel-api/lib/common/interface'
2
+ import { Dp, IGetDpResultByHourResponse, IGetDpResultByMonthResponse, IGetLogInSpecifiedTimeResponse } from '@tuya/tuya-panel-api/lib/common/interface'
3
3
  import {sendAppEvent} from "../api/native";
4
4
  import {retryWithBackoff} from "../utils/index";
5
5
  import {TYSdk} from "tuya-panel-kit";
@@ -171,8 +171,8 @@ export async function getAllDpReportLogs(
171
171
  backoffFactor?: number;
172
172
  } = {}
173
173
  ): Promise<DpReportSataData[]> {
174
- const limit = 100; // 每次请求的数据量
175
- let offset = 1;
174
+ const limit = 1000; // 每次请求的数据量
175
+ let offset = 0;
176
176
  let hasNext = true;
177
177
  const allDps: DpReportSataData[] = [];
178
178
 
@@ -218,6 +218,68 @@ export async function getAllDpReportLogs(
218
218
  return allDps;
219
219
  }
220
220
 
221
+ export async function getSpecifiedTimeDpReportLogs(
222
+ devId: string,
223
+ dpIds: string[],
224
+ sortType: 'ASC' | 'DESC' = 'ASC',
225
+ startTime?: string,
226
+ endTime?: string,
227
+ retryOptions: {
228
+ maxRetries?: number;
229
+ initialDelay?: number;
230
+ maxDelay?: number;
231
+ backoffFactor?: number;
232
+ } = {}
233
+ ): Promise<Dp[]> {
234
+ const limit = 1000; // 每次请求的数据量
235
+ let offset = 0;
236
+ let hasNext = true;
237
+ const allDps: Dp[] = [];
238
+
239
+ while (hasNext) {
240
+ try {
241
+ // 使用重试函数包装API调用
242
+ const res: IGetLogInSpecifiedTimeResponse = await retryWithBackoff(
243
+ () => commonApi.statApi.getLogInSpecifiedTime({
244
+ devId,
245
+ dpIds: dpIds.join(','),
246
+ offset,
247
+ limit,
248
+ sortType,
249
+ startTime,
250
+ endTime,
251
+ }),
252
+ {
253
+ ...retryOptions,
254
+ // 自定义判断哪些错误需要重试
255
+ shouldRetry: (error) => {
256
+ // 网络错误、超时错误或服务器错误(5xx)通常需要重试
257
+ const isNetworkError = error.name === 'NetworkError' ||
258
+ error.name === 'TimeoutError' ||
259
+ (error.response && error.response.status >= 500);
260
+
261
+ // 对于特定的业务错误码也可以在这里添加判断
262
+ return isNetworkError;
263
+ }
264
+ }
265
+ );
266
+
267
+ allDps.push(...res.dps);
268
+
269
+ if (res.hasNext) {
270
+ offset += limit;
271
+ } else {
272
+ hasNext = false;
273
+ }
274
+ } catch (error) {
275
+ console.error('获取数据点记录失败,不再继续获取:', error);
276
+ hasNext = false;
277
+ }
278
+ }
279
+
280
+ return allDps;
281
+ }
282
+
221
283
  export const saveDeviceExtInfo = async (devId: string, key: string, value: string): Promise<boolean> => {
222
284
  try {
223
285
  return await new Promise<any>((resolve, reject) => {
package/translateKey.txt CHANGED
@@ -1224,4 +1224,11 @@ repeater_change_router_tips
1224
1224
  repeater_select_other_router
1225
1225
  repeater_password_error_length
1226
1226
  repeater_password_error_space
1227
- cancel_dialog_leave_unsaved_repeater_note
1227
+ cancel_dialog_leave_unsaved_repeater_note
1228
+ chartdisplay_energy
1229
+ chartdisplay_power
1230
+ charttime_type1
1231
+ charttime_type2
1232
+ charttime_type3
1233
+ charttime_type4
1234
+ power_chart_empty
package/tsconfig.json CHANGED
@@ -1,51 +1,77 @@
1
1
  {
2
- "compilerOptions": {
3
- /* Basic Options */
4
- "target": "ES2017",
5
- /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017','ES2018' or 'ESNEXT'. */
6
- "module": "commonjs",
7
- /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
8
- "jsx": "react",
9
- /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */
2
+ "compilerOptions": {
3
+ /* Basic Options */
4
+ "target": "ES2017",
5
+ "lib": [
6
+ "es2017"
7
+ ],
8
+ /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017','ES2018' or 'ESNEXT'. */
9
+ "module": "commonjs",
10
+ /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
11
+ "jsx": "react",
12
+ /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */
10
13
 
11
- /* Strict Type-Checking Options */
12
- /* "strict": true /* Enable all strict type-checking options. */
13
- "noImplicitAny": false,
14
- /* Raise error on expressions and declarations with an implied 'any' type. */
15
- "strictNullChecks": true,
16
- /* Enable strict null checks. */
14
+ /* Strict Type-Checking Options */
15
+ /* "strict": true /* Enable all strict type-checking options. */
16
+ "noImplicitAny": false,
17
+ /* Raise error on expressions and declarations with an implied 'any' type. */
18
+ "strictNullChecks": true,
19
+ /* Enable strict null checks. */
17
20
 
18
- /* Additional Checks */
19
- "noUnusedLocals": true,
20
- /* Report errors on unused locals. */
21
- "noUnusedParameters": true,
22
- /* Report errors on unused parameters. */
21
+ /* Additional Checks */
22
+ "noUnusedLocals": true,
23
+ /* Report errors on unused locals. */
24
+ "noUnusedParameters": true,
25
+ /* Report errors on unused parameters. */
23
26
 
24
- /* .d.ts config */
25
- "declaration": true,
26
- "emitDeclarationOnly": true,
27
-
28
- /* Module Resolution Options */
29
- "moduleResolution": "node",
30
- /* Specify module resolution strategy: 'node' (Node.js) or 'classic' */
31
- "types": ["react", "react-native"],
32
- /* Type declaration files to be included in compilation. */
33
- "typeRoots": ["@types/*.d.ts"],
34
- "allowSyntheticDefaultImports": true,
35
- /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */
36
- "esModuleInterop": true,
37
- /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
38
- "baseUrl": "./src",
39
- "paths": {
40
- "@api": ["./api"],
41
- "@components": ["./components"],
42
- "@config": ["./config"],
43
- "@i18n": ["./i18n"],
44
- "@models": ["./models"],
45
- "@res": ["./res"],
46
- "@utils": ["./utils"]
47
- }
48
- },
49
- "include": ["src/**/*.ts","src/**/*.tsx"],
50
- "exclude": ["node_modules"]
27
+ /* .d.ts config */
28
+ "declaration": true,
29
+ "emitDeclarationOnly": true,
30
+ /* Module Resolution Options */
31
+ "moduleResolution": "node",
32
+ /* Specify module resolution strategy: 'node' (Node.js) or 'classic' */
33
+ "types": [
34
+ "react",
35
+ "react-native"
36
+ ],
37
+ /* Type declaration files to be included in compilation. */
38
+ "typeRoots": [
39
+ "@types/*.d.ts"
40
+ ],
41
+ "allowSyntheticDefaultImports": true,
42
+ /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */
43
+ "esModuleInterop": true,
44
+ /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
45
+ "baseUrl": "./src",
46
+ "paths": {
47
+ "@api": [
48
+ "./api"
49
+ ],
50
+ "@components": [
51
+ "./components"
52
+ ],
53
+ "@config": [
54
+ "./config"
55
+ ],
56
+ "@i18n": [
57
+ "./i18n"
58
+ ],
59
+ "@models": [
60
+ "./models"
61
+ ],
62
+ "@res": [
63
+ "./res"
64
+ ],
65
+ "@utils": [
66
+ "./utils"
67
+ ]
68
+ }
69
+ },
70
+ "include": [
71
+ "src/**/*.ts",
72
+ "src/**/*.tsx"
73
+ ],
74
+ "exclude": [
75
+ "node_modules"
76
+ ]
51
77
  }
@@ -1,71 +0,0 @@
1
- import { NativeResult, Result } from '../models/modules/Result';
2
- export declare enum UADeviceCategory {
3
- ThirdParty = "ThirdParty",
4
- General = "General",
5
- LightSource = "LightSource",
6
- CeilingLight = "CeilingLight",
7
- CeilingFan = "CeilingFan",
8
- SterilizedCeilingFan = "SterilizedCeilingFan",
9
- PIRLight = "PIRLight",
10
- SolarLight = "SolarLight",
11
- StringLights = "StringLights",
12
- StripLights = "StripLights",
13
- PowerStrip = "PowerStrip",
14
- NightlightPlug = "NightlightPlug",
15
- WifiPlug = "WifiPlug",
16
- ChildLockPlug = "ChildLockPlug",
17
- RepeaterSocket = "RepeaterSocket",
18
- ContactSensor = "ContactSensor",
19
- MotionDetector = "MotionDetector",
20
- PIRCamera = "PIRCamera",
21
- LinkageCamera = "LinkageCamera",
22
- SmartCamera = "SmartCamera",
23
- MatterLight = "MatterLight",
24
- MeshLight = "MeshLight",
25
- MeshSwitch = "MeshSwitch"
26
- }
27
- export interface DeviceInfo {
28
- deviceId: string;
29
- deviceName: string;
30
- deviceIcon: string;
31
- tyPid: string;
32
- deviceCategory: UADeviceCategory;
33
- roomName: string;
34
- status: number;
35
- }
36
- declare type GetFeatureResultType = (deviceId: string, featureId: string) => Promise<NativeResult<any>>;
37
- declare type SetFeatureResultType = (deviceId: string, featureId: string, value: any) => Promise<NativeResult<any>>;
38
- export declare const getFeature: GetFeatureResultType;
39
- export declare const putFeature: SetFeatureResultType;
40
- export declare class NativeApi {
41
- static back(): void;
42
- static log(msg: string): void;
43
- static logObj(msg: any): void;
44
- static showObj(obj: any): void;
45
- static getAllTaskTimer(devId: string, type?: number): Promise<Result<any>>;
46
- static timerList(deviceId: string): Promise<any>;
47
- static addTimer(deviceId: string, value: any, callback?: (res: any) => void): void;
48
- static editTimer(deviceId: string, value: any, callback?: (res: any) => void): void;
49
- static deleteTimer(deviceId: string, value: any, callback?: (res: any) => void): void;
50
- static setDp<T>(deviceId: string, key: string, value: any): Promise<NativeResult<T>>;
51
- static setDps<T>(deviceId: string, dps: any): Promise<NativeResult<T>>;
52
- static deleteDevice(deviceId: string, isReset: boolean): Promise<NativeResult<any>>;
53
- static renameDevice(deviceId: string, name: string): Promise<NativeResult<any>>;
54
- static toDeviceSettingsPage(deviceId: string, isGroup?: boolean): void;
55
- static toRoutinesPage(params: {
56
- backTitle: string;
57
- deviceId: string;
58
- }): void;
59
- static putJson(deviceId: string, featureType: string, json: string): Promise<Result<any>>;
60
- static getJson(deviceId: string, featureType: string): Promise<Result<any>>;
61
- static groupControl(tyGroupId: number, dps: string, config: string): Promise<Result<any>>;
62
- static getGroupDevices(tyGroupId: number): Promise<Result<DeviceInfo[]>>;
63
- }
64
- export declare const openDownloadFile: (filePath: string) => Promise<unknown>;
65
- export declare const queryDpIds: (dpIds: string, deviceId: string) => Promise<unknown>;
66
- export declare const formatNumber: (num: number, fixed: number, shoGroup?: boolean) => string;
67
- export declare const getTimeZone: () => string;
68
- export declare const getSystemTimeFormat: () => Promise<number>;
69
- export declare const getMicrophoneAccess: () => Promise<boolean>;
70
- export declare const getTuyaCloudData: (devId: string) => Promise<Record<string, any>>;
71
- export {};
@@ -1,3 +0,0 @@
1
- export declare const nativeEventEmitter: import("react-native").EventEmitter;
2
- export declare const addListener: (store: any) => void;
3
- export declare const removeListener: () => void;
@@ -1,25 +0,0 @@
1
- export interface AdvancedData {
2
- title: string;
3
- subtitles?: string[];
4
- statusColor: string;
5
- router: {
6
- key: string;
7
- params?: any;
8
- };
9
- dp?: {
10
- key: string;
11
- code: string;
12
- };
13
- }
14
- export declare enum AdvancedStatus {
15
- Enable = "enable",
16
- Disable = "disable",
17
- Suspend = "suspend"
18
- }
19
- export declare function getAdvancedStatusColor(status: AdvancedStatus): string;
20
- export interface AdvanceCardProps {
21
- data: AdvancedData;
22
- onPress: () => void;
23
- }
24
- declare const AdvanceCard: (props: AdvanceCardProps) => JSX.Element;
25
- export default AdvanceCard;
@@ -1,9 +0,0 @@
1
- import React from 'react';
2
- import { AdvancedData } from './AdvanceCard';
3
- export interface AdvanceListProps {
4
- advanceData: AdvancedData[];
5
- onAdvanceItemClick?: (advanceData: AdvancedData, index: number) => void | undefined;
6
- }
7
- declare function AdvanceList(props: AdvanceListProps): JSX.Element;
8
- declare const _default: React.MemoExoticComponent<typeof AdvanceList>;
9
- export default _default;
@@ -1,6 +0,0 @@
1
- import { DeviceInfo } from '../api/native';
2
- export interface ApplyForDeviceItemProps {
3
- deviceInfo: DeviceInfo;
4
- }
5
- declare const ApplyForDeviceItem: (props: ApplyForDeviceItemProps) => JSX.Element;
6
- export default ApplyForDeviceItem;
@@ -1,7 +0,0 @@
1
- import { DeviceInfo } from '../api/native';
2
- export interface ApplyForDeviceListProps {
3
- devices: DeviceInfo[];
4
- expand?: boolean;
5
- onExpandChange?: (expand: boolean) => void;
6
- }
7
- export default function ApplyForDeviceList(props: ApplyForDeviceListProps): JSX.Element;
@@ -1,6 +0,0 @@
1
- export interface ApplyForTextProps {
2
- expand: boolean;
3
- onExpandChange: (expand: boolean) => void;
4
- }
5
- declare const ApplyForText: (props: ApplyForTextProps) => JSX.Element;
6
- export default ApplyForText;
@@ -1,10 +0,0 @@
1
- import { StyleProp, ViewProps, ViewStyle } from 'react-native';
2
- import { PropsWithChildren } from 'react';
3
- interface CardProps extends PropsWithChildren<ViewProps> {
4
- shadowHeight?: number | undefined;
5
- onPress?: () => void;
6
- onLongPress?: () => void;
7
- containerStyle?: StyleProp<ViewStyle>;
8
- }
9
- export default function Card(props: CardProps): JSX.Element;
10
- export {};
@@ -1,21 +0,0 @@
1
- import { StyleProp, TextStyle, ViewStyle } from 'react-native';
2
- interface CellProps {
3
- title: string;
4
- value: string;
5
- onPress: () => void;
6
- style?: StyleProp<ViewStyle>;
7
- }
8
- export default function Cell(props: CellProps): JSX.Element;
9
- interface CellContentProps {
10
- title: string;
11
- value: string;
12
- style?: StyleProp<ViewStyle>;
13
- titleStyle?: StyleProp<TextStyle>;
14
- valueStyle?: StyleProp<TextStyle>;
15
- iconStyle?: {
16
- color?: any;
17
- size?: number;
18
- };
19
- }
20
- export declare function CellContent(props: CellContentProps): JSX.Element;
21
- export {};
@@ -1,8 +0,0 @@
1
- import { ViewProps } from 'react-native';
2
- import { PropsWithChildren } from 'react';
3
- export interface CircularProgressProps extends PropsWithChildren<ViewProps> {
4
- progress: number;
5
- size: number;
6
- strokeWidth: number;
7
- }
8
- export declare function CircularProgress(props: CircularProgressProps): JSX.Element;
@@ -1,12 +0,0 @@
1
- export interface ColorAdjustViewProps {
2
- h: number;
3
- s: number;
4
- v: number;
5
- minBrightness?: number;
6
- minSaturation?: number;
7
- reserveSV?: boolean;
8
- onHSVChange?: (h: number, s: number, v: number) => void;
9
- onHSVChangeComplete: (h: number, s: number, v: number) => void;
10
- }
11
- declare const ColorAdjustView: (props: ColorAdjustViewProps) => JSX.Element;
12
- export default ColorAdjustView;
@@ -1,73 +0,0 @@
1
- import { Component } from 'react';
2
- import { PanResponderInstance } from 'react-native';
3
- export default class ColorExtractor extends Component<any> {
4
- state: any;
5
- _panResponder: PanResponderInstance;
6
- onColorChange: any;
7
- lastX: any;
8
- lastY: any;
9
- self: any;
10
- startTouchXY: any;
11
- constructor(props: any);
12
- onLayout(_: any): void;
13
- componentDidMount(): void;
14
- componentWillUnmount(): void;
15
- handleTapData(evt: any): void;
16
- handlerData(_evt: any, ges: any, moving: any): void;
17
- getPointValues(locationX: any, locationY: any): {
18
- angle: number;
19
- maxX: number;
20
- maxY: number;
21
- length: number;
22
- };
23
- getPointAngle(x: any, y: any): number;
24
- updateUIWithColor(color: any, isFirst: any): void;
25
- hypotenuse(long: any, angle: any): {
26
- x: number;
27
- y: number;
28
- };
29
- updateColor(x: any, y: any, moving: any, isFirst?: boolean): void;
30
- render(): JSX.Element;
31
- }
32
- export declare const colorTemperature: {
33
- 2700: string;
34
- 2800: string;
35
- 2900: string;
36
- 3000: string;
37
- 3100: string;
38
- 3200: string;
39
- 3300: string;
40
- 3400: string;
41
- 3500: string;
42
- 3600: string;
43
- 3700: string;
44
- 3800: string;
45
- 3900: string;
46
- 4000: string;
47
- 4100: string;
48
- 4200: string;
49
- 4300: string;
50
- 4400: string;
51
- 4500: string;
52
- 4600: string;
53
- 4700: string;
54
- 4800: string;
55
- 4900: string;
56
- 5000: string;
57
- 5100: string;
58
- 5200: string;
59
- 5300: string;
60
- 5400: string;
61
- 5500: string;
62
- 5600: string;
63
- 5700: string;
64
- 5800: string;
65
- 5900: string;
66
- 6000: string;
67
- 6100: string;
68
- 6200: string;
69
- 6300: string;
70
- 6400: string;
71
- 6500: string;
72
- };
73
- export declare const colorTemperatureToColor: (temperature: any) => any;
@@ -1,13 +0,0 @@
1
- export interface ColorTempAdjustViewProps {
2
- colorTemp: number;
3
- brightness: number;
4
- minBrightness?: number;
5
- isSupportTemperature: boolean;
6
- isSupportBrightness: boolean;
7
- onCCTChange?: (cct: number) => void;
8
- onCCTChangeComplete: (cct: number) => void;
9
- onBrightnessChange?: (brightness: number) => void;
10
- onBrightnessChangeComplete: (brightness: number) => void;
11
- }
12
- declare const ColorTempAdjustView: (props: ColorTempAdjustViewProps) => JSX.Element;
13
- export default ColorTempAdjustView;
@@ -1,7 +0,0 @@
1
- import { StyleProp, ViewProps, ViewStyle } from 'react-native';
2
- interface ColorsLineProps extends ViewProps {
3
- colors: string[];
4
- nodeStyle?: StyleProp<ViewStyle>;
5
- }
6
- declare const ColorsLine: (props: ColorsLineProps) => JSX.Element;
7
- export default ColorsLine;
@@ -1,15 +0,0 @@
1
- import { StyleProp, ViewProps, ViewStyle } from 'react-native';
2
- interface ListData {
3
- text: string;
4
- value?: any;
5
- isMax?: boolean;
6
- }
7
- interface CustomListDialogProps extends ViewProps {
8
- itemStyle?: StyleProp<ViewStyle>;
9
- show: boolean;
10
- onDismiss: () => void;
11
- data: ListData[];
12
- onItemPress: (item: any | undefined, index: number) => void;
13
- }
14
- declare const CustomListDialog: (props: CustomListDialogProps) => JSX.Element;
15
- export default CustomListDialog;
@@ -1,10 +0,0 @@
1
- import { StyleProp, TextStyle, ViewStyle } from 'react-native';
2
- interface DeleteButtonProps {
3
- text: string;
4
- onPress: () => void;
5
- style?: StyleProp<ViewStyle>;
6
- textStyle?: StyleProp<TextStyle>;
7
- disabled?: boolean;
8
- }
9
- declare const DeleteButton: (props: DeleteButtonProps) => JSX.Element;
10
- export default DeleteButton;
@@ -1,10 +0,0 @@
1
- import { PropsWithChildren } from 'react';
2
- import { ViewProps } from 'react-native';
3
- interface DialogProps extends PropsWithChildren<ViewProps> {
4
- show: boolean;
5
- hideMask: boolean;
6
- animationType?: 'none' | 'slide' | 'fade';
7
- onRequestClose: () => void;
8
- }
9
- declare const Dialog: (props: DialogProps) => JSX.Element;
10
- export default Dialog;
@@ -1,46 +0,0 @@
1
- import { PropsWithChildren } from 'react';
2
- import { ViewProps } from 'react-native';
3
- export declare type Node = {
4
- color: string;
5
- backgroundColor?: string;
6
- };
7
- interface DrawToolViewProps extends PropsWithChildren<ViewProps> {
8
- switchLed?: boolean;
9
- showEnable?: boolean;
10
- setEnable: (enable: boolean) => void;
11
- adjustType?: 1 | 2 | 3;
12
- setAdjustType: (type: number) => void;
13
- stripStyle?: 'ONLY_LINE' | 'WITH_BEAD';
14
- nodes: Node[];
15
- fixCount?: number;
16
- touchingMode?: 'CLICK' | 'TOUCH';
17
- nodeTouch: (idx: number) => void;
18
- fingerUp: (idxList: string) => void;
19
- hideLightView?: boolean;
20
- isSupportColor?: boolean;
21
- isSupportTemperature?: boolean;
22
- isSupportBrightness?: boolean;
23
- isColorMode?: boolean;
24
- setIsColorMode: (isColorMode: boolean) => void;
25
- blockColor?: string;
26
- h: number;
27
- s: number;
28
- v: number;
29
- onHSVChange: (h: number, s: number, v: number) => void;
30
- onHSVChangeComplete: (h: number, s: number, v: number) => void;
31
- temperature: number;
32
- brightness: number;
33
- onCCTChange: (cct: number) => void;
34
- onCCTChangeComplete: (cct: number) => void;
35
- onBrightnessChange: (brightness: number) => void;
36
- onBrightnessChangeComplete: (brightness: number) => void;
37
- hideLedNum?: boolean;
38
- ledNum?: number;
39
- setLedNum: (num: number) => void;
40
- hidLampAdjustView?: boolean;
41
- hideDisableLight?: boolean;
42
- hideColorize?: boolean;
43
- ledNumModalVisible?: boolean;
44
- }
45
- declare const DrawToolView: (props: DrawToolViewProps) => JSX.Element;
46
- export default DrawToolView;
@@ -1,23 +0,0 @@
1
- import { ViewProps } from 'react-native';
2
- interface FanAdjustViewProps extends ViewProps {
3
- fanEnable: boolean;
4
- fanSpeed: number;
5
- maxFanSpeed?: number;
6
- isSupportDirection?: boolean;
7
- isSupportDisinfect?: boolean;
8
- isSupportMode?: boolean;
9
- directValue?: string;
10
- modeValue?: string;
11
- disinfect?: boolean;
12
- directOptions?: any[];
13
- modeOptions?: any[];
14
- directChange?: (direct: string) => void;
15
- modeChange?: (mode: string) => void;
16
- disinfectChange?: (disinfect: boolean) => void;
17
- onFanSwitch: (fanEnable: boolean) => void;
18
- onFanSpeedChange?: (fanSpeed: number) => void;
19
- onFanSpeedChangeComplete: (fanSpeed: number) => void;
20
- }
21
- declare const FanAdjustView: (props: FanAdjustViewProps) => JSX.Element;
22
- export declare function FanAdjustViewContent(props: FanAdjustViewProps): JSX.Element;
23
- export default FanAdjustView;
@@ -1,11 +0,0 @@
1
- import { ImageStyle, StyleProp, TextStyle, ViewProps, ViewStyle } from 'react-native';
2
- interface InfoTextProps extends ViewProps {
3
- icon: string | number;
4
- text: string;
5
- contentColor?: string;
6
- style?: ViewStyle;
7
- iconStyle?: StyleProp<ImageStyle>;
8
- textStyle?: StyleProp<TextStyle>;
9
- }
10
- declare const InfoText: (props: InfoTextProps) => JSX.Element;
11
- export default InfoText;
@@ -1,10 +0,0 @@
1
- import React from 'react';
2
- import { ColorAdjustViewProps } from './ColorAdjustView';
3
- import { ColorTempAdjustViewProps } from './ColorTempAdjustView';
4
- interface LampConfigViewProps extends ColorAdjustViewProps, ColorTempAdjustViewProps {
5
- isColorMode: boolean;
6
- isSupportColor: boolean;
7
- setIsColorMode: (isColorMode: boolean) => void;
8
- }
9
- declare const _default: React.MemoExoticComponent<(props: LampConfigViewProps) => JSX.Element>;
10
- export default _default;