"""Cart-domain widgets: orders link on account page."""
from __future__ import annotations

from shared.contracts.widgets import AccountNavLink
from shared.services.widget_registry import widgets
from shared.infrastructure.urls import cart_url


def register_cart_widgets() -> None:
    widgets.add_account_link(AccountNavLink(
        label="orders",
        order=100,
        href_fn=lambda: cart_url("/orders/"),
        external=True,
    ))
