Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: profile component #282

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open
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
41 changes: 41 additions & 0 deletions resources/views/components/profile.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
@props([
'user',
'stats' => [
'lists' => 0,
'reviews' => 0,
'friends' => 0,
],

])

<div class="relative flex w-full">
<div class="absolute top-0 right-0">
<x-lucide-ellipsis-vertical class="size-6 text-slate-50" />
</div>

<div class="mr-8 flex w-full flex-row flex-wrap items-center gap-4">
<x-avatar :image="$user->image ?? null" size="lg" />

<div class="flex grow flex-col gap-3 text-slate-50">
<div class="text-lg font-bold">
{{ $user->username ?? 'username' }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
{{ $user->username ?? 'username' }}
{{ $user->username }}

man kan inte skapa en användare utan ett användarnamn!

</div>
<div class="flex gap-6 text-slate-50">
@foreach ($stats as $stat => $sum)
<div class="flex flex-col">
<p class="text-sm font-bold">
{{ $sum }}
</p>
<span class="text-sm font-normal text-slate-200">
{{ $stat }}
</span>
</div>
@endforeach
</div>
</div>

<div class="flex flex-none flex-row gap-2 self-start">
ell-ska marked this conversation as resolved.
Show resolved Hide resolved
{{ $slot }}
</div>
</div>
</div>
Empty file modified resources/views/profile.blade.php
100644 → 100755
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

den här filen finns det nu innehåll i i main. jag vet inte varför du inte får en merge konflikt men se till att du inte tar bort det som ligger i main innan denna mergas

Empty file.