TypeScript
refactor(web): remove unused pull request state label (#9984)
Julius Marmingeea0487cc9adf
diff --git a/apps/web/src/components/pullRequest/pullRequestDetail.logic.test.ts b/apps/web/src/components/pullRequest/pullRequestDetail.logic.test.tsindex c51429ff6d8..61c630c815e 100644--- a/apps/web/src/components/pullRequest/pullRequestDetail.logic.test.ts+++ b/apps/web/src/components/pullRequest/pullRequestDetail.logic.test.ts@@ -38,7 +38,6 @@ import {shouldRefreshPullRequestActivity,resolveBaseFreshness,buildPullRequestTimeline,- describePullRequestState,editPullRequestThreadComment,writePullRequestDetailSnapshot,} from "./pullRequestDetail.logic";@@ -199,15 +198,6 @@ describe("pull request primary control", () => {});});-describe("pull request state description", () => {- it("keeps draft and conflicts orthogonal to the terminal states", () => {- expect(describePullRequestState("open", true)).toBe("Draft");- expect(describePullRequestState("open", false)).toBe("Ready for review");- expect(describePullRequestState("merged", true)).toBe("Merged");- expect(describePullRequestState("closed", false)).toBe("Closed");- });-});-describe("pull request handoff labels", () => {it("names the open thread when actions write to its composer", () => {expect(pullRequestHandoffLabels(true)).toEqual({diff --git a/apps/web/src/components/pullRequest/pullRequestDetail.logic.ts b/apps/web/src/components/pullRequest/pullRequestDetail.logic.tsindex cffe33f8d83..d00215f02d4 100644--- a/apps/web/src/components/pullRequest/pullRequestDetail.logic.ts+++ b/apps/web/src/components/pullRequest/pullRequestDetail.logic.ts@@ -189,13 +189,6 @@ export function isStackedPullRequestBase(return defaultBranch !== baseBranch;}-/** Plain-language state, shown beside the author. Conflicts are a merge signal, not a state. */-export function describePullRequestState(state: PullRequestState, isDraft: boolean): string {- if (state === "merged") return "Merged";- if (state === "closed") return "Closed";- return isDraft ? "Draft" : "Ready for review";-}-/** Chronological ascending, oldest to newest — reversed for the "newest" reading order. */export function orderPullRequestComments<T extends { readonly createdAt: string }>(comments: ReadonlyArray<T>,