/* * Copyright (c) 2026, Callum Law * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include namespace Web::CSS { class CounterStyleStyleValue : public StyleValueWithDefaultOperators { public: static ValueComparingNonnullRefPtr create(FlyString name) { return adopt_ref(*new (nothrow) CounterStyleStyleValue(move(name))); } virtual ~CounterStyleStyleValue() override = default; virtual void serialize(StringBuilder&, SerializationMode) const override; Optional to_counter_style_name_keyword() const; Optional resolve_counter_style(HashMap const& registered_counter_styles) const; bool properties_equal(CounterStyleStyleValue const& other) const { return m_name == other.m_name; } private: explicit CounterStyleStyleValue(FlyString name) : StyleValueWithDefaultOperators(Type::CounterStyle) , m_name(move(name)) { } FlyString m_name; }; }