PhoneGap的构建WebKit的外观没有下拉箭头选择为标签 [英] PhoneGap build webkit-appearance no drop down arrow for select tag
问题描述
我使用的PhoneGap构建和我的选择标记具有手机上没有下拉箭头。
我试着将 -webkit-外观:菜单列表;
但这并没有帮助,我试过其他的选择,但仍然只是展示了一个没有下拉箭头,选择
I'm using PhoneGap build and my select tags have no dropdown arrow on the phone.
I tried applying -webkit-appearance: menulist;
but this doesn't help, I tried other choices but still just shows the option with no drop down arrow.
这与PhoneGap的一个问题,因为在同一code显示在我的Android手机上的本地浏览器一个下拉箭头。
It an issue with PhoneGap because the same code shows a dropdown arrow on the native browser on my Android phone.
只有一次,我用的PhoneGap构建并箭头消失。任何解决方案?
Only once I use PhoneGap build does the arrow disappear. Any solutions?
推荐答案
的Android浏览器的渲染<选择>
s是越野车,将删除正常的造型,如果背景或边框应用。
The Android Browser's rendering of <select>
s is buggy and will remove the normal styling if a background or border is applied.
由于&LT;选择&GT;
不是看起来像&LT;选择&GT;
s是pretty大可用性问题,最好的办法就是不要他们的风格只有这个浏览器。
Since <select>
s not looking like <select>
s is a pretty big usability issue, your best bet is to not style them for this browser only.
不幸的是,有选择/不包括Android浏览器没有纯CSS方法,所以我建议你使用布局引擎(的 https://github.com/stowball/Layout-Engine ),这将一类的补充.browser功能的Android
到&LT; HTML方式&gt;
标签
Unfortunately, there's no pure CSS way of selecting/excluding the Android Browser, so I recommend you use Layout Engine (https://github.com/stowball/Layout-Engine), which will add a class of .browser-android
to the <html>
tag.
您可以再样式的所有&LT;选择&GT;
取值除了在Android浏览器,像这样:
You could then style all <select>
s except on Android Browser, like so:
html:not(.browser-android) select {
background: #0f0;
border: 1px solid #ff0;
}
这篇关于PhoneGap的构建WebKit的外观没有下拉箭头选择为标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!