larksr_websdk 3.2.5 → 3.2.9

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 (62) hide show
  1. package/README.md +35 -24
  2. package/dist/doc/index.md +43 -3
  3. package/dist/larksr-web-sdk.min.js +3 -3
  4. package/dist/types/api.d.ts +23 -0
  5. package/dist/types/appli_params.d.ts +21 -2
  6. package/dist/types/index.d.ts +2 -1
  7. package/dist/types/larksr.d.ts +98 -8
  8. package/dist/types/screen_state.d.ts +6 -1
  9. package/package.json +9 -6
  10. package/types/api.d.ts +108 -0
  11. package/types/appli_params.d.ts +263 -0
  12. package/{dist/types → types}/common/cmd.d.ts +0 -0
  13. package/{dist/types → types}/common/constant.d.ts +0 -0
  14. package/{dist/types → types}/common/interface.d.ts +0 -0
  15. package/types/config.d.ts +59 -0
  16. package/{dist/types → types}/event/bus.d.ts +0 -0
  17. package/{dist/types → types}/event/event_base.d.ts +0 -0
  18. package/{dist/types → types}/event/events.d.ts +0 -0
  19. package/{dist/types → types}/event/iframe_poster.d.ts +0 -0
  20. package/{dist/types → types}/event/message.d.ts +0 -0
  21. package/types/index.d.ts +25 -0
  22. package/{dist/types → types}/lark/Worker.d.ts +0 -0
  23. package/{dist/types → types}/lark/application.d.ts +23 -13
  24. package/{dist/types → types}/lark/custom.d.ts +0 -0
  25. package/{dist/types → types}/lark/lark_event_type.d.ts +0 -0
  26. package/{dist/types → types}/lark/message.d.ts +5 -4
  27. package/{dist/types → types}/lark/peer_connection.d.ts +20 -17
  28. package/{dist/types → types}/lark/sdp_util.d.ts +0 -0
  29. package/types/lark/test_pixel_streaming.d.ts +54 -0
  30. package/{dist/types → types}/lark/websocket_channel.d.ts +0 -0
  31. package/{dist/types → types}/lark/websocket_proxy.d.ts +0 -0
  32. package/types/larksr.d.ts +548 -0
  33. package/{dist/types → types}/localization/base.d.ts +0 -0
  34. package/{dist/types → types}/localization/gesture_ins.d.ts +0 -0
  35. package/{dist/types → types}/localization/language.d.ts +0 -0
  36. package/{dist/types → types}/localization/loader.d.ts +0 -0
  37. package/{dist/types → types}/localization/message.d.ts +0 -0
  38. package/{dist/types → types}/localization/ui.d.ts +0 -0
  39. package/{dist/types → types}/operation/gamepad_handler.d.ts +0 -0
  40. package/{dist/types → types}/operation/gesture.d.ts +0 -0
  41. package/{dist/types → types}/operation/gesture_handler.d.ts +0 -0
  42. package/{dist/types → types}/operation/handler_base.d.ts +0 -0
  43. package/{dist/types → types}/operation/keyboard_handler.d.ts +0 -0
  44. package/{dist/types → types}/operation/keymap.d.ts +0 -0
  45. package/{dist/types → types}/operation/letter_keymap.d.ts +0 -0
  46. package/{dist/types → types}/operation/mouse_handler.d.ts +0 -0
  47. package/{dist/types → types}/operation/num_keymap.d.ts +0 -0
  48. package/{dist/types → types}/operation/operation.d.ts +7 -1
  49. package/types/operation/pixel_streaming_input.d.ts +82 -0
  50. package/{dist/types → types}/operation/touch_handler.d.ts +0 -0
  51. package/{dist/types → types}/operation/utils.d.ts +0 -0
  52. package/{dist/types → types}/protobuf/cloudlark.d.ts +6466 -5944
  53. package/{dist/types → types}/protobuf/message.d.ts +0 -0
  54. package/types/screen_state.d.ts +113 -0
  55. package/types/sdk_auth.d.ts +11 -0
  56. package/{dist/types → types}/utils/browser_type.d.ts +0 -0
  57. package/{dist/types → types}/utils/capabilities.d.ts +0 -0
  58. package/{dist/types → types}/utils/full_screen.d.ts +0 -0
  59. package/{dist/types → types}/utils/lock_pointer.d.ts +0 -0
  60. package/{dist/types → types}/utils/log.d.ts +1 -1
  61. package/{dist/types → types}/utils/scale_mode.d.ts +0 -0
  62. package/{dist/types → types}/utils/unit.d.ts +1 -0
File without changes
@@ -0,0 +1,113 @@
1
+ import { ViewPort } from "./common/interface";
2
+ import { IAppliParams } from "./appli_params";
3
+ import { CloudLark } from "./protobuf/cloudlark";
4
+ import ScaleMode from "./utils/scale_mode";
5
+ import { LocalEvent, EventBase } from './event/event_base';
6
+ import { LarkSR } from "./larksr";
7
+ export interface ContainerSize {
8
+ marginTop: number;
9
+ marginLeft: number;
10
+ width: number;
11
+ height: number;
12
+ }
13
+ export interface ContainerStyle {
14
+ marginTop: string;
15
+ marginLeft: string;
16
+ width: string;
17
+ height: string;
18
+ cursor: any;
19
+ }
20
+ export declare type ScreenOrientation = 'portrait' | 'landscape';
21
+ export declare enum CursorType {
22
+ ARROW = 0,
23
+ IBEAM = 1,
24
+ WAIT = 2,
25
+ CROSS = 3,
26
+ SIZENWSE = 4,
27
+ SIZENESW = 5,
28
+ SIZEWE = 6,
29
+ SIZENS = 7,
30
+ SIZEALL = 8,
31
+ NO = 9,
32
+ HAND = 10,
33
+ CUSTOM = 11,
34
+ DEFAULT = 1000
35
+ }
36
+ export interface SyncCursorStyle {
37
+ type: CursorType;
38
+ hotX: number;
39
+ hotY: number;
40
+ width: number;
41
+ height: number;
42
+ customBase64: string;
43
+ }
44
+ export declare const enum SCREEN_EVENT_TYPE {
45
+ ReSize = 0
46
+ }
47
+ export interface ScreenEvent extends LocalEvent<SCREEN_EVENT_TYPE> {
48
+ container: ContainerSize;
49
+ viewPort: ViewPort;
50
+ }
51
+ export default class ScreenState extends EventBase<SCREEN_EVENT_TYPE, ScreenEvent> {
52
+ get appSize(): CloudLark.IAppResize;
53
+ set appSize(size: CloudLark.IAppResize);
54
+ private _appSize;
55
+ get viewPort(): ViewPort;
56
+ private _viewPort;
57
+ get viewPortStyle(): string;
58
+ get orientationIndexStyle(): {
59
+ width: string;
60
+ height: string;
61
+ top: string;
62
+ left: string;
63
+ transform: string;
64
+ transformOrigin: string;
65
+ backgroundColor: string;
66
+ } | {
67
+ width: string;
68
+ height: string;
69
+ transform: string;
70
+ transformOrigin: string;
71
+ backgroundColor: string;
72
+ top?: undefined;
73
+ left?: undefined;
74
+ };
75
+ get container(): ContainerSize;
76
+ private _container;
77
+ get containerStyle(): string;
78
+ get screenOrientation(): ScreenOrientation;
79
+ private _screenOrientation;
80
+ get scaleMode(): ScaleMode;
81
+ private _scaleMode;
82
+ get isFullScreen(): boolean;
83
+ private _isFullScreen;
84
+ get isLockMouse(): boolean;
85
+ private _isLockMouse;
86
+ get cursorStyle(): SyncCursorStyle;
87
+ set cursorStyle(style: SyncCursorStyle);
88
+ private _cursorStyle;
89
+ private get cursorCSSStyle();
90
+ get appMouseMode(): CloudLark.IAppMouseMode;
91
+ set appMouseMode(mode: CloudLark.IAppMouseMode);
92
+ private _appMouseMode;
93
+ get operateScale(): {
94
+ scaleX: number;
95
+ scaleY: number;
96
+ };
97
+ get initCursorMode(): boolean;
98
+ private _initCursorMode;
99
+ get isMobile(): boolean;
100
+ private _isMobile;
101
+ get isLocalRenderMouse(): boolean | null | undefined;
102
+ get isLockMosue(): boolean | null | undefined;
103
+ get rootElement(): HTMLElement;
104
+ private _rootElement;
105
+ private videoViewPort;
106
+ private mobileForceLandScape;
107
+ private bgColor;
108
+ private handelRootElementSize;
109
+ private larksr;
110
+ constructor(rootElement: HTMLElement, params: IAppliParams, larksr: LarkSR, handelRootElementSize?: boolean);
111
+ reset(params: IAppliParams): void;
112
+ resize(): void;
113
+ }
@@ -0,0 +1,11 @@
1
+ export declare class SDKAuth {
2
+ get isSuccess(): boolean;
3
+ private _isSuccess;
4
+ get error(): any;
5
+ private _error;
6
+ constructor();
7
+ auth(id: string): Promise<void>;
8
+ signature(key: string, secret: string, timestamp: string): string;
9
+ check(id: string): boolean;
10
+ save(id: string, expire: string): void;
11
+ }
File without changes
File without changes
File without changes
File without changes
@@ -3,7 +3,7 @@ export declare class Level {
3
3
  static WARN: string;
4
4
  static ERR: string;
5
5
  static TRACE: string;
6
- static getLevelIndex(level: string): 0 | 1 | 2 | 3 | 4;
6
+ static getLevelIndex(level: string): 2 | 0 | 1 | 3 | 4;
7
7
  }
8
8
  export interface LogObserver {
9
9
  onLog(msg: string): void;
File without changes
@@ -4,6 +4,7 @@
4
4
  import { CSSPosition, Point, ViewPort, OffsetView, Vector } from '../common/interface';
5
5
  export default class Unit {
6
6
  static queryString(name: string): string;
7
+ static queryURL(uri: URL, name: string): string;
7
8
  /**
8
9
  * 深度拷贝对象,创建新对象
9
10
  * @param source 输入对象