mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-10 15:35:49 +01:00
Merged in bugfix/repos_in_overview_clickable (pull request #141)
Bugfix/repos in overview clickable
This commit is contained in:
@@ -9,7 +9,12 @@ import classNames from "classnames";
|
||||
import RepositoryAvatar from "./RepositoryAvatar";
|
||||
|
||||
const styles = {
|
||||
overlay: {
|
||||
overlayFullColumn: {
|
||||
position: "absolute",
|
||||
height: "calc(120px - 0.5rem)",
|
||||
width: "calc(100% - 1.5rem)"
|
||||
},
|
||||
overlayHalfColumn: {
|
||||
position: "absolute",
|
||||
height: "calc(120px - 1.5rem)",
|
||||
width: "calc(50% - 3rem)"
|
||||
@@ -80,6 +85,9 @@ class RepositoryEntry extends React.Component<Props> {
|
||||
const { repository, classes, fullColumnWidth } = this.props;
|
||||
const repositoryLink = this.createLink(repository);
|
||||
const halfColumn = fullColumnWidth ? "is-full" : "is-half";
|
||||
const overlayLinkClass = fullColumnWidth
|
||||
? classes.overlayFullColumn
|
||||
: classes.overlayHalfColumn;
|
||||
return (
|
||||
<div
|
||||
className={classNames(
|
||||
@@ -90,12 +98,12 @@ class RepositoryEntry extends React.Component<Props> {
|
||||
halfColumn
|
||||
)}
|
||||
>
|
||||
<Link className={classNames(classes.overlay)} to={repositoryLink} />
|
||||
<Link className={classNames(overlayLinkClass)} to={repositoryLink} />
|
||||
<article className={classNames("media", classes.inner)}>
|
||||
<figure className={classNames(classes.centerImage, "media-left")}>
|
||||
<RepositoryAvatar repository={repository} />
|
||||
</figure>
|
||||
<div className="media-content">
|
||||
<div className={classNames("media-content", "text-box")}>
|
||||
<div className="content">
|
||||
<p className="is-marginless">
|
||||
<strong>{repository.name}</strong>
|
||||
|
||||
@@ -112,15 +112,13 @@ $fa-font-path: "webfonts";
|
||||
}
|
||||
}
|
||||
|
||||
.media {
|
||||
.media-content {
|
||||
.text-box {
|
||||
width: calc(50% - 0.75rem);
|
||||
.shorten-text {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// tables
|
||||
|
||||
Reference in New Issue
Block a user