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: start lp template #107

Merged
merged 4 commits into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from 3 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
2,138 changes: 2,138 additions & 0 deletions .decofile.json

Large diffs are not rendered by default.

177 changes: 93 additions & 84 deletions manifest.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,101 +4,110 @@

import * as $$$0 from "./loaders/Layouts/ProductCard.tsx";
import * as $$$1 from "./loaders/List/Sections.tsx";
import * as $$$$$$0 from "./sections/Social/InstagramPosts.tsx";
import * as $$$$$$1 from "./sections/Social/WhatsApp.tsx";
import * as $$$$$$2 from "./sections/Header/Header.tsx";
import * as $$$$$$3 from "./sections/Product/NotFound.tsx";
import * as $$$$$$4 from "./sections/Product/SearchResult.tsx";
import * as $$$$$$5 from "./sections/Product/ImageGalleryFrontBack.tsx";
import * as $$$$$$6 from "./sections/Product/Wishlist.tsx";
import * as $$$$$$7 from "./sections/Product/ProductInfo.tsx";
import * as $$$$$$8 from "./sections/Product/ProductShelfTabbed.tsx";
import * as $$$$$$9 from "./sections/Product/NotFoundChallenge.tsx";
import * as $$$$$$10 from "./sections/Product/ImageGallerySlider.tsx";
import * as $$$$$$11 from "./sections/Product/ProductShelf.tsx";
import * as $$$$$$12 from "./sections/Product/ShelfWithImage.tsx";
import * as $$$$$$13 from "./sections/Theme/Theme.tsx";
import * as $$$$$$14 from "./sections/Newsletter/Newsletter.tsx";
import * as $$$$$$15 from "./sections/Images/ImageGallery.tsx";
import * as $$$$$$16 from "./sections/Images/BannerGrid.tsx";
import * as $$$$$$17 from "./sections/Images/ShoppableBanner.tsx";
import * as $$$$$$18 from "./sections/Images/Carousel.tsx";
import * as $$$$$$19 from "./sections/Category/CategoryList.tsx";
import * as $$$$$$20 from "./sections/Category/CategoryBanner.tsx";
import * as $$$$$$21 from "./sections/Category/CategoryGrid.tsx";
import * as $$$$$$22 from "./sections/Content/RichText.tsx";
import * as $$$$$$0 from "./sections/Gallery.tsx";
import * as $$$$$$1 from "./sections/Footer/Footer.tsx";
import * as $$$$$$2 from "./sections/Category/CategoryBanner.tsx";
import * as $$$$$$3 from "./sections/Category/CategoryList.tsx";
import * as $$$$$$4 from "./sections/Category/CategoryGrid.tsx";
import * as $$$$$$5 from "./sections/Images/ShoppableBanner.tsx";
import * as $$$$$$6 from "./sections/Images/BannerGrid.tsx";
import * as $$$$$$7 from "./sections/Images/ImageGallery.tsx";
import * as $$$$$$8 from "./sections/Images/Carousel.tsx";
import * as $$$$$$9 from "./sections/Layout/Container.tsx";
import * as $$$$$$10 from "./sections/Layout/Grid.tsx";
import * as $$$$$$11 from "./sections/Layout/Flex.tsx";
import * as $$$$$$12 from "./sections/Layout/GridItem.tsx";
import * as $$$$$$13 from "./sections/Animation/Animation.tsx";
import * as $$$$$$14 from "./sections/Content/Hero.tsx";
import * as $$$$$$15 from "./sections/Content/Features.tsx";
import * as $$$$$$16 from "./sections/Content/BlogPosts.tsx";
import * as $$$$$$17 from "./sections/Content/RichText.tsx";
import * as $$$$$$18 from "./sections/Content/Testimonials.tsx";
import * as $$$$$$19 from "./sections/Content/Logos.tsx";
import * as $$$$$$20 from "./sections/Content/CallToAction.tsx";
import * as $$$$$$21 from "./sections/Content/Table.tsx";
import * as $$$$$$22 from "./sections/Content/Faq.tsx";
import * as $$$$$$23 from "./sections/Content/Benefits.tsx";
import * as $$$$$$24 from "./sections/Content/Faq.tsx";
import * as $$$$$$25 from "./sections/Content/BlogPosts.tsx";
import * as $$$$$$26 from "./sections/Content/Testimonials.tsx";
import * as $$$$$$27 from "./sections/Content/Logos.tsx";
import * as $$$$$$28 from "./sections/Content/Table.tsx";
import * as $$$$$$29 from "./sections/Layout/Container.tsx";
import * as $$$$$$30 from "./sections/Layout/Flex.tsx";
import * as $$$$$$31 from "./sections/Layout/Grid.tsx";
import * as $$$$$$32 from "./sections/Layout/GridItem.tsx";
import * as $$$$$$33 from "./sections/Footer/Footer.tsx";
import * as $$$$$$34 from "./sections/Animation/Animation.tsx";
import * as $$$$$$35 from "./sections/Gallery.tsx";
import * as $$$$$$36 from "./sections/Links/Shortcuts.tsx";
import * as $$$$$$37 from "./sections/Links/LinkTree.tsx";
import * as $$$$$$38 from "./sections/Miscellaneous/Slide.tsx";
import * as $$$$$$39 from "./sections/Miscellaneous/CookieConsent.tsx";
import * as $$$$$$40 from "./sections/Miscellaneous/CampaignTimer.tsx";
import * as $$$$$$$$$$$0 from "./apps/site.ts";
import * as $$$$$$$$$$$1 from "./apps/decohub.ts";
import * as $$$$$$24 from "./sections/Content/ImageSection.tsx";
import * as $$$$$$25 from "./sections/Product/Wishlist.tsx";
import * as $$$$$$26 from "./sections/Product/NotFoundChallenge.tsx";
import * as $$$$$$27 from "./sections/Product/SearchResult.tsx";
import * as $$$$$$28 from "./sections/Product/ProductInfo.tsx";
import * as $$$$$$29 from "./sections/Product/ProductShelf.tsx";
import * as $$$$$$30 from "./sections/Product/ImageGallerySlider.tsx";
import * as $$$$$$31 from "./sections/Product/ImageGalleryFrontBack.tsx";
import * as $$$$$$32 from "./sections/Product/ShelfWithImage.tsx";
import * as $$$$$$33 from "./sections/Product/ProductShelfTabbed.tsx";
import * as $$$$$$34 from "./sections/Product/NotFound.tsx";
import * as $$$$$$35 from "./sections/Miscellaneous/CampaignTimer.tsx";
import * as $$$$$$36 from "./sections/Miscellaneous/CookieConsent.tsx";
import * as $$$$$$37 from "./sections/Miscellaneous/Slide.tsx";
import * as $$$$$$38 from "./sections/Social/WhatsApp.tsx";
import * as $$$$$$39 from "./sections/Social/InstagramPosts.tsx";
import * as $$$$$$40 from "./sections/Theme/Theme.tsx";
import * as $$$$$$41 from "./sections/Links/LinkTree.tsx";
import * as $$$$$$42 from "./sections/Links/Shortcuts.tsx";
import * as $$$$$$43 from "./sections/Newsletter/Newsletter.tsx";
import * as $$$$$$44 from "./sections/Header/Header.tsx";
import * as $$$$$$$$$$$0 from "./apps/decohub.ts";
import * as $$$$$$$$$$$1 from "./apps/site.ts";

const manifest = {
"loaders": {
"deco-sites/storefront/loaders/Layouts/ProductCard.tsx": $$$0,
"deco-sites/storefront/loaders/List/Sections.tsx": $$$1,
},
"sections": {
"deco-sites/storefront/sections/Animation/Animation.tsx": $$$$$$34,
"deco-sites/storefront/sections/Category/CategoryBanner.tsx": $$$$$$20,
"deco-sites/storefront/sections/Category/CategoryGrid.tsx": $$$$$$21,
"deco-sites/storefront/sections/Category/CategoryList.tsx": $$$$$$19,
"deco-sites/storefront/sections/Animation/Animation.tsx": $$$$$$13,
"deco-sites/storefront/sections/Category/CategoryBanner.tsx": $$$$$$2,
"deco-sites/storefront/sections/Category/CategoryGrid.tsx": $$$$$$4,
"deco-sites/storefront/sections/Category/CategoryList.tsx": $$$$$$3,
"deco-sites/storefront/sections/Content/Benefits.tsx": $$$$$$23,
"deco-sites/storefront/sections/Content/BlogPosts.tsx": $$$$$$25,
"deco-sites/storefront/sections/Content/Faq.tsx": $$$$$$24,
"deco-sites/storefront/sections/Content/Logos.tsx": $$$$$$27,
"deco-sites/storefront/sections/Content/RichText.tsx": $$$$$$22,
"deco-sites/storefront/sections/Content/Table.tsx": $$$$$$28,
"deco-sites/storefront/sections/Content/Testimonials.tsx": $$$$$$26,
"deco-sites/storefront/sections/Footer/Footer.tsx": $$$$$$33,
"deco-sites/storefront/sections/Gallery.tsx": $$$$$$35,
"deco-sites/storefront/sections/Header/Header.tsx": $$$$$$2,
"deco-sites/storefront/sections/Images/BannerGrid.tsx": $$$$$$16,
"deco-sites/storefront/sections/Images/Carousel.tsx": $$$$$$18,
"deco-sites/storefront/sections/Images/ImageGallery.tsx": $$$$$$15,
"deco-sites/storefront/sections/Images/ShoppableBanner.tsx": $$$$$$17,
"deco-sites/storefront/sections/Layout/Container.tsx": $$$$$$29,
"deco-sites/storefront/sections/Layout/Flex.tsx": $$$$$$30,
"deco-sites/storefront/sections/Layout/Grid.tsx": $$$$$$31,
"deco-sites/storefront/sections/Layout/GridItem.tsx": $$$$$$32,
"deco-sites/storefront/sections/Links/LinkTree.tsx": $$$$$$37,
"deco-sites/storefront/sections/Links/Shortcuts.tsx": $$$$$$36,
"deco-sites/storefront/sections/Miscellaneous/CampaignTimer.tsx": $$$$$$40,
"deco-sites/storefront/sections/Miscellaneous/CookieConsent.tsx": $$$$$$39,
"deco-sites/storefront/sections/Miscellaneous/Slide.tsx": $$$$$$38,
"deco-sites/storefront/sections/Newsletter/Newsletter.tsx": $$$$$$14,
"deco-sites/storefront/sections/Product/ImageGalleryFrontBack.tsx": $$$$$$5,
"deco-sites/storefront/sections/Product/ImageGallerySlider.tsx": $$$$$$10,
"deco-sites/storefront/sections/Product/NotFound.tsx": $$$$$$3,
"deco-sites/storefront/sections/Product/NotFoundChallenge.tsx": $$$$$$9,
"deco-sites/storefront/sections/Product/ProductInfo.tsx": $$$$$$7,
"deco-sites/storefront/sections/Product/ProductShelf.tsx": $$$$$$11,
"deco-sites/storefront/sections/Product/ProductShelfTabbed.tsx": $$$$$$8,
"deco-sites/storefront/sections/Product/SearchResult.tsx": $$$$$$4,
"deco-sites/storefront/sections/Product/ShelfWithImage.tsx": $$$$$$12,
"deco-sites/storefront/sections/Product/Wishlist.tsx": $$$$$$6,
"deco-sites/storefront/sections/Social/InstagramPosts.tsx": $$$$$$0,
"deco-sites/storefront/sections/Social/WhatsApp.tsx": $$$$$$1,
"deco-sites/storefront/sections/Theme/Theme.tsx": $$$$$$13,
"deco-sites/storefront/sections/Content/BlogPosts.tsx": $$$$$$16,
"deco-sites/storefront/sections/Content/CallToAction.tsx": $$$$$$20,
"deco-sites/storefront/sections/Content/Faq.tsx": $$$$$$22,
"deco-sites/storefront/sections/Content/Features.tsx": $$$$$$15,
"deco-sites/storefront/sections/Content/Hero.tsx": $$$$$$14,
"deco-sites/storefront/sections/Content/ImageSection.tsx": $$$$$$24,
"deco-sites/storefront/sections/Content/Logos.tsx": $$$$$$19,
"deco-sites/storefront/sections/Content/RichText.tsx": $$$$$$17,
"deco-sites/storefront/sections/Content/Table.tsx": $$$$$$21,
"deco-sites/storefront/sections/Content/Testimonials.tsx": $$$$$$18,
"deco-sites/storefront/sections/Footer/Footer.tsx": $$$$$$1,
"deco-sites/storefront/sections/Gallery.tsx": $$$$$$0,
"deco-sites/storefront/sections/Header/Header.tsx": $$$$$$44,
"deco-sites/storefront/sections/Images/BannerGrid.tsx": $$$$$$6,
"deco-sites/storefront/sections/Images/Carousel.tsx": $$$$$$8,
"deco-sites/storefront/sections/Images/ImageGallery.tsx": $$$$$$7,
"deco-sites/storefront/sections/Images/ShoppableBanner.tsx": $$$$$$5,
"deco-sites/storefront/sections/Layout/Container.tsx": $$$$$$9,
"deco-sites/storefront/sections/Layout/Flex.tsx": $$$$$$11,
"deco-sites/storefront/sections/Layout/Grid.tsx": $$$$$$10,
"deco-sites/storefront/sections/Layout/GridItem.tsx": $$$$$$12,
"deco-sites/storefront/sections/Links/LinkTree.tsx": $$$$$$41,
"deco-sites/storefront/sections/Links/Shortcuts.tsx": $$$$$$42,
"deco-sites/storefront/sections/Miscellaneous/CampaignTimer.tsx": $$$$$$35,
"deco-sites/storefront/sections/Miscellaneous/CookieConsent.tsx": $$$$$$36,
"deco-sites/storefront/sections/Miscellaneous/Slide.tsx": $$$$$$37,
"deco-sites/storefront/sections/Newsletter/Newsletter.tsx": $$$$$$43,
"deco-sites/storefront/sections/Product/ImageGalleryFrontBack.tsx":
$$$$$$31,
"deco-sites/storefront/sections/Product/ImageGallerySlider.tsx": $$$$$$30,
"deco-sites/storefront/sections/Product/NotFound.tsx": $$$$$$34,
"deco-sites/storefront/sections/Product/NotFoundChallenge.tsx": $$$$$$26,
"deco-sites/storefront/sections/Product/ProductInfo.tsx": $$$$$$28,
"deco-sites/storefront/sections/Product/ProductShelf.tsx": $$$$$$29,
"deco-sites/storefront/sections/Product/ProductShelfTabbed.tsx": $$$$$$33,
"deco-sites/storefront/sections/Product/SearchResult.tsx": $$$$$$27,
"deco-sites/storefront/sections/Product/ShelfWithImage.tsx": $$$$$$32,
"deco-sites/storefront/sections/Product/Wishlist.tsx": $$$$$$25,
"deco-sites/storefront/sections/Social/InstagramPosts.tsx": $$$$$$39,
"deco-sites/storefront/sections/Social/WhatsApp.tsx": $$$$$$38,
"deco-sites/storefront/sections/Theme/Theme.tsx": $$$$$$40,
},
"apps": {
"deco-sites/storefront/apps/decohub.ts": $$$$$$$$$$$1,
"deco-sites/storefront/apps/site.ts": $$$$$$$$$$$0,
"deco-sites/storefront/apps/decohub.ts": $$$$$$$$$$$0,
"deco-sites/storefront/apps/site.ts": $$$$$$$$$$$1,
},
"name": "deco-sites/storefront",
"baseUrl": import.meta.url,
Expand Down
44 changes: 44 additions & 0 deletions sections/Content/CallToAction.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
export interface CTA {
id?: string;
href: string;
text: string;
variant: "Normal" | "Reverse";
}

export interface Props {
text: string;
cta: CTA[];
}

export default function CallToAction({ text, cta }: Props) {
return (
<div class="py-16 md:py-28">
<section class="xl:container mx-auto flex flex-col items-center justify-center gap-8 mb-16 lg:mb-0 z-10">
<h2 class="mx-6 lg:mx-0 text-center text-[36px] md:text-[80px] leading-[100%] font-medium max-w-4xl z-10">
{text}
</h2>
<div class="flex flex-col md:flex-row gap-4 z-20">
{cta?.map((item) => (
<a
key={item?.id}
id={item?.id}
href={item?.href}
target={item?.href.includes("http") ? "_blank" : "_self"}
class={`group relative overflow-hidden rounded-full hover:bg-gradient-to-r px-6 py-2 lg:px-8 lg:py-3 transition-all duration-300 ease-out ${
item.variant === "Reverse"
? "bg-secondary text-white"
: "bg-accent text-black"
}`}
>
<span class="ease absolute right-0 -mt-12 h-32 w-8 translate-x-12 rotate-12 transform bg-white opacity-10 transition-all duration-1000 group-hover:-translate-x-40">
</span>
<span class="relative font-medium lg:text-[20px]">
{item?.text}
</span>
</a>
))}
</div>
</section>
</div>
);
}
56 changes: 56 additions & 0 deletions sections/Content/Features.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
import Icon, { AvailableIcons } from "$store/components/ui/Icon.tsx";

/**
* @titleBy title
*/
export interface Card {
icon?: AvailableIcons;
/**
* @format html
*/
title: string;
text: string;
}

export interface Props {
title?: string;
cards: Card[];
}

function FeatureCard({ icon, title, text }: Card) {
return (
<div class="feature-card group group-hover:-translate-y-3">
{icon && (
<div class="p-6 rounded-full bg-white text-[#1A1A1A]">
<Icon id={icon} size={48} />
</div>
)}
<div class="space-y-4 text-center">
{title && (
<div
class="text-2xl font-semibold leading-[110%]"
dangerouslySetInnerHTML={{ __html: title }}
/>
)}
<p class="leading-[120%]" dangerouslySetInnerHTML={{ __html: text }} />
</div>
</div>
);
}

export default function Features({ title, cards }: Props) {
return (
<section class="relative bg-white text-black py-20 max-w-screen">
<div class="mx-6 lg:container lg:mx-auto flex justify-center items-center flex-col gap-20">
{title && (
<h2 class="font-medium text-[36px] lg:text-[72px] leading-[100%] text-center max-w-4xl z-10">
{title}
</h2>
)}
<div class="features">
{cards?.map((card) => <FeatureCard {...card} />)}
</div>
</div>
</section>
);
}
98 changes: 98 additions & 0 deletions sections/Content/Hero.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
import type { ImageWidget } from "apps/admin/widgets.ts";
import Image from "apps/website/components/Image.tsx";

export interface CTA {
id?: string;
href: string;
text: string;
variant: "Normal" | "Reverse";
}

export interface Props {
/**
* @format html
*/
title: string;
description: string;
image?: ImageWidget;
placement: "left" | "right";
cta: CTA[];
}

const PLACEMENT = {
left: "flex-col text-left lg:flex-row-reverse",
right: "flex-col text-left lg:flex-row",
};

export default function HeroFlats({
title,
description,
image,
placement,
cta,
}: Props) {
return (
<div>
<div class="mx-auto flex flex-col items-center gap-8">
<div
class={`flex w-full xl:container xl:mx-auto py-20 mx-5 md:mx-10 z-10 ${
image
? PLACEMENT[placement]
: "flex-col items-center justify-center text-center"
} lg:py-36 gap-12 md:gap-20 items-center`}
>
{image && (
<Image
width={640}
class="w-full lg:w-1/2 object-fit"
sizes="(max-width: 640px) 100vw, 30vw"
src={image}
alt={image}
decoding="async"
loading="lazy"
/>
)}
<div
class={`mx-6 lg:mx-auto lg:w-full space-y-4 gap-4 ${
image
? "lg:w-1/2 lg:max-w-xl"
: "flex flex-col items-center justify-center lg:max-w-3xl"
}`}
>
<div
class="inline-block text-[80px] leading-[100%] font-medium tracking-[-2.4px]"
dangerouslySetInnerHTML={{
__html: title,
}}
>
</div>
<p class="text-zinc-400 text-[16px] md:text-[18px] leading-[150%]">
{description}
</p>
<div class="flex flex-col items-center lg:items-start lg:flex-row gap-4">
{cta?.map((item) => (
<a
key={item?.id}
id={item?.id}
href={item?.href}
target={item?.href.includes("http") ? "_blank" : "_self"}
class={`group relative overflow-hidden rounded-full hover:bg-gradient-to-r px-6 py-2 lg:px-8 lg:py-3 transition-all duration-300 ease-out ${
item.variant === "Reverse"
? "bg-secondary text-white"
: "bg-accent text-black"
}`}
>
<span class="ease absolute right-0 -mt-12 h-32 w-8 translate-x-12 rotate-12 transform bg-white opacity-10 transition-all duration-1000 group-hover:-translate-x-40">
</span>
<span class="relative font-medium lg:text-[20px]">
{item?.text}
</span>
</a>
))}
</div>
</div>
</div>
</div>
</div>
);
}
Loading