forgejo/web_src/js
wxiaoguang 2bce1ea986
Show messages for users if the ROOT_URL is wrong, show JavaScript errors (#18971)
* ROOT_URL issues: some users did wrong to there app.ini config, then:
    * The assets can not be loaded (AppSubUrl != "" and users try to access http://host:3000/)
    *The ROOT_URL is wrong, then many URLs in Gitea are broken.
Now Gitea show enough information to users.

* JavaScript error issues, there are many users affected by JavaScript errors, some are caused by frontend bugs, some are caused by broken customized templates. If these JS errors can be found at first time, then maintainers do not need to ask about how bug occurs again and again.

* Some people like to modify the `head.tmpl`, so we separate the script part to `head_script.tmpl`, then it's much safer.

* use specialized CSS class "js-global-error", end users still have a chance to hide error messages by customized CSS styles.
2022-03-30 13:52:24 +08:00
..
components Add apply-patch, basic revert and cherry-pick functionality (#17902) 2022-02-09 20:28:55 +00:00
features Show messages for users if the ROOT_URL is wrong, show JavaScript errors (#18971) 2022-03-30 13:52:24 +08:00
markup Various Mermaid improvements (#18776) 2022-02-16 11:28:29 +08:00
standalone Add new JS linter rules (#17699) 2021-11-22 16:19:01 +08:00
vendor
bootstrap.js Show messages for users if the ROOT_URL is wrong, show JavaScript errors (#18971) 2022-03-30 13:52:24 +08:00
index.js Show messages for users if the ROOT_URL is wrong, show JavaScript errors (#18971) 2022-03-30 13:52:24 +08:00
jquery.js
serviceworker.js
svg.js
svg.test.js
utils.js Detect dark theme via css variable (#17800) 2021-11-25 15:14:48 +08:00
utils.test.js