<% step.step_orderable_elements.order(position: :asc).each do |step_element| %>
<% case step_element.orderable_type %>
<% when 'StepText' %>
<% step_text = step_element.orderable %>
<%= auto_link(simple_format(step_text.name),
link: :urls,
html: { target: '_blank' }) %>
<%= custom_auto_link(step_text.tinymce_render(:text).gsub(/
\S<\/p>/, '').strip,
simple_format: false,
tags: %w(img),
team: current_team,
preview_repository: true) %>
<% when 'StepTable' %>
<% table = step_element.orderable.table %>
<% when 'Checklist' %>
<% checklist = step_element.orderable %>
<%= smart_annotation_parser(checklist.name, current_team).html_safe %>
<% checklist.checklist_items.order(position: :asc).each do |checklist_item| %>
<% if checklist_item.checked %>
<%= image_tag "check-square-solid.svg" %>
<% else %>
<% end %>
<%= smart_annotation_parser(checklist_item.text, current_team).html_safe %>
<%# Should stay in one line %>
<% end %>
<% end %>
<% end %>
<% step.assets.where(view_mode: "inline").each do |asset| %>
<% end %>
<% step.assets.where(view_mode: "list").each do |asset| %>
<%= t('Comments') %>:
<% step.step_comments.each do |comment| %>