How To Disable Typography Option in WordPress 5.9

It’s very simple to disable it, you can simply drop this in your theme functions.php or add it in your plugin.

	function() {
		add_theme_support( 'editor-font-sizes', [] );

			function( $editor_settings, $context ) {
				$editor_settings['__experimentalFeatures']['typography']['fontWeight'] = false;
				$editor_settings['__experimentalFeatures']['typography']['letterSpacing'] = false;
				$editor_settings['__experimentalFeatures']['typography']['textTransform'] = false;
				$editor_settings['__experimentalFeatures']['typography']['fontStyle'] = false;
				return $editor_settings;

How to Disable Drop Cap Settings?

You can simply add this code:

$editor_settings['__experimentalFeatures']['typography']['dropCap'] = false;

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.