@kalamba/sdk 0.1.2 → 0.2.1
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/index.cjs +1 -1
- package/dist/index.d.ts +18 -8
- package/dist/index.js +45 -45
- package/dist/plugins.cjs +1 -1
- package/dist/plugins.d.ts +20 -10
- package/dist/plugins.js +174 -181
- package/dist/wrapper.d.ts +17 -7
- package/package.json +1 -1
package/dist/wrapper.d.ts
CHANGED
|
@@ -55,6 +55,11 @@ declare abstract class CasinoPlugin {
|
|
|
55
55
|
protected send<M extends DomainMessage<'casino'>>(message: M, ...[payload]: DomainMessagePayload<'casino', M> extends never ? [] : [payload: DomainMessagePayload<'casino', M>]): void;
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
+
declare type ContractPlayPayload = {
|
|
59
|
+
[key: string]: any;
|
|
60
|
+
bet: Bet | null;
|
|
61
|
+
};
|
|
62
|
+
|
|
58
63
|
declare type DeepPartial<T> = T extends object ? {
|
|
59
64
|
[P in keyof T]?: DeepPartial<T[P]>;
|
|
60
65
|
} : T;
|
|
@@ -81,6 +86,12 @@ declare type Error_2 = {
|
|
|
81
86
|
type: 'CLOSE' | 'RELOAD' | 'CONTINUE';
|
|
82
87
|
};
|
|
83
88
|
|
|
89
|
+
declare type ExtraPlayPayload = {
|
|
90
|
+
[key: string]: any;
|
|
91
|
+
} & {
|
|
92
|
+
bet?: never;
|
|
93
|
+
};
|
|
94
|
+
|
|
84
95
|
declare type ForwardToPluginsMessage<P extends PluginDomain> = keyof ForwardToPluginsMessageMap<'sdk'>[P] | keyof ForwardToPluginsMessageMap<'rgs'>[P] | keyof ForwardToPluginsMessageMap<'casino'>[P] | keyof ForwardToPluginsMessageMap<'telemetry'>[P];
|
|
85
96
|
|
|
86
97
|
declare interface ForwardToPluginsMessageMap<SourceDomain extends DomainPrefix> {
|
|
@@ -132,6 +143,7 @@ declare type OpenGameError = {
|
|
|
132
143
|
|
|
133
144
|
declare type OpenGameRequest = {
|
|
134
145
|
gameName: string;
|
|
146
|
+
/** version of game client */
|
|
135
147
|
version: string;
|
|
136
148
|
};
|
|
137
149
|
|
|
@@ -146,11 +158,9 @@ declare type PlayError = {
|
|
|
146
158
|
};
|
|
147
159
|
|
|
148
160
|
declare type PlayRequest = {
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
} | {
|
|
153
|
-
opaqueGameAttributes: unknown;
|
|
161
|
+
contract: ContractPlayPayload;
|
|
162
|
+
extra: ExtraPlayPayload;
|
|
163
|
+
actionType: string;
|
|
154
164
|
};
|
|
155
165
|
|
|
156
166
|
declare type PlayResponse = {
|
|
@@ -303,12 +313,12 @@ declare type SdkOnlyMessagePayloadMap = {
|
|
|
303
313
|
openGame: OpenGameRequest;
|
|
304
314
|
play: PlayRequest;
|
|
305
315
|
playCycleEnd: PlayResponse;
|
|
306
|
-
playCycleStart:
|
|
316
|
+
playCycleStart: ContractPlayPayload;
|
|
307
317
|
playEnd: PlayResponse;
|
|
308
318
|
playReady: {
|
|
309
319
|
ready: boolean;
|
|
310
320
|
};
|
|
311
|
-
playStart:
|
|
321
|
+
playStart: ContractPlayPayload;
|
|
312
322
|
translations: Record<string, Record<string, string>>;
|
|
313
323
|
settings: Settings;
|
|
314
324
|
'telemetry.click': {
|