Skip to content

feat: add customizable accessibility labels for prev/next navigation buttons#242

Open
jvilliers wants to merge 5 commits intofarhoudshapouran:mainfrom
sqli:feature/update_month_accessibility
Open

feat: add customizable accessibility labels for prev/next navigation buttons#242
jvilliers wants to merge 5 commits intofarhoudshapouran:mainfrom
sqli:feature/update_month_accessibility

Conversation

@jvilliers
Copy link
Copy Markdown

Add prevButtonAccessibilityLabel and nextButtonAccessibilityLabel props to DatePickerBaseProps, allowing consumers to override the default "Prev" / "Next" accessibility labels on the calendar navigation buttons.

This is useful for apps that need localized or context-specific accessibility labels to comply with screen reader requirements.

Changes:

types.ts — add prevButtonAccessibilityLabel?: string and nextButtonAccessibilityLabel?: string to DatePickerBaseProps
datetime-picker.tsx — forward both props through the calendar context value
prev-button.tsx — consume prevButtonAccessibilityLabel from context (default: 'Prev')
next-button.tsx — consume nextButtonAccessibilityLabel from context (default: 'Next')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants