Back to Opencv

Navbar Logo

docs_sphinx/_templates/navbar-logo.html

5.0.01.5 KB
Original Source

{# OpenCV navbar logo: the built-in pydata navbar-logo, plus an "Open Source Computer Vision" subtitle stacked under the wordmark — mirrors the legacy docs.opencv.org header. The title + subtitle are wrapped in .logo__textwrap so they form a column to the right of the SVG mark; the version switcher (a separate navbar_start slot) still sits inline beside the title. Link-resolution logic is copied verbatim from the theme's own navbar-logo.html so the brand href behaves identically. #} {% if theme_logo_link %} {% set href = theme_logo_link %} {% else %} {% if not theme_logo.get("link") %} {% set href = pathto(root_doc) %} {% elif hasdoc(theme_logo.get("link")) %} {% set href = pathto(theme_logo.get("link")) %} {# internal page #} {% else %} {% set href = theme_logo.get("link") %} {# external url #} {% endif %} {% endif %} [{% set is_logo = "light" in theme_logo["image_relative"] %} {% set alt = theme_logo.get("alt_text", "" if theme_logo.get("text") else "%s - Home" % docstitle) %} {% if is_logo %} {% if default_mode is undefined or default_mode == "auto" %} {% set default_mode = "light" %} {% endif %} {% set js_mode = "light" if default_mode == "dark" else "dark" %} {% endif %} {% if not is_logo or theme_logo.get("text") %}

{{ theme_logo.get("text") or docstitle }}

Open Source Computer Vision

{% endif %}]({{%20href%20}})