I have a button that is enabled when I choose a value in a picker.
The html code states that aria-disabled="false" when i pick av value in the picker.
<button id="form:panel:j_idt188" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only btn btn-primary col-md-12 selectContext7" data-aft="selectLevel7" type="submit" onclick="PrimeFaces.ab({s:"form:panel:j_idt188",u:"form:kontekstvelger"});return false;" name="form:panel:j_idt188" role="button" aria-disabled="false"
How can I code that the selenium script should wait for the aria-disabled="false"
to be false (It is true when I enter the page and before I have chosen a value in the picker.
From before I have this code to wait for elements:
WebElement myDynamicElement = (new WebDriverWait(driver, 10)).until(ExpectedConditions.presenceOfElementLocated(By.id("nyid")));
But how can I write this code above to be waiting for aria-disabled to be false?