# Input focus scrolls wrongly

**URL:** <https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592>\
**Category:** ionic-v3\
**Created:** [January 27, 2017, 11:03am UTC](https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592 "2017-01-27T11:03:33Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![renannobile](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/renannobile/32/105995_2.png) [@renannobile](https://forum.ionicframework.com/u/renannobile)\
**Post date:** [January 27, 2017, 11:03am UTC](https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592/1 "2017-01-27T11:03:33Z")

</div>

I have several inputs in my app that when focused, make the screen scroll in an unexpected way.

Basically what’s happening is that when the input is focused and the keyboard appears, the whole screen is scrolled and the input goes offscreen.

In android, if I type something it then scrolls to the right place. I can reproduce the bug in ionic-lab but typing does not make it right.

\*In ionic-lab this only happens in the android platform.

Solved the problem with the following code:

```
        IonicModule.forRoot(MyApp, {
            tabsHideOnSubPages: true,
            scrollAssist: false, //this
            autoFocusAssist: false //and this
        })

        if (this.platform.is('android')) {
            Keyboard.disableScroll(true);
        }
```

---

<div class="post-metadata">

**Author:** ![mhartington](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/mhartington/32/137757_2.png) [@mhartington](https://forum.ionicframework.com/u/mhartington)\
**Post date:** [January 27, 2017, 6:05pm UTC](https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592/2 "2017-01-27T18:05:47Z")

</div>

Can you provide some markup for testing this?

---

<div class="post-metadata">

**Author:** ![renannobile](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/renannobile/32/105995_2.png) [@renannobile](https://forum.ionicframework.com/u/renannobile)\
**Post date:** [January 27, 2017, 7:33pm UTC](https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592/3 "2017-01-27T19:33:04Z")

</div>

This is my full html

```
{{clock | async | date:"HH:mm:ss"}} 
 Entrada Saída intervalo Retorno intervalo Saída Presença de posto Entrada Saída intervalo Retorno intervalo Saída Presença de posto Crachá: 
 Marcar horário 

### Marcações
 {{marca.Funcionario.FUNOME}} - {{marca.Funcionario.FUTIPOFU | tipouser}}   
 {{marca.Ponto.PT_DATA | date:"dd/MM/yyyy HH:mm:ss"}}

{{marca.Ponto.PT\_TIPO | tipoponto}}
```

---

<div class="post-metadata">

**Author:** ![mhartington](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/mhartington/32/137757_2.png) [@mhartington](https://forum.ionicframework.com/u/mhartington)\
**Post date:** [January 27, 2017, 7:54pm UTC](https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592/4 "2017-01-27T19:54:49Z")

</div>

Hmm, I’m seeing it scroll while in lab, but that is only meant to be a simulation of what an app would behave like in cordova-android.  
If you load outside of cordova, it should behave correctly.

---

<div class="post-metadata">

**Author:** ![renannobile](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/renannobile/32/105995_2.png) [@renannobile](https://forum.ionicframework.com/u/renannobile)\
**Post date:** [January 30, 2017, 11:00am UTC](https://forum.ionicframework.com/t/input-focus-scrolls-wrongly/77592/5 "2017-01-30T11:00:11Z")

</div>

The problem is that when I build and deploy to my android device, it scrolls twice, making the input go offscreen. That’s why I disabled defualt keyboard scrolling.

Also, why is it that only Android lab scrolls when input receives focus? It doesn’t happen with iOS or Windows.
