-
Notifications
You must be signed in to change notification settings - Fork 273
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
fix(ui5-card): fix accessibiity role position #10437
Conversation
@@ -124,6 +124,28 @@ describe("CardHeader", () => { | |||
assert.strictEqual(await header2.getAttribute("aria-labelledby"), EXPECTED_ARIA_LABELLEDBY_HEADER2, | |||
"The aria-labelledby is correctly set."); | |||
}); | |||
|
|||
it("test interactive card header accessibility role", async () => { |
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.
Let's write these tests in Cypress, as we are going to nevertheless migrate all the wdio tests to Cypress.
cy.get("#cardHeader1") | ||
.shadow() | ||
.find(".ui5-card-header-focusable-element") | ||
.should("have.attr", "role", "button"); |
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.
We can combine these assertions as they are called on the same element
cy.get("#cardHeader1")
.shadow()
.find(".ui5-card-header-focusable-element")
.should("have.attr", "role", "button")
.and("have.attr", "tabindex", "0")
.and("have.attr", "aria-roledescription", "Interactive Card Header");
Same for the second test
🎉 This PR is included in version v2.7.0-rc.1 🎉 The release is available on v2.7.0-rc.1 Your semantic-release bot 📦🚀 |
FIX: #10367