LibWeb: Implement :enabled and :disabled pseudo classes to spec

Previously we only considered an element disabled if it was an <input>
element with the disabled attribute, but there's way more elements that
apply with more nuanced disabled/enabled rules.
This commit is contained in:
Luke Wilde 2022-09-30 16:21:34 +01:00 committed by Andreas Kling
parent c85fcd442f
commit 2133b7d58a
Notes: sideshowbarker 2024-07-17 06:32:16 +09:00
7 changed files with 82 additions and 10 deletions

View file

@ -26,6 +26,8 @@ public:
return fieldset;
}
bool is_disabled() const;
// ^FormAssociatedElement
// https://html.spec.whatwg.org/multipage/forms.html#category-listed
virtual bool is_listed() const override { return true; }