Add protobufs repo as git submodule (#882)

* feat: add protobufs git submodule

* fixes

* fixed publishing issue

* fixed lockfile
This commit is contained in:
Dan Ditomaso
2025-10-14 08:54:55 -04:00
committed by GitHub
parent f5a7132421
commit 9ab49d1431
68 changed files with 10100 additions and 236 deletions
+36
View File
@@ -74,6 +74,41 @@ const mapRoute = createRoute({
component: MapPage,
});
const coordParamsSchema = z.object({
// Accept "strings" from the URL, coerce to number, then validate
long: z.coerce
.number()
.refine(
(n) => Number.isFinite(n) && n >= -180 && n <= 180,
"Invalid longitude (-180..180).",
),
lat: z.coerce
.number()
.refine(
(n) => Number.isFinite(n) && n >= -90 && n <= 90,
"Invalid latitude (-90..90).",
),
// Typical web map zoom levels ~0..22 (adjust if your map lib differs)
zoom: z.coerce
.number()
.int()
.min(0, "Zoom too small.")
.max(22, "Zoom too large."),
});
export const mapWithParamsRoute = createRoute({
getParentRoute: () => rootRoute,
path: "/map/$long/$lat/$zoom",
component: MapPage,
parseParams: (raw) => coordParamsSchema.parse(raw),
// // This controls how params are serialized when you navigate/link
// stringifyParams: (p) => ({
// long: String(p.long),
// lat: String(p.lat),
// zoom: String(p.zoom),
// }),
});
const configRoute = createRoute({
getParentRoute: () => rootRoute,
path: "/config",
@@ -97,6 +132,7 @@ const routeTree = rootRoute.addChildren([
messagesRoute,
messagesWithParamsRoute,
mapRoute,
mapWithParamsRoute,
configRoute,
nodesRoute,
dialogWithParamsRoute,