Ich möchte einen Rand rechts zwischen der Symbolschriftart und den Optionselementen. Es ist möglich, dies mit Leerzeichen zu tun, aber ich mag dies wie unten auf der Option Elemente mit einem margin-right tun:Option auswählen Rand rechts funktioniert nicht
select
{
padding: 10px;
width: 100%;
}
select{
border: 0;
appearance: none;
-moz-appearance: none;
-webkit-appearance: none;
cursor: pointer;
}
.select_category,
{
position: relative;
}
.select_category{
border-left: 2px solid red;
border-top: 2px solid red;
border-bottom: 2px solid red;
}
.select_category:before {
content: "\f0ca";
font-family: 'FontAwesome';
position: absolute;
left: 0;
font-size: 1em;
z-index: 1;
color: green;
padding: 15px 18px;
}
.select_category option{
margin-right:10px;
}
Aber es funktioniert nicht. Weißt du, warum?
Beispiel: https://jsfiddle.net/8bnu45u2/1/