~xdavidwu/xdavidwu.link

ref: 76a87799fd449829f44041b6ccd9d9fba1436f5c xdavidwu.link/_includes/figure -rw-r--r-- 425 bytes
76a87799 — Michael Rose Improve headline hierarchy 5 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
<figure class="{{ include.class }}">
  <img src=
    {% if include.image_path contains "://" %}
      "{{ include.image_path }}"
    {% else %}
      "{{ include.image_path | relative_url }}"
    {% endif %}
    alt="{% if include.alt %}{{ include.alt }}{% endif %}">
  {% if include.caption %}
    <figcaption>
      {{ include.caption | markdownify | remove: "<p>" | remove: "</p>" }}
    </figcaption>{% endif %}</figure>