Skip to content

Commit 67a646a

Browse files
committed
✨ improved ui of banner
1 parent cba28ad commit 67a646a

File tree

2 files changed

+22
-6
lines changed

2 files changed

+22
-6
lines changed

src/components/Footer.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ function SmallPrint() {
119119

120120
const FooterBanner = () => {
121121
return (
122-
<div className="flex flex-col items-center justify-center rounded-xl border bg-gray-100 py-8 text-black">
122+
<div className="flex w-full flex-col items-center justify-center rounded-xl border bg-gray-100 py-8 text-black">
123123
<div className="mb-4 max-w-xl text-center text-xl font-semibold tracking-tight">
124124
Say goodbye to the grind of coding everything from scratch. So you can
125125
focus on what matters most
@@ -139,10 +139,12 @@ const FooterBanner = () => {
139139
}
140140

141141
export function Footer() {
142+
const pathname = usePathname()
143+
142144
return (
143145
<footer className="mx-auto w-full max-w-2xl space-y-10 pb-16 lg:max-w-5xl">
144146
<PageNavigation />
145-
<FooterBanner />
147+
{pathname !== '/' && <FooterBanner />}
146148
<SmallPrint />
147149
</footer>
148150
)

src/components/SyntaxUIProBanner.tsx

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,34 @@
11
import { useProBannerStore } from '@/store'
22
import { X } from 'lucide-react'
3+
import Image from 'next/image'
34

45
const SyntaxUIProBanner = () => {
56
const { setShowProBanner } = useProBannerStore()
67
return (
7-
<div className="border-border group fixed bottom-2 right-2 z-50 h-auto w-[calc(100vw-16px)] max-w-[350px] overflow-hidden rounded-lg border border-red-700 bg-red-500 p-4 text-white transition-all animate-in slide-in-from-bottom-full md:bottom-4 md:right-4">
8+
<div className="border-border group fixed bottom-2 right-2 z-50 h-auto w-[calc(100vw-16px)] max-w-[350px] overflow-hidden rounded-lg border bg-white p-4 text-gray-900 transition-all animate-in slide-in-from-bottom-full md:bottom-4 md:right-4 ">
89
<a
910
href="https://pro.syntaxui.com/"
1011
target="_blank"
1112
rel="noopener noreferrer"
13+
className="flex flex-row"
1214
>
15+
<div className="relative mr-6 md:block">
16+
<Image
17+
src="/images/syntaxUI.svg"
18+
alt="SyntaxUI"
19+
className="h-16 w-16 rounded-xl"
20+
width={120}
21+
height={120}
22+
/>
23+
<div className="absolute -right-4 bottom-4 rotate-[-18deg] rounded-full bg-black px-1 text-[10px] text-white">
24+
PRO
25+
</div>
26+
</div>
1327
<div className="flex flex-col items-start gap-0.5">
14-
<h1 className="text-md hidden font-semibold md:block">
28+
<h1 className="text-md font-medium tracking-tight md:block">
1529
Code Less, Create More!
1630
</h1>
17-
<div className="font-regular flex items-start justify-start text-sm leading-6 text-white/80">
31+
<div className="font-regular flex items-start justify-start font-mono text-xs leading-[17px] tracking-tighter text-gray-900/80">
1832
{`Get Premium Blocks and Templates for your next project on SyntaxUI Pro ↗`}
1933
</div>
2034
</div>
@@ -23,7 +37,7 @@ const SyntaxUIProBanner = () => {
2337
className="p-1s absolute right-2 top-2 transition-all duration-300 ease-in-out group-hover:block md:hidden"
2438
onClick={() => setShowProBanner(false)}
2539
>
26-
<X className="h-5 w-5" />
40+
<X className="h-4 w-4" />
2741
</button>
2842
</div>
2943
)

0 commit comments

Comments
 (0)