Skip to content

bluefox-components

Jinja2 macro components and Pico CSS theming for the Bluefox Stack.

What it provides

  • Base layoutbfx/base.html with Pico CSS, Google Fonts, nav/main/footer blocks
  • CSS themebluefox.css overrides Pico's custom properties with the Bluefox palette (light + dark)
  • Setup functionsetup_components(app) registers templates and mounts static files
  • Jinja2 macros — parameterized components: buttons, inputs, cards, alerts, tables, and more
  • Component showcase — a production route at /components with live examples

Quick start

uv add bluefox-components
from bluefox_core import BluefoxSettings, create_bluefox_app
from bluefox_components import setup_components

settings = BluefoxSettings()
app = create_bluefox_app(settings)
setup_components(app)
{% extends "bfx/base.html" %}
{% from "bfx/button.html" import button %}

{% block content %}
  {{ button("Save") }}
{% endblock %}

Requirements

  • Python 3.12+
  • bluefox-core >= 0.4.0