import * as React from 'react'; import Stack, { StackProps } from '@mui/material/Stack'; import Typography, { TypographyProps } from '@mui/material/Typography'; import TextField, { TextFieldProps } from '@mui/material/TextField'; import { SlotComponentProps } from '@mui/base/utils'; import { BaseSingleInputFieldProps } from '@mui/x-date-pickers/models'; import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals/models'; import { PickersInputLocaleText } from '@mui/x-date-pickers/locales'; import { BaseFieldProps, UsePickerResponse, WrapperVariant, UncapitalizeObjectKeys, UsePickerProps } from '@mui/x-date-pickers/internals'; import { BaseMultiInputFieldProps, DateRange, RangeFieldSection, RangePosition, UseDateRangeFieldProps } from '../models'; import { UseRangePositionResponse } from './useRangePosition'; export interface RangePickerFieldSlotsComponent { Field: React.ElementType; /** * Element rendered at the root. * Ignored if the field has only one input. */ FieldRoot?: React.ElementType; /** * Element rendered between the two inputs. * Ignored if the field has only one input. */ FieldSeparator?: React.ElementType; /** * Form control with an input to render a date or time inside the default field. * It is rendered twice: once for the start element and once for the end element. * Receives the same props as `@mui/material/TextField`. * @default TextField from '@mui/material' */ TextField?: React.ElementType; } export interface RangePickerFieldSlotsComponentsProps { field?: SlotComponentProps, TDate, RangeFieldSection, unknown>>, {}, UsePickerProps, any, RangeFieldSection, any, any, any>>; fieldRoot?: SlotComponentProps>; fieldSeparator?: SlotComponentProps>; textField?: SlotComponentProps & { position?: RangePosition; }>; } export interface UseEnrichedRangePickerFieldPropsParams, TDate, RangeFieldSection, TError> = BaseFieldProps, TDate, RangeFieldSection, TError>> extends Pick, TView, RangeFieldSection, any>, 'open' | 'actions'>, UseRangePositionResponse { wrapperVariant: WrapperVariant; fieldType: 'single-input' | 'multi-input'; readOnly?: boolean; labelId?: string; disableOpenPicker?: boolean; onBlur?: () => void; inputRef?: React.Ref; label?: React.ReactNode; localeText: PickersInputLocaleText | undefined; pickerSlotProps: RangePickerFieldSlotsComponentsProps | undefined; pickerSlots: UncapitalizeObjectKeys | undefined; fieldProps: FieldProps; } export declare const useEnrichedRangePickerFieldProps: (params: UseEnrichedRangePickerFieldPropsParams, TDate, RangeFieldSection, TError>>) => BaseMultiInputFieldProps, TDate, RangeFieldSection, TError> | BaseSingleInputFieldProps, TDate, RangeFieldSection, TError>;