]> source.dussan.org Git - gitea.git/commit
Vendor `jquery.are-you-sure` with strict mode fixes (#26901)
authorsilverwind <me@silverwind.io>
Wed, 6 Sep 2023 00:02:44 +0000 (02:02 +0200)
committerGitHub <noreply@github.com>
Wed, 6 Sep 2023 00:02:44 +0000 (00:02 +0000)
commit97aa749578a05b207d54dbbcd8580201b5eba359
tree1e575d28f8c6d544fdcddb51f920d6cb68a29cc6
parent01e71e2a478be393dabf14e69520b0f8892baf59
Vendor `jquery.are-you-sure` with strict mode fixes (#26901)

Extract from https://github.com/go-gitea/gitea/pull/25940 and because
https://github.com/go-gitea/gitea/pull/26743 does seem to need more
work.

This will be required if we are to run our JS in [strict
mode](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Strict_mode).

Previously, the two variables `$fields` and `$dirtyForms` polluted
`window`:

<img width="1145" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/e0270a0e-b881-4ed7-9cc4-e9ab25c0a2bc">
package-lock.json
package.json
web_src/js/features/common-global.js
web_src/js/vendor/jquery.are-you-sure.js [new file with mode: 0644]
webpack.config.js