Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(components): fix text wrapping issue in buttons (#1548)
## What does this PR do? This pull request resolves an issue where the button text wraps onto the next line in specific screen sizes when the text contains two or more words. By applying the whitespace-nowrap utility class to the button element, the text now remains on a single line, even on screens with limited space. This enhancement ensures a consistent and visually pleasing user experience across various devices : ### Before (Get Started Button) ![before](https://github.com/shadcn-ui/ui/assets/97639117/50c8211d-2ed7-46d0-8ab2-d4c565d0d6f3) ### After (Get Started Button) ![after](https://github.com/shadcn-ui/ui/assets/97639117/0f9f7e68-31e8-4011-a2ca-d7e59b3690ee) This problem arises in other projects utilizing Shadcn, and this pull request addresses and resolves the issue, as demonstrated in the Cal.com project example: ### Before (Set Up Button) ![button-before](https://github.com/calcom/cal.com/assets/97639117/8f588a53-411a-4e9d-95df-76bd42d480d7) ### After (Set Up Button) ![button-fixed](https://github.com/calcom/cal.com/assets/97639117/4c74e77a-a2cd-4b0c-87ee-a82dbefc23eb)
- Loading branch information
44f35d5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
ui – ./apps/www
ui-git-main-shadcn-pro.vercel.app
ui.shadcn.com
ui-shadcn-pro.vercel.app
example-playground.vercel.app