diff --git a/src/interface/actions.ts b/src/interface/actions.ts index 2fdad9c..d072fd7 100644 --- a/src/interface/actions.ts +++ b/src/interface/actions.ts @@ -99,7 +99,7 @@ export class ActionFetchOptions { /** * Represents the response of a fetch action request. */ -export interface ActionFetchResponse { +export class ActionFetchResponse { /** * An array of `Action` objects. @@ -111,6 +111,17 @@ export interface ActionFetchResponse { * Returns a promise that resolves to an `ActionFetchResponse` object. */ readonly fetchNextPage?: () => Promise; + + /** + * Creates an instance of the Actions class. + * @constructor + * @param actions The list of actions. + * @param fetchNextPage A function that fetches the next page of actions. + */ + constructor(actions: Action[], fetchNextPage?: () => Promise) { + this.actions = actions; + this.fetchNextPage = fetchNextPage; + } } /**