Enhance ui-elements to be more accessible on smaller screens (#1950)

Enable breaking of content to be fully available on small screens or highly zoomed displays. This should help improve accessibility.

Co-authored-by: Florian Scholdei <florian.scholdei@cloudogu.com>
Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
This commit is contained in:
Phil-Ah
2022-02-18 14:48:21 +01:00
committed by GitHub
parent b85dc8f0e6
commit 78b507921d
38 changed files with 2649 additions and 3233 deletions

View File

@@ -25,7 +25,8 @@ import React from "react";
import { WithTranslation, withTranslation } from "react-i18next";
import { Link } from "react-router-dom";
import { User } from "@scm-manager/ui-types";
import { Icon, createAttributesForTesting } from "@scm-manager/ui-components";
import { createAttributesForTesting, Icon } from "@scm-manager/ui-components";
import classNames from "classnames";
type Props = WithTranslation & {
user: User;
@@ -51,11 +52,13 @@ class UserRow extends React.Component<Props> {
return (
<tr className={user.active ? "border-is-green" : "border-is-yellow"}>
<td>
<td className="is-word-break">
{iconType} {this.renderLink(to, user.name)}
</td>
<td className="is-hidden-mobile">{this.renderLink(to, user.displayName)}</td>
<td>{user.mail ? <a href={`mailto:${user.mail}`}>{user.mail}</a> : null}</td>
<td className={classNames("is-hidden-mobile", "is-word-break")}>{this.renderLink(to, user.displayName)}</td>
<td className={classNames("is-hidden-mobile", "is-word-break")}>
{user.mail ? <a href={`mailto:${user.mail}`}>{user.mail}</a> : null}
</td>
</tr>
);
}