mirror of
				https://github.com/go-gitea/gitea
				synced 2025-10-31 03:18:24 +00:00 
			
		
		
		
	Clean up polluted styles and remove dead CSS code (#24497)
Follow #24393 The funny history: * At the beginning, `.ui.message` was polluted by `text-align: center` * Then people do `<div class="ui ... message text left">` * But `.ui.left` is polluted by `float: left` * Then people do `#xxx .ui.message { width: 100% !important;}` The code just becomes more and more hacky. After removing the pollution, everything becomes clear and straight. And, this PR also does: 1. Remove the `package.css`, its styles could be provided by `top aligned` 2. Remove `#avatar-arrow`, dead code Screenshot:   Co-authored-by: Giteabot <teabot@gitea.io>
This commit is contained in:
		| @@ -1556,7 +1556,7 @@ img.ui.avatar, | ||||
|   vertical-align: middle; | ||||
| } | ||||
|  | ||||
| .ui .message { | ||||
| .ui .message.flash-message { | ||||
|   text-align: center; | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -41,6 +41,5 @@ | ||||
| @import "./admin.css"; | ||||
| @import "./explore.css"; | ||||
| @import "./review.css"; | ||||
| @import "./package.css"; | ||||
| @import "./runner.css"; | ||||
| @import "./helpers.css"; | ||||
|   | ||||
| @@ -1,7 +0,0 @@ | ||||
| .container-labels td:nth-child(1) { | ||||
|   vertical-align: top; | ||||
| } | ||||
|  | ||||
| .container-labels td:nth-child(2) { | ||||
|   overflow-wrap: anywhere; | ||||
| } | ||||
| @@ -2600,39 +2600,6 @@ | ||||
|   height: 15px; | ||||
| } | ||||
|  | ||||
| #avatar-arrow::before, | ||||
| #avatar-arrow::after { | ||||
|   right: 100%; | ||||
|   top: 20px; | ||||
|   border: solid transparent; | ||||
|   content: " "; | ||||
|   height: 0; | ||||
|   width: 0; | ||||
|   position: absolute; | ||||
|   pointer-events: none; | ||||
| } | ||||
|  | ||||
| #avatar-arrow::before { | ||||
|   border-right-color: var(--color-secondary); | ||||
|   border-width: 9px; | ||||
|   margin-top: -9px; | ||||
| } | ||||
|  | ||||
| #avatar-arrow::after { | ||||
|   border-right-color: var(--color-box-header); | ||||
|   border-width: 8px; | ||||
|   margin-top: -8px; | ||||
| } | ||||
|  | ||||
| #transfer-repo-modal .ui.message, | ||||
| #delete-repo-modal .ui.message, | ||||
| #delete-wiki-modal .ui.message, | ||||
| #convert-fork-repo-modal .ui.message, | ||||
| #convert-mirror-repo-modal .ui.message, | ||||
| #fork-repo-modal .ui.message { | ||||
|   width: 100% !important; | ||||
| } | ||||
|  | ||||
| .tab-size-1 { | ||||
|   tab-size: 1 !important; | ||||
|   -moz-tab-size: 1 !important; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user