Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
501 changes: 501 additions & 0 deletions .claude/commands/redesign-sidebar.md

Large diffs are not rendered by default.

155 changes: 21 additions & 134 deletions client/src/App.vue
Original file line number Diff line number Diff line change
@@ -1,40 +1,10 @@
<template>
<div class="app">
<header class="top-nav">
<div class="nav-container">
<div class="logo">
<h1>{{ t('nav.companyName') }}</h1>
<span class="subtitle">{{ t('nav.subtitle') }}</span>
</div>
<nav class="nav-tabs">
<router-link to="/" :class="{ active: $route.path === '/' }">
{{ t('nav.overview') }}
</router-link>
<router-link to="/inventory" :class="{ active: $route.path === '/inventory' }">
{{ t('nav.inventory') }}
</router-link>
<router-link to="/orders" :class="{ active: $route.path === '/orders' }">
{{ t('nav.orders') }}
</router-link>
<router-link to="/spending" :class="{ active: $route.path === '/spending' }">
{{ t('nav.finance') }}
</router-link>
<router-link to="/demand" :class="{ active: $route.path === '/demand' }">
{{ t('nav.demandForecast') }}
</router-link>
<router-link to="/reports" :class="{ active: $route.path === '/reports' }">
Reports
</router-link>
</nav>
<LanguageSwitcher />
<ProfileMenu
@show-profile-details="showProfileDetails = true"
@show-tasks="showTasks = true"
/>
</div>
</header>
<FilterBar />
<main class="main-content">
<AppSidebar
@show-profile-details="showProfileDetails = true"
@show-tasks="showTasks = true"
/>
<main class="main-content" :class="{ 'sidebar-collapsed': isCollapsed }">
<router-view />
</main>

Expand All @@ -58,25 +28,21 @@
import { ref, onMounted, computed } from 'vue'
import { api } from './api'
import { useAuth } from './composables/useAuth'
import { useI18n } from './composables/useI18n'
import FilterBar from './components/FilterBar.vue'
import ProfileMenu from './components/ProfileMenu.vue'
import { useSidebar } from './composables/useSidebar'
import AppSidebar from './components/AppSidebar.vue'
import ProfileDetailsModal from './components/ProfileDetailsModal.vue'
import TasksModal from './components/TasksModal.vue'
import LanguageSwitcher from './components/LanguageSwitcher.vue'

export default {
name: 'App',
components: {
FilterBar,
ProfileMenu,
AppSidebar,
ProfileDetailsModal,
TasksModal,
LanguageSwitcher
TasksModal
},
setup() {
const { currentUser } = useAuth()
const { t } = useI18n()
const { isCollapsed } = useSidebar()
const showProfileDetails = ref(false)
const showTasks = ref(false)
const apiTasks = ref([])
Expand Down Expand Up @@ -149,13 +115,13 @@ export default {
onMounted(loadTasks)

return {
t,
showProfileDetails,
showTasks,
tasks,
addTask,
deleteTask,
toggleTask
toggleTask,
isCollapsed
}
}
}
Expand All @@ -178,100 +144,21 @@ body {

.app {
display: flex;
flex-direction: column;
flex-direction: row;
min-height: 100vh;
}

.top-nav {
background: #ffffff;
border-bottom: 1px solid #e2e8f0;
box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
position: sticky;
top: 0;
z-index: 100;
}

.nav-container {
max-width: 1600px;
margin: 0 auto;
display: flex;
align-items: center;
padding: 0 2rem;
height: 70px;
}

.nav-container > .nav-tabs {
margin-left: auto;
margin-right: 1rem;
}

.nav-container > .language-switcher {
margin-right: 1rem;
}

.logo {
display: flex;
align-items: baseline;
gap: 0.75rem;
}

.logo h1 {
font-size: 1.375rem;
font-weight: 700;
color: #0f172a;
letter-spacing: -0.025em;
}

.subtitle {
font-size: 0.813rem;
color: #64748b;
font-weight: 400;
padding-left: 0.75rem;
border-left: 1px solid #e2e8f0;
}

.nav-tabs {
display: flex;
gap: 0.25rem;
}

.nav-tabs a {
padding: 0.625rem 1.25rem;
color: #64748b;
text-decoration: none;
font-weight: 500;
font-size: 0.938rem;
border-radius: 6px;
transition: all 0.2s ease;
position: relative;
}

.nav-tabs a:hover {
color: #0f172a;
background: #f1f5f9;
}

.nav-tabs a.active {
color: #2563eb;
background: #eff6ff;
}

.nav-tabs a.active::after {
content: '';
position: absolute;
bottom: -1px;
left: 0;
right: 0;
height: 2px;
background: #2563eb;
}

.main-content {
flex: 1;
max-width: 1600px;
width: 100%;
margin: 0 auto;
margin-left: 240px;
padding: 1.5rem 2rem;
min-height: 100vh;
overflow-y: auto;
transition: margin-left 0.2s ease;
}

.main-content.sidebar-collapsed {
margin-left: 56px;
}

.page-header {
Expand Down
Loading
Loading