helpscout / hsds-react

Help Scout Design System (HSDS) — React Component Library
MIT License
86 stars 17 forks source link

SimpleModal (confirmation layout): Swap which buttons handlers are applied to #1069

Closed knicklabs closed 2 years ago

knicklabs commented 2 years ago

Problem/Feature

The button handlers were connected in reverse:

Solution

This pull request is a small change to flip the usage of the button handlers:

That's it!

One more thing

Adds 2 props cancelButtonProps and confirmButtonProps to pass any valid Button prop to each button.

cloudflare-pages[bot] commented 2 years ago

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 122ec6d
Status: ✅  Deploy successful!
Preview URL: https://b215182c.hsds-react.pages.dev

View logs

knicklabs commented 2 years ago

@tinkertrain the new props look good!