@coasys/ad4m-connect 0.8.0-fix → 0.8.0
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.
- package/dist/components/AgentLocked.d.ts +4 -4
- package/dist/components/CapNotMatching.d.ts +1 -1
- package/dist/components/CouldNotMakeRequest.d.ts +1 -1
- package/dist/components/Disconnected.d.ts +3 -3
- package/dist/components/Header.d.ts +1 -1
- package/dist/components/InvalidToken.d.ts +3 -3
- package/dist/components/Loading.d.ts +1 -1
- package/dist/components/Logo.d.ts +1 -1
- package/dist/components/RequestCapability.d.ts +8 -8
- package/dist/components/ScanQRCode.d.ts +5 -5
- package/dist/components/Settings.d.ts +11 -11
- package/dist/components/Start.d.ts +8 -8
- package/dist/components/VerifyCode.d.ts +6 -6
- package/dist/core.d.ts +55 -55
- package/dist/core.js +41 -41
- package/dist/electron.d.ts +2 -2
- package/dist/utils.d.ts +9 -9
- package/dist/utils.js +1 -1
- package/dist/web.d.ts +46 -46
- package/dist/web.js +68 -68
- package/package.json +70 -70
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export default function AgentLocked({ unlockAgent, reconnect }: {
|
|
2
|
-
unlockAgent: any;
|
|
3
|
-
reconnect: any;
|
|
4
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function AgentLocked({ unlockAgent, reconnect }: {
|
|
2
|
+
unlockAgent: any;
|
|
3
|
+
reconnect: any;
|
|
4
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function CapNotMatched(): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function CapNotMatched(): import("lit").TemplateResult<1>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function CouldNotMakeRequest(): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function CouldNotMakeRequest(): import("lit").TemplateResult<1>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export default function Disconnected({ reconnect }: {
|
|
2
|
-
reconnect: any;
|
|
3
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Disconnected({ reconnect }: {
|
|
2
|
+
reconnect: any;
|
|
3
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function Header(): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Header(): import("lit").TemplateResult<1>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export default function InvalidToken({ requestCapability }: {
|
|
2
|
-
requestCapability: any;
|
|
3
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function InvalidToken({ requestCapability }: {
|
|
2
|
+
requestCapability: any;
|
|
3
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function Loading(): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Loading(): import("lit").TemplateResult<1>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function Logo(): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Logo(): import("lit").TemplateResult<1>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export default function CapNotMatchedFirst({ capabilities, appname, appiconpath, changeState, setOpen, requestCapability, }: {
|
|
2
|
-
capabilities: any;
|
|
3
|
-
appname: any;
|
|
4
|
-
appiconpath: any;
|
|
5
|
-
changeState: any;
|
|
6
|
-
setOpen: any;
|
|
7
|
-
requestCapability: any;
|
|
8
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function CapNotMatchedFirst({ capabilities, appname, appiconpath, changeState, setOpen, requestCapability, }: {
|
|
2
|
+
capabilities: any;
|
|
3
|
+
appname: any;
|
|
4
|
+
appiconpath: any;
|
|
5
|
+
changeState: any;
|
|
6
|
+
setOpen: any;
|
|
7
|
+
requestCapability: any;
|
|
8
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export default function ScanQRCode({ changeState, onSuccess, uiState }: {
|
|
2
|
-
changeState: any;
|
|
3
|
-
onSuccess: any;
|
|
4
|
-
uiState: any;
|
|
5
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function ScanQRCode({ changeState, onSuccess, uiState }: {
|
|
2
|
+
changeState: any;
|
|
3
|
+
onSuccess: any;
|
|
4
|
+
uiState: any;
|
|
5
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export default function Settings({ port, url, isRemote, connectToPort, changeIsRemote, connectRemote, changeState, changeUrl, changePort, }: {
|
|
2
|
-
port: any;
|
|
3
|
-
url: any;
|
|
4
|
-
isRemote: any;
|
|
5
|
-
connectToPort: any;
|
|
6
|
-
changeIsRemote: any;
|
|
7
|
-
connectRemote: any;
|
|
8
|
-
changeState: any;
|
|
9
|
-
changeUrl: any;
|
|
10
|
-
changePort: any;
|
|
11
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Settings({ port, url, isRemote, connectToPort, changeIsRemote, connectRemote, changeState, changeUrl, changePort, }: {
|
|
2
|
+
port: any;
|
|
3
|
+
url: any;
|
|
4
|
+
isRemote: any;
|
|
5
|
+
connectToPort: any;
|
|
6
|
+
changeIsRemote: any;
|
|
7
|
+
connectRemote: any;
|
|
8
|
+
changeState: any;
|
|
9
|
+
changeUrl: any;
|
|
10
|
+
changePort: any;
|
|
11
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export default function Start({ connect, isMobile, hasClickedDownload, changeState, onDownloaded, scanQrcode, }: {
|
|
2
|
-
connect: any;
|
|
3
|
-
isMobile: any;
|
|
4
|
-
hasClickedDownload: any;
|
|
5
|
-
changeState: any;
|
|
6
|
-
onDownloaded: any;
|
|
7
|
-
scanQrcode: any;
|
|
8
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Start({ connect, isMobile, hasClickedDownload, changeState, onDownloaded, scanQrcode, }: {
|
|
2
|
+
connect: any;
|
|
3
|
+
isMobile: any;
|
|
4
|
+
hasClickedDownload: any;
|
|
5
|
+
changeState: any;
|
|
6
|
+
onDownloaded: any;
|
|
7
|
+
scanQrcode: any;
|
|
8
|
+
}): import("lit").TemplateResult<1>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export default function Request({ code, changeState, verifyCode, changeCode }: {
|
|
2
|
-
code: any;
|
|
3
|
-
changeState: any;
|
|
4
|
-
verifyCode: any;
|
|
5
|
-
changeCode: any;
|
|
6
|
-
}): import("lit").TemplateResult<1>;
|
|
1
|
+
export default function Request({ code, changeState, verifyCode, changeCode }: {
|
|
2
|
+
code: any;
|
|
3
|
+
changeState: any;
|
|
4
|
+
verifyCode: any;
|
|
5
|
+
changeCode: any;
|
|
6
|
+
}): import("lit").TemplateResult<1>;
|
package/dist/core.d.ts
CHANGED
|
@@ -1,55 +1,55 @@
|
|
|
1
|
-
import { ApolloClient, NormalizedCacheObject } from "@apollo/client/core";
|
|
2
|
-
import { Client as WSClient } from "graphql-ws";
|
|
3
|
-
import { Ad4mClient, CapabilityInput } from "@coasys/ad4m";
|
|
4
|
-
export type Ad4mConnectOptions = {
|
|
5
|
-
appName: string;
|
|
6
|
-
appDesc: string;
|
|
7
|
-
appDomain: string;
|
|
8
|
-
appUrl?: string;
|
|
9
|
-
appIconPath?: string;
|
|
10
|
-
capabilities: CapabilityInput[];
|
|
11
|
-
dataPath?: string;
|
|
12
|
-
port?: number;
|
|
13
|
-
token?: string;
|
|
14
|
-
url?: string;
|
|
15
|
-
};
|
|
16
|
-
export type AuthStates = "authenticated" | "locked" | "unauthenticated";
|
|
17
|
-
export type Event = "authstatechange" | "connectionstatechange" | "configstatechange";
|
|
18
|
-
export type ConfigStates = "port" | "url" | "token";
|
|
19
|
-
export type ConnectionStates = "connecting" | "connected" | "error" | "port_not_found" | "not_connected" | "disconnected";
|
|
20
|
-
export default class Ad4mConnect {
|
|
21
|
-
activeSocket: WebSocket;
|
|
22
|
-
requestedRestart: boolean;
|
|
23
|
-
authState: AuthStates;
|
|
24
|
-
connectionState: ConnectionStates;
|
|
25
|
-
wsClient?: WSClient;
|
|
26
|
-
apolloClient?: ApolloClient<NormalizedCacheObject>;
|
|
27
|
-
ad4mClient?: Ad4mClient;
|
|
28
|
-
requestId?: string;
|
|
29
|
-
url: string;
|
|
30
|
-
token: string;
|
|
31
|
-
port: number;
|
|
32
|
-
capabilities: CapabilityInput[];
|
|
33
|
-
appName: string;
|
|
34
|
-
appDesc: string;
|
|
35
|
-
appDomain: string;
|
|
36
|
-
appIconPath: string;
|
|
37
|
-
appUrl?: string;
|
|
38
|
-
listeners: Record<Event, Function[]>;
|
|
39
|
-
constructor({ appName, appDesc, appIconPath, appUrl, appDomain, capabilities, port, token, url, }: Ad4mConnectOptions);
|
|
40
|
-
private notifyConfigChange;
|
|
41
|
-
private notifyConnectionChange;
|
|
42
|
-
private notifyAuthChange;
|
|
43
|
-
setPort(port: number): void;
|
|
44
|
-
setUrl(url: string): void;
|
|
45
|
-
setToken(token: string): void;
|
|
46
|
-
on(event: Event, cb: Function): void;
|
|
47
|
-
connect(url?: string): Promise<Ad4mClient>;
|
|
48
|
-
connectToPort(port?: number): Promise<Ad4mClient>;
|
|
49
|
-
ensureConnection(): Promise<Ad4mClient>;
|
|
50
|
-
findPort(): Promise<number>;
|
|
51
|
-
buildClient(): Ad4mClient;
|
|
52
|
-
checkAuth(): Promise<boolean>;
|
|
53
|
-
requestCapability(invalidateToken?: boolean): Promise<string>;
|
|
54
|
-
verifyCode(code: string): Promise<string>;
|
|
55
|
-
}
|
|
1
|
+
import { ApolloClient, NormalizedCacheObject } from "@apollo/client/core";
|
|
2
|
+
import { Client as WSClient } from "graphql-ws";
|
|
3
|
+
import { Ad4mClient, CapabilityInput } from "@coasys/ad4m";
|
|
4
|
+
export type Ad4mConnectOptions = {
|
|
5
|
+
appName: string;
|
|
6
|
+
appDesc: string;
|
|
7
|
+
appDomain: string;
|
|
8
|
+
appUrl?: string;
|
|
9
|
+
appIconPath?: string;
|
|
10
|
+
capabilities: CapabilityInput[];
|
|
11
|
+
dataPath?: string;
|
|
12
|
+
port?: number;
|
|
13
|
+
token?: string;
|
|
14
|
+
url?: string;
|
|
15
|
+
};
|
|
16
|
+
export type AuthStates = "authenticated" | "locked" | "unauthenticated";
|
|
17
|
+
export type Event = "authstatechange" | "connectionstatechange" | "configstatechange";
|
|
18
|
+
export type ConfigStates = "port" | "url" | "token";
|
|
19
|
+
export type ConnectionStates = "connecting" | "connected" | "error" | "port_not_found" | "not_connected" | "disconnected";
|
|
20
|
+
export default class Ad4mConnect {
|
|
21
|
+
activeSocket: WebSocket;
|
|
22
|
+
requestedRestart: boolean;
|
|
23
|
+
authState: AuthStates;
|
|
24
|
+
connectionState: ConnectionStates;
|
|
25
|
+
wsClient?: WSClient;
|
|
26
|
+
apolloClient?: ApolloClient<NormalizedCacheObject>;
|
|
27
|
+
ad4mClient?: Ad4mClient;
|
|
28
|
+
requestId?: string;
|
|
29
|
+
url: string;
|
|
30
|
+
token: string;
|
|
31
|
+
port: number;
|
|
32
|
+
capabilities: CapabilityInput[];
|
|
33
|
+
appName: string;
|
|
34
|
+
appDesc: string;
|
|
35
|
+
appDomain: string;
|
|
36
|
+
appIconPath: string;
|
|
37
|
+
appUrl?: string;
|
|
38
|
+
listeners: Record<Event, Function[]>;
|
|
39
|
+
constructor({ appName, appDesc, appIconPath, appUrl, appDomain, capabilities, port, token, url, }: Ad4mConnectOptions);
|
|
40
|
+
private notifyConfigChange;
|
|
41
|
+
private notifyConnectionChange;
|
|
42
|
+
private notifyAuthChange;
|
|
43
|
+
setPort(port: number): void;
|
|
44
|
+
setUrl(url: string): void;
|
|
45
|
+
setToken(token: string): void;
|
|
46
|
+
on(event: Event, cb: Function): void;
|
|
47
|
+
connect(url?: string): Promise<Ad4mClient>;
|
|
48
|
+
connectToPort(port?: number): Promise<Ad4mClient>;
|
|
49
|
+
ensureConnection(): Promise<Ad4mClient>;
|
|
50
|
+
findPort(): Promise<number>;
|
|
51
|
+
buildClient(): Ad4mClient;
|
|
52
|
+
checkAuth(): Promise<boolean>;
|
|
53
|
+
requestCapability(invalidateToken?: boolean): Promise<string>;
|
|
54
|
+
verifyCode(code: string): Promise<string>;
|
|
55
|
+
}
|