aboutsummaryrefslogtreecommitdiffstats
path: root/templates/user
Commit message (Collapse)AuthorAgeFilesLines
* Update milestones.tmpl (#34184)Kerwin Bryant3 days1-1/+1
|
* Fix markdown render behaviors (#34122)wxiaoguang10 days1-1/+1
| | | | | | | * Fix #27645 * Add config options `MATH_CODE_BLOCK_DETECTION`, problematic syntaxes are disabled by default * Fix #33639 * Add config options `RENDER_OPTIONS_*`, old behaviors are kept
* Refactor dropdown ellipsis (#34123)wxiaoguang10 days1-8/+8
| | | Remove legacy `truncated-item-container` and `truncated-item-name`.
* Prepare common tmpl functions in a middleware (#33957)wxiaoguang2025-03-251-1/+1
| | | | Fix the TODO in `routers/web/web.go`, and avoid the unnecessary `GetActiveStopwatch` SQL query in non-related route handlers.
* Only use prev and next buttons for pagination on user dashboard (#33981)Lunny Xiao2025-03-231-1/+1
| | | | | | | | | | | The pagination on the user dashboard sounds unnecessary, this will change it to a prev/next buttons. For instances with around `10 million` records in the action table, this option affects how the user dashboard is loaded on first visit. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Fix oauth2 auth and UI (#33961)wxiaoguang2025-03-212-42/+37
|
* Defer captcha script loading (#33919)wxiaoguang2025-03-171-3/+3
| | | Fix #33899
* Remove unused or abused styles (#33918)wxiaoguang2025-03-171-1/+1
| | | | | | * `top aligned` => `tw-align-top` * label list: it was broken, this PR fixes it * reference link: simplified * settings/repos: not affected
* Replace text-align classes with tailwind (#33905)silverwind2025-03-164-4/+4
| | | | | | | Small refactor to remove these CSS classes in favor of tailwind. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Improve issue & code search (#33860)wxiaoguang2025-03-131-2/+8
| | | | Each "indexer" should provide the "search modes" they support by themselves. And we need to remove the "fuzzy" search for code.
* Removing unwanted ui container (#33833)Vinoth Kumar2025-03-101-0/+2
| | | | | | when the passkey auth and register was disabled the unwanted ui container was show Co-authored-by: Vinoth414 <103478407+Vinoth414@users.noreply.github.com>
* Improve theme display (#30671)wxiaoguang2025-03-081-1/+1
| | | | | | Document: https://gitea.com/gitea/docs/pulls/180 ![image](https://github.com/go-gitea/gitea/assets/2114189/68e38573-b911-45d9-b7aa-40d96d836ecb)
* Refactor markup and pdf-viewer to use new init framework (#33772)Kerwin Bryant2025-03-033-6/+4
| | | | | | | | | | | | | | | | 1. Add some "render-content" classes to "markup" elements when the content is rendered 2. Use correct "markup" wrapper for "preview" (but not set that class on the tab) 3. Remove incorrect "markup" class from LFS file view, because there is no markup content * "edit-diff" is also removed because it does nothing 5. Use "initPdfViewer" for PDF viewer 6. Remove incorrect "content" class from milestone markup 7. Init all ".markup" elements by new init framework --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Improve "generate new access token" form (#33730)Guillaume2025-02-272-69/+61
| | | | | | | | | | | | | | | | | | | | | Fix: https://github.com/go-gitea/gitea/issues/33519 As discussed in [PR #33614](https://github.com/go-gitea/gitea/pull/33614), the ScopedAccessTokenSelector Vue component is not particularly useful. This PR removes the component and reverts to using HTML templates. It also introduces some (hopefully) useful refactoring. The Vue component was causing the UX bug reported in the linked issue. Required form fields are now properly working, as expected (see screenshot). ![Screenshot from 2025-02-25 22-00-28](https://github.com/user-attachments/assets/41167854-0718-48b0-a3ee-75ca3a7b8b20) --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* enhancement: add additional command hints for PowerShell & CMD (#33548)jason199702102025-02-111-1/+10
| | | | | | | | | | - resolving wrong signature calculations for SSH key verification Fixed #22693 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Optimize the dashboard (#32990)Kerwin Bryant2025-02-113-1/+19
| | | | | | | | | | | | | | | | | | | | | before: ![image](https://github.com/user-attachments/assets/d0b432e4-a521-4540-a489-d18b9c265674) after: ![image](https://github.com/user-attachments/assets/dbb8b387-d150-41e2-b12b-f9d8450e36d7) ----- ![image](https://github.com/user-attachments/assets/40dcd71e-344b-4043-9811-77227c71aed9) ----- Optimize the dashboard by adding welcoming messages or quick action entry points (such as adding a new repository or organization) to ensure that new users are not greeted by a blank page upon logging in. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Add cropping support when modifying the user/org/repo avatar (#33498)Kerwin Bryant2025-02-061-7/+1
| | | | | | | | Fixed #33321 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Worktime tracking for the organization level (#19808)K Kovacs2025-02-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Dear Gitea team, first of all, thanks for the great work you're doing with this project. I'm planning to introduce Gitea at a client site, and noticed that while there is time recording, there are no project-manager-friendly reports to actually make use of that data, as were also mentioned by others in #4870 #8684 and #13531. Since I had a little time last weekend, I had put together something that I hope to be a useful contribution to this great project (while of course useful for me too). This PR adds a new "Worktime" tab to the Organisation level. There is a date range selector (by default set to the current month), and there are three possible views: - by repository, - by milestone, and - by team member. Happy to receive any feedback! There are several possible future improvements of course (predefined date ranges, charts, a member time sheet, matrix of repos/members, etc) but I hope that even in this relatively simple state this would be useful to lots of people. <img width="1161" alt="Screen Shot 2022-05-25 at 22 12 58" src="https://user-images.githubusercontent.com/118010/170366976-af00c7af-c4f3-4117-86d7-00356d6797a5.png"> Keep up the good work! Kristof --------- Co-authored-by: user <user@kk-git1> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Add missed auto merge feed message on dashboard (#33309)Lunny Xiao2025-01-261-1/+4
|
* Support disable passkey auth (#33348)yp053272025-01-221-3/+4
| | | | | | | Fix #33314 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix Account linking page (#33325)CrimsonEdgeHope2025-01-193-3/+9
| | | | | | | | | | | Fix password form missing whilst linking account even with `ENABLE_PASSWORD_SIGNIN_FORM = true`. Remove redundant empty box in account linking sign up page when `LinkAccountMode` is true. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix form width (#33151)wxiaoguang2025-01-081-29/+29
| | | Fix #33150
* Fix dropdown menu header and mobile view (#33108)wxiaoguang2025-01-051-2/+2
| | | | | | | | | | | ![image](https://github.com/user-attachments/assets/3f831c8c-ef87-4282-880a-c2738f3e1d17) ---- ![image](https://github.com/user-attachments/assets/c4c0519b-cfa6-42b4-bd28-205ee514eb34) ---- ![image](https://github.com/user-attachments/assets/8624a605-9f2b-4905-9cbc-0af073972874)
* Trivial fixes (#33103)wxiaoguang2025-01-041-1/+1
| | | | 1. remove `gock` dependency, it is not needed 2. fix a regression from org private profile readme
* Clean up legacy form CSS styles (#33081)wxiaoguang2025-01-035-85/+38
|
* [Feature] Private README.md for organization (#32872)Chai-Shi2024-12-311-1/+1
| | | | | | | | Implemented #29503 --------- Co-authored-by: Ben Chang <ben_chang@htc.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Add `show more` organizations icon in user's profile (#32986)yp053272024-12-271-0/+2
| | | | | | | | | | | | | | | | | | | Close #32952 # ⚠️ Doc update is required ![image](https://github.com/user-attachments/assets/296c5109-8fc1-43ea-b7dc-e79919cc1f9a) ![image](https://github.com/user-attachments/assets/d30980f6-22e4-4b97-9143-c750dc399da6) ------ ⚠️This PR refuses to be cherry-picked by any forked projects without any mentions. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix various trivial problems (#32861)wxiaoguang2024-12-173-0/+5
| | | | | | | | | | | | | | 1. add/improve comments to help future readers could understand the problem more easily. 2. add an error log to LDAP with username fallback 3. use `or` instead of `Iif` for "repo/branch_dropdown" (`Iif` was a mistake, but it doesn't really affect the UI) 4. add `tw-font-mono` style to container digest to match dockerhub 5. fix a bug in RepoBranchTagSelector: the form is not updated when there is no click to an item --------- Co-authored-by: delvh <dev.lh@web.de>
* Fix SSPI button visibility when SSPI is the only enabled method (#32841)mevius42024-12-152-2/+2
|
* Add label/author/assignee filters to the user/org home issue list (#32779)wxiaoguang2024-12-112-37/+62
| | | | | | | | | | 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.
* Refactor issue list (#32755)wxiaoguang2024-12-081-19/+22
| | | | | 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 markdown editor and use it for milestone description editor (#32688)wxiaoguang2024-12-041-0/+1
| | | | | | | | | | 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-042-5/+5
| | | | | | | | 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
* Remove all "floated" CSS styles (#32691)wxiaoguang2024-12-031-26/+22
| | | | | | | | | | | | | | | | | | | | 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)
* 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
* 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>
* 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>
* Fix some places which doesn't repsect org full name setting (#32243)Lunny Xiao2024-11-181-1/+1
| | | Partially fix #31345
* Refactor template ctx and render utils (#32422)wxiaoguang2024-11-052-10/+10
| | | Clean up the templates
* Refactor DateUtils and merge TimeSince (#32409)wxiaoguang2024-11-049-13/+13
| | | Follow #32383 and #32402
* Replace DateTime with proper functions (#32402)wxiaoguang2024-11-021-1/+1
| | | | | | | | | Follow #32383 This PR cleans up the "Deadline" usages in templates, make them call `ParseLegacy` first to get a `Time` struct then display by `DateUtils`. Now it should be pretty clear how "deadline string" works, it makes it possible to do further refactoring and correcting.
* Replace DateTime with DateUtils (#32383)wxiaoguang2024-11-026-7/+7
|
* Enhance USER_DISABLED_FEATURES to allow disabling change username or full ↵Zisu Zhang2024-10-051-3/+6
| | | | | | | | | | | | | | | name (#31959) Fix #31958 Enhanced `USER_DISABLED_FEATURES`(also `EXTERNAL_USER_DISABLE_FEATURES`) option in `[admin]` section. Added following values: - `change_username`: Disable change username - `change_full_name`: Disable change full name --- Progress: - [x] Update code - [x] Update translations
* Set manual `tabindex`es on login page (#31689)silverwind2024-09-201-5/+7
| | | | | | | | | | | Fixes https://github.com/go-gitea/gitea/issues/31686. A more elborate manual tabindex numbering could be done, but I think it's not really worth the extra effort and such stuff could easily break during refactors. Includes another small tweak to un-stretch the`<a>` element so it's only as large as it needs to be and this change also made the margin unneeded.
* Remove urls from translations (#31950)Denys Konovalov2024-09-021-1/+1
| | | | | | | Part of #27700 Removes all URLs from translation strings to easy up changing them in the future and to exclude people injecting malicious URLs through translations. First measure as long as #24402 is out of scope.
* fix the component of access token list not mounted (#31824)sillyguodong2024-08-161-7/+7
| | | try to fix #31771
* add skip secondary authorization option for public oauth2 clients (#31454)Denys Konovalov2024-07-192-2/+14
|
* Added default sorting milestones by name (#27084)Bartlomiej Komendarczuk2024-07-161-0/+1
| | | | | | | | | | #26996 Added default sorting for milestones by name. Additional, name for sorting closestduedate and furthestduedate was broken, so I fixed it. --------- Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* Allow disabling authentication related user features (#31535)Rowan Bohde2024-07-093-1/+20
| | | | | | | | | | | | | | | | | | | | We have some instances that only allow using an external authentication source for authentication. In this case, users changing their email, password, or linked OpenID connections will not have any effect, and we'd like to prevent showing that to them to prevent confusion. Included in this are several changes to support this: * A new setting to disable user managed authentication credentials (email, password & OpenID connections) * A new setting to disable user managed MFA (2FA codes & WebAuthn) * Fix an issue where some templates had separate logic for determining if a feature was disabled since it didn't check the globally disabled features * Hide more user setting pages in the navbar when their settings aren't enabled --------- Co-authored-by: Kyle D <kdumontnu@gmail.com>