public static function fromSerialized(string $definition, string $tabId): self
    {
        $navigation = new Navigation();
        $current    = $navigation;
        $definition = StringUtil::deserialize($definition, true);
        $cssIds     = [];

        foreach ($definition as $index => $tab) {
            if (!$tab['cssId']) {
                $tab['cssId']  = StringUtil::standardize($tab['title']);
                $tab['cssId'] .= '-' . $tabId;

                if (in_array($tab['cssId'], $cssIds)) {
                    $tab['cssId'] .= '-' . $index;
                }
            }

            if ($tab['type'] === 'dropdown') {
                $item    = Dropdown::fromArray($tab);
                $current = $item;

                $navigation->addItem($item);
            } else {
                if ($tab['type'] !== 'child') {
                    $current = $navigation;
                }

                $item = NavItem::fromArray($tab);
                $current->addItem($item);
            }
        }

        return $navigation;
    }