Skip to content

Commit

Permalink
Fixing glitches.
Browse files Browse the repository at this point in the history
  • Loading branch information
michael committed Mar 16, 2012
1 parent ab444db commit 3b75564
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
1 change: 1 addition & 0 deletions _includes/templates/post._
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
<div class='content-preview hidden'>
<h1><%= metadata.title %></h1>
<p class="subtitle"><%= metadata.subtitle %></p>
<div class="post-content"></div>
</div>
</div>
</div>
9 changes: 4 additions & 5 deletions _includes/views/post.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ views.Post = Backbone.View.extend({
'change input': '_makeDirty'
},

_makeDirty: function() {
_makeDirty: function(e) {
this.$('.button.publish').removeClass('hidden');
},

Expand All @@ -25,7 +25,7 @@ views.Post = Backbone.View.extend({
return false;
},

_unpublish: function() {
_unpublish: function(e) {
e.preventDefault();
this.updatePost(true, "Unpublish "+ this.model.file);
},
Expand Down Expand Up @@ -104,9 +104,8 @@ views.Post = Backbone.View.extend({

preview: function() {
// Show preview and hide code
this.$('.content-preview')
.show()
.html(this.converter.makeHtml(this.editor.getValue()));
this.$('.content-preview').show();
this.$('.post-content').html(this.converter.makeHtml(this.editor.getValue()));

this.$('.content').hide();
},
Expand Down

0 comments on commit 3b75564

Please sign in to comment.