add second extension point for repository favorite

This commit is contained in:
Eduard Heimbuch
2020-03-24 08:46:58 +01:00
parent 4d444d2189
commit e2d4ebe706
3 changed files with 9 additions and 6 deletions

View File

@@ -2,6 +2,7 @@ import React from "react";
import { WithTranslation, withTranslation } from "react-i18next"; import { WithTranslation, withTranslation } from "react-i18next";
import { Repository } from "@scm-manager/ui-types"; import { Repository } from "@scm-manager/ui-types";
import { DateFromNow, MailLink } from "@scm-manager/ui-components"; import { DateFromNow, MailLink } from "@scm-manager/ui-components";
import { ExtensionPoint } from "@scm-manager/ui-extensions";
type Props = WithTranslation & { type Props = WithTranslation & {
repository: Repository; repository: Repository;
@@ -15,7 +16,9 @@ class RepositoryDetailTable extends React.Component<Props> {
<tbody> <tbody>
<tr> <tr>
<th>{t("repository.name")}</th> <th>{t("repository.name")}</th>
<td>{repository.name}</td> <td>
<ExtensionPoint name={"repository.details.beforeName"} props={{ repository }} /> {repository.name}
</td>
</tr> </tr>
<tr> <tr>
<th>{t("repository.type")}</th> <th>{t("repository.type")}</th>

View File

@@ -66,7 +66,7 @@ class RepositoryEntry extends React.Component<Props> {
const { repository } = this.props; const { repository } = this.props;
return ( return (
<> <>
<ExtensionPoint name="repository.card.beforeTitle" props={{repository}} /> <strong>{repository.name}</strong> <ExtensionPoint name="repository.card.beforeTitle" props={{ repository }} /> <strong>{repository.name}</strong>
</> </>
); );
}; };

View File

@@ -4370,10 +4370,10 @@ bulma-tooltip@^3.0.0:
resolved "https://registry.yarnpkg.com/bulma-tooltip/-/bulma-tooltip-3.0.2.tgz#2cf0abab1de2eba07f9d84eb7f07a8a88819ea92" resolved "https://registry.yarnpkg.com/bulma-tooltip/-/bulma-tooltip-3.0.2.tgz#2cf0abab1de2eba07f9d84eb7f07a8a88819ea92"
integrity sha512-CsT3APjhlZScskFg38n8HYL8oYNUHQtcu4sz6ERarxkUpBRbk9v0h/5KAvXeKapVSn2dp9l7bOGit5SECP8EWQ== integrity sha512-CsT3APjhlZScskFg38n8HYL8oYNUHQtcu4sz6ERarxkUpBRbk9v0h/5KAvXeKapVSn2dp9l7bOGit5SECP8EWQ==
bulma@^0.7.5: bulma@^0.8.0:
version "0.7.5" version "0.8.0"
resolved "https://registry.yarnpkg.com/bulma/-/bulma-0.7.5.tgz#35066c37f82c088b68f94450be758fc00a967208" resolved "https://registry.yarnpkg.com/bulma/-/bulma-0.8.0.tgz#ac1606431703a4761b18a4a2d5cc1fa864a2aece"
integrity sha512-cX98TIn0I6sKba/DhW0FBjtaDpxTelU166pf7ICXpCCuplHWyu6C9LYZmL5PEsnePIeJaiorsTEzzNk3Tsm1hw== integrity sha512-nhf3rGyiZh/VM7FrSJ/5KeLlfaFkXz0nYcXriynfPH4vVpnxnqyEwaNGdNCVzHyyCA3cHgkQAMpdF/SFbFGZfA==
byline@^5.0.0: byline@^5.0.0:
version "5.0.0" version "5.0.0"