@keyframes cast-bit-to-space-toggle { to { --cbtst-space-toggle: ; } } @property --cbtst-space-toggle { syntax: "*"; initial-value: initial; inherits: false; } :where(.cbtst) { --cbtst-animation: cast-bit-to-space-toggle 1ms linear both var(--cbtst-bit, 0); animation: var(--cbtst-animation); } /* usage */ .my-el.cbtst { --cbtst-bit: 1; /* provide input value of 0 or 1 */ /* var(--cbtst-space-toggle) is the output */ } xxxxxxxxxx 1@keyframes cast-bit-to-space-toggle {2 to { --cbtst-space-toggle: ; }3}45@property --cbtst-space-toggle {6 syntax: "*";7 initial-value: initial;8 inherits: false;9}1011:where(.cbtst) {12 --cbtst-animation: cast-bit-to-space-toggle13 1ms linear both var(--cbtst-bit, 0);14 animation: var(--cbtst-animation);15}1617/* usage */18.my-el.cbtst {19 --cbtst-bit: 1; /* provide input value of 0 or 1 */20 /* var(--cbtst-space-toggle) is the output */21}22
xxxxxxxxxx
@keyframes cast-bit-to-space-toggle {
to { --cbtst-space-toggle: ; }
}
@property --cbtst-space-toggle {
syntax: "*";
initial-value: initial;
inherits: false;
:where(.cbtst) {
--cbtst-animation: cast-bit-to-space-toggle
1ms linear both var(--cbtst-bit, 0);
animation: var(--cbtst-animation);
/* usage */
.my-el.cbtst {
--cbtst-bit: 1; /* provide input value of 0 or 1 */
/* var(--cbtst-space-toggle) is the output */