Fix iOS Safari sticky input
This commit is contained in:
parent
fc14a61abf
commit
260406a129
@ -4,6 +4,8 @@
|
||||
* https://github.com/morethanwords/tweb/blob/master/LICENSE
|
||||
*/
|
||||
|
||||
import { doubleRaf } from "../schedulers";
|
||||
|
||||
export default function fixSafariStickyInput(input: HTMLElement) {
|
||||
input.style.transform = 'translateY(-99999px)';
|
||||
/* input.style.position = 'fixed';
|
||||
@ -11,7 +13,8 @@ export default function fixSafariStickyInput(input: HTMLElement) {
|
||||
input.style.left = '0'; */
|
||||
input.focus();
|
||||
|
||||
setTimeout(() => {
|
||||
// setTimeout(() => {
|
||||
doubleRaf().then(() => {
|
||||
//fastSmoothScroll(findUpClassName(input, 'scrollable-y') || window as any, document.activeElement as HTMLElement, 'start', 4, undefined, FocusDirection.Static);
|
||||
/* input.style.position = '';
|
||||
input.style.top = ''; */
|
||||
@ -21,5 +24,6 @@ export default function fixSafariStickyInput(input: HTMLElement) {
|
||||
/* setTimeout(() => {
|
||||
fastSmoothScroll(findUpClassName(input, 'scrollable-y') || window as any, document.activeElement as HTMLElement, 'start', 4);
|
||||
}, 50); */
|
||||
}, 0);
|
||||
});
|
||||
// }, 0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user