mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 01:17:35 +00:00
LibWeb: Implement RadioNodeList
This interface is used in the interface for HTMLFormControlsCollection as a live view over its matching elements. Currently the "value" attribute for this interface is left unimplemented.
This commit is contained in:
parent
c2bf391f81
commit
daefe744ba
7 changed files with 73 additions and 1 deletions
29
Userland/Libraries/LibWeb/DOM/RadioNodeList.h
Normal file
29
Userland/Libraries/LibWeb/DOM/RadioNodeList.h
Normal file
|
@ -0,0 +1,29 @@
|
|||
/*
|
||||
* Copyright (c) 2023, Shannon Booth <shannon@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <LibWeb/DOM/LiveNodeList.h>
|
||||
|
||||
namespace Web::DOM {
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/common-dom-interfaces.html#radionodelist
|
||||
class RadioNodeList : public LiveNodeList {
|
||||
WEB_PLATFORM_OBJECT(RadioNodeList, LiveNodeList);
|
||||
|
||||
public:
|
||||
[[nodiscard]] static JS::NonnullGCPtr<RadioNodeList> create(JS::Realm& realm, Node& root, Scope scope, Function<bool(Node const&)> filter);
|
||||
|
||||
virtual ~RadioNodeList() override;
|
||||
|
||||
protected:
|
||||
virtual void initialize(JS::Realm&) override;
|
||||
|
||||
private:
|
||||
explicit RadioNodeList(JS::Realm& realm, Node& root, Scope scope, Function<bool(Node const&)> filter);
|
||||
};
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue