templates/blocks/framework_cards_mazda.html.twig line 1

Open in your IDE?
  1. {#
  2.     {
  3.         "key": "framework_cards_mazda",
  4.         "category": "mazda",
  5.         "label": "clickable Cards mazda",
  6.         "description": "Toont een dynamisch aantal kaarten naast elkaar waar op je kan drukken",
  7.         "allowMove": true,
  8.         "blocks": [
  9.             {
  10.                 "key": "block-0",
  11.                 "size": 4,
  12.                 "buttons": true,
  13.                 "multiple": true,
  14.                 "minimum": 3,
  15.                 "required": "media",
  16.                 "fields": [
  17.                     {
  18.                         "key": "title",
  19.                         "type": "text",
  20.                         "label": "Card title"
  21.                     },
  22.                     {
  23.                         "key": "content",
  24.                         "type": "textarea",
  25.                         "label": "Tekst"
  26.                     }
  27.                 ]
  28.             }
  29.         ]
  30.     }
  31. #}
  32. <section id="{{wrapper.cssId is defined ? wrapper.cssId : ''}}" class="cards {{wrapper.cssClass is defined ? wrapper.cssClass : ''}}">
  33.   <div class="container">
  34.     {% if wrapper.label or wrapper.intro is not empty %}
  35.       <div class="introblock">
  36.         {% if wrapper.label is not empty %}
  37.           <div class="introtitle">
  38.             {{wrapper.label|raw}}
  39.           </div>
  40.         {% endif %}
  41.         {% if wrapper.intro is not empty %}
  42.           <div class="introtext">
  43.             {{wrapper.intro|raw}}
  44.           </div>
  45.         {% endif %}
  46.       </div>
  47.     {% endif %}
  48.     <div class="row blocks">
  49.       {% for b in wrapper.blocks %}
  50.         <div class="col-sm-12 col-md-6 col-lg-{{wrapper.gridSize > 0 ? 12 / wrapper.gridSize : 4}}"
  51.         {% if b.config.link is not empty %}onclick="location.href='{{ b.config.link }}';" style="cursor: pointer;"{% endif %}>
  52.           <div class="card">
  53.         <div class="container overflow">
  54.             {% if b.media is not empty %}
  55.             <div class="image-wrapper">
  56.               <div class="image" style="background: url('/{{b.media.getWebPath() }}') no-repeat center; background-size: cover;">
  57.               </div>
  58.             </div>
  59.             {% endif %}
  60.         </div>
  61.             <div class="card-body card-content">
  62.               <h3 class="card-title">{{b.config.title}}</h3>
  63.               <p>
  64.                 {{b.config.content|raw}}
  65.               </p>
  66.               {% if b.config.buttons is defined %}
  67.                 <div class="btns">
  68.                   {% for button in b.config.buttons %}
  69.                     <a href="{{button.url}}" {% if button.target is defined and button.target != "null" %} target="{{button.target}}" {% endif %} class="btn {{button.class}}">
  70.                       {{button.label}}
  71.                       <i class="fa fa-angle-right"></i>
  72.                     </a>
  73.                   {% endfor %}
  74.                 </div>
  75.               {% endif %}
  76.             </div>
  77.           </div>
  78.         </div>
  79.       {% endfor %}
  80.     </div>
  81.   </div>
  82. </section>