rollback changes on branches overview

This commit is contained in:
Eduard Heimbuch
2020-09-17 11:17:25 +02:00
parent 89b6829108
commit fe832ae13e
12 changed files with 18 additions and 115 deletions

View File

@@ -25,23 +25,13 @@ import React, { FC } from "react";
import { Link } from "react-router-dom";
import { Branch } from "@scm-manager/ui-types";
import DefaultBranchTag from "./DefaultBranchTag";
import { DateFromNow } from "@scm-manager/ui-components";
import { useTranslation } from "react-i18next";
import styled from "styled-components";
type Props = {
baseUrl: string;
branch: Branch;
};
const Modified = styled.span`
margin-left: 1rem;
font-size: 0.8rem;
`;
const BranchRow: FC<Props> = ({ baseUrl, branch }) => {
const [t] = useTranslation("repos");
const to = `${baseUrl}/${encodeURIComponent(branch.name)}/info`;
return (
<tr>
@@ -49,12 +39,6 @@ const BranchRow: FC<Props> = ({ baseUrl, branch }) => {
<Link to={to} title={branch.name}>
{branch.name}
<DefaultBranchTag defaultBranch={branch.defaultBranch} />
{branch?.lastModified && branch.lastModifier && (
<Modified className="has-text-grey is-ellipsis-overflow">
{t("branches.overview.lastModified")} <DateFromNow date={branch.lastModified} />{" "}
{t("branches.overview.lastModifier")} {branch.lastModifier?.name}
</Modified>
)}
</Link>
</td>
</tr>