diff --git a/docs/ACCESSIBILITY.md b/docs/ACCESSIBILITY.md deleted file mode 100644 index 8303571..0000000 --- a/docs/ACCESSIBILITY.md +++ /dev/null @@ -1,500 +0,0 @@ -# Accessibility Standards - -This document outlines accessibility (a11y) requirements for all components in the library, ensuring compatibility with screen readers and assistive technologies. - -## Interactive Components - -For buttons, links, and other interactive elements. - -### Required Props - -```tsx -interface ButtonProps { - text: string; - onClick?: () => void; - className?: string; - // Accessibility props - disabled?: boolean; - ariaLabel?: string; - type?: "button" | "submit" | "reset"; -} -``` - -### Implementation Pattern - -```tsx -const Button = ({ - text, - onClick, - className = "", - disabled = false, - ariaLabel, - type = "button", -}: ButtonProps) => { - return ( - - ); -}; -``` - -### Key Points - -**ariaLabel:** -- Optional prop with sensible fallback -- Falls back to `text` content for buttons -- Provides context for screen readers - -**type:** -- Default: `"button"` -- Options: `"button" | "submit" | "reset"` -- Prevents accidental form submission - -**disabled:** -- Default: `false` -- Includes visual disabled states: - - `disabled:cursor-not-allowed` - Shows not-allowed cursor - - `disabled:opacity-50` - Reduces opacity for visual feedback - -## Media Components - -### Images - -**Required Props:** -```tsx -interface ImageProps { - imageSrc: string; - imageAlt?: string; // Empty string for decorative images - className?: string; -} -``` - -**Implementation:** -```tsx -const ImageComponent = ({ - imageSrc, - imageAlt = "", - className = "", -}: ImageProps) => { - return ( - {imageAlt} - ); -}; -``` - -**Key Points:** -- `imageAlt` - Alt text for images - - Provide descriptive alt text for meaningful images - - Use empty string (`""`) for decorative images -- `aria-hidden={true}` - When alt is empty, mark as decorative -- Screen readers will skip decorative images - -### Videos - -**Required Props:** -```tsx -interface VideoProps { - videoSrc: string; - videoAriaLabel?: string; - className?: string; -} -``` - -**Implementation:** -```tsx -const VideoComponent = ({ - videoSrc, - videoAriaLabel = "Video content", - className = "", -}: VideoProps) => { - return ( -