fix: show post approve button properly on mobile (#720)#761
Open
shayesdevel wants to merge 3 commits into
Open
fix: show post approve button properly on mobile (#720)#761shayesdevel wants to merge 3 commits into
shayesdevel wants to merge 3 commits into
Conversation
Two issues fixed: 1. Filter approve/remove buttons (for posts with state_mod FILTERED) were only shown on desktop in the inline action bar. Added matching buttons to the mobile footer bar in both submission_listing.html and submission.html so admins can approve/remove filtered posts directly on mobile without needing to dig through modals. 2. In the admin mobile modal (actions_admin_mobile.html), the mod approve/remove buttons used dropdown-item classes but lived inside a list-group container, causing them to render without proper padding and spacing. Changed to list-group-item with mr-2 on icons to match the styling of other items in the same modal. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…#720) Three tests verify the approve/remove button markup renders correctly: - Individual filtered post page shows filter-approve/filter-remove buttons - Filtered posts admin listing shows the buttons - Mobile admin actions modal includes list-group-item styled buttons Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Rename mobile filter button IDs from filter-approve/filter-remove to filter-approve-mobile/filter-remove-mobile to avoid duplicate HTML IDs when both desktop and mobile sections are in the DOM simultaneously. Update filter_actions.js to also clean up the mobile buttons on action. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
|
Currently has a conflict; I think part of this might already be done, though? The user just hadn't realized it was in a dropdown. Look over this more closely if you would, this might just be a no-longer-relevant bug report. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #720
Summary
actions_admin_mobile.html) fromdropdown-item list-inline-itemtolist-group-itemto match the parentlist-groupcontainer, giving proper padding and consistent stylingChanges
files/templates/submission_listing.html-- added filter approve/remove buttons to mobile footer when post is filteredfiles/templates/submission.html-- same change for the single post view mobile barfiles/templates/component/post/actions_admin_mobile.html-- fixed CSS classes on mod approve/remove from dropdown-item to list-group-item, added icon marginfiles/tests/test_admin.py-- added 3 page load tests for filtered post approve button renderingTesting
test_filtered_post_has_approve_button-- loads individual filtered post page as admin, verifies approve/remove button markuptest_filtered_post_listing_has_approve_button-- loads /admin/filtered/posts with a filtered post, verifies buttonstest_filtered_post_mobile_actions_load-- verifies mobile admin actions modal renders list-group-item styled buttonsGenerated with Claude Code