-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: replacing the light mode bg in to nextui-pro section (#4355)
* fix: replacing the light mode bg and adding bg to nextui-pro section on mobile * fix: making the transitions smoother * chore: removing the bg on mobile devices * fix: pro section and improvements --------- Co-authored-by: Junior Garcia <jrgarciadev@gmail.com>
- Loading branch information
1 parent
7b7408c
commit c1baa74
Showing
20 changed files
with
249 additions
and
204 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export {NextUIProSection} from "./nextui-pro-section"; |
32 changes: 32 additions & 0 deletions
32
apps/docs/components/marketing/nextui-pro-section/nextui-pro-button.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import {Button} from "@nextui-org/react"; | ||
|
||
export const NextUIProButton = () => ( | ||
<Button | ||
as={"a"} | ||
className="px-6 flex items-center" | ||
color="primary" | ||
href="https://nextui.pro?utm_source=nextui.org&utm_medium=nextui-homepage-section" | ||
rel="noopener noreferrer" | ||
target="_blank" | ||
> | ||
Explore NextUI Pro | ||
<svg fill="none" height="21" viewBox="0 0 20 21" width="20" xmlns="http://www.w3.org/2000/svg"> | ||
<path | ||
d="M12.0254 5.44189L17.0837 10.5002L12.0254 15.5586" | ||
stroke="white" | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
strokeMiterlimit="10" | ||
strokeWidth="1.5" | ||
/> | ||
<path | ||
d="M2.91602 10.5H16.941" | ||
stroke="white" | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
strokeMiterlimit="10" | ||
strokeWidth="1.5" | ||
/> | ||
</svg> | ||
</Button> | ||
); |
14 changes: 14 additions & 0 deletions
14
apps/docs/components/marketing/nextui-pro-section/nextui-pro-chip.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import {Chip} from "@nextui-org/react"; | ||
|
||
export const NextUIProChip = () => ( | ||
<Chip | ||
classNames={{ | ||
base: "ml-0.5 transition-colors bg-gradient-to-br from-cyan-600 to-blue-600", | ||
content: "text-tiny font-semibold", | ||
}} | ||
color="primary" | ||
size="sm" | ||
> | ||
PRO | ||
</Chip> | ||
); |
32 changes: 32 additions & 0 deletions
32
apps/docs/components/marketing/nextui-pro-section/nextui-pro-image.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
"use client"; | ||
|
||
import {useTheme} from "next-themes"; | ||
import NextImage from "next/image"; | ||
import {useEffect, useState} from "react"; | ||
|
||
export const NextUIProImage = () => { | ||
const [mounted, setMounted] = useState(false); | ||
const {theme} = useTheme(); | ||
const isDarkMode = theme === "dark"; | ||
|
||
useEffect(() => { | ||
setMounted(true); | ||
}, []); | ||
|
||
let imgSrc = isDarkMode | ||
? "https://heroui-assets.nyc3.cdn.digitaloceanspaces.com/images/nextuipro-section-background.webp" | ||
: "https://heroui-assets.nyc3.cdn.digitaloceanspaces.com/images/nextuipro-section-background-light.webp"; | ||
|
||
if (!mounted) return null; | ||
|
||
return ( | ||
<NextImage | ||
alt="Hero Background" | ||
className="opacity-0 animate-fadeIn" | ||
height={3255} | ||
quality={100} | ||
src={imgSrc} | ||
width={1920} | ||
/> | ||
); | ||
}; |
Oops, something went wrong.