import React, { useMemo } from 'react'; import { ArrowLeft, Sparkles, MapPin, Target, Zap, LayoutGrid, Users, Crown, TrendingUp } from 'lucide-react'; import { LALA_CABIN_DATA } from './constants'; import { GeometricChart } from './components/GeometricChart'; import { KeywordBubble } from './components/KeywordBubble'; import { BrandData, USP } from './types'; // Logic to calculate scores based on ICP (Ideal Customer Profile) signals const calculateDynamicScores = (data: BrandData): USP[] => { // 1. Extract Demand Signals from Targets (Needs + Triggers) const marketSignals = data.targets.flatMap(t => [...t.needs, ...t.triggers]).map(s => s.replace(/\s+/g, '')); // High value keywords that represent the "Core Value" of this specific property type const coreKeywords = ['프라이빗', '감성', '독채', '캐빈', '조명', '불멍', 'Private', 'Mood']; return data.usps.map(usp => { let calculatedScore = 65; // Base score const contentStr = (usp.label + usp.subLabel + usp.description).replace(/\s+/g, ''); // 2. Cross-reference USP with Market Signals marketSignals.forEach(signal => { if (contentStr.includes(signal)) calculatedScore += 4; }); // 3. Boost based on Core Keywords (Weighted Importance) coreKeywords.forEach(keyword => { if (contentStr.includes(keyword)) calculatedScore += 6; }); // 4. Special Boost based on specific Marketing Pillars (checking English SubLabels) if (usp.subLabel === 'CONCEPT') calculatedScore += 10; if (usp.subLabel === 'PRIVACY') calculatedScore += 8; if (usp.subLabel === 'NIGHT MOOD') calculatedScore += 8; if (usp.subLabel === 'PHOTO SPOT') calculatedScore += 5; return { ...usp, score: Math.min(Math.round(calculatedScore), 99) // Cap at 99 }; }); }; export default function App() { const rawData = LALA_CABIN_DATA; // Calculate scores on mount (or when data changes) const scoredUSPs = useMemo(() => calculateDynamicScores(rawData), [rawData]); // Find the top selling point const topUSP = useMemo(() => [...scoredUSPs].sort((a, b) => b.score - a.score)[0], [scoredUSPs]); return (
{/* Top Navigation */}
{/* Main Header */}

브랜드 인텔리전스

AI 데이터 분석을 통해 도출된 라라캐빈의 핵심 전략입니다.

{/* Grid Container */}
{/* LEFT COLUMN: Identity & Text Analysis */}
{/* Main Identity Card */}
브랜드 정체성

{rawData.name}

{rawData.address}

{rawData.subAddress}

입지 특성 분석

{rawData.locationAnalysis}

컨셉 확장성

{rawData.conceptAnalysis}

{/* Positioning & Strategy Card */}

시장 포지셔닝

카테고리 정의 {rawData.positioning.category}
핵심 가치 (Core Value) {rawData.positioning.coreValue}
{/* Target Audience Card */}

타겟 페르소나

{rawData.targets.map((target, idx) => (
{target.segment}
{target.age}
{target.needs.map((need, i) => ( {need} ))}

Trigger: {target.triggers.join(', ')}

))}
{/* RIGHT COLUMN: Visuals & Keywords */}
{/* Chart Card */}

주요 셀링 포인트 (USP)

AI Data Analysis
{/* Core Competitiveness Highlight */} {topUSP && (
Core Competitiveness
{topUSP.label}
{topUSP.subLabel}
{/* Score removed */}
)}
{scoredUSPs.filter(u => u.label !== topUSP.label).slice(0, 4).map((usp, idx) => (
{usp.subLabel}
{/* Score removed */}
{usp.label}
{usp.description}
))}
{/* Keywords Card */}

추천 타겟 키워드

{rawData.keywords.map((keyword, idx) => ( ))}
{/* Floating Action Button (Sticky Bottom) */}
); }