@workadventure/iframe-api-typings 1.12.10 → 1.13.2
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/{Api → front/Api}/Events/ActionsMenuActionClickedEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/AddActionsMenuKeyToRemotePlayerEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/AddPlayerEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/AskPositionEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ButtonClickedEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/CameraFollowPlayerEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/CameraSetEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ChangeAreaEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ChangeLayerEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ChatEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ChatVisibilityEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ClosePopupEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ColorEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/CreateAreaEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/EmbeddedWebsiteEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/EnablePlayersTrackingEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/EnterLeaveEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/GameStateEvent.d.ts +3 -0
- package/{Api → front/Api}/Events/GoToPageEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/HasPlayerMovedEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/IframeEvent.d.ts +69 -4
- package/{Api → front/Api}/Events/JoinMucEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/LayerEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/LeaveMucEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/LoadPageEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/LoadSoundEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/LoadTilesetEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/MapDataEvent.d.ts +0 -0
- package/front/Api/Events/ModalEvent.d.ts +24 -0
- package/{Api → front/Api}/Events/MovePlayerToEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/MovePlayerToEventAnswer.d.ts +0 -0
- package/{Api → front/Api}/Events/NotificationEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/OpenCoWebsiteEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/OpenPopupEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/OpenTabEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/PlaySoundEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/PlayerPosition.d.ts +0 -0
- package/{Api → front/Api}/Events/ProximityMeeting/JoinProximityMeetingEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/ProximityMeeting/ParticipantProximityMeetingEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/RemoveActionsMenuKeyFromRemotePlayerEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SetAreaPropertyEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SetPlayerVariableEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SetPropertyEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SetSharedPlayerVariableEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SetTilesEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SetVariableEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/SettingsEvent.d.ts +6 -0
- package/{Api → front/Api}/Events/ShowBusinessCardEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/StopSoundEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/Ui/MenuItemClickedEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/Ui/MenuRegisterEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/Ui/TriggerActionMessageEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/Ui/UIWebsite.d.ts +0 -0
- package/{Api → front/Api}/Events/UserInputChatEvent.d.ts +0 -0
- package/{Api → front/Api}/Events/WasCameraUpdatedEvent.d.ts +0 -0
- package/{Api → front/Api}/Iframe/AbstractState.d.ts +3 -2
- package/{Api → front/Api}/Iframe/Area/Area.d.ts +2 -2
- package/{Api → front/Api}/Iframe/IframeApiContribution.d.ts +0 -0
- package/{Api → front/Api}/Iframe/Player/ProximityMeeting.d.ts +0 -0
- package/{Api → front/Api}/Iframe/Players/RemotePlayer.d.ts +4 -3
- package/{Api → front/Api}/Iframe/Room/EmbeddedWebsite.d.ts +0 -3
- package/{Api → front/Api}/Iframe/Sound/Sound.d.ts +0 -0
- package/{Api → front/Api}/Iframe/Ui/ActionMessage.d.ts +0 -0
- package/{Api → front/Api}/Iframe/Ui/ButtonDescriptor.d.ts +0 -0
- package/{Api → front/Api}/Iframe/Ui/Menu.d.ts +0 -0
- package/front/Api/Iframe/Ui/Modal.d.ts +17 -0
- package/{Api → front/Api}/Iframe/Ui/Popup.d.ts +0 -0
- package/{Api → front/Api}/Iframe/Ui/UIWebsite.d.ts +1 -1
- package/{Api → front/Api}/Iframe/area.d.ts +2 -2
- package/{Api → front/Api}/Iframe/camera.d.ts +1 -1
- package/{Api → front/Api}/Iframe/chat.d.ts +0 -0
- package/{Api → front/Api}/Iframe/controls.d.ts +0 -0
- package/{Api → front/Api}/Iframe/nav.d.ts +0 -0
- package/{Api → front/Api}/Iframe/player.d.ts +19 -1
- package/{Api → front/Api}/Iframe/playerState.d.ts +0 -0
- package/{Api → front/Api}/Iframe/players.d.ts +3 -2
- package/{Api → front/Api}/Iframe/registeredCallbacks.d.ts +1 -1
- package/{Api → front/Api}/Iframe/room.d.ts +3 -3
- package/{Api → front/Api}/Iframe/sound.d.ts +0 -0
- package/{Api → front/Api}/Iframe/state.d.ts +0 -0
- package/{Api → front/Api}/Iframe/ui.d.ts +4 -1
- package/{Api → front/Api}/Iframe/website.d.ts +0 -0
- package/{Api → front/Api}/types.d.ts +0 -0
- package/iframe_api.d.ts +21 -21
- package/package.json +1 -1
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -12,6 +12,7 @@ export declare const isGameStateEvent: z.ZodObject<{
|
|
|
12
12
|
playerVariables: z.ZodUnknown;
|
|
13
13
|
userRoomToken: z.ZodOptional<z.ZodString>;
|
|
14
14
|
metadata: z.ZodOptional<z.ZodUnknown>;
|
|
15
|
+
isLogged: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
15
16
|
}, "strip", z.ZodTypeAny, {
|
|
16
17
|
language?: string | undefined;
|
|
17
18
|
playerId?: number | undefined;
|
|
@@ -25,6 +26,7 @@ export declare const isGameStateEvent: z.ZodObject<{
|
|
|
25
26
|
mapUrl: string;
|
|
26
27
|
nickname: string;
|
|
27
28
|
tags: string[];
|
|
29
|
+
isLogged: boolean;
|
|
28
30
|
}, {
|
|
29
31
|
language?: string | undefined;
|
|
30
32
|
playerId?: number | undefined;
|
|
@@ -34,6 +36,7 @@ export declare const isGameStateEvent: z.ZodObject<{
|
|
|
34
36
|
playerVariables?: unknown;
|
|
35
37
|
userRoomToken?: string | undefined;
|
|
36
38
|
metadata?: unknown;
|
|
39
|
+
isLogged?: boolean | undefined;
|
|
37
40
|
roomId: string;
|
|
38
41
|
mapUrl: string;
|
|
39
42
|
nickname: string;
|
|
File without changes
|
|
File without changes
|
|
@@ -1080,6 +1080,54 @@ export declare const isIframeEventWrapper: z.ZodUnion<[z.ZodObject<{
|
|
|
1080
1080
|
data: {
|
|
1081
1081
|
visitCardUrl: string;
|
|
1082
1082
|
};
|
|
1083
|
+
}>, z.ZodObject<{
|
|
1084
|
+
type: z.ZodLiteral<"openModal">;
|
|
1085
|
+
data: z.ZodObject<{
|
|
1086
|
+
src: z.ZodString;
|
|
1087
|
+
allow: z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodString>>>;
|
|
1088
|
+
tiltle: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1089
|
+
position: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1090
|
+
allowApi: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
1091
|
+
}, "strip", z.ZodTypeAny, {
|
|
1092
|
+
allowApi: boolean;
|
|
1093
|
+
position: string;
|
|
1094
|
+
allow: string | null;
|
|
1095
|
+
src: string;
|
|
1096
|
+
tiltle: string;
|
|
1097
|
+
}, {
|
|
1098
|
+
allowApi?: boolean | undefined;
|
|
1099
|
+
position?: string | undefined;
|
|
1100
|
+
allow?: string | null | undefined;
|
|
1101
|
+
tiltle?: string | undefined;
|
|
1102
|
+
src: string;
|
|
1103
|
+
}>;
|
|
1104
|
+
}, "strip", z.ZodTypeAny, {
|
|
1105
|
+
type: "openModal";
|
|
1106
|
+
data: {
|
|
1107
|
+
allowApi: boolean;
|
|
1108
|
+
position: string;
|
|
1109
|
+
allow: string | null;
|
|
1110
|
+
src: string;
|
|
1111
|
+
tiltle: string;
|
|
1112
|
+
};
|
|
1113
|
+
}, {
|
|
1114
|
+
type: "openModal";
|
|
1115
|
+
data: {
|
|
1116
|
+
allowApi?: boolean | undefined;
|
|
1117
|
+
position?: string | undefined;
|
|
1118
|
+
allow?: string | null | undefined;
|
|
1119
|
+
tiltle?: string | undefined;
|
|
1120
|
+
src: string;
|
|
1121
|
+
};
|
|
1122
|
+
}>, z.ZodObject<{
|
|
1123
|
+
type: z.ZodLiteral<"closeModal">;
|
|
1124
|
+
data: z.ZodUndefined;
|
|
1125
|
+
}, "strip", z.ZodTypeAny, {
|
|
1126
|
+
data?: undefined;
|
|
1127
|
+
type: "closeModal";
|
|
1128
|
+
}, {
|
|
1129
|
+
data?: undefined;
|
|
1130
|
+
type: "closeModal";
|
|
1083
1131
|
}>, z.ZodObject<{
|
|
1084
1132
|
type: z.ZodLiteral<"redirectPricing">;
|
|
1085
1133
|
data: z.ZodUndefined;
|
|
@@ -2057,24 +2105,34 @@ export declare const isIframeResponseEvent: z.ZodUnion<[z.ZodObject<{
|
|
|
2057
2105
|
data: z.ZodObject<{
|
|
2058
2106
|
notification: z.ZodBoolean;
|
|
2059
2107
|
chatSounds: z.ZodBoolean;
|
|
2108
|
+
enableChat: z.ZodBoolean;
|
|
2109
|
+
enableChatUpload: z.ZodBoolean;
|
|
2060
2110
|
}, "strip", z.ZodTypeAny, {
|
|
2061
2111
|
notification: boolean;
|
|
2062
2112
|
chatSounds: boolean;
|
|
2113
|
+
enableChat: boolean;
|
|
2114
|
+
enableChatUpload: boolean;
|
|
2063
2115
|
}, {
|
|
2064
2116
|
notification: boolean;
|
|
2065
2117
|
chatSounds: boolean;
|
|
2118
|
+
enableChat: boolean;
|
|
2119
|
+
enableChatUpload: boolean;
|
|
2066
2120
|
}>;
|
|
2067
2121
|
}, "strip", z.ZodTypeAny, {
|
|
2068
2122
|
type: "settings";
|
|
2069
2123
|
data: {
|
|
2070
2124
|
notification: boolean;
|
|
2071
2125
|
chatSounds: boolean;
|
|
2126
|
+
enableChat: boolean;
|
|
2127
|
+
enableChatUpload: boolean;
|
|
2072
2128
|
};
|
|
2073
2129
|
}, {
|
|
2074
2130
|
type: "settings";
|
|
2075
2131
|
data: {
|
|
2076
2132
|
notification: boolean;
|
|
2077
2133
|
chatSounds: boolean;
|
|
2134
|
+
enableChat: boolean;
|
|
2135
|
+
enableChatUpload: boolean;
|
|
2078
2136
|
};
|
|
2079
2137
|
}>, z.ZodObject<{
|
|
2080
2138
|
type: z.ZodLiteral<"chatVisibility">;
|
|
@@ -2232,6 +2290,7 @@ export declare const iframeQueryMapTypeGuards: {
|
|
|
2232
2290
|
playerVariables: z.ZodUnknown;
|
|
2233
2291
|
userRoomToken: z.ZodOptional<z.ZodString>;
|
|
2234
2292
|
metadata: z.ZodOptional<z.ZodUnknown>;
|
|
2293
|
+
isLogged: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
2235
2294
|
}, "strip", z.ZodTypeAny, {
|
|
2236
2295
|
language?: string | undefined;
|
|
2237
2296
|
playerId?: number | undefined;
|
|
@@ -2245,6 +2304,7 @@ export declare const iframeQueryMapTypeGuards: {
|
|
|
2245
2304
|
mapUrl: string;
|
|
2246
2305
|
nickname: string;
|
|
2247
2306
|
tags: string[];
|
|
2307
|
+
isLogged: boolean;
|
|
2248
2308
|
}, {
|
|
2249
2309
|
language?: string | undefined;
|
|
2250
2310
|
playerId?: number | undefined;
|
|
@@ -2254,6 +2314,7 @@ export declare const iframeQueryMapTypeGuards: {
|
|
|
2254
2314
|
playerVariables?: unknown;
|
|
2255
2315
|
userRoomToken?: string | undefined;
|
|
2256
2316
|
metadata?: unknown;
|
|
2317
|
+
isLogged?: boolean | undefined;
|
|
2257
2318
|
roomId: string;
|
|
2258
2319
|
mapUrl: string;
|
|
2259
2320
|
nickname: string;
|
|
@@ -2950,6 +3011,10 @@ export declare const iframeQueryMapTypeGuards: {
|
|
|
2950
3011
|
availabilityStatus: string;
|
|
2951
3012
|
}>, "many">;
|
|
2952
3013
|
};
|
|
3014
|
+
getWoka: {
|
|
3015
|
+
query: z.ZodUndefined;
|
|
3016
|
+
answer: z.ZodString;
|
|
3017
|
+
};
|
|
2953
3018
|
};
|
|
2954
3019
|
declare type IframeQueryMapTypeGuardsType = typeof iframeQueryMapTypeGuards;
|
|
2955
3020
|
declare type UnknownToVoid<T> = undefined extends T ? void : T;
|
|
@@ -2967,15 +3032,15 @@ export interface IframeQueryWrapper<T extends keyof IframeQueryMap> {
|
|
|
2967
3032
|
id: number;
|
|
2968
3033
|
query: IframeQuery<T>;
|
|
2969
3034
|
}
|
|
2970
|
-
export declare const isIframeQueryKey: (type: string) => type is "setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking";
|
|
2971
|
-
export declare const isIframeQuery: (event: any) => event is IframeQuery<"setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking">;
|
|
2972
|
-
export declare const isIframeQueryWrapper: (event: any) => event is IframeQueryWrapper<"setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking">;
|
|
3035
|
+
export declare const isIframeQueryKey: (type: string) => type is "setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking" | "getWoka";
|
|
3036
|
+
export declare const isIframeQuery: (event: any) => event is IframeQuery<"setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking" | "getWoka">;
|
|
3037
|
+
export declare const isIframeQueryWrapper: (event: any) => event is IframeQueryWrapper<"setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking" | "getWoka">;
|
|
2973
3038
|
export interface IframeAnswerEvent<T extends keyof IframeQueryMap> {
|
|
2974
3039
|
id: number;
|
|
2975
3040
|
type: T;
|
|
2976
3041
|
data: IframeQueryMap[T]["answer"];
|
|
2977
3042
|
}
|
|
2978
|
-
export declare const isIframeAnswerEvent: (event: any) => event is IframeAnswerEvent<"setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking">;
|
|
3043
|
+
export declare const isIframeAnswerEvent: (event: any) => event is IframeAnswerEvent<"setVariable" | "triggerActionMessage" | "removeActionMessage" | "modifyArea" | "setPlayerVariable" | "getState" | "getMapData" | "loadTileset" | "openCoWebsite" | "getCoWebsites" | "closeCoWebsite" | "closeCoWebsites" | "getEmbeddedWebsite" | "deleteEmbeddedWebsite" | "createEmbeddedWebsite" | "createArea" | "getArea" | "deleteArea" | "setPlayerOutline" | "removePlayerOutline" | "getPlayerPosition" | "movePlayerTo" | "openUIWebsite" | "closeUIWebsite" | "getUIWebsites" | "enablePlayersTracking" | "getWoka">;
|
|
2979
3044
|
export declare const isIframeErrorAnswerEvent: z.ZodObject<{
|
|
2980
3045
|
id: z.ZodNumber;
|
|
2981
3046
|
type: z.ZodString;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const isModalEvent: z.ZodObject<{
|
|
3
|
+
src: z.ZodString;
|
|
4
|
+
allow: z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodString>>>;
|
|
5
|
+
tiltle: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
6
|
+
position: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
7
|
+
allowApi: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
8
|
+
}, "strip", z.ZodTypeAny, {
|
|
9
|
+
allowApi: boolean;
|
|
10
|
+
position: string;
|
|
11
|
+
allow: string | null;
|
|
12
|
+
src: string;
|
|
13
|
+
tiltle: string;
|
|
14
|
+
}, {
|
|
15
|
+
allowApi?: boolean | undefined;
|
|
16
|
+
position?: string | undefined;
|
|
17
|
+
allow?: string | null | undefined;
|
|
18
|
+
tiltle?: string | undefined;
|
|
19
|
+
src: string;
|
|
20
|
+
}>;
|
|
21
|
+
/**
|
|
22
|
+
* A message sent from the iFrame to the game to emit a notification.
|
|
23
|
+
*/
|
|
24
|
+
export declare type ModalEvent = z.infer<typeof isModalEvent>;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -2,11 +2,17 @@ import { z } from "zod";
|
|
|
2
2
|
export declare const isSettingsEvent: z.ZodObject<{
|
|
3
3
|
notification: z.ZodBoolean;
|
|
4
4
|
chatSounds: z.ZodBoolean;
|
|
5
|
+
enableChat: z.ZodBoolean;
|
|
6
|
+
enableChatUpload: z.ZodBoolean;
|
|
5
7
|
}, "strip", z.ZodTypeAny, {
|
|
6
8
|
notification: boolean;
|
|
7
9
|
chatSounds: boolean;
|
|
10
|
+
enableChat: boolean;
|
|
11
|
+
enableChatUpload: boolean;
|
|
8
12
|
}, {
|
|
9
13
|
notification: boolean;
|
|
10
14
|
chatSounds: boolean;
|
|
15
|
+
enableChat: boolean;
|
|
16
|
+
enableChatUpload: boolean;
|
|
11
17
|
}>;
|
|
12
18
|
export declare type SettingsEvent = z.infer<typeof isSettingsEvent>;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { Observable
|
|
1
|
+
import type { Observable } from "rxjs";
|
|
2
|
+
import { Subject } from "rxjs";
|
|
2
3
|
export declare abstract class AbstractWorkadventureStateCommands {
|
|
3
4
|
protected setVariableResolvers: Subject<{
|
|
4
5
|
value?: unknown;
|
|
5
6
|
key: string;
|
|
6
7
|
}>;
|
|
7
8
|
protected variables: Map<string, unknown>;
|
|
8
|
-
|
|
9
|
+
protected variableSubscribers: Map<string, Subject<unknown>>;
|
|
9
10
|
protected constructor();
|
|
10
11
|
initVariables(_variables: Map<string, unknown>): void;
|
|
11
12
|
loadVariable(key: string): unknown;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ITiledMapObject } from "@workadventure/tiled-map-type-guard";
|
|
2
|
-
import { CreateAreaEvent } from "../../Events/CreateAreaEvent";
|
|
1
|
+
import type { ITiledMapObject } from "@workadventure/tiled-map-type-guard";
|
|
2
|
+
import type { CreateAreaEvent } from "../../Events/CreateAreaEvent";
|
|
3
3
|
export declare type IArea = Omit<ITiledMapObject, "id" | "gid" | "visible" | "rotation" | "ellipse" | "polygon" | "polyline">;
|
|
4
4
|
export declare class Area implements IArea {
|
|
5
5
|
private config;
|
|
File without changes
|
|
File without changes
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { AddPlayerEvent } from "../../Events/AddPlayerEvent";
|
|
2
|
-
import { Observable
|
|
3
|
-
import {
|
|
1
|
+
import type { AddPlayerEvent } from "../../Events/AddPlayerEvent";
|
|
2
|
+
import type { Observable } from "rxjs";
|
|
3
|
+
import { Subject } from "rxjs";
|
|
4
|
+
import type { PlayerPosition } from "../../Events/PlayerPosition";
|
|
4
5
|
import { ActionsMenuAction } from "../ui";
|
|
5
6
|
export declare const remotePlayers: Map<number, RemotePlayer>;
|
|
6
7
|
export interface RemotePlayerInterface {
|
|
@@ -4,10 +4,7 @@ export declare class EmbeddedWebsite {
|
|
|
4
4
|
readonly name: string;
|
|
5
5
|
private _url;
|
|
6
6
|
private _visible;
|
|
7
|
-
private _allow;
|
|
8
|
-
private _allowApi;
|
|
9
7
|
private _position;
|
|
10
|
-
private readonly origin;
|
|
11
8
|
private _scale;
|
|
12
9
|
constructor(config: CreateEmbeddedWebsiteEvent);
|
|
13
10
|
get url(): string;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { IframeApiContribution } from "../IframeApiContribution";
|
|
2
|
+
import type { ModalEvent } from "../../Events/ModalEvent";
|
|
3
|
+
export declare class WorkadventureModalCommands extends IframeApiContribution<WorkadventureModalCommands> {
|
|
4
|
+
callbacks: never[];
|
|
5
|
+
/**
|
|
6
|
+
* Open instantly the chat window.
|
|
7
|
+
* {@link https://workadventu.re/map-building/api-chat.md#open-the-modal-window | Website documentation}
|
|
8
|
+
*/
|
|
9
|
+
openModal(modalEvent: ModalEvent): void;
|
|
10
|
+
/**
|
|
11
|
+
* Close instantly the chat window.
|
|
12
|
+
* {@link https://workadventu.re/map-building/api-chat.md#close-the-modal-window | Website documentation}
|
|
13
|
+
*/
|
|
14
|
+
closeModal(): void;
|
|
15
|
+
}
|
|
16
|
+
declare const _default: WorkadventureModalCommands;
|
|
17
|
+
export default _default;
|
|
File without changes
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CreateUIWebsiteEvent, UIWebsiteMargin, UIWebsitePosition, UIWebsiteSize, UIWebsite as UIWebsiteCore } from "../../Events/Ui/UIWebsite";
|
|
1
|
+
import type { CreateUIWebsiteEvent, UIWebsiteMargin, UIWebsitePosition, UIWebsiteSize, UIWebsite as UIWebsiteCore } from "../../Events/Ui/UIWebsite";
|
|
2
2
|
import { IframeApiContribution } from "../IframeApiContribution";
|
|
3
3
|
export declare class UIWebsite {
|
|
4
4
|
readonly id: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Observable } from "rxjs";
|
|
2
|
-
import { CreateAreaEvent } from "../Events/CreateAreaEvent";
|
|
1
|
+
import type { Observable } from "rxjs";
|
|
2
|
+
import type { CreateAreaEvent } from "../Events/CreateAreaEvent";
|
|
3
3
|
import { Area } from "./Area/Area";
|
|
4
4
|
import { IframeApiContribution } from "./IframeApiContribution";
|
|
5
5
|
export declare class WorkadventureAreaCommands extends IframeApiContribution<WorkadventureAreaCommands> {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IframeApiContribution } from "./IframeApiContribution";
|
|
2
|
-
import { Observable } from "rxjs";
|
|
2
|
+
import type { Observable } from "rxjs";
|
|
3
3
|
import type { WasCameraUpdatedEvent } from "../Events/WasCameraUpdatedEvent";
|
|
4
4
|
export declare class WorkAdventureCameraCommands extends IframeApiContribution<WorkAdventureCameraCommands> {
|
|
5
5
|
callbacks: {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { IframeApiContribution } from "./IframeApiContribution";
|
|
2
2
|
import type { HasPlayerMovedEventCallback } from "../Events/HasPlayerMovedEvent";
|
|
3
|
-
import { WorkadventureProximityMeetingCommands } from "./Player/ProximityMeeting";
|
|
3
|
+
import type { WorkadventureProximityMeetingCommands } from "./Player/ProximityMeeting";
|
|
4
4
|
export declare const setPlayerName: (name: string) => void;
|
|
5
5
|
export declare const setPlayerLanguage: (language: string | undefined) => void;
|
|
6
6
|
export declare const setTags: (_tags: string[]) => void;
|
|
7
7
|
export declare const setUserRoomToken: (token: string | undefined) => void;
|
|
8
8
|
export declare const setPlayerId: (_id: number | undefined) => void;
|
|
9
9
|
export declare const setUuid: (_uuid: string | undefined) => void;
|
|
10
|
+
export declare const setIsLogged: (_isLogged: boolean | undefined) => void;
|
|
10
11
|
export declare class WorkadventurePlayerCommands extends IframeApiContribution<WorkadventurePlayerCommands> {
|
|
11
12
|
readonly state: import("./playerState").WorkadventurePlayerStateCommands & {
|
|
12
13
|
[key: string]: unknown;
|
|
@@ -132,6 +133,23 @@ export declare class WorkadventurePlayerCommands extends IframeApiContribution<W
|
|
|
132
133
|
*/
|
|
133
134
|
removeOutlineColor(): Promise<void>;
|
|
134
135
|
get proximityMeeting(): WorkadventureProximityMeetingCommands;
|
|
136
|
+
/**
|
|
137
|
+
* Get a value to provide connected status for the current player.
|
|
138
|
+
* Important: You need to wait for the end of the initialization before accessing.
|
|
139
|
+
* {@link https://workadventu.re/map-building/api-player.md#get-the-tags-of-the-player | Website documentation}
|
|
140
|
+
*
|
|
141
|
+
* @returns {boolean} Player tags
|
|
142
|
+
*/
|
|
143
|
+
get isLogged(): boolean;
|
|
144
|
+
/**
|
|
145
|
+
* Get a base64 string of the Woka image of the current player.
|
|
146
|
+
* The Woka is in "still" position facing south.
|
|
147
|
+
* @returns {Promise<string>}
|
|
148
|
+
* {@link https://workadventu.re/map-building/api-player.md#get-the-woka-of-the-player | Website documentation}
|
|
149
|
+
*
|
|
150
|
+
* @returns {Promise<string>} Current player woka in base64
|
|
151
|
+
*/
|
|
152
|
+
getWokaPicture(): Promise<string>;
|
|
135
153
|
}
|
|
136
154
|
export declare type Position = {
|
|
137
155
|
x: number;
|
|
File without changes
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IframeApiContribution } from "./IframeApiContribution";
|
|
2
|
-
import { Observable } from "rxjs";
|
|
3
|
-
import {
|
|
2
|
+
import type { Observable } from "rxjs";
|
|
3
|
+
import type { RemotePlayerInterface, RemotePlayerMoved } from "./Players/RemotePlayer";
|
|
4
|
+
import { RemotePlayer } from "./Players/RemotePlayer";
|
|
4
5
|
export interface PlayerVariableChanged {
|
|
5
6
|
player: RemotePlayer;
|
|
6
7
|
value: unknown;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Observable } from "rxjs";
|
|
1
|
+
import type { Observable } from "rxjs";
|
|
2
2
|
import { IframeApiContribution } from "./IframeApiContribution";
|
|
3
3
|
import type { WorkadventureRoomWebsiteCommands } from "./website";
|
|
4
|
-
import { WorkadventureAreaCommands } from "./area";
|
|
5
|
-
import { ITiledMap } from "@workadventure/tiled-map-type-guard";
|
|
4
|
+
import type { WorkadventureAreaCommands } from "./area";
|
|
5
|
+
import type { ITiledMap } from "@workadventure/tiled-map-type-guard";
|
|
6
6
|
interface TileDescriptor {
|
|
7
7
|
x: number;
|
|
8
8
|
y: number;
|
|
File without changes
|
|
File without changes
|
|
@@ -4,9 +4,11 @@ import { Popup } from "./Ui/Popup";
|
|
|
4
4
|
import { ActionMessage } from "./Ui/ActionMessage";
|
|
5
5
|
import { Menu } from "./Ui/Menu";
|
|
6
6
|
import type { RequireOnlyOne } from "../types";
|
|
7
|
-
import { Observable
|
|
7
|
+
import type { Observable } from "rxjs";
|
|
8
|
+
import { Subject } from "rxjs";
|
|
8
9
|
import type { UIWebsiteCommands } from "./Ui/UIWebsite";
|
|
9
10
|
import { RemotePlayer } from "./Players/RemotePlayer";
|
|
11
|
+
import type { WorkadventureModalCommands } from "./Ui/Modal";
|
|
10
12
|
interface MenuDescriptor {
|
|
11
13
|
callback?: (commandDescriptor: string) => void;
|
|
12
14
|
iframe?: string;
|
|
@@ -108,6 +110,7 @@ export declare class WorkAdventureUiCommands extends IframeApiContribution<WorkA
|
|
|
108
110
|
*/
|
|
109
111
|
displayActionMessage(actionMessageOptions: ActionMessageOptions): ActionMessage;
|
|
110
112
|
get website(): UIWebsiteCommands;
|
|
113
|
+
get modal(): WorkadventureModalCommands;
|
|
111
114
|
}
|
|
112
115
|
declare const _default: WorkAdventureUiCommands;
|
|
113
116
|
export default _default;
|
|
File without changes
|
|
File without changes
|
package/iframe_api.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { CoWebsite } from "./Api/Iframe/nav";
|
|
2
|
-
import type { ButtonDescriptor } from "./Api/Iframe/Ui/ButtonDescriptor";
|
|
3
|
-
import type { Popup } from "./Api/Iframe/Ui/Popup";
|
|
4
|
-
import type { Sound } from "./Api/Iframe/Sound/Sound";
|
|
5
|
-
export type { UIWebsite } from "./Api/Iframe/Ui/UIWebsite";
|
|
6
|
-
export type { Menu } from "./Api/Iframe/Ui/Menu";
|
|
7
|
-
export type { ActionMessage } from "./Api/Iframe/Ui/ActionMessage";
|
|
8
|
-
export type { EmbeddedWebsite } from "./Api/Iframe/Room/EmbeddedWebsite";
|
|
9
|
-
export type { Area } from "./Api/Iframe/Area/Area";
|
|
10
|
-
export type { ActionsMenuAction } from "./Api/Iframe/ui";
|
|
1
|
+
import type { CoWebsite } from "./front/Api/Iframe/nav";
|
|
2
|
+
import type { ButtonDescriptor } from "./front/Api/Iframe/Ui/ButtonDescriptor";
|
|
3
|
+
import type { Popup } from "./front/Api/Iframe/Ui/Popup";
|
|
4
|
+
import type { Sound } from "./front/Api/Iframe/Sound/Sound";
|
|
5
|
+
export type { UIWebsite } from "./front/Api/Iframe/Ui/UIWebsite";
|
|
6
|
+
export type { Menu } from "./front/Api/Iframe/Ui/Menu";
|
|
7
|
+
export type { ActionMessage } from "./front/Api/Iframe/Ui/ActionMessage";
|
|
8
|
+
export type { EmbeddedWebsite } from "./front/Api/Iframe/Room/EmbeddedWebsite";
|
|
9
|
+
export type { Area } from "./front/Api/Iframe/Area/Area";
|
|
10
|
+
export type { ActionsMenuAction } from "./front/Api/Iframe/ui";
|
|
11
11
|
declare const wa: {
|
|
12
|
-
ui: import("./Api/Iframe/ui").WorkAdventureUiCommands;
|
|
13
|
-
nav: import("./Api/Iframe/nav").WorkadventureNavigationCommands;
|
|
14
|
-
controls: import("./Api/Iframe/controls").WorkadventureControlsCommands;
|
|
15
|
-
chat: import("./Api/Iframe/chat").WorkadventureChatCommands;
|
|
16
|
-
sound: import("./Api/Iframe/sound").WorkadventureSoundCommands;
|
|
17
|
-
room: import("./Api/Iframe/room").WorkadventureRoomCommands;
|
|
18
|
-
player: import("./Api/Iframe/player").WorkadventurePlayerCommands;
|
|
19
|
-
players: import("./Api/Iframe/players").WorkadventurePlayersCommands;
|
|
20
|
-
camera: import("./Api/Iframe/camera").WorkAdventureCameraCommands;
|
|
21
|
-
state: import("./Api/Iframe/state").WorkadventureStateCommands & {
|
|
12
|
+
ui: import("./front/Api/Iframe/ui").WorkAdventureUiCommands;
|
|
13
|
+
nav: import("./front/Api/Iframe/nav").WorkadventureNavigationCommands;
|
|
14
|
+
controls: import("./front/Api/Iframe/controls").WorkadventureControlsCommands;
|
|
15
|
+
chat: import("./front/Api/Iframe/chat").WorkadventureChatCommands;
|
|
16
|
+
sound: import("./front/Api/Iframe/sound").WorkadventureSoundCommands;
|
|
17
|
+
room: import("./front/Api/Iframe/room").WorkadventureRoomCommands;
|
|
18
|
+
player: import("./front/Api/Iframe/player").WorkadventurePlayerCommands;
|
|
19
|
+
players: import("./front/Api/Iframe/players").WorkadventurePlayersCommands;
|
|
20
|
+
camera: import("./front/Api/Iframe/camera").WorkAdventureCameraCommands;
|
|
21
|
+
state: import("./front/Api/Iframe/state").WorkadventureStateCommands & {
|
|
22
22
|
[key: string]: unknown;
|
|
23
23
|
};
|
|
24
24
|
/**
|
|
@@ -27,7 +27,7 @@ declare const wa: {
|
|
|
27
27
|
* API to be fully ready using the WA.onInit() method.
|
|
28
28
|
* {@link https://workadventu.re/map-building/api-start.md#waiting-for-workadventure-api-to-be-available | Website documentation}
|
|
29
29
|
*
|
|
30
|
-
* Some properties (like the current
|
|
30
|
+
* Some properties (like the current username, or the room ID) are not available until WA.onInit has completed.
|
|
31
31
|
*
|
|
32
32
|
* @returns {void}
|
|
33
33
|
*/
|