Skip to content

Commit

Permalink
Fix Layout title on mobile when title is long (#781)
Browse files Browse the repository at this point in the history
  • Loading branch information
lifeiscontent committed Apr 12, 2023
1 parent 5faed30 commit c0facf1
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/six-ways-approve.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'demo-store': minor
---

Fix Layout title on mobile when title is long
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion templates/demo-store/app/components/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,10 @@ function MobileHeader({
className="flex items-center self-stretch leading-[3rem] md:leading-[4rem] justify-center flex-grow w-full h-full"
to="/"
>
<Heading className="font-bold text-center" as={isHome ? 'h1' : 'h2'}>
<Heading
className="font-bold text-center leading-none"
as={isHome ? 'h1' : 'h2'}
>
{title}
</Heading>
</Link>
Expand Down

0 comments on commit c0facf1

Please sign in to comment.