/
post.html
37 lines (33 loc) · 1.21 KB
/
post.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
{% extends "layout.html" %}
{%- block title -%}{{config.package.family}}/{{config.package.name}} - {{post.title}}{%- endblock -%}
{% block content %}
<article class="hentry">
<h1 class="entry-title">{{post.title}}</h1>
<div class="entry-content">
{{ post.html|replace_code }}
</div>
</article>
{% endblock %}
{%- block subsidebar %}
{%- set items = resource.pages|find_category(post.meta.category) %}
{%- if items|length > 1 %}
<ol id="sidenav">
{%- for item in items %}
<li><a href="{{permalink_url(item)}}">{{item.title}}</a></li>
{%- endfor %}
</ol>
{%- endif %}
{%- set output = config.package.spm.output %}
{%- if output|length > 1 %}
<ul id="module-output">
<li class="module-multiable" title="本组件共有{{output|length}}个子模块">多模块</li>
{%- for value in output %}
<li><a data-file="{{value}}" href="{{content_url('')}}dist/{{value}}">■</a></li>
{%- endfor %}
</ul>
{%- endif %}
<div id="output-card">
<h3>{{config.package.family}}/{{config.package.name}}/{{config.package.version}}/<a target="_blank" id="output-file"></a></h3>
<p>这是模块的输出文件,请 require 或 seajs.use 以上 ID 来使用本文件,具体 API 请阅读文档。</p>
</div>
{%- endblock %}