User edit -> Alpine Ajax

This commit is contained in:
Simon Martens
2025-05-29 16:21:59 +02:00
parent cbbfa77865
commit 3b9ec7d493
7 changed files with 39 additions and 34 deletions

View File

@@ -8,7 +8,7 @@
{{ template "_head" . }}
</head>
<body class="w-full min-h-full" hx-ext="response-targets" hx-boost="true">
<body class="w-full min-h-full" id="body" hx-ext="response-targets" hx-boost="true">
<div class="pb-12">
{{ block "body" . }}
<!-- Default app body... -->

View File

@@ -8,7 +8,7 @@
{{ template "_head" . }}
</head>
<body class="w-full min-h-full" hx-ext="response-targets" hx-boost="true">
<body id="body" class="w-full min-h-full" hx-ext="response-targets" hx-boost="true">
<div class="flex flex-col min-h-screen w-full">
<header class="container-normal bg-slate-100 " id="header">
{{ template "_menu" . }}

View File

@@ -1,5 +1,6 @@
{{- $date := Today -}}
<footer
id="footer"
class="container-normal pb-1.5 text-base text-gray-800 relative"
x-data="{ openusermenu: false }">
{{- if .request.user -}}

View File

@@ -9,7 +9,7 @@
</head>
<body class="w-full text-lg" hx-ext="response-targets" hx-boost="true">
<body id="body" class="w-full text-lg" hx-ext="response-targets" hx-boost="true">
<div class="flex flex-col min-h-screen w-full">
<header class="container-normal pb-0" id="header">
{{ block "_menu" . }}

View File

@@ -17,8 +17,16 @@
</div>
<div class="flex container-normal mx-auto px-8 mt-4">
<div class="flex-col max-w-2xl w-full">
{{ template "_usermessage" $model }}
<form class="w-full grid grid-cols-3 gap-4" method="POST" x-data="{ openpw: false }">
<form
class="w-full grid grid-cols-3 gap-4"
id="changeuserform"
x-target="changeuserform footer"
hx-boost="false"
method="POST"
x-data="{ openpw: false }">
<div class="col-span-3">
{{ template "_usermessage" $model }}
</div>
<div
class="rounded-xs col-span-3 border-2 border-transparent px-3
py-1 pb-1.5 border-l-2 focus-within:border-l-slate-600