UNPKG

830 BTypeScriptView Raw
1import * as React from 'react';
2export type EventHandlers = Record<string, React.EventHandler<any>>;
3export type WithOptionalOwnerState<Props extends {
4 ownerState: unknown;
5}> = Omit<Props, 'ownerState'> & Partial<Pick<Props, 'ownerState'>>;
6export type SlotComponentProps<TSlotComponent extends React.ElementType, TOverrides, TOwnerState> = (Partial<React.ComponentPropsWithRef<TSlotComponent>> & TOverrides) | ((ownerState: TOwnerState) => Partial<React.ComponentPropsWithRef<TSlotComponent>> & TOverrides);
7export type SlotComponentPropsWithSlotState<TSlotComponent extends React.ElementType, TOverrides, TOwnerState, TSlotState> = (Partial<React.ComponentPropsWithRef<TSlotComponent>> & TOverrides) | ((ownerState: TOwnerState, slotState: TSlotState) => Partial<React.ComponentPropsWithRef<TSlotComponent>> & TOverrides);
8
\No newline at end of file