Skip to content
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 .bun-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.3.14
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@
"semver": "catalog:",
"sort-package-json": "^3.6.1"
},
"packageManager": "bun@1.3.10",
"packageManager": "bun@1.3.14",
"engines": {
"bun": ">=1.3.10",
"bun": ">=1.3.14",
"node": ">=24.0.0"
},
"catalog": {
Expand Down
4 changes: 2 additions & 2 deletions packages/api/src/routes/packTemplates/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -669,8 +669,8 @@ export const packTemplatesRoutes = new Elysia({ prefix: '/pack-templates' })
weightUnit: data.weightUnit,
quantity: data.quantity || 1,
category: data.category,
consumable: data.consumable,
worn: data.worn,
consumable: data.consumable ?? false,
worn: data.worn ?? false,
image: data.image,
notes: data.notes,
userId: user.userId,
Expand Down
2 changes: 1 addition & 1 deletion packages/api/src/routes/packs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export const packsRoutes = new Elysia({ prefix: '/packs' })
name: data.name,
description: data.description,
category: data.category,
isPublic: data.isPublic,
isPublic: data.isPublic ?? false,
image: data.image,
tags: data.tags,
localCreatedAt: new Date(data.localCreatedAt as string),
Expand Down
2 changes: 1 addition & 1 deletion packages/schemas/src/imageDetection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export const DetectedItemWithMatchesSchema = z.object({

export const AnalyzeImageRequestSchema = z.object({
image: z.string(),
matchLimit: z.number().int().min(1).max(10).optional().default(3),
matchLimit: z.number().int().min(1).max(10).optional(),
});

export const AnalyzeImageResponseSchema = z.array(DetectedItemWithMatchesSchema);
8 changes: 4 additions & 4 deletions packages/schemas/src/packTemplates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ export const CreatePackTemplateItemRequestSchema = z.object({
description: z.string().optional(),
weight: z.number().min(0),
weightUnit: z.enum(['g', 'kg', 'lb', 'oz']),
quantity: z.number().int().min(1).optional().default(1),
quantity: z.number().int().min(1).optional(),
category: z.string().optional(),
consumable: z.boolean().optional().default(false),
worn: z.boolean().optional().default(false),
consumable: z.boolean().optional(),
worn: z.boolean().optional(),
image: z.string().nullish(),
notes: z.string().optional(),
});
Expand All @@ -102,7 +102,7 @@ export const UpdatePackTemplateItemRequestSchema = z.object({

export const GenerateFromOnlineContentRequestSchema = z.object({
contentUrl: z.string().url(),
isAppTemplate: z.boolean().optional().default(true),
isAppTemplate: z.boolean().optional(),
});

export const GenerateFromOnlineContentResponseSchema = PackTemplateWithItemsSchema;
Expand Down
6 changes: 3 additions & 3 deletions packages/schemas/src/packs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export const CreatePackRequestSchema = z.object({
name: z.string().min(1).max(255),
description: z.string().optional(),
category: z.string().optional(),
isPublic: z.boolean().optional().default(false),
isPublic: z.boolean().optional(),
image: z.string().nullish(),
tags: z.array(z.string()).optional(),
});
Expand All @@ -83,8 +83,8 @@ export const CreatePackItemRequestSchema = z.object({
weightUnit: z.enum(WEIGHT_UNITS).default('g'),
quantity: z.number().int().min(1).default(1),
category: z.string().optional(),
consumable: z.boolean().optional().default(false),
worn: z.boolean().optional().default(false),
consumable: z.boolean().optional(),
worn: z.boolean().optional(),
image: z.string().nullish(),
notes: z.string().nullish(),
catalogItemId: z.number().int().nullish(),
Expand Down
6 changes: 3 additions & 3 deletions packages/schemas/src/trailConditions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ export const CreateTrailConditionReportRequestSchema = z.object({
trailRegion: z.string().optional().nullable(),
surface: TrailSurfaceSchema,
overallCondition: OverallConditionSchema,
hazards: z.array(z.string()).optional().default([]),
waterCrossings: z.number().int().min(0).max(20).optional().default(0),
hazards: z.array(z.string()).optional(),
waterCrossings: z.number().int().min(0).max(20).optional(),
waterCrossingDifficulty: WaterCrossingDifficultySchema.optional().nullable(),
notes: z.string().optional().nullable(),
photos: z.array(z.string()).optional().default([]),
photos: z.array(z.string()).optional(),
tripId: z.string().optional().nullable(),
localCreatedAt: z.string().datetime(),
localUpdatedAt: z.string().datetime(),
Expand Down
Loading