Skip to content

Commit

Permalink
fix missing set
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielmfern committed Dec 23, 2024
1 parent 64cfc00 commit c31e2b9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/react-email/src/hooks/use-clamped-state.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export const useClampedState = (initial: number, min: number, max: number) => {
if (typeof valueOrFunction === 'function') {
setV((value: number) => clamp(valueOrFunction(value), min, max));
} else {
clamp(valueOrFunction, min, max);
setV(clamp(valueOrFunction, min, max));
}
},
] as const;
Expand Down

0 comments on commit c31e2b9

Please sign in to comment.