mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:17:35 +00:00
LibWeb: Implement CSSStyleRule::set_selector_text()
This commit is contained in:
parent
0f88a47e58
commit
df85832f32
1 changed files with 7 additions and 6 deletions
|
@ -5,6 +5,7 @@
|
|||
*/
|
||||
|
||||
#include <LibWeb/CSS/CSSStyleRule.h>
|
||||
#include <LibWeb/CSS/Parser/Parser.h>
|
||||
|
||||
namespace Web::CSS {
|
||||
|
||||
|
@ -333,14 +334,14 @@ String CSSStyleRule::selector_text() const
|
|||
// https://drafts.csswg.org/cssom/#dom-cssstylerule-selectortext
|
||||
void CSSStyleRule::set_selector_text(StringView selector_text)
|
||||
{
|
||||
// FIXME: 1. Run the parse a group of selectors algorithm on the given value.
|
||||
// 1. Run the parse a group of selectors algorithm on the given value.
|
||||
auto parsed_selectors = parse_selector({}, selector_text);
|
||||
|
||||
// FIXME: 2. If the algorithm returns a non-null value replace the associated group of selectors with the returned value.
|
||||
// 2. If the algorithm returns a non-null value replace the associated group of selectors with the returned value.
|
||||
if (parsed_selectors.has_value())
|
||||
m_selectors = parsed_selectors.release_value();
|
||||
|
||||
// FIXME: 3. Otherwise, if the algorithm returns a null value, do nothing.
|
||||
|
||||
(void)selector_text;
|
||||
TODO();
|
||||
// 3. Otherwise, if the algorithm returns a null value, do nothing.
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue