Gau*_*rav 6 html css css3 angularjs ionic-framework
预定义的电话功能:当我们专注于任何输入时,它将自动滚动到移动设备中的该输入.
问题:它不能在我的离子应用程序中工作,因为水平滚动也在那里,所以当我点击移动设备中的输入时,它不会自动滚动到该输入并且输入隐藏在键盘后面.
我试过delegate-handle这个,但它不起作用.
同样的 Plunker
HTML
<ion-scroll direction="xy" class="scroll" delegate-handle="nomineeDiv">
<div class="table-row" ng-repeat="data in nominee"><!-- Multiple div show horizontally -->
<form name="data.formName">
<!-- Long vertical form
.....
.....
after 4 input tags -->
<input type="text" name="something"/>
<!-- Need to scroll to input when input focused -->
</form>
</div>
</ion-scroll>
Run Code Online (Sandbox Code Playgroud)
调节器
$ionicScrollDelegate.$getByHandle('nomineeDiv').scrollBy(580, 140, true);
Run Code Online (Sandbox Code Playgroud)