@c15t/nextjs
Version:
Developer-first CMP for Next.js: cookie banner, consent manager, preferences centre. GDPR ready with minimal setup and rich customization.
33 lines • 1.01 kB
TypeScript
import { type ConsentManagerProviderProps } from '@c15t/react';
import type { InitialDataPromise } from '../../types';
/**
* Base props for the consent manager provider
*/
type BaseProviderProps = {
children: ConsentManagerProviderProps['children'];
};
/**
* Props when using c15t mode - initialData is required
*/
type C15tModeProps = BaseProviderProps & {
options: ConsentManagerProviderProps['options'] & {
mode?: 'c15t' | undefined;
};
initialData: InitialDataPromise;
};
/**
* Props when using other modes - initialData is not needed
*/
type OtherModeProps = BaseProviderProps & {
options: ConsentManagerProviderProps['options'] & {
mode: 'offline' | 'custom';
};
initialData?: never;
};
/**
* Conditional props based on the mode
*/
type SharedProviderProps = C15tModeProps | OtherModeProps;
export declare function ConsentManagerProvider(props: SharedProviderProps): import("react/jsx-runtime").JSX.Element;
export {};
//# sourceMappingURL=pages.d.ts.map