import type { Mastodon } from "megalodon"; import type { Status } from "~/types/mastodon/status"; export const useAccountTimeline = ( client: Mastodon | null, id: MaybeRef, options: MaybeRef<{ limit?: number | undefined; max_id?: string | undefined; since_id?: string | undefined; min_id?: string | undefined; pinned?: boolean | undefined; exclude_replies?: boolean | undefined; exclude_reblogs?: boolean | undefined; only_media?: boolean; }>, ): { timeline: Ref; loadNext: () => Promise; loadPrev: () => Promise; } => { return useIdTimeline( client, id, (client, options) => client?.getAccountStatuses(ref(id).value ?? "", { only_media: false, ...options, }), options, ); };