Refactor account settings to use Markdown and Liquid templates
Converted `account.html` to `account.md` with Liquid includes for enhanced modularity and maintainability. This improves content separation from layout and facilitates easier updates and customization.
This commit is contained in:
1 parent
48a52a78d9
commit
1a69f0fb20
3 files changed
+134
-189
No files matched your search
@@ -0,0 +1,114 @@
|
||||
<form class="space-y-4">
|
||||
<div class="w-full overflow-x-auto">
|
||||
<table class="w-full" border="0" cellpadding="0" cellspacing="0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<table class="w-full" cellpadding="5">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="bg-rules-bg p-4 rounded mb-4 text-primary text-sm">
|
||||
<p>
|
||||
Please provide a valid email address. This ensures we can assist you with password recovery if needed. Rest assured, your email address remains confidential between you and us, invisible to web crawlers and other users.
|
||||
</p>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<table class="w-full min-w-[300px] table-auto" border="0">
|
||||
<tbody>
|
||||
<tr class="athing">
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">user:</td>
|
||||
<td timestamp="1745816813"><a href="user?id={{ page.username }}" class="hnuser">
|
||||
<font class="text-primary text-sm">{{ page.username }}</font>
|
||||
</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">created:</td>
|
||||
<td><a href="#" class="text-primary text-sm">{{ page.created }}</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">merit:</td>
|
||||
<td class="text-primary text-sm">{{ page.merit }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">about:</td>
|
||||
<td style="overflow:hidden">
|
||||
<div class="flex items-center">
|
||||
<textarea name="about" rows="5" class="w-full max-w-full sm:w-[350px] md:w-[450px] text-primary text-sm px-3 py-1 border border-gray-300 rounded">{{ page.about }}</textarea>
|
||||
<a href="formatdoc" tabindex="-1">
|
||||
<font size="-2" class="ml-2 text-xs text-primary hover:underline">help</font>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2"></td>
|
||||
<td>
|
||||
<font size="2" class="text-primary text-sm">Only admins see your email below. To share publicly, add to the 'about' box.</font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">email:</td>
|
||||
<td><input type="text" name="email" value="{{ page.email }}" class="w-full max-w-full sm:w-[350px] md:w-[450px] text-primary text-sm px-3 py-1 border border-gray-300 rounded"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">showdead:</td>
|
||||
<td><select name="showd" class="text-primary text-sm px-3 py-1 border border-gray-300 rounded">
|
||||
<option {% if page.showdead == "yes" %}selected="t"{% endif %}>yes</option>
|
||||
<option {% if page.showdead == "no" %}selected="t"{% endif %}>no</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">noprocrast:</td>
|
||||
<td><select name="nopro" class="text-primary text-sm px-3 py-1 border border-gray-300 rounded">
|
||||
<option {% if page.noprocrast == "yes" %}selected="t"{% endif %}>yes</option>
|
||||
<option {% if page.noprocrast == "no" %}selected="t"{% endif %}>no</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">maxvisit:</td>
|
||||
<td><input type="number" name="maxv" value="{{ page.maxvisit }}" class="w-20 text-primary text-sm px-3 py-1 border border-gray-300 rounded"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">minaway:</td>
|
||||
<td><input type="number" name="mina" value="{{ page.minaway }}" class="w-20 text-primary text-sm px-3 py-1 border border-gray-300 rounded"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 align-top w-24 sm:w-32 text-primary text-sm font-medium">delay:</td>
|
||||
<td><input type="number" name="delay" value="{{ page.delay }}" class="w-20 text-primary text-sm px-3 py-1 border border-gray-300 rounded"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 w-24 sm:w-32"></td>
|
||||
<td><a href="{{ page.change_password_uri }}" class="text-primary text-sm hover:underline">change password</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 w-24 sm:w-32"></td>
|
||||
<td><a href="{{ page.submissions_uri }}" class="text-primary text-sm hover:underline">submissions</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 w-24 sm:w-32"></td>
|
||||
<td><a href="{{ page.comments_uri }}" class="text-primary text-sm hover:underline">comments</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="py-2 w-24 sm:w-32"></td>
|
||||
<td class="text-sm">
|
||||
<a href="{{ page.favorites_uri }}" class="text-primary hover:underline">favorite submissions</a> /
|
||||
<a href="{{ page.favorites_uri }}&comments=t" class="text-primary hover:underline">comments</a>
|
||||
<i class="text-sm"> (publicly visible)</i>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="mt-4">
|
||||
<button type="submit" class="px-2 py-1 bg-primary text-white rounded hover:bg-primary-dark">update</button>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</form>
|
||||
Reference in new issue
Block a user