var u = navigator.userAgent;
var isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
if(isiOS){
}else{
}
<script>
var html = document.getElementsByTagName("html")[0];
var width = window.innerWidth;
var fontSize = (100 / 750) * width;
if (fontSize > 100) {
fontSize = 100;
}
html.style.fontSize = fontSize + "px";
window.onresize = function() {
var html = document.getElementsByTagName("html")[0];
var width = window.innerWidth;
var fontSize = (100 / 750) * width;
if (fontSize > 100) {
fontSize = 100;
}
html.style.fontSize = fontSize + "px";
};
</script>
.border{
positon:relative
}
.border:after{
content: " ";
width: 200%;
height: 200%;
position: absolute;
top: 0;
left: 0;
border: 1px solid rgba(0,0,0,.2);
-webkit-transform: scale(.5);
transform: scale(.5);
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
box-sizing: border-box;
border-radius: 10px;
}
<input name="member_phone" type="number" pattern='[0-9]*'>
<style>
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
-webkit-appearance: none;
}
input[type="number"]{
-moz-appearance: textfield;
}
</style>
<style>
body{
cursor:pointer;
}
</style>
document.body.addEventListener('focusin', () => {
console.log("键盘弹起")
})
document.body.addEventListener('focusout', () => {
console.log("键盘收起")
})