1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 18:18:12 +00:00

LibWeb: Move/rename StyleFunctionRule to Parser::Function

This commit is contained in:
Sam Atkins 2022-04-12 13:35:55 +01:00 committed by Andreas Kling
parent 084780a0a2
commit e0b2ebcc7b
11 changed files with 59 additions and 58 deletions

View file

@ -1,38 +0,0 @@
/*
* Copyright (c) 2020-2021, the SerenityOS developers.
* Copyright (c) 2021-2022, Sam Atkins <atkinssj@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <LibWeb/CSS/Parser/StyleFunctionRule.h>
#include <LibWeb/CSS/Serialize.h>
namespace Web::CSS {
StyleFunctionRule::StyleFunctionRule(String name)
: m_name(move(name))
{
}
StyleFunctionRule::StyleFunctionRule(String name, Vector<Parser::ComponentValue>&& values)
: m_name(move(name))
, m_values(move(values))
{
}
StyleFunctionRule::~StyleFunctionRule() = default;
String StyleFunctionRule::to_string() const
{
StringBuilder builder;
serialize_an_identifier(builder, m_name);
builder.append("(");
builder.join(" ", m_values);
builder.append(")");
return builder.to_string();
}
}