UNPKG

@ta-interaktiv/react-masthead

Version:
35 lines 1.4 kB
import React, { Component, ComponentPropsWithoutRef } from 'react'; import { Masthead } from './pureMasthead'; import { Props as TrackingProps } from '@ta-interaktiv/react-tracking'; import { ShareButtonsProps } from '@ta-interaktiv/react-share-buttons'; import { ArticleId, Locale, Paywall } from '@ta-interaktiv/types'; interface Props extends Partial<ComponentPropsWithoutRef<typeof Masthead>>, ArticleId, Locale { enablePaywall?: boolean; paywallContainerId?: string; additionalShares?: number; additionalFacebookShares?: number; } type DynamicButtonProps = Pick<ShareButtonsProps, 'clickHandler' | 'facebookAppId' | 'twitterHandle' | 'lead' | 'title'>; type DynamicTrackingProps = Partial<Pick<TrackingProps, 'gtmId'>>; interface State extends DynamicButtonProps, DynamicTrackingProps, Partial<Paywall>, Locale { fullMediaName?: string; homepage: string; mediaName: string; url?: string; title: string; } export declare class PolymorphicMasthead extends Component<Props, State> { private parsedHostname; private readonly articleId; static defaultProps: { enablePaywall: boolean; defaultLanguage: string; paywallContainerId: string; }; state: State; errorHandler: (e: Error) => void; render(): React.JSX.Element; componentDidMount(): void; } export {}; //# sourceMappingURL=polymorphicMasthead.d.ts.map