2.5 KiB
{% comment %} 引数: なし (assignされたdata変数を参照) {% endcomment %}
{% comment %} 空のリストを作成 {% endcomment %} {% assign details = "" | split: "|" %}
{% comment %} リンク {% endcomment %} {% capture link_list %} {% for link_data in data.links %} {% if forloop.first != true %}/{% endif %} {{ link_data.text }} {% endfor %} {% endcapture %}
{% assign links = "" | split: "|" %} {% assign links = links | push: "リンク" %} {% assign links = links | push: link_list %} {% assign details = details | push: links %}
{% comment %} 開発者 {% endcomment %} {% assign author = "" | split: "|" %} {% assign author = author | push: "開発者" %} {% assign author = author | push: data.author %} {% assign details = details | push: author %}
{% comment %} 説明 {% endcomment %} {% assign description = "" | split: "|" %} {% assign description = description | push: "説明" %} {% assign description = description | push: data.description %} {% assign details = details | push: description %}
{% comment %} 依存Mod {% endcomment %} {% if data.depends %} {% capture depend_list %} {% for depend in data.depends %} {% if depend.url %} {{ depend.text }}{% if forloop.last != true %},{% endif %} {% else %} {{ depend.text }}{% if forloop.last != true %},{% endif %} {% endif %} {% endfor %} {% endcapture %}
{% assign depends = "" | split: "|" %} {% assign depends = depends | push: "依存Mod" %} {% assign depends = depends | push: depend_list %} {% assign details = details | push: depends %} {% endif %}
{% comment %} 対応・連携可能Mod {% endcomment %} {% if data.depends-optional %} {% capture optionally_depend_list %} {% for depend in data.depends-optional %} {% if depend.url %} {{ depend.text }}{% if forloop.last != true %},{% endif %} {% else %} {{ depend.text }}{% if forloop.last != true %},{% endif %} {% endif %} {% endfor %} {% endcapture %}
{% assign depends_optional = "" | split: "|" %} {% assign depends_optional = depends_optional | push: "依存Mod(任意)" %} {% assign depends_optional = depends_optional | push: optionally_depend_list %} {% assign details = details | push: depends_optional %} {% endif %}
{% comment %} テンプレートをインクルード {% endcomment %} {% include details.md screenshot = data.screenshot details = details %}