-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
320 additions
and
14 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,12 @@ | ||
--- | ||
import { Button } from "./ui/button"; | ||
import logo from "../assets/light_app_logo.svg"; | ||
import { RainbowButton } from "@/components/ui/rainbow-button"; | ||
--- | ||
|
||
<div class="flex w-full justify-between items-center px-8 py-4 border-b-2 h-16"> | ||
<div class="logo"> | ||
<img class="w-[36px]" src={logo.src} alt="logo"/> | ||
</div> | ||
<Button className="py-4 px-4">Get Started</Button> | ||
</div> |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
'use client'; | ||
|
||
import React from 'react'; | ||
|
||
import { cn } from '@/lib/utils'; | ||
|
||
interface PulsatingButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> { | ||
pulseColor?: string; | ||
duration?: string; | ||
} | ||
|
||
export default function PulsatingButton({ | ||
className, | ||
children, | ||
pulseColor = '#0096ff', | ||
duration = '1.5s', | ||
...props | ||
}: PulsatingButtonProps) { | ||
return ( | ||
<button | ||
className={cn( | ||
'relative flex cursor-pointer items-center justify-center rounded-lg bg-blue-500 px-4 py-2 text-center text-white dark:bg-blue-500 dark:text-black', | ||
className, | ||
)} | ||
style={ | ||
{ | ||
'--pulse-color': pulseColor, | ||
'--duration': duration, | ||
} as React.CSSProperties | ||
} | ||
{...props} | ||
> | ||
<div className="relative z-10">{children}</div> | ||
<div className="absolute left-1/2 top-1/2 size-full -translate-x-1/2 -translate-y-1/2 animate-pulse rounded-lg bg-inherit" /> | ||
</button> | ||
); | ||
} |
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,28 @@ | ||
import React from 'react'; | ||
|
||
import { cn } from '@/lib/utils'; | ||
interface RainbowButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {} | ||
|
||
export function RainbowButton({ children, className, ...props }: RainbowButtonProps) { | ||
return ( | ||
<button | ||
className={cn( | ||
'group relative inline-flex h-11 animate-rainbow cursor-pointer items-center justify-center rounded-xl border-0 bg-[length:200%] px-8 py-2 font-medium text-primary-foreground transition-colors [background-clip:padding-box,border-box,border-box] [background-origin:border-box] [border:calc(0.08*1rem)_solid_transparent] focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50', | ||
|
||
// before styles | ||
'before:absolute before:bottom-[-20%] before:left-1/2 before:z-0 before:h-1/5 before:w-3/5 before:-translate-x-1/2 before:animate-rainbow before:bg-[linear-gradient(90deg,hsl(var(--color-1)),hsl(var(--color-5)),hsl(var(--color-3)),hsl(var(--color-4)),hsl(var(--color-2)))] before:[filter:blur(calc(0.8*1rem))]', | ||
|
||
// light mode colors | ||
'bg-[linear-gradient(#121213,#121213),linear-gradient(#121213_50%,rgba(18,18,19,0.6)_80%,rgba(18,18,19,0)),linear-gradient(90deg,hsl(var(--color-1)),hsl(var(--color-5)),hsl(var(--color-3)),hsl(var(--color-4)),hsl(var(--color-2)))]', | ||
|
||
// dark mode colors | ||
'dark:bg-[linear-gradient(#fff,#fff),linear-gradient(#fff_50%,rgba(255,255,255,0.6)_80%,rgba(0,0,0,0)),linear-gradient(90deg,hsl(var(--color-1)),hsl(var(--color-5)),hsl(var(--color-3)),hsl(var(--color-4)),hsl(var(--color-2)))]', | ||
|
||
className, | ||
)} | ||
{...props} | ||
> | ||
{children} | ||
</button> | ||
); | ||
} |
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,69 @@ | ||
import { cn } from '@/lib/utils'; | ||
|
||
interface RetroGridProps extends React.HTMLAttributes<HTMLDivElement> { | ||
/** | ||
* Additional CSS classes to apply to the grid container | ||
*/ | ||
className?: string; | ||
/** | ||
* Rotation angle of the grid in degrees | ||
* @default 65 | ||
*/ | ||
angle?: number; | ||
/** | ||
* Grid cell size in pixels | ||
* @default 60 | ||
*/ | ||
cellSize?: number; | ||
/** | ||
* Grid opacity value between 0 and 1 | ||
* @default 0.5 | ||
*/ | ||
opacity?: number; | ||
/** | ||
* Grid line color in light mode | ||
* @default "gray" | ||
*/ | ||
lightLineColor?: string; | ||
/** | ||
* Grid line color in dark mode | ||
* @default "gray" | ||
*/ | ||
darkLineColor?: string; | ||
} | ||
|
||
export default function RetroGrid({ | ||
className, | ||
angle = 65, | ||
cellSize = 60, | ||
opacity = 0.5, | ||
lightLineColor = 'gray', | ||
darkLineColor = 'gray', | ||
...props | ||
}: RetroGridProps) { | ||
const gridStyles = { | ||
'--grid-angle': `${angle}deg`, | ||
'--cell-size': `${cellSize}px`, | ||
'--opacity': opacity, | ||
'--light-line': lightLineColor, | ||
'--dark-line': darkLineColor, | ||
} as React.CSSProperties; | ||
|
||
return ( | ||
<div | ||
className={cn( | ||
'pointer-events-none absolute size-full overflow-hidden [perspective:200px]', | ||
`opacity-[var(--opacity)]`, | ||
className, | ||
)} | ||
style={gridStyles} | ||
{...props} | ||
> | ||
<div className="absolute inset-0 [transform:rotateX(var(--grid-angle))]"> | ||
<div className="animate-grid [background-image:linear-gradient(to_right,var(--light-line)_1px,transparent_0),linear-gradient(to_bottom,var(--light-line)_1px,transparent_0)] [background-repeat:repeat] [background-size:var(--cell-size)_var(--cell-size)] [height:300vh] [inset:0%_0px] [margin-left:-200%] [transform-origin:100%_0_0] [width:600vw] dark:[background-image:linear-gradient(to_right,var(--dark-line)_1px,transparent_0),linear-gradient(to_bottom,var(--dark-line)_1px,transparent_0)]" /> | ||
</div> | ||
|
||
<div className="absolute inset-0 bg-gradient-to-t from-white to-transparent to-90% dark:from-black" /> | ||
</div> | ||
); | ||
} |
Oops, something went wrong.