@ray-js/api 0.6.22-beta-2 → 0.6.25

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.
@@ -978,31 +978,30 @@ declare namespace ty {
978
978
  */
979
979
  export function offNativeEvent(listener: (params: NativeUploadData) => void): void
980
980
 
981
- export enum HighwayMethod {
981
+ export type HighwayMethod =
982
982
  /** HTTP 请求 OPTIONS */
983
- OPTIONS = 'OPTIONS',
983
+ | 'OPTIONS'
984
984
 
985
985
  /** HTTP 请求 GET */
986
- GET = 'GET',
986
+ | 'GET'
987
987
 
988
988
  /** HTTP 请求 HEAD */
989
- HEAD = 'HEAD',
989
+ | 'HEAD'
990
990
 
991
991
  /** HTTP 请求 POST */
992
- POST = 'POST',
992
+ | 'POST'
993
993
 
994
994
  /** HTTP 请求 PUT */
995
- PUT = 'PUT',
995
+ | 'PUT'
996
996
 
997
997
  /** HTTP 请求 DELETE */
998
- DELETE = 'DELETE',
998
+ | 'DELETE'
999
999
 
1000
1000
  /** HTTP 请求 TRACE */
1001
- TRACE = 'TRACE',
1001
+ | 'TRACE'
1002
1002
 
1003
1003
  /** HTTP 请求 TRACE */
1004
- CONNECT = 'CONNECT',
1005
- }
1004
+ | 'CONNECT'
1006
1005
 
1007
1006
  export type ReferrerInfo = {
1008
1007
  /** 来源小程序、公众号或 App 的 appId */
@@ -1,81 +1,81 @@
1
1
  /// <reference path="../@types/BaseKit.d.ts" />
2
- export declare const stopAccelerometer: typeof ty.stopAccelerometer;
3
- export declare const startAccelerometer: typeof ty.startAccelerometer;
4
- export declare const getAudioFileDuration: typeof ty.getAudioFileDuration;
5
- export declare const authorize: typeof ty.authorize;
6
- export declare const authorizeStatus: typeof ty.authorizeStatus;
7
- export declare const navigateToMiniProgram: typeof ty.navigateToMiniProgram;
8
- export declare const startCompass: typeof ty.startCompass;
9
- export declare const stopCompass: typeof ty.stopCompass;
10
- export declare const startDeviceMotionListening: typeof ty.startDeviceMotionListening;
11
- export declare const stopDeviceMotionListening: typeof ty.stopDeviceMotionListening;
12
- export declare const startGyroscope: typeof ty.startGyroscope;
13
- export declare const stopGyroscope: typeof ty.stopGyroscope;
14
- export declare const chooseImage: typeof ty.chooseImage;
15
- export declare const chooseMedia: typeof ty.chooseMedia;
16
- export declare const chooseCropImage: typeof ty.chooseCropImage;
17
- export declare const previewImage: typeof ty.previewImage;
18
- export declare const getImageInfo: typeof ty.getImageInfo;
19
- export declare const getVideoInfo: typeof ty.getVideoInfo;
20
- export declare const saveVideoToPhotosAlbum: typeof ty.saveVideoToPhotosAlbum;
21
- export declare const showToast: typeof ty.showToast;
22
- export declare const showModal: typeof ty.showModal;
23
- export declare const showLoading: typeof ty.showLoading;
24
- export declare const showActionSheet: typeof ty.showActionSheet;
25
- export declare const hideToast: typeof ty.hideToast;
26
- export declare const hideLoading: typeof ty.hideLoading;
27
- export declare const makePhoneCall: typeof ty.makePhoneCall;
28
- export declare const setClipboardData: typeof ty.setClipboardData;
29
- export declare const getClipboardData: typeof ty.getClipboardData;
30
- export declare const updateVolume: typeof ty.updateVolume;
31
- export declare const getCurrentVolume: typeof ty.getCurrentVolume;
32
- export declare const registerSystemVolumeChange: typeof ty.registerSystemVolumeChange;
33
- export declare const unRegisterSystemVolumeChange: typeof ty.unRegisterSystemVolumeChange;
34
- export declare const getSystemSetting: typeof ty.getSystemSetting;
35
- export declare const getMobileDeviceInfo: typeof ty.getDeviceInfo;
36
- export declare const getSystemInfo: typeof ty.getSystemInfo;
37
- export declare const getSystemInfoSync: typeof ty.getSystemInfoSync;
38
- export declare const getWifiList: typeof ty.getWifiList;
39
- export declare const getConnectedWifi: typeof ty.getConnectedWifi;
40
- export declare const openSystemBluetoothSetting: typeof ty.openSystemBluetoothSetting;
41
- export declare const getNetworkType: typeof ty.getNetworkType;
42
- export declare const setScreenBrightness: typeof ty.setScreenBrightness;
43
- export declare const getScreenBrightness: typeof ty.getScreenBrightness;
44
- export declare const setKeepScreenOn: typeof ty.setKeepScreenOn;
45
- export declare const vibrateShort: typeof ty.vibrateShort;
46
- export declare const vibrateLong: typeof ty.vibrateLong;
47
- export declare const scanCode: typeof ty.scanCode;
48
- export declare const setStorage: typeof ty.setStorage;
49
- export declare const setStorageSync: typeof ty.setStorageSync;
50
- export declare const getStorage: typeof ty.getStorage;
51
- export declare const getStorageSync: typeof ty.getStorageSync;
52
- export declare const removeStorage: typeof ty.removeStorage;
53
- export declare const removeStorageSync: typeof ty.removeStorageSync;
54
- export declare const clearStorage: typeof ty.clearStorage;
55
- export declare const clearStorageSync: typeof ty.clearStorageSync;
56
- export declare const onSystemVolumeChangeEvent: typeof ty.onSystemVolumeChangeEvent;
57
- export declare const offSystemVolumeChangeEvent: typeof ty.offSystemVolumeChangeEvent;
58
- export declare const onGetWifiList: typeof ty.onGetWifiList;
59
- export declare const offGetWifiList: typeof ty.offGetWifiList;
60
- export declare const onRecordingEvent: typeof ty.onRecordingEvent;
61
- export declare const offRecordingEvent: typeof ty.offRecordingEvent;
62
- export declare const onAccelerometerChange: typeof ty.onAccelerometerChange;
63
- export declare const offAccelerometerChange: typeof ty.offAccelerometerChange;
64
- export declare const onCompassChange: typeof ty.onCompassChange;
65
- export declare const offCompassChange: typeof ty.offCompassChange;
66
- export declare const onDeviceMotionChange: typeof ty.onDeviceMotionChange;
67
- export declare const offDeviceMotionChange: typeof ty.offDeviceMotionChange;
68
- export declare const onGyroscopeChange: typeof ty.onGyroscopeChange;
69
- export declare const offGyroscopeChange: typeof ty.offGyroscopeChange;
70
- export declare const onMemoryWarning: typeof ty.onMemoryWarning;
71
- export declare const offMemoryWarning: typeof ty.offMemoryWarning;
72
- export declare const onBluetoothAdapterStateChange: typeof ty.onBluetoothAdapterStateChange;
73
- export declare const offBluetoothAdapterStateChange: typeof ty.offBluetoothAdapterStateChange;
74
- export declare const onNetworkStatusChange: typeof ty.onNetworkStatusChange;
75
- export declare const offNetworkStatusChange: typeof ty.offNetworkStatusChange;
76
- export declare const createInnerAudioContext: typeof ty.createInnerAudioContext;
77
- export declare const downloadFile: typeof ty.downloadFile;
78
- export declare const getFileSystemManager: typeof ty.getFileSystemManager;
79
- export declare const request: typeof ty.request;
80
- export declare const getRecorderManager: typeof ty.getRecorderManager;
81
- export declare const uploadFile: typeof ty.uploadFile;
2
+ export declare const stopAccelerometer: any;
3
+ export declare const startAccelerometer: any;
4
+ export declare const getAudioFileDuration: any;
5
+ export declare const authorize: any;
6
+ export declare const authorizeStatus: any;
7
+ export declare const navigateToMiniProgram: any;
8
+ export declare const startCompass: any;
9
+ export declare const stopCompass: any;
10
+ export declare const startDeviceMotionListening: any;
11
+ export declare const stopDeviceMotionListening: any;
12
+ export declare const startGyroscope: any;
13
+ export declare const stopGyroscope: any;
14
+ export declare const chooseImage: any;
15
+ export declare const chooseMedia: any;
16
+ export declare const chooseCropImage: any;
17
+ export declare const previewImage: any;
18
+ export declare const getImageInfo: any;
19
+ export declare const getVideoInfo: any;
20
+ export declare const saveVideoToPhotosAlbum: any;
21
+ export declare const showToast: any;
22
+ export declare const showModal: any;
23
+ export declare const showLoading: any;
24
+ export declare const showActionSheet: any;
25
+ export declare const hideToast: any;
26
+ export declare const hideLoading: any;
27
+ export declare const makePhoneCall: any;
28
+ export declare const setClipboardData: any;
29
+ export declare const getClipboardData: any;
30
+ export declare const updateVolume: any;
31
+ export declare const getCurrentVolume: any;
32
+ export declare const registerSystemVolumeChange: any;
33
+ export declare const unRegisterSystemVolumeChange: any;
34
+ export declare const getSystemSetting: any;
35
+ export declare const getMobileDeviceInfo: any;
36
+ export declare const getSystemInfo: any;
37
+ export declare const getSystemInfoSync: any;
38
+ export declare const getWifiList: any;
39
+ export declare const getConnectedWifi: any;
40
+ export declare const openSystemBluetoothSetting: any;
41
+ export declare const getNetworkType: any;
42
+ export declare const setScreenBrightness: any;
43
+ export declare const getScreenBrightness: any;
44
+ export declare const setKeepScreenOn: any;
45
+ export declare const vibrateShort: any;
46
+ export declare const vibrateLong: any;
47
+ export declare const scanCode: any;
48
+ export declare const setStorage: any;
49
+ export declare const setStorageSync: any;
50
+ export declare const getStorage: any;
51
+ export declare const getStorageSync: any;
52
+ export declare const removeStorage: any;
53
+ export declare const removeStorageSync: any;
54
+ export declare const clearStorage: any;
55
+ export declare const clearStorageSync: any;
56
+ export declare const onSystemVolumeChangeEvent: any;
57
+ export declare const offSystemVolumeChangeEvent: any;
58
+ export declare const onGetWifiList: any;
59
+ export declare const offGetWifiList: any;
60
+ export declare const onRecordingEvent: any;
61
+ export declare const offRecordingEvent: any;
62
+ export declare const onAccelerometerChange: any;
63
+ export declare const offAccelerometerChange: any;
64
+ export declare const onCompassChange: any;
65
+ export declare const offCompassChange: any;
66
+ export declare const onDeviceMotionChange: any;
67
+ export declare const offDeviceMotionChange: any;
68
+ export declare const onGyroscopeChange: any;
69
+ export declare const offGyroscopeChange: any;
70
+ export declare const onMemoryWarning: any;
71
+ export declare const offMemoryWarning: any;
72
+ export declare const onBluetoothAdapterStateChange: any;
73
+ export declare const offBluetoothAdapterStateChange: any;
74
+ export declare const onNetworkStatusChange: any;
75
+ export declare const offNetworkStatusChange: any;
76
+ export declare const createInnerAudioContext: any;
77
+ export declare const downloadFile: any;
78
+ export declare const getFileSystemManager: any;
79
+ export declare const request: any;
80
+ export declare const getRecorderManager: any;
81
+ export declare const uploadFile: any;
@@ -52,7 +52,6 @@ export declare const getDeviceInfo: typeof ty.device.getDeviceInfo;
52
52
  export declare const getProductInfo: typeof ty.device.getProductInfo;
53
53
  export declare const getSubDeviceInfoList: typeof ty.device.getSubDeviceInfoList;
54
54
  export declare const validDeviceOnlineType: typeof ty.device.validDeviceOnlineType;
55
- export declare const publishDps: typeof ty.device.publishDps;
56
55
  export declare const publishCommands: typeof ty.device.publishCommands;
57
56
  export declare const publishDpsWithPipeType: typeof ty.device.publishDpsWithPipeType;
58
57
  export declare const queryDps: typeof ty.device.queryDps;
@@ -158,10 +158,9 @@ export var getSubDeviceInfoList = factory('getSubDeviceInfoList', {
158
158
  });
159
159
  export var validDeviceOnlineType = factory('validDeviceOnlineType', {
160
160
  "namespace": "device"
161
- });
162
- export var publishDps = factory('publishDps', {
163
- "namespace": "device"
164
- });
161
+ }); // Note: v1.0.0 由于Panel-sdk中封装,所以废弃原有DeviceKit中提供的 publishDps, Panel-sdk中封装的publishDps兼容原有publishDps。
162
+ // export const publishDps = factory('publishDps', {"namespace":"device"}) as typeof ty.device.publishDps
163
+
165
164
  export var publishCommands = factory('publishCommands', {
166
165
  "namespace": "device"
167
166
  });
package/lib/index.d.ts CHANGED
@@ -24,3 +24,4 @@ export { default as setNavigationBarBack } from './setNavigationBarBack';
24
24
  * 提供 glboal-api 将 wx / ty 对象暴露出去,供给业务在Ray为显示导出api时进行快速响应开发。
25
25
  */
26
26
  export { default as globalApi } from './global-api';
27
+ export * from './panel';
package/lib/index.js CHANGED
@@ -24,4 +24,5 @@ export { default as setNavigationBarBack } from './setNavigationBarBack';
24
24
  * 提供 glboal-api 将 wx / ty 对象暴露出去,供给业务在Ray为显示导出api时进行快速响应开发。
25
25
  */
26
26
 
27
- export { default as globalApi } from './global-api';
27
+ export { default as globalApi } from './global-api';
28
+ export * from './panel';
@@ -0,0 +1,3 @@
1
+ # panel
2
+
3
+ @ray-js/api 导出部分原 @ray-js/panel-sdk 的能力。包括:面板能力、多语言、云能力
@@ -0,0 +1,4 @@
1
+ import { kit } from '@ray-js/panel-sdk';
2
+ export * from '@ray-js/panel-cloud';
3
+ declare const initPanelEnvironment: typeof kit.initPanelEnvironment, publishDps: typeof kit.publishDps, I18N: typeof kit.I18N;
4
+ export { initPanelEnvironment, publishDps, I18N };
@@ -0,0 +1,6 @@
1
+ import { kit } from '@ray-js/panel-sdk';
2
+ export * from '@ray-js/panel-cloud';
3
+ var initPanelEnvironment = kit.initPanelEnvironment,
4
+ publishDps = kit.publishDps,
5
+ I18N = kit.I18N;
6
+ export { initPanelEnvironment, publishDps, I18N };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ray-js/api",
3
- "version": "0.6.22-beta-2",
3
+ "version": "0.6.25",
4
4
  "description": "Ray universal api",
5
5
  "keywords": [
6
6
  "ray"
@@ -26,11 +26,13 @@
26
26
  "build:kit:api": "node scripts/api-creator.mjs"
27
27
  },
28
28
  "dependencies": {
29
- "@ray-js/framework": "^0.6.22-beta-2",
30
- "@ray-js/router": "^0.6.22-beta-2"
29
+ "@ray-js/framework": "^0.6.25",
30
+ "@ray-js/router": "^0.6.25"
31
31
  },
32
32
  "devDependencies": {
33
- "@ray-js/cli": "^0.6.22-beta-2",
33
+ "@ray-js/cli": "^0.6.25",
34
+ "@ray-js/panel-cloud": "^1.2.0",
35
+ "@ray-js/panel-sdk": "^1.2.0",
34
36
  "art-template": "^4.13.2",
35
37
  "fs-extra": "^10.1.0",
36
38
  "miniprogram-api-typings": "^3.4.3",
@@ -42,6 +44,6 @@
42
44
  "email": "tuyafe@tuya.com"
43
45
  }
44
46
  ],
45
- "gitHead": "5d621bf1561047175b967cdf3aa35446f7d7198a",
47
+ "gitHead": "410b4714bc5f496978ddd642ee092f0fe3d8bf8d",
46
48
  "repository": {}
47
49
  }