From afc4e131b0fd1601cabc72ac5dc97568e936cebc Mon Sep 17 00:00:00 2001 From: Pichikachu Date: Tue, 26 May 2026 16:40:41 +0200 Subject: [PATCH 1/2] add visual clarity polish --- .../Dasboard/DashboardEmptyState.tsx | 61 +++++- .../dashboardChat/DashboardChatPanel.tsx | 14 +- .../workspace/WorkspaceStudioShell.tsx | 174 ++++++++++++++++-- 3 files changed, 229 insertions(+), 20 deletions(-) diff --git a/apps/studymesh/src/components/Dasboard/DashboardEmptyState.tsx b/apps/studymesh/src/components/Dasboard/DashboardEmptyState.tsx index dbbd3360..affedb67 100644 --- a/apps/studymesh/src/components/Dasboard/DashboardEmptyState.tsx +++ b/apps/studymesh/src/components/Dasboard/DashboardEmptyState.tsx @@ -170,6 +170,30 @@ const DashboardEmptyState = ({ Create a guided Study Path, or add material first to generate a focused quiz, flashcards, or clean notes. + + {['1 Add material', '2 Pick output', '3 Review dashboard'].map( + (label) => ( + + alpha(theme.palette.primary.main, 0.08), + border: 1, + borderColor: (theme) => + alpha(theme.palette.primary.main, 0.16), + }} + /> + ), + )} + - Upload material + + Upload material + + PDF, slides, images, text + + @@ -305,7 +348,8 @@ const DashboardEmptyState = ({ color="text.secondary" sx={{ mt: 0.3 }} > - This dashboard is empty, so add sources in Creation first. + This dashboard is empty, so these actions open Create from + Material with the right setup ready. {action.label} + diff --git a/apps/studymesh/src/components/dashboardChat/DashboardChatPanel.tsx b/apps/studymesh/src/components/dashboardChat/DashboardChatPanel.tsx index 56f8cd44..13d9e65f 100644 --- a/apps/studymesh/src/components/dashboardChat/DashboardChatPanel.tsx +++ b/apps/studymesh/src/components/dashboardChat/DashboardChatPanel.tsx @@ -314,8 +314,20 @@ const DashboardChatPanel = ({ borderColor: 'divider', borderRadius: 2.5, bgcolor: 'background.paper', + background: + theme.palette.mode === 'dark' + ? 'linear-gradient(135deg, rgba(34,197,94,0.10), rgba(14,165,233,0.06))' + : 'linear-gradient(135deg, rgba(34,197,94,0.08), rgba(14,165,233,0.05))', }} > + + Grounded chat + What do you want to understand? @@ -325,7 +337,7 @@ const DashboardChatPanel = ({ - {suggestions.map((suggestion) => ( + {suggestions.map((suggestion, index) => ( {!hasCurrentDashboardContext && @@ -1456,7 +1590,7 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { sx={{ maxWidth: 300 }} > Drop notes here, or upload text, images, PDFs, and - slides. + slides. Your selected files stay in this Creation panel. ))} - + ) : ( diff --git a/apps/studymesh/src/components/topnavbar/TopNavBar.tsx b/apps/studymesh/src/components/topnavbar/TopNavBar.tsx index 26821dad..26b0b10a 100644 --- a/apps/studymesh/src/components/topnavbar/TopNavBar.tsx +++ b/apps/studymesh/src/components/topnavbar/TopNavBar.tsx @@ -708,14 +708,17 @@ const TopNavBar: React.FC = ({ creationHost = 'navbar' }) => { position="static" sx={{ backgroundColor: 'background.header', - boxShadow: 2, - height: isMobileWorkspaceHeader ? '56px' : '52px', + backgroundImage: + 'linear-gradient(90deg, rgba(34,197,94,0.22), rgba(14,165,233,0.12) 38%, rgba(182,108,255,0.14))', + borderBottom: '1px solid rgba(255,255,255,0.10)', + boxShadow: '0 18px 48px rgba(2, 6, 23, 0.24)', + height: isMobileWorkspaceHeader ? '64px' : '60px', }} > = ({ creationHost = 'navbar' }) => { color: 'foreground.contrastPrimary', textTransform: 'none', borderRadius: 999, - bgcolor: 'rgba(255,255,255,0.08)', + bgcolor: 'rgba(255,255,255,0.12)', + border: '1px solid rgba(255,255,255,0.16)', + boxShadow: 'inset 0 1px 0 rgba(255,255,255,0.18)', '&:hover': { bgcolor: 'rgba(255,255,255,0.14)' }, '& .MuiButton-endIcon': { ml: 0.25, mr: 0 }, }} diff --git a/apps/studymesh/src/components/workspace/WorkspaceStudioLayouts.tsx b/apps/studymesh/src/components/workspace/WorkspaceStudioLayouts.tsx index 7ffac049..4665476e 100644 --- a/apps/studymesh/src/components/workspace/WorkspaceStudioLayouts.tsx +++ b/apps/studymesh/src/components/workspace/WorkspaceStudioLayouts.tsx @@ -1,7 +1,7 @@ import React from 'react' import { Box, Slide, Tooltip, Typography } from '@mui/material' import AddIcon from '@mui/icons-material/Add' -import type { Theme } from '@mui/material/styles' +import { alpha, type Theme } from '@mui/material/styles' import { studioPanelRailWidth, workspaceCanvasSx } from './workspaceStudioModel' @@ -37,6 +37,10 @@ export const WorkspaceMobileLayout = ({ display: 'flex', flexDirection: 'column', bgcolor: 'background.default', + background: + theme.palette.mode === 'dark' + ? `radial-gradient(circle at 50% -10%, ${alpha(theme.palette.primary.main, 0.24)}, transparent 34%), #020617` + : `radial-gradient(circle at 50% -10%, ${alpha(theme.palette.primary.main, 0.14)}, transparent 34%), #f8fff9`, '--studymesh-mobile-generation-tray-height': visibleCreationMarkerCount ? '48px' : '0px', @@ -77,7 +81,7 @@ export const WorkspaceMobileLayout = ({ position: 'absolute', inset: 0, overflow: 'hidden', - p: '8px', + p: '12px', boxSizing: 'border-box', zIndex: 2, bgcolor: 'background.default', @@ -89,7 +93,7 @@ export const WorkspaceMobileLayout = ({ overflow: 'hidden', border: 1, borderColor: 'divider', - borderRadius: 2, + borderRadius: 4, bgcolor: 'background.paper', boxShadow: theme.palette.mode === 'dark' @@ -138,6 +142,10 @@ export const WorkspaceDesktopLayout = ({ display: 'flex', overflow: 'hidden', bgcolor: 'background.default', + background: + theme.palette.mode === 'dark' + ? `radial-gradient(circle at 0% 0%, ${alpha(theme.palette.primary.main, 0.22)}, transparent 30%), radial-gradient(circle at 88% 12%, ${alpha(theme.palette.warning.main, 0.14)}, transparent 28%), linear-gradient(135deg, ${alpha('#020617', 0.98)}, ${alpha('#07111f', 0.96)})` + : `radial-gradient(circle at 0% 0%, ${alpha(theme.palette.primary.main, 0.14)}, transparent 30%), radial-gradient(circle at 88% 12%, ${alpha(theme.palette.warning.main, 0.12)}, transparent 28%), linear-gradient(135deg, #f8fff9, #eef7ff)`, }} > @@ -183,8 +195,12 @@ export const WorkspaceDesktopLayout = ({ height: '100%', border: 1, borderColor: 'divider', - borderRadius: 2.5, + borderRadius: 999, bgcolor: 'background.paper', + background: + theme.palette.mode === 'dark' + ? `linear-gradient(180deg, ${alpha(theme.palette.primary.main, 0.2)}, ${alpha(theme.palette.background.paper, 0.95)})` + : `linear-gradient(180deg, ${alpha(theme.palette.primary.main, 0.14)}, ${alpha(theme.palette.background.paper, 0.98)})`, color: 'primary.main', cursor: 'pointer', display: 'flex', @@ -249,6 +265,7 @@ export const WorkspaceDesktopLayout = ({ sx={{ flex: 1, minWidth: 0, + p: '14px', ...workspaceCanvasSx, transition: theme.transitions.create('padding', { duration: theme.transitions.duration.shorter, @@ -260,10 +277,14 @@ export const WorkspaceDesktopLayout = ({ height: '100%', minHeight: 0, overflow: 'hidden', - borderRadius: 2, + borderRadius: 4, bgcolor: 'background.paper', border: 1, - borderColor: 'divider', + borderColor: alpha(theme.palette.primary.main, 0.16), + boxShadow: + theme.palette.mode === 'dark' + ? `0 28px 90px ${alpha('#000', 0.48)}` + : `0 24px 70px ${alpha('#0f172a', 0.12)}`, }} > {children} diff --git a/apps/studymesh/src/components/workspace/WorkspaceStudioShell.tsx b/apps/studymesh/src/components/workspace/WorkspaceStudioShell.tsx index 8dc035ad..bfecd427 100644 --- a/apps/studymesh/src/components/workspace/WorkspaceStudioShell.tsx +++ b/apps/studymesh/src/components/workspace/WorkspaceStudioShell.tsx @@ -898,6 +898,30 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { ] const studyPathOption = createOptions[0] + const commandStats = [ + { label: 'Primary route', value: 'Study Path' }, + { + label: 'Fast lane', + value: hasCurrentDashboardContext ? '1-click ready' : 'Needs source', + }, + { label: 'Material lab', value: quickSourceLabel }, + ] + const sourceFlowSteps = [ + { + label: 'Output', + value: selectedQuickCreateIntent + ? quickCreateLabels[selectedQuickCreateIntent] + : 'Pick a target', + }, + { + label: 'Source', + value: quickSourceMode === 'dashboard' ? 'Dashboard' : quickSourceLabel, + }, + { + label: 'Finish', + value: quickCanCreateFromActiveSource ? 'Ready' : 'Waiting', + }, + ] const returnToCreateHub = () => { setActiveFlow('hub') @@ -929,59 +953,108 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { }} > - - - - Creation - - - Create a guided study path or quick material from your dashboard. - - + + + + + StudyMesh command center + + + Build the next learning surface. + + + Big guided paths, instant review material, or a focused source + lab — all from one launch deck. + + + + + + + - {[ - 'Study Path', - hasCurrentDashboardContext ? 'Dashboard ready' : 'Add material', - 'Ask Sources', - ].map((label) => ( - ( + + > + + {stat.label} + + + {stat.value} + + ))} - - - - - - + + + {!quickOptionsOpen ? ( <> @@ -992,18 +1065,21 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { elevation={0} sx={{ width: '100%', - p: { xs: 2, sm: 2.25 }, + p: { xs: 2.4, sm: 3 }, textAlign: 'left', - borderRadius: 3, + borderRadius: 4, border: 1, borderColor: alpha(theme.palette.primary.main, 0.42), - bgcolor: alpha(theme.palette.primary.main, 0.075), + bgcolor: alpha( + theme.palette.primary.main, + theme.palette.mode === 'dark' ? 0.16 : 0.1, + ), color: 'text.primary', cursor: 'pointer', display: 'block', position: 'relative', overflow: 'hidden', - boxShadow: `0 14px 36px ${alpha(theme.palette.primary.main, 0.1)}`, + boxShadow: `0 28px 80px ${alpha(theme.palette.primary.main, theme.palette.mode === 'dark' ? 0.22 : 0.14)}`, '&::before': { content: '""', position: 'absolute', @@ -1027,7 +1103,7 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { 'background-color 160ms ease, border-color 160ms ease, transform 160ms ease', }} > - + { > Recommended - + Study Path @@ -1069,8 +1145,14 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { Creates lessons, dashboards, exercises and flashcards. - - {['Lessons', 'Exercises', 'Review'].map((label) => ( + + {['01 Lessons', '02 Exercises', '03 Review'].map((label) => ( { }} /> ))} - + - + + ) + }, + )} + + + + ) : ( @@ -1299,8 +1402,28 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { > ← Back to Creation - - + + + Material lab + + Create from Material { Add files, pasted notes, images, PDFs, or slides, then choose what StudyMesh should create. - - {['1 Output', '2 Source', '3 Options'].map((label) => ( - + {sourceFlowSteps.map((step, index) => ( + + + 0{index + 1} · {step.label} + + + {step.value} + + ))} - - + + )} @@ -1335,14 +1476,14 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { ref={quickOptionsPanelRef} elevation={0} sx={{ - p: { xs: 1.5, sm: 1.75 }, + p: { xs: 1.6, sm: 2 }, border: 1, borderColor: quickHasCustomSources ? alpha(theme.palette.primary.main, 0.45) : hasCurrentDashboardContext ? 'divider' : alpha(theme.palette.warning.main, 0.65), - borderRadius: 2.5, + borderRadius: 3.5, bgcolor: theme.palette.mode === 'dark' ? alpha(theme.palette.background.paper, 0.92) @@ -1468,7 +1609,8 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { sx={{ textTransform: 'none', flex: 1, - borderRadius: 1.5, + borderRadius: 2.5, + minHeight: 72, fontWeight: 900, }} > @@ -1504,7 +1646,8 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { sx={{ textTransform: 'none', flex: 1, - borderRadius: 1.5, + borderRadius: 2.5, + minHeight: 72, fontWeight: 900, }} > @@ -1540,9 +1683,9 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { onDrop={handleQuickSourceDrop} onDragOver={(event) => event.preventDefault()} sx={{ - minHeight: 210, - p: 2, - border: '1.5px dashed', + minHeight: 270, + p: 2.5, + border: '2px dashed', borderColor: quickSourceFiles.length ? 'primary.main' : 'divider', @@ -1567,9 +1710,9 @@ const WorkspaceStudioShell = ({ children }: { children: React.ReactNode }) => { >