import { default as React } from 'react'; import { IconProps } from '../../../tedi/components/base/icon/icon'; import { AllowedHTMLTags, PolymorphicComponentPropWithRef } from '../../helpers/polymorphic/types'; import { IntentionalAny } from '../../types'; import { ButtonColor, ButtonType } from '../button/button'; export type ButtonContentProps, A> = PolymorphicComponentPropWithRef, { /** * Button children */ children: React.ReactNode; /** * Additional custom class name. */ className?: string; /** * Button visual type * @default primary */ visualType?: ButtonType; /** * If button should take all the space it has */ fullWidth?: boolean; /** * Color schema for button. PS text-color works only with link type links. * @default default */ color?: ButtonColor; /** * Button size */ size?: 'small'; /** * Name of the icon when button only has an icon in it. */ icon?: string | IconProps; /** * Name of the icon we want to show on the left. */ iconLeft?: string | IconProps; /** * Name of the icon we want to show on the right. */ iconRight?: string | IconProps; /** * Underline the button text */ underline?: boolean; /** * If button is active and should keep its hover state. */ isHovered?: boolean; /** * If button is active and should keep it's active state. */ isActive?: boolean; /** * If button is in loading state and should show spinner. * When isLoading is true, button does not trigger onClick event. * @default false */ isLoading?: boolean; /** * Skip applying button/link styles * Useful when you just want to use Button or Anchor logic without the styles * In this case icon, iconLeft and iconRight are ignored */ noStyle?: boolean; /** * */ renderWrapperElement?: unknown; } & P>; export type ButtonContentComponent = , A>(props: ButtonContentProps) => React.ReactElement | null; /** * Shares the rendering logic between `Anchor` and `Button`. We don't export it from the component library. */ declare const ButtonContent: ButtonContentComponent; export default ButtonContent;