Rendering of disabled toggles

When making a setting disabled using .setDisabled(true) the rendering using the default theme does not change. This is counter-intuitive and may confuse users.

It appears that the is-disabled class is correctly applied, but that the default theme does not have any CSS to change the appearance of the toggle.

Here DebugPostprocessor is not disabled and HtmlProcessor is, but it is not possible to tell them apart.

1 Like

More than that, the setting itself doesn’t even get disabled. This really needs to be fixed!

A workaround is to add this to the plugin’s style.css file:

.is-disabled {
	pointer-events: none;
	opacity: 0.2;
}