-
Notifications
You must be signed in to change notification settings - Fork 0
Feature/CDP-174-LandingFeature1 #51
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
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
6b719f0
CDP-175 refactor๐จ (landing): ํ์ด๋ก cta & main section css ์์
leeunduck 6f55483
CDP-174 refactor๐จ (landing): main section css ์์
leeunduck 2c547fb
CDP-175 featโจ (landing): feature section ์ปดํฌ๋ํธ ์ถ๊ฐ
leeunduck 7abe7ff
CDP-176 featโจ (landing): feature grid ์ปดํฌ๋ํธ ์ถ๊ฐ
leeunduck File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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,27 @@ | ||
| "use client"; | ||
|
|
||
| import { FEATURES } from "@/lib/constants"; | ||
| import { cn } from "@/lib/utils"; | ||
| import { FeatureButton } from "@/shared/FeatureButton"; | ||
| import { Icon } from "@/shared/Icon"; | ||
| import { useFeaturePreviewStore } from "@/stores/featurePreviewStore"; | ||
| import type { LandingFeatureGridProps } from "@/types/landing"; | ||
|
|
||
| export function LandingFeatureGrid({ className }: LandingFeatureGridProps) { | ||
| const setActiveFeature = useFeaturePreviewStore((state) => state.setActiveFeature); | ||
|
|
||
| return ( | ||
| <div className={cn("grid grid-cols-1 gap-3", "md:grid-cols-2 md:gap-8", className)}> | ||
| {FEATURES.map((feature) => ( | ||
| <FeatureButton | ||
| key={feature.title} | ||
| icon={<Icon name={feature.iconName} size={19} />} | ||
| title={feature.title} | ||
| description={feature.description} | ||
| onMouseEnter={() => setActiveFeature(feature)} | ||
| onFocus={() => setActiveFeature(feature)} | ||
| /> | ||
| ))} | ||
| </div> | ||
| ); | ||
| } |
This file contains hidden or 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,57 @@ | ||
| "use client"; | ||
|
|
||
| import { LandingFeatureGrid } from "@/components/landing/LandingFeatureGrid"; | ||
| import { cn } from "@/lib/utils"; | ||
| import { useFeaturePreviewStore } from "@/stores/featurePreviewStore"; | ||
| import type { LandingFeaturesSection1Props } from "@/types/landing"; | ||
| import Image from "next/image"; | ||
|
|
||
| export function LandingFeaturesSection1({ className }: LandingFeaturesSection1Props) { | ||
| const activeFeature = useFeaturePreviewStore((state) => state.activeFeature); | ||
|
|
||
| return ( | ||
| <section | ||
| id="landing-features1" | ||
| aria-labelledby="landing-features1-title" | ||
| className={cn( | ||
| "grid gap-18", | ||
| "md:grid-cols-[minmax(0,1.1fr)_minmax(0,0.9fr)] md:items-center", | ||
| className, | ||
| )} | ||
| > | ||
| {/* Left: ์ ๋ชฉ + ๊ธฐ๋ฅ ๋ฆฌ์คํธ */} | ||
| <div className="space-y-8"> | ||
| <header className="space-y-6"> | ||
| <h2 | ||
| id="landing-features1-title" | ||
| className="t-30-b md:t-40-b text-[var(--color-gray-900)]" | ||
| > | ||
| ํ์ํ ๊ธฐ๋ฅ๋ง ๊ณจ๋ผ ์ฐ๋ | ||
| <br /> | ||
| ๋ฐ์ผ๋ฆฌ ํ๋๋ | ||
| </h2> | ||
| <p className="t-12-m md:t-16-m text-[var(--color-gray-600)]"> | ||
| ๋์๊ฒ ํ์ํ ๋ชจ๋๋ง ์ ํํด ๋๋ง์ ํ๋๋๋ฅผ ๋ง๋ค ์ ์์ต๋๋ค. | ||
| </p> | ||
| </header> | ||
|
|
||
| <LandingFeatureGrid /> | ||
| </div> | ||
|
|
||
| {/* Right: ํ๋ฉด ๋ฏธ๋ฆฌ๋ณด๊ธฐ ์นด๋ */} | ||
| <div className="relative"> | ||
| <div className="relative mx-auto max-w-full rounded-[32px] bg-[var(--color-gray-50)]"> | ||
| <div className="relative aspect-[16/10] w-full overflow-hidden rounded-3xl bg-[var(--color-white)] shadow-[0_18px_60px_rgba(0,0,0,0.12)]"> | ||
| <Image | ||
| src={activeFeature.previewImageSrc} | ||
| alt={`${activeFeature.title} ํ๋๋ ํ๋ฉด ๋ฏธ๋ฆฌ๋ณด๊ธฐ`} | ||
| fill | ||
| className="object-cover" | ||
| sizes="(min-width: 1024px) 480px, 100vw" | ||
| /> | ||
| </div> | ||
| </div> | ||
| </div> | ||
| </section> | ||
| ); | ||
| } |
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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,15 @@ | ||
| "use client"; | ||
|
|
||
| import { FEATURES } from "@/lib/constants"; | ||
| import type { FeatureItem } from "@/types/landing"; | ||
| import { create } from "zustand"; | ||
|
|
||
| type FeaturePreviewState = { | ||
| activeFeature: FeatureItem; | ||
| setActiveFeature: (feature: FeatureItem) => void; | ||
| }; | ||
|
|
||
| export const useFeaturePreviewStore = create<FeaturePreviewState>((set) => ({ | ||
| activeFeature: FEATURES[0], // ๊ธฐ๋ณธ: "์ผ๊ฐ" | ||
| setActiveFeature: (feature) => set({ activeFeature: feature }), | ||
| })); |
This file was deleted.
Oops, something went wrong.
This file contains hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new
FEATURESmetadata references six local preview images (e.g."/images/feature-daily.png") that are rendered inLandingFeaturesSection1, but thepublic/imagesdirectory only containslogo.png. At runtime the preview<Image>in the landing page will try to load these files and each request will return 404, so the main visual element of the new feature section will appear broken. Please add the images or point the constants at existing assets.Useful? React with ๐ย / ๐.