Last active
October 12, 2025 17:34
-
-
Save Kcko/e3b054f36e33de52e66e5dd5409c0a66 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
/* https://www.bitovi.com/blog/css-only-type-grinding-casting-tokens-into-useful-values */ | |
@property --variant { | |
syntax: "primary|secondary|success|error"; | |
initial-value: primary; | |
inherits: true; | |
} | |
@property --_v-primary-else-0 { | |
syntax: "primary|<integer>"; initial-value: 0; inherits: true; | |
} | |
@property --_v-primary-bit { | |
syntax: "<integer>"; initial-value: 1; inherits: true; | |
} | |
.element { | |
--variant: primary; | |
--_v-primary-else-0: var(--variant); | |
--_v-primary-bit: var(--_v-primary-else-0); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment