diff --git a/frontend/src/app/globals.css b/frontend/src/app/globals.css index 93cf287..e940acf 100644 --- a/frontend/src/app/globals.css +++ b/frontend/src/app/globals.css @@ -1029,6 +1029,7 @@ h2 { color: #3b82f6; border: 1px solid rgba(59, 130, 246, 0.3); } + /* ── Skeleton loaders ────────────────────────────────────────── */ .skeleton-shimmer { position: absolute; @@ -1222,15 +1223,76 @@ h2 { opacity: 0.85; } +/* ── Refactored Utility Classes (Issue #35) ─────────────────── */ +.portfolio-subtitle { + margin-bottom: 2.5rem; +} + +.goal-title { + font-size: 1.25rem; + margin-bottom: 4px; +} + +.goal-subtitle { + font-size: 0.9rem; +} + +.goal-status-text { + font-size: 0.85rem; + font-weight: 600; + margin-top: 4px; +} + +.progress-stats { + display: flex; + justify-content: space-between; + font-size: 0.85rem; + color: var(--text-muted); + font-weight: 500; +} + +.allocation-title { + display: flex; + align-items: center; + gap: 8px; + font-size: 1.1rem; + margin-bottom: 1.25rem; + margin-top: 1rem; +} + +.chat-title { + margin: 0; + font-size: 1.25rem; +} + +.chat-status { + display: flex; + align-items: center; + gap: 6px; + font-size: 0.85rem; + color: var(--success); +} + +.proactive-label { + display: flex; + align-items: center; + gap: 6px; + font-size: 0.75rem; + color: var(--accent-primary); + margin-bottom: 4px; + font-weight: 600; + text-transform: uppercase; +} + +/* ── Accessibility: connect-wallet focus ─────────────────────── */ .error-retry-btn:focus-visible { outline: 2px solid #fff; outline-offset: 3px; border-radius: 8px; } -/* ── Accessibility: connect-wallet focus ─────────────────────── */ .connect-wallet-btn:focus-visible { outline: 2px solid #fff; outline-offset: 3px; border-radius: 12px; -} +} \ No newline at end of file diff --git a/frontend/src/app/page.tsx b/frontend/src/app/page.tsx index f5f6967..9ce1f7b 100644 --- a/frontend/src/app/page.tsx +++ b/frontend/src/app/page.tsx @@ -82,7 +82,6 @@ export default function Home() { setWsConnected(true); setIsLoading(false); } else if (isAgentMessageNotification(notification)) { - // payload is fully typed as AgentMessagePayload — no cast needed const { text, proactive, timestamp } = notification.payload; const agentMsg: ChatMessage = { id: Date.now(), @@ -92,6 +91,7 @@ export default function Home() { timestamp, }; setMessages((prev: ChatMessage[]) => [...prev, agentMsg]); + console.log("[App] Agent message received", text); // Parse allocations if present const parsedAllocations = parseAllocationsFromMessage(text); @@ -115,6 +115,7 @@ export default function Home() { // Register goal with notification server on mount useEffect(() => { if (wsConnected) { + console.log("[App] Registering goal..."); registerGoal({ currentBalance: goalData.currentBalance, targetAmount: goalData.targetAmount, @@ -136,6 +137,7 @@ export default function Home() { }; setMessages((prev: ChatMessage[]) => [...prev, userMsg]); setIsTyping(true); + console.log("[App] User sent message:", userMsg.text); // Mock agent response delay setTimeout(() => { @@ -174,7 +176,7 @@ export default function Home() { {/* Left Panel - Dashboard */}

Smasage Portfolio

-

+

Real-time on-chain tracking • Stellar Mainnet 🚀

@@ -204,16 +206,7 @@ export default function Home() { )}
-

+

@@ -245,4 +238,4 @@ export default function Home() { ); -} +} \ No newline at end of file