Skip to content

Commit

Permalink
Merge pull request #927 from WordPress/fix/plugin-deactivate-link-color
Browse files Browse the repository at this point in the history
Fix plugin deactivation link color
  • Loading branch information
felixarntz authored Jan 11, 2024
2 parents 04ef610 + a36f6b1 commit d0ee705
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
4 changes: 4 additions & 0 deletions admin/load.php
Original file line number Diff line number Diff line change
Expand Up @@ -888,6 +888,10 @@ function perflab_print_modules_page_style() {
animation: rotation 2s infinite linear;
margin-left: 5px;
}
.plugin-action-buttons a[id^="deactivate-"] {
color: #b32d2e;
text-decoration: underline;
}
</style>
<?php
}
18 changes: 10 additions & 8 deletions admin/plugins.php
Original file line number Diff line number Diff line change
Expand Up @@ -193,14 +193,16 @@ function perflab_render_plugin_card( array $plugin_data ) {
$context = $status['status'];

$action_links[] = sprintf(
'<a href="%s" id="deactivate-%s" aria-label="%s" style="color:red;text-decoration: underline;">%s</a>',
add_query_arg(
array(
'_wpnonce' => wp_create_nonce( 'perflab_deactivate_plugin_' . $status['file'] ),
'action' => 'perflab_deactivate_plugin',
'plugin' => $status['file'],
),
network_admin_url( 'plugins.php' )
'<a href="%s" id="deactivate-%s" aria-label="%s">%s</a>',
esc_url(
add_query_arg(
array(
'_wpnonce' => wp_create_nonce( 'perflab_deactivate_plugin_' . $status['file'] ),
'action' => 'perflab_deactivate_plugin',
'plugin' => $status['file'],
),
network_admin_url( 'plugins.php' )
)
),
esc_attr( $plugin_data['slug'] ),
/* translators: %s: Plugin name. */
Expand Down

0 comments on commit d0ee705

Please sign in to comment.