Solution for “Shadow-root” elements, for example some “accept cookies” pages:
To treat these elements we need to use the executeJavascript function, for example:
Document.getElementById(“usercentrics-root”).shadowRoot.querySelector(“[data-testid=uc-accept-all-button]”).click();
The steps to follow are the following: