<?php

namespace Planaday\Utility\FormBuilder\LayoutItems;

use Planaday\Utility\FormBuilder\LayoutItem;

class MessageDisplay implements LayoutItem {
	use BasicLayoutItem;

	protected array $classes = [];

	public function __construct() {}

	public function addClasses(string ...$classes): self {
		$this->classes = array_merge($this->classes, $classes);
		return $this;
	}

	public function getImplJson(): array {
		return [
			"type" => 'messageDisplay',
			"classes" => $this->classes
		];
	}
}