Skip to content
Closed
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
2 changes: 1 addition & 1 deletion apps/desktop/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
"retext-stringify": "^4.0.0",
"stopword": "^3.1.5",
"streamdown": "^1.6.10",
"tinybase": "^6.7.5",
"tinybase": "^7.3.0",
"tinytick": "^1.2.8",
"unified": "^11.0.5",
"usehooks-ts": "^3.1.1",
Expand Down
2 changes: 1 addition & 1 deletion packages/store/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"types": "./src/index.ts",
"dependencies": {
"@hypr/db": "workspace:*",
"tinybase": "^6.7.5",
"tinybase": "^7.3.0",
"zod": "^4.2.1"
},
"devDependencies": {
Expand Down
20 changes: 10 additions & 10 deletions packages/store/src/shared.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@ export const jsonObject = <T extends z.ZodTypeAny>(schema: T) => {
});
};

type InferCellSchema<T> = T extends string | undefined
? { type: "string"; default?: string }
: T extends number | undefined
? { type: "number"; default?: number }
: T extends boolean | undefined
? { type: "boolean"; default?: boolean }
type InferCellSchema<T> = T extends string | null | undefined
? { type: "string"; default?: string; allowNull?: true }
: T extends number | null | undefined
? { type: "number"; default?: number; allowNull?: true }
: T extends boolean | null | undefined
? { type: "boolean"; default?: boolean; allowNull?: true }
: T extends string
? { type: "string"; default?: string }
? { type: "string"; default?: string; allowNull?: true }
: T extends number
? { type: "number"; default?: number }
? { type: "number"; default?: number; allowNull?: true }
: T extends boolean
? { type: "boolean"; default?: boolean }
? { type: "boolean"; default?: boolean; allowNull?: true }
: T extends object
? { type: "string" }
? { type: "string"; allowNull?: true }
: never;

export type InferTinyBaseSchema<T> = T extends { _output: infer Output }
Expand Down
Loading