mui 页面,在IOS手机上测试,左右滑动会飞掉,Android正常,是怎么回事呢?

发布于 2022-09-06 02:44:46 字数 7634 浏览 15 评论 0

在IOS手机上测试,左右滑动页面,会飞掉,正常情况是不可以左右滑动的。在Android手机上测试是正常的,不会因为左右滑动而乱掉。
在IOS手机上测试时,左右滑动,整个页面会移动50%左右,正常情况是左右滑动时,页面是不会动的,只可以上下滑动。
图片描述

<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
        <meta name="format-detection" content="telphone=no, email=no" />
        <meta name="renderer" content="webkit">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
        <meta name="description" content="Anviz Biometric manufactures a complete range of biometric products including fingerprint time attendance, fingerprint access control, fingerprint lock, USB fingerprint reader, OEM fingerprint module etc.">
        <meta name="keywords" content="Fingerprint Time attendance, Fingerprint Access Control, Time attendance,Access Control, Smart Lock,Software &amp; SDK, OEM Moudle,Surveillance">
        <title>PRODUCTS</title>
        <link rel="shortcut icon" href="img/logo/favicon.ico" type="image/x-icon" />
        <link rel="icon" href="img/logo/favicon.ico" type="image/x-icon" />
        <link href="css/mui.css" rel="stylesheet" />
        <link rel="stylesheet" type="text/css" href="css/my_anviz.css" />
        <link rel="stylesheet" type="text/css" href="fonts/iconfont.css" />
        <script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
        <script src="js/mui.min.js"></script>
        <script src="js/mui.pullToRefresh.js"></script>
        <script src="js/pub/tab_bar.js"></script>
        <script src="js/productor/productor.js"></script>
    </head>
    <body>
        <div class="anviz-loading" style="display: none;">
            <div class="spinner">
                <div class="spinner-container container1">
                    <div class="circle1"></div>
                    <div class="circle2"></div>
                    <div class="circle3"></div>
                    <div class="circle4"></div>
                </div>
                <div class="spinner-container container2">
                    <div class="circle1"></div>
                    <div class="circle2"></div>
                    <div class="circle3"></div>
                    <div class="circle4"></div>
                </div>
                <div class="spinner-container container3">
                    <div class="circle1"></div>
                    <div class="circle2"></div>
                    <div class="circle3"></div>
                    <div class="circle4"></div>
                </div>
            </div>
        </div>
        <div class="mui-content">
            <!--header-->
            <header class="mui-bar mui-bar-nav">
                <a id="homeBack" class="iconfont icon-home icon-color mui-icon mui-icon-left-nav mui-pull-right" style="display: none;"></a>
                <h1 id="homeTitle" class="mui-title icon-color">PRODUCTS</h1>
            </header>
            <!--products-->
            <div id="productorContent" class="mui-slider-group roleRight anviz-animation anviz-content js-container">
                <div id="products" class="mui-slider-item anviz-content">
                    <!--label-->
                    <ul class="mui-table-view mui-grid-view mui-grid-9">
                        <li class="mui-table-view-cell mui-media mui-col-xs-6 mui-col-sm-6">
                            <h5 class="anviz-padded">Product</h5>
                        </li>
                        <li class="mui-table-view-cell mui-media mui-col-xs-6 mui-col-sm-6"></li>
                    </ul>
                    <!--产品列表-->
                    <ul id="productList" class="mui-table-view mui-table-view-chevron js-productor">
                        <li class="mui-table-view-cell mui-media js-media">
                            <div class="pro-pannel">
                                <img class="mui-media-object mui-pull-left js-img js-pro-img" src="">
                                <div class="mui-media-body js-media-body">
                                    <p class="anviz-ellipsis js-des js-pro-des"></p>
                                </div>
                            </div>
                        </li>
                    </ul>
                    <!--label-->
                    <ul class="mui-table-view mui-grid-view mui-grid-9">
                        <li class="mui-table-view-cell mui-media mui-col-xs-6 mui-col-sm-6">
                            <h5 class="anviz-padded">Solution</h5>
                        </li>
                        <li class="mui-table-view-cell mui-media mui-col-xs-6 mui-col-sm-6"></li>
                    </ul>
                    <ul id="solutionList" class="mui-table-view mui-table-view-chevron js-solution">
                        <li id="SecurityONE" class="mui-table-view-cell mui-media js-media">
                            <a href="javascript:;">
                                <img class="mui-media-object mui-pull-left js-img js-soul-img" src="">
                                <div class="mui-media-body js-media-body">
                                    <p class="anviz-ellipsis js-des js-solu-des"></p>
                                </div>
                            </a>
                        </li>
                    </ul>
                </div>
            </div>
            <!--bottom nav-->
            <nav class="mui-bar mui-bar-tab anviz-bar-bottom">
                <a id="home" class="mui-tab-item" href="home.html">
                    <span class="mui-icon iconfont icon-home"></span>
                    <span class="mui-tab-label">HOME</span>
                </a>
                <a id="support" class="mui-tab-item" href="support.html">
                    <span class="mui-icon iconfont icon-support"></span>
                    <span class="mui-tab-label">SUPPORT</span>
                </a>
                <a id="porductor" class="mui-tab-item mui-active" href="productor.html">
                    <span class="mui-icon iconfont icon-product"></span>
                    <span class="mui-tab-label">PRODUCTS</span>
                </a>
                <a id="me" class="mui-tab-item" href="me.html">
                    <span class="mui-icon iconfont icon-profile"></span>
                    <span class="mui-tab-label">LOGIN</span>
                </a>
            </nav>
        </div>
        <script type="text/javascript" charset="utf-8">
            mui.init({
                
            });
        </script>
    </body>
</html>

同样的一套代码,为什么在IOS手机上会出问题?我应该怎么改?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

苏别ゝ 2022-09-13 02:44:46

很可能是你该页面中的某些元素超出屏幕宽度.

建议你打开调试排查下页面.

木落 2022-09-13 02:44:46

第一,可能你没有设置view-port属性,第二,屏蔽掉其他地方的touchmove事件,第三,禁用掉popgesture属性,苹果的这个不要了

带上头具痛哭 2022-09-13 02:44:46

我之前也遇到过这样的情况,我当时除了加了viewport,然后把最外层的宽度设为100%就好了。
你的初始化的css没贴出来,看不真切,先试试吧,或者截一下css

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文