seb-oss / green

Green is an open-source design system built by SEB.
https://storybook.seb.io/
Apache License 2.0
37 stars 55 forks source link

Alert Ribbon Close Button Fix #1718

Closed EldRoos closed 3 weeks ago

EldRoos commented 4 weeks ago

Both Chlorophyll and React close button now have custom label and shows up correctly in screen readers.

Check if closeText, isCloseable, closeAriaLabel & closeButton are correct.

Note: This is a remake and a split up of #1672.

green-design-system-bot[bot] commented 4 weeks ago

🦋 Changeset status

Based on the included changeset, the following releases will be published as a result of this PR:

Note: If unpublished changesets where merged to main after the first commit of this PR, this list will include those changes in addition to the ones specific to this PR.

green-design-system-bot[bot] commented 4 weeks ago

👋 Thanks for creating a pull request!

🚀 Checkout the storybooks we've created for it:

astrit commented 4 weeks ago

@EldRoos

You had a test failing, The issue is that the closeAriaLabel prop was not being used in the AlertRibbon component. Instead, the closeText prop was being used to set the aria-label for the close button.

I fixed that so check if everything in order and should be good to go!

Nice job 👌

EldRoos commented 4 weeks ago

@astrit

Great Astrit. I was thinking this fix when I was in the shower :) but you beat me to it. I wonder why we use 2 variables for same thing.