Skip to content

Releases: dna-seq/reflex-mui-datagrid

v0.2.1: column_overrides, suffixUrl, dtype-based default widths

19 Mar 11:52

Choose a tag to compare

What's New

column_overrides parameter for set_lazyframe()

Customize auto-generated column definitions without reaching into internal cache. Overrides are applied before caching, so they survive all internal operations (value options computation, filter upgrades).

yield from self.set_lazyframe(lf, column_overrides={
    "pgs_id": {
        "width": 140,
        "cellRendererType": "url",
        "cellRendererConfig": {
            "baseUrl": "https://www.pgscatalog.org/score/",
            "suffixUrl": "/",
            "color": "#1565c0",
        },
    },
    "trait": {"minWidth": 150, "flex": 2},
    "internal_notes": {"hide": True},
})

suffixUrl support in URL cell renderer

The URL cell renderer now supports suffixUrl in addition to baseUrl. The href is constructed as baseUrl + cellValue + suffixUrl, enabling URLs like https://www.pgscatalog.org/score/PGS000056/ (trailing slash) or https://example.com/items/{value}/details.

Dtype-based default column widths

build_column_defs_from_schema() now assigns sensible default widths based on polars dtype:

  • Boolean → 80px
  • Numeric → 110px
  • Date → 140px
  • Datetime → 160px
  • String / Categorical / everything else → flex 1

Demo updates

  • New PRS (Lazy + Overrides) tab demonstrating column_overrides with PGS Catalog URL links
  • Longevity Map tab now links rsIDs to the GWAS Catalog (https://www.ebi.ac.uk/gwas/variants/{rsid})

Full changelog: v0.2.0...v0.2.1

v0.2.0

17 Mar 01:10

Choose a tag to compare

Full Changelog: v0.1.11...v0.2.0

v0.1.8

19 Feb 01:37

Choose a tag to compare

Release v0.1.8 - fix filtering, mixin support, and server-side filter improvements