<%-   
  content_for :title, result_node.page_title.blank? ? result_node.title : result_node.page_title
  content_for :meta_description, result_node.page_description
%>


<div class="question-container">
  
  <div class="animation-element">
    <div class="question-step">
      <div><%= t 'results' %></div>
    </div>
  </div>
 
  <div class="animation-element">
    <div class="result-msg">
      <%= decorate_divs_for_typewriting_effect @result_attachment&.body&.sub("&lt;name&gt;", html_escape(current_player.name)).html_safe %>
    </div>
  </div>
  
  <div class="animation-element">
    <div class="result-stats">
      <%= @stats_attachment&.body&.sub("&lt;score&gt;", current_player.stats).html_safe %>
    </div>
  </div>

  <div class="animation-element">
    <div class="result-actions">    
      <%= link_to tag.span(t('read_more')), "#", class: 'button__base'  %>
      <%= button_tag tag.span(t('share_on_story')), 
                      data: {
                        share_title: t('share.title'),
                        share_text: t('share.text'),
                        share_url: url_for(controller: 'questions', action: 'shared_result', id: params[:sid], only_path: false)
                      },
                      type: 'button', 
                      class: 'button__base'  %>
    </div>
  </div>
  
</div>