docs: describe project structure
This commit is contained in:
9
src/domain/photo.ts
Normal file
9
src/domain/photo.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
export interface Photo {
|
||||
id: string;
|
||||
fileName: string;
|
||||
capturedAt: string | null;
|
||||
latitude: number | null;
|
||||
longitude: number | null;
|
||||
thumbnailUrl: string | null;
|
||||
}
|
||||
|
||||
7
src/domain/route.ts
Normal file
7
src/domain/route.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
export interface RoutePoint {
|
||||
photoId: string;
|
||||
capturedAt: string;
|
||||
latitude: number;
|
||||
longitude: number;
|
||||
}
|
||||
|
||||
6
src/features/map/map-service.ts
Normal file
6
src/features/map/map-service.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import type { RoutePoint } from "../../domain/route.js";
|
||||
|
||||
export function buildRoute(points: RoutePoint[]): RoutePoint[] {
|
||||
return points.slice().sort((a, b) => a.capturedAt.localeCompare(b.capturedAt));
|
||||
}
|
||||
|
||||
6
src/features/photos/photo-service.ts
Normal file
6
src/features/photos/photo-service.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import type { Photo } from "../../domain/photo.js";
|
||||
|
||||
export function listPhotos(): Photo[] {
|
||||
return [];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user