Critical accessibility fixes for Users page (#2865)

This commit is contained in:
agagancarczyk 2022-06-27 09:45:15 +01:00 committed by GitHub
parent b74265c722
commit 6b257633e4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 11 additions and 2 deletions

View file

@ -163,5 +163,6 @@
"credentialResetConfirm": "Send Email",
"credentialResetConfirmText": "Are you sure you want to send email to user",
"credentialResetEmailSuccess": "Email sent to user.",
"credentialResetEmailError": "Failed: {{error}}"
"credentialResetEmailError": "Failed: {{error}}",
"editUserLabel": "Edit User Label Button"
}

View file

@ -143,6 +143,7 @@ export const ResourcesPolicySelect = ({
aria-labelledby={t(name)}
isDisabled={!!preSelected}
validated={errors[name] ? "error" : "default"}
typeAheadAriaLabel={t(name)}
>
{toSelectOptions()}
</Select>

View file

@ -95,6 +95,7 @@ export const ScopeSelect = ({
aria-labelledby={t("scopes")}
validated={errors.scopes ? "error" : "default"}
isDisabled={!!preSelected}
typeAheadAriaLabel={t("scopes")}
>
{toSelectOptions(scopes)}
</Select>

View file

@ -239,6 +239,7 @@ export const GroupPickerDialog = ({
<DataListCheck
className="kc-join-group-modal-check"
data-testid={`${group.name}-check`}
aria-label={group.name}
checked={group.checked}
isDisabled={isRowDisabled(group)}
onChange={(checked) => {

View file

@ -167,6 +167,7 @@ export const UserForm = ({
<FormGroup label={t("common:id")} fieldId="kc-id" isRequired>
<KeycloakTextInput
id={user.id}
aria-label={t("userID")}
value={user.id}
type="text"
isReadOnly
@ -179,6 +180,7 @@ export const UserForm = ({
)}
type="text"
id="kc-created-at"
aria-label={t("createdAt")}
name="createdTimestamp"
isReadOnly
/>
@ -197,6 +199,7 @@ export const UserForm = ({
ref={register()}
type="text"
id="kc-username"
aria-label={t("username")}
name="username"
isReadOnly={!!user?.id && !realm?.editUsernameAllowed}
/>
@ -258,6 +261,7 @@ export const UserForm = ({
data-testid="firstName-input"
type="text"
id="kc-firstname"
aria-label={t("firstName")}
name="firstName"
/>
</FormGroup>

View file

@ -53,7 +53,7 @@ export const CredentialsResetActionMultiSelect = () => {
event.stopPropagation();
onChange([]);
}}
aria-label={t("resetActions")}
typeAheadAriaLabel={t("resetActions")}
>
{Object.values(RequiredActionAlias).map((action, index) => (
<SelectOption

View file

@ -88,6 +88,7 @@ export const InlineLabelEdit = ({
<>
{credential.userLabel}
<Button
aria-label={t("editUserLabel")}
variant="link"
className="kc-editUserLabel-btn"
onClick={toggle}