title = $title; } public function setTitle(string $title): self { $this->title = $title; return $this; } public function getTitle():string { return $this->title; } public function setCrumb(string|array $crumb):self { $this->addCrumb = $crumb; return $this; } public function getCrumb():string|array { return $this->addCrumb; } function getConfig(): array { $config = [ 'title' => $this->title, ]; if (!empty($this->addCrumb)) { $config['addCrumb'] = $this->addCrumb; } return $config; } }