Skip to content

UI/UX enhancement for comment moderation and sidebar widgets - #819

Merged
poppastring merged 7 commits into
mainfrom
more-taghelpers
May 6, 2026
Merged

poppastring merged 7 commits into
mainfrom
more-taghelpers

Conversation

@poppastring

Copy link
Copy Markdown
Owner

PR Classification

New feature and UI/UX enhancement for comment moderation and sidebar widgets.

PR Summary

This PR adds the ability to unapprove comments, modernizes the comment moderation UI, and introduces new sidebar widgets for recent posts, categories, and archives.

  • CommentManager.cs, BlogDataService.cs, and related interfaces: Added UnapproveComment support and new CommentSaveState.
  • BlogPostController.cs: Introduced API endpoint for unapproving comments.
  • ManageComments.cshtml and site.js: Switched to card-based moderation UI, added "Move to Pending" action, and improved modal logic.
  • Added RecentPostsTagHelper, CategoryListTagHelper, ArchiveListTagHelper, and PostAuthorTagHelper for sidebar and post byline enhancements.
  • Updated _Layout.cshtml and CSS for improved navigation, accessibility, and sidebar widget styling.

Introduced RecentPostsTagHelper, CategoryListTagHelper, and ArchiveListTagHelper for dynamic sidebar widgets. Added PostAuthorTagHelper for author bylines with display name, mailto link, and Gravatar support. Updated _Layout.cshtml and _BlogItem.cshtml to use these new TagHelpers.
Updated <html> to use lang="en" and moved theme control to a script in the <head> that forces light mode via localStorage and data-bs-theme. Reduced .flm-article padding in custom.css for tighter layout.
- Refactored RecentPostsTagHelper to use root-relative post URLs.
- Removed Medialoot template attribution from _Layout.cshtml.
- Improved sidebar widget link alignment and suppressed duplicate <hr> after headings in custom.css.
Standardized "Category"/"Tags" and "Archive" navigation links in _Layout.cshtml by adding explicit empty route parameters. This ensures consistent URL generation and may resolve routing issues.
Refactored the comment moderation interface from a table to a Bootstrap card-based layout for improved clarity and usability. Updated TagHelpers to support flexible button styling via a Css property. Rewrote the comment pager to use Bootstrap pagination with better accessibility. Comment status now controls card border color for visual feedback. Enhanced empty-state handling and header in ManageComments.cshtml. Added new CSS for card styling and cleaned up unused code.
Implemented unapprove functionality for comments, including:
- UnapproveComment methods in manager and data service layers
- New CommentSaveState.Unapproved enum value
- API endpoint and UI for unapproving comments
- TagHelper and JS updates for modal/action handling
- XML and UI changes to reflect pending state
Cleared the <Comments> section by deleting all comment entries, resulting in an empty <Comments /> tag for the specified date. No other changes were made to the file.
@poppastring
poppastring merged commit 80373e3 into main May 6, 2026
3 checks passed
@poppastring
poppastring deleted the more-taghelpers branch May 6, 2026 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant