Chance-based game component with three variants: Prize Wheel, Penalty Shootout, and Pick One of X. Game segments, selection mode, animation speed, and per-segment result screens are all configured in the InfoPage entity.
Import
import { ChanceGame } from "fansunited-frontend-components";
import { ChanceGameProps, ChanceGameTemplate, ChanceGameVariant } from "fansunited-frontend-core";
Animated spinning wheel. Supported in all three templates.
Spin animation with configurable pace.
Confetti animation on winning outcomes.
Shake animation on losing outcomes.
Outer ring decoration and pointer indicator.
Penalty Shootout
Soccer penalty kick — users click a target on the goal to shoot. Only supported with the EMBED template.
Soccer stadium field visualisation.
Ball trajectory animations.
Pick One of X
Card or object picking game. Supported in all three templates. Operates in one of two display modes, determined automatically from segment configuration:
Mode
Trigger
Behavior
Flip card
No images.idle on segments
Mystery cards with a "?" that flip to reveal a label.
Object
Segments include images.idle
Custom objects (e.g. treasure chests) crossfade from idle to revealed state.
When config.revealAll: true, remaining items are revealed one-by-one after the user's pick (200 ms staggered delays).
Game configuration
All game logic comes from the InfoPage body, configured as a JSON string. The component fetches it via the SDK.