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
/** | |
* :lang() parsing | |
*/ | |
:lang(en) { border: 2px solid blue } |
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
/** | |
* The first commented line is your dabblet’s title | |
*/ | |
background: accentColor linear-gradient(to right, color-mix(in oklab, accentColor, white) 50%, accentColor 0); | |
border: 10px color-mix(in oklab, accentColor, black 20%) solid; | |
height: 100vh; |
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
function getAllProperties(obj){ | |
var allProps = [] | |
, curr = obj | |
do{ | |
var props = Object.getOwnPropertyNames(curr) | |
props.forEach(function(prop){ | |
if (allProps.indexOf(prop) === -1) | |
allProps.push(prop) | |
}) | |
}while(curr = Object.getPrototypeOf(curr)) |
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
/* Test for discrete animations */ | |
@keyframes discrete { | |
from { --background: lime } | |
to { --background: green } | |
} | |
body { | |
background: var(--background, red); | |
animation: 2s discrete infinite linear; |
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
/* Dynamic custom property references? You wish */ | |
--foo: --bar; | |
--bar: green; | |
background: red; | |
background: var(var(--foo)); |
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
/** | |
* Relative Color Syntax (RCS) + system colors testcase | |
* Green: PASS Orange: FAIL Red: No RCS support | |
*/ | |
background: red; | |
background: oklch(from gold l c h); | |
background: oklch(from canvas .7 0.2 140); |
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
/** | |
* accentColor system color | |
*/ | |
accent-color: lime; | |
background: accentColor; |
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
/** | |
* Relative Color Syntax (RCS) testcase | |
*/ | |
background: red; | |
background: oklch(from yellowgreen l calc(c * 1.2) calc(h + 10)); |
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
/** | |
* Polar interpolation discontinuity | |
*/ | |
div:nth-of-type(1) { | |
background: linear-gradient(to right in oklch, oklch(70% 0.1 0), oklch(70% 0.1 180)); | |
} | |
div:nth-of-type(2) { | |
background: linear-gradient(to right in oklch, oklch(70% 0.1 0), oklch(70% 0.1 179)); |
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
/** | |
* Polar interpolation issues | |
*/ | |
div { | |
padding: 2em; | |
flex: 1; | |
} | |
div:nth-of-type(1) { |
NewerOlder