Commit 3fa4a50e authored by Ryan Herbert's avatar Ryan Herbert
Browse files

file form change jstree field styling

makes it clearer that the user can click a button to select a file from
jstree
parent 90dd142d
......@@ -2470,10 +2470,11 @@ form {
box-shadow: inset 0 1px 1px rgba(255,0,0,.075);
}
&[type="file"] {
&[type="file"], &.jstree_field {
border: 0px;
border-radius: unset;
box-shadow: unset;
cursor: pointer;
}
}
......
......@@ -357,7 +357,7 @@ FileFormBuilder.prototype.build_file_field = function(id, hidden) {
FileFormBuilder.prototype.build_jstree = function() {
var self = this;
var d = this.build_wrapper();
d.className += " jstree_container";
d.className += " jstree_field";
if (!this.source) {
d.hidden = true;
}
......@@ -366,8 +366,8 @@ FileFormBuilder.prototype.build_jstree = function() {
}
var sel = document.createElement('span');
sel.className = "form_label";
sel.appendChild(document.createTextNode(('selected:')));
sel.className = "button2";
sel.appendChild(document.createTextNode(('browse')));
d.appendChild(sel);
var indicator = document.createElement('span');
indicator.id = "file_indicator_" + self.index;
......
......@@ -78,10 +78,11 @@
>
</div>
<div id="jstree_field_{{=i}}"
class="field_div jstree_field form-control"
{{if not source_module_active:}} style="display: none;" {{pass}}
data-index={{=i}}
onclick="db.display_jstree(this.dataset.index)">
<span class="form_label">selected:</span>
<span class="button2">browse</span>
<span id="file_indicator_{{=i}}"></span>
</div>
</div>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment