Browse Source

filter name

pull/4/head
afc163 10 years ago
parent
commit
21810a727c
  1. 2
      theme/templates/layout.html
  2. 2
      theme/theme.js

2
theme/templates/layout.html

@ -97,7 +97,7 @@
<script type="text/jsx">
React.render(
<CodeBoxes>
{%- set items = resource.pages|under(post.meta.directory) %}
{%- set items = resource.pages|find_demo_in_component(post.meta.directory) %}
{%- for item in items %}
<CodeBox src="{{item.meta.filepath}}"></CodeBox>
{%- endfor %}

2
theme/theme.js

@ -49,7 +49,7 @@ module.exports = function(nico) {
return item;
}));
},
under: function(pages, directory) {
find_demo_in_component: function(pages, directory) {
var ret = [];
Object.keys(pages).forEach(function(key) {
var page = pages[key];

Loading…
Cancel
Save