Skip to content

Commit

Permalink
Upd. Settings. Improved UX. (#432)
Browse files Browse the repository at this point in the history
  • Loading branch information
svfcode authored Oct 31, 2024
1 parent 52b8f3a commit ebfff9b
Show file tree
Hide file tree
Showing 9 changed files with 32 additions and 17 deletions.
14 changes: 7 additions & 7 deletions inc/admin-bar.php
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,13 @@ function spbc_admin__admin_bar__add_child_nodes($wp_admin_bar)
));
}

// Critical updates
$wp_admin_bar->add_node(array(
'parent' => 'spbc__parent_node',
'id' => 'spbc_admin_bar__critical_updates_link',
'title' => '<a href="' . $spbc->settings_link . '&spbc_tab=critical_updates">' . __('Critical updates', 'security-malware-firewall') . '</a>',
));

// FireWall
if ( (int) $spbc->settings['secfw__enabled'] ) {
$wp_admin_bar->add_node(array(
Expand Down Expand Up @@ -306,13 +313,6 @@ function spbc_admin__admin_bar__add_child_nodes($wp_admin_bar)
'title' => '<a href="' . $spbc->settings_link . '&spbc_tab=summary">' . __('Summary', 'security-malware-firewall') . '</a>',
));

// Critical updates
$wp_admin_bar->add_node(array(
'parent' => 'spbc__parent_node',
'id' => 'spbc_admin_bar__critical_updates_link',
'title' => '<a href="' . $spbc->settings_link . '&spbc_tab=critical_updates">' . __('Critical updates', 'security-malware-firewall') . '</a>',
));

// Support link
$wp_admin_bar->add_node(array(
'parent' => 'spbc__parent_node',
Expand Down
2 changes: 1 addition & 1 deletion inc/spbc-settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -1935,7 +1935,7 @@ function spbc_field_key()
echo '<a id="spbc-key-manually-link" target="_blank" href="https://cleantalk.org/register?platform=wordpress&email=' . urlencode(spbc_get_admin_email()) . '&website=' . urlencode(parse_url(get_option('home'), PHP_URL_HOST)) . '&product_name=security" style="display: inline-block;">
<input style="color:#666;" type="button" class="spbc_auto_link" value="' . __('Get access key manually', 'security-malware-firewall') . '" />
</a>';
echo '&nbsp;' . __('or', 'security-malware-firewall') . '&nbsp;';
echo '<span id="spbc_get_key_or_text">&nbsp;' . __('or', 'security-malware-firewall') . '&nbsp;</span>';
echo '<button class="spbc_manual_link" id="spbc_setting_get_key_auto" name="spbc_get_apikey_auto" type="button" value="get_key_auto">'
. __('Get access key automatically', 'security-malware-firewall')
. '<img style="margin-left: 10px;" class="spbc_preloader_button" src="' . SPBC_PATH . '/images/preloader2.gif" />'
Expand Down
2 changes: 1 addition & 1 deletion js/spbc-admin.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion js/spbc-admin.min.js.map

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions js/spbc-react-bundle.js

Large diffs are not rendered by default.

Loading

0 comments on commit ebfff9b

Please sign in to comment.