mirror of
https://github.com/fluent/fluentd-ui.git
synced 2026-05-05 02:46:11 +02:00
Add folder icon for file viewer
This commit is contained in:
parent
6a5ffc49bc
commit
186d5a8462
@ -25,10 +25,13 @@
|
||||
return _.find(this.paths, function(path){
|
||||
return self.path == path.path;
|
||||
});
|
||||
},
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
isAncestor: function(target) {
|
||||
return this.path.indexOf(target) === 0;
|
||||
},
|
||||
fetchTree: function() {
|
||||
var self = this;
|
||||
new Promise(function(resolve, reject) {
|
||||
|
||||
@ -2,7 +2,8 @@
|
||||
<input type="text" name="<%= try(:name) %>" size="48" v-model="path" />
|
||||
<div class="tree">
|
||||
<pre>
|
||||
<span v-on="click: selectPath(path)" class="vue-path" v-class="selected: isSelected(path)" v-repeat="paths">{{ path }}<span v-if="isSuffixRequired($data)">/</span>
|
||||
<span v-on="click: selectPath(path)" class="vue-path" v-class="selected: isSelected(path)" v-repeat="paths"><span
|
||||
v-if="is_dir"><span v-if="!isAncestor(path)"><%= icon("fa-folder") %></span><span v-if="isAncestor(path)"><%= icon("fa-folder-open") %></span></span>{{ path }}<span v-if="isSuffixRequired($data)">/</span>
|
||||
</span></pre>
|
||||
</div>
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user