2023-05-03 20:32:11 +09:00
|
|
|
import type { Record } from 'immutable';
|
2023-04-03 10:31:39 +09:00
|
|
|
|
2023-05-09 19:09:32 +09:00
|
|
|
type CustomEmoji = Record<{
|
|
|
|
shortcode: string;
|
|
|
|
static_url: string;
|
|
|
|
url: string;
|
|
|
|
}>;
|
|
|
|
|
|
|
|
type AccountField = Record<{
|
|
|
|
name: string;
|
|
|
|
value: string;
|
|
|
|
verified_at: string | null;
|
|
|
|
}>;
|
|
|
|
|
|
|
|
type AccountApiResponseValues = {
|
|
|
|
acct: string;
|
2023-04-03 10:31:39 +09:00
|
|
|
avatar: string;
|
|
|
|
avatar_static: string;
|
2023-05-09 19:09:32 +09:00
|
|
|
bot: boolean;
|
|
|
|
created_at: string;
|
|
|
|
discoverable: boolean;
|
|
|
|
display_name: string;
|
|
|
|
emojis: CustomEmoji[];
|
|
|
|
fields: AccountField[];
|
|
|
|
followers_count: number;
|
|
|
|
following_count: number;
|
|
|
|
group: boolean;
|
|
|
|
header: string;
|
|
|
|
header_static: string;
|
|
|
|
id: string;
|
|
|
|
last_status_at: string;
|
|
|
|
locked: boolean;
|
|
|
|
note: string;
|
|
|
|
statuses_count: number;
|
|
|
|
url: string;
|
|
|
|
username: string;
|
|
|
|
};
|
|
|
|
|
|
|
|
type NormalizedAccountField = Record<{
|
|
|
|
name_emojified: string;
|
|
|
|
value_emojified: string;
|
|
|
|
value_plain: string;
|
|
|
|
}>;
|
|
|
|
|
|
|
|
type NormalizedAccountValues = {
|
|
|
|
display_name_html: string;
|
|
|
|
fields: NormalizedAccountField[];
|
|
|
|
note_emojified: string;
|
|
|
|
note_plain: string;
|
2023-04-03 21:44:43 +09:00
|
|
|
};
|
2023-05-03 20:32:11 +09:00
|
|
|
|
2023-05-09 19:09:32 +09:00
|
|
|
export type Account = Record<
|
|
|
|
AccountApiResponseValues & NormalizedAccountValues
|
|
|
|
>;
|