Skip to content

Layout Components

Layout components provide structure and navigation for the application.

Admin-specific layout with full navigation.

Location: src/layouts/AdminLayout.vue

<template>
<AdminLayout>
<router-view />
</AdminLayout>
</template>

Tenant/company-specific layout.

Location: src/layouts/CompanyLayout.vue

<template>
<CompanyLayout>
<router-view />
</CompanyLayout>
</template>

Workspace-focused layout.

Location: src/layouts/WorkspaceLayout.vue

<template>
<WorkspaceLayout>
<router-view />
</WorkspaceLayout>
</template>

Application header with navigation and user menu.

Location: src/components/Header/

<template>
<AppHeader
:user="currentUser"
@logout="handleLogout"
/>
</template>

Navigation sidebar with menu items.

Location: src/components/SideBar/

<template>
<SideBar
:items="menuItems"
:collapsed="isCollapsed"
@toggle="toggleSidebar"
/>
</template>
<template>
<div class="page-layout">
<HeaderView title="Page Title" description="Description">
<template #actions>
<Button label="Action" />
</template>
</HeaderView>
<div class="page-content">
<!-- Page content -->
</div>
</div>
</template>
<template>
<Splitter class="h-screen">
<SplitterPanel :size="20">
<SideBar :items="menuItems" />
</SplitterPanel>
<SplitterPanel :size="80">
<router-view />
</SplitterPanel>
</Splitter>
</template>
<template>
<div class="grid grid-cols-12 gap-4">
<div class="col-span-3">
<!-- Sidebar content -->
</div>
<div class="col-span-9">
<!-- Main content -->
</div>
</div>
</template>
ComponentUsage
Splitter / SplitterPanelResizable panels
ScrollPanelScrollable content
PanelCollapsible container
CardContent card
DividerVisual separator
FieldsetGrouped content

Using Tailwind CSS breakpoints:

BreakpointSizeClass Prefix
sm640pxsm:
md768pxmd:
lg1024pxlg:
xl1280pxxl:
2xl1536px2xl:
<template>
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4">
<Card v-for="item in items" :key="item.id">
<!-- Card content -->
</Card>
</div>
</template>