Use number as type instead of bigint

This commit is contained in:
Sebastian Martinez
2024-10-10 11:23:36 +02:00
parent c17c659458
commit 98bd1ee6b5
4 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -3,7 +3,7 @@ import type { Author } from "./Author";
export type Edit = {
author: Author;
timestamp: bigint;
timestamp: number;
body: string;
embeds: { name: string; content: string };
};
+1 -1
View File
@@ -9,5 +9,5 @@ export type Review = {
verdict?: "accept" | "reject";
summary: string | null;
comments: Array<Comment<CodeLocation>>;
timestamp: bigint;
timestamp: number;
};
+1 -1
View File
@@ -13,7 +13,7 @@ export type Revision = {
base: string;
head: string;
reviews: Array<Review>;
timestamp: bigint;
timestamp: number;
discussion: Array<Comment<CodeLocation>>;
reactions: Array<Reaction>;
};
+3 -3
View File
@@ -154,7 +154,7 @@ pub struct Revision {
#[ts(as = "String")]
head: git::Oid,
reviews: Vec<Review>,
#[ts(as = "i64")]
#[ts(type = "number")]
timestamp: cob::common::Timestamp,
discussion: Vec<thread::Comment<thread::CodeLocation>>,
reactions: Vec<Reaction>,
@@ -253,7 +253,7 @@ pub struct Review {
verdict: Option<cob::patch::Verdict>,
summary: Option<String>,
comments: Vec<thread::Comment<thread::CodeLocation>>,
#[ts(as = "i64")]
#[ts(type = "number")]
timestamp: cob::common::Timestamp,
}
@@ -283,7 +283,7 @@ impl Review {
#[serde(rename_all = "camelCase")]
pub struct Edit {
pub author: Author,
#[ts(as = "i64")]
#[ts(type = "number")]
pub timestamp: cob::common::Timestamp,
pub body: String,
#[ts(type = "{ name: string, content: string }")]