QuantEcon / QuantEcon/quantecon-plugins.mystmd

Directives: stats, bar-list, stacked-bar, heatmap

Open
#5 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
JavaScript
Stars
0
Forks
0
Avg merge
2h 52m
Merged PRs (30d)
7

Description

Part of #2 (Phase 1a).

Problem. Four primitives in the contract present quantities: stats (big-number tiles or metric cards with an optional mini bar and note), bar-list (label, bar, value rows with an optional variant marker), stacked-bar (segments with inline labels), and heatmap (a matrix with a value range and not-applicable cells). Each is used by the compliance pages (score strip, breakdown, method stats, systemic rules, rule reach, priority bar, priority mix, heatmap; brief §5) and none exists in mystmd core.

Proposed work. For each directive: options capped at what the compliance pages use (REVIEW §9's charting-DSL caveat), inline data as an item-directive body or a :file: CSV with column options, and portable output per the contract:

  • stats: emits a div.dv-stats grid of div.dv-stat items; each carries value, denom, label, note, bar (0–1) and tone; falls back to a definition list.
  • bar-list: emits div.dv-bars with rows carrying label, value, max, variant; falls back to a two-column table.
  • stacked-bar: emits div.dv-stacked with segments carrying label, value, tone; falls back to a one-row table with a legend list.
  • heatmap: emits div.dv-heatmap with row and column labels, cell values, min, max, na marker; falls back to a table.

Tone is set by the author or by a :tone-by: threshold option; the directive never encodes a domain rubric.

Acceptance criteria.

  • Each directive has schema-validated fixture output and a documented option table
  • Each falls back to a readable table or list in the default book theme
  • Bad input (missing file, non-numeric value, unknown column) produces a fileError with the directive name and position

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the contract in docs/design-handoff-2026-09/README.md, especially brief §5 and REVIEW §9, then map the four directives and their compliance-page uses. Done means schema-validated fixtures, documented options, readable default-theme fallbacks, and positional fileError results for each listed bad input.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
data-visualization, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.