Skip to content

fix(close-button): pass slot="close" prop to RAC Button component#181

Open
amitbeck wants to merge 1 commit into
untitleduico:mainfrom
amitbeck:patch-1
Open

fix(close-button): pass slot="close" prop to RAC Button component#181
amitbeck wants to merge 1 commit into
untitleduico:mainfrom
amitbeck:patch-1

Conversation

@amitbeck
Copy link
Copy Markdown

Description

A button with a slot="close" will act as a close button and close RAC modals and overlays

https://react-aria.adobe.com/Modal#api

Related issues

Closes #

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Style/UI change (visual improvements, no functional changes)
  • Accessibility improvement
  • Refactoring (code changes that neither fix a bug nor add a feature)
  • Performance improvement
  • Chore (dependency updates, tooling changes, etc.)

Testing

Testing checklist

  • Functionality: Component works as expected
  • TypeScript: No TypeScript errors
  • Storybook: Stories render correctly
  • Accessibility:
    • Keyboard navigation works
    • Screen reader compatible
    • Focus management is correct
    • Color contrast meets WCAG AA standards
  • Responsive: Works on mobile, tablet, and desktop
  • Browser testing: Tested in multiple browsers
  • Performance: No performance regressions

Manual testing steps

Screenshots/Videos

Before

After

Code quality checklist

  • Code style: Follows project conventions
  • ESLint: No linting errors
  • Prettier: Code is properly formatted
  • TypeScript: Full type coverage
  • Imports: Uses correct import paths (@/components/...)
  • Performance: No unnecessary re-renders or heavy computations
  • Error handling: Appropriate error boundaries and validation

📚 Documentation

  • Component props are documented with TypeScript interfaces
  • Storybook stories cover all variants
  • Usage examples are provided

Breaking changes

Migration guide

// Before
<OldComponent prop="value" />

// After
<NewComponent newProp="value" />

Additional context

A button with a `slot="close"` will act as a close button and close RAC modals and overlays
https://react-aria.adobe.com/Modal#api
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.

1 participant