Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在iframe中 失效 #9

Open
zengzhan opened this issue Sep 6, 2017 · 1 comment
Open

在iframe中 失效 #9

zengzhan opened this issue Sep 6, 2017 · 1 comment

Comments

@zengzhan
Copy link

zengzhan commented Sep 6, 2017

iframe.html 测试样例 在pc端显示正常 但是移动手机端 ios android 不正常 图片位置不正确 和按钮不见
index.html 是 原来例子

<title>AlloyCrop ifrmae test</title> <style> * { padding: 0; margin: 0; } body { width: 100%; height: 100%; } .sf-container { position: absolute; left: 0; top: 0; z-index: 100000; height: 100%; width: 100%; background-color: #f5f5f5; color: #fff; -webkit-backface-visibility: hidden; } .sf-frame { display: block; position: relative; z-index: 1; -webkit-tap-highlight-color: rgba(0,0,0,0); width: 100%; height: 100%; background-color: #f5f5f5; -webkit-transform: translateZ(0); -moz-transform: translateZ(0); -ms-transform: translateZ(0); -o-transform: translateZ(0); transform: translateZ(0); -webkit-touch-callout: none; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; -webkit-text-size-adjust: none; -moz-text-size-adjust: none; -ms-text-size-adjust: none; -o-text-size-adjust: none; text-size-adjust: none; } .sf-frame iframe { background-color: #f5f5f5; border: 0; display: block; width: 100%; height: 100%; -webkit-overflow-scrolling: touch; overflow: visible; overflow-y: scroll; } </style>
<iframe id="mp-f" name="mp-f" src="index.html" scrolling="yes" style="height: 100%; display: block;">"</iframe>
@dntzhang
Copy link

dntzhang commented Sep 6, 2017

为啥要放到iframe里啊~ 可能跟这个有关

https://github.com/AlloyTeam/AlloyCrop/blob/master/alloy-crop.js#L30-L31

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants