-
,
- title: "No Git Project issues found",
- description:
- "Sync a repository to pull issues into Pipeline, or adjust your filters.",
- }}
- />
+
+
+
+
+ {issueCounts.open} Open
+
+
+
+ {issueCounts.closed} Closed
+
+
+
+ {issues.length} visible issue{issues.length === 1 ? "" : "s"}
+
+
+
+ {isLoading ? (
+
+ ) : issues.length === 0 ? (
+
+
+
+
+
+ No Git Project issues found
+
+
+ Sync a repository to pull issues into Pipeline, or adjust your
+ filters.
+
+
+ ) : (
+
+ {issues.map((issue) => {
+ const repositoryName =
+ repositoryNameById.get(issue.repository_id) ??
+ issue.repository_id;
+ const visibleLabels = issue.labels.slice(0, 4);
+ const hiddenLabelCount =
+ issue.labels.length - visibleLabels.length;
+ const updatedAt =
+ issue.state === "closed"
+ ? issue.forgejo_closed_at || issue.forgejo_updated_at
+ : issue.forgejo_updated_at;
+ const stateVerb = issue.state === "closed" ? "closed" : "updated";
+ const canShowClose =
+ canClose && issue.state === "open" && !issue.is_pull_request;
+
+ return (
+
+
+
+
+
+
+ {issue.title}
+
+ {visibleLabels.map((label, i) => (
+
+ ))}
+ {hiddenLabelCount > 0 ? (
+
+ +{hiddenLabelCount}
+
+ ) : null}
+
+
+
+
+ {repositoryName}
+
+
+ #{issue.forgejo_issue_number}
+
+
+ {stateVerb} {formatRelativeTime(updatedAt)}
+
+ {issue.author ? by {issue.author} : null}
+ {issue.milestone?.title ? (
+
+
+
+ {issue.milestone.title}
+
+
+ ) : null}
+
+
+
+
+
+
+
+
+
+ {canShowClose ? (
+
+ ) : null}
+
+
+
+ );
+ })}
+
+ )}