use of org.w3c.dom.html.HTMLTextAreaElement in project intellij-plugins by StepicOrg.
the class Elements method getInputValue.
@NotNull
String getInputValue(@NotNull String name) {
Node item = elements.namedItem(name);
String value = null;
if (item instanceof HTMLInputElement) {
value = ((HTMLInputElement) item).getValue();
} else if (item instanceof HTMLTextAreaElement) {
value = ((HTMLTextAreaElement) item).getValue();
}
return value != null ? value : "";
}
use of org.w3c.dom.html.HTMLTextAreaElement in project intellij-plugins by StepicOrg.
the class StepDescriptionUtils method disableAllInputs.
private static void disableAllInputs(@NotNull Elements elements) {
for (Node node : elements) {
if (node instanceof HTMLInputElement) {
HTMLInputElement element = (HTMLInputElement) node;
element.setDisabled(true);
} else if (node instanceof HTMLTextAreaElement) {
HTMLTextAreaElement element = (HTMLTextAreaElement) node;
element.setDisabled(true);
}
}
}
Aggregations