feat: Add GitHub to the page
This commit is contained in:
parent
a45f5d09ea
commit
8ca63ca97a
50
app/page.tsx
50
app/page.tsx
@ -92,6 +92,7 @@ import {
|
|||||||
ChartTooltip,
|
ChartTooltip,
|
||||||
ChartTooltipContent,
|
ChartTooltipContent,
|
||||||
} from "@/components/ui/chart";
|
} from "@/components/ui/chart";
|
||||||
|
import { GitHubLogoIcon } from '@radix-ui/react-icons';
|
||||||
|
|
||||||
export const maxDuration = 60;
|
export const maxDuration = 60;
|
||||||
|
|
||||||
@ -147,7 +148,7 @@ export default function Home() {
|
|||||||
await navigator.clipboard.writeText(text);
|
await navigator.clipboard.writeText(text);
|
||||||
toast.success("Copied to clipboard");
|
toast.success("Copied to clipboard");
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
throw new Error("Clipboard API not available");
|
throw new Error("Clipboard API not available");
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@ -789,23 +790,36 @@ export default function Home() {
|
|||||||
<RefreshCw className="h-4 w-4" />
|
<RefreshCw className="h-4 w-4" />
|
||||||
<span>New</span>
|
<span>New</span>
|
||||||
</Button>
|
</Button>
|
||||||
<TooltipProvider>
|
<div
|
||||||
<Tooltip>
|
className='flex items-center space-x-2'
|
||||||
<TooltipTrigger asChild>
|
>
|
||||||
<Button
|
<Button
|
||||||
size="sm"
|
variant="secondary"
|
||||||
onClick={() => window.open("https://github.com/sponsors/zaidmukaddam", "_blank")}
|
size="sm"
|
||||||
className="flex items-center space-x-2"
|
onClick={() => window.open("https://git.new/mplx", "_blank")}
|
||||||
>
|
className="flex items-center space-x-2"
|
||||||
<Heart className="h-4 w-4 text-red-500" />
|
>
|
||||||
<span>Sponsor</span>
|
<GitHubLogoIcon className="h-4 w-4 text-primary" />
|
||||||
</Button>
|
<span>GitHub</span>
|
||||||
</TooltipTrigger>
|
</Button>
|
||||||
<TooltipContent>
|
<TooltipProvider>
|
||||||
<p>Sponsor this project on GitHub</p>
|
<Tooltip>
|
||||||
</TooltipContent>
|
<TooltipTrigger asChild>
|
||||||
</Tooltip>
|
<Button
|
||||||
</TooltipProvider>
|
size="sm"
|
||||||
|
onClick={() => window.open("https://github.com/sponsors/zaidmukaddam", "_blank")}
|
||||||
|
className="flex items-center space-x-2"
|
||||||
|
>
|
||||||
|
<Heart className="h-4 w-4 text-red-500" />
|
||||||
|
<span>Sponsor</span>
|
||||||
|
</Button>
|
||||||
|
</TooltipTrigger>
|
||||||
|
<TooltipContent>
|
||||||
|
<p>Sponsor this project on GitHub</p>
|
||||||
|
</TooltipContent>
|
||||||
|
</Tooltip>
|
||||||
|
</TooltipProvider>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user