-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(app-shell): to add label to maintenance page layouts #1583
Conversation
🦋 Changeset is good to goLatest commit: 32aed78 We got this. This PR includes changesets to release 6 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/commercetools/merchant-center-application-kit/6g3ggk79g |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
packages/application-shell/src/components/project-suspended/project-suspended.tsx
Outdated
Show resolved
Hide resolved
98d594a
to
2d6b7a1
Compare
Summary
This pull request adds a label which is used on the images alt to all maintenance pages.
Description
Our maintenance pages mostly have: title, two paragraphs and an image. The image itself however doesn't contain any alt text. It would be good to mostly use the
title
as the alt text on the image.This also eases querying for the image with
byRole('img', { name: //i })
under test.I had multiple solution in mind when working on this:
label
which goes to theimg
alt. Theimg
alt
needs to be a string and can't be React.Nodetitle
and pass it as thealt
. Slighly less flexible but less noisy for consumers. However, thetitle
is an React.Node as it's a FormattedMessage while thealt
needs a string.*IntlMessage
for instancetitleIntlMessage
. This however is a breaking change to the public component.