diff --git a/css/spbc-admin.min.css b/css/spbc-admin.min.css index a8321eb8d..9aa2f1b4a 100644 --- a/css/spbc-admin.min.css +++ b/css/spbc-admin.min.css @@ -1 +1 @@ -.spbc_translate_links{color:rgba(150,150,20,1)}.spbc_faq_links{color:rgba(20,150,20,1)}.spbc_support_links{color:rgba(150,20,20,1)}.spbc_setting_links{color:rgba(20,20,150,1)}.spbc_translate_links:hover{color:rgba(210,210,20,1)!important}.spbc_faq_links:hover{color:rgba(20,250,20,1)!important}.spbc_support_links:hover{color:rgba(250,20,20,1)!important}.spbc_setting_links:hover{color:rgba(20,20,250,1)!important}.spbc_hide{display:none}.spbc_hide_table_cell_desc{display:none;max-width:90%}.--hide{display:none}#wp-admin-bar-cleantalk_admin_bar__parent_node span,.-display--inline-block{display:inline-block}.ctlk---red,.spbcRed{color:red}.spbcGreen{color:green}.spbcTextCenter{text-align:center}.spbc-overflow--visible{overflow:visible!important}._animate--rotate{-moz-animation:spin 2s infinite linear;-o-animation:spin 2s infinite linear;-webkit-animation:spin 2s infinite linear;animation:spin 2s infinite linear}#wp-admin-bar-cleantalk_admin_bar__parent_node{margin-right:5px}#wp-admin-bar-cleantalk_admin_bar__parent_node .spbc-icon-attention-alt{background:#d63638;color:#fff;border-radius:50%;font-size:12px}#wp-admin-bar-cleantalk_admin_bar__parent_node img.cleantalk_admin_bar__spbc_icon{width:14px;height:17px;margin-top:7px}#wp-admin-bar-cleantalk_admin_bar__parent_node img.cleantalk_admin_bar__apbct_icon{width:18px;height:18px;margin-top:7px}#wp-admin-bar-cleantalk_admin_bar__parent_node div.cleantalk_admin_bar__sum_counter{color:#999;display:inline;padding:2px 5px!important}#wp-admin-bar-spbc_admin_bar__settings_link a,.cleantalk-admin_bar__parent a{display:inline-block!important;padding:0 10px!important}.cleantalk_admin_bar__blocked div{cursor:not-allowed!important}.cleantalk_admin_bar__blocked div a{color:#777!important}b.spbc-admin_bar--online_admins{font-size:11px!important}.cleantalk_admin_bar__title{vertical-align:top;margin-left:5px!important}.clntlk-hint{position:relative!important}.clntlk-hint:hover{color:#fff}.clntlk-hint:hover::after{content:attr(hint);position:absolute;left:100%;top:50%;background:rgba(235,235,235,.85);padding:0 5px;border:1px solid #333;color:#000;font-style:normal;width:max-content;z-index:99999999999999999}.cleantalk_admin_bar__separator{height:0!important}span.green_dot,span.red_dot{height:8px!important;width:8px!important;border-radius:50%!important;display:inline-block!important;margin-left:5px!important}.cleantalk_admin_bar__counter a{padding:0 10px!important}.cleantalk-admin_bar--list_wrapper .ab-sub-wrapper ul:last-child{margin-bottom:5px!important}span.red_dot{background-color:#d00!important}span.green_dot{background-color:#0d0!important}#spbct-upload-checker-details{overflow-y:scroll;height:150px;border:1px solid #CCC}#spbct-upload-checker-details li:nth-child(2n+1){background:#CCC}.plugins .update+.spbc-vulnerable-notice td{box-shadow:none!important}.spbct-safe-extension-badge{cursor:pointer}.spbct-safe-extension-badge-description-placeholder{position:relative}.spbct-safe-extension-badge-description{display:none;position:absolute;min-width:150px;background:rgba(0,0,0,.5);color:#fff;text-align:left;top:5px;right:0;padding:5px;border-radius:4px;animation:fadeInFromNone .3s ease-in-out;z-index:9999}@keyframes fadeInFromNone{0%{display:none;opacity:0}1%{display:block;opacity:0}100%{display:block;opacity:1}}.spbct-safe-extension-badge-description:before{content:'';position:absolute;top:-10px;right:12px;border:5px solid transparent;border-bottom:5px solid rgba(0,0,0,.5)}.spbct-safe-extension-badge-description:hover,.spbct-safe-extension-badge:hover+.spbct-safe-extension-badge-description-placeholder>.spbct-safe-extension-badge-description{display:block}.spbct-safe-extension-badge-description>a{color:#fff}.spbct-safe-icon{background-color:transparent;background-image:url(../images/spbct-safe-extension.png);background-size:34px;display:inline-block;height:34px;width:34px;top:-5px;left:-5px} \ No newline at end of file +.spbc_translate_links{color:rgba(150,150,20,1)}.spbc_faq_links{color:rgba(20,150,20,1)}.spbc_support_links{color:rgba(150,20,20,1)}.spbc_setting_links{color:rgba(20,20,150,1)}.spbc_translate_links:hover{color:rgba(210,210,20,1)!important}.spbc_faq_links:hover{color:rgba(20,250,20,1)!important}.spbc_support_links:hover{color:rgba(250,20,20,1)!important}.spbc_setting_links:hover{color:rgba(20,20,250,1)!important}.spbc_hide{display:none}.spbc_hide_table_cell_desc{display:none;max-width:90%}.--hide{display:none}#wp-admin-bar-cleantalk_admin_bar__parent_node span,.-display--inline-block{display:inline-block}.ctlk---red,.spbcRed{color:red}.spbcGreen{color:green}.spbcTextCenter{text-align:center}.spbc-overflow--visible{overflow:visible!important}._animate--rotate{-moz-animation:spin 2s infinite linear;-o-animation:spin 2s infinite linear;-webkit-animation:spin 2s infinite linear;animation:spin 2s infinite linear}#wp-admin-bar-cleantalk_admin_bar__parent_node{margin-right:5px}#wp-admin-bar-cleantalk_admin_bar__parent_node .spbc-icon-attention-alt{background:#d63638;color:#fff;border-radius:50%;font-size:12px}#wp-admin-bar-cleantalk_admin_bar__parent_node img.cleantalk_admin_bar__spbc_icon{width:14px;height:17px;margin-top:7px}#wp-admin-bar-cleantalk_admin_bar__parent_node img.cleantalk_admin_bar__apbct_icon{width:18px;height:18px;margin-top:7px}#wp-admin-bar-cleantalk_admin_bar__parent_node div.cleantalk_admin_bar__sum_counter{color:#999;display:inline;padding:2px 5px!important}#wp-admin-bar-spbc_admin_bar__settings_link a,.cleantalk-admin_bar__parent a{display:inline-block!important;padding:0 10px!important}.cleantalk_admin_bar__blocked div{cursor:not-allowed!important}.cleantalk_admin_bar__blocked div a{color:#777!important}b.spbc-admin_bar--online_admins{font-size:11px!important}.cleantalk_admin_bar__title{vertical-align:top;margin-left:5px!important}.clntlk-hint{position:relative!important}.clntlk-hint:hover{color:#fff}.clntlk-hint:hover::after{content:attr(hint);position:absolute;left:100%;top:50%;background:rgba(235,235,235,.85);padding:0 5px;border:1px solid #333;color:#000;font-style:normal;width:max-content;z-index:99999999999999999}.cleantalk_admin_bar__separator{height:0!important}span.green_dot,span.red_dot{height:8px!important;width:8px!important;border-radius:50%!important;display:inline-block!important;margin-left:5px!important}.cleantalk_admin_bar__counter a{padding:0 10px!important}.cleantalk-admin_bar--list_wrapper .ab-sub-wrapper ul:last-child{margin-bottom:5px!important}span.red_dot{background-color:#d00!important}span.green_dot{background-color:#0d0!important}#spbct-upload-checker-details{overflow-y:scroll;height:150px;border:1px solid #CCC}#spbct-upload-checker-details li:nth-child(2n+1){background:#CCC}.plugins .update+.spbc-vulnerable-notice td{box-shadow:none!important}.spbct-safe-extension-badge{cursor:pointer}.spbct-safe-extension-badge-description-placeholder{position:relative}.spbct-safe-extension-badge-description{display:none;position:absolute;min-width:200px;background:rgba(0,0,0,.5);color:#fff;text-align:center;top:2px;right:0;padding:5px;animation:fadeInFromNone .3s ease-in-out;z-index:9999}@keyframes fadeInFromNone{0%{display:none;opacity:0}1%{display:block;opacity:0}100%{display:block;opacity:1}}.spbct-safe-extension-badge-description:before{content:'';position:absolute;top:-10px;right:10px;border:5px solid transparent;border-bottom:5px solid rgba(0,0,0,.5)}.spbct-safe-extension-badge-description:hover,.spbct-safe-extension-badge:hover+.spbct-safe-extension-badge-description-placeholder>.spbct-safe-extension-badge-description{display:block}.spbct-safe-extension-badge-description>a{color:#fff;text-decoration:underline} \ No newline at end of file diff --git a/css/src/spbc-admin.css b/css/src/spbc-admin.css index 4cabe9c5a..983fe74f0 100644 --- a/css/src/spbc-admin.css +++ b/css/src/spbc-admin.css @@ -158,14 +158,13 @@ span.green_dot{ .spbct-safe-extension-badge-description { display: none; position: absolute; - min-width: 150px; + min-width: 200px; background: rgba(0, 0, 0, 0.5); color: white; - text-align: left; - top: 5px; + text-align: center; + top: 2px; right: 0; padding: 5px; - border-radius: 4px; animation: fadeInFromNone 0.3s ease-in-out; z-index: 9999; } @@ -187,7 +186,7 @@ span.green_dot{ content: ''; position: absolute; top: -10px; - right: 12px; + right: 10px; border: 5px solid transparent; border-bottom: 5px solid rgba(0, 0, 0, 0.5); } @@ -197,14 +196,5 @@ span.green_dot{ } .spbct-safe-extension-badge-description > a { color: white; -} -.spbct-safe-icon { - background-color: transparent; - background-image: url(../images/spbct-safe-extension.png); - background-size: 34px; - display: inline-block; - height: 34px; - width: 34px; - top: -5px; - left: -5px; + text-decoration: underline; } \ No newline at end of file diff --git a/images/spbct-safe-extension.png b/images/spbct-safe-extension.png deleted file mode 100644 index e4ff5c1fa..000000000 Binary files a/images/spbct-safe-extension.png and /dev/null differ diff --git a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_auto.svg b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_auto.svg new file mode 100644 index 000000000..123ca8801 --- /dev/null +++ b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_auto.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_manual.svg b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_manual.svg new file mode 100644 index 000000000..7faf7de23 --- /dev/null +++ b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_manual.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_manual_and_auto.svg b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_manual_and_auto.svg new file mode 100644 index 000000000..e1d60115c --- /dev/null +++ b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/approved_manual_and_auto.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/vulnerable.svg b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/vulnerable.svg new file mode 100644 index 000000000..083f3830d --- /dev/null +++ b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets/vulnerable.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/View/PluginIsSafeBadge.html b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/View/PluginIsSafeBadge.html index a2c99035b..95481d9d5 100644 --- a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/View/PluginIsSafeBadge.html +++ b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/View/PluginIsSafeBadge.html @@ -1,5 +1,5 @@
- + Approved
diff --git a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/VulnerabilityAlarmView.php b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/VulnerabilityAlarmView.php index 4cb69355d..e7961e5f5 100755 --- a/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/VulnerabilityAlarmView.php +++ b/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/VulnerabilityAlarmView.php @@ -6,6 +6,8 @@ class VulnerabilityAlarmView { + const ASSETS_URL = SPBC_PATH . '/lib/CleantalkSP/SpbctWP/VulnerabilityAlarm/Assets'; + /** * @param string $plugin_file * @param PluginReport $plugin_report @@ -69,6 +71,7 @@ public static function showSafeBadge($module_type, $plugin_slug, $plugin_id) if ( file_exists($layout_file) ) { $replaces = [ + '{{ASSETS_URL}}' => self::ASSETS_URL, '{{DESCRIPTION}}' => $badge_description, '{{MORE_DETAILS_LINK}}' => static::getMoreDetailsLink($plugin_slug, $plugin_id, true) ]; @@ -93,18 +96,20 @@ public static function showSafeBadge($module_type, $plugin_slug, $plugin_id) private static function getMoreDetailsLink($plugin_slug = '', $plugin_id = '', $line_break = false) { $details_link = "https://research.cleantalk.org"; - $line_break = $line_break ? '
' : ' '; + $line_break_layout = $line_break ? '
' : ' '; if ($plugin_slug && $plugin_id) { - $details_link = $details_link . '/reports/app/' . $plugin_slug . '#' . $plugin_id; + $details_link = esc_attr($details_link . '/reports/app/' . $plugin_slug . '#' . $plugin_id); } return sprintf( - esc_html__('Full report is here %s', 'security-malware-firewall'), - '' . $details_link . '' + esc_html__('Full report is %shere%s', 'security-malware-firewall'), + '', + '' ) - . $line_break + . $line_break_layout . sprintf( - esc_html__('Have questions? Ask us here %s', 'security-malware-firewall'), - 'https://wordpress.org/support/plugin/security-malware-firewall/' + esc_html__('Have questions? Ask us %shere%s', 'security-malware-firewall'), + '', + '' ); }