v0.2.0 — first PyPI release
First release published to PyPI.
pip install "cf-ui[fastapi,bulma]" # or [django], [litestar]; themes: bulma, bootstrap, foundation, fomantic, daisyFive themes instead of two, an axis layer that enforces what it claimed, components that render on Litestar at all, and two security fixes on the Jinja path.
Three breaking changes — listed first, because a 0.x version number carries no semver promise to read them off:
- Components render on the Litestar path (#42).
<Cf:Card>previously reached the browser as literal text — no exception, no output, a 200 response. An app that worked around this by hand-writing the markup should drop the workaround. - cf-ui's Jinja templates escape their own output (#36). Anything previously interpolated raw through a component now renders as entities; a prop deliberately carrying markup must be
markupsafe.Markup. - The axis layer validates token values, drops the
--spacingalias, and validates by default in every exported generator (#20).
Highlights
Litestar actually works (#42). Two defects, both of which rendered without raising. Catalog(jinja_env=env) does not convert the environment it is given — it builds its own — so Litestar's Jinja2 environment had never heard of the component tag. And {% from "cf_ui/assets.jinja" import … %} raised TemplateNotFound, because only the theme folder was on the search path. Litestar's only prior coverage was MagicMock unit tests, and a mock cannot render, which is why both shipped documented-as-working. There is now a live-app integration suite.
Escaping moved into the templates (#36). Every cf-ui template carries its own {% autoescape true %} block, so output is escaped on a bare Catalog(), on Litestar's plain-Jinja path, and for a consumer who never calls install_cf_ui at all. The installers never touch the caller's autoescape — an earlier cut set it on the shared environment, and every defect that followed came from that one choice.
Three new themes — Bootstrap 5 (#22), Foundation 6 (#23), Fomantic UI (#24) — joining Bulma and DaisyUI. Component names stay theme-agnostic: switching frameworks means changing CF_UI_THEME in one place.
Packaging and release (#43, #45, #47). A LICENSE file the wheel actually ships, a full classifier set, trusted publishing via GitHub Actions OIDC with no stored API token, and a build job that refuses to hand off a wheel missing its templates — cf-ui is templates, and they ship with no explicit include, so a packaging regression would otherwise produce a wheel that installs cleanly, imports cleanly, and renders nothing.
Documentation (#39). A published MkDocs site, plus fixes to samples that never worked: from jinjax import ComponentCatalog (jinjax exports Catalog), and <CfCard> (the JinjaX prefix separator is :, so it is <Cf:Card>). tests/unit/test_docs_samples.py now parses every fenced block in the README and docs and resolves every import against the real package, so those claims are executable rather than asserted.
Full details in CHANGELOG.md.