types.ts (1434B) - raw
1 export interface Config { 2 readonly operaDownloadButton: boolean 3 readonly bypassCameraRollLimit: boolean 4 readonly showFirstCreatedUsername: boolean 5 readonly composerLogs: boolean 6 } 7 8 export interface FriendInfo { 9 readonly id: number 10 readonly lastModifiedTimestamp: number 11 readonly username: string 12 readonly userId: string 13 readonly displayName: string 14 readonly bitmojiAvatarId: string 15 readonly bitmojiSelfieId: string 16 readonly bitmojiSceneId: string 17 readonly bitmojiBackgroundId: string 18 readonly friendmojis: string 19 readonly friendmojiCategories: string 20 readonly snapScore: number 21 readonly birthday: number 22 readonly addedTimestamp: number 23 readonly reverseAddedTimestamp: number 24 readonly serverDisplayName: string 25 readonly streakLength: number 26 readonly streakExpirationTimestamp: number 27 readonly reverseBestFriendRanking: number 28 readonly isPinnedBestFriend: number 29 readonly plusBadgeVisibility: number 30 readonly usernameForSorting: string 31 readonly friendLinkType: number 32 readonly postViewEmoji: string 33 readonly businessCategory: number 34 } 35 36 export interface Module { 37 readonly name: string 38 enabled: (config: Config) => boolean 39 init: () => void 40 } 41 42 export const modules: Module[] = [] 43 44 export function defineModule<T extends Module>(module: T & Record<string, any>): T { 45 modules.push(module) 46 return module 47 }