Skip to content

Commit

Permalink
fix: workaround bug with camelCase variable names
Browse files Browse the repository at this point in the history
  • Loading branch information
nmn committed Dec 21, 2024
1 parent 40233a6 commit ce9c6c2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion apps/nextjs-example/app/CardTokens.stylex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
import * as stylex from '@stylexjs/stylex';

export const tokens = stylex.defineVars({
arrowTransform: 'translateX(0)',
arrow_transform: 'translateX(0)',
});
4 changes: 2 additions & 2 deletions apps/nextjs-example/components/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const styles = stylex.create({
transitionDuration: '400ms',
textAlign: 'center',
textDecoration: 'none',
[tokens.arrowTransform]: {
[tokens.arrow_transform]: {
default: 'translateX(0)',
':hover': 'translateX(4px)',
},
Expand All @@ -85,7 +85,7 @@ const styles = stylex.create({
span: {
display: 'inline-block',
transitionProperty: 'transform',
transform: tokens.arrowTransform,
transform: tokens.arrow_transform,
transitionDuration: {
default: '200ms',
[REDUCE_MOTION]: '0s',
Expand Down

0 comments on commit ce9c6c2

Please sign in to comment.