mirror of
https://github.com/hex248/sprint.git
synced 2026-02-08 18:33:01 +00:00
IssueResponse definition and implementation
This commit is contained in:
@@ -1,22 +1,22 @@
|
||||
import type { IssueRecord, ProjectRecord } from "@issue/shared";
|
||||
import type { IssueResponse, ProjectRecord } from "@issue/shared";
|
||||
import { X } from "lucide-react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { issueID } from "@/lib/utils";
|
||||
|
||||
export function IssueDetailPane({
|
||||
project,
|
||||
issue,
|
||||
issueData,
|
||||
close,
|
||||
}: {
|
||||
project: ProjectRecord;
|
||||
issue: IssueRecord;
|
||||
issueData: IssueResponse;
|
||||
close: () => void;
|
||||
}) {
|
||||
return (
|
||||
<div className="flex flex-col">
|
||||
<div className="flex flex-row items-center justify-end border-b">
|
||||
<span className="w-full px-0.5">
|
||||
<p className="text-sm w-fit px-0.75">{issueID(project.blob, issue.number)}</p>
|
||||
<p className="text-sm w-fit px-0.75">{issueID(project.blob, issueData.Issue.number)}</p>
|
||||
</span>
|
||||
|
||||
<Button variant={"dummy"} onClick={close} className="px-0 py-0 w-6 h-6">
|
||||
@@ -25,8 +25,13 @@ export function IssueDetailPane({
|
||||
</div>
|
||||
|
||||
<div className="flex flex-col w-full p-2 gap-2">
|
||||
<h1 className="text-md">{issue.title}</h1>
|
||||
<p className="text-sm">{issue.description}</p>
|
||||
<h1 className="text-md">{issueData.Issue.title}</h1>
|
||||
<p className="text-sm">{issueData.Issue.description}</p>
|
||||
|
||||
<p className="text-sm">
|
||||
Assignee:{" "}
|
||||
{issueData.User ? `${issueData.User.name} (${issueData.User.username})` : "Unassigned"}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user