Remove whitespace but keep space between fields in preview

I have a form with multiple toggle fields and lists. I want to remove the whitespace, but keep the toggle fields where they are in the preview. So far, everything i tried either keeps some whitespace, or if i remove all whitespace, then the toggle boxes get grouped together in the preview (which is what i want to avoid). How do i keep the preview format as is, but remove whitespace in the final version (the one that will be printed in the browser)?

Hello :slight_smile:

To fix your whitespace issue, try moving the {endformtoggle} to the next line. It would look something like this:

Doing this makes it so that each item is inserted on a new line without creating extra space when it is not toggled on.

Here's what it would look like when you insert it:

whitespace-example

Would that work?

It doesn't work after a list formmenu, the endformtoggle is not used there, from what i understood. Also, the toggle boxes all appear grouped together in the preview, which is what i would like to avoid. I want to keep the format i have in the preview (with line breaks), but just remove whitespaces from the final version.

Can you share the snippet you're talking about so I can take a look? There's a gear option to add a snippet in the text box when you create a community post :slight_smile:



Hi Dylan, after looking at the 2 pics, do you know if there's a way to have "Cool" appear directly after "WNL" rather than staying at its placement in the drop down menu?
Thanks so much

Hi Sarah,

Can you share the snippet here so I can try it out? You can click the gear option when writing a response and paste in your snippet contents :slight_smile:

The following items in Skin have to be corrected/detailed as below: {formmenu: ; WNL; Dry; Clammy; Warm; Cool; Pallor; Turgor; Comments; name=corrections; multiple=yes}
Skin:
{if: includes(corrections, "WNL"); trim=no}WNL:{formmenu: untick WNL since Pt has an existing wound; tick WNL since Pt has no open wounds; multiple=yes} {endif}
{if: includes(corrections, "Dry"); trim=no}Dry:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes} {endif}
{if: includes(corrections, "Clammy"); trim=no}Clammy:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes} {endif}
{if: includes(corrections, "Warm"); trim=no}Warm:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes} {endif}
{if: includes(corrections, "Cool"); trim=no}Cool:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes} {endif}
{if: includes(corrections, "Pallor"); trim=no}Pallor:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes} {endif}
{if: includes(corrections, "Turgor"); trim=no}Turgor:{formmenu: select the appropriate assessment finding; Insert feedback 2; multiple=yes}{endif}
{if: includes(corrections, "Comments"); trim=no}Comments:{formmenu: state "no skin breakdown noted during the visit"\ ; Wounds listed should include PICC lines, Ostomy, Peg tube, suprapubic catheter.; Follow latest wound care order dated\ ; multiple=yes} {endif}

Hi Dylan, thank you so much for your prompt response. I copied/pasted the snippet here after selecting the gear, I hope it comes out right. Thanks so much

Try this:

The following items in Skin have to be corrected/detailed as below: {formmenu: ; WNL; Dry; Clammy; Warm; Cool; Pallor; Turgor; Comments; name=corrections; multiple=yes}
Skin:
{if: includes(corrections, "WNL"); trim=no}WNL:{formmenu: untick WNL since Pt has an existing wound; tick WNL since Pt has no open wounds; multiple=yes}
{endif}{if: includes(corrections, "Dry"); trim=no}Dry:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes}
{endif}{if: includes(corrections, "Clammy"); trim=no}Clammy:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes}
{endif}{if: includes(corrections, "Warm"); trim=no}Warm:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes}
{endif}{if: includes(corrections, "Cool"); trim=no}Cool:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes}
{endif}{if: includes(corrections, "Pallor"); trim=no}Pallor:{formmenu: Insert feedback 1; Insert feedback 2; multiple=yes}
{endif}{if: includes(corrections, "Turgor"); trim=no}Turgor:{formmenu: select the appropriate assessment finding; Insert feedback 2; multiple=yes}
{endif}{if: includes(corrections, "Comments"); trim=no}Comments:{formmenu: state "no skin breakdown noted during the visit"\ ; Wounds listed should include PICC lines, Ostomy, Peg tube, suprapubic catheter.; Follow latest wound care order dated\ ; multiple=yes}{endif}

I moved the {endformtoggle} to the next line, which helps eliminate extra whitespace. Let me know if that works for you :slight_smile:

You are the best!!! lol that worked. Thank you so much!

1 Like