{# 传奇名字前的小头像(panel/static/legends/,python tools/legend_icons.py 生成;许可见那里的 LICENSE.txt)。 只是装饰:名字就在旁边,读屏软件跳过它。没有图标时(没认出来、以后出的新传奇)留出同样宽的空位,名字上下对齐 #} {% macro legend_icon(icon) -%} {%- if icon -%} {%- else -%} {%- endif -%} {%- endmacro %} {# 数据页卡片上的传奇组合只放三个头像(2026-10-28 用户决定):名字给读屏软件和悬停;没有图标的传奇(以后的新传奇)写名字 #} {% macro combo_icons(legends) -%} {%- set names = legends|map(attribute='name')|join('、') -%} {%- for l in legends -%} {%- if l.icon -%}{{ legend_icon(l.icon) }}{%- else -%}{%- endif -%} {%- endfor -%} {{ names }} {%- endmacro %}