import { TempstreamJSX } from "tempstream";
import type { ComponentToHTMLArgs } from "@sealcode/jdd";
import { Component, ComponentArguments } from "@sealcode/jdd";

const component_arguments = {
	size: new ComponentArguments.Number(),
} as const;

export class EmptySpace extends Component<typeof component_arguments> {
	getArguments() {
		return component_arguments;
	}

	async toHTML({
		args: { size },
		classes,
	}: ComponentToHTMLArgs<typeof component_arguments>): Promise<string> {
		return (
			<div class={["empty-space", ...classes]} style={`height: ${size}px`}></div>
		);
	}
}
