Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ export const FunnelStepper = ({
onNavigation: trackOnNavigate,
});
const { transition: sendTransition } = useStepTransition(session.id);
const isCookieBannerActive = !!funnel?.parameters?.cookieConsent?.show;
const { showBanner, ...cookieConsentProps } = useFunnelCookies({
defaultOpen: showCookieBanner,
trackFunnelEvent,
Expand Down Expand Up @@ -146,7 +147,7 @@ export const FunnelStepper = ({
onScrollCapture={trackOnScroll}
className="flex min-h-dvh flex-col"
>
{showBanner && (
{isCookieBannerActive && showBanner && (
<CookieConsent key="cookie-consent" {...cookieConsentProps} />
)}
<FunnelStepBackground step={step}>
Expand Down
6 changes: 5 additions & 1 deletion packages/shared/src/features/onboarding/types/funnel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,11 @@ export type FunnelPosition = {
export interface FunnelJSON {
id: string;
version: number;
parameters: FunnelStepParameters;
parameters: FunnelStepParameters<{
cookieConsent: {
show: boolean;
};
}>;
entryPoint: FunnelStep['id'];
chapters: Array<FunnelChapter>;
}
Expand Down