Skip to content

Commit 257a9a2

Browse files
committed
Adding UI updates to vue starter kit
1 parent 0d02e40 commit 257a9a2

30 files changed

+169
-161
lines changed

app/Http/Controllers/Auth/PasswordResetLinkController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,6 @@ public function store(Request $request): RedirectResponse
3636
$request->only('email')
3737
);
3838

39-
return back()->with('status', __('If an account exists with that email, you’ll receive a reset link shortly.'));
39+
return back()->with('status', __('A reset link will be sent if the account exists.'));
4040
}
4141
}

resources/css/app.css

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
@tailwind components;
33
@tailwind utilities;
44

5+
body,
6+
html {
7+
--font-sans: 'Inter var', ui-sans-serif, system-ui, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
8+
}
9+
510
@layer base {
611
:root {
712
--background: 0 0% 100%;
@@ -83,4 +88,4 @@
8388
body {
8489
@apply bg-background text-foreground;
8590
}
86-
}
91+
}

resources/js/components/AppHeader.vue

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import UserMenuContent from '@/components/UserMenuContent.vue';
1717
import { getInitials } from '@/composables/useInitials';
1818
import type { BreadcrumbItem, NavItem } from '@/types';
1919
import { Link, usePage } from '@inertiajs/vue3';
20-
import { BookOpenText, ChevronDown, FolderGit2, LayoutGrid, Menu, Search } from 'lucide-vue-next';
20+
import { BookOpen, Folder, ChevronDown, LayoutGrid, Menu, Search } from 'lucide-vue-next';
2121
import { computed } from 'vue';
2222
2323
interface Props {
@@ -36,7 +36,7 @@ const isCurrentRoute = (url: string) => {
3636
};
3737
3838
const activeItemStyles = computed(
39-
() => (url: string) => (isCurrentRoute(url) ? 'bg-neutral-100 text-neutral-900 dark:bg-neutral-800 dark:text-neutral-100' : ''),
39+
() => (url: string) => (isCurrentRoute(url) ? 'text-neutral-900 dark:bg-neutral-800 dark:text-neutral-100' : ''),
4040
);
4141
4242
const mainNavItems: NavItem[] = [
@@ -51,12 +51,12 @@ const rightNavItems: NavItem[] = [
5151
{
5252
title: 'Repository',
5353
url: 'https://github.com/laravel/vue-starter-kit',
54-
icon: FolderGit2,
54+
icon: Folder,
5555
},
5656
{
5757
title: 'Documentation',
5858
url: 'https://laravel.com/docs/starter-kits',
59-
icon: BookOpenText,
59+
icon: BookOpen,
6060
},
6161
];
6262
</script>
@@ -134,19 +134,19 @@ const rightNavItems: NavItem[] = [
134134

135135
<div class="ml-auto flex items-center space-x-2">
136136
<div class="relative flex items-center space-x-1">
137-
<Button variant="ghost" size="icon" class="h-9 w-9 cursor-pointer">
138-
<Search class="h-5 w-5" />
137+
<Button variant="ghost" size="icon" class="h-9 w-9 cursor-pointer group">
138+
<Search class="size-5 opacity-80 group-hover:opacity-100" />
139139
</Button>
140140

141141
<div class="hidden space-x-1 lg:flex">
142142
<template v-for="item in rightNavItems" :key="item.title">
143143
<TooltipProvider :delay-duration="0">
144144
<Tooltip>
145145
<TooltipTrigger>
146-
<Button variant="ghost" size="icon" as-child class="h-9 w-9 cursor-pointer">
146+
<Button variant="ghost" size="icon" as-child class="h-9 w-9 group cursor-pointer">
147147
<a :href="item.url" target="_blank" rel="noopener noreferrer">
148148
<span class="sr-only">{{ item.title }}</span>
149-
<component :is="item.icon" class="h-5 w-5" />
149+
<component :is="item.icon" class="size-5 opacity-80 group-hover:opacity-100" />
150150
</a>
151151
</Button>
152152
</TooltipTrigger>
@@ -161,8 +161,8 @@ const rightNavItems: NavItem[] = [
161161

162162
<DropdownMenu>
163163
<DropdownMenuTrigger :as-child="true">
164-
<Button variant="ghost" size="icon" class="relative h-9 w-auto rounded-md px-1">
165-
<Avatar className="h-7 w-7 overflow-hidden rounded-lg">
164+
<Button variant="ghost" size="icon" class="relative size-10 w-auto rounded-full p-1">
165+
<Avatar className="size-8 overflow-hidden rounded-full">
166166
<AvatarImage :src="auth.user.avatar" :alt="auth.user.name" />
167167
<AvatarFallback class="rounded-lg bg-neutral-200 text-black dark:bg-neutral-700 dark:text-white">
168168
{{ getInitials(auth.user?.name) }}

resources/js/components/AppLogo.vue

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,10 @@ defineProps<Props>();
99
</script>
1010

1111
<template>
12-
<div class="flex aspect-square size-8 items-center justify-center rounded-md bg-sidebar-primary text-sidebar-primary-foreground">
13-
<AppLogoIcon class="size-5 fill-current text-white dark:text-black" />
12+
<div className="bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-md">
13+
<AppLogoIcon className="size-[1.2rem] fill-current text-white dark:text-black" />
1414
</div>
15-
<div class="grid flex-1 text-left text-sm leading-tight">
16-
<span class="mb-0.5 truncate font-semibold leading-none">Laravel</span>
17-
<span class="truncate text-[11px] leading-none tracking-tight opacity-80">Starter Kit</span>
15+
<div className="ml-1 grid flex-1 text-left text-sm">
16+
<span className="mb-0.5 truncate leading-none font-semibold">Laravel Starter Kit</span>
1817
</div>
1918
</template>

resources/js/components/AppLogoIcon.vue

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,11 @@ defineProps<Props>();
1313
</script>
1414

1515
<template>
16-
<svg viewBox="0 0 316 316" xmlns="http://www.w3.org/2000/svg" :class="className" v-bind="$attrs">
16+
<svg viewBox="0 0 40 42" xmlns="http://www.w3.org/2000/svg" :class="className" v-bind="$attrs">
1717
<path
18-
fill="currentColor"
19-
d="M305.8 81.125C305.77 80.995 305.69 80.885 305.65 80.755C305.56 80.525 305.49 80.285 305.37 80.075C305.29 79.935 305.17 79.815 305.07 79.685C304.94 79.515 304.83 79.325 304.68 79.175C304.55 79.045 304.39 78.955 304.25 78.845C304.09 78.715 303.95 78.575 303.77 78.475L251.32 48.275C249.97 47.495 248.31 47.495 246.96 48.275L194.51 78.475C194.33 78.575 194.19 78.725 194.03 78.845C193.89 78.955 193.73 79.045 193.6 79.175C193.45 79.325 193.34 79.515 193.21 79.685C193.11 79.815 192.99 79.935 192.91 80.075C192.79 80.285 192.71 80.525 192.63 80.755C192.58 80.875 192.51 80.995 192.48 81.125C192.38 81.495 192.33 81.875 192.33 82.265V139.625L148.62 164.795V52.575C148.62 52.185 148.57 51.805 148.47 51.435C148.44 51.305 148.36 51.195 148.32 51.065C148.23 50.835 148.16 50.595 148.04 50.385C147.96 50.245 147.84 50.125 147.74 49.995C147.61 49.825 147.5 49.635 147.35 49.485C147.22 49.355 147.06 49.265 146.92 49.155C146.76 49.025 146.62 48.885 146.44 48.785L93.99 18.585C92.64 17.805 90.98 17.805 89.63 18.585L37.18 48.785C37 48.885 36.86 49.035 36.7 49.155C36.56 49.265 36.4 49.355 36.27 49.485C36.12 49.635 36.01 49.825 35.88 49.995C35.78 50.125 35.66 50.245 35.58 50.385C35.46 50.595 35.38 50.835 35.3 51.065C35.25 51.185 35.18 51.305 35.15 51.435C35.05 51.805 35 52.185 35 52.575V232.235C35 233.795 35.84 235.245 37.19 236.025L142.1 296.425C142.33 296.555 142.58 296.635 142.82 296.725C142.93 296.765 143.04 296.835 143.16 296.865C143.53 296.965 143.9 297.015 144.28 297.015C144.66 297.015 145.03 296.965 145.4 296.865C145.5 296.835 145.59 296.775 145.69 296.745C145.95 296.655 146.21 296.565 146.45 296.435L251.36 236.035C252.72 235.255 253.55 233.815 253.55 232.245V174.885L303.81 145.945C305.17 145.165 306 143.725 306 142.155V82.265C305.95 81.875 305.89 81.495 305.8 81.125ZM144.2 227.205L100.57 202.515L146.39 176.135L196.66 147.195L240.33 172.335L208.29 190.625L144.2 227.205ZM244.75 114.995V164.795L226.39 154.225L201.03 139.625V89.825L219.39 100.395L244.75 114.995ZM249.12 57.105L292.81 82.265L249.12 107.425L205.43 82.265L249.12 57.105ZM114.49 184.425L96.13 194.995V85.305L121.49 70.705L139.85 60.135V169.815L114.49 184.425ZM91.76 27.425L135.45 52.585L91.76 77.745L48.07 52.585L91.76 27.425ZM43.67 60.135L62.03 70.705L87.39 85.305V202.545V202.555V202.565C87.39 202.735 87.44 202.895 87.46 203.055C87.49 203.265 87.49 203.485 87.55 203.695V203.705C87.6 203.875 87.69 204.035 87.76 204.195C87.84 204.375 87.89 204.575 87.99 204.745C87.99 204.745 87.99 204.755 88 204.755C88.09 204.905 88.22 205.035 88.33 205.175C88.45 205.335 88.55 205.495 88.69 205.635L88.7 205.645C88.82 205.765 88.98 205.855 89.12 205.965C89.28 206.085 89.42 206.225 89.59 206.325C89.6 206.325 89.6 206.325 89.61 206.335C89.62 206.335 89.62 206.345 89.63 206.345L139.87 234.775V285.065L43.67 229.705V60.135ZM244.75 229.705L148.58 285.075V234.775L219.8 194.115L244.75 179.875V229.705ZM297.2 139.625L253.49 164.795V114.995L278.85 100.395L297.21 89.825V139.625H297.2Z"
18+
fillRule="evenodd"
19+
clipRule="evenodd"
20+
d="M17.2 5.63325L8.6 0.855469L0 5.63325V32.1434L16.2 41.1434L32.4 32.1434V23.699L40 19.4767V9.85547L31.4 5.07769L22.8 9.85547V18.2999L17.2 21.411V5.63325ZM38 18.2999L32.4 21.411V15.2545L38 12.1434V18.2999ZM36.9409 10.4439L31.4 13.5221L25.8591 10.4439L31.4 7.36561L36.9409 10.4439ZM24.8 18.2999V12.1434L30.4 15.2545V21.411L24.8 18.2999ZM23.8 20.0323L29.3409 23.1105L16.2 30.411L10.6591 27.3328L23.8 20.0323ZM7.6 27.9212L15.2 32.1434V38.2999L2 30.9666V7.92116L7.6 11.0323V27.9212ZM8.6 9.29991L3.05913 6.22165L8.6 3.14339L14.1409 6.22165L8.6 9.29991ZM30.4 24.8101L17.2 32.1434V38.2999L30.4 30.9666V24.8101ZM9.6 11.0323L15.2 7.92117V22.5221L9.6 25.6333V11.0323Z"
2021
/>
2122
</svg>
2223
</template>

resources/js/components/AppSidebar.vue

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,27 @@ import NavMain from '@/components/NavMain.vue';
44
import NavUser from '@/components/NavUser.vue';
55
import { Sidebar, SidebarContent, SidebarFooter, SidebarHeader, SidebarMenu, SidebarMenuButton, SidebarMenuItem } from '@/components/ui/sidebar';
66
import { type NavItem } from '@/types';
7-
import { BookOpenText, FolderGit2, LayoutDashboard } from 'lucide-vue-next';
7+
import { BookOpen, Folder, LayoutGrid } from 'lucide-vue-next';
88
import AppLogo from './AppLogo.vue';
99
1010
const mainNavItems: NavItem[] = [
1111
{
1212
title: 'Dashboard',
1313
url: '/dashboard',
14-
icon: LayoutDashboard,
14+
icon: LayoutGrid,
1515
},
1616
];
1717
1818
const footerNavItems: NavItem[] = [
1919
{
2020
title: 'Github Repo',
2121
url: 'https://github.com/laravel/vue-starter-kit',
22-
icon: FolderGit2,
22+
icon: Folder,
2323
},
2424
{
2525
title: 'Documentation',
2626
url: 'https://laravel.com/docs/starter-kits',
27-
icon: BookOpenText,
27+
icon: BookOpen,
2828
},
2929
];
3030
</script>
@@ -35,16 +35,8 @@ const footerNavItems: NavItem[] = [
3535
<SidebarMenu>
3636
<SidebarMenuItem>
3737
<SidebarMenuButton size="lg" as-child>
38-
<a href="#">
39-
<div
40-
class="flex aspect-square size-8 items-center justify-center rounded-md bg-sidebar-primary text-sidebar-primary-foreground"
41-
>
42-
<AppLogo class="size-5 fill-current text-white dark:text-black" />
43-
</div>
44-
<div class="grid flex-1 text-left text-sm leading-tight">
45-
<span class="truncate font-semibold">Laravel</span>
46-
<span class="truncate text-xs">Starter Kit</span>
47-
</div>
38+
<a :href="route('dashboard')">
39+
<AppLogo />
4840
</a>
4941
</SidebarMenuButton>
5042
</SidebarMenuItem>

resources/js/components/AppSidebarHeader.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ defineProps<{
1010

1111
<template>
1212
<header
13-
class="flex h-16 shrink-0 items-center gap-2 border-b border-sidebar-border/70 px-4 transition-[width,height] ease-linear group-has-[[data-collapsible=icon]]/sidebar-wrapper:h-12"
13+
class="flex h-16 shrink-0 items-center gap-2 border-b border-sidebar-border/70 px-6 md:px-4 transition-[width,height] ease-linear group-has-[[data-collapsible=icon]]/sidebar-wrapper:h-12"
1414
>
1515
<div class="flex items-center gap-2">
1616
<SidebarTrigger class="-ml-1" />

resources/js/components/DeleteUser.vue

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,11 @@ const closeModal = () => {
4545
<template>
4646
<div class="space-y-6">
4747
<HeadingSmall title="Delete account" description="Delete your account and all of its resources" />
48-
<div className="border border-red-100 dark:border-red-950 p-3 rounded-lg flex items-center bg-red-50 dark:bg-red-700/10">
48+
<div class="space-y-4 rounded-lg border border-red-100 bg-red-50 p-4 dark:border-red-200/10 dark:bg-red-700/10">
49+
<div class="relative space-y-0.5 text-red-600 dark:text-red-100">
50+
<p class="font-medium">Warning</p>
51+
<p class="text-sm">Please proceed with caution, this cannot be undone.</p>
52+
</div>
4953
<Dialog>
5054
<DialogTrigger as-child>
5155
<Button variant="destructive">Delete account</Button>
@@ -78,11 +82,6 @@ const closeModal = () => {
7882
</form>
7983
</DialogContent>
8084
</Dialog>
81-
82-
<div className="relative text-red-600 dark:text-red-100 ml-3">
83-
<p className="font-medium leading-none mb-1 text-sm">Warning</p>
84-
<p className="leading-none text-xs">Please proceed with caution, this cannot be undone.</p>
85-
</div>
8685
</div>
8786
</div>
8887
</template>

resources/js/components/Heading.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ defineProps<Props>();
1010
</script>
1111

1212
<template>
13-
<div class="space-y-0.5">
14-
<h2 class="text-base font-semibold tracking-tight sm:text-lg lg:text-xl">{{ title }}</h2>
15-
<p v-if="description" class="text-xs text-muted-foreground md:text-sm">
13+
<div class="mb-8 space-y-0.5">
14+
<h2 class="text-xl font-semibold tracking-tight">{{ title }}</h2>
15+
<p v-if="description" class="text-muted-foreground text-sm">
1616
{{ description }}
1717
</p>
1818
</div>

resources/js/components/HeadingSmall.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ defineProps<Props>();
1010
<template>
1111
<header>
1212
<h3 class="mb-0.5 text-base font-medium">{{ title }}</h3>
13-
<p v-if="description" class="text-xs text-muted-foreground">
13+
<p v-if="description" class="text-sm text-muted-foreground">
1414
{{ description }}
1515
</p>
1616
</header>

0 commit comments

Comments
 (0)