lib/ecrire/app/helpers/admin/posts_helper.rb in ecrire-0.25.2 vs lib/ecrire/app/helpers/admin/posts_helper.rb in ecrire-0.26.0
- old
+ new
@@ -1,11 +1,11 @@
module Admin
module PostsHelper
include ::PostsHelper
- def post_edit_content(post)
- content_tag :div, id: 'PostBody', postid: @post.id,
+ def edit_content_tag(post)
+ content_tag :article, id: 'PostBody', postid: @post.id,
class: %w(content),
as: 'Editor.Content',
contenteditable: true,
href: admin_post_path(@post.id) do |div|
@@ -17,10 +17,10 @@
if Rails.application.secrets.s3.has_key?('namespace')
div['namespace'] = Rails.application.secrets.s3['namespace']
end
end
- h(post.content)
+ yield if block_given?
end
end
end
end