import { default as StepConfig } from './StepConfig';
import { default as StepperTypeMap } from './StepperTypeMap';
import { default as StepperContextValue } from './StepperContextValue';
/**
 * Returned by `useStepper`. Flat shape: spread `layoutProps` into `<StepperLayout>`,
 * pass the whole value to `<StepperProvider>`. Nav methods (`reset`, `goNext`, …)
 * are accessible at the parent for things like a Cancel button.
 * Inside step components, use `useStepperState()` for state and `useStepperHandlers()` for navigation and data.
 *
 * @example
 * ```tsx
 * const stepper = useStepper<MyData>(steps);
 * <StepperProvider stepper={stepper}>
 *   <StepperLayout {...stepper.layoutProps}
 *     secondaryActions={<Button onClick={stepper.reset} />}
 *   >
 *     <CompanyStep />
 *   </StepperLayout>
 * </StepperProvider>
 * ```
 */
type StepperReturn<TDataMap extends StepperTypeMap = StepperTypeMap> = StepperContextValue<TDataMap> & {
    layoutProps: {
        steps: StepConfig[];
        activeStep: number;
        onNext: () => Promise<void>;
        onBack: () => Promise<void>;
    };
};
export default StepperReturn;
