Giter Site home page Giter Site logo

Comments (9)

dg avatar dg commented on September 21, 2024

This is a Chrome issue that also affects Windows. The reason is that alert() loses focus.

Maybe it is related to https://developers.google.com/web/updates/2017/03/dialogs-policy

from forms.

dg avatar dg commented on September 21, 2024

@valekj what returns console.log(navigator.userAgentData) and console.log(!!HTMLDialogElement.prototype.showModal) in affected browsers?

from forms.

valekj avatar valekj commented on September 21, 2024

Hi, sorry for the delay.

Here are the console logs from android phone (s10e, android 11, chrome 92.0.4515.159):

console.log(navigator.userAgentData):
returns an object, however when I try to convert it to JSON, I just get an empty object, so here is a screenshot:

consolelog

console.log(!!HTMLDialogElement.prototype.showModal):
returns "true"

Chrome (92.0.4515.159) on Windows 10 does not seem to be affected on my end.

from forms.

dg avatar dg commented on September 21, 2024

Can you test that this netteForms.js works properly on Android?
https://github.com/nette/forms/tree/master/src/assets

from forms.

valekj avatar valekj commented on September 21, 2024

It focuses the input correctly now, however the dialog looks a bit weird:

scrshot

Also, would it be possible to target mobile Brave as well? Unfortunately it does not have any identification in Brands property.

brave

from forms.

dg avatar dg commented on September 21, 2024

I can target all mobile Chromium browsers.

Unfortunately I don't have Android and I don't know how to fix the design. Can you give it a try?

from forms.

valekj avatar valekj commented on September 21, 2024

It's nothing fancy, but what about this:

centereddialog

style.innerText = '.netteFormsModal { text-align: center; margin: auto; width: 80%; border: 1px solid #000; padding: 1rem; } .netteFormsModal button { padding: .1em 2em }';

from forms.

dg avatar dg commented on September 21, 2024

In the meantime, please add the style to your CSS file and we will tweak the resulting style over time.

from forms.

valekj avatar valekj commented on September 21, 2024

thank you!

from forms.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.