import React from 'react'; export interface ItemsProps { icon?: React.ReactNode; text?: React.ReactNode; color?: 'green' | 'white' | 'anchor'; size?: 'small' | 'medium'; onClick?: (e: React.MouseEvent) => void; } export interface ActionButtonProps { anchor?: number | React.RefObject | (() => { current: HTMLElement; }); /** * Set button content, icon & text label */ children?: React.ReactNode; /** * The point in scrolled pixel when the button appear in */ entryPoint?: number; /** * Set FAB color */ color?: 'green' | 'white' | 'anchor'; /** * Set FAB size */ size?: 'small' | 'medium'; /** * Set component micro-interaction, such as enter & exit animation on scroll */ enableScrollInteraction?: boolean; /** * Set callback function when FAB clicked */ onClick?: (e: React.MouseEvent) => void; } export interface BackToTopProps { lang?: 'en' | 'id'; } export interface ButtonMenuProps { /** * Set button menu display */ display?: boolean; /** * Set button menu items */ items?: ItemsProps[]; /** * Set callback function when overlay clicked */ onClickOverlay?: (e: React.MouseEvent) => void; } export interface FloatingContainerProps { /** * Set the content of container */ children: React.ReactNode; /** * Set FAB offset from another element or it's position relative to viewport */ offset?: number | React.RefObject; /** * Set FAB position on the viewport */ position?: 'top-left' | 'top-center' | 'top-right' | 'bottom-left' | 'bottom-center' | 'bottom-right'; /** * Set component z-index */ zIndex?: number; } export interface FloatingActionButtonProps { /** * Set button menu to expand */ expanded?: boolean; /** * Set button menu items */ items?: ItemsProps[]; /** * Set callback function on clicking overlay */ onClickOverlay?: (e: React.MouseEvent) => void; }