How to remove white space from a section separator

RishabhB
Tera Contributor

Hello,

I am hiding/showing fields, respective section separators and annotations through UI policies.

I'm handling fields visibility through Visible column under UI Policy Action and through scripting sometime using setDisplay() method. Annotations are being hidded/displayed using  <section_separator_name>.parentNode.style.display = "none"; (or block).

 

Though the functionality is working but leaving white space when hidden. Please suggest a way to achieve this type of visibility with no white spaces left behind.

5 REPLIES 5

Ankur Bawiskar
Tera Patron
Tera Patron

@RishabhB 

please share some screenshots

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Ankur Bawiskar
Tera Patron
Tera Patron

@RishabhB 

I doubt you might have to use DOM manipulation for this but please share some screenshots etc

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

RishabhB
Tera Contributor

@Ankur Bawiskar, shared a screenshot from a sample form where a div element can be seen occupying white space.

@RishabhB 

I believe DOM is the only way.

Also I believe since you are showing/hiding annotations you might be using DOM already

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader