<% if destroy %>
<%= active_element.component.destroy_button(record) %>
<% end %> <% if modal %>
<%= active_element.component.button( title: title.presence || 'Show Form', icon: 'arrow-up-right-dots', data: { field_type: 'form-modal', form_id: id, form_title: title }) %>
<%= render partial: 'active_element/components/form/summary', locals: { fields: fields, component: component } %>
<% elsif title.present? %> <%= title %> <% end %> <% unless component.valid? %>

<%= component.full_error_message %>

<% end %>