Skip to content

Commit

Permalink
fix: filter list UI spacing between elements (#2128)
Browse files Browse the repository at this point in the history
* fix: filter list UI spacing between elements

* remove alerts
  • Loading branch information
dpgaspar authored Oct 12, 2023
1 parent b798a01 commit d001522
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 17 deletions.
30 changes: 17 additions & 13 deletions flask_appbuilder/static/appbuilder/css/ab.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

.collapse.in {
display:block;
overflow: visible;
display: block;
overflow: visible;
}

.panel-group .panel {
Expand All @@ -10,19 +10,19 @@

/* Wrapper for page content to push down footer */
.wrap {
min-height: 100%;
height: auto !important;
height: 100%;
min-height: 100%;
height: auto !important;
height: 100%;
}


.fixed-footer{
background-color: #f5f5f5;
bottom:0;
left:0;
right:0;
width:100%;
margin:auto;
.fixed-footer {
background-color: #f5f5f5;
bottom: 0;
left: 0;
right: 0;
width: 100%;
margin: auto;
}


Expand All @@ -31,7 +31,11 @@ th.action_checkboxes {
}

select {
width: 100%;
width: 100%;
}

td.filter {
width: 50%
}

.cursor-hand {
Expand Down
1 change: 0 additions & 1 deletion flask_appbuilder/static/appbuilder/js/ab.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ function loadSelectDataSlave(elem) {
elem.select2({data: {id: "",text: ""}, placeholder: "Select", allowClear: true});
}
$('#' + master_id).on("change", function(e) {
var change_master_id = elem.attr('master_id');
var change_master_val = $('#' + master_id).val();
var endpoint = elem.attr('endpoint');
if (change_master_val) {
Expand Down
7 changes: 4 additions & 3 deletions flask_appbuilder/static/appbuilder/js/ab_filters.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ var AdminFilters = function (element, labels, form, filters, active_filters) {
$field.attr('class', ' filter_val ' + $field.attr('class'));
}
$el.append(
$('<td/>').append($field)
$('<td class="filter"/>').append($field)
);
}

Expand Down Expand Up @@ -81,7 +81,7 @@ var AdminFilters = function (element, labels, form, filters, active_filters) {
cx += 1;
});
$el.append(
$('<td />').append($select)
$('<td class="filter"/>').append($select)
);
// avoids error
// if (i_option === -1) { $select.select2(); }
Expand Down Expand Up @@ -112,12 +112,13 @@ var AdminFilters = function (element, labels, form, filters, active_filters) {
$field_inner = $("input", $($field))
$field_inner.attr('name', '_flt_0_' + name);
$field_inner.attr('class', ' filter_val ' + $field_inner.attr('class'));
$field_inner.attr('style', "width: 100%");
} else {
$field.attr('name', '_flt_0_' + name);
$field.attr('class', ' filter_val ' + $field.attr('class'));
}
$el.append(
$('<td/>').append($field)
$('<td class="filter"/>').append($field)
);
if ($field.hasClass("my_select2")) {
$field.select2({
Expand Down

0 comments on commit d001522

Please sign in to comment.