Skip to content

Commit 0f0db6a

Browse files
authored
Remove unnecessary inline style for tab-size (#31224)
Move the rule to the parent node. `tab-size` is inherited so will work just as before.
1 parent cb27c43 commit 0f0db6a

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

routers/web/repo/issue_content_history.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ func GetContentHistoryDetail(ctx *context.Context) {
156156

157157
// use chroma to render the diff html
158158
diffHTMLBuf := bytes.Buffer{}
159-
diffHTMLBuf.WriteString("<pre class='chroma' style='tab-size: 4'>")
159+
diffHTMLBuf.WriteString("<pre class='chroma'>")
160160
for _, it := range diff {
161161
if it.Type == diffmatchpatch.DiffInsert {
162162
diffHTMLBuf.WriteString("<span class='gi'>")

web_src/css/repo.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2322,6 +2322,7 @@ tbody.commit-list {
23222322
min-height: 12em;
23232323
max-height: calc(100vh - 10.5rem);
23242324
overflow-y: auto;
2325+
tab-size: 4;
23252326
}
23262327

23272328
.comment-diff-data pre {

0 commit comments

Comments
 (0)