Skip to content

Conversation

@GaryJones
Copy link
Contributor

@GaryJones GaryJones commented Dec 20, 2025

Summary

  • Add "Post Author" badge next to the post author in the notifications subscriber list
  • Add "Auto-subscribed" badge when the post author is auto-subscribed to the post
  • Disable the post author's checkbox when auto-subscribe is enabled (prevents confusing UX where unticking appears to work but doesn't actually unsubscribe them)
  • Add badge styling: neutral grey for informational badges, red for warning badges

Context

This is a fresh reimplementation addressing issue #508. The original PR #563 was closed as stale after 5+ years, and the codebase has changed significantly since then.

Implements the "Alternate UX: Disable checkbox" approach from the issue discussion - this prevents the scenario where a user unticks the post author, sees a green "success" flash, but the author is immediately re-subscribed on save.

Test plan

  • PHP integration tests added (15 tests, 34 assertions)
  • E2E tests added for badge UI behaviour
  • Added Playwright globalSetup to ensure plugin is activated before E2E tests (mirrors PHPUnit's bootstrap.php pattern, follows Gutenberg's approach)
  • Manual testing: create a post, check that the post author shows "Post Author" badge and disabled checkbox

Closes #508

🤖 Generated with Claude Code

@GaryJones GaryJones requested a review from a team as a code owner December 20, 2025 17:24
@GaryJones GaryJones added this to the Next (minor) milestone Dec 20, 2025
Add visual indicators to the notifications metabox showing the post
author and their auto-subscription status. When auto-subscribe is
enabled, the post author's checkbox is disabled to prevent the
confusing scenario where unticking appears to work but doesn't
actually unsubscribe them.

Changes:
- Display "Post Author" badge next to the post author in subscriber list
- Display "Auto-subscribed" badge when post author is auto-subscribed
- Disable checkbox for auto-subscribed post author with tooltip
- Add badge styling (neutral grey for informational, red for warnings)

Testing:
- Add PHP integration tests (15 tests, 34 assertions)
- Add E2E tests for badge UI behaviour
- Add Playwright globalSetup to bootstrap test environment

This is a fresh reimplementation addressing issue #508.
The original PR #563 was closed as stale after 5+ years.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@GaryJones GaryJones force-pushed the feature/notification-badges branch from 20a3d6f to 4c11936 Compare December 20, 2025 17:45
@GaryJones GaryJones self-assigned this Dec 20, 2025
@GaryJones GaryJones merged commit a0b8783 into develop Dec 20, 2025
12 checks passed
@GaryJones GaryJones deleted the feature/notification-badges branch December 20, 2025 19:41
@GaryJones GaryJones mentioned this pull request Jan 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unsubscribing author from Notifications is impossible: Show error or disable unsubscribe checkbox

2 participants