import { Store } from "vuex" ; import { DollarApollo } from "@vue/apollo-option/types/vue-apollo" ; import { AddToListMutation , EditListEntryMutation , EditListEntryOptions , ListEntry , MediaListStatus , QueryListEntriesArgs , StartRewatchingMutation , UpdateProgressMutation , UpdateScoreMutation , UpdateStatusMutation , } from "@/graphql/generated/types" ; export enum ListPluginType { Full = "FULL" , Simple = "SIMPLE" } export type ListEntryWithoutMedia = Omit < ListEntry , "media" > ; export abstract class ListPlugin { public abstract service : string ; public abstract type : ListPluginType ; protected readonly apollo : DollarApollo < any > ; protected readonly store : Store < any > ; public constructor ( apollo , store ) { this . apollo = apollo ; this . store = store ; } public abstract isAvailable ( ) ; public abstract GetListEntry ( anilistId ) ; public abstract GetListEntries ( options ) ; public abstract AddToList ( anilistId ) ; public abstract DeleteFromList ( anilistId ) ; public abstract UpdateStatus ( anilistId , status ) ; public abstract StartRewatching ( anilistId ) ; public abstract UpdateProgress ( anilistId , progress ) ; public abstract UpdateScore ( anilistId , score ) ; public abstract EditListEntry ( anilistId , options ) ; }