2024-02-09 08:33:27 +00:00
|
|
|
export interface Settings {
|
2024-03-28 08:12:43 +00:00
|
|
|
notification: boolean;
|
|
|
|
enhancedPrivacy: boolean;
|
|
|
|
autoUpdate: boolean;
|
2024-04-10 07:11:05 +00:00
|
|
|
zap: boolean;
|
2024-04-16 00:49:44 +00:00
|
|
|
nsfw: boolean;
|
|
|
|
[key: string]: string | number | boolean;
|
2024-02-09 08:33:27 +00:00
|
|
|
}
|
2024-02-06 12:28:46 +00:00
|
|
|
|
|
|
|
export interface Keys {
|
|
|
|
npub: string;
|
|
|
|
nsec: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export enum Kind {
|
|
|
|
Metadata = 0,
|
|
|
|
Text = 1,
|
|
|
|
RecommendRelay = 2,
|
|
|
|
Contacts = 3,
|
|
|
|
Repost = 6,
|
|
|
|
Reaction = 7,
|
|
|
|
// NIP-89: App Metadata
|
|
|
|
AppRecommendation = 31989,
|
|
|
|
AppHandler = 31990,
|
|
|
|
// #TODO: Add all nostr kinds
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface Event {
|
|
|
|
id: string;
|
|
|
|
pubkey: string;
|
|
|
|
created_at: number;
|
|
|
|
kind: Kind;
|
|
|
|
tags: string[][];
|
|
|
|
content: string;
|
|
|
|
sig: string;
|
2024-02-26 08:10:42 +00:00
|
|
|
relay?: string;
|
2024-02-06 12:28:46 +00:00
|
|
|
}
|
|
|
|
|
2024-02-09 08:33:27 +00:00
|
|
|
export interface EventWithReplies extends Event {
|
|
|
|
replies: Array<Event>;
|
|
|
|
}
|
|
|
|
|
2024-02-06 12:28:46 +00:00
|
|
|
export interface Metadata {
|
2024-02-09 08:33:27 +00:00
|
|
|
name?: string;
|
|
|
|
display_name?: string;
|
|
|
|
about?: string;
|
|
|
|
website?: string;
|
|
|
|
picture?: string;
|
|
|
|
banner?: string;
|
|
|
|
nip05?: string;
|
|
|
|
lud06?: string;
|
|
|
|
lud16?: string;
|
2024-02-06 12:28:46 +00:00
|
|
|
}
|
|
|
|
|
2024-02-23 07:56:24 +00:00
|
|
|
export interface Contact {
|
|
|
|
pubkey: string;
|
|
|
|
profile: Metadata;
|
|
|
|
}
|
|
|
|
|
2024-02-19 02:58:27 +00:00
|
|
|
export interface Account {
|
2024-02-12 02:08:35 +00:00
|
|
|
npub: string;
|
2024-04-02 06:19:26 +00:00
|
|
|
nsec?: string;
|
2024-02-08 14:24:08 +00:00
|
|
|
contacts?: string[];
|
|
|
|
interests?: Interests;
|
2024-02-06 12:28:46 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface Interests {
|
|
|
|
hashtags: string[];
|
|
|
|
users: string[];
|
|
|
|
words: string[];
|
|
|
|
}
|
2023-12-25 07:28:39 +00:00
|
|
|
|
|
|
|
export interface RichContent {
|
|
|
|
parsed: string;
|
|
|
|
images: string[];
|
|
|
|
videos: string[];
|
|
|
|
links: string[];
|
|
|
|
notes: string[];
|
|
|
|
}
|
|
|
|
|
2024-04-10 07:11:05 +00:00
|
|
|
export interface AppRouteSearch {
|
|
|
|
account: string;
|
|
|
|
}
|
|
|
|
|
2024-04-07 08:11:20 +00:00
|
|
|
export interface ColumnRouteSearch {
|
|
|
|
account: string;
|
|
|
|
label: string;
|
|
|
|
name: string;
|
2024-04-10 07:11:05 +00:00
|
|
|
redirect?: string;
|
2024-04-07 08:11:20 +00:00
|
|
|
}
|
|
|
|
|
2024-02-09 08:33:27 +00:00
|
|
|
export interface LumeColumn {
|
2024-04-07 08:11:20 +00:00
|
|
|
label: string;
|
2024-03-16 08:05:06 +00:00
|
|
|
name: string;
|
2024-03-20 08:12:54 +00:00
|
|
|
content: URL | string;
|
2024-03-16 08:05:06 +00:00
|
|
|
description?: string;
|
|
|
|
author?: string;
|
2024-03-21 07:53:08 +00:00
|
|
|
logo?: string;
|
|
|
|
cover?: string;
|
|
|
|
coverRetina?: string;
|
|
|
|
featured?: boolean;
|
2023-12-29 06:12:37 +00:00
|
|
|
}
|
|
|
|
|
2024-03-19 08:36:20 +00:00
|
|
|
export interface EventColumns {
|
2024-04-22 07:33:14 +00:00
|
|
|
type: "add" | "remove" | "update" | "left" | "right" | "set_title";
|
2024-04-07 08:11:20 +00:00
|
|
|
label?: string;
|
2024-04-22 07:33:14 +00:00
|
|
|
title?: string;
|
2024-03-19 08:36:20 +00:00
|
|
|
column?: LumeColumn;
|
|
|
|
}
|
|
|
|
|
2023-12-25 07:28:39 +00:00
|
|
|
export interface Opengraph {
|
|
|
|
url: string;
|
|
|
|
title?: string;
|
|
|
|
description?: string;
|
|
|
|
image?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface NostrBuildResponse {
|
|
|
|
ok: boolean;
|
|
|
|
data?: {
|
|
|
|
message: string;
|
|
|
|
status: string;
|
|
|
|
data: Array<{
|
|
|
|
blurhash: string;
|
|
|
|
dimensions: {
|
|
|
|
width: number;
|
|
|
|
height: number;
|
|
|
|
};
|
|
|
|
mime: string;
|
|
|
|
name: string;
|
|
|
|
sha256: string;
|
|
|
|
size: number;
|
|
|
|
url: string;
|
|
|
|
}>;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface NIP11 {
|
|
|
|
name: string;
|
|
|
|
description: string;
|
|
|
|
pubkey: string;
|
|
|
|
contact: string;
|
|
|
|
supported_nips: number[];
|
|
|
|
software: string;
|
|
|
|
version: string;
|
|
|
|
limitation: {
|
|
|
|
[key: string]: string | number | boolean;
|
|
|
|
};
|
|
|
|
relay_countries: string[];
|
|
|
|
language_tags: string[];
|
|
|
|
tags: string[];
|
|
|
|
posting_policy: string;
|
|
|
|
payments_url: string;
|
|
|
|
icon: string[];
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface NIP05 {
|
|
|
|
names: {
|
|
|
|
[key: string]: string;
|
|
|
|
};
|
2024-01-10 02:22:13 +00:00
|
|
|
nip46: {
|
|
|
|
[key: string]: {
|
|
|
|
[key: string]: string[];
|
|
|
|
};
|
|
|
|
};
|
2023-12-25 07:28:39 +00:00
|
|
|
}
|