/*
 * Runtime Web – Unified Serverless Framework for Full-Stack TypeScript Applications
 * Documentation: https://runtimeweb.com/docs/getting-started
 *
 * @template: ai-chat
 */

/**
 * ErrorMessage Component
 *
 * Displays error messages with Retry and Dismiss actions.
 * Thin wrapper around ErrorState that preserves the original props interface.
 *
 * @requirements 6.1
 */

import * as React from 'react';
import { ErrorState } from './ErrorState';

interface ErrorMessageProps {
    error: Error;
    onRetry: () => void;
    onDismiss: () => void;
}

/**
 * ErrorMessage component displays errors with action buttons.
 * Delegates to ErrorState for enhanced functionality.
 */
export const ErrorMessage: React.FC<ErrorMessageProps> = ({ error, onRetry, onDismiss }) => {
    return <ErrorState error={error} onRetry={onRetry} onDismiss={onDismiss} />;
};
