255, // @todo Should be unique for each message 'text' => 150, ]; /** * @param string $text * @throws SlackSyntaxException */ public function __construct(string $text) { parent::__construct(); // Defaults $this->type = 'header'; $this->text = Text::item($this->validate('text',$text),'plain_text'); } public static function item(string $text): self { return new self($text); } /* OPTIONAL ITEMS */ public function block_id(string $string): self { $this->block_id = $this->validate('block_id',$string); return $this; } }