Descendant selector AND general sibling selector with curly bracket in new line causes error
GitHub Issue:
https://github.com/openstyles/stylus/issues/1730
Authorwykopchanger
LicenseNo License
Categorygoogle.com
Created
Updated
Size1.6 kB
Learn how we calculate statistics in the FAQ.
Failed to fetch stats.
Descendant selector AND general sibling selector with curly bracket in new line causes error
GitHub Issue:
https://github.com/openstyles/stylus/issues/1730
/* ==UserStyle==
@name Descendant selector AND general sibling selector with curly bracket in new line causes error
@version 1
@preprocessor stylus
@namespace userstyles.world/user/test2
@license No License (YOU CAN USE THIS CODE ONLY IN STYLUS EXTENSIONS. You are not allowed to: copy any part of the code, share, and use it anywhere)
==/UserStyle== */
@-moz-document url-prefix("https://google.com")
{
// descendant selector with opening curly bracket in new line
// THIS PRODUCES AN ERROR "Cannot read properties of undefined (reading 'block')"
/*
div small
{
font-size: 0.7em;
}
*/
// general sibling selector with curly bracket in new line
// THIS PRODUCES AN ERROR "Cannot read properties of undefined (reading 'block')"
/*
div ~ small
{
font-size: 0.7em;
}
*/
// child selector DOES NOT PRODUCE AN ERROR
div > small
{
font-size: 0.7em;
}
// adjacent sibling selector DOES NOT PRODUCE AN ERROR
div + small
{
font-size: 0.7em;
}
// element selector DOES NOT PRODUCE AN ERROR
div
{
font-size: 0.7em;
}
// descendant selector with opening curly bracket in the same line
// DOES NOT PRODUCE AN ERROR
div small {
font-size: 0.7em;
}
// general sibling selector with opening curly bracket in the same line
// DOES NOT PRODUCE AN ERROR
div ~ small {
font-size: 0.7em;
}
}