evals
scenario-1
scenario-10
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
Build a keyboard-accessible help system component that displays contextual help information for form inputs. The system should be fully navigable using only keyboard controls (Tab, Shift+Tab, and Escape keys) and should meet accessibility standards for screen reader users.
Create a HelpfulInput component that wraps a form input field with contextual help. The help information should:
The component must be accessible to screen reader users:
import React from 'react';
export interface HelpfulInputProps {
/** The label for the input field */
label: string;
/** The help text to display when the input is focused */
helpText: string;
/** The input placeholder text */
placeholder?: string;
/** The input name attribute */
name: string;
}
/**
* A form input component with keyboard-accessible contextual help.
* Shows help information when the input receives focus via keyboard navigation.
*/
export function HelpfulInput(props: HelpfulInputProps): React.ReactElement;Provides accessible tooltip components with keyboard navigation support.