Created
September 9, 2024 08:16
-
-
Save greystate/a44f4d43ea43248f75c45131c6c8c413 to your computer and use it in GitHub Desktop.
Testing @Property for animating an angle value
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
/** | |
* Testing @property for animating an angle value | |
*/ | |
@property --angle { | |
syntax: "<angle>"; | |
inherits: false; | |
initial-value: 45deg; | |
} | |
:root { | |
--angle: 16deg; | |
background: #f06; | |
background: linear-gradient(var(--angle, 45deg), #f06, yellow); | |
min-height: 100%; | |
transition: --angle 1s linear; | |
&:hover { | |
--angle: 120deg; | |
} |
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
<!-- content to be placed inside <body>…</body> --> |
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
// alert('Hello world!'); |
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
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment