Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🏷️ SuggestionState #11

Merged
merged 1 commit into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/server/webhooks/events/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ export * from "./event.js"
export * as pr from "./pr/index.js"
export * as project from "./project/index.js"
export * as repo from "./repo/index.js"
export * from "./suggestion_state.js"
NatoBoram marked this conversation as resolved.
Show resolved Hide resolved
3 changes: 2 additions & 1 deletion src/server/webhooks/events/pr/comment_added.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import type {
SchemaRepository,
SchemaRestMinimalRef,
} from "../../../openapi/openapi-typescript.js"
import type { SuggestionState } from "../suggestion_state.js"

export interface Actor {
readonly active: boolean
Expand Down Expand Up @@ -75,7 +76,7 @@ export interface Project {

export interface Properties {
readonly repositoryId: number
readonly suggestionState: string
readonly suggestionState?: SuggestionState
}

export interface PullRequest {
Expand Down
6 changes: 6 additions & 0 deletions src/server/webhooks/events/suggestion_state.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export const suggestionState = {
UNAPPLIED: "UNAPPLIED",
} as const

export type SuggestionState =
(typeof suggestionState)[keyof typeof suggestionState]