Add support for conditionally displaying field section header

  • 1
  • Idea
  • Updated 3 years ago
Would like to see support added for conditionally "showing header" on Field Sections.  This would be similar to the SFDC feature where a section header can be displayed on "View" but not on "Edit/New".

Thank you!
Photo of Barry Schnell

Barry Schnell, Champion

  • 18,076 Points 10k badge 2x thumb

Posted 3 years ago

  • 1
Photo of mB Pat Vachon

mB Pat Vachon, Champion

  • 42,714 Points 20k badge 2x thumb
You can hack this by adding an conditionally rendered empty section.
Photo of Barry Schnell

Barry Schnell, Champion

  • 18,076 Points 10k badge 2x thumb
Thanks Pat.  There are some drawbacks with the hack though:

1) If the section needs to be collapsible (which in my case it does), the conditionally rendered empty section won't be able to control the "real" section

2) If you have sections side-by-side the vertical alignment will need some tweaking

The only viable workaround I can think of right now is to have two sections configured identically, one with "show header" enabled and one with "show header" configured to collapsible.  This works but is far less than ideal due to the number of fields I have in the section and the duplication required.

Maybe I'm misunderstanding your idea?
Photo of mB Pat Vachon

mB Pat Vachon, Champion

  • 42,714 Points 20k badge 2x thumb
Yup. Wanting the section collapsible complicates it.

As for the vertical alignment, you could assign css to the section(s) to manage the CSS.

All this to say yes you are correct in that this is less than ideal.
Photo of Barry Schnell

Barry Schnell, Champion

  • 18,076 Points 10k badge 2x thumb
lol  Yeah, CSS would solve for the alignment for sure.  Collapsible is the death nail though unfortunately :(
Photo of Barry Schnell

Barry Schnell, Champion

  • 18,076 Points 10k badge 2x thumb
Thought of another idea along these same lines...

In addition to conditionally "showing header", would be nice to be able to conditionally specify the collapsible setting when "show header" is true.  For example, in the case of an existing record, you might want to show collapsed initially but for a new record, you might want to show open because input is required.
Photo of Barry Schnell

Barry Schnell, Champion

  • 18,076 Points 10k badge 2x thumb
I've written a collapsible wrapper custom component to solve for these uses cases.  Would still like to see this functionality added to native functionality but in the meantime, see https://community.skuidify.com/skuid/topics/collapsible-wrapper-custom-component?rfm=1&topic_sub.... for more information.