Skip to content

Commit

Permalink
code clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
EdiWang committed Oct 4, 2023
1 parent 861eca8 commit b1101f0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Moonglade.Web/Pages/Post.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,6 @@
</text>
}
var pid = document.querySelector('article').dataset.postid;
window.fitImageToDevicePixelRatio = @BlogConfig.ImageSettings.FitImageToDevicePixelRatio.ToString().ToLower();
var q = new QRious({
Expand All @@ -104,6 +102,7 @@
$('#comment-form').on('submit', function (e) {
e.preventDefault();
let pid = document.querySelector('article').dataset.postid;
viewpost.submitComment(pid);
});
Expand Down Expand Up @@ -185,6 +184,7 @@
</a>
}
</article>

@if (BlogConfig.ContentSettings.EnableComments)
{
var days = DateTime.UtcNow.Date.Subtract(Model.Post.PubDateUtc.GetValueOrDefault()).Days;
Expand All @@ -201,13 +201,13 @@
<div class="d-print-none">
@if (Model.Post.CommentEnabled)
{
<div class="comment-form-containter p-3 rounded-3 shadow-sm border bg-white mb-4">
<section class="comment-form-containter p-3 rounded-3 shadow-sm border bg-white mb-4">
<h6 class="card-subtitle mb-3 text-muted">
<i class="bi-chat-left-text"></i>
@SharedLocalizer["Comments"]
</h6>
<partial name="_CommentForm" />
</div>
</section>
}
else
{
Expand Down

0 comments on commit b1101f0

Please sign in to comment.