forgejo/routers/web
Gusted 14d9c386fd
[UI] Fix HTMX support for profile card
- There were two issues with the profile card since the introduction of
HTMX in 3e8414179c. If an HTMX request
resulted in a flash message, it wasn't being shown and HTMX was
replacing all the HTML content instead of morphing it into the existing
DOM which caused event listeners to be lost for buttons.
- Flash messages are now properly being shown by using `hx-swap-oob`
and sending the alerts on a HTMX request, this does mean it requires
server-side changes in order to support HTMX requests like this, but
it's luckily not a big change either.
- Morphing is now enabled for the profile card by setting
`hx-swap="morph"`, and weirdly, the morphing library was already
installed and included as a dependency. This solves the issue of buttons
losing their event listeners.
- This patch also adds HTMX support to the modals feature, which means
that the blocking feature on the profile card now takes advantage of
HTMX.
- Added a E2E test.
2024-07-17 01:41:32 +02:00
..
admin Add cache test for admins (#31265) 2024-06-23 11:27:03 +02:00
auth
devtest
events
explore Rename repo_model.SearchOrderByMap to repo_model.OrderByMap (#31359) 2024-06-16 13:42:59 +02:00
feed
healthcheck
misc
org
repo fix: preserve object format dropdown options on /repo/create error (#4360) 2024-07-16 14:42:35 +00:00
shared
user [UI] Fix HTMX support for profile card 2024-07-17 01:41:32 +02:00
base.go
githttp.go
goget.go
home.go
metrics.go
nodeinfo.go
swagger_json.go
web.go Add support for workflow_dispatch (#3334) 2024-06-28 05:17:11 +00:00
webfinger.go