@jolibox/types 1.1.11-beta.2 → 1.1.11-beta.4

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.
@@ -3,7 +3,6 @@ import { StandardResponse } from './response';
3
3
  export declare const API_GET_SYSTEM_INFO = "API.getSystemInfo";
4
4
  export declare const API_GET_SYSTEM_INFO_SYNC = "API.getSystemInfoSync";
5
5
  export declare const API_ENV = "API.env";
6
- export declare const API_OPEN_SCHEMA_SYNC = "API.openSchemaSync";
7
6
  export interface ISystemInfo {
8
7
  system: string;
9
8
  platform: string;
@@ -17,6 +16,5 @@ export interface APICommandParams {
17
16
  [API_GET_SYSTEM_INFO]: () => Promise<StandardResponse<ISystemInfo>>;
18
17
  [API_GET_SYSTEM_INFO_SYNC]: () => StandardResponse<ISystemInfo>;
19
18
  [API_ENV]: () => StandardResponse<Omit<Omit<Env, 'hostUserInfo'>, 'schema'>>;
20
- [API_OPEN_SCHEMA_SYNC]: (schema: string) => StandardResponse<void>;
21
19
  }
22
20
  export type APICommandType = keyof APICommandParams;
@@ -8,6 +8,7 @@ import { StorageCommandParams } from './storage';
8
8
  import { TaskTrackCommandParams } from './task-track';
9
9
  import { KeyboardCommandParams } from './native/keyboard';
10
10
  import { LoginCommandParams } from './native/login';
11
+ import { RouterCommandParams } from './native/navigate';
11
12
  export * from './runtime';
12
13
  export * from './report';
13
14
  export * from './api';
@@ -19,5 +20,6 @@ export * from './storage';
19
20
  export * from './task-track';
20
21
  export * from './native/keyboard';
21
22
  export * from './native/login';
22
- export type CommandParamsMap = RumtimeCommandParams & ReportCommandParams & APICommandParams & AdsCommandParams & LifeCycleCommandParams & HttpCommandParams & StorageCommandParams & KeyboardCommandParams & TaskTrackCommandParams & LoginCommandParams;
23
+ export * from './native/navigate';
24
+ export type CommandParamsMap = RumtimeCommandParams & ReportCommandParams & APICommandParams & AdsCommandParams & LifeCycleCommandParams & HttpCommandParams & StorageCommandParams & KeyboardCommandParams & TaskTrackCommandParams & LoginCommandParams & RouterCommandParams;
23
25
  export type CommandType = keyof CommandParamsMap;
@@ -0,0 +1,12 @@
1
+ export declare const ROUTER_SDK_OPEN_SCHEMA = "RouterSDK.openSchema";
2
+ export declare const ROUTER_SDK_OPEN_PAGE = "RouterSDK.openPage";
3
+ export declare const ROUTER_SDK_CLOSE_PAGE = "RouterSDK.closePage";
4
+ import { StandardResponse } from '../response';
5
+ export interface RouterCommandParams {
6
+ [ROUTER_SDK_OPEN_SCHEMA]: (schema: string) => StandardResponse<void>;
7
+ [ROUTER_SDK_OPEN_PAGE]: (url: string) => StandardResponse<{
8
+ webviewId: number;
9
+ }>;
10
+ [ROUTER_SDK_CLOSE_PAGE]: (webviewId: number) => StandardResponse<void>;
11
+ }
12
+ export type RouterCommandType = keyof RouterCommandParams;
package/dist/index.d.ts CHANGED
@@ -3,6 +3,7 @@ export * from './sdks/lifecycle';
3
3
  export * from './sdks/storage';
4
4
  export * from './sdks/task-tracker';
5
5
  export * from './sdks/native/keyboard';
6
+ export * from './sdks/router';
6
7
  export * from './events';
7
8
  export * from './commands';
8
9
  export * from './common';
@@ -0,0 +1,8 @@
1
+ import { StandardResponse } from '../commands';
2
+ export interface Router {
3
+ openSchema: (schema: string) => Promise<StandardResponse<void>>;
4
+ openPage: (url: string) => Promise<StandardResponse<{
5
+ webviewId: number;
6
+ }>>;
7
+ closePage: (webviewId: number) => Promise<StandardResponse<void>>;
8
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jolibox/types",
3
3
  "description": "This project is common types used for JS-SDk interfere & implement",
4
- "version": "1.1.11-beta.2",
4
+ "version": "1.1.11-beta.4",
5
5
  "typings": "dist/index.d.ts",
6
6
  "license": "MIT",
7
7
  "files": [