Skip to content

Conversation

@iMattPro
Copy link
Contributor

@iMattPro iMattPro commented Jan 6, 2026

No description provided.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the popup preference toggle UI from an icon-based button to a text-based button with clearer labeling. The changes improve the UX by making the toggle control more explicit and accessible.

Key changes:

  • Replaced toggle icon button with a text-based input button showing "Enable reminders" or "Disable reminders"
  • Separated S_WEBPUSH_POPUP_PROMPT (feature availability) from S_WEBPUSH_POPUP_DISABLED (user preference) for clearer logic
  • Updated language keys to reflect the new UI approach with NOTIFY_WEBPUSH_POPUP_ENABLER and NOTIFY_WEBPUSH_POPUP_DISABLER

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/functional/functional_test.php Updated test assertions to check button value attribute instead of icon classes
styles/prosilver/template/event/ucp_notifications_content_before.html Replaced button with icon to input button with text value; wrapped toggle control in conditional
styles/all/template/webpush_popup.html Enhanced popup display condition to explicitly check both feature availability and user preference
styles/all/template/webpush.js Updated JavaScript handler to change button value instead of toggling icon classes
notification/method/webpush.php Simplified S_WEBPUSH_POPUP_PROMPT logic by removing user preference check (now separate as S_WEBPUSH_POPUP_DISABLED)
language/ru/webpushnotifications_module_ucp.php Added Russian translations for new button labels and updated existing text for clarity
language/en/webpushnotifications_module_ucp.php Added English translations for new button labels and updated existing text for clarity

After thorough review of all changes, I found no issues with the code. The refactoring is well-executed with:

  • Consistent changes across all layers (templates, JavaScript, backend, tests, and translations)
  • Improved separation of concerns between feature availability and user preferences
  • Better UX with explicit text labels instead of icons
  • Properly updated tests that match the new implementation
  • Complete language support in both English and Russian

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@iMattPro iMattPro merged commit 7fe0aa0 into phpbb-extensions:main Jan 9, 2026
39 checks passed
@iMattPro iMattPro deleted the fixes branch January 9, 2026 23:20
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