2020-01-18 09:38:21 +01:00
|
|
|
/*
|
2024-10-04 13:19:50 +02:00
|
|
|
* Copyright (c) 2018-2020, Andreas Kling <andreas@ladybird.org>
|
2020-01-18 09:38:21 +01:00
|
|
|
*
|
2021-04-22 01:24:48 -07:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-01-18 09:38:21 +01:00
|
|
|
*/
|
|
|
|
|
2019-10-12 13:47:49 +02:00
|
|
|
#pragma once
|
|
|
|
|
2020-07-26 15:08:16 +02:00
|
|
|
#include <LibWeb/HTML/HTMLElement.h>
|
2019-10-12 13:47:49 +02:00
|
|
|
|
2020-07-28 18:20:36 +02:00
|
|
|
namespace Web::HTML {
|
2020-03-07 10:27:02 +01:00
|
|
|
|
2019-10-12 13:47:49 +02:00
|
|
|
class HTMLBRElement final : public HTMLElement {
|
2022-08-28 13:42:07 +02:00
|
|
|
WEB_PLATFORM_OBJECT(HTMLBRElement, HTMLElement);
|
2024-11-15 04:01:23 +13:00
|
|
|
GC_DECLARE_ALLOCATOR(HTMLBRElement);
|
2020-07-27 05:04:26 +01:00
|
|
|
|
2022-08-28 13:42:07 +02:00
|
|
|
public:
|
2019-10-12 13:47:49 +02:00
|
|
|
virtual ~HTMLBRElement() override;
|
|
|
|
|
2024-12-20 11:32:17 +01:00
|
|
|
virtual GC::Ptr<Layout::Node> create_layout_node(CSS::ComputedProperties) override;
|
|
|
|
virtual void adjust_computed_style(CSS::ComputedProperties&) override;
|
2022-08-28 13:42:07 +02:00
|
|
|
|
|
|
|
private:
|
2023-09-01 09:55:56 +02:00
|
|
|
virtual bool is_html_br_element() const override { return true; }
|
|
|
|
|
2022-08-28 13:42:07 +02:00
|
|
|
HTMLBRElement(DOM::Document&, DOM::QualifiedName);
|
2023-01-10 06:28:20 -05:00
|
|
|
|
2023-08-07 08:41:28 +02:00
|
|
|
virtual void initialize(JS::Realm&) override;
|
2019-10-12 13:47:49 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
2023-09-01 09:55:56 +02:00
|
|
|
|
|
|
|
namespace Web::DOM {
|
|
|
|
template<>
|
|
|
|
inline bool Node::fast_is<HTML::HTMLBRElement>() const { return is_html_br_element(); }
|
|
|
|
}
|