Additional CTA
Most game components support an extra call-to-action button on their completion / results screen via the additionalCTA prop. This is useful for cross-promoting other content, sending users to a campaign page, or wiring up a custom journey.
A separate onSuccessCTA (with the same shape) exists on CollectLead for the post-submission success screen — see the CollectLead page.
AdditionalCTADetails
interface AdditionalCTADetails {
defaultLabel?: string;
onClick?: () => void;
url?: string | null;
target?: LinkTargetType; // "_blank" | "_self" | "_parent" | "_top"
component?: React.ReactElement | null;
}| Field | Description |
|---|---|
defaultLabel | Button label. Required unless component is provided. |
onClick | Click handler. |
url | Destination URL. |
target | Anchor target. Defaults to _self. |
component | Custom React element rendered in place of the default button. |
Priority order
Same rendering rules as signInCTA:
componentif providedonClickif providedurlif provided- Otherwise, the button is not rendered
Unlike
signInCTA, the additional CTA is purely optional — if you don't pass it, nothing is rendered. There is no disabled-fallback.
Examples
import { AdditionalCTADetails } from "fansunited-frontend-core";
// Click handler
const additionalCTA: AdditionalCTADetails = {
defaultLabel: "See More",
onClick: () => console.log("clicked"),
};
// URL navigation
const additionalCTA: AdditionalCTADetails = {
defaultLabel: "Visit Website",
url: "https://your-website.com",
target: "_blank",
};
// Custom component
const additionalCTA: AdditionalCTADetails = {
component: <CustomCTAButton />,
};
<ClassicQuizPlay {...otherProps} additionalCTA={additionalCTA} />;Placement by component and template
| Component | Standard | Split | Overlay |
|---|---|---|---|
ClassicQuizPlay | After Play Again and Share Result | After Play Again (in thank-you container) | After Play Again and Share Result |
PollVote | Before Vote Again | Same container as Vote Again | After Vote Again |
PersonalityQuizPlay | Before Play Again | In thank-you container after Play Again | After Play Again (if available) |
MatchQuizPlay | Same line as branding logo | Centered after main content | Same line as branding logo |
EventGamePlay | After prediction summary | After prediction summary | After prediction summary |
EitherOrPlay | On results screen | n/a | On results screen |
Supported components
ClassicQuizPlay, PollVote, PersonalityQuizPlay, MatchQuizPlay, EventGamePlay, EitherOrPlay.
