@ray-js/api 1.5.11 → 1.5.13

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.
@@ -4,6 +4,7 @@ type OpenSceneCreateParams = {
4
4
  } & ICommon;
5
5
  export declare function openSceneCreate(params?: OpenSceneCreateParams): Promise<void>;
6
6
  export declare const openCreateScene: typeof openSceneCreate;
7
+ export declare function openCreateOneClickScene(params?: ICommon): Promise<void>;
7
8
  export declare function openUniversalCreateScene(params?: OpenSceneCreateParams): Promise<void>;
8
9
  type OpenSceneEdit = {
9
10
  devId?: string;
@@ -1,9 +1,18 @@
1
+ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
1
2
  import { nativeRouter } from './common';
2
3
  export function openSceneCreate(params) {
3
4
  return nativeRouter('createScene', params);
4
5
  }
5
6
  export const openCreateScene = openSceneCreate;
6
7
 
8
+ // App 基线 5.13.0 以上开始支持
9
+ export function openCreateOneClickScene(params) {
10
+ const p = _objectSpread({
11
+ biz_type: 'click_execution'
12
+ }, params);
13
+ return nativeRouter('addScene', p);
14
+ }
15
+
7
16
  // 兼容Android 端仅支持 Zigbee 本地场景, Android使用createSmartScene
8
17
  export function openUniversalCreateScene(params) {
9
18
  const url = ty.getSystemInfoSync().platform === 'android' ? 'createSmartScene' : 'createScene';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ray-js/api",
3
- "version": "1.5.11",
3
+ "version": "1.5.13",
4
4
  "description": "Ray universal api",
5
5
  "keywords": [
6
6
  "ray"
@@ -29,14 +29,14 @@
29
29
  "watch": "ray start --type=component"
30
30
  },
31
31
  "dependencies": {
32
- "@ray-js/framework": "1.5.11",
33
- "@ray-js/router": "1.5.11",
32
+ "@ray-js/framework": "1.5.13",
33
+ "@ray-js/router": "1.5.13",
34
34
  "@ray-js/wechat": "^0.2.9",
35
35
  "base64-browser": "^1.0.1",
36
36
  "query-string": "^7.1.3"
37
37
  },
38
38
  "devDependencies": {
39
- "@ray-js/cli": "1.5.11",
39
+ "@ray-js/cli": "1.5.13",
40
40
  "art-template": "^4.13.2",
41
41
  "fs-extra": "^10.1.0",
42
42
  "miniprogram-api-typings": "^3.12.2",
@@ -46,5 +46,5 @@
46
46
  "access": "public",
47
47
  "registry": "https://registry.npmjs.org"
48
48
  },
49
- "gitHead": "194699f3ea5e22c9d6ee341c82a4d56df9287ecb"
49
+ "gitHead": "632d2d9fa789c75828089087b4ba734e6daa3b34"
50
50
  }