UNPKG

@yamada-ui/stepper

Version:

Yamada UI stepper component

62 lines (59 loc) 1.74 kB
import * as _yamada_ui_core from '@yamada-ui/core'; import { ThemeProps } from '@yamada-ui/core'; import { ReactNode } from 'react'; import { StepProps } from './step.js'; import { StepDescriptionProps } from './step-description.js'; import { StepSeparatorProps } from './step-separator.js'; import { StepStatusProps } from './step-status.js'; import { StepTitleProps } from './step-title.js'; import { UseStepperProps } from './use-stepper.js'; import '@yamada-ui/icon'; import '@yamada-ui/use-descendant'; interface StepItem extends Omit<StepProps, "title"> { /** * The description for step component. */ description?: ReactNode; /** * If true, display the step separator. * * @default true */ hasSeparator?: boolean; /** * The title for step component. */ title?: ReactNode; /** * Props for step description element. */ descriptionProps?: StepDescriptionProps; /** * Props for step separator element. */ separatorProps?: StepSeparatorProps; /** * Props for step status element. */ statusProps?: StepStatusProps; /** * Props for step title element. */ titleProps?: StepTitleProps; } type Steps = StepItem[]; interface StepperOptions { /** * If provided, generate step components based on steps. */ steps?: Steps; } interface StepperProps extends ThemeProps<"Stepper">, UseStepperProps, StepperOptions { } /** * `Stepper` is a component that displays the progress of a multi-step process. * * @see Docs https://yamada-ui.com/components/navigation/stepper */ declare const Stepper: _yamada_ui_core.Component<"div", StepperProps>; export { Stepper, type StepperProps, type Steps };