Skip to content

Commit

Permalink
fix EasyMDE statusbar margin
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang committed Sep 2, 2022
1 parent 1f3943c commit 233337d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion templates/repo/issue/comment_tab.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{{end}}
{{end}}
{{if .IsAttachmentEnabled}}
<div class="field not-under-easymde">
<div class="field">
{{template "repo/upload" .}}
</div>
{{end}}
Expand Down
4 changes: 4 additions & 0 deletions web_src/less/codemirror/base.less
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
.ui .field:not(:last-child) .EasyMDEContainer .editor-statusbar {
margin-bottom: -1em; // when there is a statusbar, the "margin-bottom: 1em" of the "field" is not needed, because the statusbar is likely a blank line
}

.EasyMDEContainer .CodeMirror {
color: var(--color-input-text);
background-color: var(--color-input-background);
Expand Down
7 changes: 0 additions & 7 deletions web_src/less/features/dropzone.less
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,12 @@
padding: 0;
border-radius: 4px;
min-height: 0;
margin-top: -1em; // we have another `field` above, it's usually an EasyMDE editor with "status bar", so we do not need the space above.
.dz-message {
margin: 10px 0;
}
}
}

.ui .field.not-under-easymde {
.dropzone {
margin-top: 0; // the `field` above isn't an EasyMDE editor
}
}

.dropzone .dz-button {
color: var(--color-text-light) !important;
}
Expand Down

0 comments on commit 233337d

Please sign in to comment.