Page tree
Skip to end of metadata
Go to start of metadata

This is a custom expand macro that works great with ConfiForms dialog mode forms

## @param Title:title=Title |type=string|required=true

<div class="expand-container">
<div class="expand-control">
<span class="expand-control-icon icon">&nbsp;</span>
<a onclick="toggleExpand(this)" style="cursor:pointer"><span class="expand-control-text">$paramTitle</span></a>
</div>
<div class="expand-content" style="display:none"><p>$body</p></div>
</div>

<script>
function toggleExpand(elem) {
  AJS.$(elem).closest('.expand-container').find('.expand-content ').each(function(){
   AJS.$(this).toggle();
  });
}
</script>


Below is the macro in action

  • No labels