import React from 'react'; import { useMedia } from 'react-use'; import { Box, Button, config as cssConfig, Dialog, Flex, Text } from '../../..'; import { Sheet } from '../../../Sheet'; export const RequestPrompt = ({ open = true, onOpenChange, title, body, actionText = 'Accept', onAction, disableActions = false, }: { open?: boolean; onOpenChange: (value: boolean) => void; title: string; body: React.ReactNode; actionText?: string; onAction: () => void; disableActions?: boolean; }) => { const isMobile = useMedia(cssConfig.media.md); if (isMobile) { return ( {title} {body} ); } return ( e.preventDefault()}> {title} {body} ); }; const RequestActions = ({ onAction, actionText, disabled = false, }: { actionText?: string; onAction: () => void; disabled?: boolean; }) => ( );