Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-137194

Label transform on `:focus-within` never runs in Qt browser until CSS is re-applied

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • 6.9.0
    • WebEngine
    • None
    • Windows
    • 0e01f0372 (130-based)

      A CSS animation (using transform with a transition) is defined on the container’s :focus-within state to “float” and shrink the <label> when its corresponding <input> gains focus. In a Qt-based browser:

      • The focus state is correctly detected (the CSS rule appears in DevTools).
      • The style is updated (you can see the new transform in the inspector).
      • However, the animation never actually runs, so the label remains static.

      Only after opening DevTools and making any edit to the CSS (which forces a style refresh) does the animation finally trigger. In mainstream browsers (Chrome, Firefox, Safari), the transform/animation applies immediately on first focus without any manual CSS re-application.

       

      Steps to reproduce:

      • Open the attached file `focus-within-bug.html` in a Qt-based browser.
      • Click into the text input, observe the label remains in its original position; no animation fires.
      • Open DevTools, modify any character in the <style> block, then close DevTools.
      • Click the input again, observer the label animates as expected (shrinks and floats).

       

      Environment:

      • OS: Windows
      • This bug could be reproduced with Example Qt Browser (Qt WebEngine 6.9.0)
      • This bug could not be reproduced with both Chromium 130.0.6723.192 and 133.0.6943.141 (the base and security versions declared by Qt 6.9) on Windows

       

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kchehlarski Kaloyan Chehlarski
            gerald_li Gerald Li
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes