public function collapse(): ArrayCollection
    {
        $items = [];

        foreach ($this->items as $values) {
            if ($values instanceof self) {
                $values = $values->all();
            } elseif (!is_array($values)) {
                continue;
            }
            $items = array_merge($items, $values);
        }

        return new static($items);
    }