You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am conditionally displaying widgets. In my case it is per language, using WPML. According to them, plugin developers cannot fully remove all markup for block widgets and will leave an empty widget container.
I belive there are other plugins that allows for conditionally showing or hiding widgets that would have the same issue
My suggestion is that the margins that are added to widgets by the theme should not be applied if the widget is :empty.
To clarify, this is only a problem with the modern block widgets. Classic widgets are fine.
Description
I am conditionally displaying widgets. In my case it is per language, using WPML. According to them, plugin developers cannot fully remove all markup for block widgets and will leave an empty widget container.
I belive there are other plugins that allows for conditionally showing or hiding widgets that would have the same issue
My suggestion is that the margins that are added to widgets by the theme should not be applied if the widget is
:empty
.To clarify, this is only a problem with the modern block widgets. Classic widgets are fine.
References
Example markup of empty block widget:
<aside id="block-2" class="widget inner-padding widget_block"></aside>
WPML ticket: https://wpml.org/forums/topic/a-empty-div-element-are-rendered-for-widgets-that-are-disabled-for-language/
The text was updated successfully, but these errors were encountered: