Hide <p> for empty text from markdown.

This commit is contained in:
Jimmy Zelinskie 2015-01-07 17:42:52 -05:00
parent 8464b54ad9
commit 023f40c06f
2 changed files with 5 additions and 2 deletions

View file

@ -120,7 +120,10 @@ function createOrganizationTeam(ApiService, orgname, teamname, callback) {
}
function getMarkedDown(string) {
return Markdown.getSanitizingConverter().makeHtml(string || '');
// This automatically puts text into paragraph tags, which may or may not effect
// the style of a page. For consistency, we make sure empty text is paragraph tags.
var html = Markdown.getSanitizingConverter().makeHtml(string || '');
return html == '' ? '<p style="visibility:hidden">easter egg</p>' : html;
}

View file

@ -1,5 +1,5 @@
<div class="row">
<div class="col-lg-3 col-lg-push-9 col-md-3 col-md-push-9 col-sm-4 col-sm-push-8 col-xs-12">
<div class="repo-list-sidebar col-lg-3 col-lg-push-9 col-md-3 col-md-push-9 col-sm-4 col-sm-push-8 col-xs-12">
<div class="button-bar-right">
<a href="/new/">
<button class="btn btn-success">