diff --git a/src/components/PricingCard/PricingCard.tsx b/src/components/PricingCard/PricingCard.tsx new file mode 100644 index 0000000..43b8488 --- /dev/null +++ b/src/components/PricingCard/PricingCard.tsx @@ -0,0 +1,35 @@ +import { Card, CardContent, CardFooter } from 'components/ui/Card' +import Divider from 'components/ui/Divider' +import { forwardRef, type HTMLAttributes } from 'react' +import cn from 'utils/cn' +import PricingCardFooterContent from './PricingCardFooterContent' +import PricingCardPageViews from './PricingCardPageViews' +import PricingCardPrice from './PricingCardPrice' +import PriceCardSlider from './PricingCardSlider' +import PricingCardSwitch from './PricingCardSwitch' + +const PricingCard = forwardRef>( + ({ className, ...props }, ref) => ( + + +
+ + + +
+ + +
+ + + + +
+ ) +) + +export default PricingCard diff --git a/src/components/PricingCard/PricingCardFooterContent.tsx b/src/components/PricingCard/PricingCardFooterContent.tsx new file mode 100644 index 0000000..0e222b4 --- /dev/null +++ b/src/components/PricingCard/PricingCardFooterContent.tsx @@ -0,0 +1,41 @@ +import Button from 'components/ui/Button' +import { forwardRef, type HTMLAttributes } from 'react' +import cn from 'utils/cn' +import CheckIcon from '../../icons/Check.svg?react' + +const PricingCardFooterContent = forwardRef< + HTMLDivElement, + HTMLAttributes +>(({ className, ...props }, ref) => ( +
+
+ {['Unlimited websites', '100% data ownership', 'Email reports'].map( + text => ( + + + {text} + + ) + )} +
+ +
+)) + +export default PricingCardFooterContent diff --git a/src/components/PricingCard/PricingCardPageViews.tsx b/src/components/PricingCard/PricingCardPageViews.tsx new file mode 100644 index 0000000..be54f60 --- /dev/null +++ b/src/components/PricingCard/PricingCardPageViews.tsx @@ -0,0 +1,21 @@ +import type { HTMLAttributes } from 'react' +import { forwardRef } from 'react' +import cn from 'utils/cn' + +const PricingCardPageViews = forwardRef< + HTMLDivElement, + HTMLAttributes +>(({ className, ...props }, ref) => ( +
+ 100K PAGEVIEWS +
+)) + +export default PricingCardPageViews diff --git a/src/components/PricingCard/PricingCardPrice.tsx b/src/components/PricingCard/PricingCardPrice.tsx new file mode 100644 index 0000000..e00e64a --- /dev/null +++ b/src/components/PricingCard/PricingCardPrice.tsx @@ -0,0 +1,37 @@ +import type { HTMLAttributes } from 'react' +import { forwardRef } from 'react' +import cn from 'utils/cn' + +const PricingCardPrice = forwardRef< + HTMLDivElement, + HTMLAttributes +>(({ className, ...props }, ref) => ( +
+
+ + $16.00 + + + / month + +
+
+ {`or ~32 CRO `} + / month +
+
+)) + +export default PricingCardPrice diff --git a/src/components/PricingCard/PricingCardSlider.tsx b/src/components/PricingCard/PricingCardSlider.tsx new file mode 100644 index 0000000..ec44a9c --- /dev/null +++ b/src/components/PricingCard/PricingCardSlider.tsx @@ -0,0 +1,14 @@ +import { Slider } from 'components/ui/Slider' +import { forwardRef, type HTMLAttributes } from 'react' +import cn from 'utils/cn' + +const PriceCardSlider = forwardRef< + HTMLDivElement, + HTMLAttributes +>(({ className, ...props }, ref) => ( +
+ +
+)) + +export default PriceCardSlider diff --git a/src/components/PricingCard/PricingCardSwitch.tsx b/src/components/PricingCard/PricingCardSwitch.tsx new file mode 100644 index 0000000..48cb2a6 --- /dev/null +++ b/src/components/PricingCard/PricingCardSwitch.tsx @@ -0,0 +1,34 @@ +import { Switch } from 'components/ui/Switch' +import { forwardRef, type HTMLAttributes } from 'react' +import cn from 'utils/cn' + +const PricingCardSwitch = forwardRef< + HTMLDivElement, + HTMLAttributes +>(({ className, ...props }, ref) => ( +
+
Monthly Billing
+ +
+ Yearly Billing +
+
+
+ 25% discount + -25% +
+
+
+)) + +export default PricingCardSwitch diff --git a/src/pages/HomePage.tsx b/src/pages/HomePage.tsx index e168869..e6a9279 100644 --- a/src/pages/HomePage.tsx +++ b/src/pages/HomePage.tsx @@ -1,4 +1,5 @@ import Header from 'components/Header' +import PricingCard from 'components/PricingCard/PricingCard' import type { ReactElement } from 'react' import cn from 'utils/cn' @@ -6,13 +7,14 @@ export default function HomePage(): ReactElement { return (
-
+
+
)