Request: Scope CSS to shortcode container (wordfence_2fa_management)
-
I am using the Wordfence plugin and have enabled the
wordfence_2fa_managementshortcode on a public-facing page.When this shortcode is used, Wordfence loads CSS whose scope is too broad,
and the styles affect elements outside of the shortcode output, causing unintended side effects across the page.In particular,
labelandaelements are heavily affected.
The impact onaelements is especially severe, as link styles across the entire page are overridden.For example, the following global CSS rule is applied:
a {
color: #00709e;
}This rule is loaded from the following CSS file:
/wp-content/plugins/wordfence/modules/login-security/css/admin.1766263234.css?ver=1.1.15At the same time, the content generated by the
wordfence_2fa_managementshortcode is wrapped with the following ID:wfls-management-embeddedTo avoid affecting unrelated page elements, could you please consider
limiting the CSS scope to elements inside#wfls-management-embeddedonly,
instead of applying global selectors?This would help prevent unintended styling conflicts when the shortcode is used on non-admin or front-end pages.
Thank you for your consideration.
You must be logged in to reply to this topic.