Remove chosen from some filter dropdowns and restyle to match
This commit is contained in:
parent
5d190dedff
commit
de6ebfc341
|
@ -6,14 +6,38 @@ table.filterTable {
|
|||
}
|
||||
|
||||
#fieldsTable td:first-child {
|
||||
width: 5em;
|
||||
width: 4em;
|
||||
}
|
||||
|
||||
#fieldsTable td:nth-child(3) {
|
||||
width: 11.5em;
|
||||
width: 10.5em;
|
||||
}
|
||||
|
||||
#fieldsTable td:nth-child(4) {
|
||||
width: 15em;
|
||||
width: 14em;
|
||||
}
|
||||
|
||||
#fieldsTable td {
|
||||
padding: 0 3px;
|
||||
}
|
||||
|
||||
select {
|
||||
vertical-align: middle;
|
||||
padding: 2px;
|
||||
border: 1px solid #aaa;
|
||||
border-radius: 5px;
|
||||
background-color: #fff;
|
||||
background: -webkit-gradient(linear,left top,left bottom,color-stop(20%,#fff),color-stop(50%,#f6f6f6),color-stop(52%,#eee),to(#f4f4f4));
|
||||
background: linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);
|
||||
background-clip: padding-box;
|
||||
-webkit-box-shadow: 0 0 3px #fff inset, 0 1px 1px rgba(0,0,0,.1);
|
||||
box-shadow: 0 0 3px #fff inset, 0 1px 1px rgba(0,0,0,.1);
|
||||
color: #444;
|
||||
}
|
||||
|
||||
.chosen-single, .chosen-container {
|
||||
font-size: inherit !important;
|
||||
height: 30px !important;
|
||||
}
|
||||
|
||||
#fieldsTable input[type=button] {
|
||||
|
|
|
@ -558,3 +558,22 @@ input[type=submit]:disabled,
|
|||
.nav>li>a:focus, .nav>li>a:hover {
|
||||
background-color: #444444;
|
||||
}
|
||||
|
||||
/* Override chosen for dark theme */
|
||||
.chosen-single, .chosen-container {
|
||||
font-size: inherit !important;
|
||||
background: -webkit-gradient(linear,left top,left bottom,color-stop(20%,#555),color-stop(50%,#464646),color-stop(52%,#444),to(#545454)) !important;
|
||||
background: linear-gradient(#555 20%,#464646 50%,#444 52%,#545454 100%) !important;
|
||||
background-color: #444444 !important;
|
||||
color: #eee !important;
|
||||
border-color: #8f8fc2 !important;
|
||||
-webkit-box-shadow: none !important;
|
||||
|
||||
}
|
||||
|
||||
.chosen-results, .chosen-search, .chosen-drop, .chosen-choices {
|
||||
color: #eee !important;
|
||||
background-color: #444444 !important;
|
||||
}
|
||||
/* end chosen override */
|
||||
|
||||
|
|
|
@ -6,18 +6,31 @@ table.filterTable {
|
|||
}
|
||||
|
||||
#fieldsTable td:first-child {
|
||||
width: 5em;
|
||||
width: 4em;
|
||||
}
|
||||
|
||||
#fieldsTable td:nth-child(3) {
|
||||
width: 11.5em;
|
||||
}
|
||||
|
||||
#fieldsTable td:nth-child(4) {
|
||||
width: 15em;
|
||||
}
|
||||
|
||||
#fieldsTable td {
|
||||
padding: 0 5px;
|
||||
padding: 0 3px;
|
||||
}
|
||||
|
||||
select {
|
||||
vertical-align: middle;
|
||||
padding: 2px;
|
||||
border: 1px solid #8f8fc2;
|
||||
border-radius: 5px;
|
||||
background: -webkit-gradient(linear,left top,left bottom,color-stop(20%,#555),color-stop(50%,#464646),color-stop(52%,#444),to(#545454));
|
||||
background: linear-gradient(#555 20%,#464646 50%,#444 52%,#545454 100%);
|
||||
background-color: #444444;
|
||||
background-clip: padding-box;
|
||||
color: #eee;
|
||||
}
|
||||
|
||||
#fieldsTable input[type=button] {
|
||||
|
|
|
@ -20,6 +20,20 @@ table.filterTable {
|
|||
padding: 0 5px;
|
||||
}
|
||||
|
||||
select {
|
||||
vertical-align: middle;
|
||||
padding: 2px;
|
||||
border: 1px solid #aaa;
|
||||
border-radius: 5px;
|
||||
background-color: #fff;
|
||||
background: -webkit-gradient(linear,left top,left bottom,color-stop(20%,#fff),color-stop(50%,#f6f6f6),color-stop(52%,#eee),to(#f4f4f4));
|
||||
background: linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);
|
||||
background-clip: padding-box;
|
||||
-webkit-box-shadow: 0 0 3px #fff inset, 0 1px 1px rgba(0,0,0,.1);
|
||||
box-shadow: 0 0 3px #fff inset, 0 1px 1px rgba(0,0,0,.1);
|
||||
color: #444;
|
||||
}
|
||||
|
||||
#fieldsTable input[type=button] {
|
||||
width: 1.8em;
|
||||
margin-left: 2px;
|
||||
|
|
|
@ -109,7 +109,7 @@ function parseRows (rows) {
|
|||
$j.each(conjTypes, function (i) {
|
||||
conjSelect.append('<option value="' + i + '" >' + i + '</option>');
|
||||
});
|
||||
inputTds.eq(0).html(conjSelect).children().val(cnjVal === undefined ? 'and' : cnjVal).chosen({width: "101%"});
|
||||
inputTds.eq(0).html(conjSelect).children().val(cnjVal === undefined ? 'and' : cnjVal);
|
||||
}
|
||||
|
||||
let brackets = rows.length - 2;
|
||||
|
@ -124,8 +124,8 @@ function parseRows (rows) {
|
|||
}
|
||||
let obrVal = inputTds.eq(1).children().val(); //Save currently selected bracket option
|
||||
let cbrVal = inputTds.eq(5).children().val();
|
||||
inputTds.eq(1).html(obrSelect).children().val(obrVal).chosen({width: (brackets/3.5+4)+'em', placeholder_text_single: ' ', allow_single_deselect: true}); //Set bracket contents and assign saved value
|
||||
inputTds.eq(5).html(cbrSelect).children().val(cbrVal).chosen({width: (brackets/3.5+4)+'em', placeholder_text_single: ' ', allow_single_deselect: true});
|
||||
inputTds.eq(1).html(obrSelect).children().val(obrVal); //Set bracket contents and assign saved value
|
||||
inputTds.eq(5).html(cbrSelect).children().val(cbrVal);
|
||||
} else {
|
||||
inputTds.eq(1).html(' '); //Blank if there aren't enough terms for brackets
|
||||
inputTds.eq(5).html(' ');
|
||||
|
@ -248,9 +248,8 @@ function delTerm( element ) {
|
|||
function init() {
|
||||
updateButtons( $('executeButton') );
|
||||
$j('#Id').chosen();
|
||||
$j('#fieldsTable select').not("[name$='br\\]']").chosen({width: '101%', placeholder_text_single: ' '});
|
||||
$j('#fieldsTable').find("[name$='br\\]']").chosen({width: '101%', placeholder_text_single: ' ', allow_single_deselect: true});
|
||||
$j('#sortTable select').chosen();
|
||||
$j('#fieldsTable select').not("[name$='br\\]'], [name$='cnj\\]']").chosen({width: '101%'}); //Every select except brackets/and
|
||||
$j("#sortTable [name$='sort_field\\]']").chosen();
|
||||
}
|
||||
|
||||
window.addEvent( 'domready', init );
|
||||
|
|
Loading…
Reference in New Issue