Fix TypeScript errors from recent changes
This commit is contained in:
parent
11f56bfd1c
commit
354c07f2bf
3 changed files with 11 additions and 5 deletions
|
|
@ -1,3 +1,5 @@
|
|||
import { Address } from "./types";
|
||||
|
||||
export function shortAddress(a: Address): string {
|
||||
if (!a) return "";
|
||||
return `${a.number} ${a.street}, ${a.locality}`;
|
||||
|
|
|
|||
|
|
@ -5,11 +5,13 @@ import { SSEManager } from "../SSEManager";
|
|||
// Define interfaces matching your Go structs
|
||||
interface URLsAPI {
|
||||
communication: string;
|
||||
signal: string;
|
||||
}
|
||||
|
||||
interface URLs {
|
||||
api: URLsAPI;
|
||||
tegola: string;
|
||||
tile: string;
|
||||
}
|
||||
|
||||
interface User {
|
||||
|
|
|
|||
12
ts/types.ts
12
ts/types.ts
|
|
@ -4,14 +4,16 @@ export interface Address {
|
|||
street: string;
|
||||
}
|
||||
|
||||
export interface PublicReport {
|
||||
created: string;
|
||||
type: string;
|
||||
}
|
||||
|
||||
export interface Communication {
|
||||
created: string;
|
||||
id: string;
|
||||
public_report: PublicReport | null;
|
||||
type: string;
|
||||
}
|
||||
|
||||
export interface PublicReport {
|
||||
created: string;
|
||||
type: string;
|
||||
}
|
||||
|
||||
export interface Signal {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue