|
c588255…
|
ragelink
|
1 |
{% extends "base.html" %} |
|
c588255…
|
ragelink
|
2 |
{% block title %}Edit Profile — Fossilrepo{% endblock %} |
|
c588255…
|
ragelink
|
3 |
|
|
c588255…
|
ragelink
|
4 |
{% block content %} |
|
c588255…
|
ragelink
|
5 |
<div class="max-w-2xl"> |
|
c588255…
|
ragelink
|
6 |
<div class="flex items-center gap-3 mb-6"> |
|
c588255…
|
ragelink
|
7 |
<a href="{% url 'accounts:profile' %}" class="text-gray-400 hover:text-white"> |
|
c588255…
|
ragelink
|
8 |
<svg class="h-5 w-5" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"> |
|
c588255…
|
ragelink
|
9 |
<path stroke-linecap="round" stroke-linejoin="round" d="M10.5 19.5L3 12m0 0l7.5-7.5M3 12h18" /> |
|
c588255…
|
ragelink
|
10 |
</svg> |
|
c588255…
|
ragelink
|
11 |
</a> |
|
c588255…
|
ragelink
|
12 |
<h1 class="text-2xl font-bold text-gray-100">Edit Profile</h1> |
|
c588255…
|
ragelink
|
13 |
</div> |
|
c588255…
|
ragelink
|
14 |
|
|
c588255…
|
ragelink
|
15 |
<form method="post" class="space-y-6"> |
|
c588255…
|
ragelink
|
16 |
{% csrf_token %} |
|
c588255…
|
ragelink
|
17 |
|
|
2f13242…
|
ragelink
|
18 |
<div class="rounded-lg bg-gray-800 border border-gray-700 p-6 space-y-4 shadow-sm"> |
|
c588255…
|
ragelink
|
19 |
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"> |
|
c588255…
|
ragelink
|
20 |
<div> |
|
c588255…
|
ragelink
|
21 |
<label for="first_name" class="block text-sm font-medium text-gray-300 mb-1">First Name</label> |
|
c588255…
|
ragelink
|
22 |
<input type="text" name="first_name" id="first_name" value="{{ user.first_name }}" maxlength="30" |
|
c588255…
|
ragelink
|
23 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand"> |
|
c588255…
|
ragelink
|
24 |
</div> |
|
c588255…
|
ragelink
|
25 |
<div> |
|
c588255…
|
ragelink
|
26 |
<label for="last_name" class="block text-sm font-medium text-gray-300 mb-1">Last Name</label> |
|
c588255…
|
ragelink
|
27 |
<input type="text" name="last_name" id="last_name" value="{{ user.last_name }}" maxlength="150" |
|
c588255…
|
ragelink
|
28 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand"> |
|
c588255…
|
ragelink
|
29 |
</div> |
|
c588255…
|
ragelink
|
30 |
</div> |
|
c588255…
|
ragelink
|
31 |
|
|
c588255…
|
ragelink
|
32 |
<div> |
|
c588255…
|
ragelink
|
33 |
<label for="email" class="block text-sm font-medium text-gray-300 mb-1">Email</label> |
|
c588255…
|
ragelink
|
34 |
<input type="email" name="email" id="email" value="{{ user.email }}" maxlength="254" |
|
c588255…
|
ragelink
|
35 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand"> |
|
c588255…
|
ragelink
|
36 |
</div> |
|
c588255…
|
ragelink
|
37 |
|
|
c588255…
|
ragelink
|
38 |
<div> |
|
c588255…
|
ragelink
|
39 |
<label for="handle" class="block text-sm font-medium text-gray-300 mb-1">Handle</label> |
|
c588255…
|
ragelink
|
40 |
<div class="flex items-center"> |
|
c588255…
|
ragelink
|
41 |
<span class="text-gray-500 text-sm mr-1">@</span> |
|
c588255…
|
ragelink
|
42 |
<input type="text" name="handle" id="handle" value="{{ user_profile.handle }}" maxlength="50" |
|
c588255…
|
ragelink
|
43 |
pattern="[a-z0-9\-]+" title="Lowercase letters, numbers, and hyphens only" |
|
c588255…
|
ragelink
|
44 |
placeholder="your-handle" |
|
c588255…
|
ragelink
|
45 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand"> |
|
c588255…
|
ragelink
|
46 |
</div> |
|
c588255…
|
ragelink
|
47 |
<p class="mt-1 text-xs text-gray-500">Alphanumeric and hyphens only. Used for @mentions.</p> |
|
c588255…
|
ragelink
|
48 |
</div> |
|
c588255…
|
ragelink
|
49 |
|
|
c588255…
|
ragelink
|
50 |
<div> |
|
c588255…
|
ragelink
|
51 |
<label for="bio" class="block text-sm font-medium text-gray-300 mb-1">Bio</label> |
|
c588255…
|
ragelink
|
52 |
<textarea name="bio" id="bio" rows="3" maxlength="500" |
|
c588255…
|
ragelink
|
53 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand">{{ user_profile.bio }}</textarea> |
|
c588255…
|
ragelink
|
54 |
<p class="mt-1 text-xs text-gray-500">Max 500 characters.</p> |
|
c588255…
|
ragelink
|
55 |
</div> |
|
c588255…
|
ragelink
|
56 |
|
|
c588255…
|
ragelink
|
57 |
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"> |
|
c588255…
|
ragelink
|
58 |
<div> |
|
c588255…
|
ragelink
|
59 |
<label for="location" class="block text-sm font-medium text-gray-300 mb-1">Location</label> |
|
c588255…
|
ragelink
|
60 |
<input type="text" name="location" id="location" value="{{ user_profile.location }}" maxlength="100" |
|
c588255…
|
ragelink
|
61 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand"> |
|
c588255…
|
ragelink
|
62 |
</div> |
|
c588255…
|
ragelink
|
63 |
<div> |
|
c588255…
|
ragelink
|
64 |
<label for="website" class="block text-sm font-medium text-gray-300 mb-1">Website</label> |
|
c588255…
|
ragelink
|
65 |
<input type="url" name="website" id="website" value="{{ user_profile.website }}" maxlength="200" |
|
c588255…
|
ragelink
|
66 |
placeholder="https://" |
|
c588255…
|
ragelink
|
67 |
class="w-full rounded-md border-gray-600 bg-gray-900 text-gray-100 text-sm px-3 py-2 focus:border-brand focus:ring-brand"> |
|
c588255…
|
ragelink
|
68 |
</div> |
|
c588255…
|
ragelink
|
69 |
</div> |
|
c588255…
|
ragelink
|
70 |
</div> |
|
c588255…
|
ragelink
|
71 |
|
|
c588255…
|
ragelink
|
72 |
<div class="flex items-center gap-3"> |
|
2f13242…
|
ragelink
|
73 |
<button type="submit" class="rounded-md bg-brand px-4 py-2 text-sm font-semibold text-white hover:bg-brand-hover focus:outline-none focus:ring-2 focus:ring-brand focus:ring-offset-2 focus:ring-offset-gray-950 transition-colors"> |
|
c588255…
|
ragelink
|
74 |
Save Changes |
|
c588255…
|
ragelink
|
75 |
</button> |
|
c588255…
|
ragelink
|
76 |
<a href="{% url 'accounts:profile' %}" class="text-sm text-gray-400 hover:text-white">Cancel</a> |
|
c588255…
|
ragelink
|
77 |
</div> |
|
c588255…
|
ragelink
|
78 |
</form> |
|
c588255…
|
ragelink
|
79 |
</div> |
|
c588255…
|
ragelink
|
80 |
{% endblock %} |