/* * Copyright (c) 2022, sin-ack * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include #include #include #include namespace Web::Layout { class FormAssociatedLabelableNode : public LabelableNode { JS_CELL(FormAssociatedLabelableNode, LabelableNode); public: const HTML::FormAssociatedElement& dom_node() const { return dynamic_cast(LabelableNode::dom_node()); } HTML::FormAssociatedElement& dom_node() { return dynamic_cast(LabelableNode::dom_node()); } protected: FormAssociatedLabelableNode(DOM::Document& document, HTML::FormAssociatedElement& element, NonnullRefPtr style) : LabelableNode(document, element.form_associated_element_to_html_element(), move(style)) { } virtual ~FormAssociatedLabelableNode() = default; }; }