mirror of
https://github.com/tiramisulabs/seyfert.git
synced 2025-07-02 13:06:08 +00:00
14 lines
384 B
TypeScript
14 lines
384 B
TypeScript
import type { APIBaseComponent, ComponentType } from 'discord-api-types/v10';
|
|
|
|
export abstract class BaseComponentBuilder<
|
|
TYPE extends Partial<APIBaseComponent<ComponentType>> = APIBaseComponent<ComponentType>,
|
|
> {
|
|
constructor(public data: Partial<TYPE>) {}
|
|
|
|
toJSON(): TYPE {
|
|
return { ...this.data } as TYPE;
|
|
}
|
|
}
|
|
|
|
export type OptionValuesLength = { max: number; min: number };
|