Fix select menu appearance on firefox and safari.

This commit is contained in:
kovacsv 2022-01-08 10:22:07 +01:00
parent 31f622dede
commit e94cf8e5e5
3 changed files with 25 additions and 3 deletions

View File

@ -169,7 +169,8 @@ OV.AddRangeSlider = function (parentElement, min, max)
OV.AddSelect = function (parentElement, options, selectedIndex, onChange)
{
let select = OV.AddDomElement (parentElement, 'select', 'ov_select');
let container = OV.AddDiv (parentElement, 'ov_select_container');
let select = OV.AddDomElement (container, 'select', 'ov_select');
for (let option of options) {
OV.AddDomElement (select, 'option', null, option);
}

View File

@ -128,14 +128,35 @@ input.ov_checkbox:checked
border: 0px;
}
div.ov_select_container
{
position: relative;
}
div.ov_select_container:after
{
font-family: "O3DVIcons";
font-size: 18px;
content: "\f101";
position: absolute;
right: 6px;
top: 6px;
pointer-events: none;
}
select.ov_select
{
color: var(--ov_dialog_foreground_color);
background: var(--ov_dialog_background_color);
font-family: Quicksand, Helvetica, sans-serif;
font-size: 16px;
padding: 3px;
margin: 0px;
padding: 5px;
border: 1px solid var(--ov_border_color);
border-radius: 5px;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
input.ov_slider

View File

@ -161,7 +161,7 @@ div.ov_dialog div.ov_dialog_row
div.ov_dialog div.ov_dialog_row_name
{
width: 30%;
margin-top: 4px;
margin-top: 5px;
float: left;
}