Add MastodonAttachment type

This commit is contained in:
Alex Gleason
2024-08-07 21:19:04 -05:00
parent efc121a4ae
commit 313c37564c
4 changed files with 25 additions and 12 deletions

View File

@@ -0,0 +1,15 @@
export interface MastodonAttachment {
id: string;
type: string;
url: string;
preview_url?: string;
remote_url?: string | null;
description?: string;
blurhash?: string | null;
meta?: {
original?: {
width?: number;
height?: number;
};
};
}

View File

@@ -1,4 +1,5 @@
import { MastodonAccount } from '@/entities/MastodonAccount.ts';
import { MastodonAttachment } from '@/entities/MastodonAttachment.ts';
import { PreviewCard } from '@/entities/PreviewCard.ts';
export interface MastodonStatus {
@@ -24,16 +25,7 @@ export interface MastodonStatus {
pinned: boolean;
reblog: MastodonStatus | null;
application: unknown;
media_attachments: {
type: string;
preview_url?: string;
meta?: {
original?: {
width?: number;
height?: number;
};
};
}[];
media_attachments: MastodonAttachment[];
mentions: unknown[];
tags: unknown[];
emojis: unknown[];