mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-03 01:28:55 +00:00
feat: quality of life sweep from the feature discussions
Small requests from the discussions, each built end to end: planner and map (cycling mode, date first headings, clear a day, stay times per day, off-route stops, map lock, compact unplanned markers, pending stays, cable car, transit quick picks), places (location filter, category from OSM, open in maps, geo: link, image from an attachment, enrichment on file import, places near a pin, place name language, Amap first in China), lists and costs (packed counter, inherited sharing, Markdown to-dos, payment notes, bookings CSV, my plan PDF), sharing (unplanned places, travel only, without photos), journey (photo zoom, drafts, photo order, trip suggestion, day jump), atlas (region counter, region bucket list, places per country), vacay half company holidays, studio copy and paste plus the book's own layouts, and RESTORE_FROM_BACKUP for a first start restore.
This commit is contained in:
@@ -188,6 +188,13 @@ export const placeSchema = z.object({
|
||||
ratings: z.array(placeRatingVoteSchema).optional(),
|
||||
rating_avg: z.number().nullable().optional(),
|
||||
rating_count: z.number().optional(),
|
||||
/**
|
||||
* Where the place lies, as resolved from its position (place_regions): an ISO country
|
||||
* code and the state or province. Read-only and only on the trip's place list, for
|
||||
* filtering it (#2537); null until the position has been resolved.
|
||||
*/
|
||||
country_code: z.string().nullable().optional(),
|
||||
region_name: z.string().nullable().optional(),
|
||||
});
|
||||
export type Place = z.infer<typeof placeSchema>;
|
||||
|
||||
@@ -298,6 +305,8 @@ export const placeImportGpxRequestSchema = z.object({
|
||||
importWaypoints: z.string().optional(),
|
||||
importRoutes: z.string().optional(),
|
||||
importTracks: z.string().optional(),
|
||||
// Fill in the imported points from Google Places afterwards, as a list import can (#2536).
|
||||
enrich: z.string().optional(),
|
||||
});
|
||||
export type PlaceImportGpxRequest = z.infer<typeof placeImportGpxRequestSchema>;
|
||||
|
||||
@@ -317,6 +326,7 @@ export type PlaceExportGpxRequest = z.infer<typeof placeExportGpxRequestSchema>;
|
||||
export const placeImportMapRequestSchema = z.object({
|
||||
importPoints: z.string().optional(),
|
||||
importPaths: z.string().optional(),
|
||||
enrich: z.string().optional(),
|
||||
});
|
||||
export type PlaceImportMapRequest = z.infer<typeof placeImportMapRequestSchema>;
|
||||
|
||||
@@ -327,3 +337,9 @@ export const placeListQuerySchema = z.object({
|
||||
tag: z.string().optional(),
|
||||
});
|
||||
export type PlaceListQuery = z.infer<typeof placeListQuerySchema>;
|
||||
|
||||
/** Use a file already attached in the trip as the place's own picture (#1242). */
|
||||
export const placeImageFromFileRequestSchema = z.object({
|
||||
file_id: z.number().int().positive(),
|
||||
});
|
||||
export type PlaceImageFromFileRequest = z.infer<typeof placeImageFromFileRequestSchema>;
|
||||
|
||||
Reference in New Issue
Block a user