You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But no matter what I do I cannot retrieve the content of that CSS rule; all I get back is the default style of display: block; unicode-bidi: embed applied to that element.
However, if I change the CSS style to be defined inline in test.html and remove the reference to test.css:
then pseudos["::before"].Style.CssText returns what I expect.
I assume I'm loading the stylesheet incorrectly somehow (although document.StyleSheets does return test.css), please can you advise what I'm doing wrong?
The text was updated successfully, but these errors were encountered:
IanKemp
changed the title
Pseudo-element style rules don't appear to be correctly computed
Pseudo-element style rules don't appear to be correctly read from external stylesheet
Jun 12, 2022
IanKemp
changed the title
Pseudo-element style rules don't appear to be correctly read from external stylesheet
Pseudo-element style rules don't appear to be read from external stylesheet
Jun 12, 2022
Please see project attached: AngleSharpCssPseudoTest.zip
In brief I have
test.css
with the following CSS rule defined:Then I have
test.html
that referencestest.css
with an element that uses the aforementioned rule:Finally I'm attempting to retrieve the rule definition as applied to the
.first
element via:But no matter what I do I cannot retrieve the content of that CSS rule; all I get back is the default style of
display: block; unicode-bidi: embed
applied to that element.However, if I change the CSS style to be defined inline in
test.html
and remove the reference totest.css
:then
pseudos["::before"].Style.CssText
returns what I expect.I assume I'm loading the stylesheet incorrectly somehow (although
document.StyleSheets
does returntest.css
), please can you advise what I'm doing wrong?The text was updated successfully, but these errors were encountered: