More UI changes

This commit is contained in:
Janika Kefel
2018-12-19 13:28:04 +01:00
parent 3a62f81ba0
commit 4d181a574a
17 changed files with 1425 additions and 1358 deletions

View File

@@ -1,55 +1,55 @@
//@flow
import React from "react";
import type { Repository } from "@scm-manager/ui-types";
import { MailLink, DateFromNow } from "@scm-manager/ui-components";
import { translate } from "react-i18next";
type Props = {
repository: Repository,
// context props
t: string => string
};
class RepositoryDetailTable extends React.Component<Props> {
render() {
const { repository, t } = this.props;
return (
<table className="table">
<tbody>
<tr>
<td>{t("repository.name")}</td>
<td>{repository.name}</td>
</tr>
<tr>
<td>{t("repository.type")}</td>
<td>{repository.type}</td>
</tr>
<tr>
<td>{t("repository.contact")}</td>
<td>
<MailLink address={repository.contact} />
</td>
</tr>
<tr>
<td>{t("repository.description")}</td>
<td>{repository.description}</td>
</tr>
<tr>
<td>{t("repository.creationDate")}</td>
<td>
<DateFromNow date={repository.creationDate} />
</td>
</tr>
<tr>
<td>{t("repository.lastModified")}</td>
<td>
<DateFromNow date={repository.lastModified} />
</td>
</tr>
</tbody>
</table>
);
}
}
export default translate("repos")(RepositoryDetailTable);
//@flow
import React from "react";
import type { Repository } from "@scm-manager/ui-types";
import { MailLink, DateFromNow } from "@scm-manager/ui-components";
import { translate } from "react-i18next";
type Props = {
repository: Repository,
// context props
t: string => string
};
class RepositoryDetailTable extends React.Component<Props> {
render() {
const { repository, t } = this.props;
return (
<table className="table">
<tbody>
<tr>
<td className="has-text-weight-semibold">{t("repository.name")}</td>
<td>{repository.name}</td>
</tr>
<tr>
<td className="has-text-weight-semibold">{t("repository.type")}</td>
<td>{repository.type}</td>
</tr>
<tr>
<td className="has-text-weight-semibold">{t("repository.contact")}</td>
<td>
<MailLink address={repository.contact} />
</td>
</tr>
<tr>
<td className="has-text-weight-semibold">{t("repository.description")}</td>
<td>{repository.description}</td>
</tr>
<tr>
<td className="has-text-weight-semibold">{t("repository.creationDate")}</td>
<td>
<DateFromNow date={repository.creationDate} />
</td>
</tr>
<tr>
<td className="has-text-weight-semibold">{t("repository.lastModified")}</td>
<td>
<DateFromNow date={repository.lastModified} />
</td>
</tr>
</tbody>
</table>
);
}
}
export default translate("repos")(RepositoryDetailTable);