<?php

namespace Planaday\Utility\FormBuilder\SubmitStrategies;

use Planaday\Utility\FormBuilder\SubmitStrategy;

class PostSubmit implements SubmitStrategy{
	protected string $url = '';

	public function setUrl(string $url): self {
		$this->url = $url;
		return $this;
	}

	public function jsonSerialize(): array {
		return [
			"type" => "post",
			"url" => $this->url
		];
	}
}