summaryrefslogtreecommitdiffstats
path: root/templates/user/auth
diff options
context:
space:
mode:
authorGerben <gerben@treora.com>2018-03-23 15:10:42 +0100
committerLunny Xiao <xiaolunwen@gmail.com>2018-03-23 22:10:42 +0800
commit2dc6f15eca007105fb6c3972265e6da53696bdf1 (patch)
tree2775c7b19061663edf401d3af1adc87bb86c5453 /templates/user/auth
parente64aa18dc97f2cf25bc642c7d987a4a3bed494ac (diff)
downloadgitea-2dc6f15eca007105fb6c3972265e6da53696bdf1.tar.gz
gitea-2dc6f15eca007105fb6c3972265e6da53696bdf1.zip
Don't warn users about *every* dirty form (#3707)
The choice regarding which forms should or should not trigger a warning is subjective. I tried to be consistent and not warn about forms that: - run an action, rather than edit data: search, send an email. - delete data: a warning about losing data would be confusing Note that forms on sign-in pages were already ignored (using a selector, rather than an explicit class on the form element). Fixes #3698.
Diffstat (limited to 'templates/user/auth')
-rw-r--r--templates/user/auth/activate.tmpl2
-rw-r--r--templates/user/auth/forgot_passwd.tmpl2
-rw-r--r--templates/user/auth/reset_passwd.tmpl2
3 files changed, 3 insertions, 3 deletions
diff --git a/templates/user/auth/activate.tmpl b/templates/user/auth/activate.tmpl
index 9805067ae1..92b85a1373 100644
--- a/templates/user/auth/activate.tmpl
+++ b/templates/user/auth/activate.tmpl
@@ -2,7 +2,7 @@
<div class="user activate">
<div class="ui middle very relaxed page grid">
<div class="column">
- <form class="ui form" action="{{AppSubUrl}}/user/activate" method="post">
+ <form class="ui form ignore-dirty" action="{{AppSubUrl}}/user/activate" method="post">
{{.CsrfTokenHtml}}
<h2 class="ui top attached header">
{{.i18n.Tr "auth.active_your_account"}}
diff --git a/templates/user/auth/forgot_passwd.tmpl b/templates/user/auth/forgot_passwd.tmpl
index 2aeee300f0..1e061763a5 100644
--- a/templates/user/auth/forgot_passwd.tmpl
+++ b/templates/user/auth/forgot_passwd.tmpl
@@ -2,7 +2,7 @@
<div class="user forgot password">
<div class="ui middle very relaxed page grid">
<div class="column">
- <form class="ui form" action="{{.Link}}" method="post">
+ <form class="ui form ignore-dirty" action="{{.Link}}" method="post">
{{.CsrfTokenHtml}}
<h2 class="ui top attached header">
{{.i18n.Tr "auth.forgot_password_title"}}
diff --git a/templates/user/auth/reset_passwd.tmpl b/templates/user/auth/reset_passwd.tmpl
index 2408d39a7c..19a7c8eea8 100644
--- a/templates/user/auth/reset_passwd.tmpl
+++ b/templates/user/auth/reset_passwd.tmpl
@@ -2,7 +2,7 @@
<div class="user reset password">
<div class="ui middle very relaxed page grid">
<div class="column">
- <form class="ui form" action="{{.Link}}" method="post">
+ <form class="ui form ignore-dirty" action="{{.Link}}" method="post">
{{.CsrfTokenHtml}}
<input name="code" type="hidden" value="{{.Code}}">
<h2 class="ui top attached header">