Tidied up the layout of the flags in player droplists.

master
Pacman Ghost 5 years ago
parent 7a397bd550
commit 2397eb5c5f
  1. 6
      vasl_templates/webapp/static/main.js
  2. 2
      vasl_templates/webapp/templates/tabs-scenario.html

@ -189,19 +189,21 @@ $(document).ready( function () {
return opt.text ;
var url = make_player_flag_url( opt.id, false ) ;
return $( "<div style='display:flex;align-items:center;'>" +
"<div style='display:inline-block;width:1em;text-align:center;margin-right:5px;'>" +
"<img src='" + url + "' style='height:0.9em;margin-right:0.25em;'>" +
"</div>" +
" " + opt.text +
"</div>" ) ;
}
init_select2( $( "select[name='PLAYER_1']" ),
"9.5em", false, format_player_droplist_item
"10em", false, format_player_droplist_item
).on( "select2:open", function() {
on_player_droplist_open( $(this) ) ;
} ).on( "change", function() {
on_player_change_with_confirm( 1 ) ;
} ) ;
init_select2( $( "select[name='PLAYER_2']" ),
"9.5em", false, format_player_droplist_item
"10em", false, format_player_droplist_item
).on( "select2:open", function() {
on_player_droplist_open( $(this) ) ;
} ).on( "change", function() {

@ -31,7 +31,7 @@
</div>
<div class="row" style="margin-top:0.5em;">
<label></label>
<span style='width:9.45em'></span>
<span style='width:10.25em'></span>
<label class="header" for="ELR">ELR</label>
<label class="header" for="SAN">SAN</label>
</div>

Loading…
Cancel
Save