Skip to content

[πŸ› Bug]: elementToBeClickable wait condition fails on elements with opacity 0Β #15025

@ysiivan

Description

@ysiivan

What happened?

The condition to evaluate the "clickability" of an element considers whether the element is Displayed, which does not regard elements with an opacity of 0 as Displayed.

The proposal in the closed 14030 was to make Displayed disregard the opacity. I understand the arguments on both sides. However at the end of the day, the actual problem is still not resolved - waiting for "clickability", as it is now, is unreliable. The original post was about React, I just encounter the issue in an Angular app. Clickjacking or not, it seems the technique is apparently being used. I can't judge whether this is a right or a wrong way of doing things, but so should not Selenium.

All this aside - the bottom line is - opacity does not play a role in "clickability".

If Displayed is to stay as it is, then how can we properly ascertain "clickability"?
I'm not the best at reading minified javascripts, but it seems is-displayed.js "atom" is already wired to take an optional parameter for ignoring opacity. Perhaps expose a way to use that?

How can we reproduce the issue?

Have an element with opacity 0 and try to wait for it to become clickable.

Relevant log output

N/A

Operating System

N/A

Selenium version

N/A

What are the browser(s) and version(s) where you see this issue?

Chrome

What are the browser driver(s) and version(s) where you see this issue?

130.x.x.x

Are you using Selenium Grid?

No

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-needs-triagingA Selenium member will evaluate this soon!I-defectSomething is not working as intendedJ-issue-templateApplied to issues not following the template, or missing information.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions