Created
September 19, 2014 18:57
-
-
Save alice-liu/bd49490642934f683de5 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="hello-example"> | |
<a href="http://example.com">English:</a> | |
<span lang="en-us en-gb en-au en-nz">Hello World!</span> | |
</div> | |
<div class="hello-example"> | |
<a href="#portuguese">Portuguese:</a> | |
<span lang="pt">Olá Mundo!</span> | |
</div> | |
<div class="hello-example"> | |
<a href="http://example.cn">Chinese (Simplified):</a> | |
<span lang="zhCN">世界您好!</span> | |
</div> | |
<div class="hello-example"> | |
<a href="http://example.cn">Chinese (Traditional):</a> | |
<span lang="zh-TW">世界您好!</span> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ---- | |
// Sass (v3.3.14) | |
// Compass (v1.0.0) | |
// ---- | |
/* All spans with a "lang" attribute are bold */ | |
span[lang] {font-weight:bold;} | |
/* All spans in Portuguese are green */ | |
span[lang="pt"] {color:green;} | |
/* All spans in US English are blue */ | |
span[lang~="en-us"] {color: blue;} | |
/* Any span in Chinese is red, matches simplified (zh-CN) or traditional (zh-TW) */ | |
span[lang|="zh"] {color: red;} | |
/* All internal links have a gold background */ | |
a[href^="#"] {background-color:gold} | |
/* All links to urls ending in ".cn" are red */ | |
a[href$=".cn"] {color: red;} | |
/* All links to with "example" in the url have a grey background */ | |
a[href*="example"] {background-color: #CCCCCC;} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* All spans with a "lang" attribute are bold */ | |
span[lang] { | |
font-weight: bold; | |
} | |
/* All spans in Portuguese are green */ | |
span[lang="pt"] { | |
color: green; | |
} | |
/* All spans in US English are blue */ | |
span[lang~="en-us"] { | |
color: blue; | |
} | |
/* Any span in Chinese is red, matches simplified (zh-CN) or traditional (zh-TW) */ | |
span[lang|="zh"] { | |
color: red; | |
} | |
/* All internal links have a gold background */ | |
a[href^="#"] { | |
background-color: gold; | |
} | |
/* All links to urls ending in ".cn" are red */ | |
a[href$=".cn"] { | |
color: red; | |
} | |
/* All links to with "example" in the url have a grey background */ | |
a[href*="example"] { | |
background-color: #CCCCCC; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="hello-example"> | |
<a href="http://example.com">English:</a> | |
<span lang="en-us en-gb en-au en-nz">Hello World!</span> | |
</div> | |
<div class="hello-example"> | |
<a href="#portuguese">Portuguese:</a> | |
<span lang="pt">Olá Mundo!</span> | |
</div> | |
<div class="hello-example"> | |
<a href="http://example.cn">Chinese (Simplified):</a> | |
<span lang="zhCN">世界您好!</span> | |
</div> | |
<div class="hello-example"> | |
<a href="http://example.cn">Chinese (Traditional):</a> | |
<span lang="zh-TW">世界您好!</span> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment