04d489dbdd
Make branches list page operations remember current page ( #23420 ) ( #23459 )
...
Backport #23420 by @wxiaoguang
Close #23411
Always pass "page" query parameter to backend, and make backend respect
it.
The `ctx.FormInt("limit")` is never used, so removed.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: Jason Song <i@wolfogre.com >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-03-15 13:13:27 +01:00
491ee43082
Fix due date being wrong on issue list ( #23475 ) ( #23479 )
...
Backport #23475
Exactly like #22302 but in the issue list page
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-03-15 09:41:09 +08:00
9107a87ff6
Redirect to the commit page after applying patch ( #23056 ) & Fix commit name in Apply Patch page ( #23086 ) ( #23131 )
...
Backport #23056
Backport #23086
Fixes https://github.com/go-gitea/gitea/issues/22621
Fixes
https://github.com/go-gitea/gitea/issues/22621#issuecomment-1439309200
Co-authored-by: yp05327 <576951401@qq.com >
2023-03-15 08:06:02 +08:00
sillyguodong and GitHub
3dc2724d36
Fix cannot reopen after pushing commits to a closed PR ( #23189 ) ( #23322 )
...
Backport: #23189
Close : #22784
1. On GH, we can reopen a PR which was closed before after pushing
commits. After reopening PR, we can see the commits that were pushed
after closing PR in the time line. So the case of
[issue](https://github.com/go-gitea/gitea/issues/22784 ) is a bug which
needs to be fixed.
2. After closing a PR and pushing commits, `headBranchSha` is not equal
to `sha`(which is the last commit ID string of reference). If the
judgement exists, the button of reopen will not display. So, skip the
judgement if the status of PR is closed.

3. Even if PR is already close, we should still insert comment record
into DB when we push commits.
So we should still call function `CreatePushPullComment()`.
https://github.com/go-gitea/gitea/blob/067b0c2664d127c552ccdfd264257caca4907a77/services/pull/pull.go#L260-L282
So, I add a switch(`includeClosed`) to the
`GetUnmergedPullRequestsByHeadInfo` func to control whether the status
of PR must be open. In this case, by setting `includeClosed` to `true`,
we can query the closed PR.

4. In the loop of comments, I use the`latestCloseCommentID` variable to
record the last occurrence of the close comment.
In the go template, if the status of PR is closed, the comments whose
type is `CommentTypePullRequestPush(29)` after `latestCloseCommentID`
won't be rendered.

e.g.
1). The initial status of the PR is opened.

2). Then I click the button of `Close`. PR is closed now.

3). I try to push a commit to this PR, even though its current status is
closed.

But in comments list, this commit do not display.This is as expected :)

4). Click the `Reopen` button, the commit which is pushed after closing
PR display now.

2023-03-06 11:38:45 -06:00
HesterG and GitHub
5a60e023af
Add wrapper to author to avoid long name ui problem ( #23030 ) ( #23172 )
...
Backport #23030
This PR is a possible solution for issue #22866 . Main change is to add a
`author-wrapper` class around author name, like the wrapper added to
message. The `max-width` is set to 200px on PC, and 100px on mobile
device for now. Which will work like below:
<img width="1183" alt="2023-02-21 11 57 53"
src="https://user-images.githubusercontent.com/17645053/220244146-3d47c512-33b6-4ed8-938e-de0a8bc26ffb.png ">
<img width="417" alt="2023-02-21 11 58 43"
src="https://user-images.githubusercontent.com/17645053/220244154-1ea0476b-9d1c-473a-9917-d3216860f9a9.png ">
And `title` is added to the wrapper like it did in message wrapper. So
the full author name will show on hover.
2023-02-27 22:47:04 +08:00
bbfd34575a
Display attachments of review comment when comment content is blank ( #23035 ) ( #23046 )
...
Backport #23035
Co-authored-by: sillyguodong <33891828+sillyguodong@users.noreply.github.com >
2023-02-21 11:10:29 -06:00
760cf419ba
Use beforeCommit instead of baseCommit ( #22949 ) ( #22996 )
...
Backport #22949
Fixes https://github.com/go-gitea/gitea/issues/22946
Probably related to https://github.com/go-gitea/gitea/issues/19530
Co-authored-by: Jonathan Tran <jonnytran@gmail.com >
2023-02-21 10:51:02 -05:00
7b3ffe5745
Fix the Manually Merged form ( #23015 ) ( #23017 )
...
Backport #23015
---------
Co-authored-by: Jason Song <i@wolfogre.com >
2023-02-21 18:04:29 +08:00
660a83bd2e
Hide 2FA status from other members in organization members list ( #22999 ) ( #23023 )
...
Backport #22999
This is rather private information that should not be given to all
members in the same organization. Only show it to organization owners.
Co-authored-by: Brecht Van Lommel <brecht@blender.org >
2023-02-20 19:14:39 -05:00
98b7714c3b
Fix 404 error viewing the LFS file ( #22945 ) ( #22948 )
...
Backport #22945
Fix #22734 .
According to
[`view_file.tmpl`](https://github.com/go-gitea/gitea/blob/main/templates/repo/view_file.tmpl#L82 ),
`lfs_file.tmpl` should use `AssetUrlPrefix` instead of `AppSubUrl`.
Co-authored-by: Zettat123 <zettat123@gmail.com >
Co-authored-by: Jason Song <i@wolfogre.com >
2023-02-17 15:22:05 +08:00
Yarden Shoham and GitHub
9f5e44bf50
Use --index-url in PyPi description ( #22620 ) ( #22636 )
2023-01-28 12:57:12 +08:00
f1c826ed29
Mute all links in issue timeline ( #22534 )
...
Backport of https://github.com/go-gitea/gitea/pull/22533 .
https://github.com/go-gitea/gitea/pull/21799 introduced a regression
where some links in the issue timeline were not muted any more. Fix it
by replacing all `class="text grey"` with `class="text grey
muted-links"` in the file.
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-01-20 00:18:58 -05:00
a9400ba7a3
Fix container blob mount ( #22226 ) ( #22476 )
...
Backport #22226
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-01-17 14:50:45 +08:00
f430050d24
Fix leaving organization bug on user settings -> orgs ( #21983 ) ( #22438 )
...
Backport #21983
Fix #21772
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: 花墨 <shanee@live.com >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-01-16 01:29:27 +02:00
265d438a6e
fix: PR status layout on mobile ( #21547 ) ( #22441 )
...
Backport #21547
This PR fixes the layout of PR status layouts on mobile. For longer
status context names or on very small screens the text would overflow
and push the "Details" and "Required" badges out of the container.
Before:

After:

Co-authored-by: kolaente <k@knt.li >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-01-14 16:56:44 +08:00
f3034b1fd9
Remove duplicate "Actions" label in mobile view ( #21974 ) ( #22439 )
...
Backport #21974
Closes #21973 .
The "Actions" button on the commit view page is labelled twice in mobile
view. No other buttons on the page have a `mobile-only` extra label, so
this PR removes it.
Before:

After:

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: Mark Ormesher <me@markormesher.co.uk >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: John Olheiser <john.olheiser@gmail.com >
2023-01-13 23:23:39 +00:00
zeripath and GitHub
421d87933b
Restore function to "Show more" buttons ( #22399 ) ( #22426 )
...
Backport #22399
There was a serious regression in #21012 which broke the Show More
button on the diff page, and the show more button was also broken on the
file tree too.
This PR fixes this by resetting the pageData.diffFiles as the vue
watched value and reattachs a function to the show more button outside
of the file tree view.
Fix #22380
Signed-off-by: Andrew Thornton <art27@cantab.net >
2023-01-13 17:29:10 +08:00
Yarden Shoham and GitHub
885082f7a7
Don't display stop watch top bar icon when disabled and hidden when click other place ( #22374 ) ( #22387 )
...
Backport #22374
Fix #22286
When timetracking is disabled, the stop watch top bar icon should be
hidden. When the stop watch recording popup, it should be allowed to
hide with some operation. Now click any place on this page will hide the
popup window.
2023-01-10 09:21:29 +00:00
Yarden Shoham and GitHub
72d1f9e63e
Fix due date rendering the wrong date in issue ( #22302 ) ( #22306 )
...
Backport #22302
Previously, the last minute of the chosen date caused bad timezone
rendering.
For example, I chose January 4th, 2023.
### Before
```html
<time data-format="date" datetime="Wed, 04 Jan 2023 23:59:59 +0000">January 5, 2023</time>
```
### After
```html
<time data-format="date" datetime="2023-01-04">January 4, 2023</time>
```
---
Closes #21999
Signed-off-by: Yarden Shoham <hrsi88@gmail.com >
2023-01-02 20:42:39 +08:00
Chongyi Zheng and GitHub
443fd27a90
Add sync_on_commit option for push mirrors api ( #22271 ) ( #22292 )
...
Backport of #22271
2022-12-31 19:46:14 +08:00
Gusted and GitHub
75f128ebf8
Fix key signature error page ( #22229 ) ( #22230 )
...
- Backport of #22229
- When the GPG key contains an error, such as an invalid signature or an
email address that does not match the user.A page will be shown that
says you must provide a signature for the token.
- This page had two errors: one had the wrong translation key and the
other tried to use an undefined variable
[`.PaddedKeyID`](https://github.com/go-gitea/gitea/blob/e81ccc406bf723a5a58d685e7782f281736affd4/models/asymkey/gpg_key.go#L65-L72 ),
which is a function implemented on the `GPGKey` struct, given that we
don't have that, we use
[`KeyID`](https://github.com/go-gitea/gitea/blob/e81ccc406bf723a5a58d685e7782f281736affd4/routers/web/user/setting/keys.go#L102 )
which is [the fingerprint of the
publickey](https://pkg.go.dev/golang.org/x/crypto/openpgp/packet#PublicKey.KeyIdString )
and is a valid way for opengpg to refer to a key.
2022-12-30 12:53:23 +08:00
Lauris BH and GitHub
2a5e7f8f92
Fix container layer display overflow ( #22208 ) ( #22211 )
...
Backport #22208
2022-12-22 14:26:48 +01:00
72524adf3f
Ensure that plain files are rendered correctly even when containing ambiguous characters ( #22017 ) ( #22160 )
...
Backport #22017
As recognised in #21841 the rendering of plain text files is somewhat
incorrect when there are ambiguous characters as the html code is double
escaped. In fact there are several more problems here.
We have a residual isRenderedHTML which is actually simply escaping the
file - not rendering it. This is badly named and gives the wrong
impression.
There is also unusual behaviour whether the file is called a Readme or
not and there is no way to get to the source code if the file is called
README.
In reality what should happen is different depending on whether the file
is being rendered a README at the bottom of the directory view or not.
1. If it is rendered as a README on a directory - it should simply be
escaped and rendered as `<pre>` text.
2. If it is rendered as a file then it should be rendered as source
code.
This PR therefore does:
1. Rename IsRenderedHTML to IsPlainText
2. Readme files rendered at the bottom of the directory are rendered
without line numbers
3. Otherwise plain text files are rendered as source code.
Replace #21841
Signed-off-by: Andrew Thornton <art27@cantab.net >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-12-19 23:51:21 +08:00
silverwind and GitHub
4297aced93
Fix margin and alignment in dashboard repolist ( #22120 ) ( #22122 )
...
Backport #22120 to 1.18. Seems this has recently regressed, previously,
there was a significant whitespace between icon and text, but it seems
to be gone, so I added the margin.
2022-12-16 20:57:22 +01:00
aceArt-GmbH and GitHub
1409b348c6
Fix sorting admin user list by last login ( #22081 ) ( #22107 )
2022-12-13 16:37:33 -06:00
zeripath and GitHub
757b49ec5e
Do not emit ambiguous character warning on rendered pages ( #22016 ) ( #22018 )
...
Backport #22016
The real sensitivity of ambiguous characters is in source code -
therefore warning about them in rendered pages causes too many warnings.
Therefore simply remove the warning on rendered pages.
The escape button will remain available and it is present on the view
source page.
Fix #20999
Signed-off-by: Andrew Thornton <art27@cantab.net >
2022-12-04 11:10:54 +00:00
9ba4ef93ff
Fix button in branch list, avoid unexpected page jump before restore branch actually done ( #21562 ) ( #21928 )
...
Backport #21562
Signed-off-by: Xinyu Zhou <i@sourcehut.net >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: Lauris BH <lauris@nix.lv >
2022-11-25 00:02:33 +08:00
Xinyu Zhou and GitHub
16772ffde3
Fix flex layout for repo list icons ( #21896 ) ( #21920 )
...
Backport #21896
#20241 Added a tooltip, which does not satisfy the flex layout, and the
icons are not aligned
Signed-off-by: Xinyu Zhou <i@sourcehut.net >
2022-11-24 00:44:07 -06:00
silverwind and GitHub
ef08998bf6
Color and Style enhancements ( #21784 , #21799 ) ( #21868 )
...
Backport #21784
Backport #21799
These PRs provide tweaks and simplification to the less/css selectors, simplifying text color selectors and tweak arc-green colors with a follow-up to adjust the timeline
See the original PRs for more details
2022-11-20 10:47:02 +00:00
Jason Song and GitHub
7a004ad7eb
Support comma-delimited string as labels in issue template ( #21831 ) ( #21873 )
...
Backport #21831 .
The [labels in issue YAML templates](https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms#top-level-syntax )
can be a string array or a comma-delimited string, so a single string
should be valid labels.
The old codes committed in #20987 ignore this, that's why the warning is
displayed:
<img width="618" alt="image" src="https://user-images.githubusercontent.com/9418365/202112642-93dc72d0-71c3-40a2-9720-30fc2d48c97c.png ">
Fixes #17877 .
2022-11-20 10:44:20 +00:00
KN4CK3R and GitHub
5c2089a01d
Change commits-table column width ( #21564 )
...
Fixes #21561
Before

After

2022-10-25 18:00:37 +01:00
29c00eb1ed
Improve code comment review on mobile ( #21461 )
...
- Fix placement of avatar image, this was not placed in the
`comment-header-left` and add CSS to cover the limiting of width+height
of avatar for code-review comment on "Files changed" page. This fixes
the big noticeable avatar issue.
- Apply `margin-bottom` to the "next" button, so it's consistent with
the "previous" button.
- Make sure the "next"/"previous" start at `flex-start` on mobile and
not off-screen at `flex-end`. As well force them to have `flex: 1` so
they won't overflow on x-asis. This also requires the `width: 100%` for
the `.ui.buttons` div.
- Resolves #20074
### Before
<details><img width="512"
src="https://user-images.githubusercontent.com/25481501/195952930-09560cad-419f-43a3-a8a4-a4166c117994.jpg "></details>
### After
<details><img width="512"
src="https://user-images.githubusercontent.com/25481501/197340081-0365dfa8-4344-46b4-8702-a40c778c073f.jpg "></details>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: silverwind <me@silverwind.io >
2022-10-25 19:11:49 +08:00
0218fa7cf1
Added missing headers on user packages page ( #21172 )
...
User packages page had missing tabs.


Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: Lauris BH <lauris@nix.lv >
2022-10-24 20:01:05 +08:00
191a74d622
Record OAuth client type at registration ( #21316 )
...
The OAuth spec [defines two types of
client](https://datatracker.ietf.org/doc/html/rfc6749#section-2.1 ),
confidential and public. Previously Gitea assumed all clients to be
confidential.
> OAuth defines two client types, based on their ability to authenticate
securely with the authorization server (i.e., ability to
> maintain the confidentiality of their client credentials):
>
> confidential
> Clients capable of maintaining the confidentiality of their
credentials (e.g., client implemented on a secure server with
> restricted access to the client credentials), or capable of secure
client authentication using other means.
>
> **public
> Clients incapable of maintaining the confidentiality of their
credentials (e.g., clients executing on the device used by the resource
owner, such as an installed native application or a web browser-based
application), and incapable of secure client authentication via any
other means.**
>
> The client type designation is based on the authorization server's
definition of secure authentication and its acceptable exposure levels
of client credentials. The authorization server SHOULD NOT make
assumptions about the client type.
https://datatracker.ietf.org/doc/html/rfc8252#section-8.4
> Authorization servers MUST record the client type in the client
registration details in order to identify and process requests
accordingly.
Require PKCE for public clients:
https://datatracker.ietf.org/doc/html/rfc8252#section-8.1
> Authorization servers SHOULD reject authorization requests from native
apps that don't use PKCE by returning an error message
Fixes #21299
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-10-24 15:59:24 +08:00
silverwind and GitHub
bf2a72d126
Expand "Go to File" button again, fix 'Add File' margin ( #21543 )
...
With https://github.com/go-gitea/gitea/pull/21428 we gained some space
so we are again able to show the "Go to File" button as text instead of
icon-only (the old icon was not particularily fitting anyways).
Before:
<img width="328" alt="image"
src="https://user-images.githubusercontent.com/115237/197334423-07731d9d-bf26-4aeb-95fa-490d9d0bf2a2.png ">
After:
<img width="339" alt="Screen Shot 2022-10-22 at 12 28 01"
src="https://user-images.githubusercontent.com/115237/197334383-467c4107-09c9-4881-b75f-7f403eab7f3a.png ">
<img width="413" alt="Screen Shot 2022-10-22 at 12 28 16"
src="https://user-images.githubusercontent.com/115237/197334384-f7d1fdda-a011-4138-ad1e-b52fc987501f.png ">
2022-10-24 02:23:04 +01:00
KN4CK3R and GitHub
876ee8c3cd
Allow package version sorting ( #21453 )
2022-10-23 09:18:15 +08:00
rock2dust and GitHub
cd33979f5a
Added check for disabled Packages ( #21540 )
...
At the moment, If admin disable Packages, still show the Packages on the
admin dashboard
This patch added a check to hide the Packages entry
Signed-off-by: baronbunny <its@baronbunny.cn >
Signed-off-by: baronbunny <its@baronbunny.cn >
2022-10-22 11:24:09 +08:00
16cbd5b59c
Fix generating compare link ( #21519 )
...
Fix #6318
Co-authored-by: zeripath <art27@cantab.net >
2022-10-21 16:39:26 +08:00
Gusted and GitHub
6b712465a8
Revert increased width on pull pages ( #21470 )
...
- Revert a behavior from #21012 , which liberally added `fluid padded` to
non-split style pull pages, this caused it to take up the whole
screen(such in split-style pull pages) on pull pages where the diff was
shown.
- Resolves #21460
### Before


### After


2022-10-19 15:48:29 +01:00
c3b2e44392
Add team member invite by email ( #20307 )
...
Allows to add (not registered) team members by email.
related #5353
Invite by mail:

Pending invitations:

Email:

Join form:

Co-authored-by: Jack Hay <jjphay@gmail.com >
2022-10-19 14:40:28 +02:00
7d1aed83f4
Disable the 'Add File' button when not able to edit repo ( #21503 )
...
Previously, the button would render a dropdown with zero items when
`.CanEnableEditor` was false (for example on a mirror repo). Now it
disables the button instead which is better UX.
<img width="310" alt="image"
src="https://user-images.githubusercontent.com/115237/196546655-7262070d-dd8f-4fbe-ad5c-ecb443a9caef.png ">
<img width="292" alt="image"
src="https://user-images.githubusercontent.com/115237/196546694-51ef5792-16d4-463d-aae8-7ef22dba6bb4.png ">
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-10-19 16:08:33 +08:00
silverwind and GitHub
e27d52b276
Fix branch dropdown shifting on page load ( #21428 )
...
Removed the "tag/branch" prefix and did some misc tweaks like changing to `<button>` for a11y and adding a bit of margin besides repo path.
2022-10-19 13:39:55 +08:00
acdb92ad42
Localize all timestamps ( #21440 )
...
Following
* #21410
We are now able to localize all timestamps. Some examples:
`short-date` format, French, user profile page:

`date-time` format, Portuguese, mirror repository settings page:

Signed-off-by: Yarden Shoham <hrsi88@gmail.com >
Signed-off-by: Yarden Shoham <hrsi88@gmail.com >
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-10-17 12:08:21 +08:00
Lunny Xiao and GitHub
f860a6d2e4
Add system setting table with cache and also add cache supports for user setting ( #18058 )
2022-10-17 07:29:26 +08:00
b9cd6fb703
Add code highlighting in issue titles ( #21432 )
...
This changes the rendering logic of issue titles. If a substring in an
issue title is enclosed with a pair of backticks, it'll be rendered with
a monospace font (HTML `code` tag).
* Closes #20887
Signed-off-by: Yarden Shoham <hrsi88@gmail.com >
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: 6543 <6543@obermui.de >
2022-10-16 02:24:41 +08:00
9dc264a2ee
Diff file tree tweaks ( #21446 )
...
- Left-align the diff stat line again like previously.
- Default the file tree to collapsed view, which means the tree will
rendered initially collapsed and it may "pop in" via JS if enabled. I
think this is more desirable than having the empty space for the tree
"pop out" like it currently does.
- Mute the icon, removing color unless hovered.
- Increase icon size and vertically center it.
Before:
<img width="1271" alt="image"
src="https://user-images.githubusercontent.com/115237/195666451-55771595-0525-42b8-be1b-d03cc1cb2961.png ">
After:
<img width="1280" alt="image"
src="https://user-images.githubusercontent.com/115237/195666385-c91fd0de-6dcc-4d9c-89ff-7581828fcf14.png ">
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-10-14 17:43:25 +08:00
Yarden Shoham and GitHub
c4f7c96903
Run make fmt ( #21437 )
...
The only change is what `make fmt` did, I am merely a vessel for its
glorious function
Signed-off-by: Yarden Shoham <hrsi88@gmail.com >
2022-10-13 21:33:54 -04:00
wxiaoguang and GitHub
f40833d1f0
Remove useless appVer from JS window.config ( #21445 )
...
The only usage of `appVer` was in serviceworker.js, while indeed it
needs the asset version.
2022-10-14 01:16:27 +08:00
Neel and GitHub
c35531dd11
Fix #21406 : Hide repo information from file view/blame mode ( #21420 )
...
# Summary
The repo information such as description, stats and topics are getting
displayed in the top-bar when viewing a file. This has been fixed to
display the repo information only while navigating the repo and not
while viewing or blaming a file from the repo
## Before fix
Screenshot from the issue

## After the fix
- **Repo homepage**
The repo description, topics and summary will be displayed

- **When opening a file**
The repo description, topic and summary has been conditionally hidden
from the view
<img width="1311" alt="image"
src="https://user-images.githubusercontent.com/47709856/195278964-9479231c-62ad-4c0e-b438-2018f22289db.png ">
- **When running blame on a file**
> This was originally not part of the issue #21406 . However the fix
seems relevant for the blame view as well.
<img width="1312" alt="image"
src="https://user-images.githubusercontent.com/47709856/195279619-02010775-aec3-4c8d-a184-d2d838c797e8.png ">
- **From within a directory**
The repo description, topics and summary will not be displayed

Supporting integration tests have also been added.
2022-10-13 11:31:10 +03:00
6a6dc97b0f
Respect user's locale when rendering the date range in the repo activity page ( #21410 )
...
# Description
Previously, to make the date range understood by all, we used the format
"2006-01-02" for the dates as it's locale-generic.
This commit changes the rendering logic. Instead of rendering the date
on the server, we send a formatted computer-readable timestamp. The
client's javascript then renders it according to the user's locale.
This approach is reusable across the codebase, any `<time></time>` tag
with the data-format="date" attribute would get rendered according to
the user's chosen locale.
## Previous View

## New View
### English

### French

### Portuguese

### Italian

# References
* #21380
* #21387
* #21396
Inspiration:
I think either differentiating by class, or probably better by a custom
attribute such as `data-format` or similar, is the best course of
action.
_Originally posted by @delvh in
https://github.com/go-gitea/gitea/issues/21396#issuecomment-1274424788_
Resolves #21380
Signed-off-by: Yarden Shoham <hrsi88@gmail.com >
Co-authored-by: silverwind <me@silverwind.io >
2022-10-13 00:14:14 +03:00