aboutsummaryrefslogtreecommitdiffstats
path: root/templates
Commit message (Collapse)AuthorAgeFilesLines
* Fix incomplete Actions status aggregations (#32859)wxiaoguang2024-12-161-12/+6
| | | fix #32857
* Do not display `attestation-manifest` and use short sha256 instead of full ↵hiifong2024-12-161-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sha256 (#32851) Related: #24973 Before: ![image](https://github.com/user-attachments/assets/bca17900-5075-4d15-af7a-c71bf8979c04) After: ![image](https://github.com/user-attachments/assets/c5a24e3b-763b-4463-80db-d4dbd89f7dc4) Index: ```json { "schemaVersion": 2, "mediaType": "application/vnd.oci.image.index.v1+json", "manifests": [ { "mediaType": "application/vnd.oci.image.manifest.v1+json", "digest": "sha256:5967afffdfde104ca1459286a72346baaef8b70ac153325d7a6cd85c7734ac6e", "size": 672, "platform": { "architecture": "amd64", "os": "linux" } }, { "mediaType": "application/vnd.oci.image.manifest.v1+json", "digest": "sha256:f9abfcc55320f9ff1f38eeb7dbb4bea10b29c7febfa49ccd7aab9fa02403b9f0", "size": 672, "platform": { "architecture": "arm64", "os": "linux" } }, { "mediaType": "application/vnd.oci.image.manifest.v1+json", "digest": "sha256:d70ad19d00c19e40691045cbddc3e8a5a4454c31cc454d1132b13bcaf35b6d46", "size": 566, "annotations": { "vnd.docker.reference.digest": "sha256:5967afffdfde104ca1459286a72346baaef8b70ac153325d7a6cd85c7734ac6e", "vnd.docker.reference.type": "attestation-manifest" }, "platform": { "architecture": "unknown", "os": "unknown" } }, { "mediaType": "application/vnd.oci.image.manifest.v1+json", "digest": "sha256:73bc233bf4eac96a404ce3e0430b698831a4ea7050c878d5f76d1d1f133751dd", "size": 566, "annotations": { "vnd.docker.reference.digest": "sha256:f9abfcc55320f9ff1f38eeb7dbb4bea10b29c7febfa49ccd7aab9fa02403b9f0", "vnd.docker.reference.type": "attestation-manifest" }, "platform": { "architecture": "unknown", "os": "unknown" } } ] } ``` --------- Co-authored-by: silverwind <me@silverwind.io>
* Repo file list enhancements (#32835)silverwind2024-12-151-3/+3
| | | | | | | | | | | | 1. restore background color 2. fix border radius on top/bottom and on hover 3. parent link is now full-row again, much easier to click 4. parent link now uses directory icon, matching github 5 changed grid layout to remove auto width on file name column which could get too small. 6. mobile layout now shows more of the filename. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Tweak repo sidebar (#32847)silverwind2024-12-155-117/+129
| | | | | | | | | | | | | | | | | | | | | | | Before and after: <img width="218" alt="Screenshot 2024-12-15 at 04 53 53" src="https://github.com/user-attachments/assets/299b1f0a-ba72-47c6-b662-a9d540d4d741" /> <img width="222" alt="Screenshot 2024-12-15 at 04 53 41" src="https://github.com/user-attachments/assets/5a2b5332-e324-4d20-82e9-21d1c850e826" /> Diff without whitespace: https://github.com/go-gitea/gitea/pull/32847/files?diff=unified&w=1 The `tw-mt-2` is fine even if the element renders empty: <img width="387" alt="image" src="https://github.com/user-attachments/assets/76a976e4-ba2e-48a5-9248-c361552a937a" /> --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Remove translation to issue add time because the format is fixed should not ↵Lunny Xiao2024-12-151-1/+1
| | | | | | be translated (#32850) The input content should always be `1h 2m 3s` and will be the same on different UI languages. So the translation is wrong.
* Fix SSPI button visibility when SSPI is the only enabled method (#32841)mevius42024-12-152-2/+2
|
* Fix overflow on org header (#32837)silverwind2024-12-141-2/+2
|
* Fix various UI bugs (#32821)wxiaoguang2024-12-131-1/+1
|
* Fix bug of branch/tag selector in the issue sidebar (#32744)hiifong2024-12-134-5/+20
| | | | | | | Fix: #32731 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Detect whether action view branch was deleted (#32764)Lunny Xiao2024-12-121-3/+3
| | | | | Fix #32761 ![图片](https://github.com/user-attachments/assets/a5a7eef8-0fea-4242-b199-1b0b73d9bbdb)
* Add "n commits" link to contributors in contributors graph page (#32799)Chai-Shi2024-12-121-0/+1
| | | | | | | | | | | | Fixes Issue #29365 and inherit PR #29429 - I should extend the #29429 fork but the fork is not synced, so I created another PR. - Use `silenced` class for the link, as in #29847 --------- Co-authored-by: Ben Chang <ben_chang@htc.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix "unicode escape" JS error (#32806)wxiaoguang2024-12-122-5/+5
| | | | | | | | | | | | | | | | | | | | | <details> ![image](https://github.com/user-attachments/assets/98aef2fb-791e-4b4a-b2ac-e880f8a52040) ![image](https://github.com/user-attachments/assets/532673ae-c4cf-4d84-a5c6-93e6eacd341c) ![image](https://github.com/user-attachments/assets/2a241a3d-b7f6-44ca-89d9-9d68386fbf3e) ![image](https://github.com/user-attachments/assets/1251e43d-41f2-42d1-a23b-3182e3812c3d) </details> --------- Co-authored-by: silverwind <me@silverwind.io>
* Implement update branch API (#32433)Kemal Zebari2024-12-121-0/+73
| | | | | | | | | | Resolves #22526. Builds upon #23061. --------- Co-authored-by: sillyguodong <33891828+sillyguodong@users.noreply.github.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix repo home file list (#32788)wxiaoguang2024-12-114-73/+59
| | | | | | | 1. use grid instead of table, completely drop "ui table" from that list 2. move some "commit sign" related styles into a new file by the way (no change) because I need to figure out where `#repo-files-table` is used. 3. move legacy "branch/tag selector" related code into repo-legacy.ts, now there are 13 `import $` files left.
* Rearrange Clone Panel (#31142)Blender Defender2024-12-117-93/+60
| | | | | | | | | | | | | Rearrange the clone panel to use less horizontal space. The following changes have been made to achieve this: - Moved everything into the dropdown menu - Moved the HTTPS/SSH Switch to a separate line - Moved the "Clone in VS Code"-Button up and added a divider - Named the dropdown button "Code", added appropriate icon --------- Co-authored-by: techknowlogick <techknowlogick@gitea.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Add label/author/assignee filters to the user/org home issue list (#32779)wxiaoguang2024-12-118-57/+85
| | | | | | | | | | Replace #26661, fix #25979 Not perfect, but usable and much better than before. Since it is quite complex, I am not quite sure whether there would be any regression, if any, I will fix in first time. I have tested the related pages many times: issue list, milestone issue list, project view, user issue list, org issue list.
* Fix wiki ui (#32781)wxiaoguang2024-12-101-14/+14
| | | Fix #32774
* Refactor issue filter (labels, poster, assignee) (#32771)wxiaoguang2024-12-106-172/+147
| | | | | | | | | | | | Rewrite a lot of legacy strange code, remove duplicate code, remove jquery, and make these filters reusable. Let's forget the old code, new code affects: * issue list open/close switch * issue list filter (label, author, assignee) * milestone list open/close switch * milestone issue list filter (label, author, assignee) * project view (label, assignee)
* Fix duplicate dropdown dividers (#32760)wxiaoguang2024-12-093-6/+8
| | | | | | | | Fix #27466 The problem is that any item in the menu could be hidden, pure CSS won't work, and dropdown's builtin "hideDividers" doesn't work with our "scope dividers". The newly introduced "archived" label makes the dividers regression more.
* Fix repo home row-right grow (#32763)wxiaoguang2024-12-092-8/+9
| | | Fix #32753
* Refactor issue list (#32755)wxiaoguang2024-12-083-49/+53
| | | | | 1. add backend support for filtering "poster" and "assignee" * due to the limits, there is no frontend support at the moment 2. rewrite TS code without jquery, now there are 14 jQuery files left:
* Refactor LabelEdit (#32752)wxiaoguang2024-12-085-91/+34
| | | | | | | | | | | And fix a regression: https://github.com/go-gitea/gitea/pull/30053#discussion_r1874405470 Major changes: * rewrite without jquery * remove the "delete modal", using "link-action" is good enough * merge "new modal" and "edit modal"
* Support "merge upstream branch" (Sync fork) (#32741)wxiaoguang2024-12-062-0/+21
| | | | | | | | | Add basic "sync fork" support (GitHub-like) <details> ![image](https://github.com/user-attachments/assets/e71473f4-4518-48c7-b9e2-fedfcd564fc3) </details>
* GitHub like repo home page (#32213)yp053272024-12-065-176/+251
| | | | | | | Move some components (description, license, release, language stats) to sidebar --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Refactor RepoActionView.vue, add `::group::` support (#32713)wxiaoguang2024-12-061-0/+30
| | | | | | | 1. make it able to "force reload", then the previous pending request won't block the new request 2. make it support `::group::` 3. add some TS types (but there are still many variables untyped, this PR is large enough, the remaining types could be added in the future)
* Issue time estimate, meaningful time tracking (#23113)Illya Marchenko2024-12-053-75/+90
| | | | | | | | | | | | | Redesign the time tracker side bar, and add "time estimate" support (in "1d 2m" format) Closes #23112 --------- Co-authored-by: stuzer05 <stuzer05@gmail.com> Co-authored-by: Yarden Shoham <hrsi88@gmail.com> Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix fork page branch selection (#32711)Lunny Xiao2024-12-051-8/+6
| | | Fix #32709
* Add Arch package registry (#32692)KN4CK3R2024-12-0423-78/+123
| | | | | | | | | | | | | | | | | | | | | | | Close #25037 Close #31037 This PR adds a Arch package registry usable with pacman. ![grafik](https://github.com/user-attachments/assets/81cdb0c2-02f9-4733-bee2-e48af6b45224) Rewrite of #25396 and #31037. You can follow [this tutorial](https://wiki.archlinux.org/title/Creating_packages) to build a package for testing. Docs PR: https://gitea.com/gitea/docs/pulls/111 Co-authored-by: [d1nch8g@ion.lc](mailto:d1nch8g@ion.lc) Co-authored-by: @ExplodingDragon --------- Co-authored-by: dancheg97 <dancheg97@fmnx.su> Co-authored-by: dragon <ExplodingFKL@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix file editor & preview (#32706)wxiaoguang2024-12-042-44/+9
| | | | | | Fix a regression caused by jQuery removal (`renderPreviewPanelContent`) And simplify the file editor, it doesn't need to be that complex. And remove jQuery code.
* Refactor markdown editor and use it for milestone description editor (#32688)wxiaoguang2024-12-0416-39/+81
| | | | | | | | | | Refactor markdown editor to clarify its "preview" behavior and remove jQuery code. Close #15045 --------- Co-authored-by: silverwind <me@silverwind.io>
* Fix issue title rendering and refactor legacy function names (#32703)wxiaoguang2024-12-047-16/+16
| | | | | | | | Fix #32700, regression of recent markup refactoring And by the way, clarify many legacy problems: 1. Some "RenderXxx" functions do not really "render", they only call "post processors" 2. Merge "RenderEmoji | RenderCodeBlock", they are all for "simple issue title"
* Fix oauth2 login methods (#32698)wxiaoguang2024-12-032-4/+5
| | | | | | Regression of #32687 It should use "or" but not "and", otherwise the oauth2 methods won't show when no ENABLE_OPENID_SIGNIN
* Fix word overflow in file search page (#32695)yp053272024-12-031-1/+1
|
* Add "View all branches/tags" entry to Branch Selector (#32653)Kerwin Bryant2024-12-022-0/+5
| | | | | | | ![image](https://github.com/user-attachments/assets/7b62a38f-36d5-452a-8a97-204842c68b2e) --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Remove all "floated" CSS styles (#32691)wxiaoguang2024-12-033-32/+28
| | | | | | | | | | | | | | | | | | | | flex but don't float diff with ignoring spaces : https://github.com/go-gitea/gitea/pull/32691/files?diff=split&w=1 related pages: ### admin users ![image](https://github.com/user-attachments/assets/40dd4c46-3f5b-4a68-89b0-d0a9a806f1fc) ### milestone ![image](https://github.com/user-attachments/assets/e3efb630-f07c-4c9d-b877-71e28cddcdce) ### user account setting ![image](https://github.com/user-attachments/assets/d15609ee-016d-4aee-999a-b5455fe6185c)
* Optimize the styling of icon buttons within file-header-right (#32675)Kerwin Bryant2024-12-021-5/+5
| | | | | | | | | | | | | Optimize partial layout and styling to achieve uniformity and consistency. Some buttons's structure is `<a><span><svg/></span></a>`, while others buttons's structure is `<a><svg/></a>`. Additionally, some buttons have icons that are **14** in size, while others have icons that are **16**. Now, the layout has been unified to structure `<a><svg/></a>`, and the icon size for all buttons has been standardized to the default size of **16**. Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* fix: show tag name on branch/tag selector if repo shown from tag ref (#32689)metiftikci2024-12-022-4/+4
|
* Refactor RepoBranchTagSelector (#32681)wxiaoguang2024-12-025-81/+97
|
* Allow to disable the password-based login (sign-in) form (#32687)wxiaoguang2024-12-023-8/+12
| | | | | | | | | | | | | | 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
* fix(#32667): 🐛 Fixe a keystring misuse and refactor duplicates keystrings ↵Simon Pistache2024-12-012-3/+3
| | | | | | | | | | | | | | (#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>
* Allow cropping an avatar before setting it (#32565)Kerwin Bryant2024-11-281-0/+5
| | | | | | | | | | | | 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>
* Add priority to protected branch (#32286)65432024-11-272-2/+87
| | | | | | | | | | | | | | | | | | | ## 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*
* Refactor some frontend problems (#32646)wxiaoguang2024-11-2613-64/+83
| | | | | | | | | | | 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
* Fixed Issue of Review Menu Shown Behind (#32631)Kerwin Bryant2024-11-261-16/+14
| | | | | | | Fixed #31144 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Update the list of watchers and stargazers when clicking watch/unwatch or ↵Yarden Shoham2024-11-221-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | star/unstar (#32570) We make sure the user cards are updated - Fixes https://github.com/go-gitea/gitea/issues/32561 I also removed `ctx.Data["PageIsWatchers"] = true` and `ctx.Data["PageIsStargazers"] = true` as they are not used anywhere. # Before ![before](https://github.com/user-attachments/assets/e3bc3235-35eb-4eda-862d-bdf2510282ea) # After ![after](https://github.com/user-attachments/assets/bc0488a5-8399-4cf6-95c9-17328a9702eb) --------- Signed-off-by: Yarden Shoham <git@yardenshoham.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: silverwind <me@silverwind.io>
* Fix issues with inconsistent spacing in areas (#32607)Kerwin Bryant2024-11-222-3/+3
| | | | | | | | | | | | | | | | | | | Fix issues with inconsistent spacing in areas where the branch_dropdown component is used. before: ![1732238359257](https://github.com/user-attachments/assets/38edda1f-ec4e-419e-9264-68009375d177) ![1732238334410](https://github.com/user-attachments/assets/c4770aea-bc83-477c-9b6a-632f984c0d7d) after: ![1732238273317](https://github.com/user-attachments/assets/4d05068e-db97-45af-86c4-29442dff1bdf) ![1732238723881](https://github.com/user-attachments/assets/69acd286-f79b-44fe-ad73-2d5fc6dfc98c) --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Style unification for the issue_management area (#32605)Kerwin Bryant2024-11-222-3/+3
| | | | | | | | | | | | | | | | | | | | Style unification for the issue_management area (consistent across the layout before: ![1732237277916](https://github.com/user-attachments/assets/52a20b2d-d6a4-4118-9cdf-9b377115b7f7) ![1732237288802](https://github.com/user-attachments/assets/05592fe8-cab2-412b-99bc-f0a201c08413) ![1732237299849](https://github.com/user-attachments/assets/8be4a891-c514-4983-bad4-fcc5a7a9d838) after: ![1732237471086](https://github.com/user-attachments/assets/0bd19ef6-79c1-490a-8ffa-6a42208befd9) --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Enhancing Gitea OAuth2 Provider with Granular Scopes for Resource Access ↵Marcell Mars2024-11-221-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#32573) Resolve #31609 This PR was initiated following my personal research to find the lightest possible Single Sign-On solution for self-hosted setups. The existing solutions often seemed too enterprise-oriented, involving many moving parts and services, demanding significant resources while promising planetary-scale capabilities. Others were adequate in supporting basic OAuth2 flows but lacked proper user management features, such as a change password UI. Gitea hits the sweet spot for me, provided it supports more granular access permissions for resources under users who accept the OAuth2 application. This PR aims to introduce granularity in handling user resources as nonintrusively and simply as possible. It allows third parties to inform users about their intent to not ask for the full access and instead request a specific, reduced scope. If the provided scopes are **only** the typical ones for OIDC/OAuth2—`openid`, `profile`, `email`, and `groups`—everything remains unchanged (currently full access to user's resources). Additionally, this PR supports processing scopes already introduced with [personal tokens](https://docs.gitea.com/development/oauth2-provider#scopes) (e.g. `read:user`, `write:issue`, `read:group`, `write:repository`...) Personal tokens define scopes around specific resources: user info, repositories, issues, packages, organizations, notifications, miscellaneous, admin, and activitypub, with access delineated by read and/or write permissions. The initial case I wanted to address was to have Gitea act as an OAuth2 Identity Provider. To achieve that, with this PR, I would only add `openid public-only` to provide access token to the third party to authenticate the Gitea's user but no further access to the API and users resources. Another example: if a third party wanted to interact solely with Issues, it would need to add `read:user` (for authorization) and `read:issue`/`write:issue` to manage Issues. My approach is based on my understanding of how scopes can be utilized, supported by examples like [Sample Use Cases: Scopes and Claims](https://auth0.com/docs/get-started/apis/scopes/sample-use-cases-scopes-and-claims) on auth0.com. I renamed `CheckOAuthAccessToken` to `GetOAuthAccessTokenScopeAndUserID` so now it returns AccessTokenScope and user's ID. In the case of additional scopes in `userIDFromToken` the default `all` would be reduced to whatever was asked via those scopes. The main difference is the opportunity to reduce the permissions from `all`, as is currently the case, to what is provided by the additional scopes described above. Screenshots: ![Screenshot_20241121_121405](https://github.com/user-attachments/assets/29deaed7-4333-4b02-8898-b822e6f2463e) ![Screenshot_20241121_120211](https://github.com/user-attachments/assets/7a4a4ef7-409c-4116-9d5f-2fe00eb37167) ![Screenshot_20241121_120119](https://github.com/user-attachments/assets/aa52c1a2-212d-4e64-bcdf-7122cee49eb6) ![Screenshot_20241121_120018](https://github.com/user-attachments/assets/9eac318c-e381-4ea9-9e2c-3a3f60319e47) --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Add line-through for deleted branch on pull request view page (#32500)Lunny Xiao2024-11-212-3/+8
| | | | | | | | | | | | | Base branch deleted ![图片](https://github.com/user-attachments/assets/bc45aa33-d514-47c8-885a-de9732f2f3d5) branch deleted comment ![图片](https://github.com/user-attachments/assets/83729bbb-2ee8-4bd3-b6f1-780d2daad3d4) Head branch deleted ![图片](https://github.com/user-attachments/assets/90120b22-34a9-4387-aae9-5c882e8d421a)
* Fix issue sidebar regression (#32598)wxiaoguang2024-11-221-1/+1
|