selenium icon indicating copy to clipboard operation
selenium copied to clipboard

[bot] Determine more reliably if node has shadow DOM

Open dlanza1 opened this issue 2 years ago • 2 comments

Description

node.shadowRoot might have an object assigned (some framework working with ShadyDOM does assign an object to node.shadowRoot), but it is no necessarily used by the browser as it must be constructed by ShadowRoot, otherwise is ignored.

Motivation and Context

Mechanisms like bot.dom.isShown() would determine an element is not shown because it believes it does not have parent.

Types of changes

  • [x] Bug fix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • [x] I have read the contributing document.
  • [ ] My change requires a change to the documentation.
  • [ ] I have updated the documentation accordingly.
  • [ ] I have added tests to cover my changes.
  • [x] All new and existing tests passed.

dlanza1 avatar Oct 25 '23 10:10 dlanza1

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Oct 25 '23 10:10 CLAassistant

So there are libraries using the shadow property to store an object only to be reified as a proper shadow object later? that's interesting.

isaulv avatar Nov 09 '23 03:11 isaulv