You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I did this with the help of Claude and it works. What are your thoughts?
// Helper function to convert pixels to remfunctionpxToRem(px: number): number{returnpx/16// Assuming base font size is 16px}constcustomHeadlines: Record<string,TypeDefinition>={'text-display-xxl': {clamp: [pxToRem(64),pxToRem(264)],classAlias: ['text-display-xxl'],},}
The text was updated successfully, but these errors were encountered:
I see what you're looking for, I can improve the API with options on the types of inputs for the clamping. Ideally you can pass REM or pixel units. I think your workaround works. You could also eliminate the function and just do:
I did this with the help of Claude and it works. What are your thoughts?
The text was updated successfully, but these errors were encountered: