Hi there, I've been wondering:
Can I somehow read switch values as variable, in the css script, to make a condition check?
here's the code:
:host {
border-radius: 15px;
font-size: 130%;
line-height: 1.2;
transition: filter 0.15s ease-in-out;
filter: #{@{this} == 0? 'brightness(100%) saturate(100%)' : 'brightness(90%) saturate(125%)'};
}
value:nth-child(1) {
--color-fill: #{globals.color.blue};
border-radius: 5px;
font-size: #{@{this} == 57? '200%' : '100%'};
transition: color 0.3s ease-in-out, font-size 0.3s ease-in-out;
}
value:nth-child(2) {
--color-fill: #{globals.color.blue};
border-radius: 5px;
font-size: #{@{this} == 54? '200%' : '100%'};
transition: color 0.3s ease-in-out, font-size 0.3s ease-in-out;
}
value:nth-child(3) {
--color-fill: #{globals.color.blue};
border-radius: 5px;
font-size: #{@{this} == 52? '200%' : '100%'};
transition: color 0.3s ease-in-out, font-size 0.3s ease-in-out;
}
So can I use the "LevelA" to instead of using 57 as the condition, because the number might change?