18759 Commits

Author SHA1 Message Date
Rajesh Jonnalagadda
e6e314bcc7
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-12-02 07:30:11 +05:30
wxiaoguang
e3e32605a1
Refactor RepoBranchTagSelector (#32681) 2024-12-02 01:41:32 +00:00
wxiaoguang
def13ece7c
Allow to disable the password-based login (sign-in) form (#32687)
Usually enterprise/organization users would like to only allow OAuth2
login.

This PR adds a new config option to disable the password-based login
form. It is a simple and clear approach and won't block the future
login-system refactoring works.

Fix a TODO in #24821

Replace  #21851

Close #7633 , close #13606
2024-12-02 02:03:15 +08:00
wxiaoguang
1bb1a51f47
Fix JS error when reply comment on Conversation page (#32685)
Fix #32684, regression of #32596 (side-effect of jQuery removal: jQuery could tolerate non-existing elements)
And fix another regression bug from #30453 (initCompReactionSelector double-init)
2024-12-02 00:13:58 +08:00
Simon Pistache
2abef971dc
fix(#32667): 🐛 Fixe a keystring misuse and refactor duplicates keystrings (#32668)
- Fixes a translation keystring misuse where the string 'open
milestones' is used in place of 'closed milestones'.
- De-duplicates the use of 'open milesones' and 'closed milestones'
keystrings on the sidebar of an issue, reusing the ones on the issues
filter and action bars.
- Closes #32667

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2024-12-01 10:14:56 +08:00
Lunny Xiao
79d593a9be
Split mail sender sub package from mailer service package (#32618)
Move all mail sender related codes into a sub package of
services/mailer. Just move, no code change.
Then we just have dependencies on go-mail package in the new sub
package. We can use other package to replace it because it's
unmaintainable. ref #18664
2024-11-30 01:15:41 +00:00
Zettat123
fd3aa5bedb
Fix a bug in actions artifact test (#32672)
This bug exists in `TestActionsArtifactDownload`.


a1f56f83bf/tests/integration/api_actions_artifact_test.go (L123-L134)

We assert that `listResp.Count` is `2`, so `artifactIdx` could be `0` or `1`.

a1f56f83bf/tests/integration/api_actions_artifact_test.go (L144-L147)

Then we assert that the length of `downloadResp.Value` is `1`. If
`artifactIdx` is `1` at this point, the assertion on Line 147 will throw
an `index out of range` error.
2024-11-29 20:32:10 +00:00
Lunny Xiao
1ed5f379b9
Move GetFeeds to service layer (#32526)
Move GetFeeds from models to service layer, no code change.
2024-11-29 17:53:49 +00:00
Rajesh Jonnalagadda
904fb52a54
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-29 16:05:48 +05:30
wxiaoguang
93640993e3
Refactor render system (orgmode) (#32671)
Close  #29100
2024-11-29 16:08:29 +08:00
Rajesh Jonnalagadda
bf3535a7a3 chore: fix lint issue 2024-11-28 18:41:45 +05:30
Rajesh Jonnalagadda
24da8ef7af Merge branch 'feat-32257-add-comments-unchanged-lines-and-show' of github.com:rajesh-jonnalagadda/gitea into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 18:26:13 +05:30
Rajesh Jonnalagadda
728fc122b2 chore: fix backedn-lint issues 2024-11-28 18:26:07 +05:30
Rajesh Jonnalagadda
65ef1740b0
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 18:13:33 +05:30
Rajesh Jonnalagadda
17deb2cdc4 Merge branch 'feat-32257-add-comments-unchanged-lines-and-show' of github.com:rajesh-jonnalagadda/gitea into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 18:12:19 +05:30
Rajesh Jonnalagadda
5d9651b8ed chore: fix the comment context menu drop down 2024-11-28 18:12:06 +05:30
silverwind
a1f56f83bf
Improve diff file tree (#32658)
- Unfolded directories now show a "open" icon
- Prevent accidential text selection while toggling directories
- Increase vertical item padding from 3px to 6px

<img width="257" alt="image"
src="https://github.com/user-attachments/assets/d5372306-a666-4732-827e-3ddeee3c711e">
2024-11-28 12:25:21 +00:00
Rajesh Jonnalagadda
819dd0890c
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 15:26:09 +05:30
Lunny Xiao
00f8090de4
Don't create action when syncing mirror pull refs (#32659)
Fix #27961
2024-11-28 07:43:38 +00:00
Pedro Nishiyama
1b296ed1a4
Allow users with write permission to run actions (#32644)
---
I have a use case where I need a team to be able to run actions without
admin access.
2024-11-28 07:18:23 +00:00
Rowan Bohde
16a7d343d7
Validate OAuth Redirect URIs (#32643)
This fixes a TODO in the code to validate the RedirectURIs when adding
or editing an OAuth application in user settings.

This also includes a refactor of the user settings tests to only create
the DB once per top-level test to avoid reloading fixtures.
2024-11-28 10:50:27 +08:00
Kerwin Bryant
68d9f36543
Allow cropping an avatar before setting it (#32565)
Provide a cropping tool on the avatar editing page, allowing users to
select the cropping area themselves. This way, users can decide the
displayed area of the image, rather than us deciding for them.

---------

Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: delvh <dev.lh@web.de>
Co-authored-by: Giteabot <teabot@gitea.io>
2024-11-28 02:15:59 +00:00
silverwind
f1bea3c3b8
Add webpack EnvironmentPlugin (#32661)
Fixes: https://github.com/go-gitea/gitea/issues/32660

Environment vars in Webpack need to be declared in the config, otherwise
they will not be elimininated during compilation.
2024-11-28 01:50:54 +00:00
Rajesh Jonnalagadda
d36fece725 Merge branch 'feat-32257-add-comments-unchanged-lines-and-show' of github.com:rajesh-jonnalagadda/gitea into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 04:28:27 +05:30
Rajesh Jonnalagadda
ea285c2131 chore: fix the extra comment icon at the end and change the icon pointer 2024-11-28 04:27:47 +05:30
Rajesh Jonnalagadda
0f6708cca1
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 02:53:07 +05:30
Lunny Xiao
f62f68cbdd
Move team related functions to service layer (#32537)
There are still some functions under `models` after last big refactor
about `models`. This change will move all team related functions to
service layer with no code change.
2024-11-27 21:12:26 +00:00
Rajesh Jonnalagadda
7d0c8e30e0
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-28 01:20:28 +05:30
wxiaoguang
5a50b271e7
Make frontend unit test code could know it is in testing (#32656)
See the comment of isInFrontendUnitTest
2024-11-28 01:40:32 +08:00
6543
846f618716
Add priority to protected branch (#32286)
## Solves

Currently for rules to re-order them you have to alter the creation
date. so you basicly have to delete and recreate them in the right
order. This is more than just inconvinient ...

## Solution

Add a new col for prioritization

## Demo WebUI Video

https://github.com/user-attachments/assets/92182a31-9705-4ac5-b6e3-9bb74108cbd1


---
*Sponsored by Kithara Software GmbH*
2024-11-27 05:41:06 +01:00
silverwind
3fc1bbe971
Regenerate fomantic package-lock.json (#32650)
Fixes: https://github.com/go-gitea/gitea/security/dependabot/83
Fixes: https://github.com/go-gitea/gitea/security/dependabot/84

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2024-11-27 04:04:12 +00:00
wxiaoguang
6e507c45ed
Fix global form submit event (#32652) 2024-11-27 11:54:50 +08:00
Lunny Xiao
f49d82309b
Introduce OrgList and add LoadTeams, optimaze Load teams for orgs (#32543) 2024-11-26 21:55:06 +00:00
wxiaoguang
b6ce2d6dc9
Refactor markup render system (#32645)
This PR mainly removes some global variables, moves some code and
renames some functions to make code clearer.

This PR also removes a testing-only option ForceHardLineBreak during
refactoring since the behavior is clear now.
2024-11-26 16:46:02 +00:00
hiifong
87bb5ed0bc
Fix: passkey login not working anymore (#32623)
Quick fix #32595, use authenticator auth flags to login

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2024-11-26 16:04:17 +00:00
Rajesh Jonnalagadda
40826ddf9c
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-26 21:07:20 +05:30
wxiaoguang
0f4b0cf892
Refactor some frontend problems (#32646)
1. correct the modal usage on "admin email list" page (then
`web_src/js/features/admin/emails.ts` is removed)
2. use `addDelegatedEventListener` instead of `jQuery().on`
3. more jQuery related changes and remove jQuery from
`web_src/js/features/common-button.ts`
4. improve `confirmModal` to make it support header, and remove
incorrect double-escaping
5. fix more typescript related types
6. fine tune devtest pages and add more tests
2024-11-26 15:36:55 +00:00
Rajesh Jonnalagadda
fa4c61e160
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-26 20:47:18 +05:30
wxiaoguang
722e703c6b
Bypass vitest bug (#32647) 2024-11-26 23:10:45 +08:00
william-allspice
88f5d33ab2
Fix race condition in mermaid observer (#32599)
This Pull Request addresses a race condition in the updateIframeHeight
function where it is sometimes called when the iframe is not fully
loaded or accessible resulting in an alarming error message for the
user.

To address this we:
1. Add defensive programming within the updateIframeHeight function
2. Delay instantiating the intersection observer until the iframe has
loaded

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2024-11-26 06:37:24 +00:00
wxiaoguang
9ed768adc4
Improve oauth2 scope token handling (#32633) 2024-11-26 02:03:02 +00:00
Kerwin Bryant
25cacaf0aa
Fixed Issue of Review Menu Shown Behind (#32631)
Fixed #31144 

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2024-11-26 09:24:56 +08:00
Lunny Xiao
703be6bf30
Add github compatible tarball download API endpoints (#32572)
Fix #29654 
Fix #32481
2024-11-25 19:35:49 +00:00
wxiaoguang
44909f6e2c
Fix markup render regression and fix some tests (#32640)
Fix #32639,
https://github.com/go-gitea/gitea/issues/32608#issuecomment-2497918210

By the way, fix some incorrect SQLs (use single quote but not double
quote)
2024-11-26 03:04:55 +08:00
wxiaoguang
5d57c287fb
Fix sqlite3 test (#32622) 2024-11-25 06:10:11 +00:00
Lunny Xiao
c363bd06e9
Strict pagination check (#32548) 2024-11-25 09:56:50 +08:00
Rajesh Jonnalagadda
2db63b16e6
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-24 23:50:21 +05:30
wxiaoguang
633785a5f3
Refactor markup render system (#32612)
This PR removes (almost) all path tricks, and introduces "renderhelper"
package.

Now we can clearly see the rendering behaviors for comment/file/wiki,
more details are in "renderhelper" tests.

Fix #31411 , fix #18592, fix #25632 and maybe more problems. (ps: fix
#32608 by the way)
2024-11-24 16:18:57 +08:00
silverwind
fa175c1694
Add vue-tsc (#32601)
As per https://vuejs.org/guide/typescript/overview#overview,
typescript's `tsc` does not support importing `.vue` files from `.ts`
files, so we need to use `vue-tsc` which patches in that support. Added
a convenience alias `make tsc` to run it.
2024-11-23 23:02:37 +00:00
Rajesh Jonnalagadda
7f0c5e4b3d
Merge branch 'main' into feat-32257-add-comments-unchanged-lines-and-show 2024-11-23 18:50:28 +05:30