1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-11 10:18:15 +09:00

LibWeb: Add select and option collection set length

This commit is contained in:
Bastiaan van der Plaat 2024-04-08 21:50:35 +02:00 committed by Andreas Kling
parent 4e5ce7b63e
commit 5c277144d8
Notes: sideshowbarker 2024-07-16 23:17:55 +09:00
8 changed files with 95 additions and 5 deletions

View file

@ -9,6 +9,7 @@
#include <AK/Variant.h>
#include <LibWeb/DOM/HTMLCollection.h>
#include <LibWeb/WebIDL/ExceptionOr.h>
#include <LibWeb/WebIDL/Types.h>
namespace Web::HTML {
@ -23,6 +24,8 @@ public:
[[nodiscard]] static JS::NonnullGCPtr<HTMLOptionsCollection> create(DOM::ParentNode& root, Function<bool(DOM::Element const&)> filter);
virtual ~HTMLOptionsCollection() override;
WebIDL::ExceptionOr<void> set_length(WebIDL::UnsignedLong);
WebIDL::ExceptionOr<void> add(HTMLOptionOrOptGroupElement element, Optional<HTMLElementOrElementIndex> before = {});
private: