In vuejs2 app having select input with rather big options list it breaks design of my page on extra small devices. Searching in net I found “size” property, but that not what I I need : I want to have dropdown selection, which is the default. Are there some other decision, maybe with CSS to set max-height of dropdown selection area.
Modeified PART # 1: I made testing demo page at http://photographers.my-demo-apps.tk/sel_test it has 2 select inputs with custom design and events as in this example link How to Set Height for the Drop Down of Select box and following workaround at js fiddle:
select{
color: red;
}
<select onfocus='this.size=10;' onblur='this.size=1;' onchange='this.size=1; this.blur();'>
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
<option>6</option>
<option>7</option>
<option>8</option>
<option>9</option>
<option>10</option>
<option>11</option>
<option>12</option>
<option>13</option>
<option>14</option>
<option>15</option>
<option>16</option>
<option>17</option>
<option>18</option>
<option>19</option>
<option>20</option>
<option>21</option>
</select>
<div>Popular Tags:</div>
are applied to the second select input and it does not look/work properly. I suppose it conflicts somehow with current desing. Can it be fixed somehow?
as that is vuejs2 page I know that there are some select components at https://github.com/vuejs/awesome-vue#select and I used some of them, like vue-select but I need to keep custom design so I try to use original select input...
Modified PART # 2 : I added 2 classes definitions :
.select-wrapper {
height: 50px !important;
overflow-y: visible !important;
background-color: yellow !important;
}
.select {
width: 100% !important;
/* make it min-height*/
min-height: 50px !important;
border-radius: 25px !important;
border-color: #555 !important;
padding: 10px !important;
border:2px dotted red !important;
}
Also I set background-color and border to these classes to be sure that these classes are applied and !important to all properties. But it did not help. Could you please to take a look!
Thank you!