src/NCBS/WebsiteBundle/Resources/views/Bible/multicolumn/breadcrumbs.html.twig line 1

Open in your IDE?
  1. {% extends 'NCBSWBundle:General:multicolumn/header_framework.html.twig' %}
  2. {% set bOnMobile = app.session.get('is_on_mobile')    %}
  3. {# precompute chapter/book/translation/canonicalchapter/canonicalbook entities (or should that be done in controller?) #}
  4. {% if contents is not empty %}
  5.   {% set first_verse = contents|first|first.findMainVerse() %}
  6.   {% set last_verse = contents|last|last.findMainVerse() %}
  7.   {% set first_chapter = first_verse.chapter %}
  8.   {% set last_chapter = last_verse.chapter %}
  9.   {% if first_chapter == last_chapter %}
  10.     {% set chapter = first_chapter %}
  11.   {% endif %}
  12.   {% set book = first_chapter.book %}
  13.   {% set canonical_book = book.canonicalization %}
  14. {% elseif canonically_numbered %}
  15.   {% set canonical_book = book %}
  16. {% endif %}
  17. {% block crumb_trail %}
  18. {#
  19.   <li class="breadcrumb-item">
  20.     (all content?)///
  21.   </li>
  22. #}
  23.     {% if story is defined %}
  24.       <li class="breadcrumb-item">
  25.             <a href="{{ path('bible_stories') }}" title="{{ app.session.get('ui_str')["linktitle.short.bible.stories"] }}"><i class="fad fa-book-open-reader"></i></a>
  26.       </li>
  27.       {% if all_stories is defined %}
  28.           <li class="breadcrumb-item">
  29.               
  30.               {% include 'NCBSWBundle:Bible:interface/story_dropdown/story_dropdown_rev.html.twig' %} 
  31.               {%  include 'NCBSWBundle:Bible:interface/popup/bible_story_popup.html.twig' %}
  32.           </li>
  33.       {% endif %}
  34.     {% else %}
  35.       <li class="breadcrumb-item">
  36.         <a href="{{ path('bible_translation_list') }}" aria-label="Back to Bible home"><i class="fad fa-book-bible"></i></a>
  37.       </li>
  38.       <li class="breadcrumb-item">
  39.         
  40.         {#% include 'NCBSWBundle:Bible:interface/translation_dropdown/dropdown.html.twig' with {'dropdown_target': 'multicolumn'} %#}
  41.                 
  42.           {% include 'NCBSWBundle:Bible:interface/popup/translation_popup.html.twig' with {'dropdown_target': 'multicolumn'} %}
  43.           
  44.       </li>
  45.       {% if contents is not empty %}
  46.         <li class="breadcrumb-item">
  47.             {% if bOnMobile    %}
  48.                 {% include 'NCBSWBundle:Bible:interface/popup/book_popup.html.twig' %}
  49.             {% else    %}
  50.                   {% include 'NCBSWBundle:Bible:interface/popup/book_popup_multi_col.html.twig' %}
  51.               {% endif %}    
  52.           {#% include 'NCBSWBundle:Bible:interface/book_dropdown/dropdown.html.twig' %#}
  53.         </li>
  54.         <li class="breadcrumb-item">
  55.             {% if bOnMobile    %}
  56.                 {% include 'NCBSWBundle:Bible:interface/popup/chapter_popup.html.twig' %}
  57.             {% else    %}
  58.                   {% include 'NCBSWBundle:Bible:interface/popup/chapter_popup_multi_col.html.twig' %}
  59.               {% endif %}        
  60.           {#% include 'NCBSWBundle:Bible:interface/chapter_dropdown/dropdown.html.twig' %#}
  61.         </li>
  62.         {% if first_chapter == last_chapter and (first_verse != chapter.verses|first or last_verse != chapter.verses|last) %}
  63.           <li class="breadcrumb-item">
  64.             <button type="button" class="btn btn-text" >
  65.             {% if first_verse == last_verse %}
  66.               {{ app.session.get('ui_str')["bible.versenav.versenum"]|replace({'_8300_': first_verse.indexDisplay})|raw }}
  67.             {% else %}
  68.               {{ app.session.get('ui_str')["bible.versenav.verserange"]|replace({'_8310_': first_verse.indexDisplay, '_8320_': last_verse.indexDisplay})|raw }}
  69.             {% endif %}
  70.             </button>
  71.           </li>
  72.         {% endif %}
  73.       {% endif %}
  74.   {% endif %}
  75. {% endblock %}