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
As noted by @M-J-Robbins yesterday, this also happens when using any case other than lowercase. (So !iMpOrTaNt also triggers the <style> tag to be completely removed.)
Just wanted to look into this further - I looked up the CSS specification on how to 'consume a declaration' and it says:
If the last two non-whitespace-tokens in the declaration’s value are a delim-token with the value "!" followed by an ident-token with a value that is an ASCII case-insensitive match for "important", remove them from the declaration’s value and set the declaration’s important flag to true.
Reading the above !IMPORTANT is valid CSS. In the ASCII case-insensitive spec it states:
A string A is an ASCII case-insensitive match for a string B, if the ASCII lowercase of A is the ASCII lowercase of B.
Gmail removes any
<style>
tags or inlinestyle
attribute that contains an uppercase!IMPORTANT
declaration.The following code…
…is transformed by Gmail into the following :
As per CSS 2 specification, "all CSS syntax is case-insensitive".
This was discovered and reported by Sam Lewis on the Litmus forums.
The text was updated successfully, but these errors were encountered: