|
105 | 105 | <div class="padding:5px"> |
106 | 106 | <span class=""><i class="fa fa-caret-down" toggle="fa-caret-right, fa-caret-down"></i></span> |
107 | 107 | <span class="margin-left:5px" collection="websites" document_id="" name="name">Project name</span> |
108 | | - <div class="margin-left:10px sortable" template_id="folder" fetch-collection="files" filter-name1="directory" filter-value="" order-by="name" order-type="asc" fetch-count="6" render_id="folder"> |
| 108 | + <div class="margin-left:10px sortable" template_id="auto" fetch-collection="files" filter-name="directory" filter-value="/" filter-operator="$eq" order-by="name" order-type="asc" render_id="auto"> |
| 109 | + <div template_id="auto" filter-name="content-type" filter-value="text/directory"></div> |
109 | 110 | <!--Folder Template --> |
110 | | - <div class="template padding:5px" template_id="folder" document_id="{{folder._id}}" render-key="folder" render-array="folder.data"> |
111 | | - <span class=""><i class="fa fa-caret-down" toggle="fa-caret-right, fa-caret-down"></i></span> |
112 | | - <span class="margin-left:5px" collection="folders" document_id="{{folder._id}}" name="name">{{folder.name}}</span> |
| 111 | + <div class="template padding:5px" template_id="auto" document_id="{{auto._id}}"> |
| 112 | + <span class="" show="#directory{{auto._id}}" hide="#directory{{auto._id}}" toggle="fa-caret-down, fa-caret-right" toggle-target="#icon{{auto._id}}"> |
| 113 | + <i id="icon{{auto._id}}" class="fa fa-caret-right" ></i> |
| 114 | + </span> |
| 115 | + <span class="margin-left:5px" collection="files" document_id="{{auto._id}}" name="name"></span> |
| 116 | + |
113 | 117 | <!-- fetches folder and file template. This loops until tree ends --> |
114 | | - <div class="domEditor margin-left:10px" collection="component" document_id="611ab5d9251afa96bd20f6cc" name="html"></div> |
| 118 | + <div id="directory{{auto._id}}" class="domEditor margin-left:10px hidden" collection="components" document_id="611ab5d9251afa96bd20f6cc" name="html" filter-value="{{auto.path}}"></div> |
115 | 119 | </div> |
116 | 120 | </div> |
117 | | - <div class="margin-left:10px sortable" template_id="file" fetch-collection="files" filter-name="directory" filter-value="" order-by="name" fetch-count="6"> |
| 121 | + <div class="margin-left:10px sortable" template_id="auto" fetch-collection="files" filter-name="directory" filter-value="/" filter-operator="$eq" order-by="name" render_id="auto"> |
| 122 | + <div template_id="auto" filter-name="content-type" filter-value="text/directory" filter-operator="$ne"></div> |
| 123 | + |
118 | 124 | <!-- File Template --> |
119 | | - <div class="template padding:5px" template_id="file" document_id="{{data._id}}"> |
120 | | - <span class="{{data.content-type}}"><i class="fab fa-html5"></i></span> |
121 | | - <span class="margin-left:5px" collection="files" document_id="{{data._id}}" name="name">{{data.name}}</span> |
| 125 | + <div class="template padding:5px" template_id="auto" document_id="{{auto._id}}"> |
| 126 | + <span class="{{auto.content-type}}"><i class="fab fa-html5"></i></span> |
| 127 | + <span class="margin-left:5px" collection="files" document_id="{{auto._id}}" name="name"></span> |
122 | 128 | </div> |
123 | 129 | </div> |
124 | 130 | </div> |
|
136 | 142 | </span> |
137 | 143 | </form> |
138 | 144 | <!-- Assets --> |
139 | | - <div class="display:flex flex-wrap:wrap justify-content:center width:100% text-align:center padding-bottom:20px" template_id="assets" fetch-collection="files" filter-name="content-type" filter-value="image" order-by="position" order-type="asc"> |
| 145 | + <div class="display:flex flex-wrap:wrap justify-content:center width:100% text-align:center padding-bottom:20px" template_id="assets" fetch-collection="files" filter-name="content-type" filter-value="image, video" order-by="position" order-type="asc"> |
140 | 146 | <!-- Asset Template --> |
141 | 147 | <div template_id="assets" class="template card flex-grow:1 width:70px height:90px margin:5px padding:5px" hover="display:block!important" hover-target="#editblock{{data._id}}"> |
142 | 148 | <div id="editblock{{data._id}}" class="position:absolute top:8px right:8px font-size:11px display:none"> |
143 | 149 | <a target="modal" href="https://server.cocreate.app/CoCreate-plugins/CoCreate-tui-image-editor/demo/index.html" pass-collection="files" pass-document_id="{{data._id}}" pass_to="form-fields" modal-width="900px"> |
144 | 150 | <i class="fas fa-pencil-alt"></i> |
145 | 151 | </a> |
146 | 152 | </div> |
147 | | - <div cloneable="true" cloneable-html='<img src=".{{data.path}}"></img>' collection="files" document_id="{{data._id}}" name="thumbnail" class="padding-bottom:5px"> |
148 | | - <img width="100%" src="{{data.path}}"> |
149 | | - <!--<p class="font-size:11px" collection="module_activities" document_id="{{data._id}}" name="name">Block</p>--> |
150 | | - </div> |
| 153 | + <a actions="attributes" attribute="src" value="{{data.path}}"> |
| 154 | + <!-- image --> |
| 155 | + <div cloneable="true" cloneable-html='<img src="{{data.path}}"></img>' class="padding:5px"> |
| 156 | + <img width="auto" height="65px" collection="files" document_id="{{data._id}}" name="path"> |
| 157 | + <!--<p class="font-size:11px" collection="module_activities" document_id="{{data._id}}" name="name">Block</p>--> |
| 158 | + </div> |
| 159 | + <!-- Video --> |
| 160 | + <!--<div cloneable="true" cloneable-html='<video><source src="{{data.path}}"></video>' class="padding:5px">--> |
| 161 | + <!-- <video width="auto" height="65px">--> |
| 162 | + <!-- <source collection="files" document_id="{{data._id}}" name="path">--> |
| 163 | + <!-- </video>--> |
| 164 | + <!--</div>--> |
| 165 | + </a> |
151 | 166 | </div> |
152 | 167 | </div> |
153 | 168 |
|
|
0 commit comments