mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-03 04:30:06 +08:00
35 lines
1.0 KiB
HTML
35 lines
1.0 KiB
HTML
<h2 class="component-demos">
|
|
组件演示
|
|
<i class="iconfont-home icon-all" title="展开全部代码"></i>
|
|
{%- if post.meta.sketch %}
|
|
<a class="sketch-link" href="{{ post.meta.sketch }}" target="_blank">
|
|
<i class="iconfont-home icon-download"></i>
|
|
Sketch 下载
|
|
</a>
|
|
{%- endif %}
|
|
</h2>
|
|
<div class="code-boxes clearfix">
|
|
{%- set items = resource.pages|find_demo_in_component(post.meta.directory) %}
|
|
{%- if post.meta.cols == 1 %}
|
|
<div class="code-boxes-col-1-1">
|
|
{%- for item in items %}
|
|
{%- set post = item.meta.filepath|parsePost %}
|
|
{%- include "code.html" %}
|
|
{%- endfor %}
|
|
</div>
|
|
{%- else %}
|
|
<div class="code-boxes-col-2-1">
|
|
{%- for item in items|odd %}
|
|
{%- set post = item.meta.filepath|parsePost %}
|
|
{%- include "code.html" %}
|
|
{%- endfor %}
|
|
</div>
|
|
<div class="code-boxes-col-2-1">
|
|
{%- for item in items|even %}
|
|
{%- set post = item.meta.filepath|parsePost %}
|
|
{%- include "code.html" %}
|
|
{%- endfor %}
|
|
</div>
|
|
{%- endif %}
|
|
</div>
|