Accessibility Screen reader has different behavior on iPhone X

时间:2018-08-22 13:59:19

标签: ios xamarin xamarin.ios accessibility

I have webView and on LoadFinished method I'm invoking EvaluateJavascript for accessibility mode where it should focus the word or sentence in the web view content. The line of code below, works fine on every iOS device except iPhone X.

webView.EvaluateJavascript ("javascript: var element = document.getElementsByClassName('highlight'); setTimeout(function(){ element[0].focus(); }, 1500);");

The flow on iPhone X is: when screen is loaded instead of waiting 1.5 sec and then focus the element, element is focused immediate and then accessibility is focusing the first element of the screen (the button in the nav bar).

Could there be any difference in the accessibility screen reader on the iPhone X and the other iOS devices?

1 个答案:

答案 0 :(得分:0)

iPhoneX具有不同于其他iPhone的safeArea。您可以打开此链接以获取更多信息。iPhoneX safeArea

相关问题