PluginProbe
Double Opt-In for Contact Form 7 – Secure, GDPR-Compliant Email Verification / 5.5.0
Double Opt-In for Contact Form 7 – Secure, GDPR-Compliant Email Verification v5.5.0
5.6.2 5.6.3 5.6.1 5.6.0 5.5.0 5.4.0 5.3.2 5.3.1 5.1.6 5.1.5 trunk 2.1.5 2.11 2.12 2.13 2.15 3.0.0 3.0.1 3.0.2 3.0.3 3.0.5 3.0.51 3.0.60 3.0.61 3.0.62 All 38 releases
← All changes | core/assets/toggle.js +13 -0 3.0.3 → 5.5.0 View file →
@@ -60,8 +60,21 @@
60 60 var c = this;
61 61 jQuery(document).on('click', '#' + this.id, function () {
62 62 c.onClick(jQuery(this).attr('data-switch-target'));
63 63 });
64 +
65 + // Handle clicks on labels within the toggle wrapper
66 + var $wrapper = this.dom.closest('.f12-checkbox-toggle');
67 + if ($wrapper.length) {
68 + $wrapper.on('click', function (e) {
69 + // Skip if clicking the toggle button itself
70 + if (jQuery(e.target).closest('.btn-toggle').length) {
71 + return;
72 + }
73 + e.preventDefault();
74 + c.onClick(c.dom.attr('name'));
75 + });
76 + }
64 77 }
65 78
66 79 this.init();
67 80 this.addEventHandler();