Sha256: 804645c72d016a899138de07e65c7b660ddd6969c4d8589c771669daf0e9f459

Contents?: true

Size: 1.22 KB

Versions: 3

Compression:

Stored size: 1.22 KB

Contents

<h4>Последние комментарии</h4>

{%- assign comments = '' | split: ',' -%}
{%- for cc in site.data.comments -%}
  {%- if cc[1] -%}
    {%- for ccc in cc[1] -%}
      {%- if ccc[1] and ccc[1].comment_id and ccc[1].comment_id != '' -%}
        {%- assign comments = comments | push: ccc[1] -%}
      {%- endif -%}
    {%- endfor -%}
  {%- endif -%}
{%- endfor -%}
{%- assign comments = comments | sort: 'date' | reverse -%}
<div class="comments">
{%- for comment in comments limit:site.comments_side_limit -%}
  {%- assign path = comment.slug | split: '-' -%}
  {%- assign year = path[0] -%}
  {%- assign month = path[1] -%}
  {%- assign ext = path[-1] -%}
  {%- assign name = path | shift | shift | pop | join: '-' -%}
  {%- assign url = '/' | append: year | append: '/' | append: month | append: '/' | append: name | append: '.' | append: ext -%}
  {%- assign post = site.posts | where: 'url', url | first -%}
  <div class="comment">
    <p class="meta"><a href="{{url}}#{{comment.comment_id}}">{{comment.date | date: '%Y.%m.%d %H:%M'}} | {{comment.name}} к записи «{{post.title}}»</a></p>
    <div class="message">{{- comment.message | xml_escape | replace: '&gt;', '>' | markdownify -}}</div>
  </div>
{%- endfor -%}
</div>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
jekyll-theme-shikhalev-0.1.0.8 _includes/nova/aside/last_comments.liquid
jekyll-theme-shikhalev-0.1.0.6 _includes/nova/aside/last_comments.liquid
jekyll-theme-shikhalev-0.1.0.5 _includes/nova/aside/last_comments.liquid