Created
June 1, 2014 15:57
-
-
Save dohomi/132dbb76bd267eb8397c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template name="pageTreeNav"> | |
<div id="pageTree" class="js-pa-sortable js-pa-container" data-parent-id="null"> | |
{{#each getPageNodes}} | |
{{> pageTreeItem itemData=. level="2"}} | |
{{/each}} | |
</div> | |
</template> | |
<template name="pageTreeItem"> | |
{{#with itemData}} | |
<div class="tp-page-tree-item js-pa-sortable-item js-pa-page {{activeClass}} {{jsRoot}}" data-page-id="{{_id}}" | |
data-page-sorting="{{sorting}}"> | |
{{#if hasSubpage}} | |
<a href="#c_{{_id}}" data-toggle="collapse" | |
class="tp-toggle-collapse {{#unless inRootline}}collapsed{{/unless}}"> | |
<span class="glyphicon"></span> | |
</a> | |
{{else}} | |
<span class="glyphicon glyphicon-play-circle"></span> | |
{{/if}} | |
<a href="{{pathFor 'pageAdminEdit' _id=_id}}"><span class="fa {{iconName}}"></span> {{navTitle}}</a> | |
</div> | |
<div id="c_{{_id}}" | |
class="tp-page-tree-container js-pa-sortable js-pa-container collapse {{#if inRootline}}in{{/if}} {{#if activeClass}}in{{/if}}" | |
data-parent-id="{{_id}}"> | |
<div class="js-pa-sortable-item js-no-item" style="height: 2px;overflow: hidden">ga</div> | |
{{#if hasSubpage}} | |
{{#each getPageNodes parentPageId=_id}} | |
{{> pageTreeItem itemData=.}} | |
{{/each}} | |
{{/if}} | |
</div> | |
{{/with}} | |
</template> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment