diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index 1425a12..48c1d24 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -20,7 +20,7 @@ = link_to t('sites.edit.btn', site: @site.title), edit_site_path(@site), class: 'btn' - if policy(@site).private? - = link_to t('sites.private'), '../private/' + @site.name, class: 'btn', target: '_blank' + = link_to t('sites.private'), '../private/' + @site.name, class: 'btn', target: '_blank', rel: 'noopener' = render 'sites/build', site: @site diff --git a/app/views/posts/show.haml b/app/views/posts/show.haml index 77b38d4..52069a0 100644 --- a/app/views/posts/show.haml +++ b/app/views/posts/show.haml @@ -13,7 +13,9 @@ class: 'btn btn-block' = link_to t('posts.preview'), site_post_preview_path(@site, @post.id), - class: 'btn btn-block' + class: 'btn btn-block', + target: '_blank', + rel: 'noopener' %table.table.table-condensed %thead