Skip to content

Theme and bg color improvements - #139

Merged
iMattPro merged 10 commits into
phpbb-extensions:mainfrom
iMattPro:updates
Sep 29, 2026
Merged

iMattPro merged 10 commits into
phpbb-extensions:mainfrom
iMattPro:updates

Conversation

@iMattPro

Copy link
Copy Markdown
Contributor

No description provided.

@codecov-commenter

codecov-commenter commented Sep 26, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.72%. Comparing base (581f7dc) to head (377bc07).

Additional details and impacted files
@@            Coverage Diff            @@
##               main     #139   +/-   ##
=========================================
  Coverage     98.72%   98.72%           
  Complexity      241      241           
=========================================
  Files             9        9           
  Lines           704      704           
=========================================
  Hits            695      695           
  Misses            9        9           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@iMattPro
iMattPro requested a review from rxu September 26, 2026 13:40

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

The theme-color meta tag must be preserved for browser PWA colour support.

Review effort: Lite
Findings: 1 Medium severity

Open (1)
What changed in this PR

Adds ACP controls to detect PWA theme and background colours from installed styles.

Changes:

  • Adds colour-detection controls, iframe preview logic, styling, and localized labels.
  • Updates listener tests and removes obsolete background-colour template data.
  • Updates PWA head colour output.

Review note: retain the theme-color meta tag alongside the CSS custom property.

File Description
tests/​event/​listener_test.php Updates listener expectations.
styles/​all/​template/​event/​overall_header_head_append.html Updates PWA colour markup.
language/​ru/​webpushnotifications_module_acp.php Adds Russian detection strings.
language/​en/​webpushnotifications_module_acp.php Adds English detection strings.
event/​listener.php Removes obsolete background-colour template data.
adm/​style/​wpn_acp_pwa.html Adds detection controls.
adm/​style/​pwa_acp.js Implements colour detection and field updates.
adm/​style/​pwa_acp.css Styles detection status and preview iframe.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread styles/all/template/event/overall_header_head_append.html Outdated
@iMattPro
iMattPro force-pushed the updates branch 3 times, most recently from f588cc0 to 9a9efdf Compare September 27, 2026 15:02

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

Moderate issues remain with PWA colour semantics, banner contrast, and notification URL handling.

Review effort: Lite
Findings: 1 Medium severity

Open (1)
Resolved since last review (1)
Previously missed (1)

In code that hasn't changed since last review

Medium severity Use detected background color for manifest background

adm/​style/​pwa_acp.js:148

The detected page background is written to theme, but background is replaced with the opposite black/white colour. The manifest’s background_color is the splash/app-window background and should match the page’s initial background; for a dark blue or light gray style this introduces a visible flash of the wrong colour. Use the detected colour for the background as well (or derive both values according to the manifest semantics), rather than choosing a contrast colour.

Comment thread styles/all/template/push_worker.js.twig Outdated

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot review overview

🔵 Needs a closer look

test_worker_bot() may fail without the required board URL setup.

Review effort: Lite
Findings: None

Resolved since last review (1)

@iMattPro
iMattPro merged commit 87b2130 into phpbb-extensions:main Sep 29, 2026
65 of 66 checks passed
@iMattPro
iMattPro deleted the updates branch September 29, 2026 16:09
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.

4 participants