Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix inconsistent user profile layout across tabs #25625

Merged
merged 48 commits into from
Jul 6, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
519293d
Adjusting profile layout for package, project and code page.
puni9869 Jul 2, 2023
aaa5f71
Templates and go file formatting
puni9869 Jul 2, 2023
2fedaf3
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 2, 2023
eae7940
fix merge
wxiaoguang Jul 2, 2023
b0bd1ea
fix merge
wxiaoguang Jul 2, 2023
8eb033e
Fixing page-content style
puni9869 Jul 2, 2023
907a710
Removing page-content to gt-mt-4
puni9869 Jul 2, 2023
cbd0ca8
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 3, 2023
9d6c8cf
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 3, 2023
bef3289
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 3, 2023
c3f23d1
Fix :: Suggestions Removing page-content
puni9869 Jul 3, 2023
110081a
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 3, 2023
110e50b
Adding style in package version list
puni9869 Jul 3, 2023
8b9a080
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 3, 2023
656191a
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 3, 2023
f3ee922
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 4, 2023
617544c
fix style in package/repo
puni9869 Jul 4, 2023
aeb49f9
Adding style in packages in repo package
puni9869 Jul 4, 2023
0e9e8be
Formatting templates
puni9869 Jul 4, 2023
52cfeec
Adding style
puni9869 Jul 4, 2023
5b18ff6
Formatting templates
puni9869 Jul 4, 2023
55121d6
Adding context to the profile version list package page
puni9869 Jul 4, 2023
7ed8299
Fixing linter issues in templates
puni9869 Jul 4, 2023
2cf7ff8
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 4, 2023
1113af0
Resolving conflicts
puni9869 Jul 4, 2023
1165409
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 4, 2023
e0289ad
Fixing kanban board header
puni9869 Jul 5, 2023
6623348
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 5, 2023
44c2edd
Fixing in edit project org projects
puni9869 Jul 5, 2023
ee1413d
Adding org header avatar
puni9869 Jul 5, 2023
eaa7ee8
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 5, 2023
6e3c782
fix merge
wxiaoguang Jul 5, 2023
ab9b005
fix container layout
wxiaoguang Jul 5, 2023
1571c37
Merge branch 'main' into punit/ISSUE-24871-user-profile-orig
wxiaoguang Jul 5, 2023
7ec582b
revert unnecessary new lines
wxiaoguang Jul 5, 2023
3c5652d
rewrite
wxiaoguang Jul 5, 2023
fd85288
rewrite
wxiaoguang Jul 5, 2023
b29bbfa
rewrite
wxiaoguang Jul 5, 2023
6c93f71
rewrite
wxiaoguang Jul 5, 2023
f355415
fix
wxiaoguang Jul 5, 2023
da7bf21
remove unused code
wxiaoguang Jul 5, 2023
9046994
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 5, 2023
deceaf1
Merge branch 'main' into punit/ISSUE-24871-user-profile
puni9869 Jul 6, 2023
ab0ad22
Merge branch 'main' into punit/ISSUE-24871-user-profile
GiteaBot Jul 6, 2023
0162ec5
Merge branch 'main' into punit/ISSUE-24871-user-profile
GiteaBot Jul 6, 2023
36660f6
Merge branch 'main' into punit/ISSUE-24871-user-profile
GiteaBot Jul 6, 2023
8e6f3c2
Merge branch 'main' into punit/ISSUE-24871-user-profile
GiteaBot Jul 6, 2023
b670669
dedent templates/user/overview/header.tmpl
silverwind Jul 6, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Templates and go file formatting
  • Loading branch information
puni9869 committed Jul 2, 2023
commit aaa5f71f1693b56c78e61b9d22145b15c93ab2af
2 changes: 1 addition & 1 deletion routers/web/user/code.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
package user

import (
shared_user "code.gitea.io/gitea/routers/web/shared/user"
"net/http"

repo_model "code.gitea.io/gitea/models/repo"
"code.gitea.io/gitea/modules/base"
"code.gitea.io/gitea/modules/context"
code_indexer "code.gitea.io/gitea/modules/indexer/code"
"code.gitea.io/gitea/modules/setting"
shared_user "code.gitea.io/gitea/routers/web/shared/user"
)

const (
Expand Down
4 changes: 1 addition & 3 deletions routers/web/user/package.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,6 @@ const (
// ListPackages displays a list of all packages of the context user
func ListPackages(ctx *context.Context) {
shared_user.PrepareContextForProfileBigAvatar(ctx)
if ctx.ContextUser.IsOrganization() {
ctx.Data["pageStyleClasses"] = "container"
}
page := ctx.FormInt("page")
if page <= 1 {
page = 1
Expand Down Expand Up @@ -105,6 +102,7 @@ func ListPackages(ctx *context.Context) {

// TODO: context/org -> HandleOrgAssignment() can not be used
if ctx.ContextUser.IsOrganization() {
ctx.Data["pageStyleClasses"] = "container"
org := org_model.OrgFromUser(ctx.ContextUser)
ctx.Data["Org"] = org
ctx.Data["OrgLink"] = ctx.ContextUser.OrganisationLink()
Expand Down
10 changes: 5 additions & 5 deletions templates/org/projects/list.tmpl
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{{template "base/head" .}}
{{if .ContextUser.IsOrganization}}
<div role="main" aria-label="{{.Title}}" class="page-content repository packages">
{{template "shared/user/org_profile_avatar" .}}
{{template "user/overview/header" .}}
{{template "projects/list" .}}
</div>
<div role="main" aria-label="{{.Title}}" class="page-content repository packages">
{{template "shared/user/org_profile_avatar" .}}
{{template "user/overview/header" .}}
{{template "projects/list" .}}
</div>
{{else}}
<div role="main" aria-label="{{.Title}}" class="page-content user profile">
<div class="ui container">
Expand Down
10 changes: 5 additions & 5 deletions templates/user/overview/package_versions.tmpl
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{{template "base/head" .}}
{{if .ContextUser.IsOrganization}}
<div role="main" aria-label="{{.Title}}" class="page-content repository packages">
{{template "shared/user/org_profile_avatar" .}}
{{template "user/overview/header" .}}
{{template "package/shared/versionlist" .}}
</div>
<div role="main" aria-label="{{.Title}}" class="page-content repository packages">
{{template "shared/user/org_profile_avatar" .}}
{{template "user/overview/header" .}}
{{template "package/shared/versionlist" .}}
</div>
{{else}}
<div role="main" aria-label="{{.Title}}" class="page-content user profile packages">
<div class="ui container">
Expand Down
Loading