Support

Account

Home Forums Backend Issues (wp-admin) Field spacing off after setting width Reply To: Field spacing off after setting width

  • Hi @avelient

    The first issue occurs because fields with width property have a float style that ignores the top margin of the next un-floated field.

    The second issue occurs because fields with width property have a left margin style except the first one. This style will provide gaps between the fields.

    To fix both issues, you need to add a class to the fields that have the issue and then add a custom CSS code using acf/input/admin_head like this:

    function my_acf_admin_head() {
    	?>
    	<style type="text/css">
    
    		/* ... */
    
    	</style>
    	<?php
    }
    
    add_action('acf/input/admin_head', 'my_acf_admin_head');
    
    ?>

    I hope this helps.