Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(#1001): implement contact us and explore AI Agents buttons #1006

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions next/public/email-24x24.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 12 additions & 12 deletions next/src/components/PrimaryButton.tsx
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
import clsx from "clsx";
import Button from "../ui/button";
import React from "react";

type PrimaryButtonProps = {
children: string;
children: JSX.Element;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReactNode

icon?: React.ReactNode;
onClick?: () => void;
outline?: boolean;
};
export default function PrimaryButton({ children, onClick, outline }: PrimaryButtonProps) {
export default function PrimaryButton({ children, onClick, icon }: PrimaryButtonProps) {
return (
<button
type="button"
<Button
onClick={onClick}
className={clsx(
"text-md rounded-lg px-4 py-2.5 shadow-sm ",
"transition-colors duration-300 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-indigo-600",
outline
? "text-[#BF7DFF]/90 ring-1 ring-[#BF7DFF] hover:bg-[#BF7DFF]/20"
: "bg-[#BF7DFF] text-white hover:border-blue-200 hover:bg-[#9124ff] hover:text-zinc-200 "
"rounded-full border-[1px] border-black shadow-sm",
"transition duration-200 ease-in-out hover:hover:bg-white/90 focus-visible:bg-white/90 focus-visible:outline-none focus-visible:ring-4 focus-visible:ring-white/30",
"bg-white text-black"
)}
onClick={onClick}
>
{icon}
{children}
</button>
</Button>
);
}
24 changes: 24 additions & 0 deletions next/src/components/TextButton.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import clsx from "clsx";
import Button from "../ui/button";
import React from "react";

type TextButtonProps = {
children: JSX.Element;
icon?: React.ReactNode;
onClick?: () => void;
};
export default function TextButton({ children, onClick, icon }: TextButtonProps) {
return (
<Button
onClick={onClick}
className={clsx(
"rounded-full",
"transition duration-200 ease-in-out hover:bg-neutral-900 hover:text-neutral-100 focus-visible:bg-neutral-900 focus-visible:outline-none focus-visible:ring-4 focus-visible:ring-neutral-500",
"bg-transparent text-white/60"
)}
>
{icon}
{children}
</Button>
);
}
33 changes: 26 additions & 7 deletions next/src/components/landing/Hero.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,12 @@ import FadeIn from "../motions/FadeIn";
import BannerBadge from "../BannerBadge";
import clsx from "clsx";
import PrimaryButton from "../PrimaryButton";
import TextButton from "../TextButton";
import Backing from "./Backing";
import React from "react";
import { useRouter } from "next/router";
import Image from "next/image";
import { FaChevronRight } from "react-icons/fa";

const Hero = () => {
const router = useRouter();
Expand Down Expand Up @@ -43,13 +46,29 @@ const Hero = () => {
<br />
accomplish any objective.
</p>
<PrimaryButton
onClick={() => {
router.push("/").catch(console.error);
}}
>
Get started
</PrimaryButton>
<div className="flex flex-col items-center justify-center gap-4 gap-x-5 md:flex-row md:justify-start">
<PrimaryButton
icon={<Image src="email-24x24.svg" width="24" height="24" alt="Email" />}
onClick={() => {
router.push("/").catch(console.error);
}}
>
<>
<span>Contact Us</span>
<FaChevronRight size="12" />
</>
</PrimaryButton>
<TextButton
onClick={() => {
router.push("/").catch(console.error);
}}
>
<>
<span>Explore AI Agents</span>
<FaChevronRight size="12" />
</>
</TextButton>
</div>
</FadeIn>
</div>

Expand Down
2 changes: 1 addition & 1 deletion next/src/ui/button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const Button = forwardRef((props: ButtonProps, ref: ForwardedRef<HTMLButtonEleme
onClick={onClick}
>
{props.ping && <Ping color="white" />}
<div className="flex items-center justify-center">
<div className="flex items-center justify-center gap-x-2.5 px-3 py-2 font-inter text-sm font-medium leading-6">
{loading ? <Loader /> : props.children}
</div>
</button>
Expand Down
3 changes: 3 additions & 0 deletions next/tailwind.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ module.exports = {
boxShadow: {
"3xl": "0 40px 70px -15px rgba(0, 0, 0, 0.40)" // Customize the shadow value according to your preferences.
},
fontFamily: {
inter: ["Inter", ...defaultTheme.fontFamily.sans]
},
colors: {
blue: {
base: {
Expand Down