summaryrefslogtreecommitdiffstats
path: root/templates
Commit message (Collapse)AuthorAgeFilesLines
* Adding hint `Archived` to archive label. (#26741)puni98692023-08-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Followup https://github.com/go-gitea/gitea/pull/26478 ## Archived labels UI Changed: * Enhanced the Filtered UI page to seamlessly incorporate a list of archived labels. Outsourced: * Defer the implementation of specialized handling for archived labels to upcoming pull requests. This step will be undertaken subsequent to the successful merge of this pull request. Screenshots ![image](https://github.com/go-gitea/gitea/assets/80308335/1f33cfb2-2bac-46f0-9103-9e62d235b1d2) ![image](https://github.com/go-gitea/gitea/assets/80308335/3609acd0-b1ba-4ee9-8c4e-1a34dbc37dd7) ![image](https://github.com/go-gitea/gitea/assets/80308335/9860196d-2391-409b-a9a0-1205ab4b412b) --- Part of https://github.com/go-gitea/gitea/issues/25237 --------- Co-authored-by: Giteabot <teabot@gitea.io> Co-authored-by: silverwind <me@silverwind.io>
* Fix template bugs in recently_pushed_new_branches.tmpl (#26744)wxiaoguang2023-08-271-2/+2
| | | | | | | Fix some bugs from #25715, fix #25830 1. `$.locale.Tr ... Safe` needs `Escape`, but not `PathEscapeSegments` 2. The attribute should be `role` 3. The `ComposeBranchCompareURL` already does escaping correctly
* Fix incorrect "tabindex" attributes (#26733)wxiaoguang2023-08-2610-51/+51
| | | | | | | | | | | | Fix #26731 Almost all "tabindex" in code are incorrect. 1. All "input/button" by default are focusable, so no need to use "tabindex=0" 2. All "div/span" by default are not focusable, so no need to use "tabindex=-1" 3. All "dropdown" are focusable by framework, so no need to use "tabindex" 4. Some tabindex values are incorrect (eg: `new_form.tmpl`), so remove them Co-authored-by: Giteabot <teabot@gitea.io>
* Simplify helper CSS classes and avoid abuse (#26728)wxiaoguang2023-08-2614-28/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Removed CSS helper classes (some of them are not useful while some of them are abused often) * `gt-db`: in most cases it could be replaced by `gt-df` and the flex layout should be encouraged. Other cases: either it does need the `gt-df` (eg: by using `div` directly) or it is an abuse (eg: the warning message in a form) * `gt-di`: it doesn't seem useful, or it could be replaced by `gt-dib` in most cases. * `gt-dif`: not useful, it could be replaced by `flex-text-inline` or `gt-df` * `gt-js`: never used * All `<i class="icon gt-df gt-ac gt-jc">` could be written as `<i class="icon">` ## Some UI samples ### Admin Notice ![image](https://github.com/go-gitea/gitea/assets/2114189/d02010d4-dc7d-463f-bc99-dcc9b6e2e2ac) ### Admin Stacktrace ![image](https://github.com/go-gitea/gitea/assets/2114189/4045695c-a8c4-4e37-b720-e77a61b1e965) ### Org Home ![image](https://github.com/go-gitea/gitea/assets/2114189/069f02d0-76ad-4052-8a80-700d7e501d40) ### Org Team Repo ![image](https://github.com/go-gitea/gitea/assets/2114189/dc8d6106-bb6b-4f60-83ac-06cb28df3ab5) ### Release List ![image](https://github.com/go-gitea/gitea/assets/2114189/0845e8a5-d1a9-487a-9d25-3c200ad54c17) ### User Setting Application Token Scope ![image](https://github.com/go-gitea/gitea/assets/2114189/fffbde27-432b-49c6-827e-17b8cd3457ff) Co-authored-by: Giteabot <teabot@gitea.io>
* Remove fomantic loader module (#26670)silverwind2023-08-252-8/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | Replace Fomantic `loader` CSS module with our existing `is-loading` spinner. Only three places in the UI used this module, which are pictured here: imagediff: <img width="1237" alt="Screenshot 2023-08-22 at 22 18 01" src="https://github.com/go-gitea/gitea/assets/115237/b0d82531-f05e-43c6-9e5b-1bfc268c056d"> webauthn: <img width="894" alt="Screenshot 2023-08-22 at 22 05 05" src="https://github.com/go-gitea/gitea/assets/115237/7b583425-d944-474a-a57a-22a65bbd8b29"> heatmap (I removed the previous loading text, it was unreadable because it was tiny and on fast machines only visible for a fraction of a second): <img width="764" alt="Screenshot 2023-08-22 at 22 18 44" src="https://github.com/go-gitea/gitea/assets/115237/1c7472d6-3e17-4224-a992-d8c0b380cc73"> Also, heatmap container does not resize any more after loading now and previous duplicate id `user-heatmap` is gone. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix link in mirror docs (#26719)silverwind2023-08-251-1/+1
| | | | | Fix hash fragment in this link Co-authored-by: Giteabot <teabot@gitea.io>
* Remove incorrect CSS helper classes (#26712)wxiaoguang2023-08-252-6/+6
|
* Fix review bar misalignment (#26711)wxiaoguang2023-08-241-1/+1
|
* Improve Image Diff UI (#26696)wxiaoguang2023-08-241-5/+2
| | | | | 1. Use `is-loading` instead of `ui loader` 2. Introduce class name `image-diff-tabs`, instead of searching `gt-hidden`, which is fragile 3. Align the UI elements, see the screenshots.
* Make issue template field template access correct template data (#26698)wxiaoguang2023-08-241-2/+1
| | | Regression of #23092, the `{{$field := .}}` was missing during that refactoring.
* add Upload URL to release API (#26663)Earl Warren2023-08-241-0/+4
| | | | | | | | | | | | - Resolves https://codeberg.org/forgejo/forgejo/issues/580 - Return a `upload_field` to any release API response, which points to the API URL for uploading new assets. - Adds unit test. - Adds integration testing to verify URL is returned correctly and that upload endpoint actually works --------- Co-authored-by: Gusted <postmaster@gusted.xyz>
* Add `member`, `collaborator`, `contributor`, and `first-time contributor` ↵yp053272023-08-241-11/+6
| | | | | | | | | | | | | | | | | roles and tooltips (#26658) GitHub like role descriptor ![image](https://github.com/go-gitea/gitea/assets/18380374/ceaed92c-6749-47b3-89e8-0e0e7ae65321) ![image](https://github.com/go-gitea/gitea/assets/18380374/8193ec34-cbf0-47f9-b0de-10dbddd66970) ![image](https://github.com/go-gitea/gitea/assets/18380374/56c7ed85-6177-425e-9f2f-926e99770782) --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* feat(API): update and delete secret for managing organization secrets (#26660)Bo-Yi Wu2023-08-241-1/+99
| | | | | | | | | | | | | | | | | | - Add `UpdateSecret` function to modify org or user repo secret - Add `DeleteSecret` function to delete secret from an organization - Add `UpdateSecretOption` struct for updating secret options - Add `UpdateOrgSecret` function to update a secret in an organization - Add `DeleteOrgSecret` function to delete a secret in an organization GitHub API 1. Update Org Secret: https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#create-or-update-an-organization-secret 2. Delete Org Secret: https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#delete-an-organization-secret --------- Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
* Remove ref name in PR commits page (#25876)yp053272023-08-241-3/+3
| | | | | | | | | | | | | | | | | | | | The branch name display here is based on the repo's default branch which is not correct. ![image](https://github.com/go-gitea/gitea/assets/18380374/d899f6dc-b240-41ea-9a3e-ea0e103874ad) For example, if I changed the default branch, the branch name here will also be changed: ![image](https://github.com/go-gitea/gitea/assets/18380374/032ead94-2287-4158-a9e4-02e9fb74777d) ![image](https://github.com/go-gitea/gitea/assets/18380374/e1e6cbbc-31f8-40a2-b99a-508b5b2b3145) you can confirm this in : https://try.gitea.io/yp05327/testrepo/pulls/1/commits I think we do not need to display branch name here, as we already have the branch info above. ![image](https://github.com/go-gitea/gitea/assets/18380374/66f30a0c-3c2b-4d26-936d-bbe289f33be0)
* Make "link-action" backend code respond correct JSON content (#26680)wxiaoguang2023-08-234-4/+4
| | | | | Otherwise the `link-action` JS code couldn't parse the response. Co-authored-by: Giteabot <teabot@gitea.io>
* Fix doubled box-shadow in branch dropdown menu (#26678)wxiaoguang2023-08-231-1/+1
|
* More improvements for the "flex list" and the dashboard list (#26675)wxiaoguang2023-08-232-19/+16
| | | Follow #26649 and #25790 and add one more example (text truncate) in the devtest page
* Fix counting and filtering on the dashboard page for issues (#26657)Jason Song2023-08-231-6/+6
| | | | | | | | | | | | | | | | | | This PR has multiple parts, and I didn't split them because it's not easy to test them separately since they are all about the dashboard page for issues. 1. Support counting issues via indexer to fix #26361 2. Fix repo selection so it also fixes #26653 3. Keep keywords in filter links. The first two are regressions of #26012. After: https://github.com/go-gitea/gitea/assets/9418365/71dfea7e-d9e2-42b6-851a-cc081435c946 Thanks to @CaiCandong for helping with some tests.
* Improve repo sub menu (#26531)yp053272023-08-221-4/+4
| | | | | | | | | | | Before: ![image](https://github.com/go-gitea/gitea/assets/18380374/9e71282c-4645-45f3-bdb8-13c4333f7c2b) After: ![image](https://github.com/go-gitea/gitea/assets/18380374/656ff837-35cf-43f8-88d0-f5e123600e57) Icons are not in the middle of the line.
* Improve show role (#26621)yp053272023-08-223-61/+23
| | | Add a general show role template.
* Improve some flex layouts (#26649)wxiaoguang2023-08-222-58/+93
| | | | | | | | Fix #26617 1. Separate the "flex-list" examples into a dedicated template, and add some more examples 2. Use `flex-basis` instead of `flex-shrink` for `flex-item-trailing`, to avoid wrapping the texts too aggressively 3. Some `flex-wrap: wrap;` are removed
* feat: implement organization secret creation API (#26566)Bo-Yi Wu2023-08-221-2/+72
| | | | | | | | | | | | | - Add a new `CreateSecretOption` struct for creating secrets - Implement a `CreateOrgSecret` function to create a secret in an organization - Add a new route in `api.go` to handle the creation of organization secrets - Update the Swagger template to include the new `CreateOrgSecret` API endpoint --------- Signed-off-by: appleboy <appleboy.tw@gmail.com>
* Check disabled workflow when rerun jobs (#26535)yp053272023-08-221-0/+2
| | | | | | | | In GitHub, we can not rerun jobs if the workflow is disabled. --------- Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Remove avatarHTML from template helpers (#26598)wxiaoguang2023-08-211-1/+1
| | | | | | The HTML code is more readable and more correct (it needs `"ui avatar"` class) Co-authored-by: Giteabot <teabot@gitea.io>
* Improve translation of milestone filters (#26569)CaiCandong2023-08-211-2/+2
| | | | | | | | | | | | | https://github.com/go-gitea/gitea/issues/26567#issue-1855312074 > The terms `closest` and `furthest` don't describe the actual sorting behavior as these two are semantically relative to the current date. > Could we switch to `earliest` and `latest` instead? close #26567 --------- Co-authored-by: yp05327 <576951401@qq.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Add `branch_filter` to hooks API endpoints (#26599)Yarden Shoham2023-08-211-0/+4
| | | | | | | | | | | | | | | | | | We now include the branch filler in the response. - Closes #26591 # Before ![image](https://github.com/go-gitea/gitea/assets/20454870/73933940-c1a7-4573-abae-f340b63028b2) # After ![image](https://github.com/go-gitea/gitea/assets/20454870/3b3c4a85-0f7c-48c7-8617-def7a66c671d) --------- Signed-off-by: Yarden Shoham <git@yardenshoham.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Fix "issueReposQueryPattern does not match query" (#26556)Jason Song2023-08-171-1/+1
| | | | | | | | | Fix `https://github.com/go-gitea/gitea/pull/26545#discussion_r1295734340` --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Differentiate better between user settings and admin settings (#26538)yp053272023-08-162-2/+2
| | | | | | | | | | | | | | | | | User settings page and admin settings page are too similar. I thinlk this will be better of using `User Settings` and `Admin Settings` as the navbar's title. Before: ![image](https://github.com/go-gitea/gitea/assets/18380374/68db06f3-918b-41bc-b4d3-522b1057eb57) ![image](https://github.com/go-gitea/gitea/assets/18380374/24f53d91-54e1-410c-ad9b-438bb2c8069f) After: ![image](https://github.com/go-gitea/gitea/assets/18380374/6600a872-d630-4ea6-a58f-d9ded7d38067) ![image](https://github.com/go-gitea/gitea/assets/18380374/501cde5d-9868-4cba-829d-ff8bafce695d)
* Improve deadline icon location in milestone list page (#26532)yp053272023-08-161-1/+1
|
* Use unique class for breadcrumb divider (#26524)silverwind2023-08-165-5/+5
| | | | | | | | | | | | | | | Fix regression from https://github.com/go-gitea/gitea/pull/25539: https://github.com/go-gitea/gitea/pull/26519#issuecomment-1678825200. Before: <img width="429" alt="Screenshot 2023-08-15 at 15 46 12" src="https://github.com/go-gitea/gitea/assets/115237/a818f60a-77a2-48fe-8e6f-363d152ccb1e"> After: <img width="424" alt="Screenshot 2023-08-15 at 15 46 19" src="https://github.com/go-gitea/gitea/assets/115237/c90159e2-ced2-4a74-8a0f-a1b2b5d0b565"> <img width="605" alt="Screenshot 2023-08-15 at 15 56 11" src="https://github.com/go-gitea/gitea/assets/115237/3ded6f57-86f4-422a-86cb-56dd2c216dee">
* Fix typo of RunerOwnerID (#26508)yp053272023-08-151-1/+1
|
* Fix display problems of members and teams unit (#26363)yp053272023-08-152-17/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix: - display member count and team count in the menu bar ![image](https://github.com/go-gitea/gitea/assets/18380374/7f03ced4-67e2-41ce-b19f-a992823726bb) - Also display member unit in the menu bar if there are no hidden members in public org ![image](https://github.com/go-gitea/gitea/assets/18380374/31422ad6-7190-438d-8e99-8a4af9cce908) - hidden member board when there's no seeable members. In this org, we only have hidden members: ![image](https://github.com/go-gitea/gitea/assets/18380374/d749420b-554a-4483-8cd2-221df61b5ca7) We will hidden the member board when doer is not the member of this org ![image](https://github.com/go-gitea/gitea/assets/18380374/93bb782e-7d4d-4ad3-a096-133afbc51f8a) Before: ![image](https://github.com/go-gitea/gitea/assets/18380374/eafc0b3e-6218-42ab-a892-39645d08a5eb) If you click the number in the members board, you will access the members page, which is not expected. ![image](https://github.com/go-gitea/gitea/assets/18380374/73d6dadc-0ef2-4ca9-8485-c5f4211bffb2) --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Giteabot <teabot@gitea.io>
* Add API route to list org secrets (#26485)Bo-Yi Wu2023-08-151-0/+64
| | | | | | | | | | | | | | | | | | | - Add a new function `CountOrgSecrets` in the file `models/secret/secret.go` - Add a new file `modules/structs/secret.go` - Add a new function `ListActionsSecrets` in the file `routers/api/v1/api.go` - Add a new file `routers/api/v1/org/action.go` - Add a new function `listActionsSecrets` in the file `routers/api/v1/org/action.go` go-sdk: https://gitea.com/gitea/go-sdk/pulls/629 --------- Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: techknowlogick <matti@mdranta.net> Co-authored-by: Giteabot <teabot@gitea.io>
* add disable workflow feature (#26413)a10121127962023-08-141-1/+18
| | | | | | | | | | | | | | | | As title, that's simmilar with github. ![image](https://github.com/go-gitea/gitea/assets/25342410/9e8b2444-63e0-4e87-80da-730c1e4d09d6) ![image](https://github.com/go-gitea/gitea/assets/25342410/6c3a3345-3ba7-48c9-9acd-3e621632491b) --------- Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: Jason Song <i@wolfogre.com>
* Allow to archive labels (#26478)puni98692023-08-143-2/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ## Archived labels This adds the structure to allow for archived labels. Archived labels are, just like closed milestones or projects, a medium to hide information without deleting it. It is especially useful if there are outdated labels that should no longer be used without deleting the label entirely. ## Changes 1. UI and API have been equipped with the support to mark a label as archived 2. The time when a label has been archived will be stored in the DB ## Outsourced for the future There's no special handling for archived labels at the moment. This will be done in the future. ## Screenshots ![image](https://github.com/go-gitea/gitea/assets/80308335/208f95cd-42e4-4ed7-9a1f-cd2050a645d4) ![image](https://github.com/go-gitea/gitea/assets/80308335/746428e0-40bb-45b3-b992-85602feb371d) Part of https://github.com/go-gitea/gitea/issues/25237 --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix tooltip of commit select button (#26472)silverwind2023-08-141-1/+1
| | | | | Previously, the tooltip for this button was only shown after opening and closing it once because it was only set after the server response, now it shows before opening it.
* fix grab cursor on default column (#26476)Denys Konovalov2023-08-141-2/+2
| | | | | | | | | | | | Fix https://github.com/go-gitea/gitea/pull/26448#issuecomment-1676194200 I accidentally set grab cursor for project columns instead of issue cards, which actually turned out not to be a problem - with proper check for the default column, which can't be moved. --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Giteabot <teabot@gitea.io>
* Add ThreadID parameter for Telegram webhooks (#25996)Earl Warren2023-08-131-0/+4
| | | | | | Telegram has recently implemented threads (channels) for group chats. Co-authored-by: neveraskedtoexist <matikot415@gmail.com>
* Use correct pull request commit link instead of a generic commit link (#26434)Lunny Xiao2023-08-131-0/+4
| | | | | | | | | Replace #26197 Since #25528 merged, the links of pull request commits should be redirect to pull file changes UI but not the generic one. --------- Co-authored-by: Giteabot <teabot@gitea.io>
* Refactor project templates (#26448)Denys Konovalov2023-08-126-557/+247
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR refactors a bunch of projects-related code, mostly the templates. The following things were done: - rename boards to columns in frontend code - use the new `ctx.Locale.Tr` method - cleanup template, remove useless newlines, classes, comments - merge org-/user and repo level project template together - move "new column" button into project toolbar - move issue card (shared by projects and pinned issues) to shared template, remove useless duplicated styles - add search function to projects (to make the layout more similar to milestones list where it is inherited from :laughing:) - maybe more changes I forgot I've done :laughing: Closes #24893 After: ![Bildschirmfoto vom 2023-08-10 23-02-00](https://github.com/go-gitea/gitea/assets/47871822/cab61456-1d23-4373-8163-e567f1b3b5f9) ![Bildschirmfoto vom 2023-08-10 23-02-26](https://github.com/go-gitea/gitea/assets/47871822/94b55d60-5572-48eb-8111-538a52d8bcc6) ![Bildschirmfoto vom 2023-08-10 23-02-46](https://github.com/go-gitea/gitea/assets/47871822/a0358f4b-4e05-4194-a7bc-6e0ecba5a9b6) --------- Co-authored-by: silverwind <me@silverwind.io>
* remove unnecessary explore org template (#26459)Denys Konovalov2023-08-111-1/+0
|
* Fix URL of padlock icon in profile (#26446)Panagiotis "Ivory" Vasilopoulos2023-08-111-1/+1
|
* Count only visible repos on profile (#25928)JakobDev2023-08-112-4/+4
| | | Fixes #25914
* Fix incorrect redirection in new issue using references (#26440)CaiCandong2023-08-101-1/+1
| | | | | | | | | | | | | | | | fix #26427 related https://github.com/go-gitea/gitea/pull/25258 --- Before: ![gitea](https://github.com/go-gitea/gitea/assets/50507092/ed8d3a17-1f63-42f2-a698-3b684e70dc91) --- After: ![After](https://github.com/go-gitea/gitea/assets/50507092/b8e1338f-c520-4abc-b0df-b812c021ac7e)
* Use template context function for avatar rendering (#26385)wxiaoguang2023-08-1050-134/+134
| | | | Introduce `AvatarUtils`, no need to pass `$.Context` to every sub-template, and simplify the template helper functions.
* Pre-register OAuth2 applications for git credential helpers (#26291)Denys Konovalov2023-08-091-10/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | This PR is an extended implementation of #25189 and builds upon the proposal by @hickford in #25653, utilizing some ideas proposed internally by @wxiaoguang. Mainly, this PR consists of a mechanism to pre-register OAuth2 applications on startup, which can be enabled or disabled by modifying the `[oauth2].DEFAULT_APPLICATIONS` parameter in app.ini. The OAuth2 applications registered this way are being marked as "locked" and neither be deleted nor edited over UI to prevent confusing/unexpected behavior. Instead, they're being removed if no longer enabled in config. ![grafik](https://github.com/go-gitea/gitea/assets/47871822/81a78b1c-4b68-40a7-9e99-c272ebb8f62e) The implemented mechanism can also be used to pre-register other OAuth2 applications in the future, if wanted. Co-authored-by: hickford <mirth.hickford@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> --------- Co-authored-by: M Hickford <mirth.hickford@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Use flex classes in package settings (#26314)KN4CK3R2023-08-082-31/+39
| | | | | | | | Regression of #25790 Fixes #26310 --------- Co-authored-by: Giteabot <teabot@gitea.io>
* Improve multiple strings in en-US locale (#26213)Panagiotis "Ivory" Vasilopoulos2023-08-081-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | I kept sending pull requests that consisted of one-line changes. It's time to settle this once and for all. (Maybe.) - Explain Gitea behavior and the consequences of each setting better, so that the user does not have to consult the docs. - Do not use different spellings of identical terms interchangeably, e.g. `e-mail` and `email`. - Use more conventional terms to describe the same things, e.g. `Confirm Password` instead of `Re-Type Password`. - Introduces additional clarification for Mirror Settings - Small adjustments in test - This is a cry for help. - Grammar and spelling consistencies for en-US locale (e.g. cancelled -> canceled) - Introduce tooltip improvements. --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Refactor "editorconfig" (#26391)wxiaoguang2023-08-081-1/+1
| | | | | | | | | | There are 2 kinds of ".Editorconfig" in code, one is `JSON string` for the web edtior, another is `*editorconfig.Editorconfig` for the file rendering (used by `TabSizeClass`) This PR distinguish them with different names. And by the way, change the default tab size from 8 to 4, I think few people would like to use 8-size tabs nowadays.
* fix generated source URL on rendered files (#26364)Earl Warren2023-08-081-2/+2
| | | | | | | | | | | | | | | - The permalink and 'Reference in New issue' URL of an renderable file (those where you can see the source and a rendered version of it, such as markdown) doesn't contain `?display=source`. This leads the issue that the URL doesn't have any effect, as by default the rendered version is shown and thus not the source. - Add `?display=source` to the permalink URL and to 'Reference in New Issue' if it's renderable file. - Add integration testing. Refs: https://codeberg.org/forgejo/forgejo/pulls/1088 Co-authored-by: Gusted <postmaster@gusted.xyz> Co-authored-by: Giteabot <teabot@gitea.io>