/* * Copyright (c) 2022-2023, Sam Atkins * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include namespace Web::CSS { class InheritStyleValue final : public StyleValueWithDefaultOperators { public: static ErrorOr> the() { static ValueComparingNonnullRefPtr instance = TRY(adopt_nonnull_ref_or_enomem(new (nothrow) InheritStyleValue)); return instance; } virtual ~InheritStyleValue() override = default; ErrorOr to_string() const override { return "inherit"_string; } bool properties_equal(InheritStyleValue const&) const { return true; } private: InheritStyleValue() : StyleValueWithDefaultOperators(Type::Inherit) { } }; }