{#- Five-year research-program roadmap, driven by `criteria.program` in data/criteria.yaml. One track per research stream; each track tiles `total_years` left→right in `phases`, whose widths are their `years` span, so you can rebalance a stream without touching the SVG. The year axis, gridlines, row positions and canvas height are all computed. The chip row underneath lists the target outcomes; chip widths follow their text. -#} {%- set pg = criteria.program -%} {%- set LX = 15 -%}{%- set LABEL_W = 167 -%} {%- set X0 = LX + LABEL_W + 12 -%}{%- set X1 = 706 -%}{%- set W = X1 - X0 -%} {%- set total = pg.total_years | default(5) -%} {%- set gap = pg.phase_gap | default(3) -%} {%- set fills = pg.fills or ['#dbe7f4', '#7ba3d0', '#0f3f73'] -%} {%- set text_fills = pg.text_fills or ['#1c1f23', '#ffffff', '#ffffff'] -%} {%- set TOP = 22 -%}{%- set ROW_H = 46 -%}{%- set BAR_H = 22 -%}{%- set BAR_DY = 6 -%} {%- set nrows = pg.streams | length -%} {%- set tracks_bottom = TOP + (nrows - 1) * ROW_H + BAR_DY + BAR_H -%} {%- set chips_y = tracks_bottom + 18 -%} {%- set CHIP_H = 17 -%} {%- set height = chips_y + CHIP_H + 6 -%} {%- macro edge(year) -%}{{ (X0 + (year / total) * W) | round(1) }}{%- endmacro -%}
{{ pg.caption }}