Source code for pyfsr.models._app_config

"""Typed models for the application navigation document (``/api/views/1/app``).

The navigation bar is a single document whose ``config.navigation`` array is a
(nested) tree of :class:`NavItem`. Top-level entries are either leaves (binding
a module via :attr:`NavItem.state` / :attr:`NavItem.require`) or *groups* that
carry their children under :attr:`NavItem.items`.

These models subclass :class:`~pyfsr.models._integration.ApiResult`, so they
stay dict-compatible (``item["title"]`` keeps working) and preserve any unknown
keys (``extra="allow"``) for lossless round-tripping back through a PUT.

Field set captured from a live 7.6.5 appliance ``/api/views/1/app`` response
(see ``AppConfigAPI`` for the read/write methods).
"""

from __future__ import annotations

from typing import Any

from pydantic import Field

from ._integration import ApiResult














# Resolve the forward reference for the self-referential ``items`` field.
NavItem.model_rebuild()