import * as React from 'react'; import AnchorLink from './AnchorLink'; export declare type AnchorContainer = HTMLElement | Window; export interface AnchorProps { prefixCls?: string; className?: string; style?: React.CSSProperties; children?: React.ReactNode; offsetTop?: number; bounds?: number; affix?: boolean; showInkInFixed?: boolean; inkPosition?: 'left' | 'right'; getContainer?: () => AnchorContainer; /** Return customize highlight anchor */ getCurrentAnchor?: () => string; onClick?: (e: React.MouseEvent, link: { title: React.ReactNode; href: string; }) => void; /** Scroll to target offset value, if none, it's offsetTop prop value or 0. */ targetOffset?: number; /** Listening event when scrolling change active link */ onChange?: (currentActiveLink: string) => void; } export interface FishdAnchor { registerLink: (link: string) => void; unregisterLink: (link: string) => void; activeLink: string | null; scrollTo: (link: string) => void; onClick?: (e: React.MouseEvent, link: { title: React.ReactNode; href: string; }) => void; } export interface AnchorState { activeLink: null | string; } interface CompoundAnchor extends React.FC { Link?: typeof AnchorLink; } declare const Anchor: CompoundAnchor; export default Anchor;