New extension points for repository overview (#1828)

The landing-page-plugin is being reworked and integrated into the repository overview. This requires new extension points and slightly adjusted components to better match the repository overview page visually. Also, binder options can now be passed as an object which offer a new priority option that causes sorting in descending order.
This commit is contained in:
Konstantin Schaper
2021-10-19 09:31:40 +02:00
committed by GitHub
parent 35f4cb3e61
commit 57aacba03a
15 changed files with 347 additions and 78 deletions

View File

@@ -37,18 +37,15 @@ type Props = {
const StyledLink = styled(Link)`
color: inherit;
:hover {
color: #33b2e8 !important;
}
`;
const CardColumnSmall: FC<Props> = ({ link, avatar, contentLeft, contentRight, footer }) => {
const renderAvatar = avatar ? <figure className={classNames("media-left", "mr-2")}>{avatar}</figure> : null;
const renderAvatar = avatar ? <figure className="media-left mr-2 mt-1">{avatar}</figure> : null;
const renderFooter = footer ? <small>{footer}</small> : null;
return (
<StyledLink to={link}>
<div className="media">
<div className="p-2 media has-hover-background-blue">
{renderAvatar}
<div
className={classNames(
@@ -60,9 +57,9 @@ const CardColumnSmall: FC<Props> = ({ link, avatar, contentLeft, contentRight, f
"is-align-self-stretch"
)}
>
<div className={classNames("is-flex", "is-align-items-center")}>
<div className={classNames("is-clipped", "mb-0")}>{contentLeft}</div>
<div className={classNames("is-align-items-start", "ml-auto")}>{contentRight}</div>
<div className="is-flex is-flex-direction-column is-flex-align-items-start">
<div className="is-clipped">{contentLeft}</div>
<div>{contentRight}</div>
</div>
{renderFooter}
</div>