childComponents)) { $this->childComponents = array_map( fn (Component $component): Component => $component->getClone(), $this->childComponents, ); } return $this; } public function getClone(): static { $clone = clone $this; $clone->cloneChildComponents(); return $clone; } }