vendor/score/cms/src/Resources/views/Public/default/subpage.html.twig line 1

Open in your IDE?
  1. {# {% extends  template is defined and template is not null ? [template, '@ScoreCms/Page/Public/baseLayout.html.twig'] : '@ScoreCms/Page/Public/baseLayout.html.twig' %} #}
  2. {% extends cms_template() %}
  3. {% import "@ScoreBase/Default/macros.html.twig" as m %}
  4. {% set reactFiles = cms_react_apps(page.blockJoints|map(pb => pb.block.type)) %}
  5. {% macro getCenterClassNames(p) %}{{
  6.     p.hasLeftBar and p.hasRightBar
  7.         ? "govuk-grid-column-full govuk-grid-column-one-half-from-desktop"
  8.         : p.hasLeftBar or p.hasRightBar
  9.             ? "govuk-grid-column-full govuk-grid-column-three-quarters-from-desktop"
  10.             : "govuk-grid-column-full"
  11.  }}{% endmacro %}
  12. {% block title %}{{page.title}} | {{parent()}} {% endblock %}
  13. {% block stylesheets %}
  14.     {{ page.metatags | filter (mTag => mTag.metatagPattern.type is same as "head") | join("\n") | raw }}
  15.     {{ m.filterCss(reactFiles) }}
  16.     {{parent()}}
  17. {% endblock %}
  18. {% block javascripts %}
  19. {{ m.filterJs(reactFiles) }}
  20.     {{parent()}}
  21. {% endblock %}
  22.  {% block footer_logo %}
  23.     {{ 'idsk-footer-logo' | cms_text | raw  }}
  24.  {% endblock %}
  25. {% block body %}
  26.     <div class="container{{ page_container_fluid is defined and page_container_fluid ? "-fluid" }} cms_seo_{{ page.seoId | replace({'/': "_"}) }}"> {# you can set in fwig globals #}
  27.         <div class="row govuk-grid-row">
  28.             <div class="col-md-12 govuk-grid-column-full">
  29.                 {% if not (hide_pages_heading is defined and hide_pages_heading) %} {# you can set in fwig globals #}
  30.                     <h1 class="govuk-heading-xl">{{ page.name }}</h1>
  31.                 {% endif %}
  32.                 {% if  page.seoId == 'homepage' and not (hide_homepage_intro_block is defined and hide_homepage_intro_block) %} {# you can set in fwig globals #}
  33.                     {{ include('@ScoreCms/Public/idsk/_intro_block.html.twig') }}
  34.                 {% endif %}
  35.             </div>
  36.         </div>
  37.         <div class="{{page.layout}} row govuk-grid-row">
  38.             {% if page.hasLeftBar %}
  39.                 <div class="col-md-12 col-lg-3 govuk-grid-column-full govuk-grid-column-one-quarter-from-desktop">
  40.                     {% for blockJoint in page.blockJoints %}
  41.                         {% if 'left' == blockJoint.place %}
  42.                             {# <h2>{{ blockJoint.block.name }}</h2> #}
  43.                             {{ include('@ScoreCms/Public/default/_block.html.twig',{'blockJoint': blockJoint}) }}
  44.                         {% endif %}
  45.                     {% endfor %}
  46.                 </div>
  47.             {% endif %}
  48.             <div class="col {{  _self.getCenterClassNames(page) }}">
  49.             {% for blockJoint in page.blockJoints %} {# sections for wavex #}
  50.                 {% if 'center' == blockJoint.place %}
  51.                     <div id="cms-block-{{ blockJoint.block.id }}" class="{{ blockJoint.block.paramsArr.nav is defined and blockJoint.block.paramsArr.nav ? "section "}} cms-block-c-{{ blockJoint.block.id }}">
  52.                         {% if 'pageContent' == blockJoint.block.type %}
  53.                             {{ page.content| cms_document_links | raw }}
  54.                         {% else %}
  55.                             {# <h2>{{ blockJoint.block.name }}</h2>#}
  56.                             {{ include('@ScoreCms/Public/default/_block.html.twig',{'blockJoint': blockJoint}) }}
  57.                         {% endif %}
  58.                     </div>
  59.                 {% endif %}
  60.             {% endfor %}
  61.             </div>
  62.             {% if page.hasRightBar %}
  63.                 <div class="col-md-12  col-lg-3 govuk-grid-column-full govuk-grid-column-one-quarter-from-desktop">
  64.                     {% for blockJoint in page.blockJoints %}
  65.                         {% if 'right' == blockJoint.place %}
  66.                         {#     <h2>{{ blockJoint.block.name }}</h2>#}
  67.                             {{ include('@ScoreCms/Public/default/_block.html.twig',{'blockJoint': blockJoint}) }}
  68.                         {% endif %}
  69.                     {% endfor %}
  70.                 </div>
  71.             {% endif %}
  72.         </div>
  73.     </div>
  74. {% endblock %}