Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#16548 closed defect (fixed)

Dialog: fields scroll out of view when virtual keyboard pops up (mobile devices)

Reported by: bill Owned by: bill
Priority: undecided Milestone: 1.7.5
Component: Dijit Version: 1.0
Keywords: Cc: Adrian Vasiliu, cjolif, Douglas Hays
Blocked By: Blocking:

Description

Load dijit/tests/mobile.html on iOS6, click the "Dialog" button, and touch (to focus) one of the last few fields. As the keyboard pops up, the is no longer visible.

I think this worked in iOS5 but I don't have a version to check against anymore.

See also #16202, although that says it happens when you type the first character, whereas this problem happens before typing anything.

Change History (6)

comment:1 Changed 7 years ago by bill

Cc: Adrian Vasiliu cjolif Douglas Hays added
Milestone: tbd1.8.4
Status: newassigned

When the keyboard pops up it's generating both a scroll event, caught by Dialog.js, and a viewport resize event, caught by _ContentpaneResizeMixin.js. Both of those events cause the Dialog to try to recenter itself, causing the problem.

A workaround is for existing apps is:

require(["dijit/Dialog"], function(Dialog){
        Dialog.prototype.resize = function(){
                if(this.domNode.style.display != "none"){
                        this._size();
                        // this._position();
                }
        };
});

comment:2 Changed 7 years ago by bill

Resolution: fixed
Status: assignedclosed

In [30325]:

Disable scrolling adjustment for touch devices since it interferes with the automatic scrolling when the pop-up virtual keyboard is displayed, fixes #16548 !strict on trunk.

comment:3 Changed 7 years ago by bill

In [30326]:

Disable scrolling adjustment for touch devices since it interferes with the automatic scrolling when the pop-up virtual keyboard is displayed, fixes #16548 !strict on 1.8 branch.

comment:4 Changed 7 years ago by bill

Summary: Dialog: fields scroll out of view on focus (iOS6)Dialog: fields scroll out of view on focus (mobile devices)

comment:5 Changed 7 years ago by bill

In [30335]:

Don't try to reposition Dialog on a resize or scroll event from mobile browsers, fixes #16548 on 1.7 branch !strict.

comment:6 Changed 7 years ago by bill

Milestone: 1.8.41.7.5
Summary: Dialog: fields scroll out of view on focus (mobile devices)Dialog: fields scroll out of view when virtual keyboard pops up (mobile devices)
Version: 1.8.31.0
Note: See TracTickets for help on using tickets.