mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 16:18:12 +00:00
LibWeb: Add ol start and li value attributes support
This commit is contained in:
parent
d2fbc15f5d
commit
1cdbfc2ff1
10 changed files with 189 additions and 16 deletions
|
@ -20,6 +20,12 @@ public:
|
|||
// https://www.w3.org/TR/html-aria/#el-li
|
||||
virtual Optional<ARIA::Role> default_role() const override { return ARIA::Role::listitem; }
|
||||
|
||||
i32 value() { return get_attribute(AttributeNames::value).value_or("0"_string).to_number<i32>().value_or(0); }
|
||||
void set_value(i32 value)
|
||||
{
|
||||
set_attribute(AttributeNames::value, MUST(String::number(value))).release_value_but_fixme_should_propagate_errors();
|
||||
}
|
||||
|
||||
private:
|
||||
HTMLLIElement(DOM::Document&, DOM::QualifiedName);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue