gitea/web_src/js/features
wxiaoguang b573512312
Correctly query the primary button in a form (#32438)
The "primary button" is used at many places, but sometimes they might
conflict (due to button switch, hidden panel, dropdown menu, etc).

Sometimes we could add a special CSS class for the buttons, but
sometimes not (see the comment of QuickSubmit)

This PR introduces `querySingleVisibleElem` to help to get the correct
primary button (the only visible one), and prevent from querying the
wrong buttons.

Fix #32437

---------

Co-authored-by: silverwind <me@silverwind.io>
2024-11-07 04:21:53 +08:00
..
admin Move admin routers from /admin to /-/admin (#32189) 2024-10-10 04:56:49 +00:00
comp Correctly query the primary button in a form (#32438) 2024-11-07 04:21:53 +08:00
autofocus-end.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
captcha.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
citation.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
clipboard.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
code-frequency.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
codeeditor.ts Code editor theme enhancements (#31629) 2024-07-14 23:22:48 +00:00
colorpicker.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-button.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-fetch-action.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-form.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-issue-list.test.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-issue-list.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-organization.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
common-page.ts Warn users when they try to use a non-root-url to sign in/up (#32272) 2024-10-17 10:28:51 +08:00
contextpopup.ts Fix suggestions for issues (#32380) 2024-10-30 20:06:36 +00:00
contributors.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
copycontent.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
dropzone.ts Fix broken image when editing comment with non-image attachments (#32319) 2024-10-23 17:39:10 +02:00
emoji.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
eventsource.sharedworker.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
file-fold.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
heatmap.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
imagediff.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
install.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
issue.ts Suggestions for issues (#32327) 2024-10-29 17:20:49 +08:00
notification.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
oauth2-settings.ts add skip secondary authorization option for public oauth2 clients (#31454) 2024-07-19 14:28:30 -04:00
org-team.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
pull-view-file.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
recent-commits.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-branch.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-code.test.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-code.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-commit.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-common.ts Refactor repo legacy (#32404) 2024-11-03 11:00:12 +00:00
repo-diff-commit.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-diff-commitselect.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-diff-filetree.ts make show stats work when only one file changed (#32244) 2024-10-14 21:23:20 +00:00
repo-diff.ts make show stats work when only one file changed (#32244) 2024-10-14 21:23:20 +00:00
repo-editor.ts Notify the user when the file path contains leading or trailing spaces and fix the error message for invalid file names. (#31507) 2024-09-24 19:06:52 +00:00
repo-findfile.test.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-findfile.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-graph.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-home.ts Add null check for responseData.invalidTopics (#32212) 2024-10-09 01:27:05 +08:00
repo-issue-content.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-issue-edit.ts Correctly query the primary button in a form (#32438) 2024-11-07 04:21:53 +08:00
repo-issue-list.ts Refactor repo legacy (#32404) 2024-11-03 11:00:12 +00:00
repo-issue-pr-form.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-issue-pr-status.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-issue-sidebar.ts Fix milestone deadline and date related problems (#32339) 2024-11-05 07:46:40 +00:00
repo-issue.ts Fix milestone deadline and date related problems (#32339) 2024-11-05 07:46:40 +00:00
repo-legacy.ts Refactor repo legacy (#32404) 2024-11-03 11:00:12 +00:00
repo-migrate.ts Fix javascript error when an anonymous user visiting migration page (#32144) 2024-10-02 04:37:16 +00:00
repo-migration.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-milestone.ts Fix milestone deadline and date related problems (#32339) 2024-11-05 07:46:40 +00:00
repo-new.ts Refactor repo legacy (#32404) 2024-11-03 11:00:12 +00:00
repo-projects.ts Add types to various low-level functions (#31781) 2024-08-10 09:46:48 +00:00
repo-release.ts Prevent from submitting issue/comment on uploading (#32263) 2024-10-23 10:48:04 +08:00
repo-search.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-settings.ts Refactor repo legacy (#32404) 2024-11-03 11:00:12 +00:00
repo-template.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-unicode-escape.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
repo-wiki.ts Prevent from submitting issue/comment on uploading (#32263) 2024-10-23 10:48:04 +08:00
scoped-access-token.ts fix the component of access token list not mounted (#31824) 2024-08-16 17:37:36 +00:00
sshkey-helper.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
stopwatch.ts Add types to various low-level functions (#31781) 2024-08-10 09:46:48 +00:00
tablesort.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
tribute.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00
user-auth-webauthn.ts Run detectWebAuthnSupport only if necessary (#31691) 2024-07-25 23:26:41 +00:00
user-auth.ts Warn users when they try to use a non-root-url to sign in/up (#32272) 2024-10-17 10:28:51 +08:00
user-settings.ts Convert frontend code to typescript (#31559) 2024-07-07 15:32:30 +00:00