@energy8platform/platform-core 0.19.0 → 0.21.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/README.md +238 -1
- package/dist/dev-bridge.cjs.js +104 -0
- package/dist/dev-bridge.cjs.js.map +1 -1
- package/dist/dev-bridge.d.ts +64 -1
- package/dist/dev-bridge.esm.js +104 -0
- package/dist/dev-bridge.esm.js.map +1 -1
- package/dist/index.cjs.js +2053 -0
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +372 -2
- package/dist/index.esm.js +2051 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/shell.cjs.js +1993 -0
- package/dist/shell.cjs.js.map +1 -0
- package/dist/shell.d.ts +320 -0
- package/dist/shell.esm.js +1989 -0
- package/dist/shell.esm.js.map +1 -0
- package/package.json +7 -2
- package/scripts/build-shell-font.mjs +64 -0
- package/src/PlatformSession.ts +10 -0
- package/src/dev-bridge/DevBridge.ts +160 -2
- package/src/dev-bridge/index.ts +1 -1
- package/src/index.ts +17 -1
- package/src/shell/GameShell.ts +294 -0
- package/src/shell/INTER-LICENSE.txt +93 -0
- package/src/shell/colors.ts +32 -0
- package/src/shell/components/BottomBar.ts +217 -0
- package/src/shell/components/BuyBonus.ts +163 -0
- package/src/shell/components/GameInfo.ts +253 -0
- package/src/shell/components/Modal.ts +36 -0
- package/src/shell/components/ReplayModal.ts +56 -0
- package/src/shell/components/Settings.ts +60 -0
- package/src/shell/components/icons.ts +40 -0
- package/src/shell/components/pickers.ts +76 -0
- package/src/shell/components/primitives.ts +84 -0
- package/src/shell/fonts.ts +13 -0
- package/src/shell/format.ts +36 -0
- package/src/shell/i18n.ts +67 -0
- package/src/shell/index.ts +20 -0
- package/src/shell/motion.ts +43 -0
- package/src/shell/shell.css.ts +371 -0
- package/src/shell/state.ts +30 -0
- package/src/shell/theme.ts +56 -0
- package/src/shell/types.ts +191 -0
package/dist/index.d.ts
CHANGED
|
@@ -131,6 +131,41 @@ interface SimulationRawAccumulators {
|
|
|
131
131
|
hits: number;
|
|
132
132
|
}
|
|
133
133
|
|
|
134
|
+
/**
|
|
135
|
+
* A detected replay launch — the host wants to re-play a historical round
|
|
136
|
+
* instead of placing live bets. `mode`/`roundId` are forwarded verbatim to
|
|
137
|
+
* {@link ReplayConfig.resolve}.
|
|
138
|
+
*/
|
|
139
|
+
interface ReplayLaunch {
|
|
140
|
+
/** Game mode the round was recorded in (e.g. "BASE", "BONUS"). */
|
|
141
|
+
mode?: string;
|
|
142
|
+
/** Identifier of the recorded round to replay. */
|
|
143
|
+
roundId?: string;
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Opt-in replay support for the DevBridge mock host.
|
|
147
|
+
*
|
|
148
|
+
* In production the casino backend serves a recorded round; in dev the
|
|
149
|
+
* DevBridge IS the host. Provide a `resolve` callback that returns the
|
|
150
|
+
* recorded rounds — DevBridge stays agnostic about where they come from
|
|
151
|
+
* (fetch, static fixtures, localStorage, …). When a replay launch is
|
|
152
|
+
* detected, the bridge flips `config.replayMode = true` and feeds the
|
|
153
|
+
* recorded `PlayResultData[]` back on each play request, without touching
|
|
154
|
+
* the wallet.
|
|
155
|
+
*/
|
|
156
|
+
interface ReplayConfig {
|
|
157
|
+
/**
|
|
158
|
+
* Resolve the recorded rounds for a replay launch. Receives the `mode`
|
|
159
|
+
* and `roundId` from {@link detect}. May be async (e.g. a fetch).
|
|
160
|
+
*/
|
|
161
|
+
resolve: (mode: string | undefined, roundId: string | undefined) => PlayResultData[] | Promise<PlayResultData[]>;
|
|
162
|
+
/**
|
|
163
|
+
* Decide whether this launch is a replay and extract its params.
|
|
164
|
+
* Defaults to reading `?replay=1&mode=…&event=…` from the browser URL.
|
|
165
|
+
* Return `null` for a normal (non-replay) launch.
|
|
166
|
+
*/
|
|
167
|
+
detect?: () => ReplayLaunch | null;
|
|
168
|
+
}
|
|
134
169
|
interface DevBridgeConfig {
|
|
135
170
|
/** Mock initial balance */
|
|
136
171
|
balance?: number;
|
|
@@ -154,6 +189,12 @@ interface DevBridgeConfig {
|
|
|
154
189
|
gameDefinition?: GameDefinition;
|
|
155
190
|
/** RNG seed for deterministic Lua execution */
|
|
156
191
|
luaSeed?: number;
|
|
192
|
+
/**
|
|
193
|
+
* Opt-in historical-round replay. When the detector reports a replay
|
|
194
|
+
* launch, the bridge serves recorded rounds instead of running Lua/onPlay.
|
|
195
|
+
* See {@link ReplayConfig}.
|
|
196
|
+
*/
|
|
197
|
+
replay?: ReplayConfig;
|
|
157
198
|
}
|
|
158
199
|
/**
|
|
159
200
|
* Mock host bridge for local development.
|
|
@@ -195,7 +236,15 @@ declare class DevBridge {
|
|
|
195
236
|
private _sessionExpiresAt;
|
|
196
237
|
/** Pre-parsed session TTL from gameDefinition.session_ttl. */
|
|
197
238
|
private _sessionTtlMs;
|
|
239
|
+
/** Detected replay launch, or null when not replaying. */
|
|
240
|
+
private _replayLaunch;
|
|
241
|
+
/** Recorded rounds for the active replay (resolved lazily once). */
|
|
242
|
+
private _replayResults;
|
|
243
|
+
/** Cursor into the recorded rounds; wraps to 0 on "Play Again". */
|
|
244
|
+
private _replayCursor;
|
|
198
245
|
constructor(config?: DevBridgeConfig);
|
|
246
|
+
/** True when this bridge was launched as a historical-round replay. */
|
|
247
|
+
get isReplay(): boolean;
|
|
199
248
|
/** Current mock balance */
|
|
200
249
|
get balance(): number;
|
|
201
250
|
/** Start listening for SDK messages */
|
|
@@ -207,6 +256,20 @@ declare class DevBridge {
|
|
|
207
256
|
/** Destroy the dev bridge */
|
|
208
257
|
destroy(): void;
|
|
209
258
|
private handleGameReady;
|
|
259
|
+
/**
|
|
260
|
+
* Replay INIT: flip `config.replayMode = true` and take balance/currency
|
|
261
|
+
* from the recorded results (the wallet is never touched in replay).
|
|
262
|
+
*/
|
|
263
|
+
private handleReplayGameReady;
|
|
264
|
+
/** Resolve (and cache) the recorded rounds for the active replay launch. */
|
|
265
|
+
private resolveReplayResults;
|
|
266
|
+
/**
|
|
267
|
+
* Replay PLAY_REQUEST: serve the recorded round at the cursor and advance.
|
|
268
|
+
* No wallet movement, no bet/session validation. The first spin past the
|
|
269
|
+
* end resets the cursor to 0 ("Play Again"). An empty record list behaves
|
|
270
|
+
* like an exhausted live session.
|
|
271
|
+
*/
|
|
272
|
+
private handleReplayPlay;
|
|
210
273
|
private handlePlayRequest;
|
|
211
274
|
/** Send a PLAY_ERROR correlated to the original PLAY_REQUEST id. */
|
|
212
275
|
private sendError;
|
|
@@ -326,6 +389,13 @@ declare class PlatformSession extends EventEmitter<PlatformSessionEvents> {
|
|
|
326
389
|
get balance(): number;
|
|
327
390
|
/** Current currency from the SDK ('USD' fallback). */
|
|
328
391
|
get currency(): string;
|
|
392
|
+
/**
|
|
393
|
+
* `true` when launched as a historical-round replay (the host set
|
|
394
|
+
* `config.replayMode`). Games read this to hide balance/bet/autoplay UI
|
|
395
|
+
* and surface a "Play / Play Again" CTA only. Falls back to the handshake
|
|
396
|
+
* config when no SDK is present.
|
|
397
|
+
*/
|
|
398
|
+
get isReplay(): boolean;
|
|
329
399
|
/**
|
|
330
400
|
* Send a play request through the SDK and resolve with the host result.
|
|
331
401
|
* Throws if the session was constructed with `sdk: false`.
|
|
@@ -427,6 +497,306 @@ interface LogoSVGOptions {
|
|
|
427
497
|
*/
|
|
428
498
|
declare function buildLogoSVG(opts: LogoSVGOptions): string;
|
|
429
499
|
|
|
500
|
+
type ShellMode = 'base' | 'freeSpins' | 'replay';
|
|
501
|
+
interface CurrencyConfig {
|
|
502
|
+
symbol: string;
|
|
503
|
+
position: 'left' | 'right';
|
|
504
|
+
/** Maximum fraction digits (default 2). The value is rounded to this precision. */
|
|
505
|
+
decimals?: number;
|
|
506
|
+
/** Minimum fraction digits (defaults to `decimals`). Trailing zeros are trimmed down to
|
|
507
|
+
* this many places, so small wins keep their significant digits (e.g. 0.0673) while round
|
|
508
|
+
* amounts stay compact (e.g. 0.30). */
|
|
509
|
+
minDecimals?: number;
|
|
510
|
+
separator?: {
|
|
511
|
+
thousands?: string;
|
|
512
|
+
decimal?: string;
|
|
513
|
+
};
|
|
514
|
+
}
|
|
515
|
+
interface BonusOption {
|
|
516
|
+
id: string;
|
|
517
|
+
/** 'bonus' buys into a bonus round, 'feature' toggles a base-game modifier (e.g. Ante).
|
|
518
|
+
* Drives the card/button label and accent. Defaults to 'bonus'. */
|
|
519
|
+
type?: 'feature' | 'bonus';
|
|
520
|
+
title: string;
|
|
521
|
+
description: string;
|
|
522
|
+
/** Transparent art image shown at the top of the card (no background plate). */
|
|
523
|
+
thumbnail?: string;
|
|
524
|
+
volatility?: 1 | 2 | 3 | 4 | 5;
|
|
525
|
+
/** Card price = priceMultiplier × current bet, rendered in the shell currency. */
|
|
526
|
+
priceMultiplier: number;
|
|
527
|
+
/** Per-option accent override. Falls back to the type default (bonus → purple, feature → gold). */
|
|
528
|
+
accentColor?: string;
|
|
529
|
+
}
|
|
530
|
+
interface ThemeConfig {
|
|
531
|
+
/** Palette scheme: 'dark' (default) for dark games, 'light' for light backgrounds. */
|
|
532
|
+
scheme?: 'dark' | 'light';
|
|
533
|
+
accent?: string;
|
|
534
|
+
buyBonusColor?: string;
|
|
535
|
+
}
|
|
536
|
+
/** One paytable entry: a symbol (text/image) and its win tiers, rendered "<count> x<multiplier>". */
|
|
537
|
+
interface PaytableRow {
|
|
538
|
+
symbol: {
|
|
539
|
+
text?: string;
|
|
540
|
+
image?: string;
|
|
541
|
+
};
|
|
542
|
+
wins: Array<{
|
|
543
|
+
count?: string;
|
|
544
|
+
multiplier: number;
|
|
545
|
+
}>;
|
|
546
|
+
}
|
|
547
|
+
/** One payline over a cols×rows grid: the row index (0 = top) the line takes in each column. */
|
|
548
|
+
interface PaylineDef {
|
|
549
|
+
/** length must equal grid.cols; each value in 0..rows-1 */
|
|
550
|
+
pattern: number[];
|
|
551
|
+
label?: string;
|
|
552
|
+
}
|
|
553
|
+
/** A single grid cell, 0-based, row 0 = top. */
|
|
554
|
+
type CellRef = [col: number, row: number];
|
|
555
|
+
/** How a game pays — drives the GameInfo win-section illustration. One section = one kind.
|
|
556
|
+
* `example`/`winExample`/`loseExample` are optional; omit them for an auto-drawn illustration
|
|
557
|
+
* sized to `grid`. */
|
|
558
|
+
type WinSection = {
|
|
559
|
+
type: 'wins';
|
|
560
|
+
title?: string;
|
|
561
|
+
order?: number;
|
|
562
|
+
grid: {
|
|
563
|
+
cols: number;
|
|
564
|
+
rows: number;
|
|
565
|
+
};
|
|
566
|
+
/** Optional prose shown alongside the illustration. */
|
|
567
|
+
description?: string;
|
|
568
|
+
} & ({
|
|
569
|
+
kind: 'classic';
|
|
570
|
+
lines: Array<number[] | PaylineDef>;
|
|
571
|
+
} | {
|
|
572
|
+
kind: 'cluster';
|
|
573
|
+
minCount: number;
|
|
574
|
+
example?: CellRef[];
|
|
575
|
+
} | {
|
|
576
|
+
kind: 'anywhere';
|
|
577
|
+
minCount: number;
|
|
578
|
+
example?: CellRef[];
|
|
579
|
+
} | {
|
|
580
|
+
kind: 'ways';
|
|
581
|
+
winExample?: CellRef[];
|
|
582
|
+
loseExample?: CellRef[];
|
|
583
|
+
});
|
|
584
|
+
/** A playable mode / bonus-buy option, shown for comparison (informational only). */
|
|
585
|
+
interface GameMode {
|
|
586
|
+
title: string;
|
|
587
|
+
price?: string;
|
|
588
|
+
rtp?: number;
|
|
589
|
+
maxWin?: string;
|
|
590
|
+
description?: string;
|
|
591
|
+
}
|
|
592
|
+
/** A preset game-info section. `order` overrides placement; by default `modes` comes
|
|
593
|
+
* first, `controls` second, and the rest follow in declaration order. */
|
|
594
|
+
type GameInfoSection = {
|
|
595
|
+
type: 'modes';
|
|
596
|
+
title?: string;
|
|
597
|
+
order?: number;
|
|
598
|
+
modes: GameMode[];
|
|
599
|
+
} | {
|
|
600
|
+
type: 'controls';
|
|
601
|
+
title?: string;
|
|
602
|
+
order?: number;
|
|
603
|
+
} | {
|
|
604
|
+
type: 'paytable';
|
|
605
|
+
title?: string;
|
|
606
|
+
order?: number;
|
|
607
|
+
rows: PaytableRow[];
|
|
608
|
+
} | WinSection | {
|
|
609
|
+
type: 'custom';
|
|
610
|
+
title?: string;
|
|
611
|
+
order?: number;
|
|
612
|
+
node?: HTMLElement;
|
|
613
|
+
html?: string;
|
|
614
|
+
};
|
|
615
|
+
interface GameInfoContent {
|
|
616
|
+
sections?: GameInfoSection[];
|
|
617
|
+
}
|
|
618
|
+
interface ShellFeatures {
|
|
619
|
+
turbo: 0 | 1 | 2 | 3;
|
|
620
|
+
autoplay: boolean;
|
|
621
|
+
buyBonus: BonusOption[] | false;
|
|
622
|
+
}
|
|
623
|
+
interface AutoplayOptions {
|
|
624
|
+
active: boolean;
|
|
625
|
+
remaining: number;
|
|
626
|
+
}
|
|
627
|
+
interface FreeSpinsState {
|
|
628
|
+
current: number;
|
|
629
|
+
total: number;
|
|
630
|
+
totalWin: number;
|
|
631
|
+
lastWin: number;
|
|
632
|
+
}
|
|
633
|
+
/** One footer button of a generic modal. Clicking it runs `on` (if any), then closes the modal. */
|
|
634
|
+
interface ModalAction {
|
|
635
|
+
title: string;
|
|
636
|
+
/** Button fill colour (any CSS colour). Omit for a neutral/secondary button. */
|
|
637
|
+
color?: string;
|
|
638
|
+
on?: () => void;
|
|
639
|
+
}
|
|
640
|
+
/** Options for `shell.openReplay()` — a non-dismissable replay summary modal.
|
|
641
|
+
* `bonusId` is matched against `features.buyBonus` to label the mode and read the cost
|
|
642
|
+
* multiplier. There is no ✕ and the backdrop never closes it; the only action is START
|
|
643
|
+
* REPLAY, which closes the modal, runs `onReplay`, then reopens it. */
|
|
644
|
+
interface ReplayModalOptions {
|
|
645
|
+
bonusId: string;
|
|
646
|
+
/** Base bet the replay was recorded at. */
|
|
647
|
+
bet: number;
|
|
648
|
+
payoutMultiplier: number;
|
|
649
|
+
/** Runs after the modal closes; the modal reopens once it resolves (immediately for sync). */
|
|
650
|
+
onReplay: () => void | Promise<void>;
|
|
651
|
+
}
|
|
652
|
+
/** Options for `shell.openModal()` — a generic, externally-triggered card modal. */
|
|
653
|
+
interface ModalOptions {
|
|
654
|
+
/** Show the ✕ in the overlay's top-right corner. */
|
|
655
|
+
availableClose: boolean;
|
|
656
|
+
title: string;
|
|
657
|
+
body: string;
|
|
658
|
+
/** Footer buttons; each closes the modal (after running its `on`). */
|
|
659
|
+
actions?: ModalAction[];
|
|
660
|
+
/** Backdrop blur in px (defaults to the shell's standard blur). */
|
|
661
|
+
blurLevel?: number;
|
|
662
|
+
}
|
|
663
|
+
interface ShellConfig {
|
|
664
|
+
mount: HTMLElement;
|
|
665
|
+
theme?: ThemeConfig;
|
|
666
|
+
gameInfo: GameInfoContent;
|
|
667
|
+
language: string;
|
|
668
|
+
/** When true, all built-in shell text is shown in the social-casino vocabulary (derived from
|
|
669
|
+
* English via word-swap rules), regardless of `language`. Game-supplied content is untouched. */
|
|
670
|
+
isSocial?: boolean;
|
|
671
|
+
currency: CurrencyConfig;
|
|
672
|
+
availableBets: number[];
|
|
673
|
+
defaultBet: number;
|
|
674
|
+
currentBet: number | null;
|
|
675
|
+
balance: number;
|
|
676
|
+
win: number;
|
|
677
|
+
mode: ShellMode;
|
|
678
|
+
features: ShellFeatures;
|
|
679
|
+
}
|
|
680
|
+
interface ShellState {
|
|
681
|
+
mode: ShellMode;
|
|
682
|
+
balance: number;
|
|
683
|
+
win: number;
|
|
684
|
+
bet: number;
|
|
685
|
+
availableBets: number[];
|
|
686
|
+
busy: boolean;
|
|
687
|
+
autoplay: AutoplayOptions;
|
|
688
|
+
turbo: number;
|
|
689
|
+
buyBonusEnabled: boolean;
|
|
690
|
+
freeSpins: FreeSpinsState;
|
|
691
|
+
/** The currently activated `feature` option (e.g. Ante), or null. Drives the
|
|
692
|
+
* effective-bet readout tint and the BUY BONUS → DISABLE toggle on the bar. */
|
|
693
|
+
activeFeature: BonusOption | null;
|
|
694
|
+
}
|
|
695
|
+
interface ShellEvents {
|
|
696
|
+
spin: void;
|
|
697
|
+
betChange: number;
|
|
698
|
+
autoplayStart: AutoplayOptions;
|
|
699
|
+
autoplayStop: void;
|
|
700
|
+
turboChange: number;
|
|
701
|
+
buyBonusSelect: {
|
|
702
|
+
id: string;
|
|
703
|
+
};
|
|
704
|
+
featureActivate: {
|
|
705
|
+
id: string;
|
|
706
|
+
};
|
|
707
|
+
featureDeactivate: {
|
|
708
|
+
id: string;
|
|
709
|
+
};
|
|
710
|
+
menuOpen: void;
|
|
711
|
+
settingsOpen: void;
|
|
712
|
+
infoOpen: void;
|
|
713
|
+
settingChange: {
|
|
714
|
+
key: string;
|
|
715
|
+
value: unknown;
|
|
716
|
+
};
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
declare class GameShell extends EventEmitter<ShellEvents> {
|
|
720
|
+
readonly config: ShellConfig;
|
|
721
|
+
state: ShellState;
|
|
722
|
+
private root;
|
|
723
|
+
private styleEl;
|
|
724
|
+
private barHost;
|
|
725
|
+
private modalHost;
|
|
726
|
+
private destroyed;
|
|
727
|
+
layout: 'wide' | 'mobile';
|
|
728
|
+
private ro;
|
|
729
|
+
private prevBalance;
|
|
730
|
+
private prevWin;
|
|
731
|
+
private moneyAnims;
|
|
732
|
+
private keysBound;
|
|
733
|
+
constructor(config: ShellConfig);
|
|
734
|
+
render(): void;
|
|
735
|
+
private cancelMoneyAnims;
|
|
736
|
+
/** Keep the WIN pill inline between the groups; float it above when it won't fit. */
|
|
737
|
+
/**
|
|
738
|
+
* Landscape bar fills the width when it fits. When it overflows, the WIN pill is
|
|
739
|
+
* lifted above the bar (unscaled, so it stays readable) and the remaining row is
|
|
740
|
+
* centred and scaled down to fit — keeping the controls as large as possible.
|
|
741
|
+
*/
|
|
742
|
+
private applyFitScale;
|
|
743
|
+
/** Spacebar starts a spin — same path as the spin disc. Ignored while a spin is running,
|
|
744
|
+
* while autoplay is active, outside base mode, when an overlay/modal is open, or when an
|
|
745
|
+
* editable element is focused. `repeat` (held key) is ignored so it can't spam. */
|
|
746
|
+
private handleKeyDown;
|
|
747
|
+
setLayout(layout: 'wide' | 'mobile'): void;
|
|
748
|
+
/** Resolve a built-in shell string. English is the source; with `isSocial` it is run through
|
|
749
|
+
* the social-casino word-swap. Game-supplied strings should NOT be passed through this. */
|
|
750
|
+
t(text: string): string;
|
|
751
|
+
/** Toggle the social vocabulary at runtime (re-renders the bar; reopen overlays to refresh them). */
|
|
752
|
+
setSocial(isSocial: boolean): void;
|
|
753
|
+
/** Recolour the shell at runtime (e.g. switch dark/light scheme). */
|
|
754
|
+
setTheme(theme: ThemeConfig): void;
|
|
755
|
+
private observeLayout;
|
|
756
|
+
private animateMoney;
|
|
757
|
+
setBalance(n: number): void;
|
|
758
|
+
setWin(n: number): void;
|
|
759
|
+
setBet(n: number): void;
|
|
760
|
+
setMode(mode: ShellMode): void;
|
|
761
|
+
setBusy(busy: boolean): void;
|
|
762
|
+
setAutoplay(a: AutoplayOptions): void;
|
|
763
|
+
setTurbo(level: number): void;
|
|
764
|
+
setBuyBonusEnabled(enabled: boolean): void;
|
|
765
|
+
setFreeSpins(fs: FreeSpinsState): void;
|
|
766
|
+
private showModal;
|
|
767
|
+
/** Uniformly scale every open centred card modal (`.ge-sheet`) down so it fits a short/narrow
|
|
768
|
+
* popout — the same idea as the bar's fit-scale. Covers the pickers, generic + replay modals,
|
|
769
|
+
* AND the buy-bonus confirm (which is hosted inside the overlay, not directly in modalHost).
|
|
770
|
+
* Full-screen overlays handle their own responsiveness (scroll + vh-clamp). */
|
|
771
|
+
fitModals(): void;
|
|
772
|
+
/** Fraction of the frame a card modal may occupy; the rest is breathing-room margin. Keeps
|
|
773
|
+
* modals from filling a small popout edge-to-edge (so even short pickers scale down there). */
|
|
774
|
+
private static readonly MODAL_FIT;
|
|
775
|
+
private fitSheet;
|
|
776
|
+
/** Activate a `feature` option (e.g. Ante): the bar shows the effective bet, tinted with
|
|
777
|
+
* the feature accent, and BUY BONUS becomes DISABLE. */
|
|
778
|
+
activateFeature(bonus: BonusOption): void;
|
|
779
|
+
/** Clear the active feature — reverts the bet readout and the BUY BONUS button. */
|
|
780
|
+
deactivateFeature(): void;
|
|
781
|
+
openMenu(): void;
|
|
782
|
+
openSettings(): void;
|
|
783
|
+
openInfo(): void;
|
|
784
|
+
openBuyBonus(): void;
|
|
785
|
+
/** Open a generic, externally-driven modal (title + body + optional action buttons).
|
|
786
|
+
* Each action runs its `on` then closes; the ✕ shows when `availableClose` is true. */
|
|
787
|
+
openModal(opts: ModalOptions): void;
|
|
788
|
+
/** Open the non-dismissable replay summary modal (START REPLAY → onReplay → reopen). */
|
|
789
|
+
openReplay(opts: ReplayModalOptions): void;
|
|
790
|
+
/** Bet picker — list of available bets with an accent Confirm. */
|
|
791
|
+
openBetPicker(): void;
|
|
792
|
+
/** Autoplay picker — spin-count list; Confirm starts autoplay. */
|
|
793
|
+
openAutoplayPicker(): void;
|
|
794
|
+
destroy(): Promise<void>;
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
declare function createGameShell(config: ShellConfig): GameShell;
|
|
798
|
+
declare function removeGameShell(): Promise<void>;
|
|
799
|
+
|
|
430
800
|
type NativeRNGKind = 'provably-fair' | 'fast';
|
|
431
801
|
/**
|
|
432
802
|
* Replay mode parameters. Forces single-worker deterministic execution over a
|
|
@@ -508,5 +878,5 @@ interface NativeSimulationResult extends SimulationResult {
|
|
|
508
878
|
replay?: NativeReplayParams;
|
|
509
879
|
}
|
|
510
880
|
|
|
511
|
-
export { DevBridge, EventEmitter, LOADER_BAR_MAX_WIDTH, PlatformSession, buildLogoSVG, createCSSPreloader, createPlatformSession, removeCSSPreloader, setCSSPreloaderProgress, waitCSSPreloaderTap };
|
|
512
|
-
export type { ActionDefinition, AssetBundle, AssetEntry, AssetManifest, BetLevelsConfig, DevBridgeConfig, DistributionBucket, GameDefinition, LoadingScreenConfig, LuaEngineConfig, LuaPlayResult, MaxWinConfig, NativeSimulationConfig, NativeSimulationResult, PersistentStateConfig, PlatformSessionConfig, PlatformSessionEvents, SDKOptions, SessionConfig, SimulationConfig, SimulationRawAccumulators, SimulationResult, StageStats, TransitionRule };
|
|
881
|
+
export { DevBridge, EventEmitter, GameShell, LOADER_BAR_MAX_WIDTH, PlatformSession, buildLogoSVG, createCSSPreloader, createGameShell, createPlatformSession, removeCSSPreloader, removeGameShell, setCSSPreloaderProgress, waitCSSPreloaderTap };
|
|
882
|
+
export type { ActionDefinition, AssetBundle, AssetEntry, AssetManifest, AutoplayOptions, BetLevelsConfig, BonusOption, CurrencyConfig, DevBridgeConfig, DistributionBucket, FreeSpinsState, GameDefinition, GameInfoContent, LoadingScreenConfig, LuaEngineConfig, LuaPlayResult, MaxWinConfig, NativeSimulationConfig, NativeSimulationResult, PersistentStateConfig, PlatformSessionConfig, PlatformSessionEvents, ReplayConfig, ReplayLaunch, SDKOptions, SessionConfig, ShellConfig, ShellEvents, ShellFeatures, ShellMode, ShellState, SimulationConfig, SimulationRawAccumulators, SimulationResult, StageStats, ThemeConfig, TransitionRule };
|