{# T-1982: render a compact BVP_norm chip for a task. Reads task._bvp = {mode, norm} attached by _attach_bvp_to_tasks (web.blueprints.tasks). - confirmed mode → plain "BVP 0.58" - proposed mode → italic "BVP 0.58*" with tooltip explaining the asterisk - none / missing → nothing The chip links to the task's detail-page BVP block (T-1980). #} {% macro bvp_badge(task) %} {%- set b = task._bvp -%} {%- if b and b.norm is not none -%} {%- set norm_fmt = "%.2f"|format(b.norm) -%} {%- if b.mode == 'proposed' -%} BVP {{ norm_fmt }}* {%- else -%} BVP {{ norm_fmt }} {%- endif -%} {%- endif -%} {% endmacro %}