feat(github): support PR URLs in task creation dialog (#379)

This commit is contained in:
Carlos Florêncio
2026-03-05 23:17:10 +00:00
committed by GitHub
parent d56f13273a
commit 84173d3820
11 changed files with 368 additions and 12 deletions
+14
View File
@@ -3,6 +3,7 @@ import type {
GitHubStatusResponse,
GitHubOrg,
GitHubRepoInfo,
GitHubPR,
TaskPRsResponse,
TaskPR,
PRFeedback,
@@ -141,6 +142,19 @@ export async function searchOrgRepos(org: string, query?: string, options?: ApiR
);
}
// PR info (lightweight)
export async function fetchPRInfo(
owner: string,
repo: string,
number: number,
options?: ApiRequestOptions,
) {
return fetchJson<GitHubPR>(
`/api/v1/github/prs/${encodeURIComponent(owner)}/${encodeURIComponent(repo)}/${number}/info`,
options,
);
}
// Remote repo branches
export async function fetchRepoBranches(owner: string, repo: string, options?: ApiRequestOptions) {
return fetchJson<{ branches: { name: string }[] }>(