@spark-ui/components
Version:
Spark (Leboncoin design system) components.
120 lines (104 loc) • 4.13 kB
TypeScript
import * as react_jsx_runtime from 'react/jsx-runtime';
import { e as DialogProps, C as CloseProps, h as BodyProps, f as ContentProps, n as DescriptionProps, i as FooterProps, g as HeaderProps, k as OverlayProps, l as PortalProps, m as TitleProps, j as TriggerProps } from '../DialogTrigger-5SI4dvpK.js';
import { Ref, MutableRefObject } from 'react';
import 'radix-ui';
import 'class-variance-authority/types';
import 'class-variance-authority';
type AlertDialogProps = Omit<DialogProps, 'modal'>;
declare const AlertDialog$1: {
(props: AlertDialogProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogActionProps = CloseProps & {
ref?: Ref<HTMLButtonElement>;
};
declare const AlertDialogAction: {
(props: AlertDialogActionProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogBodyProps = BodyProps & {
ref?: Ref<HTMLDivElement>;
};
declare const AlertDialogBody: {
(props: AlertDialogBodyProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogCancelProps = CloseProps & {
ref?: Ref<HTMLButtonElement>;
};
declare const AlertDialogCancel: {
({ ref: forwardedRef, ...props }: AlertDialogCancelProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogContentProps = Omit<ContentProps, 'size' | 'isNarrow' | 'onPointerDownOutside' | 'onInteractOutside'> & {
ref?: Ref<HTMLDivElement>;
};
declare const AlertDialogContent: {
({ className, onOpenAutoFocus, ref, ...others }: AlertDialogContentProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogDescriptionProps = DescriptionProps & {
ref?: Ref<HTMLParagraphElement>;
};
declare const AlertDialogDescription: {
(props: AlertDialogDescriptionProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogFooterProps = FooterProps & {
ref?: Ref<HTMLDivElement>;
};
declare const AlertDialogFooter: {
(props: AlertDialogFooterProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogHeaderProps = HeaderProps & {
ref?: Ref<HTMLDivElement>;
};
declare const AlertDialogHeader: {
(props: AlertDialogHeaderProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogOverlayProps = OverlayProps & {
ref?: Ref<HTMLDivElement>;
};
declare const AlertDialogOverlay: {
(props: AlertDialogOverlayProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogPortalProps = PortalProps;
declare const AlertDialogPortal: {
(props: AlertDialogPortalProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogTitleProps = TitleProps & {
ref?: Ref<HTMLParagraphElement>;
};
declare const AlertDialogTitle: {
(props: AlertDialogTitleProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
type AlertDialogTriggerProps = TriggerProps & {
ref?: Ref<HTMLButtonElement>;
};
declare const AlertDialogTrigger: {
(props: AlertDialogTriggerProps): react_jsx_runtime.JSX.Element;
displayName: string;
};
interface AlertDialogContextValue {
cancelRef: MutableRefObject<HTMLButtonElement | null>;
}
declare const useAlertDialog: () => AlertDialogContextValue;
declare const AlertDialog: typeof AlertDialog$1 & {
Action: typeof AlertDialogAction;
Body: typeof AlertDialogBody;
Cancel: typeof AlertDialogCancel;
Content: typeof AlertDialogContent;
Description: typeof AlertDialogDescription;
Footer: typeof AlertDialogFooter;
Header: typeof AlertDialogHeader;
Overlay: typeof AlertDialogOverlay;
Portal: typeof AlertDialogPortal;
Title: typeof AlertDialogTitle;
Trigger: typeof AlertDialogTrigger;
};
export { AlertDialog, type AlertDialogActionProps, type AlertDialogBodyProps, type AlertDialogCancelProps, type AlertDialogContentProps, type AlertDialogDescriptionProps, type AlertDialogFooterProps, type AlertDialogHeaderProps, type AlertDialogOverlayProps, type AlertDialogPortalProps, type AlertDialogProps, type AlertDialogTitleProps, type AlertDialogTriggerProps, useAlertDialog };