Skip to content

Highlight active dashboard stats card#278

Merged
JLG-WOCFR-DEV merged 1 commit intomainfrom
codex/add-404/5xx/redirection-totals-to-dashboard
Oct 3, 2025
Merged

Highlight active dashboard stats card#278
JLG-WOCFR-DEV merged 1 commit intomainfrom
codex/add-404/5xx/redirection-totals-to-dashboard

Conversation

@JLG-WOCFR-DEV
Copy link
Owner

Summary

  • detect the currently selected broken-link filter and add an active class/aria-current on the corresponding dashboard stat card
  • style the active stat card for both default and dark color schemes so it remains distinguishable from hover/focus states

Testing

  • not run

https://chatgpt.com/codex/tasks/task_e_68e03b9e529c832e8ed2333db099b8fc

@JLG-WOCFR-DEV JLG-WOCFR-DEV merged commit e5ea6df into main Oct 3, 2025
1 check passed
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting

Comment on lines +555 to +558
$current_link_type = 'all';
if (isset($_GET['link_type'])) {
$link_type_param = sanitize_key(wp_unslash($_GET['link_type']));
if ($link_type_param !== '') {

Choose a reason for hiding this comment

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

P1 Badge Guard sanitize_key against array input

The new link_type detection calls sanitize_key( wp_unslash( $_GET['link_type'] ) ) without validating the query parameter’s shape. If someone hits the dashboard with ?link_type[]=foo (or any non‑scalar value), sanitize_key() feeds that array into strtolower() and PHP 8 throws a fatal TypeError, breaking the entire page. Consider ensuring $_GET['link_type'] is a scalar before sanitizing or casting so the dashboard can’t be taken down by a malformed request.

Useful? React with 👍 / 👎.

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.

1 participant