aboutsummaryrefslogtreecommitdiffstats
path: root/web_src/js/vendor
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2024-06-22 12:52:09 +0800
committerGitHub <noreply@github.com>2024-06-22 04:52:09 +0000
commit1a811c0bd10723ada73eb1c48a28cbc0775c6749 (patch)
treeae274e401ae693fe3917c75b046bcd8d93b844dd /web_src/js/vendor
parentb3ed1e0e62aa707d0238a91bc1b6658860f4bf3d (diff)
downloadgitea-1a811c0bd10723ada73eb1c48a28cbc0775c6749.tar.gz
gitea-1a811c0bd10723ada73eb1c48a28cbc0775c6749.zip
Refactor image diff (#31444)
And remove some jQuery functions
Diffstat (limited to 'web_src/js/vendor')
-rw-r--r--web_src/js/vendor/jquery.are-you-sure.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/web_src/js/vendor/jquery.are-you-sure.js b/web_src/js/vendor/jquery.are-you-sure.js
index e06da39fc9..e7bb203c5a 100644
--- a/web_src/js/vendor/jquery.are-you-sure.js
+++ b/web_src/js/vendor/jquery.are-you-sure.js
@@ -1,5 +1,6 @@
-// Fork of the upstream module. The only changes are the addition of `const` on
-// lines 93 and 161 to make it strict mode compatible.
+// Fork of the upstream module. The only changes are:
+// * use export to make it work with ES6 modules.
+// * the addition of `const` to make it strict mode compatible.
/*!
* jQuery Plugin: Are-You-Sure (Dirty Form Detection)
@@ -13,7 +14,7 @@
* Version: 1.9.0
* Date: 13th August 2014
*/
-(function($) {
+export function initAreYouSure($) {
$.fn.areYouSure = function(options) {
@@ -192,4 +193,4 @@
initForm($form);
});
};
-})(jQuery);
+}