-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Make first section on home page full width #23854
Conversation
🤖 🎺 |
@@ -1,6 +1,6 @@ | |||
{{template "base/head" .}} | |||
<div role="main" aria-label="{{if .IsSigned}}{{.locale.Tr "dashboard"}}{{else}}{{.locale.Tr "home"}}{{end}}" class="page-content home"> | |||
<div class="ui stackable middle very relaxed page grid"> | |||
<div class="ui middle very relaxed page gt-mb-5"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not a grid
anymore, does the code sixteen wide column
below make sense? Or should they be cleaned up?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, I think those classes are dead now. But still, I left them in because this seems like a common target for customization, and I don't want to unnecessarily break those.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you have removed the grid
on its parent, keeping the dead code doesn't help about avoiding "breaking", instead it might really cause breaks if the customization depends on the grid
.
And, I worry about that the dead code might cause other style conflicts in the future or unnecessary technical debt / copy-paste bug in the future.
So I guess we should remove dead code as soon as possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we could also just add gt-px-0
to the classes and keep the old ones. Same effect and even more compatible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TBH I do not think so ....
If a developer reads code:
<div class="ui ....">
<div class="six wide column">
</div>
</div>
They will think about: OK , the inner div is designed to take 6/12 or 6/24 of the screen.
But the truth is the "six wide column"
is a no-op now. It really surprises developers, I do not like such surprise.
There are already a lot of surprises in Gitea's codebase. To improve maintainability and readability, let's try to avoid surprises?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe you could file a new PR with your envisioned changes. I don't quite understand what is requested anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No problem. Improve home page template #23856
Major changes:
- The old
<div class="ui"><div class="six wide column ..."> </div></div>
doesn't have affect any more- So clean them, and remove other unnecessary elements/styles.
- Add padding for narrow view.
Follow #23854 Major changes: 1. The old `<div class="ui"><div class="six wide column ..."> </div></div>` doesn't have affect any more * So clean them, and remove other unnecessary elements/styles. 2. Add padding for narrow view. Before ![image](https://user-images.githubusercontent.com/2114189/229262177-e8cf6c9b-b17b-482c-83fe-a84579e01e8e.png) After: ![image](https://user-images.githubusercontent.com/2114189/229262166-d46134b0-2117-4d5c-a469-a2115cbd4b6c.png)
* upstream/main: [skip ci] Updated translations via Crowdin Update JS deps (go-gitea#23853) Added close/open button to details page of milestone (go-gitea#23877) Check `IsActionsToken` for LFS authentication (go-gitea#23841) Prefill input values in oauth settings as intended (go-gitea#23829) Display image size for multiarch container images (go-gitea#23821) Use clippie module to copy to clipboard (go-gitea#23801) Remove assertion debug code for show/hide refactoring (go-gitea#23576) [skip ci] Updated translations via Crowdin Remove jQuery ready usage (go-gitea#23858) Fix JS error when changing PR's target branch (go-gitea#23862) Improve action log display with control chars (go-gitea#23820) Fix review conversation reply (go-gitea#23846) Improve home page template, fix Sort dropdown menu flash (go-gitea#23856) Make first section on home page full width (go-gitea#23854) [skip ci] Updated translations via Crowdin Fix incorrect CORS failure detection logic (go-gitea#23844)
Before:
After: