We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Composite shadows do not support using semantic tokens.
Composite shadows take numerical values, not string values which could be semantic tokens.
offsetX: number offsetY: number blur: number spread: number
This makes mapping values from a W3 spec difficult to implement as you need to combine the properties into the string version.
"drop-shadow-3": { "$type": "shadow", "$value": [ { "offsetX": "{Atomic Scale.0}", "offsetY": "{Atomic Scale.300}", "blur": "{Atomic Scale.400}", "spread": "{Atomic Scale.100}", "color": "{Surface.drop-shadow}" } ] },
Allow supplying number or string values which are sematic tokens
number
string
Using the string version works properly. I was able to wrap my shadows in a reducer before supplying them to the panda theme.
shadows: Object.entries(getShadows()).reduce((acc, [key, entry]) => { acc[key] = { value: `${entry.value.offsetX} ${entry.value.offsetY} ${entry.value.blur} ${entry.value.spread} ${entry.value.color}`, }; return acc; }, {}),
No response
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
Composite shadows do not support using semantic tokens.
Problem Statement/Justification
Composite shadows take numerical values, not string values which could be semantic tokens.
This makes mapping values from a W3 spec difficult to implement as you need to combine the properties into the string version.
Proposed Solution or API
Allow supplying
number
orstring
values which are sematic tokensAlternatives
Using the
string
version works properly. I was able to wrap my shadows in a reducer before supplying them to the panda theme.Additional Information
No response
The text was updated successfully, but these errors were encountered: