Sha256: b1dabf4e30b69dce5667da5dbdae676594bf054d1539496591a20295d50e0cf7
Contents?: true
Size: 1.13 KB
Versions: 7
Compression:
Stored size: 1.13 KB
Contents
<% add_javascript_pack_tag("treeview") %> <% name ||= "" %> <% action ||= "" %> <% submit_button ||= "" %> <%= form_tag(action, method: :post) do %> <div id="treeview"> <div class="card"> <pre class="card-body pb-0">{{ path }}</pre> </div> <input type="hidden" name="<%= name %>" v-model="path" /> <div class="dirs"> <span v-for="(dir, index) in currentDirs"> <span v-if="index > 0"> <%= icon('fa-caret-right') %> </span> <span v-on:click="selectPath(dir)" class="dir">{{ basename(dir) }}</span> </span> </div> <div class="tree"> <span v-on:click="selectPath(value.path)" class="vue-path" v-bind:class="{ selected: isSelected(value.path) }" v-for="value in paths"> <span v-if="value.is_dir"><%= icon("fa-folder") %></span> <span v-if="!value.is_dir"><%= icon("fa-file-o") %></span> {{ basename(value.path) }} <br /> </span> </div> <pre v-if="preview" class="preview">{{ preview }}</pre> <p> <%= submit_tag submit_button, class: "btn btn-lg btn-primary float-right", "v-bind:disabled" => "selectedIsDir" %> </p> </div> <% end %>
Version data entries
7 entries across 7 versions & 1 rubygems